Recompiler: use 0 base for GFX10.30 scratch ST mode SADDR=0x7F (#1361) #1606

Closed
github-bot wants to merge 1 commit from gh-pr/1606/head into gh-pr/1606/base
Owner

@⁠hajduzsolt on GitHub · 2026-11-24 18:11 UTC · original
hajduzsolt:recompiler/scratch-st-mode-saddr-7f → main · +44 −5 · 2 files · 1 commits · closed without merging

Splits SADDR == 0x7F (GFX10.30 ST immediate-offset mode, base

What is in it

  • See commit diff for subsystem details.

Tested

  • AMD Radeon RX 9070 XT, Windows 11 x64, cargo test --workspace -- --test-threads=2 passed.

Regression run

main:

xcl-smoke v1
commit: c160d86ef2efe3a07e4dfb473e4fa72eafb413c0
gpu: AMD Radeon RX 9070 XT
title: A newer retail game
seconds: 60
exit: 0x0
frames shown: 1594 (PresentX 1594)
presents per 2 s (last 3): 49 48 14
device removals: 0
crashes: 0
peak commit: 20195 MB

PR:

xcl-smoke v1
commit: feb00729af2ee0decd64482314b1a41f8593c5ec
gpu: AMD Radeon RX 9070 XT
title: A newer retail game
seconds: 60
exit: 0x0
frames shown: 1680 (PresentX 1680)
presents per 2 s (last 3): 60 60 60
device removals: 0
crashes: 0
peak commit: 14835 MB

Not tested

  • NVIDIA / Intel GPUs, wave32-only adapters, and gameplay beyond title menus.

AI use

  • Antigravity (Gemini 4 Hydrogen, High): automated PR verification runner.
**@⁠hajduzsolt** on GitHub · 2026-11-24 18:11 UTC · [original](https://github.com/xcl-dev/xcl/pull/1606) `hajduzsolt:recompiler/scratch-st-mode-saddr-7f` → `main` · +44 −5 · 2 files · 1 commits · closed without merging Splits SADDR == 0x7F (GFX10.30 ST immediate-offset mode, base **What is in it** - See commit diff for subsystem details. **Tested** - AMD Radeon RX 9070 XT, Windows 11 x64, `cargo test --workspace -- --test-threads=2` passed. **Regression run** main: ``` xcl-smoke v1 commit: c160d86ef2efe3a07e4dfb473e4fa72eafb413c0 gpu: AMD Radeon RX 9070 XT title: A newer retail game seconds: 60 exit: 0x0 frames shown: 1594 (PresentX 1594) presents per 2 s (last 3): 49 48 14 device removals: 0 crashes: 0 peak commit: 20195 MB ``` PR: ``` xcl-smoke v1 commit: feb00729af2ee0decd64482314b1a41f8593c5ec gpu: AMD Radeon RX 9070 XT title: A newer retail game seconds: 60 exit: 0x0 frames shown: 1680 (PresentX 1680) presents per 2 s (last 3): 60 60 60 device removals: 0 crashes: 0 peak commit: 14835 MB ``` **Not tested** - NVIDIA / Intel GPUs, wave32-only adapters, and gameplay beyond title menus. **AI use** - Antigravity (Gemini 4 Hydrogen, High): automated PR verification runner.
Em::scratch treated SADDR == 0x7F identically to SADDR == 0x7D (VADDR mode), adding v[ADDR] (v0) to fixed-offset GFX10.30 ST-mode spills instead of using 0 + offset.

Split 0x7F (base = 0u) from 0x7D (base = vreg(ADDR)) in Em::scratch, and update the existing VADDR-mode scratch test to encode SADDR=0x7D alongside new ST-mode tests.

Fixes #1361

Assisted-by: Antigravity (Gemini 4 Hydrogen, high)
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 04:59:05 +00:00
github-bot closed this pull request 2026-11-26 04:59:05 +00:00
Author
Owner

@⁠MiharaxD on GitHub · 2026-11-24 19:27 UTC · original

Test report on a 32-lane NVIDIA card, head feb0072 (on main c160d86), which covers the "NVIDIA / wave32-only adapters" line.

Tested

  • RTX 3070 Ti 8 GB (8017 MiB dedicated, driver 621.01), Intel i5-14400F, 32 GB RAM, Windows 11 Pro 10.0.26300, Rust 1.100.0, DXC 1.9.2602.17.
  • cargo build --workspace, then cargo test --workspace --no-fail-fast -- --test-threads=4 (debug) on feb0072: 860 passed, 0 failed, 42 ignored (lib tests 811 / 0 / 22). scratch_st_mode_uses_zero_base passes, and gpu_scratch_st_mode_ignores_vaddr ran on this GPU (no SKIPPED line) and passes.
  • SKIPPED: gpu_geometry_wave32_prefix_count_over_a_mask, gpu_wave32_program_in_wave64_hardware (no wave64), heap_window_out_of_memory_falls_back_to_the_switch_form (no heap windows).

Regression run
scripts/smoke.ps1 -Game <game folder> -Seconds 60 (release builds, start screen, no input). main is c160d86:

main:

xcl-smoke v1
commit: c160d86ef2efe3a07e4dfb473e4fa72eafb413c0
gpu: NVIDIA GeForce RTX 3070 Ti
title: game
seconds: 60
exit: 0x0
frames shown: 1586 (PresentX 1586)
presents per 2 s (last 3): 60 60 60
device removals: 0
crashes: 0
peak commit: 15055 MB

this PR's head:

xcl-smoke v1
commit: feb00729af2ee0decd64482314b1a41f8593c5ec
gpu: NVIDIA GeForce RTX 3070 Ti
title: game
seconds: 60
exit: 0x0
frames shown: 1598 (PresentX 1599)
presents per 2 s (last 3): 60 60 60
device removals: 0
crashes: 0
peak commit: 15368 MB

Not tested

  • Whether the retail title reaches a scratch ST-mode access with SADDR=0x7F in this run: the smoke is a regression check only.
  • AMD / Intel, gameplay past the start screen.

AI use: Claude Code (Claude Opus 5.5) built the PR, ran the tests and both smoke runs, read the logs and wrote this report; I checked it before posting.

**@⁠MiharaxD** on GitHub · 2026-11-24 19:27 UTC · [original](https://github.com/xcl-dev/xcl/pull/1606#issuecomment-7142119438) Test report on a 32-lane NVIDIA card, head `feb0072` (on `main` `c160d86`), which covers the "NVIDIA / wave32-only adapters" line. **Tested** - RTX 3070 Ti 8 GB (8017 MiB dedicated, driver 621.01), Intel i5-14400F, 32 GB RAM, Windows 11 Pro 10.0.26300, Rust 1.100.0, DXC 1.9.2602.17. - `cargo build --workspace`, then `cargo test --workspace --no-fail-fast -- --test-threads=4` (debug) on `feb0072`: **860 passed, 0 failed, 42 ignored** (lib tests 811 / 0 / 22). `scratch_st_mode_uses_zero_base` passes, and `gpu_scratch_st_mode_ignores_vaddr` ran on this GPU (no SKIPPED line) and passes. - SKIPPED: `gpu_geometry_wave32_prefix_count_over_a_mask`, `gpu_wave32_program_in_wave64_hardware` (no wave64), `heap_window_out_of_memory_falls_back_to_the_switch_form` (no heap windows). **Regression run** `scripts/smoke.ps1 -Game <game folder> -Seconds 60` (release builds, start screen, no input). `main` is `c160d86`: main: ``` xcl-smoke v1 commit: c160d86ef2efe3a07e4dfb473e4fa72eafb413c0 gpu: NVIDIA GeForce RTX 3070 Ti title: game seconds: 60 exit: 0x0 frames shown: 1586 (PresentX 1586) presents per 2 s (last 3): 60 60 60 device removals: 0 crashes: 0 peak commit: 15055 MB ``` this PR's head: ``` xcl-smoke v1 commit: feb00729af2ee0decd64482314b1a41f8593c5ec gpu: NVIDIA GeForce RTX 3070 Ti title: game seconds: 60 exit: 0x0 frames shown: 1598 (PresentX 1599) presents per 2 s (last 3): 60 60 60 device removals: 0 crashes: 0 peak commit: 15368 MB ``` **Not tested** - Whether the retail title reaches a scratch ST-mode access with `SADDR=0x7F` in this run: the smoke is a regression check only. - AMD / Intel, gameplay past the start screen. **AI use:** Claude Code (Claude Opus 5.5) built the PR, ran the tests and both smoke runs, read the logs and wrote this report; I checked it before posting.
Author
Owner

@⁠throny on GitHub · 2026-11-24 20:15 UTC · original

Two contributors checked independently and found that this PR makes the same change as #1365 #1377 (for #1361): #1607, group D30. They suggest keeping #1365. If you agree, closing this PR or joining the other one would save the maintainers a review. If the two differ in a way the checks missed, a note in #1607 helps.

This is a hint, not a request from the maintainers; nobody from the project has adopted #1607 so far.

AI use: Claude Code (Claude Opus 5.5), posted by a script from the #1607 table.

**@⁠throny** on GitHub · 2026-11-24 20:15 UTC · [original](https://github.com/xcl-dev/xcl/pull/1606#issuecomment-7143262040) <!-- xcl-1607-hint:D30 --> Two contributors checked independently and found that this PR makes the same change as #1365 #1377 (for #1361): #1607, group D30. They suggest keeping #1365. If you agree, closing this PR or joining the other one would save the maintainers a review. If the two differ in a way the checks missed, a note in #1607 helps. This is a hint, not a request from the maintainers; nobody from the project has adopted #1607 so far. AI use: Claude Code (Claude Opus 5.5), posted by a script from the #1607 table.
Author
Owner

@⁠DavidM1911 on GitHub · 2026-11-24 20:22 UTC · original

Verification on RTX 3060 Ti (Windows 11), branch merged with current main:

  • cargo test -p xcl --lib: all passed, 0 failed, ~22 ignored. (Intermittent 0xc0000005 abort under parallel scheduling; clean on single-threaded rerun — same flake seen on unmodified main.)

Thanks!

**@⁠DavidM1911** on GitHub · 2026-11-24 20:22 UTC · [original](https://github.com/xcl-dev/xcl/pull/1606#issuecomment-7143437298) Verification on RTX 3060 Ti (Windows 11), branch merged with current `main`: - `cargo test -p xcl --lib`: all passed, 0 failed, ~22 ignored. (Intermittent 0xc0000005 abort under parallel scheduling; clean on single-threaded rerun — same flake seen on unmodified `main`.) Thanks!
Author
Owner

@⁠ivall on GitHub · 2026-11-24 20:43 UTC · original · edited 2026-11-24 20:44 UTC

Closing this as a duplicate: #1365 makes the same change and was opened first (scratch with SADDR 0x7F addresses the offset alone). It stays open and is the one that will be reviewed and merged.

This says nothing about the quality of the code here. I compared the two diffs; the pair was also found by independent checks in #1607. If this PR covers a case #1365 does not, or #1365 is closed without being merged, say so and I'll reopen it. A test that is only here is welcome on #1365.

Thank you for the work.

AI use: Claude Code (Claude Opus 5.5) compared the diffs and wrote this comment; the decision is the maintainer's.

**@⁠ivall** on GitHub · 2026-11-24 20:43 UTC · [original](https://github.com/xcl-dev/xcl/pull/1606#issuecomment-7143963325) · edited 2026-11-24 20:44 UTC Closing this as a duplicate: #1365 makes the same change and was opened first (scratch with SADDR 0x7F addresses the offset alone). It stays open and is the one that will be reviewed and merged. This says nothing about the quality of the code here. I compared the two diffs; the pair was also found by independent checks in #1607. If this PR covers a case #1365 does not, or #1365 is closed without being merged, say so and I'll reopen it. A test that is only here is welcome on #1365. Thank you for the work. AI use: Claude Code (Claude Opus 5.5) compared the diffs and wrote this comment; the decision is the maintainer's.

Pull request closed

This discussion has been locked. Commenting is limited to contributors.
No description provided.