Recompiler: track four image resource SGPRs with R128 set #1990

Closed
MiguelMachado-dev wants to merge 1 commit from upstream-pr/2000 into main
MiguelMachado-dev commented 2026-11-25 00:35:17 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by MiguelMachado-dev on 2026-11-25T00:35:17Z.


Part of #1269. With R128=1, MIMG.SRSRC names four SGPRs. Counting eight made the per-lane backend refuse IMAGE_LOAD when the next SGPR held a lane mask.

What is in it

  • Share the descriptor width rule between rdna2::sgpr_uses and x64_masks::uses. With R128=0, use the table width, including the four-SGPR BVH entries.
  • Check both trackers and exercise the IMAGE_LOAD wave32 case through lower_dxil::compute_code. The shader is accepted with R128=1. With R128=0, s8 is part of the descriptor and the mask read is refused.

Tested

  • Commit 263a5e0, Windows 11 build 26300.9974, i7-14700KF, RTX 5080 (driver 621.24), Rust 1.97.1 and DXC 1.8.2502.11. Cargo tests ran in debug.
  • cargo test -p xcl --lib mimg_r128 -- --test-threads=4 reported 2 passed, 0 failed, 0 ignored and 0 SKIPPED. Both regressions failed before the fix.
  • cargo build --workspace passed. cargo test --workspace --no-fail-fast -- --test-threads=4 reported 993 passed, 4 failed and 45 ignored. The four fuzz_validate_and_gpu_* tests also failed on clean main at 8c4a46a with 0x8007000E in CreateComputePipelineState at the same seeds (70, 545, 1019 and 1507).
  • 24 SKIPPED reports. 19 had no wave64, 3 were f16 lowering refusals, 1 could not disable the driver cache, and 1 had no heap windows.

Regression run

scripts/smoke.ps1 ran release builds on the same title for 60 seconds with the default backend.

xcl-smoke v1
commit: 8c4a46a3c2d50498691cbda79cbbf4fadb45fbe8
gpu: NVIDIA GeForce RTX 5080
title: 3c290c16
seconds: 60
exit: 0x0
frames shown: 610 (PresentX 610)
presents per 2 s (last 3): 23 23 23
device removals: 0
crashes: 0
peak commit: 15454 MB
xcl-smoke v1
commit: 263a5e011d80270ebc8a3617badedc09d0a1e2bd
gpu: NVIDIA GeForce RTX 5080
title: 3c290c16
seconds: 60
exit: 0x0
frames shown: 765 (PresentX 765)
presents per 2 s (last 3): 36 37 33
device removals: 0
crashes: 0
peak commit: 15270 MB

Not tested

  • The per-lane backend on a retail shader pack, shader compile time, native wave64 and the optional XCL_SAMPLE_* fixtures.

AI use

  • Codex (GPT-6.2 Sol xhigh fast) wrote the fix and regression tests, ran the checks and drafted this report.
