d3d12: RSSetScissorRects with more than 16 rectangles keeps the first 16; d3d12_close_parity passes again (D3D-SCISSOR-COUNT-PARITY) #1286
No reviewers
Labels
No labels
accessibility
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
missing claim
needs rebase
question
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/ubiquitarianism--leonida!1286
Loading…
Reference in a new issue
No description provided.
Delete branch "gh-pr/1286/head"
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?
@aslan2142 on GitHub · 2026-11-24 21:16 UTC · original
aslan2142:d3d12-scissor-count-parity→main· +6 −1 · 1 files · 1 commits · merged 2026-11-24 21:25 UTCClaimed in the coordination issue as: D3D-SCISSOR-COUNT-PARITY (#14)
What and why
d3d12_close_parityhas failed onmainsince #510 was merged (found by QemmHD in #510):RSSetScissorRectswith more than 16 rectangles an error (check(false)), so the list'sClosereturnsE_INVALIDARG.runtime/test/d3d12_close_parity_test.cpp:362expects the layer to match it.stubnotice. Counts from 1 to 16 behave as before.RSSetViewports(17)is unchanged; the parity test already lists it as a known stricter case.I merged #510, so this is my regression to fix. One file:
runtime/shims/d3d12_com.cpp.Tested
The Windows runtime was cross-built on Linux with clang-cl / lld-link 23.1.5 and the xwin MSVC CRT and Windows SDK 10.0.26100, and the full
ctestsuite was run under Wine 11.22, headless, on two devices. No game files.maind3d12_close_parityRSSetScissorRects(17)d3d12_multi_viewport(from #510)mainunder the same setup, no test changes from pass to fail on either device.GPUs tested: Mesa llvmpipe (LLVM 23.1.5) and AMD Ryzen 9 7950X3D integrated graphics (RDNA2, RADV, Mesa 26.3.1), Linux, through Wine 11.22
AI-assisted: yes (Claude Code, Claude Fable 5.2)
Checklist
mainand merges cleanly (a conflicting pull request is labeledneeds rebase).docs/design.md, with how it was confirmed. (No translator rule.)The multi-viewport change made a call with more than 16 rectangles an error, so the list's Close returned E_INVALIDARG. WARP closes such a list, and d3d12_close_parity has that row ("RSSetScissorRects(17)", match), so the test has failed on main since that merge. The call is no longer an error: the rectangles past the 16 a pipeline can have are dropped, with a one-time notice. Co-Authored-By: Claude Fable 5.2 <[email protected]>@quartz-heron-58 on GitHub · 2026-11-24 21:23 UTC · original
Independent Windows run of
4ff9a77f: Windows 11 build 26300, NVIDIA GeForce RTX 4080 (621.24), MSVC 14.44 RelWithDebInfo, built withscripts\build_runtime.ps1.d3d12_close_parity: passes. 113 cases, 82 match WARP, 16 known layer-stricter, 15 known layer-looser, 0 failures. TheRSSetScissorRects(17)row reads0x00000000 | 0x00000000 | match, and the layer prints the one-time note that the first 16 are used.6261ca91(measured in another tree, merged into the #1028 branch) the same test fails withRSSetScissorRects(17): layer Close 0x80070057, WARP succeeds, 81 matching.d3d12_multi_viewport: all 4 cases, 64/64 pixels exact against host D3D12.ctest -j 6, whole suite: 314 of 314 pass.One run of each. No game files. Not run: other GPUs, validation layers.
AI-assisted: yes (Claude Code)
@QemmHD on GitHub · 2026-11-24 21:31 UTC · original
Confirmed after the merge on Windows 11 / RTX 4070 SUPER (NVIDIA 621.24, VS 2022, Ninja, RelWithDebInfo), with a fresh build of main
51757ec55. The results are identical plain and withLEONIDA_VK_VALIDATION=1, with 0 VUIDs:d3d12_close_paritypasses: 113 cases, 0 failures.RSSetScissorRects(17)now returns0x00000000, matching WARP.d3d12_multi_viewportpasses all 4 cases, an exact match against host D3D12.d3d12_drawpasses.Thanks for the quick fix.
AI-assisted (Claude Code, Claude Opus 5.5).