disasm_rdna2: decode 64-bit DS local data share instructions #621
No reviewers
Labels
No labels
accessibility
awaiting author
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
priority: P0
question
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/R0Y00--Xbox2Windows!621
Loading…
Reference in a new issue
No description provided.
Delete branch "gh-pr/621/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?
@Neoplayer on GitHub · 2026-11-22 16:15 UTC · original
Neoplayer:disasm/ds-instructions→main· +429 −2 · 3 files · 3 commits · merged 2026-11-23 05:26 UTCChange
Add decoding for 64-bit RDNA 2 (
gfx1013) DS instructions ((w0 & 0xfc000000) == 0xd8000000, 154 forms) intools/disasm_rdna2.pyand synchronizetools/scan_unsupported_shaders.py:tools/disasm_rdna2.py:DS_OPS(154 opcodes: mnemonic, vdst/data0/data1 widths, address presence, offset mode, gds mode),_format_ds_swizzle()(QUAD_PERM, SWAP, REVERSE, BROADCAST, BITMASK_PERM, decimal fallback, omitted when 0) and_decode_ds().offset:<u16>when non-zero; dual-offset ops (read2*,write2*,wrxchg2*) print non-zerooffset0:/offset1:;gdsis printed when set.gds-only ops withoutgds,gds-invalid ops withgds, andds_nopwith an offset fall back to 8 bytes to keep stream alignment; short buffers giveds_truncated.tools/scan_unsupported_shaders.py: register all DS mnemonics inKNOWN_RDNA2_BASE_OPCODES.tests/rdna2_tools_check.py: 33 LLVM-15-assembled golden vectors, a synthetic sweep over all 154 opcodes, offset/swizzle/gds distinction and alignment tests, and DS entries in the exact-assembly LLVM comparison.Verification
Commit under test:
a741805, macOS arm64, Homebrew LLVM 15.0.7 (-mcpu=gfx1013):LLVM_LIB=... LLVM_MC=... LLVM_OBJCOPY=... python3 -B tests/rdna2_tools_check.py:Ran 52 tests - OK.pixel_aot.disassemble(..., libLLVM-15.dylib)over all 154 opcodes (gds/offset variants):Checked 653 DS encodings ... mismatches=0.imm16values: 0 mismatches (checked before porting into the tool).DSrows indocs/coverage/gfx1013.tsv.pixel_aot_check.py binary,ffx_dispatch_aot_check.pyand the other Python checks from.github/workflows/windows.ymlthat run without Windows: exit 0.git diff --check: exit 0.MSVC, D3D12 and WARP were not run on this macOS host.
Evidence and follow-up
All fixtures are source-built synthetic sequences checked against LLVM 15.0.7. Remaining undecoded 64-bit encodings include
SDWA/DPP.Checklist
AI-assisted.