Files
metal2vulkan/crates
Anees Iqbal 0ab26709c9 A bench of a Managed buffer's copies in across a guest RAM's chunk end
What: tests/host_ram_managed.rs, a new device-test module for Managed
no-copy buffers over a guest RAM, with one ignored release bench,
MANAGED-RAM-COPY-IN. Its buffer is 32 MiB centred on the end of the RAM's
first chunk, and both chunks are imported. Ranges of 256 KiB, 4 MiB and
32 MiB across the chunk end are written and named before each of 20
commits. Each commit reads the range's first and last bytes, and they are
checked. It reports the commit-call and to-completion medians and the
bytes copied in, on the default device and on one of exact_answers().
host_ram_device.rs exposes its RAM helpers and gains held_device(policy).

Why: such a buffer's host copy is its pages alone, because its own import
would be over pages the chunks' imports hold. Its copies in are staged
by the CPU at the commit today. This bench measures that before the GPU
copies them from the chunks' imports.

Verified: not run at this commit. It is run on the 2080 before and after
the change.
2026-11-13 01:56:44 -08:00
..