startup: pass OMSetStencilRef (slot 24) to the desktop list #1780
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/1787"
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 tedin7 on 2026-11-24T18:40:53Z.
Adds the missing command-list slot 24,
OMSetStencilRef, in the style of slots 21 to 23. Onmainslot 24 has no handler, so it falls through to thex2w-noopstand-in and the reference never reaches the desktop list.Changes
list_stencil_ref(reference)insrc/startup_stubs/d3d12_xs_device.cppcallsOMSetStencilRefon the desktop list while it is recording, and does nothing on a closed list. Installed aslist_typed[24]in render mode, next to slot 23.tests/startup_stream_depth.cppandtests/startup_stream_depth_check.pyadd four cases on aD24_UNORM_S8_UINTview with a stencil-onlyEQUALpipeline: stored 0x5A with reference 0x5A (all 16 pixels drawn), stored 0x5A with reference 0x5B (none), stored 0 with reference 0 and stored 0xFF with reference 0xFF (all drawn). Reference 0 is the list's default, so the 0x5A and 0xFF cases are the ones that prove the call was forwarded. A call on the already closed list is made after the first case. The harness now takes four more output paths (19 arguments instead of 15) and the existing cases are unchanged.docs/startup-runtime.mdanddocs/experiments.md.The slot number is the desktop one (the ABI notes call it NAMED, not observed in a title log).
Verified on Windows Server 2025 (Build 26100, MSVC 14.44.35207 + D3D12 WARP)
At commit
1c3777c0cfa990cff57317e31f0a3c63f9940b17:--preset dev):cmake --build --preset dev --target d3d12_xs_shim startup_stream_depth d3d12x_graphics_list_check -- -j 8(19.85s)ctest --preset dev -R '^(startup_stream_depth_warp|d3d12x_graphics_list_warp|startup_stubs)$' --parallel 6 --no-tests=error --output-on-failure: 3/3 passed (d3d12x_graphics_list_warp0.06s,startup_stubs0.48s,startup_stream_depth_warp3.33s)/O2(--preset release):cmake --build --preset release --target d3d12_xs_shim startup_stream_depth d3d12x_graphics_list_check -- -j 8(36.34s)ctest --preset release -R '^(startup_stream_depth_warp|d3d12x_graphics_list_warp|startup_stubs)$' --parallel 6 --no-tests=error --output-on-failure: 3/3 passed (d3d12x_graphics_list_warp0.06s,startup_stubs0.53s,startup_stream_depth_warp3.03s)--preset dev,startup_stream_depth_warp):list_typed[24] = reinterpret_cast<ListTyped>(&list_stencil_ref);insrc/startup_stubs/d3d12_xs_device.cpp: killed (AssertionError: stencil ref equal 0x5A: 0000ffff..., all pixels remained clear blue).0instead ofreferenceinlist_stencil_ref: killed (AssertionError: stencil ref equal 0x5A: 0000ffff...).Verified on Linux
git diff --check origin/main...HEAD,tests/docs_links_check.py,tests/bidi_controls_check.py: pass.Not verified
startup_stream_depth_hardwarewas not run (the test VM only has D3D12 WARP).AI-assisted; commands listed were executed locally.
Imported from R0Y00/Xbox2Windows. Originally posted by chatgpt-codex-connector[bot] on 2026-11-24T19:00:11Z.
Codex Review Summary: ✅ Completed
This comment shows the latest Codex review activity on this pull request.
1c3777cℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.
Imported from R0Y00/Xbox2Windows. Originally posted by R0Y00 on 2026-11-24T19:14:46Z.
Independent Release initially failed on both WARP and RTX with debug message 821 because a texture created with optimized stencil clear 0 was cleared to 0x5A or 0xFF. I pushed the fixture fix: each case creates its DSV with the clear it will use. The same draws, references and closed-list control remain in place, and the strict debug-output check passes. Both backends passed 2/2.