Repository navigation
DXIL: add semantic inspection helper and fixture - #2575
luckyteagirl wants to merge 1 commit into
Conversation
|
Confirmed the author’s independent binding-parser fix on Earlier verificationI reproduced two missing resource bindings on Fix and compiled regression fixture. The inspector now reads DXC’s With |
865c792 to
5c46919
Compare
|
Thanks for the independent DXC check. I reproduced the missing AI use: OpenAI Codex (GPT-6.2-sol) reproduced the parser gap, amended this PR, ran the tests, and drafted this reply. |
|
Verification on RTX 3060 Ti (Windows 11), branch merged with current
Thanks! — Devin |
5c46919 to
0723b11
Compare
|
Re-verification on RTX 3060 Ti (Windows 11), new head merged with current
Thanks! — Devin |
|
Test report for 0723b11 with another DXC version Tested
Not tested
AI use
|
|
Independent desktop NVIDIA verification of PR #2575 at head Environment
Targeted DXIL semantic fixture tests & build (
|
| Command | Result |
|---|---|
python -B scripts/test_dxil_semantics.py --require-dxc (3 consecutive runs, exact CI check against live DXC 1.9.2609.5) |
Ran 7 tests ... OK × 3 (0.068s, 0.071s, 0.067s, 0 skipped, 0 failed: test_entry_metadata_contains_thread_group_size, test_explicit_missing_dxc_does_not_fall_back, test_features_operations_and_resource_semantics, test_invalid_dxc_directory_does_not_fall_back, test_multiple_entry_points_are_rejected, test_resource_bindings_include_constant_buffers_textures_and_tbuffers, test_stage_model_versions_and_entry_metadata) |
cargo build --release -p xcl |
Clean build (1m 12s, exit 0, 0 new warnings) |
Paired quiet 60 s retail smoke (title: 29640639)
Exact parent & merge-base (e1d84b7d9153f86a97d2ec5d209d196046fc0bea, cached baseline on the same machine):
xcl-smoke v1
commit: e1d84b7d9153f86a97d2ec5d209d196046fc0bea
gpu: NVIDIA GeForce RTX 4060
title: 29640639
seconds: 60
exit: 0x0
frames shown: 1531 (PresentX 1531)
presents per 2 s (last 3): 60 60 60
device removals: 0
crashes: 0
peak commit: 13982 MB
PR #2575 (0723b118cbafabb3c2200b0c9680e2a874335310):
xcl-smoke v1
commit: 0723b118cbafabb3c2200b0c9680e2a874335310
gpu: NVIDIA GeForce RTX 4060
title: 29640639
seconds: 60
exit: 0x0
frames shown: 1631 (PresentX 1631)
presents per 2 s (last 3): 60 60 60
device removals: 0
crashes: 0
peak commit: 13988 MB
Runtime log observations (xcl.log)
9223log lines,0[ERROR]/ device-removal / panic lines (dxil_cache:460hits,0misses,0compilation failures;228background pipelines,0failures).- Final draw/memory telemetry in log:
19663 draws with translated pipelines (0 skipped, 0 with PC pipelines), 1024 dispatches (0 skipped); last memory sample13987 MB committed by the process; video memory 6115 MB local, 4651 MB non-local.
Limits of coverage
- This PR adds Python/DXC tooling, HLSL fixtures, and a CI job (
.github/workflows/ci.yml,scripts/inspect_dxil_semantics.py,scripts/test_dxil_semantics.py,tests/data/dxil_semantic/*.hlsl;0Rust production-code changes); all7tests inscripts/test_dxil_semantics.py --require-dxcpassed3/3against installed DXC1.9.2609.5on Windows 11. - The 60 s retail smoke confirms non-regression of the unchanged runtime binary at this commit (single-run frame/commit delta vs. cached parent reflects normal startup variance, not this PR).
AI disclosure: test execution and report drafting assisted by Google Antigravity (Gemini 4 Neon).
|
No open or merged PR adds a DXIL semantic inspector. #2553 (same issue #2541) adds manifests and a hash checker for AI review: Claude Code (Claude Opus 5.5), diffs read only, not built or run; not checked by a human. |
Part of #2541. This adds a read-only baseline for comparing DXC and XCL DXIL container semantics; it does not change the emitter.
What is in it
scripts/inspect_dxil_semantics.pyemits schema-versioned JSON with shader stage/model, DXIL module and validator versions, entry-point flags and thread-group dimensions, SFI0 feature flags and DXC feature names, calleddx.opnames/opcodes/overloads/counts, resource bindings and handle annotations, and target layout.disassembler_dxc_versionidentifies the inspection tool, not the container producer.tests/data/dxil_semantic/compute_store.hlslis a minimal compute reference with an 8×4×2 group,WaveActiveSum, and one byte-address UAV store.resource_bindings.hlslexercises a constant buffer, two-element texture array, unbounded texture array, sampler, UAV, and legacy TBuffer across register spaces 3, 12, and 15.scripts/test_dxil_semantics.pycompiles both fixtures with DXC and checks the expected semantic fields, including entry-point metadata and all six resource bindings and counts. It also checks that invalid explicit andXCL_DXC_DIRoverrides cannot fall back silently and that multi-entry containers are rejected. CI requires DXC and fails if it is absent.Tested
e1d84b7; current upstream main is08db802. The intervening changes are confined toREADME.mdandcrates/xcl/src/gpu/recomp/{dxc.rs,emit.rs,link_tests.rs,mod.rs}and do not overlap this PR's inspector, fixture, or CI workflow.1.9.2609.5fromXCL_DXC_DIR.python -B scripts/test_dxil_semantics.py --require-dxc --dxc C:\Users\Luma\Documents\ChatGPT\XCL-test\dxc-1.9.2609\bin\x64\dxc.exe: 7 passed, 0 failed, 0 skipped. DXC compiled both fixtures and-dumpbininspected them successfully.1.8.2502.11atC:\Program Files (x86)\Windows Kits\10\bin\10.0.26100.0\x64\dxc.exeand Vulkan SDK DXC1.9.0.5399atC:\VulkanSDK\1.4.357.0\Bin\dxc.exe: 7 passed, 0 failed, 0 skipped on each toolchain. CI requires DXC and fails if it is absent.python -B scripts/inspect_dxil_semantics.py --dxc C:\Users\Luma\Documents\ChatGPT\XCL-test\dxc-1.9.2609\bin\x64\dxc.exe ..\dxc-output\compute_store.dxil: emitteddisassembler_dxc_version1.9.2609.5,cs_6_6, DXIL 1.6 / validator 1.9,8×4×2, SFI00x4000,waveActiveOp.i32opcode 119,rawBufferStore.i32opcode 140, and the UAVu0binding with byte format and read/write dimension.cb2,space3andt1,space3entries. Independent DXC probes then found that a TBuffer appears astexturein DXC's type column andtbufferin its dimension column, and that DXC can concatenateunboundeddirectly to the register/space token. The final parser reports all six bindings, includingt2,space12as TBUFFER, the texture array count of 2, andt11,space15with countunbounded, on all three DXC versions.vs_6_6vertex shader (7dx.opgroups, 5 bindings) and aps_6_6pixel shader (9dx.opgroups, 0 bindings). DXC-dumpbinaccepted both. No title data or containers were uploaded.git diff --check: passed.Regression run
Not required: this changes scripts, a test fixture, and CI only; it does not change runtime code.
Not tested
AI use
OpenAI Codex (GPT-6.2-sol) wrote the inspector, fixture, test, and CI step, and ran the DXC/Python verification described above.