Tests: cover graphics PSO hooks on the GPU without game files #941

Open
github-bot wants to merge 1 commit from github-bot/gh-941 into main AGit
Owner

@⁠ChalanaGimhanaX on GitHub · 2026-11-24 09:00 UTC · original
ChalanaGimhanaX:tests/gpu-graphics-pso-e2e → main · +467 −0 · 1 files · 1 commits · open

Every GPU test in crates/xcl/tests/gpu_pso_e2e.rs skips when XCL_SAMPLE_RPF is unset, so the D3D12.X graphics pipeline hooks have no game-free GPU coverage on main. This adds an integration test binary mirroring gpu_compute_e2e.rs with minimal hand-encoded console VS/PS containers. No runtime files or game data are touched.

What is in it

  • crates/xcl/tests/gpu_graphics_e2e.rs: four synthetic GPU tests covering CreateGraphicsPipelineState (VS user-SGPR descriptor load + PS discard/interpolation, rect-list topology 19 rect_list_gs expansion, cold-cache async stand-in resolution and drop cleanup) and ID3D12Device2::CreatePipelineState (console graphics stream routing and E_INVALIDARG refusal of an MS container in the AS slot).

Tested

  • Hardware: AMD Ryzen 7 250, Windows 11 Pro build 26300, DXC 1.8.2502.11, rustc 1.100.0 (0ef1bc386 2026-11-09), debug build, tested on both GPUs on this machine:
    • AMD Radeon 780M Graphics (RDNA3, wave64 + mesh shaders, driver 32.0.21030.11004):
      • .\scripts\test.ps1 (cargo test --workspace -- --test-threads=4): 720 passed, 0 failed, 41 ignored (0 GPU skips; 2 debug-layer tests skipped because d3d12SDKLayers.dll is not installed)
      • XCL_ADAPTER=radeon XCL_REQUIRE_GPU=wave64,mesh cargo test -p xcl --test gpu_graphics_e2e: 4 passed, 0 failed
      • XCL_SPLIT_WAVE64=1 cargo test -p xcl --test gpu_graphics_e2e: 4 passed, 0 failed
      • XCL_ASYNC_PSO=0 cargo test -p xcl --test gpu_graphics_e2e: 4 passed, 0 failed (1 skipped: async_graphics_pso_registers_real_pso_and_cleans_up_on_drop)
    • NVIDIA GeForce RTX 5060 Laptop GPU (Blackwell, wave32 + mesh shaders, driver 610.88 / 32.0.16.1088):
      • XCL_ADAPTER=nvidia .\scripts\test.ps1 (cargo test --workspace -- --test-threads=4): 720 passed, 0 failed, 41 ignored (2 GPU skips: gpu_geometry_wave32_prefix_count_over_a_mask, gpu_wave32_program_in_wave64_hardware — no wave64; plus the 2 debug-layer skips)
      • XCL_ADAPTER=nvidia cargo test -p xcl --test gpu_graphics_e2e: 4 passed, 0 failed (0 skips)

Not tested

  • Intel GPUs, RDNA2/RDNA4 discrete GPUs, Wine / vkd3d-proton
  • D3D12 debug layer (d3d12SDKLayers.dll not installed) and optional XCL_SAMPLE_* retail-data tests

AI use

  • Antigravity (Gemini 4 Neon): drafted the test binary and PR description, checked open PRs for overlap, and ran the local test suite; all assertions and dual-GPU results verified on AMD Radeon 780M and NVIDIA RTX 5060 hardware.
