⬆️ Build on metal2vulkan 01506bb3ac's runtime
Pin move 24: metal2vulkan development f84816ddec..01506bb3ac, RUNTIME_VERSION 1897 -> 1919, SEMANTICS_VERSION 1993 -> 1994. What changes for the guest and the host: - A clip's first scatter into guest RAM is staged, and a first gather over a chunk the device's thread imports goes through the CPU, so neither makes an import or memory on the calling thread (the 5080's 70.9/108 ms scatter calls measured 0.22/0.24 ms). Staged gathers take their staging region at their host step, and emptied memory blocks are kept within a heap budget, so a clip's burst of frees and allocations stops paying for VkDeviceMemory again. - On unified memory (the 780M) Private memory takes the system heap first, with one budget of kept blocks across the heaps: later clips made no allocation and took 121.5/119.2 ms against 237/245 ms. - Hand-outs of Vulkan objects settle only their own first work. - The host RAM fault-in reads a VMM's shared memfd pages without holding the process's mmap_lock (writer waits beside imports 5.7-7.5 -> 0.2-0.4 ms). - A RAM's use, dropped, stops and waits out its device thread, which checks between 2 MiB steps: once a lease's drop returns, nothing reads, faults in or imports a page of that RAM, so the VMM may unmap it at once. - The device's start-up import check makes one set of imports a try (98 allocations on the 780M, from 386, with the same verdicts). - A device works out the formats of any view once rather than for each texture made at an offset in a Shared heap (738 -> 85.5 allocations a call on the RX 7900 XTX). - Draws keep their bind state per pipeline state across render-state sets. - Where Metal keeps a heap texture in its uncompressed tiles, the image in place lies exactly as those tiles do, and otherwise the texture keeps a shadow of them; textures Metal compresses stay in place. On the Iris Xe heap textures lie in place as linear images where they can, and a few small uncompressed shapes fall back to shadows, announced. - Multisample depth heap textures keep the heap's bytes on the Iris Xe; a device that clamps depth values on upload announces it (restricted-depth-upload). - In-place check records (version 12) drop the stale Unchecked verdicts an earlier check left. - macOS 11's Core Image kernels compile: a repeated equal compile option and bitcode module version 1 translate. - Buffers can be exported as dma-bufs from the runtime's pooled memory; the library does not use it yet. - METAL2VULKAN_LOG_SHADOWS=1 names every shadow a texture makes, and the counts split never-stood copies by cause. with_vk_queue now hands its closure the VkDevice as well; Generation ignores it.
This commit is contained in:
1 parent
5fff6415b1
commit
d2a27d46af
2 files changed
+4
-4
No files matched your search
+2
-2
@@ -33,9 +33,9 @@ reims-vgpu-graphics = { path = "crates/reims-vgpu-graphics" }
|
||||
reims-vgpu-video = { path = "crates/reims-vgpu-video" }
|
||||
# The Vulkan platform's runtime (architecture D1): a Metal-shaped API on Vulkan, from
|
||||
# metal2vulkan's public repository at the commit both name.
|
||||
metal2vulkan-runtime = { git = "https://github.com/steelbrain/metal2vulkan", rev = "f84816ddec9d7b0422f2e12998daee41f67a7dd5" }
|
||||
metal2vulkan-runtime = { git = "https://github.com/steelbrain/metal2vulkan", rev = "01506bb3ac64ff05034eb0e6eb7b73d0a409d574" }
|
||||
# Its translator, for the Metal enums and descriptor values the runtime's calls take.
|
||||
metal2vulkan = { git = "https://github.com/steelbrain/metal2vulkan", rev = "f84816ddec9d7b0422f2e12998daee41f67a7dd5" }
|
||||
metal2vulkan = { git = "https://github.com/steelbrain/metal2vulkan", rev = "01506bb3ac64ff05034eb0e6eb7b73d0a409d574" }
|
||||
# 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
|
||||
|
||||
@@ -77,7 +77,7 @@ impl Generation {
|
||||
for _ in 0..TAKES {
|
||||
let device = generation_serving(queue.device());
|
||||
// SAFETY: the closure keeps no handle and calls nothing.
|
||||
let (vk_queue, family) = unsafe { queue.with_vk_queue(|q, family| (q, family)) };
|
||||
let (vk_queue, family) = unsafe { queue.with_vk_queue(|_, q, family| (q, family)) };
|
||||
let handle = handle_of(&device);
|
||||
if handle_of(&generation_serving(queue.device())) == handle {
|
||||
return Ok(Generation {
|
||||
@@ -141,7 +141,7 @@ impl Generation {
|
||||
submit: impl FnOnce(vk::Queue) -> R,
|
||||
) -> Option<R> {
|
||||
// SAFETY: the caller's.
|
||||
unsafe { queue.with_vk_queue(|q, _| (q == self.queue).then(|| submit(q))) }
|
||||
unsafe { queue.with_vk_queue(|_, q, _| (q == self.queue).then(|| submit(q))) }
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user