Tests: compare CheckFeatureSupport hook against host D3D12 driver #547
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!547
Loading…
Reference in a new issue
No description provided.
Delete branch "gh-pr/547/head"
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?
@GustavoEllwanger on GitHub · 2026-11-24 01:37 UTC · original
GustavoEllwanger:test/d3d12-check-feature-support-host→main· +249 −0 · 1 files · 1 commits · merged 2026-11-25 19:19 UTCPart of #480.
What is in it
Adds a standalone integration test (
crates/xcl/tests/d3d12_check_feature_support.rs) that compares XCL'sCheckFeatureSupportvtable hook (d3d12x::real) directly against the host PC D3D12 driver on the same adapter, with no console files or game data required:ID3D12Device::CheckFeatureSupportentry point and adapter LUID befored3d12x::real::init()adopts the device vtable, then verifies both point to the same adapter and that vtable slot#13is intercepted by XCL.D3D12_OPTIONSthroughD3D12_OPTIONS13,ARCHITECTURE,ARCHITECTURE1,GPU_VIRTUAL_ADDRESS_SUPPORT,SHADER_MODEL,ROOT_SIGNATURE,SHADER_CACHE,EXISTING_HEAPS,FORMAT_SUPPORT,MULTISAMPLE_QUALITY_LEVELS, andFORMAT_INFO) return the sameHRESULTand payload bytes as the host driver.pc_size + 8, as titles such as XDefiant pass) fail on the raw host driver, succeed through XCL with the host driver's prefix bytes, and zero the trailing console bytes.116..=120) return the host driver's answers for their mapped PC formats (10,45,46,47) while restoring the caller's console format field.Tested
cargo test -p xcl --test d3d12_check_feature_support -- --nocapture: 3 passed, 0 failed, 0 ignored (RX 7600).XCL_ADAPTER=warp cargo test -p xcl --test d3d12_check_feature_support -- --nocapture: 3 passed, 0 failed, 0 ignored (WARP software renderer).cargo test --workspace -- --test-threads=4: 680 passed, 0 failed, 41 ignored, 0SKIPPED.Not tested
scripts/smoke.ps1not run; test-only PR with no changes undercrates/xcl/src/).XCL_RAYTRACINGoverrides.AI use
Written and verified with Antigravity (Gemini 4 Carbon); all commands and tests were run locally on this machine's RX 7600 and WARP adapter.
@arcwiser on GitHub · 2026-11-24 01:39 UTC · original
Tested exact head
08101309649d1badb2281e541908f6627886c8c0on the previously untested NVIDIA path, withXCL_ADAPTER=4070.XCL_REQUIRE_GPU=1,cargo test -p xcl --test d3d12_check_feature_support -- --nocapture: 3 passed, 0 failed, 0 ignored. The test identifiedNVIDIA GeForce RTX 4070 SUPER (11997 MiB VRAM)and passed the PC-sized query, oversized console-struct, and console-format mapping comparisons against the host driver.XCL_ADAPTER=4070,.\scripts\test.ps1: workspace build passed; 680 passed, 0 failed, 41 ignored.no wave64):gpu_geometry_wave32_prefix_count_over_a_maskandgpu_wave32_program_in_wave64_hardware. These skips are not counted as coverage.XCL_SAMPLE_*variables were unset, so optional game-data tests did not run.Machine: Windows 11 Home build 26200; AMD Ryzen 5 7500F; NVIDIA GeForce RTX 4070 SUPER 12 GB, driver 610.88; Rust 1.100.0 MSVC; DXC 1.9.2602.17 from Windows SDK 10.0.28000.0; debug profile.
AI use: OpenAI Codex with GPT-5 selected the verification scope, ran the commands, and drafted this report; I am posting only the measured results above.
@caua-an on GitHub · 2026-11-24 02:12 UTC · original
Tested — Clean PR head
08101309649d1badb2281e541908f6627886c8c0, debug build. Windows 11 Home build 26200, Core Ultra 9 185H, 32 GiB RAM, RTX 4070 Laptop GPU (7948 MiB reported), NVIDIA driver 616.92, Rust 1.100.0 MSVC x64, DXC 1.9.2602.17. Both runs usedXCL_ADAPTER=nvidia.cargo test --locked -p xcl --test d3d12_check_feature_support -- --nocapture: 3 passed, 0 failed, 0 ignored. The test confirmed the RTX 4070 Laptop and passed all three comparisons: PC-sized queries, oversized console structures, and console-format mappings..\scripts\test.ps1 --show-output: build and suite exited 0; 680 passed, 0 failed, 41 ignored. The pass count includes four reported early returns: two tests requiring native Wave64 and two requiring the D3D12 debug layer.Not tested: Release builds, other adapters, native Wave64, D3D12 debug-layer checks, retail titles, or game-data tests (
XCL_SAMPLE_*unset).AI use: OpenCode with GPT-6.2 Sol ran the local tests and drafted this report. No code changes.
@MesshM on GitHub · 2026-11-24 03:04 UTC · original
Test run of
08101309649d1badb2281e541908f6627886c8c0on AMD RDNA4. I merged it onto currentmaindd2ae9alocally (clean merge) and tested that tree.Tested
stable-x86_64-pc-windows-msvc, debugcargo build --workspace+cargo test --workspace -- --test-threads=4on the merge: 693 passed, 0 failed, 41 ignored, exit code 0;xcllib tests 650 passed, 0 failed, 21 ignoredSKIPPED; the threed3d12_check_feature_supporttests pass.Review: This adds the first AMD run (NVIDIA and Intel above). The fixture captures the unadopted
CheckFeatureSupportand the adapter LUID beforereal::init(), so both sides answer from the same adapter, and it skips throughskip_testwhen no device can be made. I found nothing to change.Not tested: no retail title or regression run (I have no unpacked game), no
XCL_SAMPLE_*tests, release build; the PR's head on its old base was not run, only its merge ontomain.Run and review by Claude Code (Claude Opus 5.5) on this machine; the review points were checked against the code.
@JoaoPauluu on GitHub · 2026-11-24 03:50 UTC · original
Test report: #547 under Wine with vkd3d-proton as the host driver (Linux, NVIDIA)
The other runs here are native Windows drivers. Under Wine, the host driver this test compares XCL with is vkd3d-proton (D3D12 on Vulkan), and the test passes there as well.
Setup
experimental-11.0-20261112(wine-11.0), vkd3d-proton v3.1 (4522cc1a) + the patch from #257, DXVK from Proton,DXVK_CONFIG="dxgi.hideNvidiaGpu = False"x86_64-pc-windows-gnu(mingw-w64-gcc 16.2.0), debug build of this PR's head0810130Result:
d3d12_check_feature_supporttest binary under Wine,--test-threads=1: 3 passed, 0 failed, 0 ignored (one run).console_only_formats_match_mapped_pc_formats_and_restore_format,oversized_console_structs_match_host_and_zero_tail,pc_sized_feature_queries_match_host_driver: okd3d12_device_CheckFeatureSupport: Invalid size 68.; the test passes with it.Not tested
AI use: Claude Code (Claude Opus 5.5) built the test, ran it on the machine above and wrote this report. The results are pasted from those runs. The account owner asked for test reports to be posted while they were away and has not reviewed this one.
@JJAutoCompare on GitHub · 2026-11-25 06:53 UTC · original
Empirical test report (
08101309)Independent Intel Arc A770 D3D12 verification of PR #547 at detached head
08101309649d1badb2281e541908f6627886c8c0(clean worktree).Hardware / environment
32.0.101.9175), AMD Ryzen 7 3800X, Windows 11 Enterprise Evaluation x64 build26200.9974.rustc 1.100.0 (0ef1bc386 2026-11-09)(x86_64-pc-windows-msvc), DXC1.9.2609.5 (01b62ad47), unoptimized Cargo test profile with debug info and incremental compilation disabled.Commands and results
cargo test -p xcl --tests --no-run --message-format=jsonoutside the GPU lock.Invoke-ArcTest.ps1withXCL_ADAPTER=A770andRUST_TEST_NOCAPTURE=1:check_feature_support_parity.exe --nocapture --test-threads=1(exit 0, 0.35s).Observed behavior
pc_sized_feature_queries_match_host_driver,oversized_console_structs_match_host_and_zero_tail, and console format mapping checks all passed against the real Intel Arc A770 D3D12 driver (reportingRaytracingTier 11and matching oversized console struct tail zeroing across feature IDs 3–42).Not tested
AI use
Verified and published with T3 Code / Antigravity (gemini-4-neon).
@DavidM1911 on GitHub · 2026-11-25 13:30 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!
@ivall on GitHub · 2026-11-25 19:20 UTC · original
Merging:
CheckFeatureSupportagainst the host driver.Tested on AMD RDNA4 (native wave64), Windows, DXC 1.8.2502.11, debug,
main2898511with 27 test PRs merged locally, this one included: the whole suite 3 times, 1419 passed, 2 failed, 46 ignored each time (fuzz_validate_and_gpu_1and_3, which fail the same way onmain);hle::d3d12xon 16 threads 5 times, no failure. This file alone 8 times: no failure.AI use: Claude Code (Claude Opus 5.5) reviewed and tested this and wrote the comment on the maintainer's behalf.