**@⁠ChalanaGimhanaX** on GitHub · 2026-11-24 09:00 UTC · [original](https://github.com/xcl-dev/xcl/pull/941) `ChalanaGimhanaX:tests/gpu-graphics-pso-e2e` → `main` · +467 −0 · 1 files · 1 commits · open Every GPU test in `crates/xcl/tests/gpu_pso_e2e.rs` skips when `XCL_SAMPLE_RPF` is unset, so the D3D12.X graphics pipeline hooks have no game-free GPU coverage on `main`. This adds an integration test binary mirroring `gpu_compute_e2e.rs` with minimal hand-encoded console VS/PS containers. No runtime files or game data are touched. **What is in it** - `crates/xcl/tests/gpu_graphics_e2e.rs`: four synthetic GPU tests covering `CreateGraphicsPipelineState` (VS user-SGPR descriptor load + PS discard/interpolation, rect-list topology 19 `rect_list_gs` expansion, cold-cache async stand-in resolution and drop cleanup) and `ID3D12Device2::CreatePipelineState` (console graphics stream routing and `E_INVALIDARG` refusal of an MS container in the AS slot). **Tested** - Hardware: AMD Ryzen 7 250, Windows 11 Pro build 26300, DXC 1.8.2502.11, `rustc 1.100.0 (0ef1bc386 2026-11-09)`, debug build, tested on both GPUs on this machine: - **AMD Radeon 780M Graphics** (RDNA3, wave64 + mesh shaders, driver `32.0.21030.11004`): - `.\scripts\test.ps1` (`cargo test --workspace -- --test-threads=4`): 720 passed, 0 failed, 41 ignored (0 GPU skips; 2 debug-layer tests skipped because `d3d12SDKLayers.dll` is not installed) - `XCL_ADAPTER=radeon XCL_REQUIRE_GPU=wave64,mesh cargo test -p xcl --test gpu_graphics_e2e`: 4 passed, 0 failed - `XCL_SPLIT_WAVE64=1 cargo test -p xcl --test gpu_graphics_e2e`: 4 passed, 0 failed - `XCL_ASYNC_PSO=0 cargo test -p xcl --test gpu_graphics_e2e`: 4 passed, 0 failed (1 skipped: `async_graphics_pso_registers_real_pso_and_cleans_up_on_drop`) - **NVIDIA GeForce RTX 5060 Laptop GPU** (Blackwell, wave32 + mesh shaders, driver `610.88` / `32.0.16.1088`): - `XCL_ADAPTER=nvidia .\scripts\test.ps1` (`cargo test --workspace -- --test-threads=4`): 720 passed, 0 failed, 41 ignored (2 GPU skips: `gpu_geometry_wave32_prefix_count_over_a_mask`, `gpu_wave32_program_in_wave64_hardware` — `no wave64`; plus the 2 debug-layer skips) - `XCL_ADAPTER=nvidia cargo test -p xcl --test gpu_graphics_e2e`: 4 passed, 0 failed (0 skips) **Not tested** - Intel GPUs, RDNA2/RDNA4 discrete GPUs, Wine / vkd3d-proton - D3D12 debug layer (`d3d12SDKLayers.dll` not installed) and optional `XCL_SAMPLE_*` retail-data tests **AI use** - Antigravity (Gemini 4 Neon): drafted the test binary and PR description, checked open PRs for overlap, and ran the local test suite; all assertions and dual-GPU results verified on AMD Radeon 780M and NVIDIA RTX 5060 hardware.
Every GPU test in gpu_pso_e2e.rs skips when XCL_SAMPLE_RPF is unset,
leaving CreateGraphicsPipelineState and graphics CreatePipelineState
streams untested on a GPU without retail data.

Add crates/xcl/tests/gpu_graphics_e2e.rs with hand-encoded console
VS/PS containers covering:
- VS user-SGPR descriptor loads, PS discard/interpolation and pixel
  readback through CreateGraphicsPipelineState
- console rect-list topology (19) attaching rect_list_gs and expanding
  3 vertices across the implied 4th corner
- cold-cache async graphics PSO creation behind a stand-in and cleanup
  of TRANSLATED_GRAPHICS / pso_async on drop
- graphics pipeline streams through ID3D12Device2::CreatePipelineState
  and E_INVALIDARG refusal of a console MS container in the AS slot
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 04:37:40 +00:00
Author
Owner

@⁠dcastell1 on GitHub · 2026-11-24 09:11 UTC · original

Verified on Windows 11 10.0.26300, NVIDIA GeForce RTX 5090 (driver 621.24), Rust 1.100.0 MSVC 14.44.35207, debug build, on clean main@beaa245 (713 passed, 0 failed, 41 ignored on this box):

patch -p1 < this PR            # clean, no fuzz
cargo test --workspace -- --test-threads=4
717 passed; 0 failed; 41 ignored   (exit 0)

Four more passing tests than main; the graphics PSO hook coverage runs on this GPU without game files, which is what it was written for.

Tree restored afterwards (md5 and a full diff against a clean checkout), hardware adapter, no Wine, no game data. AI-assisted (opencode): applied the patch to a built tree, ran the suite, reverted it.

**@⁠dcastell1** on GitHub · 2026-11-24 09:11 UTC · [original](https://github.com/xcl-dev/xcl/pull/941#issuecomment-7127070439) Verified on Windows 11 10.0.26300, NVIDIA GeForce RTX 5090 (driver 621.24), Rust 1.100.0 MSVC 14.44.35207, debug build, on clean `main@beaa245` (713 passed, 0 failed, 41 ignored on this box): ``` patch -p1 < this PR # clean, no fuzz cargo test --workspace -- --test-threads=4 717 passed; 0 failed; 41 ignored (exit 0) ``` Four more passing tests than main; the graphics PSO hook coverage runs on this GPU without game files, which is what it was written for. Tree restored afterwards (md5 and a full diff against a clean checkout), hardware adapter, no Wine, no game data. AI-assisted (opencode): applied the patch to a built tree, ran the suite, reverted it.
Author
Owner

@⁠Aniseto on GitHub · 2026-11-24 09:42 UTC · original · edited 2026-11-24 10:05 UTC

Verified on Windows 11 Pro build 26200, NVIDIA GeForce RTX 5070 Ti (driver 32.0.16.2124, wave32 only), Intel Core i5-12400F, 64 GB RAM, Rust 1.100.0 MSVC 14.44.35207, DXC 1.9.2609.5, debug build, on 91ca6ce (detached worktree from refs/pull/941/head):

XCL_ADAPTER=nvidia cargo test -p xcl --test gpu_graphics_e2e
4 passed, 0 failed, 0 ignored, 0 skipped      (exit 0)

The graphics PSO hook coverage runs on this GPU without game files, which is what it was written for.

Tree untouched afterwards (git status clean, no local changes), hardware adapter, no Wine, no game data. Not tested: Intel GPUs, RDNA2/RDNA4, optional XCL_SAMPLE_* retail-data tests.

AI-assisted (OpenCode), model: DeepSeek V4.1 Flash 1017 - checked out the PR's head commit in a detached worktree, built it, ran the test binary, wrote this report; the worktree was not modified.

**@⁠Aniseto** on GitHub · 2026-11-24 09:42 UTC · [original](https://github.com/xcl-dev/xcl/pull/941#issuecomment-7127783466) · edited 2026-11-24 10:05 UTC Verified on Windows 11 Pro build 26200, NVIDIA GeForce RTX 5070 Ti (driver 32.0.16.2124, wave32 only), Intel Core i5-12400F, 64 GB RAM, Rust 1.100.0 MSVC 14.44.35207, DXC 1.9.2609.5, debug build, on `91ca6ce` (detached worktree from `refs/pull/941/head`): ``` XCL_ADAPTER=nvidia cargo test -p xcl --test gpu_graphics_e2e 4 passed, 0 failed, 0 ignored, 0 skipped (exit 0) ``` The graphics PSO hook coverage runs on this GPU without game files, which is what it was written for. Tree untouched afterwards (git status clean, no local changes), hardware adapter, no Wine, no game data. Not tested: Intel GPUs, RDNA2/RDNA4, optional `XCL_SAMPLE_*` retail-data tests. AI-assisted (OpenCode), model: **DeepSeek V4.1 Flash 1017** - checked out the PR's head commit in a detached worktree, built it, ran the test binary, wrote this report; the worktree was not modified.
Author
Owner

@⁠SlopTart on GitHub · 2026-11-24 10:37 UTC · original

Linux / AMD RDNA3 datapoint.

Merged state: head 91ca6ce onto main 9aec53d, clean merge.

Full suite, cargo test --workspace --release --no-fail-fast --target x86_64-pc-windows-gnu -- --test-threads=4: 717 passed, 11 failed, 41 ignored; failures are the known Wine-lane set from my #42 rows plus this rig's title-textures flake family (see #718). GPU graphics-PSO hooks tests green.

Not tested: retail titles (none here), Windows, RDNA4.
Counts only, no game data.

Machine: RX 7900 XT (RADV NAVI31), Mesa 26.2.5, kernel 7.2 (Arch), Proton Experimental (wine-11.0), patched vkd3d-proton v3.1, Rust cross x86_64-pc-windows-gnu, XCL_NETWORK=0, release profile, --test-threads=4. My Linux rows: #42 / #718.

AI use: Hermes agent (local Qwen-class) ran the suite and drafted this; I checked it before posting.

**@⁠SlopTart** on GitHub · 2026-11-24 10:37 UTC · [original](https://github.com/xcl-dev/xcl/pull/941#issuecomment-7129036440) Linux / AMD RDNA3 datapoint. **Merged state:** head `91ca6ce` onto main `9aec53d`, clean merge. **Full suite, `cargo test --workspace --release --no-fail-fast --target x86_64-pc-windows-gnu -- --test-threads=4`:** **717 passed, 11 failed, 41 ignored**; failures are the known Wine-lane set from my #42 rows plus this rig's title-textures flake family (see #718). GPU graphics-PSO hooks tests green. **Not tested:** retail titles (none here), Windows, RDNA4. Counts only, no game data. **Machine:** RX 7900 XT (RADV NAVI31), Mesa 26.2.5, kernel 7.2 (Arch), Proton Experimental (wine-11.0), patched vkd3d-proton v3.1, Rust cross `x86_64-pc-windows-gnu`, `XCL_NETWORK=0`, release profile, `--test-threads=4`. My Linux rows: #42 / #718. AI use: Hermes agent (local Qwen-class) ran the suite and drafted this; I checked it before posting.
Author
Owner

@⁠DavidM1911 on GitHub · 2026-11-24 13:51 UTC · original

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

  • lib pso: 22 passed, 1 ignored, 0 failed.

Thanks!

**@⁠DavidM1911** on GitHub · 2026-11-24 13:51 UTC · [original](https://github.com/xcl-dev/xcl/pull/941#issuecomment-7133438134) Verification on RTX 3060 Ti (Windows 11), branch merged with current `main`: - lib pso: 22 passed, 1 ignored, 0 failed. Thanks!
Author
Owner

@⁠DavidM1911 on GitHub · 2026-11-26 03:11 UTC · original

Re-verification on RTX 3060 Ti (Windows 11), new head merged with current main:

  • cargo test -p xcl --lib: all passed, 0 failed, 27 ignored. The earlier merge conflict is resolved.

Thanks!

— Devin

**@⁠DavidM1911** on GitHub · 2026-11-26 03:11 UTC · [original](https://github.com/xcl-dev/xcl/pull/941#issuecomment-7181476676) Re-verification on RTX 3060 Ti (Windows 11), new head merged with current `main`: - `cargo test -p xcl --lib`: all passed, 0 failed, 27 ignored. The earlier merge conflict is resolved. Thanks! — Devin
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/941/head:github-bot/gh-941'
git switch 'github-bot/gh-941'

Merge

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