<!-- greyfinch-sync:ivall/xcl:issue:5482809188 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2000). Originally posted by [MiguelMachado-dev](https://github.com/MiguelMachado-dev) on 2026-11-25T00:35:17Z. --- Part of #1269. With `R128=1`, `MIMG.SRSRC` names four SGPRs. Counting eight made the per-lane backend refuse `IMAGE_LOAD` when the next SGPR held a lane mask. **What is in it** - Share the descriptor width rule between `rdna2::sgpr_uses` and `x64_masks::uses`. With `R128=0`, use the table width, including the four-SGPR BVH entries. - Check both trackers and exercise the `IMAGE_LOAD` wave32 case through `lower_dxil::compute_code`. The shader is accepted with `R128=1`. With `R128=0`, `s8` is part of the descriptor and the mask read is refused. **Tested** - Commit `263a5e0`, Windows 11 build 26300.9974, i7-14700KF, RTX 5080 (driver 621.24), Rust 1.97.1 and DXC 1.8.2502.11. Cargo tests ran in debug. - `cargo test -p xcl --lib mimg_r128 -- --test-threads=4` reported 2 passed, 0 failed, 0 ignored and 0 `SKIPPED`. Both regressions failed before the fix. - `cargo build --workspace` passed. `cargo test --workspace --no-fail-fast -- --test-threads=4` reported 993 passed, 4 failed and 45 ignored. The four `fuzz_validate_and_gpu_*` tests also failed on clean `main` at `8c4a46a` with `0x8007000E` in `CreateComputePipelineState` at the same seeds (70, 545, 1019 and 1507). - 24 `SKIPPED` reports. 19 had no wave64, 3 were f16 lowering refusals, 1 could not disable the driver cache, and 1 had no heap windows. **Regression run** `scripts/smoke.ps1` ran release builds on the same title for 60 seconds with the default backend. ``` xcl-smoke v1 commit: 8c4a46a3c2d50498691cbda79cbbf4fadb45fbe8 gpu: NVIDIA GeForce RTX 5080 title: 3c290c16 seconds: 60 exit: 0x0 frames shown: 610 (PresentX 610) presents per 2 s (last 3): 23 23 23 device removals: 0 crashes: 0 peak commit: 15454 MB ``` ``` xcl-smoke v1 commit: 263a5e011d80270ebc8a3617badedc09d0a1e2bd gpu: NVIDIA GeForce RTX 5080 title: 3c290c16 seconds: 60 exit: 0x0 frames shown: 765 (PresentX 765) presents per 2 s (last 3): 36 37 33 device removals: 0 crashes: 0 peak commit: 15270 MB ``` **Not tested** - The per-lane backend on a retail shader pack, shader compile time, native wave64 and the optional `XCL_SAMPLE_*` fixtures. **AI use** - Codex (GPT-6.2 Sol xhigh fast) wrote the fix and regression tests, ran the checks and drafted this report.
raylitebull commented 2026-11-25 02:08:50 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by raylitebull on 2026-11-25T01:34:42Z.


Diff audit passed (rdna2::sgpr_operand_dwords checking MIMG R128 == 1 -> 4 SGPRs shared across rdna2::sgpr_uses and x64_masks::uses, plus mimg_r128_leaves_the_mask_outside_the_descriptor). Build and test (Windows, no GPU) and PR description are both green on 263a5e0, and RTX 5080 passed.

Remaining before merge: one independent AMD GPU verification pass on 263a5e0.

<!-- greyfinch-sync:ivall/xcl:comment:7149708446 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2000#issuecomment-7149708446). Originally posted by [raylitebull](https://github.com/raylitebull) on 2026-11-25T01:34:42Z. --- Diff audit passed (`rdna2::sgpr_operand_dwords` checking `MIMG` `R128 == 1` -> 4 SGPRs shared across `rdna2::sgpr_uses` and `x64_masks::uses`, plus `mimg_r128_leaves_the_mask_outside_the_descriptor`). `Build and test (Windows, no GPU)` and `PR description` are both green on `263a5e0`, and RTX 5080 passed. **Remaining before merge:** one independent **AMD** GPU verification pass on `263a5e0`.
JJAutoCompare commented 2026-11-25 04:10:25 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by JJAutoCompare on 2026-11-25T03:21:15Z.


Tested

PR #2000 at 263a5e011d80270ebc8a3617badedc09d0a1e2bd, in a clean detached checkout. STOR-WINLAB ran Windows 11 Enterprise Evaluation 26200.9974 on a Ryzen 7 3800X, with an Intel Arc A770 (driver 32.0.101.9175) installed. The CPU-only run used Rust and Cargo 1.100.0 (x86_64-pc-windows-msvc), the unoptimized test profile, and DXC/DXIL 1.9.2609.5 for DXIL validation.

cargo test -p xcl --locked --lib mimg_r128 -- --nocapture --test-threads=1 selected exactly two tests. Both passed, with 0 failed, 0 ignored, 0 explicit skips, and 971 filtered out. The harness reported 0.02 seconds.

  • gpu::recomp::x64_masks::tests::mimg_r128_descriptor_reads checked both SGPR trackers. For IMAGE_LOAD, they tracked reads of s4–s7 with R128=1 and s4–s11 with R128=0. Both BVH opcodes retained four SGPR reads with R128=0. All four cases had zero SGPR writes.
  • gpu::recomp::lower_dxil::tests::mimg_r128_leaves_the_mask_outside_the_descriptor checked per-lane wave32 IMAGE_LOAD translation through compute_code. With R128=1, the fixture kept the lane mask in s8 outside the descriptor and produced DXIL that passed validation. With R128=0, it returned the expected refusal for reading that mask as a number.

Not tested

GPU execution on any adapter, fuzzing, retail titles, and the full workspace suite.

AI use

T3 Code / Codex gpt-6.2-sol verified the checkout, ran the two checked-in fixtures, and wrote this report.

<!-- greyfinch-sync:ivall/xcl:comment:7151835015 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2000#issuecomment-7151835015). Originally posted by [JJAutoCompare](https://github.com/JJAutoCompare) on 2026-11-25T03:21:15Z. --- **Tested** [PR #2000](https://github.com/xcl-dev/xcl/pull/2000) at `263a5e011d80270ebc8a3617badedc09d0a1e2bd`, in a clean detached checkout. STOR-WINLAB ran Windows 11 Enterprise Evaluation 26200.9974 on a Ryzen 7 3800X, with an Intel Arc A770 (driver 32.0.101.9175) installed. The CPU-only run used Rust and Cargo 1.100.0 (x86_64-pc-windows-msvc), the unoptimized test profile, and DXC/DXIL 1.9.2609.5 for DXIL validation. `cargo test -p xcl --locked --lib mimg_r128 -- --nocapture --test-threads=1` selected exactly two tests. Both passed, with 0 failed, 0 ignored, 0 explicit skips, and 971 filtered out. The harness reported 0.02 seconds. - `gpu::recomp::x64_masks::tests::mimg_r128_descriptor_reads` checked both SGPR trackers. For `IMAGE_LOAD`, they tracked reads of `s4–s7` with `R128=1` and `s4–s11` with `R128=0`. Both BVH opcodes retained four SGPR reads with `R128=0`. All four cases had zero SGPR writes. - `gpu::recomp::lower_dxil::tests::mimg_r128_leaves_the_mask_outside_the_descriptor` checked per-lane wave32 `IMAGE_LOAD` translation through `compute_code`. With `R128=1`, the fixture kept the lane mask in `s8` outside the descriptor and produced DXIL that passed validation. With `R128=0`, it returned the expected refusal for reading that mask as a number. **Not tested** GPU execution on any adapter, fuzzing, retail titles, and the full workspace suite. **AI use** T3 Code / Codex gpt-6.2-sol verified the checkout, ran the two checked-in fixtures, and wrote this report.
DavidM1911 commented 2026-11-25 04:10:39 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by DavidM1911 on 2026-11-25T03:43:38Z.


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

  • cargo test -p xcl --lib: 3 real failures, deterministic (also fail --test-threads=1, 1038/3):
gpu::recomp::lower_dxil::tests::mimg_r128_leaves_the_mask_outside_the_descriptor
  -> Err("unsupported IMAGE_LOAD (s8: a mask read as a number)")
gpu::recomp::x64_masks::tests::mimg_r128_descriptor_reads
  assertion failed: IMAGE_LOAD R128=1 — left [4,5,6,7,8,9,10,11], right [4,5,6,7]
gpu::recomp::x64_masks::tests::use_plan_matches_fallback_across_all_rdna2_instructions
  assertion failed: IMAGE_LOAD (ENC_MIMG, Plain) — left (1044480, 0), right (61440, 0)

Looks like the R128/mask handling for IMAGE_LOAD regressed (the mask is being folded into the descriptor operand instead of staying outside it). Needs a fix before merge.

— Devin

<!-- greyfinch-sync:ivall/xcl:comment:7152185402 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2000#issuecomment-7152185402). Originally posted by [DavidM1911](https://github.com/DavidM1911) on 2026-11-25T03:43:38Z. --- Verification on RTX 3060 Ti (Windows 11), branch merged with current `main`: - `cargo test -p xcl --lib`: **3 real failures**, deterministic (also fail `--test-threads=1`, 1038/3): ``` gpu::recomp::lower_dxil::tests::mimg_r128_leaves_the_mask_outside_the_descriptor -> Err("unsupported IMAGE_LOAD (s8: a mask read as a number)") gpu::recomp::x64_masks::tests::mimg_r128_descriptor_reads assertion failed: IMAGE_LOAD R128=1 — left [4,5,6,7,8,9,10,11], right [4,5,6,7] gpu::recomp::x64_masks::tests::use_plan_matches_fallback_across_all_rdna2_instructions assertion failed: IMAGE_LOAD (ENC_MIMG, Plain) — left (1044480, 0), right (61440, 0) ``` Looks like the R128/mask handling for IMAGE_LOAD regressed (the mask is being folded into the descriptor operand instead of staying outside it). Needs a fix before merge. — Devin
thehollowedone commented 2026-11-25 14:10:13 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by thehollowedone on 2026-11-25T14:02:10Z.


Independent integration recheck of 263a5e0 on main 06c9f55. Windows 11 build 26300, Ryzen 7 9800X3D, RTX 3080 Ti / 621.35, Rust 1.99.1 MSVC, DXC 1.8.2502.11.

The clean local merge reproduced all three failures from DavidM1911’s run. The two register-use trackers disagreed for IMAGE_LOAD R128=1, and the per-lane translator rejected the read of s8.

For a local control, I made the precomputed operand plan use the same R128 descriptor-width rule as the fallback tracker. With that change, the same three tests passed, including the stock comparison across all RDNA2 instructions. The offline workspace build passed, and the patched workspace suite finished with 1,267 passed, 0 failed, 46 ignored, including 26 runtime skips in the pass count.

Focused command: cargo test --offline --locked -p xcl --lib -j 6 -- --test-threads=1 --nocapture mimg_r128 use_plan_matches_fallback_across_all_rdna2_instructions. Workspace command: cargo test --offline --locked --workspace --no-fail-fast -j 6 -- --test-threads=4 --nocapture.

Synthetic tests only. The patched result is local. AMD GPU verification remains open.

AI-assisted. Codex (GPT-6, exact variant unavailable) ran the reproduction, wrote the local control, and drafted this report.

<!-- greyfinch-sync:ivall/xcl:comment:7164658292 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2000#issuecomment-7164658292). Originally posted by [thehollowedone](https://github.com/thehollowedone) on 2026-11-25T14:02:10Z. --- Independent integration recheck of [263a5e0](https://github.com/xcl-dev/xcl/commit/263a5e011d80270ebc8a3617badedc09d0a1e2bd) on [main 06c9f55](https://github.com/xcl-dev/xcl/commit/06c9f5505f63f10c5ec49ef932d75b2c28177324). Windows 11 build 26300, Ryzen 7 9800X3D, RTX 3080 Ti / 621.35, Rust 1.99.1 MSVC, DXC 1.8.2502.11. The clean local merge reproduced all three failures from [DavidM1911’s run](https://github.com/xcl-dev/xcl/pull/2000#issuecomment-7152185402). The two register-use trackers disagreed for `IMAGE_LOAD R128=1`, and the per-lane translator rejected the read of `s8`. For a local control, I made the precomputed operand plan use the same R128 descriptor-width rule as the fallback tracker. With that change, the same three tests passed, including the stock comparison across all RDNA2 instructions. The offline workspace build passed, and the patched workspace suite finished with **1,267 passed, 0 failed, 46 ignored**, including 26 runtime skips in the pass count. Focused command: `cargo test --offline --locked -p xcl --lib -j 6 -- --test-threads=1 --nocapture mimg_r128 use_plan_matches_fallback_across_all_rdna2_instructions`. Workspace command: `cargo test --offline --locked --workspace --no-fail-fast -j 6 -- --test-threads=4 --nocapture`. Synthetic tests only. The patched result is local. AMD GPU verification remains open. AI-assisted. Codex (GPT-6, exact variant unavailable) ran the reproduction, wrote the local control, and drafted this report.
ClosetPie107 commented 2026-11-26 07:03:40 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by ClosetPie107 on 2026-11-26T06:49:16Z.


Tested head 263a5e01 merged onto current main (b49be183) on AMD RDNA4 / Linux (Proton Experimental): 3 unit tests fail after merging with main.

Hardware & environment

  • AMD Radeon RX 9070 16 GB (RDNA4, RADV GFX1201, Mesa 26.3.1, native wave64), Ryzen 5 9600X, 30 GiB RAM, CachyOS Linux
  • Proton Experimental (experimental-11.0-20261112), DXC 1.9.2609.5, Rust x86_64-pc-windows-gnu (debug)

Targeted unit tests (main b49be183 + #2000 263a5e01, --test-threads=1):

  • xcl.exe gpu::rdna2:: -- --test-threads=1: 18 passed, 0 failed, 0 ignored (0 skipped).
  • xcl.exe gpu::recomp::x64_masks:: -- --test-threads=1: 18 passed, 2 failed, 1 ignored (mimg_r128_descriptor_reads and use_plan_matches_fallback_across_all_rdna2_instructions).
  • xcl.exe r128 -- --test-threads=1: 0 passed, 2 failed, 0 ignored:
    • gpu::recomp::x64_masks::tests::mimg_r128_descriptor_reads (x64_masks.rs:794): assertion left == right failed: IMAGE_LOAD R128=1: left: [4, 5, 6, 7, 8, 9, 10, 11], right: [4, 5, 6, 7]
    • gpu::recomp::lower_dxil::tests::mimg_r128_leaves_the_mask_outside_the_descriptor (lower_dxil.rs:482): called Result::unwrap() on an Err value: "unsupported IMAGE_LOAD (s8: a mask read as a number)"

Looks like #2000 needs a rebase onto current main (it auto-merged without git conflicts, but the R128 descriptor width isn't taking effect against main's current rdna2.rs / x64_masks.rs).

Not tested

  • Native Windows, 263a5e01 on its original base without merging main, or retail title run (excluded due to the unit test failures).

AI use

  • T3 Code / Antigravity (Gemini 4 Neon) merged #2000 onto main, ran the Proton unit tests on this machine, and drafted this report.
<!-- greyfinch-sync:ivall/xcl:comment:7184815745 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2000#issuecomment-7184815745). Originally posted by [ClosetPie107](https://github.com/ClosetPie107) on 2026-11-26T06:49:16Z. --- Tested head `263a5e01` merged onto current `main` (`b49be183`) on AMD RDNA4 / Linux (Proton Experimental): **3 unit tests fail after merging with `main`**. **Hardware & environment** - AMD Radeon RX 9070 16 GB (RDNA4, RADV GFX1201, Mesa 26.3.1, native wave64), Ryzen 5 9600X, 30 GiB RAM, CachyOS Linux - Proton Experimental (`experimental-11.0-20261112`), DXC `1.9.2609.5`, Rust `x86_64-pc-windows-gnu` (debug) **Targeted unit tests** (`main` `b49be183` + #2000 `263a5e01`, `--test-threads=1`): - `xcl.exe gpu::rdna2:: -- --test-threads=1`: **18 passed, 0 failed, 0 ignored** (0 skipped). - `xcl.exe gpu::recomp::x64_masks:: -- --test-threads=1`: **18 passed, 2 failed, 1 ignored** (`mimg_r128_descriptor_reads` and `use_plan_matches_fallback_across_all_rdna2_instructions`). - `xcl.exe r128 -- --test-threads=1`: **0 passed, 2 failed, 0 ignored**: - `gpu::recomp::x64_masks::tests::mimg_r128_descriptor_reads` (`x64_masks.rs:794`): `assertion left == right failed: IMAGE_LOAD R128=1: left: [4, 5, 6, 7, 8, 9, 10, 11], right: [4, 5, 6, 7]` - `gpu::recomp::lower_dxil::tests::mimg_r128_leaves_the_mask_outside_the_descriptor` (`lower_dxil.rs:482`): `called Result::unwrap() on an Err value: "unsupported IMAGE_LOAD (s8: a mask read as a number)"` Looks like #2000 needs a rebase onto current `main` (it auto-merged without git conflicts, but the `R128` descriptor width isn't taking effect against `main`'s current `rdna2.rs` / `x64_masks.rs`). **Not tested** - Native Windows, `263a5e01` on its original base without merging `main`, or retail title run (excluded due to the unit test failures). **AI use** - T3 Code / Antigravity (Gemini 4 Neon) merged #2000 onto `main`, ran the Proton unit tests on this machine, and drafted this report.
throny commented 2026-11-28 02:30:48 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by throny on 2026-11-28T02:30:48Z.


merge-check claim
head: 263a5e011d

<!-- greyfinch-sync:ivall/xcl:comment:7232411851 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2000#issuecomment-7232411851). Originally posted by [throny](https://github.com/throny) on 2026-11-28T02:30:48Z. --- merge-check claim head: 263a5e011d80270ebc8a3617badedc09d0a1e2bd
throny commented 2026-11-28 02:45:27 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by throny on 2026-11-28T02:45:27Z.


merge-check
base: 753e8b1a
head: 263a5e011d
merge: clean
build: cargo build --workspace -> ok
tests: cargo test --workspace --no-fail-fast -- --test-threads=4 -> 1511 passed, 3 failed, 47 ignored; failing: gpu::recomp::x64_masks::tests::mimg_r128_descriptor_reads, gpu::recomp::x64_masks::tests::use_plan_matches_fallback_across_all_rdna2_instructions, gpu::recomp::lower_dxil::tests::mimg_r128_leaves_the_mask_outside_the_descriptor. All three pass on the base (the first and third are the PR's own tests) (26 SKIPPED lines); base alone: 1512 passed, 0 failed, 47 ignored
review: blocking, and the cause of the three failures: on current main x64_masks::uses goes through a precomputed use-plan table (uses_with_table / UsePlanTable::build), which sizes each operand from its declared size and never sees the R128 bit. The PR's change lands in the fallback function only, so after the merge the plan still returns eight registers where the fallback returns four, and the two disagree on the default path. The same three failures are reported by three testers in the thread. The R128 rule itself is right (the emitter reads only descriptor words 0, 1 and 3).
performance: no runtime cost; it changes translator sources (every tester re-translates once), and the HLSL changes for programs with R128 images.
verdict: not yet: the use-plan table needs the same R128 rule; I will rerun on the new head.
hardware / tool and model: RTX 4080 16 GB (621.40), i9-12900K, Windows 11 26300, Rust 1.100.0, debug. Claude Code; merge, build and suite run by Claude Fable 5.2, diff review by Claude Opus 5.5 (every hunk read; nothing run on the GPU beyond the suite).

<!-- greyfinch-sync:ivall/xcl:comment:7232573906 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2000#issuecomment-7232573906). Originally posted by [throny](https://github.com/throny) on 2026-11-28T02:45:27Z. --- merge-check base: 753e8b1a head: 263a5e011d80270ebc8a3617badedc09d0a1e2bd merge: clean build: cargo build --workspace -> ok tests: cargo test --workspace --no-fail-fast -- --test-threads=4 -> 1511 passed, 3 failed, 47 ignored; failing: gpu::recomp::x64_masks::tests::mimg_r128_descriptor_reads, gpu::recomp::x64_masks::tests::use_plan_matches_fallback_across_all_rdna2_instructions, gpu::recomp::lower_dxil::tests::mimg_r128_leaves_the_mask_outside_the_descriptor. All three pass on the base (the first and third are the PR's own tests) (26 SKIPPED lines); base alone: 1512 passed, 0 failed, 47 ignored review: blocking, and the cause of the three failures: on current main x64_masks::uses goes through a precomputed use-plan table (uses_with_table / UsePlanTable::build), which sizes each operand from its declared size and never sees the R128 bit. The PR's change lands in the fallback function only, so after the merge the plan still returns eight registers where the fallback returns four, and the two disagree on the default path. The same three failures are reported by three testers in the thread. The R128 rule itself is right (the emitter reads only descriptor words 0, 1 and 3). performance: no runtime cost; it changes translator sources (every tester re-translates once), and the HLSL changes for programs with R128 images. verdict: not yet: the use-plan table needs the same R128 rule; I will rerun on the new head. hardware / tool and model: RTX 4080 16 GB (621.40), i9-12900K, Windows 11 26300, Rust 1.100.0, debug. Claude Code; merge, build and suite run by Claude Fable 5.2, diff review by Claude Opus 5.5 (every hunk read; nothing run on the GPU beyond the suite).
KOLESNiii commented 2026-11-28 11:38:20 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by KOLESNiii on 2026-11-28T11:38:20Z.


merge-check claim
head: 263a5e011d

<!-- greyfinch-sync:ivall/xcl:comment:7238683782 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2000#issuecomment-7238683782). Originally posted by [KOLESNiii](https://github.com/KOLESNiii) on 2026-11-28T11:38:20Z. --- merge-check claim head: 263a5e011d80270ebc8a3617badedc09d0a1e2bd
KOLESNiii commented 2026-11-28 12:04:50 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by KOLESNiii on 2026-11-28T12:04:50Z.


merge-check
base: e429936c10
head: 263a5e011d
merge: clean
build: cargo build --workspace -> ok
tests: cargo test --workspace --no-fail-fast -- --test-threads=4 -> 2125 passed, 12 failed, 48 ignored, 25 SKIPPED: 21 no wave64, 3 per-lane f16/f32 forms refused (#1426 semantics), 1 no heap windows; failing because of this PR: gpu::recomp::lower_dxil::tests::mimg_r128_leaves_the_mask_outside_the_descriptor, gpu::recomp::x64_masks::tests::mimg_r128_descriptor_reads, gpu::recomp::x64_masks::tests::use_plan_matches_fallback_across_all_rdna2_instructions: each also failed when rerun alone on this merge and none fails on the base e429936c; see review; failing: gpu::dxil::module::split::tests::dispatch_chain_oversized_loop_matches_whole, gpu::dxil::module::split::tests::dispatch_chain_wave32_live_loops, gpu::dxil::module::split::tests::dispatch_chain_wave64_live_loops_and_exchange, gpu::recomp::heap_window_tests::gpu_heap_flat_reads_match_guarded_and_root_output, gpu::recomp::tests::gpu_compute_mode_dispatch_abi, gpu::recomp::tests::gpu_float_cas_uses_ieee_equality, test_title_draws_with_a_root_signature_under_the_debug_layer, test_title_runs_and_game_folder_is_untouched, test_title_runs_under_the_debug_layer_with_dred: these 9 fail on the base too (the base e429936c's suite, run alone on this PC with the same command: 2126 passed, 9 failed, 48 ignored, 25 SKIPPED, these same 9 failing), and each also failed when rerun alone on this merge (the two debug-layer e2e tests stop on the D3D12 debug layer rejecting a pixel shader as corrupt or unsigned, and test_title_runs_and_game_folder_is_untouched on the test title's console command list memory-methods check, "post-Wait32/64 write failed"); not caused by this PR. The suite ran on this PC at the same time as 3 other PRs' suites, in one queued job.
review: [major] crates/xcl/src/gpu/rdna2.rs:457-464 (sgpr_operand_dwords) and its callers: on this merge the R128 case does not take effect: rdna2::sgpr_uses still gives IMAGE_LOAD with R128 = 1 eight descriptor SGPRs, so the program the PR means to accept is still refused ("s8: a mask read as a number"), and x64_masks' use plan and fallback tracker now disagree on IMAGE_LOAD -> the PR's two new tests and the existing use_plan_matches_fallback_across_all_rdna2_instructions fail. Evidence: the solo reruns (x64_masks.rs:794 left [4..11] right [4..7]; x64_masks.rs:1156 (1044480, 0) vs (61440, 0); lower_dxil.rs:494 unwrap on Err). (confirmed by the suite and solo reruns; cause not traced further.) Rest of the diff read (README line; the BVH ops keep the table's 4).
performance: reasoned, not measured: one field read per MIMG SRSRC operand during translation.
verdict: not yet: 3 tests fail on the merge because of this PR (its 2 new tests and use_plan_matches_fallback_across_all_rdna2_instructions); make the R128 count take effect in both trackers
hardware / tool and model: Windows 11 build 26300.9974, NVIDIA GeForce RTX 2070 SUPER 8 GB (driver 621.40, wave32 only), AMD Ryzen 5 3600XT; rustc 1.100.1 (20ddd0171 2026-11-25) x86_64-pc-windows-msvc, debug test profile; trial merge 63ed9e493f5555a961ab601ec7daf15a5c00bc26 (local, not pushed). Claude Code: Claude Opus 5.5 (coordination, full-diff review, draft).
correction (2026-11-28): the base counts above were first given as 2128 passed: that base run reused this PC's merge test binary (one cargo target dir for both sides). The base was rerun with its own target dir; the same 9 tests fail on it, so the classification and the verdict stand.

<!-- greyfinch-sync:ivall/xcl:comment:7238979095 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2000#issuecomment-7238979095). Originally posted by [KOLESNiii](https://github.com/KOLESNiii) on 2026-11-28T12:04:50Z. --- merge-check base: e429936c10a5b8aa09470ff99dfc8c8d3d8c56fd head: 263a5e011d80270ebc8a3617badedc09d0a1e2bd merge: clean build: cargo build --workspace -> ok tests: cargo test --workspace --no-fail-fast -- --test-threads=4 -> 2125 passed, 12 failed, 48 ignored, 25 SKIPPED: 21 no wave64, 3 per-lane f16/f32 forms refused (#1426 semantics), 1 no heap windows; failing because of this PR: gpu::recomp::lower_dxil::tests::mimg_r128_leaves_the_mask_outside_the_descriptor, gpu::recomp::x64_masks::tests::mimg_r128_descriptor_reads, gpu::recomp::x64_masks::tests::use_plan_matches_fallback_across_all_rdna2_instructions: each also failed when rerun alone on this merge and none fails on the base e429936c; see review; failing: gpu::dxil::module::split::tests::dispatch_chain_oversized_loop_matches_whole, gpu::dxil::module::split::tests::dispatch_chain_wave32_live_loops, gpu::dxil::module::split::tests::dispatch_chain_wave64_live_loops_and_exchange, gpu::recomp::heap_window_tests::gpu_heap_flat_reads_match_guarded_and_root_output, gpu::recomp::tests::gpu_compute_mode_dispatch_abi, gpu::recomp::tests::gpu_float_cas_uses_ieee_equality, test_title_draws_with_a_root_signature_under_the_debug_layer, test_title_runs_and_game_folder_is_untouched, test_title_runs_under_the_debug_layer_with_dred: these 9 fail on the base too (the base e429936c's suite, run alone on this PC with the same command: 2126 passed, 9 failed, 48 ignored, 25 SKIPPED, these same 9 failing), and each also failed when rerun alone on this merge (the two debug-layer e2e tests stop on the D3D12 debug layer rejecting a pixel shader as corrupt or unsigned, and test_title_runs_and_game_folder_is_untouched on the test title's console command list memory-methods check, "post-Wait32/64 write failed"); not caused by this PR. The suite ran on this PC at the same time as 3 other PRs' suites, in one queued job. review: [major] crates/xcl/src/gpu/rdna2.rs:457-464 (sgpr_operand_dwords) and its callers: on this merge the R128 case does not take effect: rdna2::sgpr_uses still gives IMAGE_LOAD with R128 = 1 eight descriptor SGPRs, so the program the PR means to accept is still refused ("s8: a mask read as a number"), and x64_masks' use plan and fallback tracker now disagree on IMAGE_LOAD -> the PR's two new tests and the existing use_plan_matches_fallback_across_all_rdna2_instructions fail. Evidence: the solo reruns (x64_masks.rs:794 left [4..11] right [4..7]; x64_masks.rs:1156 (1044480, 0) vs (61440, 0); lower_dxil.rs:494 unwrap on Err). (confirmed by the suite and solo reruns; cause not traced further.) Rest of the diff read (README line; the BVH ops keep the table's 4). performance: reasoned, not measured: one field read per MIMG SRSRC operand during translation. verdict: not yet: 3 tests fail on the merge because of this PR (its 2 new tests and use_plan_matches_fallback_across_all_rdna2_instructions); make the R128 count take effect in both trackers hardware / tool and model: Windows 11 build 26300.9974, NVIDIA GeForce RTX 2070 SUPER 8 GB (driver 621.40, wave32 only), AMD Ryzen 5 3600XT; rustc 1.100.1 (20ddd0171 2026-11-25) x86_64-pc-windows-msvc, debug test profile; trial merge 63ed9e493f5555a961ab601ec7daf15a5c00bc26 (local, not pushed). Claude Code: Claude Opus 5.5 (coordination, full-diff review, draft). correction (2026-11-28): the base counts above were first given as 2128 passed: that base run reused this PC's merge test binary (one cargo target dir for both sides). The base was rerun with its own target dir; the same 9 tests fail on it, so the classification and the verdict stand.
Foniass commented 2026-12-01 07:11:22 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by Foniass on 2026-12-01T07:11:22Z.


Triage (#1607) – head 263a5e0

No open or merged PR makes the same change; main still counts MIMG SRSRC by the table width in rdna2::sgpr_uses and x64_masks::uses.
No problems found in the diff (R128=1 means a 128-bit T#, four SGPRs). The README line describes an internal detail in the user-facing feature table; it could be left out.
Recommendation: keep open.

AI review: Claude Code (Claude Opus 5.5), diffs read only, not built or run; not checked by a human.

<!-- greyfinch-sync:ivall/xcl:comment:7303749544 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2000#issuecomment-7303749544). Originally posted by [Foniass](https://github.com/Foniass) on 2026-12-01T07:11:22Z. --- **Triage (#1607)** – head 263a5e0 No open or merged PR makes the same change; main still counts MIMG SRSRC by the table width in `rdna2::sgpr_uses` and `x64_masks::uses`. No problems found in the diff (R128=1 means a 128-bit T#, four SGPRs). The README line describes an internal detail in the user-facing feature table; it could be left out. Recommendation: keep open. AI review: Claude Code (Claude Opus 5.5), diffs read only, not built or run; not checked by a human.

Pull request closed

Sign in to join this conversation.
No reviewers
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
xcl-dev/xcl!1990
No description provided.