tooling: print one VGPR for the f64-source VOP1 conversions in disasm_rdna2 #1593

Manually merged
github merged 1 commit from gh-pr/1593/head into gh-pr/1593/base 2026-11-26 23:19:24 +00:00
Owner

@⁠vladbondarenko97 on GitHub · 2026-11-24 14:40 UTC · original
vladbondarenko97:tooling/disasm-vop1-narrow-dst → main · +40 −2 · 3 files · 1 commits · merged 2026-11-24 14:59 UTC

Change

disasm_rdna2 printed the destination of the unextended VOP1 forms v_cvt_i32_f64, v_cvt_u32_f64 and v_cvt_f32_f64 as a VGPR pair (v[4:5]) because the mnemonic ends in _f64. The result is one dword: llvm-mc prints v4, and the VOP3 (_e64) spelling here already did. The binary64 source keeps its pair; binary64 results (v_cvt_f64_i32, v_cvt_f64_f32, v_rcp_f64) are unchanged. Refs #938.

Verification

Commit 2db1df38 on main e09b3302, macOS, Python 3.14.

  • python -B tests/rdna2_tools_check.py TestRdna2Disasm.test_vop1_f64_source_conversions_have_one_register_result: OK. With tools/disasm_rdna2.py from main: FAILED (failures=6).
  • python -B tests/rdna2_tools_check.py: Ran 142, OK (skipped=18).
  • tests/docs_links_check.py, tests/bidi_controls_check.py: OK.

Not run: the Windows build/ctest, and LLVM 15 (not installed here). The golden words come from llvm-mc 23.1.6 (-mcpu=gfx1013); the new test compares against those strings and needs no LLVM.

Evidence and follow-up

Decoder text only; nothing lowers these conversions, so there is no draw or readback. Fixtures are hand-assembled words and llvm-mc output, no game data. docs/experiments.md has a new section. A follow-up names the remaining VOP1 rounding/frexp placeholders (0x17-0x1b, 0x3c-0x41), which build on this change.

Checklist

  • This pull request covers one reviewable behavior.
  • I included the exact command and result for every check I ran.
  • I considered a negative control or failure case for a new fixture.
  • I updated README/docs when a capability or build requirement changed.
  • I did not include game files, dumps, distribution links or secrets.

AI use: Claude Code. Claude Sonnet 5.5 wrote the change, the tests and the llvm-mc sweep; Claude Opus 5.5 reviewed the diff and reran the suite. I reviewed it.

🤖 Generated with Claude Code

**@⁠vladbondarenko97** on GitHub · 2026-11-24 14:40 UTC · [original](https://github.com/R0Y00/Xbox2Windows/pull/1593) `vladbondarenko97:tooling/disasm-vop1-narrow-dst` → `main` · +40 −2 · 3 files · 1 commits · merged 2026-11-24 14:59 UTC ## Change `disasm_rdna2` printed the destination of the unextended VOP1 forms `v_cvt_i32_f64`, `v_cvt_u32_f64` and `v_cvt_f32_f64` as a VGPR pair (`v[4:5]`) because the mnemonic ends in `_f64`. The result is one dword: llvm-mc prints `v4`, and the VOP3 (`_e64`) spelling here already did. The binary64 source keeps its pair; binary64 results (`v_cvt_f64_i32`, `v_cvt_f64_f32`, `v_rcp_f64`) are unchanged. Refs #938. ## Verification Commit 2db1df38 on main e09b3302, macOS, Python 3.14. - `python -B tests/rdna2_tools_check.py TestRdna2Disasm.test_vop1_f64_source_conversions_have_one_register_result`: OK. With `tools/disasm_rdna2.py` from main: FAILED (failures=6). - `python -B tests/rdna2_tools_check.py`: Ran 142, OK (skipped=18). - `tests/docs_links_check.py`, `tests/bidi_controls_check.py`: OK. Not run: the Windows build/ctest, and LLVM 15 (not installed here). The golden words come from llvm-mc 23.1.6 (`-mcpu=gfx1013`); the new test compares against those strings and needs no LLVM. ## Evidence and follow-up Decoder text only; nothing lowers these conversions, so there is no draw or readback. Fixtures are hand-assembled words and llvm-mc output, no game data. `docs/experiments.md` has a new section. A follow-up names the remaining VOP1 rounding/frexp placeholders (0x17-0x1b, 0x3c-0x41), which build on this change. ## Checklist - [x] This pull request covers one reviewable behavior. - [x] I included the exact command and result for every check I ran. - [x] I considered a negative control or failure case for a new fixture. - [x] I updated README/docs when a capability or build requirement changed. - [x] I did not include game files, dumps, distribution links or secrets. AI use: Claude Code. Claude Sonnet 5.5 wrote the change, the tests and the llvm-mc sweep; Claude Opus 5.5 reviewed the diff and reran the suite. I reviewed it. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
The unextended VOP1 forms v_cvt_i32_f64, v_cvt_u32_f64 and v_cvt_f32_f64
printed their 32-bit destination as a VGPR pair because the name ends in
_f64. LLVM names one VGPR, as the VOP3 spelling here already did. Keep the
binary64 source as a pair and leave the binary64-result forms unchanged.

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01Hri58aiQKmMwqS6K8CHq2s
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 23:19:21 +00:00
github manually merged commit 2db1df388f into gh-pr/1593/base 2026-11-26 23:19:24 +00:00
This discussion has been locked. Commenting is limited to contributors.
No description provided.