Tests: select configured adapter in VRAM fixtures #2337

Open
github-bot wants to merge 2 commits from github-bot/gh-2337 into main AGit
Owner

@⁠luckyteagirl on GitHub · 2026-11-25 15:24 UTC · original
luckyteagirl:codex/vram-test-adapter → main · +43 −18 · 2 files · 2 commits · open

Select the hardware adapter requested by XCL_ADAPTER in the two shared-video-memory GPU fixtures and print the selected adapter. Both fixtures previously used DXGI adapter 0, so on a hybrid machine they could pass on the integrated GPU when a discrete GPU was requested. The shared-page test also now reports capability and device-creation skips through the counted test helper. Part of #2306; related to #2270.

What is in it

  • crates/xcl/src/hle/d3d12x/vram.rs: use the shared adapter selector in the D32S8 VRAM fixture and report adapter/device/tier skips.
  • crates/xcl/src/hle/d3d12x/title_textures.rs: use the shared adapter selector in the placed-texture fixture and count factory, tier, reserved-cube, UMA, and allocation skips. Pixel and page assertions are unchanged.

Tested

  • Windows 11 Home build 26200, Ryzen 9 5980HX, AMD Radeon RX 6800M (driver 30.0.13002.13003), Rust 1.99.0 MSVC, DXC/DXIL 1.9.2609.5; debug builds and selected GPU tests.
  • XCL_ADAPTER=6800M cargo test --locked -p xcl --lib d32s8_targets_take_their_own_size_of_video_memory -- --test-threads=1 --show-output: 1 passed, 0 failed, 0 ignored, 0 skipped. Printed D32S8 VRAM test adapter: AMD Radeon RX 6800M and exercised the 14-target depth/stencil readback.
  • XCL_ADAPTER=6800M cargo test --locked -p xcl --lib placed_title_textures_share_vram_and_preserve_pixels -- --test-threads=1 --show-output: 1 harness pass, 0 failed, 0 ignored, 1 explicit SKIPPED because this adapter cannot create a reserved cube with mips. Printed Shared-page texture test adapter: AMD Radeon RX 6800M; the fixture's cube capability gate prevented its later checks.
  • cargo build --locked --workspace -j 1: passed (3 existing warnings: 2 deprecated atomic fetch_update calls and 1 dead-code field).
  • Initial XCL_ADAPTER=nomatch cargo test --locked --workspace --no-fail-fast -j 1 -- --test-threads=1 --show-output before building the workspace exited 101: 1434 passed, 1 failed, 47 ignored; the only failure was e2e::test_title_runs_and_game_folder_is_untouched, which requires the workspace-built xcl_testtitle.exe and testgame_mw.dll. After the workspace build, the same command passed: 37 target summaries, 1435 passed, 0 failed, 47 ignored. It emitted 137 standalone SKIPPED notices (120 no GPU, 15 no GPU with 32-lane waves, 1 no wave32 GPU, 1 no wave64); the two changed fixtures also reported inline no selected hardware adapter skips under nomatch. These no-GPU skips do not cover the GPU fixture behavior.

Regression run

  • Main (b49be1836844fe0b0cdb3211dce3cb7fb4e21ac7):
    xcl-smoke v1
    commit: b49be1836844fe0b0cdb3211dce3cb7fb4e21ac7
    gpu: AMD Radeon RX 6800M
    title: 2ef5fd64
    seconds: 30
    exit: 0x0
    frames shown: 385 (PresentX 385)
    presents per 2 s (last 3): 51 53 51
    device removals: 0
    crashes: 0
    peak commit: 8284 MB
    
  • This PR (436e946c306c0f7c70172ba9910908a2f1d2472e, clean):
    xcl-smoke v1
    commit: 436e946c306c0f7c70172ba9910908a2f1d2472e
    gpu: AMD Radeon RX 6800M
    title: 2ef5fd64
    seconds: 30
    exit: 0x0
    frames shown: 425 (PresentX 425)
    presents per 2 s (last 3): 60 49 52
    device removals: 0
    crashes: 0
    peak commit: 8297 MB
    

Not tested

  • Shared-page cubemap behavior on this RX 6800M driver, other adapters, and a full GPU workspace suite. The current-head smoke checks ordinary title behavior; it does not exercise these isolated GPU fixtures.

