Replay: the stand-in for the other API is Linux's and macOS's; the validation crate's clippy for Windows passes

The validation crate builds for x86_64-pc-windows-gnullvm (with llvm-mingw for the bundled
SQLite, as win-cross.sh builds command-replay for the Windows play), and its clippy there (job
m3-max-78094 at abf7b8f873, plain and under --cfg m2v_gpu) reported the stand-in: its writes wait
under the crate's bounded fence waits (gpu::wait::vulkan), which the crate keeps to Linux and macOS,
and its empty extension list for an NT handle did not type-check. Rather than a Windows form of the
fence wait, the stand-in is Linux's and macOS's alone: its import is fd-only, and on any other host
StandIn::new says why it is absent, so each landing is counted unwritten with that reason and the
play goes on (the S1 ruling's handling of a stand-in that cannot be made). The NT-handle import,
which no build compiled, is gone, and so is the device test's Windows arm: the test, under the
layer through candidate::validated, is Linux's and macOS's. A plane's rows are the caller's tuple.

The same clippy reported lib-test code that predates the exported surfaces and never compiled for
Windows: build_support_tests.rs hex-encoded through crate::hash (not on Windows; now sha2's own
lower-hex), and gpu/wait.rs's tests of the fence and Metal waits' own endings, which Windows lacks
(now gated as those variants are).

docs/REPLAY-STREAM.md section 10 says the stand-in is Linux's and macOS's and what Windows counts.
This commit is contained in:
Anees Iqbal committed 2026-12-02 05:39:49 -08:00
1 parent b111f209ec
commit ca370da605
7 files changed
+169 -154

No files matched your search

+8 -6
View File
@@ -989,12 +989,14 @@ contract (below) where the surface is made, and each check matches where the sta
a skipped object, counted by its reason; a handle this host has none of (an NT handle on Unix,
an fd on Windows) stops the play, which `--video-handle` avoids. At `m2v.exportSurface` the
player waits for the surface's ready point (`Surface::wait_until_ready`). The other API that
wrote the pictures where the stream was recorded is not there on replay, so a Vulkan device of
the player's own, on the runtime's instance and physical device, stands in for it: at the
surface's first export it imports the handle as one buffer over the whole memory (an opaque
handle at the size and memory type it was exported with, in an allocation dedicated to the
buffer only where the driver requires one; a dma-buf into a memory type its fd's query lists,
dedicated). At `m2v.surfaceWritesDone` the player first waits for every committed command
wrote the pictures where the stream was recorded is not there on replay, so on Linux and macOS
a Vulkan device of the player's own, on the runtime's instance and physical device, stands in
for it: at the surface's first export it imports the handle, an fd, as one buffer over the whole
memory (an opaque fd at the size and memory type it was exported with, in an allocation
dedicated to the buffer only where the driver requires one; a dma-buf into a memory type its
fd's query lists, dedicated). On Windows nothing stands in for it: the stand-in's writes wait
under the validation crate's bounded fence waits, which only Linux and macOS have, so there
each landing is counted unwritten with that reason. At `m2v.surfaceWritesDone` the player first waits for every committed command
buffer that can complete, as the other API writes a picture after the work before it; then the
stand-in copies each plane's rows into the memory at the play's layout (`SurfaceExport::planes`:
each plane's first byte and row pitch), or, where the record holds no bytes, fills the whole