Tests: check v_alignbit_b32, v_alignbyte_b32 and v_perm_b32 on the GPU #1057
No reviewers
Labels
No labels
accessibility
bug
documentation
duplicate
enhancement
goal:world-load
good first issue
help wanted
invalid
keep-open
off-goal
question
stale
test-only
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/xcl-dev--xcl!1057
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-1057"
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?
@KarolKurzyna on GitHub · 2026-11-24 11:03 UTC · original
KarolKurzyna:tests/gpu-alignbit-alignbyte-perm-b32→main· +104 −0 · 1 files · 1 commits · openv_alignbit_b32,v_alignbyte_b32andv_perm_b32had no unit or GPU test coverage inrecomp/tests.rs. Their HLSL helpers (alignbitandperm_b32inemit.rs) handle shift-by-zero guards, shift/byte-offset masking, and all four sign-extension and constant selector classes by hand. This adds a per-instruction GPU test checking all three against the RDNA2 ISA pseudocode.Test-only: nothing outside
crates/xcl/src/gpu/recomp/tests.rschanges. Searched open PRs and issues forv_perm_b32,v_alignbit, andv_alignbyteand found no existing PR or issue covering them.What is in it
crates/xcl/src/gpu/recomp/tests.rs(gpu_alignbit_alignbyte_and_perm_b32):V_ALIGNBIT_B32,V_ALIGNBYTE_B32, andV_PERM_B32with VGPR, inline-constant (0,3), and SGPRSRC2operands, checks thattranslatecompletes cleanly, and runs viagpu_waves()(wave32, pluswave64where supported).shift = 0and masked counts (32..64,0xFC..0xFF,0xFFFF_FFE0..0xFFFF_FFFF), byte offsets0..3and masked offsets (4,36,64), distinct-byte shuffles acrosssrc0/src1, one-hot and one-cold sign bits isolatingv_perm_b32selectors8..11(s1[15],s1[31],s0[15],s0[31]), near-miss bits (14/30), selector12(0x00) on all-ones, and selectors13/20/28/255(0xFF) to catch& 15masking.Tested
621.24/32.0.16.2124, wave32, SM 6.6), Intel Core i5-14600K, Windows 11 26H2 (build 26300.9974),rustc 1.100.0(stable-x86_64-pc-windows-msvc), DXC1.9.2602.17(21d28f72), debug buildcargo test -p xcl --lib gpu_alignbit_alignbyte_and_perm_b32 -- --nocapture: 1 passed, 0 failed, 0 ignored (0.24 s)emit.rs(reverted before commit): droppingalignbit'ss == 0uguard failed on lane 0 (shift = 0), and swappingperm_b32selectors8and9failed on lane 19 (s1 = 0x0000_8000).\scripts\test.ps1(cargo build --workspace+cargo test --workspace -- --test-threads=4): 738 passed, 0 failed, 41 ignoredSKIPPEDGPU tests on this adapter (expected on wave32-only NVIDIA):gpu::recomp::tests::gpu_geometry_wave32_prefix_count_over_a_mask: no wave64gpu::recomp::tests::gpu_wave32_program_in_wave64_hardware: no wave64python scripts/pr_check.py --local:description okRegression run
crates/xcl/src/gpu/recomp/tests.rs(no runtime code changes).Not tested
gpu_waves()wave64 branch), Intel GPUs, Wine, release test buildXCL_SAMPLE_*variables set)AI use
@mynzjerko on GitHub · 2026-11-24 11:53 UTC · original
Tested on native Windows + AMD RDNA4 (both
wave64andwave32paths viagpu_waves()): the new test and full suite passed with 0 skips.Tested
bf22429c3076f69657f79ace079e6fc61c2f777032.0.32029.2010), AMD Ryzen 5 7500F, Windows 11 Pro 10.0.26300,rustc 1.100.0(stable-x86_64-pc-windows-msvc), DXC1.9.2602.17, debug buildcargo build --workspace: okcargo test -p xcl --lib -- gpu_alignbit_alignbyte_and_perm_b32 --nocapture --test-threads=1: 1 passed, 0 failed, 0 ignored (0 SKIPPED)cargo test --workspace -- --test-threads=4: 738 passed, 0 failed, 41 ignored (xcl --lib: 695 passed, 0 failed, 21 ignored;SKIPPEDGPU tests: 0)Not tested
scripts/smoke.ps1)AI use
@DavidM1911 on GitHub · 2026-11-25 09:04 UTC · original
Verification on RTX 3060 Ti (Windows 11), branch merged with current
main:cargo test -p xcl --lib: all passed, 0 failed, ~26 ignored. (Intermittent single-test flake / 0xc0000005 abort under parallel scheduling — tracked in #1978; clean on single-threaded rerun.)Thanks!
View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.