Repository navigation
D3D12.X: preserve used-pipeline key on RT-gated compute stand-ins - #2755
Saksukella wants to merge 1 commit into
Conversation
luckyteagirl
left a comment
There was a problem hiding this comment.
The used-pipelines.txt capture path described here requires shared stand-in shells. At 4bb6b30, maybe_rt_gated_compute_pso calls submit_gated(..., key) only when standin::shell returned a nonzero driver; with XCL_SHARED_STANDINS=0 or console-shaped lists enabled, standin::enabled() is false and creation takes the raw standin_compute branch instead. A successful bind then has no pending key for resolve() to record. This is a scope limitation of the proposed workflow, not a new regression introduced by this patch; the new tests inject a key directly and do not cover creation with shells disabled.
Could the PR description name the shared-standin prerequisite for the XCL_RT_GATE=hold → --used-only workflow? That would keep users from treating a capture in either non-shell configuration as complete. Exact-head source review assisted by Codex (GPT-6.2 Sol and GPT-6.2 Astra); I did not run a non-shell title capture.
|
Good point @luckyteagirl — updated the PR description to state explicitly that the |
|
I tried to see the new behaviour on a retail title on Windows / RDNA2. No RT-gated key reached Setup: RX 6800 (driver 32.0.21045.5002), Windows 11 Pro 26200, release. This head sits on Method: each run started from an empty
With a full file (1,892 lines from earlier runs) neither tree added a line, so that comparison says nothing. Reading: Tests on the merge, debug: Not tested: this exact head on its own base ( AI use: Claude Code (Claude Opus 5.5) merged and built the trees, ran the title, computed the keys from the logs and wrote this comment. Update: full lib suite on this exact head ( |
|
I checked the first actual bind of a gated compute pipeline on head On the parent, the key remained absent after the bind and the assertion failed. On the PR head, the expected key appeared in AI use: OpenAI Codex with GPT-6.2 Astra constructed and ran the synthetic parent/head comparison; Codex coordinated and prepared this report. |
What is in it
crates/xcl/src/hle/d3d12x/pso_async.rs:key: u64intosubmit_gated(standin, driver, key)instead of hardcodingkey: 0.XCL_RT_GATE=hold,resolve()/resolve_for_bind()already callp.note_use()(used::note(p.key)), so storing the real pipeline key letsused-pipelines.txtrecord bound RT compute pipelines for targeted offlinexcl shaders ... --precompile --pipelines --used-only --only csruns before switching toXCL_RT_GATE=auto. Prerequisite: this capture path applies when shared stand-in shells are enabled (defaultstandin::enabled() == true; disabled underXCL_SHARED_STANDINS=0or console-shaped lists, wheremaybe_rt_gated_compute_psotakes the rawstandin_computebranch without apso_asyncentry).submit_gated_maps_driver_without_pending_or_enqueueto assert non-zero key preservation viaentry()without touching the on-diskused-pipelines.txtcache.crates/xcl/src/hle/d3d12x/real.rs:single_shader_key(hash)(matchingshaders_key(&[blob])without cloning the shader bytes) and passsingle_shader_key(record)inmaybe_rt_gated_compute_pso.a_key_follows_the_shaders_and_their_order_and_is_never_zeroto verifysingle_shader_key(fnv64(&a)) == shaders_key(&[a]).amd-dev(wheresubmit_gated/XCL_RT_GATElive).Tested
32.0.32029.2010), 24-thread x86_64 CPU, 32 GB RAM, Windows;rustc 1.100.0 (0ef1bc386 2026-11-09); debug (tests) and release (xcl.exe).cargo test -p xcl --lib submit_gated_maps_driver_without_pending_or_enqueue: 1 passed, 0 failed (0.00s).cargo test -p xcl --lib a_key_follows_the_shaders_and_their_order_and_is_never_zero: 1 passed, 0 failed (0.00s).Regression run
Not tested
AI use
pso_async::submit_gated/used::notereachability, writing the zero-allocation key helper and unit tests, and running local tests and smoke verification. All diffs and measurements were verified locally on hardware.