Tests: pin the generated D3D12 layout table invariants #1641
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!1641
Loading…
Reference in a new issue
No description provided.
Delete branch "gh-pr/1641/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?
@amazedturnip on GitHub · 2026-11-24 18:33 UTC · original
amazedturnip:xcl/tests-d3d12-layout-table-and-chain-invariants-181008→main· +133 −0 · 1 files · 1 commits · merged 2026-11-25 19:22 UTCNew static integration test crates/xcl/tests/d3d12_layout.rs (6 tests, 133 lines) pins the generated D3D12 interface table and its lookup helpers. It asserts unique names/IIDs, IUnknown vtable head, GUID round-trip through parse_guid/guid_string (with all-zero fallback for non-hex input), per-chain most-derived-first ordering with no non-versioned-sibling leakage, and slot()/find() consistency. No runtime code changes; negative control verified by duplicating an IID and observing the table_shape_and_unique_ids failure.
What is in it
crates/xcl/tests/d3d12_layout.rs: new integration test suite (6 tests) covering the generated d3d12_layout.rs table and the layout.rs helpers: unique interface names and IIDs with non-empty parent and method lists (IUnknown head QueryInterface/AddRef/Release), guid_string(parse_guid(iid)) == iid for every entry plus canonical format and all-zero fallback for non-hex text, chain(ID3D12Device)/chain(ID3D12CommandQueue) returning the base plus every numbered descendant most-derived-first with no non-versioned sibling (ID3D12DeviceChild/Factory/Configuration), slot() for known methods (CreateCommandQueue=8, CreateCommittedResource=27, CreateFence=36, ExecuteCommandLists=10) and None for unknown/misspelled/empty methods, and find/slot/chain consistency (find returns the table entry for every name, every numbered device version listed by chain(ID3D12Device) and listed by its own chain, inherited slot stable across parent and child).Tested
AMD Radeon(TM) Graphics (driver 32.0.21043.19003, DXC 1.9.2609, native wave64),XCL_ADAPTER=radeon):cargo test --workspace -- --test-threads=1— 782 passed, 0 failed, 41 ignored (SKIPPED GPU tests: 1 (no heap windows))Not tested
AI use
@DavidM1911 on GitHub · 2026-11-24 20:56 UTC · original
Verification on RTX 3060 Ti (Windows 11), branch merged with current
main:cargo test -p xcl --lib: all passed, 0 failed, ~22 ignored.Thanks!
@JJAutoCompare on GitHub · 2026-11-25 04:55 UTC · original
XCL PR #1641 — Intel Arc A770 verification
Head
e6d7485354020423b1b638f47bd66866a75fe989, tested from a clean detached checkout. STOR-WINLAB ran Windows 11 Enterprise Evaluation x64 build 26200, AMD Ryzen 7 3800X, and Intel Arc A770 with driver 32.0.101.9175. DXC was 1.9.2609.5 and rustc was 1.100.0 (0ef1bc386, x86_64-pc-windows-msvc). Builds used unoptimized dev/test profiles with debug info and incremental compilation disabled.Tested
cargo build --workspaceandcargo test --workspace --no-runsucceeded outside the Arc mutex.cargo test -p xcl --test d3d12_layoutwithXCL_ADAPTER=NONE_CPU_ONLYoutside the mutex reported 6 passed, 0 failed, 0 ignored, 0 explicit skips. The PR adds onlycrates/xcl/tests/d3d12_layout.rs. Its tests check unique interface names and IIDs, parent and method list shape and the IUnknown prefix, GUID round-trips and malformed inputs, device and queue chain membership and order, known and unknown slots, and inherited slot consistency.cargo test --workspace --no-fail-fast -- --test-threads=4ran once underInvoke-ArcTest.ps1withXCL_ADAPTER=A770andRUST_TEST_NOCAPTURE=1. Cargo exited 101. All 21 result lines inpr1641-suite.log(20 test binaries and one doctest target) sum to 846 passed, 18 failed, and 42 ignored. The six layout tests also passed in this run.Workspace failures and skips
CreateComputePipelineStateerror0x80070057. Four failed expectations for FMA overflow, implicit texture LOD, f16 high-half preservation, and pixel-shader wave reductions.RSSetDepthBiasXcheck drew blue where it expected green.SKIPPED. Two cited wave64, two cited an unavailable D3D12 debug layer, one cited tiled tier below 2, and one cited unavailable heap windows. These add no coverage.Not tested
Retail sample paths requiring
XCL_SAMPLE_*data, other GPUs, and a matched main run. The origin of the workspace failures remains undetermined.AI use
T3 Code / Codex (gpt-6.2-sol, reasoningEffort: high) ran the build and verification. Coordinator #2 (T3 Code / Antigravity, gemini-4-neon) verified counts against
pr1641-suite.logand published.@ivall on GitHub · 2026-11-25 19:22 UTC · original
Merging: invariants of the generated layout table.
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.