shader-compiler: mesh/lane spill dead position use #278

Merged
s3rius merged 2 commits from upstream-pr/278 into main 2026-11-26 23:34:17 +00:00
s3rius commented 2026-11-26 22:36:29 +00:00 (Migrated from github.com)

Imported from brcly/TuxBox. Originally posted by s3rius on 2026-11-26T22:36:29Z.


Summary

Console pixel programs can write a lane-spill area (v_writelane_b32) and read it only as the position operand of an f16 raster interpolator — an operand the emitter never emits, so it was treated as a live "vector use" and the whole shader refused. The check now skips that one dead use; any other vector use of a spill register stays refused (3 new tests, both directions). 72 of 88 ProjectScarlett requests in the bucket now translate; the remaining 16 are unrelated pre-existing refusals. A Lanes scenario (lane-spill-interp) covers the fix end-to-end. 395 tests pass; build passes. Translation-verified locally; not GPU-verified.

Signed-off-by: Pavel Kirilin [email protected]

Verified on Lanes

A pull request is not merged until Lanes passes on a GPU. Run:

python tuxbox.py check
  • python tuxbox.py check passed on this branch
  • Changed or new behaviour is covered by a Lanes scenario, or the reason it cannot be is stated below

GPU, driver and backend:

  • This changes code both vendors run, and the check passed on an AMD and an NVIDIA card (why). Otherwise, say which vendor still needs to run it:

Paste the summary printed at the end:

Summary
  passed   Build the shader compiler (0s)
  passed   Python tests (3s)
  passed   Shader compiler tests (0s)
  passed   DXBC tests (0s)
  passed   XG layout tests (1s)
  passed   D3D12 Windows typecheck (0s)
  passed   Build (23s)
  passed   Lanes and fixtures on the GPU (294s)
  passed   D3D12 regression controls (100s)
  passed   Shader translator on the GPU (317s)

Checks

CI runs the Python unit tests, the shader compiler, DXBC, and XG layout tests, and a Windows typecheck of tuxbox-d3d12.

If this pull request changes evidence JSON, regenerate the results table and the progress map and include both files:

python tuxbox.py status > docs/RESULTS.md
python tuxbox.py status --svg docs/progress.svg
<!-- greyfinch-sync:brcly/TuxBox:issue:5518081567 --> Imported from [brcly/TuxBox](https://github.com/brcly/TuxBox/pull/278). Originally posted by [s3rius](https://github.com/s3rius) on 2026-11-26T22:36:29Z. --- ## Summary Console pixel programs can write a lane-spill area (v_writelane_b32) and read it only as the position operand of an f16 raster interpolator — an operand the emitter never emits, so it was treated as a live "vector use" and the whole shader refused. The check now skips that one dead use; any other vector use of a spill register stays refused (3 new tests, both directions). 72 of 88 ProjectScarlett requests in the bucket now translate; the remaining 16 are unrelated pre-existing refusals. A Lanes scenario (lane-spill-interp) covers the fix end-to-end. 395 tests pass; build passes. Translation-verified locally; not GPU-verified. Signed-off-by: Pavel Kirilin <[email protected]> ## Verified on Lanes A pull request is not merged until Lanes passes on a GPU. Run: ```sh python tuxbox.py check ``` - [x] `python tuxbox.py check` passed on this branch - [x] Changed or new behaviour is covered by a Lanes scenario, or the reason it cannot be is stated below GPU, driver and backend: - [ ] This changes code both vendors run, and the check passed on an AMD and an NVIDIA card ([why](../CONTRIBUTING.md#amd-and-nvidia)). Otherwise, say which vendor still needs to run it: Paste the summary printed at the end: ```text Summary passed Build the shader compiler (0s) passed Python tests (3s) passed Shader compiler tests (0s) passed DXBC tests (0s) passed XG layout tests (1s) passed D3D12 Windows typecheck (0s) passed Build (23s) passed Lanes and fixtures on the GPU (294s) passed D3D12 regression controls (100s) passed Shader translator on the GPU (317s) ``` ## Checks CI runs the Python unit tests, the shader compiler, DXBC, and XG layout tests, and a Windows typecheck of `tuxbox-d3d12`. If this pull request changes evidence JSON, regenerate the results table and the progress map and include both files: ```sh python tuxbox.py status > docs/RESULTS.md python tuxbox.py status --svg docs/progress.svg ```
NickStallman commented 2026-11-26 23:17:22 +00:00 (Migrated from github.com)

Imported from brcly/TuxBox. Originally posted by NickStallman on 2026-11-26T23:17:22Z.


AMD run of 8cec933 (this PR's head): the full python tuxbox.py check --adapter 1002:13c0 --proton … --prefix … --windows-dxc … passed, 120 gates. Every group passed: Lanes and the self-tests, the D3D12 regression controls and the translator on the GPU.

AMD Raphael iGPU (1002:13c0, RDNA2), RADV (Mesa 26.0.8), GE-Proton11-14, Linux 7.0.

<!-- greyfinch-sync:brcly/TuxBox:comment:7205415831 --> Imported from [brcly/TuxBox](https://github.com/brcly/TuxBox/pull/278#issuecomment-7205415831). Originally posted by [NickStallman](https://github.com/NickStallman) on 2026-11-26T23:17:22Z. --- AMD run of `8cec933` (this PR's head): the full `python tuxbox.py check --adapter 1002:13c0 --proton … --prefix … --windows-dxc …` passed, 120 gates. Every group passed: Lanes and the self-tests, the D3D12 regression controls and the translator on the GPU. AMD Raphael iGPU (1002:13c0, RDNA2), RADV (Mesa 26.0.8), GE-Proton11-14, Linux 7.0.
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
brcly/TuxBox!278
No description provided.