shader: lower private LDS min, max and reverse subtract updates #891
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/898"
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 stan495 on 2026-11-23T16:26:32Z.
Scope
Extend the private gfx1030 LDS profile from #878 and #885 with
ds_rsub_u32,ds_min_i32,ds_max_i32,ds_min_u32andds_max_u32. Reverse subtraction stores the source minus the old word modulo 2^32. The comparisons select the signed or unsigned minimum or maximum as specified and store its 32-bit pattern. These are the no-return forms at offset 0 and use the existing initialization, private address, EXEC and immediate wait checks.Verification
Tested commit
80c4d6eon Windows 11 25H2 (10.0.26200.9974) with the D3D12 debug layer enabled. Hardware used an AMD Radeon RX 7900 XTX (driver 32.0.32029.2010). WARP used the Microsoft Basic Render Driver (10.0.26100.9818).7 passed, 0 failed, 0 skipped. Both backends matched the CPU reference over all 320 UAV words after dispatches of one and three groups, with zero debug errors or warnings in the LDS dispatches. Each mutant differed at word 1. The reversed subtraction mutant produced
7ffffff8instead of80000008. The four comparison mutants swapped signedness and picked the other operand,7ffffff0orfffffff8.Passed with LLVM 15.0.7 on WSL Ubuntu 24.04. The gfx1030 Wave32 binaries decoded to the expected forms and produced the same HLSL as the source assembly through the direct and CLI paths. The coverage records include all five new forms.