Repository navigation
Shaders: hardware probe for s_bitset0_b32 and s_bitset1_b32 - #1365
LouisRiverstone wants to merge 1 commit into
Conversation
catminou4
left a comment
There was a problem hiding this comment.
Hardware test only: s_bfm_b32 (SOP2 0x24) and s_bitset{0,1}_b32 (SOP1 0x1b/0x1d) using the low 5 bits of both operands, with width/offset edge cases (32, 33). The bfm reference (1 << (w & 31)) - 1 << (o & 31) asserts the 5-bit truncation — that's the behavior the title claims hardware shows; please confirm on the Windows run since width=32 wrapping to 0 is surprising. Local verification: macOS arm64, rustc 1.98.1, PR head merged into main ffe310e, cargo test -p <crate> --locked. Shader execution tests (valu_tests/host/diff_tests) are #[cfg(all(test, windows))], so macOS covers lowering/decode/unit tests only. 96 passed, 0 failed.
|
First GPU run of this PR's test that I could find, on an AMD GPU under Proton on Linux:
This is RADV, not AMD's Windows driver, so it adds to a Windows run rather than replacing it. Synthetic tests only, no game files. AI-assisted (Claude Code, Opus 5.5); every run was on this machine. |
|
Native Windows run on AMD RDNA2: RX 6750 XT (RDNA2, gfx1031), AMD driver 32.0.21045.29003, i5-13400F, Windows 11, Rust 1.98.1 MSVC. Head a4c994b on main ffe310e (clean merge).
Synthetic tests only, no game files. AI-assisted (Claude picked the PRs and wrote the batch script; I ran it on my machine). |
catminou4
left a comment
There was a problem hiding this comment.
Tested locally on macOS arm64 (rustc 1.98.1): PR head merged cleanly into current main (ffe310e), cargo test -p victory-shader --locked → 96 passed, 0 failed. Hardware/valu tests are #[cfg(all(test, windows))] and only run on Windows; macOS covers structure/lowering unit tests.
Hardware test for s_bfm_b32 and s_bitset0/1_b32: s_bfm_and_s_bitset_use_the_low_five_bits pins the 5-bit field behavior.
a4c994b to
8307a06
Compare
|
Automated triage for the maintainers. Merge candidate. The PR is now what the last triage asked for. The CI: passing ( Generated by Claude Code |
76742a0 to
34a3440
Compare
|
Automated triage for the maintainers, second look (a review against current Closing as covered by #2015, which adds the same two probes (destination seeded from another register, bit indices including 32 and above). The probes here are right and pass on an RX 6700 XT and on WARP. If this is mistaken, reply here with what was missed and it will be looked at again. Thank you for the contribution. |
Adds probes for
s_bitset0_b32/s_bitset1_b32(SOP1 0x1b / 0x1d) inscalar_probes: the destination is seeded with the first operand, then bitsrc[4:0]is cleared or set. Reduced after triage:s_bfm_b32is already covered on main.