⬆️ Build on metal2vulkan development dfbc157464
Pin T, from 14c37cc76d (S): 31 commits, no merges. What changes for the guest: - A fragment shader that copies texture handles as integers and merges them at a join now compiles as the handle of the branch taken. A handle phi of a constant with one candidate of its class compiles too. Before, rt refused both (Lowering(Access) HandleUse, ConstantOperand); a 3D-model preview's lit pipeline met the first at each boot. - A texture over a buffer that is written through a view of another format, where the device makes that linear image only plain, is now a counted copy (rt's OverCause::ViewStorage) instead of the extended image in place. The guest reads and writes the same texels. - A select of a typed 64-bit atomic's slot on the address form compiles; before, rt answered an internal error (ZeroAddress). - rt's mode-2 texture-buffer word writes round half and RG11B10 to nearest even. The device answers no to mode 2, so no guest reaches it. What changes on our side, for the new cause: - The counts line folds rt's view-storage copies as rt-over-copies-view-storage and rt-over-copy-bytes-view-storage. The trace's rtcounts carries the pair after image-memory's. - A shape's in-place refusal and download name it view-storage. Like linear-features, it comes from the descriptor and the kind of memory alone, so it is kept per descriptor and kind. - The 10 s summary lists its bytes as "view storage". - over_copies_fold_into_the_counts_by_their_rise holds the new pair. HOLD_BEGIN_BOUND's doc says the restoring make's wait holds "from 14c37cc76d on", which T leaves as it was.
This commit is contained in:
1 parent
fdc1ecbbb5
commit
4312d83052
5 files changed
+18
-10
No files matched your search
+2
-2
@@ -33,11 +33,11 @@ reims-vgpu-graphics = { path = "crates/reims-vgpu-graphics" }
|
||||
reims-vgpu-video = { path = "crates/reims-vgpu-video" }
|
||||
# metal2vulkan's Metal types, for the Metal enums and descriptor values the runtime's calls take,
|
||||
# from metal2vulkan's public repository at the commit both name.
|
||||
metal2vulkan = { git = "https://github.com/steelbrain/metal2vulkan", rev = "14c37cc76d97467b4ab896cd367cb4c080f404f8" }
|
||||
metal2vulkan = { git = "https://github.com/steelbrain/metal2vulkan", rev = "dfbc1574640c5ac4cb6b9b0ffb78006b7984d108" }
|
||||
# The Vulkan platform's runtime (architecture D1), metal2vulkan-runtime: a Metal-shaped API on
|
||||
# Vulkan, one path for every device, under reims-vgpu-vulkan's `rt_platform` and `seam` and
|
||||
# reims-vgpu's `pool::rt_blocks`.
|
||||
metal2vulkan-runtime = { git = "https://github.com/steelbrain/metal2vulkan", rev = "14c37cc76d97467b4ab896cd367cb4c080f404f8" }
|
||||
metal2vulkan-runtime = { git = "https://github.com/steelbrain/metal2vulkan", rev = "dfbc1574640c5ac4cb6b9b0ffb78006b7984d108" }
|
||||
# The hashes of the Vulkan platform's metallib sources (reims-vgpu-vulkan/build.rs).
|
||||
sha2 = "0.10.9"
|
||||
# A display window's swapchain on Linux (reims-vgpu-vulkan/src/swapchain.rs), at the runtime's
|
||||
|
||||
@@ -2737,6 +2737,7 @@ fn over_cause_why(cause: rt::OverCause) -> &'static str {
|
||||
rt::OverCause::RenderReach => "render-reach",
|
||||
rt::OverCause::Alignment => "alignment",
|
||||
rt::OverCause::ImageMemory => "image-memory",
|
||||
rt::OverCause::ViewStorage => "view-storage",
|
||||
_ => "other-cause",
|
||||
}
|
||||
}
|
||||
@@ -2754,7 +2755,7 @@ pub use rt::RestoreFence;
|
||||
/// place, so a caller may keep it per descriptor and kind of memory and import no further buffer
|
||||
/// to ask (rt's `Buffer::texture_copy_cause`). Its other causes (spilled, pitch, alignment,
|
||||
/// render-reach, image-memory) depend on the buffer and its place.
|
||||
const KIND_ONLY_WHYS: [&str; 7] = [
|
||||
const KIND_ONLY_WHYS: [&str; 8] = [
|
||||
"host-memory",
|
||||
"dma-buf",
|
||||
"dma-bufs",
|
||||
@@ -2762,6 +2763,7 @@ const KIND_ONLY_WHYS: [&str; 7] = [
|
||||
"surface",
|
||||
"linear",
|
||||
"linear-features",
|
||||
"view-storage",
|
||||
];
|
||||
|
||||
/// The kind of memory every import of the host's pages lies in where rt takes it, known before
|
||||
|
||||
@@ -713,8 +713,8 @@ static GAUGES_HIGHEST: crate::core::sync::Mutex<[u64; HIGHEST_GAUGES]> =
|
||||
crate::core::sync::Mutex::new([0; HIGHEST_GAUGES]);
|
||||
|
||||
/// The over-copy metrics the counts line and the trace's `rtcounts` carry ([`over_copy_counts`]):
|
||||
/// the over-copies and their bytes, those over an imported block, and the 13 causes' pairs.
|
||||
pub(super) const OVER_COPY_METRICS: usize = 4 + 2 * 13;
|
||||
/// the over-copies and their bytes, those over an imported block, and the 14 causes' pairs.
|
||||
pub(super) const OVER_COPY_METRICS: usize = 4 + 2 * 14;
|
||||
|
||||
/// The metrics the counts line carries ([`folded_counts`]): the over-copy metrics, then the
|
||||
/// command buffers held for room, the cache writes dropped, the cache bytes written, the
|
||||
@@ -1096,6 +1096,7 @@ pub(super) fn over_copy_counts(m: &rt::Metrics) -> [(&'static str, u64); OVER_CO
|
||||
"render-reach" over_copies_render_reach over_copy_bytes_render_reach,
|
||||
"alignment" over_copies_alignment over_copy_bytes_alignment,
|
||||
"image-memory" over_copies_image_memory over_copy_bytes_image_memory,
|
||||
"view-storage" over_copies_view_storage over_copy_bytes_view_storage,
|
||||
)
|
||||
}
|
||||
|
||||
@@ -2887,6 +2888,8 @@ mod tests {
|
||||
"rt-over-copy-bytes-pitch",
|
||||
"rt-over-copies-image-memory",
|
||||
"rt-over-copy-bytes-image-memory",
|
||||
"rt-over-copies-view-storage",
|
||||
"rt-over-copy-bytes-view-storage",
|
||||
HELD_FOR_ROOM_CODE,
|
||||
CACHE_WRITES_DROPPED_CODE,
|
||||
CACHE_BYTES_WRITTEN_CODE,
|
||||
@@ -2999,6 +3002,8 @@ mod tests {
|
||||
m.over_copy_bytes = 12288;
|
||||
m.over_copies_image_memory = 1;
|
||||
m.over_copy_bytes_image_memory = 4096;
|
||||
m.over_copies_view_storage = 2;
|
||||
m.over_copy_bytes_view_storage = 8192;
|
||||
m.held_for_room = 5;
|
||||
m.cache_writes_dropped = 3;
|
||||
m.cache_bytes_written = 98_304;
|
||||
@@ -3054,10 +3059,10 @@ mod tests {
|
||||
assert_eq!(
|
||||
rose,
|
||||
[
|
||||
3, 12288, 1, 4096, 1, 4096, 1, 4096, 1, 4096, 5, 3, 98_304, 9, 4, 4_250_000, 6,
|
||||
28_500_000, 3, 1, 2, 3, 9_000, 2, 3, 1, 7, 5, 11, 2, 10, 4, 14_745_600, 5,
|
||||
41_472_000, 3, 24_883_200, 13, 9, 4, 12, 5, 8, 6, 19, 3, 3_145_728, 24, 5,
|
||||
18_750_000, 3, 1_300_000, 4, 25, 102_400, 10, 20_480, 1
|
||||
3, 12288, 1, 4096, 1, 4096, 1, 4096, 1, 4096, 2, 8192, 5, 3, 98_304, 9, 4,
|
||||
4_250_000, 6, 28_500_000, 3, 1, 2, 3, 9_000, 2, 3, 1, 7, 5, 11, 2, 10, 4,
|
||||
14_745_600, 5, 41_472_000, 3, 24_883_200, 13, 9, 4, 12, 5, 8, 6, 19, 3, 3_145_728,
|
||||
24, 5, 18_750_000, 3, 1_300_000, 4, 25, 102_400, 10, 20_480, 1
|
||||
]
|
||||
);
|
||||
let named = over_copy_counts(&m).map(|(code, _)| code);
|
||||
|
||||
@@ -166,6 +166,7 @@ pub(crate) fn line(before: &rt::Metrics, now: &rt::Metrics, gauges: &rt::Gauges)
|
||||
("render reach", rose!(over_copy_bytes_render_reach)),
|
||||
("alignment", rose!(over_copy_bytes_alignment)),
|
||||
("image memory", rose!(over_copy_bytes_image_memory)),
|
||||
("view storage", rose!(over_copy_bytes_view_storage)),
|
||||
];
|
||||
let by_cause: Vec<String> = (causes.iter())
|
||||
.filter(|(_, bytes)| *bytes > 0)
|
||||
|
||||
@@ -9177,7 +9177,7 @@ const HOLD_PASSING: [&str; 2] = ["busy", "unsettled"];
|
||||
/// aed8b7eba3), against 3.5 ms for a 1080p BGRA8 image alone in metal2vulkan-runtime's seam
|
||||
/// tests: at aed8b7eba3 the runtime's restoring make shared one batch and signal with the command
|
||||
/// buffers that went out in its submission, so it waited for them too (read from the runtime's
|
||||
/// code by metal2vulkan, 2026-12-03). At the pinned 14c37cc76d it waits for its restore's batch,
|
||||
/// code by metal2vulkan, 2026-12-03). From 14c37cc76d on it waits for its restore's batch,
|
||||
/// which goes ahead of the command buffers of a group that goes in it, and for those only where
|
||||
/// an upload in that batch uses memory another API shares (the runtime's `Surface` docs). A wait
|
||||
/// outlives a span where that batch, or work the waiting thread would commit, runs past the bound.
|
||||
|
||||
Reference in new issue
Block a user