gpu: submit and wait for each shadow frame from the EXE #823
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/829"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Imported from R0Y00/Xbox2Windows. Originally posted by R0Y00 on 2026-11-23T09:26:30Z.
Change
Refs #730 and builds on #826. Reuse the source-built shadow renderer and independent case from #773/#797. The EXE now selects the descriptor slot per frame and owns the order of the fixture imports for recording, submitting, waiting and cleanup. The runtime shares a device, command allocator, direct queue, fence and surfaces across both frames. The standalone shadow check uses the same renderer.
For each adapter, native Windows, pe_map and AOT match the ordered calls with fence values 1 and 2 and all 65,536 published color and light-depth bytes. The stale index changes exactly 170 second-frame color pixels. An unsupported device IID leaves no frame output and exits 20. An invalid second submit index returns
E_INVALIDARGbefore reaching the queue, preserves the 32,768 first-frame bytes, releases four owned surfaces and the device, and exits 24.Verification
Tested
ea96661on Windows 11 26200.9974, RTX 4060 Laptop GPU (NVIDIA 616.56) and WARP 10.0.26100.9818. The EXE provider ran without requesting the D3D12 debug layer. The standalone check retained its existing setup.cmake --build --preset release --target cpu_shim_startup_lifted pe_map offscreen_check --parallel 7passed.ctest --preset release --no-tests=error --output-on-failure -R '^(cpu_native_shim_startup|cpu_shim_(compute|draw|texture_reuse|upload_texture|chain|shadow)_(warp|hardware)|mesh_shadow_draw_(warp|hardware))$'passed 15/15 with zero skips.python -B tests/docs_links_check.pyandgit diff --checkpassed.AI-assisted.
Imported from R0Y00/Xbox2Windows. Originally posted by R0Y00 on 2026-11-23T09:29:53Z.
CPU/PE and GPU review on
ea96661. I reran the Release startup script and the shadow script for WARP and the RTX 4060 Laptop using the built candidate. All 24 shadow child runs passed across native Windows,pe_mapand AOT. The EXE sets the frame and map arguments and preserves the submit index across the record call. The mapper binds the same imports, and the AOT bindings use 32-bit frame/map values and HRESULTs. I checked that each successful frame closes and executes its own list and signals and waits for fence 1 or 2 before readback and allocator reuse. The invalid second index is rejected beforeExecuteCommandLists, preserves exactly 32,768 first-frame bytes and closes four surfaces and the device before exit 24. The stale slot differed at 170 second-frame color pixels on both adapters while light depth matched. This passes review for the tested path. One separate failure path remains unexercised: if queueSignalfails after execution,submittedhas not advanced, so the normal fence accounting cannot establish that the resources are idle.