Shader: prevent WARP device loss on constant floating compares #152
No reviewers
Labels
No labels
accessibility
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
question
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/fxceless--victory-fork!152
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-152"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
@avt0m4t48 on GitHub · 2026-11-24 21:55 UTC · original
avt0m4t48:fix/warp-constant-float-compares→main· +73 −2 · 3 files · 2 commits · openRefs #136. Lower the constant DXIL predicates for
v_cmp{,x}_{f,tru}_f{16,32}through the existing lane-mask path. The emitted shaders then store the constant result instead of passingfcmp falseorfcmp trueto WARP.This is the floating-point portion of Marvisak/VIctory#1326, including the source-built regression by fuzeofficial. Upstream patch
The same Windows-2025 WARP job verified both versions. The patched test checked all eight opcodes across finite, zero, infinity, quiet-NaN and signaling-NaN inputs. Restoring the original lowering suspended the WARP device on dispatch. Windows verification
On Linux, all eight emitted DXIL modules passed
dxvand disassembled to the expected constant stores. The shader library suite passed 170 tests with two ignored. Windows-target Clippy with warnings denied andcargo xtask policyalso passed. This run used WARP and source-built inputs.AI-assisted using Codex.
@bawhen on GitHub · 2026-11-24 22:18 UTC · original
Checked on an RX 7700 (RDNA3, driver 32.0.32029.2010) and WARP.
cargo test -p victory-shader --locked --lib float_compares_that_are_always_false_or_true -- --nocapture08cb7edlower.rsandbitcode.rsfrommainwarp: dispatch failed: The GPU device instance has been suspended, the WARP device removal from #136So on this card it's a WARP/CI fix only: the RX 7700 handles
fcmp false/fcmp truecorrectly.Setup: AMD Radeon RX 7700 (RDNA3, 16 GB), driver 32.0.32029.2010, Ryzen 7 8700F, 16 GB RAM, Windows 11 (build 26300), Rust 1.98.1 from
rust-toolchain.toml. Baselinemainat4e17478:cargo test --workspace --lockedgives 496 passed, 0 failed, 7 ignored. The "without the fix" run checks outmain's version of the PR's non-test files and keeps the PR's new test. No game files used.AI use: Claude Code (Claude Opus 5.5) ran the tests and drafted this comment; posted at my request.
@avt0m4t48 on GitHub · 2026-11-25 01:32 UTC · original
Rechecked the current PR head
dbd9a894099845977fca87c8fdf66a4115897c98on Windows Server 2025 withVICTORY_WARP=1. The exactfloat_compares_that_are_always_false_or_trueregression passed for all eight opcode variants, with no skipped device. The verification commit adds only the workflow, and the job checks that before running the test.Windows WARP run
AI-assisted using Codex.
View command line instructions
Manual merge helper
Use this merge commit message when completing the merge manually.
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.