Skip to content

Tests: verify RDNA2 DPP16, DPP8, and SDWA VALU/VOPC ops on the GPU - #1366

Open
Vadson159 wants to merge 1 commit into
xcl-dev:mainfrom
Vadson159:test/recomp-dpp-sdwa
Open

Vadson159 wants to merge 1 commit into
xcl-dev:mainfrom
Vadson159:test/recomp-dpp-sdwa

Conversation

@Vadson159

Copy link
Copy Markdown
Contributor

Add an integration test suite in crates/xcl/tests/gpu_recomp_dpp_sdwa.rs covering RDNA2 DPP16, DPP8, and SDWA (including VOPC VOP_SDWA_SDST_ENC) translation, DXC compilation, and GPU execution.

What is in it

  • crates/xcl/tests/gpu_recomp_dpp_sdwa.rs (4 tests, 1,117 lines):
    • dpp_sdwa_translate_and_compile_with_dxc: verifies RDNA2 to HLSL translation and DXC compilation for DPP16, DPP8, SDWA, and VOPC SDWA test shaders.
    • gpu_dpp16_controls_masks_and_fetch_inactive: executes DPP16 controls, masks, and fetch-inactive handling on the GPU.
    • gpu_dpp8_permutations_and_fetch_inactive: executes DPP8 permutations and fetch-inactive handling on the GPU.
    • gpu_sdwa_selectors_unused_modifiers_and_vopc: executes SDWA selectors, unused-lane modes, modifiers, and VOPC (VOP_SDWA_SDST_ENC, including verifying wave32 preserves the upper 32 bits 0xDEAD_BEEF of s[10:11] via S_MOV_B32 s16, s11).

Tested

  • Hardware and toolchain: AMD Radeon RX 9070 XT (driver 32.0.32029.2010; AMD Radeon(TM) Graphics driver 32.0.21045.29003 also present), AMD Ryzen 7 9800X3D 8-Core Processor, Microsoft Windows NT 10.0.26300.0, rustc 1.100.0 (0ef1bc386 2026-11-09) (stable-x86_64-pc-windows-msvc), debug build, dxcompiler 1.8.2502.11 (C:\Program Files (x86)\Windows Kits\10\bin\10.0.26100.0\x64).
  • $env:XCL_REQUIRE_GPU="wave64,mesh"; .\scripts\test.ps1: 755 passed, 0 failed, 41 ignored across 20 test suites, 0 GPU skips (xcl lib: 707 passed, 0 failed, 21 ignored; gpu_recomp_dpp_sdwa: 4 passed, 0 failed, 0 ignored; e2e: 3 passed, 0 failed, 0 ignored; console_shaders: 3 passed, 0 failed, 4 ignored; heap_probe: 0 passed, 0 failed, 4 ignored; xg_oracle: 6 passed, 0 failed, 12 ignored; all XCL_SAMPLE_* unset).
  • $env:XCL_REQUIRE_GPU="wave64,mesh"; cargo test -p xcl --test gpu_recomp_dpp_sdwa: 4 passed, 0 failed, 0 ignored.
  • rustfmt --check H:\XCL_1\crates\xcl\tests\gpu_recomp_dpp_sdwa.rs: passed (exit 0).
  • cargo clippy -p xcl --test gpu_recomp_dpp_sdwa -- --no-deps: 0 warnings in crates/xcl/tests/gpu_recomp_dpp_sdwa.rs.
  • python -m unittest discover -s H:\XCL_1\scripts -p "test_*.py" -v: 9 passed, 0 failed.

Regression run
Not required (changes are confined to crates/xcl/tests/gpu_recomp_dpp_sdwa.rs).

Not tested

  • NVIDIA, Intel, wave32-only GPUs, and AMD RDNA1/2/3 GPUs.
  • Release build configuration.
  • Retail Xbox titles (XCL_SAMPLE_* environment variables unset; no local game folder available).

AI use

  • Antigravity, Gemini 4 Hydrogen: checked open PRs/issues and RDNA2 DPP16/DPP8/SDWA emitter behavior, wrote crates/xcl/tests/gpu_recomp_dpp_sdwa.rs, ran the test suite and linters, and prepared this PR.

Add GPU execution and DXC compilation tests in
`crates/xcl/tests/gpu_recomp_dpp_sdwa.rs` covering RDNA2 DPP16, DPP8,
and SDWA modifiers across `wave64`, `split-wave64`, `wave32`, and
`wave32@hw64`.

Assisted-by: Antigravity (Gemini 4 Hydrogen)
@futurepro62

futurepro62 commented Nov 24, 2026 •

Copy link
Copy Markdown

Full-suite run, since this PR has no test report yet. Tested exact head 2e73789 (on its base 930e8b4).

Tested

  • NVIDIA GeForce RTX 5070 Ti 16 GB (Blackwell, 32-lane waves only, mesh shaders), driver 616.64, Ryzen 7 9800X3D, Windows 11 Home 26300, Rust 1.100.0 MSVC, debug, D3D12 debug layer installed.
  • cargo build --workspace, then XCL_REQUIRE_GPU=mesh cargo test --workspace -- --test-threads=4: 755 passed, 0 failed, 41 ignored. SKIPPED (no wave64): gpu_geometry_wave32_prefix_count_over_a_mask, gpu_wave32_program_in_wave64_hardware.
  • The new tests ran and passed: dpp_sdwa_translate_and_compile_with_dxc, gpu_dpp16_controls_masks_and_fetch_inactive, gpu_dpp8_permutations_and_fetch_inactive, gpu_sdwa_selectors_unused_modifiers_and_vopc.
  • Same head on the AMD Radeon iGPU of the 9800X3D (RDNA2, XCL_ADAPTER=radeon), cargo test --workspace -- --test-threads=4: 755 passed, 0 failed, 41 ignored, no skips.

Not tested

  • a release build, a game (test run only).

AI use

  • Claude Code (Claude Opus 5.5) ran the tests and wrote this report. I checked it before posting.

@DavidM1911

Copy link
Copy Markdown
Contributor

Verification on RTX 3060 Ti (Windows 11), branch merged with current main:

  • cargo test -p xcl --lib: all passed, 0 failed, ~21 ignored.

Thanks!

@ivall ivall added the off-goal Does not bear on the current goal (world loading); waits until it is reached label Nov 24, 2026
@github-actions

Copy link
Copy Markdown

Nothing has happened on this PR for 3 days, so it is marked stale and will be closed in 4 days. A push or a comment takes the mark off: rebase it onto main if it conflicts, and say in one line what it still fixes. If it only waits for a maintainer, a comment saying so is enough.

@github-actions github-actions Bot added the stale No activity for 3 days; closed 4 days later unless something happens label Nov 28, 2026
@Foniass

Foniass commented Dec 1, 2026

Copy link
Copy Markdown
Collaborator

Triage (#1607) – head 2e73789

No open or merged PR adds the same tests. #1620, #1778 and #858 have a few DPP/SDWA encodings in wider test suites, and main has some DPP cases in gpu/recomp/tests.rs, but nothing covers DPP16/DPP8/SDWA modifiers like this file.
In gpu_ready, wave64_programs_supported() == Ok(false) skips every mode, including the wave32 and split-wave64 forms that do not need wave64. The file is 1117 lines (over the ~800 line limit) and the description should say why it cannot be split.
Recommendation: keep open.

AI review: Claude Code (Claude Opus 5.5), diffs read only, not built or run; not checked by a human.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

off-goal Does not bear on the current goal (world loading); waits until it is reached stale No activity for 3 days; closed 4 days later unless something happens

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants