fix(victory-shader): port #448 and #435 onto the Vice-Tay base #456

Open
github-bot wants to merge 2 commits from github-bot/gh-456 into main AGit
Owner

@⁠LooperSalty on GitHub · 2026-11-26 23:28 UTC · original
LooperSalty:fix/vicetay-shader-ports → main · +250 −16 · 4 files · 2 commits · open

Summary

Ports two shader-translator fixes by @⁠mauroalvare onto the Vice-Tay base (#454); their original PRs were written against the Neptune base and no longer apply.

  • #448 — v_cmp_f_* / v_cmp_tru_* on f32/f16 were emitted as fcmp false/true predicates, which suspends the device under WARP; they are now lowered as constant per-lane booleans, like the integer path. Test valu_tests::v_cmp_f_and_tru_lower_as_constant_booleans (f32 and f16, finite, infinite, qNaN, sNaN): without the fix, WARP reports the device suspended; with it, it passes.
  • #435 — DPP16/DPP8 follow RDNA 2's inactive-lane rules: a source lane off in EXEC (unless fi) or outside its row reads 0 with bound_ctrl, otherwise the destination keeps its value. Same rules as the Python reference interpreter (rdna2_exec_ext.py). Three tests in wave64_tests.rs (wave32, past a branch, wave64): without the fix they read 0xb / 0x0 instead of the console's 0xaaaa (the 0xb the author measured).

Differences from the original PRs: dpp() is changed in place in lower.rs (not moved to dpp.rs); the DPP tests run on a hardware GPU only (WARP does not take the program); one waveActiveBallot is emitted per DPP instruction without fi.

Test plan

  • cargo test --release -p victory-shader (321 passed, 4 ignored)
  • cargo build --release --workspace
  • New tests fail without the fixes and pass with them
  • CI

Source: #448, #435 (mauroalvare)

🤖 Generated with Claude Code

**@⁠LooperSalty** on GitHub · 2026-11-26 23:28 UTC · [original](https://github.com/LooperSalty/AnyXboxX/pull/456) `LooperSalty:fix/vicetay-shader-ports` → `main` · +250 −16 · 4 files · 2 commits · open ## Summary Ports two shader-translator fixes by @⁠mauroalvare onto the Vice-Tay base (#454); their original PRs were written against the Neptune base and no longer apply. - **#448** — `v_cmp_f_*` / `v_cmp_tru_*` on f32/f16 were emitted as `fcmp false/true` predicates, which suspends the device under WARP; they are now lowered as constant per-lane booleans, like the integer path. Test `valu_tests::v_cmp_f_and_tru_lower_as_constant_booleans` (f32 and f16, finite, infinite, qNaN, sNaN): without the fix, WARP reports the device suspended; with it, it passes. - **#435** — DPP16/DPP8 follow RDNA 2's inactive-lane rules: a source lane off in EXEC (unless `fi`) or outside its row reads 0 with `bound_ctrl`, otherwise the destination keeps its value. Same rules as the Python reference interpreter (`rdna2_exec_ext.py`). Three tests in `wave64_tests.rs` (wave32, past a branch, wave64): without the fix they read `0xb` / `0x0` instead of the console's `0xaaaa` (the `0xb` the author measured). Differences from the original PRs: `dpp()` is changed in place in `lower.rs` (not moved to `dpp.rs`); the DPP tests run on a hardware GPU only (WARP does not take the program); one `waveActiveBallot` is emitted per DPP instruction without `fi`. ## Test plan - [x] `cargo test --release -p victory-shader` (321 passed, 4 ignored) - [x] `cargo build --release --workspace` - [x] New tests fail without the fixes and pass with them - [ ] CI Source: #448, #435 (mauroalvare) 🤖 Generated with [Claude Code](https://claude.com/claude-code)
`v_cmp_f_*` and `v_cmp_tru_*` on f32/f16 were emitted as LLVM
`fcmp false` / `fcmp true`, which removes the D3D12 device under WARP
at dispatch. They are constant false/true whatever the operands, so
lower them as per-lane constant booleans like the integer
`v_cmp_{f,t}_*` path already does.

Ported from PR #448 by mauroalvare onto the Vice-Tay base. Adds a
WARP/GPU test covering finite, infinite and NaN inputs; it fails
(device removed) without the lowering change.

Source: https://github.com/LooperSalty/AnyXboxX/pull/448
Co-authored-by: mauroalvare <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
`Lower::dpp` ignored `fi` and the activity of the source lane in EXEC,
and passed out-of-row lane indices (row_shr on lane 0, row_shl on lane
15) straight to waveReadLaneAt. Unless `fi:1`, a source lane that is not
in EXEC must read 0 with `bound_ctrl:1` (DPP16) and leave the
destination unwritten otherwise (DPP16 and DPP8), as in
`emu/rdna2_exec_ext.py`. The author measured 0xb where the console has
0xaaaa.

The source lane's activity comes from a waveActiveBallot of the guard
(true when there is none, so lanes that took a real branch are left
out), or a quad read of the guard in quad-read paths. It is combined
with the row bound into `valid`, which zeroes the value (bound_ctrl) or
gates the write. Out-of-row sources are clamped to the lane before the
read.

Ported from PR #435 by mauroalvare onto the Vice-Tay base. Three tests
(guarded wave32, wave32 past a real branch, wave64 on 32-lane waves)
fail without the change and pass with it.

Source: https://github.com/LooperSalty/AnyXboxX/pull/435
Co-authored-by: mauroalvare <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-27 00:35:16 +00:00
Author
Owner

@⁠chatgpt-codex-connector[bot] on GitHub · 2026-11-26 23:28 UTC · original

Codex Review Summary: ❌ Failed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ❌ Failed 2026-11-26T23:28:37.019009Z
We couldn’t complete this review. Comment @codex review to try again.
1f42806 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@⁠codex review" or "@⁠codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

**@⁠chatgpt-codex-connector[bot]** on GitHub · 2026-11-26 23:28 UTC · [original](https://github.com/LooperSalty/AnyXboxX/pull/456#issuecomment-7205574007) <!-- codex-pull-request-review-summary --> <!-- codex-review-state:v1 {"code_review":{"commit_sha":"1f428068abe0a59fe465fc34ad3c603a99a4c079","has_any_findings":true,"has_unresolved_findings":true,"status":"failed"},"security_review":{"commit_sha":null,"has_any_findings":null,"has_unresolved_findings":null,"status":null}} --> <details> <summary><strong>Codex Review Summary</strong>: ❌ Failed</summary> This comment shows the latest Codex review activity on this pull request. | Review | Status | Commit | Review trigger | | --- | --- | --- | --- | | 📝 **Code Review** | ❌ **Failed** <relative-time datetime="2026-11-26T23:28:37.019009Z">2026-11-26T23:28:37.019009Z</relative-time><br/>We couldn’t complete this review. Comment `@codex review` to try again. | `1f42806` | PR opened | <details> <summary>ℹ️ About Codex in GitHub</summary> <br/> [Your team has set up Codex to review pull requests in this repo](https://chatgpt.com/codex/cloud/settings/general). Reviews are triggered when you - Open a pull request for review - Mark a draft as ready - Comment "@⁠codex review" or "@⁠codex security review". Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. </details> </details>
Author
Owner

@⁠chatgpt-codex-connector[bot] on GitHub · 2026-11-26 23:28 UTC · original

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.
To continue using code reviews, you can upgrade your account or add credits to your account and enable them for code reviews in your settings.

**@⁠chatgpt-codex-connector[bot]** on GitHub · 2026-11-26 23:28 UTC · [original](https://github.com/LooperSalty/AnyXboxX/pull/456#issuecomment-7205574586) You have reached your Codex usage limits for code reviews. You can see your limits in the [Codex usage dashboard](https://chatgpt.com/codex/cloud/settings/usage). To continue using code reviews, you can upgrade your account or add credits to your account and enable them for code reviews in your [settings](https://chatgpt.com/settings/code-review).
This pull request can be merged automatically.
This branch is out-of-date with the base branch
You are not authorized to merge this pull request.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin '+refs/pull/456/head:github-bot/gh-456'
git switch 'github-bot/gh-456'

Merge

Merge the changes and update on Forgejo.
git switch 'main'
git merge --no-ff 'github-bot/gh-456'
git switch 'github-bot/gh-456'
git rebase 'main'
git switch 'main'
git merge --ff-only 'github-bot/gh-456'
git switch 'github-bot/gh-456'
git rebase 'main'
git switch 'main'
git merge --no-ff 'github-bot/gh-456'
git switch 'main'
git merge --squash 'github-bot/gh-456'
git switch 'main'
git merge --ff-only 'github-bot/gh-456'
git switch 'main'
git merge 'github-bot/gh-456'
git push origin 'main'
This discussion has been locked. Commenting is limited to contributors.
No description provided.