shader: lower private LDS subword accesses in compute #859
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/865"
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-23T14:41:23Z.
Scope
Extend the thread-private gfx1030 LDS word added in #857 with
ds_write_b8,ds_write_b16,ds_read_u8,ds_read_i8andds_read_i16. Partial stores capture the low source bits and preserve the rest of the initialized word. Byte offsets are 0–3 and halfword offsets are 0 or 2. The existing 32×1×1 group, verifiedlocal_x << 2address, full EXEC, explicit allocation and immediates_waitcnt lgkmcnt(0)checks apply.Verification
Tested commit
0c609b6on Windows 11 25H2 (10.0.26200.9974), with the D3D12 debug layer enabled. The hardware run used AMD Radeon RX 7900 XTX (driver 32.0.32029.2010) and the WARP run used Microsoft Basic Render Driver (10.0.26100.9818). No debug errors or warnings in the passing LDS dispatches.7 passed, 0 failed, 0 skipped. On each backend the six subword variants compare the complete 320-word UAV for one-group and three-group dispatches. All six full-write mutants mismatch at word 0 (for example,
42abcd70expected and12340070observed), and all six zero-extension mutants mismatch at word 50 (byteffffff80vs00000080, halfwordffff8000vs00008000). The form-coverage records include all five added forms.Passed with LLVM 15.0.7 in WSL Ubuntu 24.04. Each new case preserves the DS instruction spellings, and decoded and CLI translation reproduce the HLSL from the source assembly. The D3D12 readbacks measure the translated shader against the CPU reference.