AI use

  • OpenAI Codex (GPT-6; exact serving variant unavailable), with a Luna subagent, refreshed the existing test-only commits onto current main, ran the checks above, and prepared this description. I reviewed the code and evidence before updating the PR. The two fixtures originated in the earlier AI-assisted branch; the refresh did not change their intended scope.
**@⁠luckyteagirl** on GitHub · 2026-11-25 15:24 UTC · [original](https://github.com/xcl-dev/xcl/pull/2337) `luckyteagirl:codex/vram-test-adapter` → `main` · +43 −18 · 2 files · 2 commits · open Select the hardware adapter requested by `XCL_ADAPTER` in the two shared-video-memory GPU fixtures and print the selected adapter. Both fixtures previously used DXGI adapter 0, so on a hybrid machine they could pass on the integrated GPU when a discrete GPU was requested. The shared-page test also now reports capability and device-creation skips through the counted test helper. Part of #2306; related to #2270. **What is in it** - `crates/xcl/src/hle/d3d12x/vram.rs`: use the shared adapter selector in the D32S8 VRAM fixture and report adapter/device/tier skips. - `crates/xcl/src/hle/d3d12x/title_textures.rs`: use the shared adapter selector in the placed-texture fixture and count factory, tier, reserved-cube, UMA, and allocation skips. Pixel and page assertions are unchanged. **Tested** - Windows 11 Home build 26200, Ryzen 9 5980HX, AMD Radeon RX 6800M (driver `30.0.13002.13003`), Rust 1.99.0 MSVC, DXC/DXIL 1.9.2609.5; debug builds and selected GPU tests. - `XCL_ADAPTER=6800M cargo test --locked -p xcl --lib d32s8_targets_take_their_own_size_of_video_memory -- --test-threads=1 --show-output`: 1 passed, 0 failed, 0 ignored, 0 skipped. Printed `D32S8 VRAM test adapter: AMD Radeon RX 6800M` and exercised the 14-target depth/stencil readback. - `XCL_ADAPTER=6800M cargo test --locked -p xcl --lib placed_title_textures_share_vram_and_preserve_pixels -- --test-threads=1 --show-output`: 1 harness pass, 0 failed, 0 ignored, 1 explicit `SKIPPED` because this adapter cannot create a reserved cube with mips. Printed `Shared-page texture test adapter: AMD Radeon RX 6800M`; the fixture's cube capability gate prevented its later checks. - `cargo build --locked --workspace -j 1`: passed (3 existing warnings: 2 deprecated atomic `fetch_update` calls and 1 dead-code field). - Initial `XCL_ADAPTER=nomatch cargo test --locked --workspace --no-fail-fast -j 1 -- --test-threads=1 --show-output` before building the workspace exited 101: 1434 passed, 1 failed, 47 ignored; the only failure was `e2e::test_title_runs_and_game_folder_is_untouched`, which requires the workspace-built `xcl_testtitle.exe` and `testgame_mw.dll`. After the workspace build, the same command passed: 37 target summaries, 1435 passed, 0 failed, 47 ignored. It emitted 137 standalone `SKIPPED` notices (120 `no GPU`, 15 `no GPU with 32-lane waves`, 1 `no wave32 GPU`, 1 `no wave64`); the two changed fixtures also reported inline `no selected hardware adapter` skips under `nomatch`. These no-GPU skips do not cover the GPU fixture behavior. **Regression run** - Main (`b49be1836844fe0b0cdb3211dce3cb7fb4e21ac7`): ``` xcl-smoke v1 commit: b49be1836844fe0b0cdb3211dce3cb7fb4e21ac7 gpu: AMD Radeon RX 6800M title: 2ef5fd64 seconds: 30 exit: 0x0 frames shown: 385 (PresentX 385) presents per 2 s (last 3): 51 53 51 device removals: 0 crashes: 0 peak commit: 8284 MB ``` - This PR (`436e946c306c0f7c70172ba9910908a2f1d2472e`, clean): ``` xcl-smoke v1 commit: 436e946c306c0f7c70172ba9910908a2f1d2472e gpu: AMD Radeon RX 6800M title: 2ef5fd64 seconds: 30 exit: 0x0 frames shown: 425 (PresentX 425) presents per 2 s (last 3): 60 49 52 device removals: 0 crashes: 0 peak commit: 8297 MB ``` **Not tested** - Shared-page cubemap behavior on this RX 6800M driver, other adapters, and a full GPU workspace suite. The current-head smoke checks ordinary title behavior; it does not exercise these isolated GPU fixtures. **AI use** - OpenAI Codex (GPT-6; exact serving variant unavailable), with a Luna subagent, refreshed the existing test-only commits onto current `main`, ran the checks above, and prepared this description. I reviewed the code and evidence before updating the PR. The two fixtures originated in the earlier AI-assisted branch; the refresh did not change their intended scope.
Select the same high-performance hardware adapter as the GPU test runner. Report selection and device setup failures as skips instead of silently returning, so a GPU report identifies the device it actually exercised.

Assisted-by: OpenAI Codex (GPT-6; exact variant unavailable)
Use the selected hardware adapter in the existing texture fixture and count unavailable-capability skips. Request IDXGIFactory6 through CreateDXGIFactory2 in both VRAM GPU fixtures.
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 05:28:02 +00:00
Author
Owner

@⁠SlopTart on GitHub · 2026-11-25 15:50 UTC · original · edited 2026-11-25 15:51 UTC

Tested: current PR head merged onto current origin/main (clean), Linux (Arch, kernel 7.2.15), Mesa 26.2.5 RADV, Radeon RX 7900 XT (NAVI31), cargo target x86_64-pc-windows-gnu run under wine-11.0 (Proton), rustc 1.94.0, vkd3d-proton 3.1 with the XCL patch, official MS DXC (binaries 2026-09-29).

  • gpu_ suite (--release --locked, --test-threads=2): 144 passed / 3 failed / 1 ignored, same three baseline failures as plain origin/main on this rig (rig's known baseline: fuzz seed 1003 of #2115, gpu_nonfused_mad_and_mac_prevent_fma_contraction, gpu_depth_buffer_created_for_unordered_access_is_placed).
  • The reworked SVAM fixtures (placed_title_textures_share_vram_and_preserve_pixels and sibling) now run through adapter::Selector under Wine/DXGI: pass with XCL_ADAPTER unset (auto) and with XCL_ADAPTER="AMD Radeon RX 7900 XT". The adapter-name print reports the real card on this lane.

Complements the XCL_ADAPTER fallback/skip matrix posted on #2324 earlier today: match path, auto path, and no-match skip all behave on the Wine lane.

Not tested: retail titles (no title data on this lane, counts only).

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

**@⁠SlopTart** on GitHub · 2026-11-25 15:50 UTC · [original](https://github.com/xcl-dev/xcl/pull/2337#issuecomment-7167357057) · edited 2026-11-25 15:51 UTC **Tested**: current PR head merged onto current `origin/main` (clean), Linux (Arch, kernel 7.2.15), Mesa 26.2.5 RADV, Radeon RX 7900 XT (NAVI31), cargo target `x86_64-pc-windows-gnu` run under wine-11.0 (Proton), rustc 1.94.0, vkd3d-proton 3.1 with the XCL patch, official MS DXC (binaries 2026-09-29). - `gpu_` suite (`--release --locked`, `--test-threads=2`): 144 passed / 3 failed / 1 ignored, same three baseline failures as plain `origin/main` on this rig (rig's known baseline: fuzz seed 1003 of #2115, `gpu_nonfused_mad_and_mac_prevent_fma_contraction`, `gpu_depth_buffer_created_for_unordered_access_is_placed`). - The reworked SVAM fixtures (`placed_title_textures_share_vram_and_preserve_pixels` and sibling) now run through `adapter::Selector` under Wine/DXGI: pass with `XCL_ADAPTER` unset (auto) and with `XCL_ADAPTER="AMD Radeon RX 7900 XT"`. The adapter-name print reports the real card on this lane. Complements the `XCL_ADAPTER` fallback/skip matrix posted on #2324 earlier today: match path, auto path, and no-match skip all behave on the Wine lane. **Not tested**: retail titles (no title data on this lane, counts only). **AI use**: Hermes agent (local Qwen-class) ran both machines and drafted this; I checked it before posting.
Author
Owner

@⁠DavidM1911 on GitHub · 2026-11-25 18:10 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!

**@⁠DavidM1911** on GitHub · 2026-11-25 18:10 UTC · [original](https://github.com/xcl-dev/xcl/pull/2337#issuecomment-7170540278) 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!
This pull request can be merged automatically.
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/2337/head:github-bot/gh-2337'
git switch 'github-bot/gh-2337'

Merge

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