D3D12.X: record first use of synchronously created compute PSOs #2409
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!2409
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-2409"
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?
@ettehn on GitHub · 2026-11-25 18:02 UTC · original
ettehn:codex/pso-manifest-sync-first-use→main· +360 −11 · 6 files · 2 commits · openStacked on #2096. This PR's own commit is
1ee46bd, on top ofb6a294d(the #2096 patch rebased ontomainb49be183).A synchronously created compute pipeline could miss its first-use record, leaving milestone precompilation with an incomplete prefix. The follow-up records first use for eager and ready compute pipelines while preserving the existing used-pipeline history.
What is in it
useevent per pipeline across repeated binds, including the current non-waitingSetPipelineStatepath.Tested
cargo build --workspace --offline --locked -j 2passed.cargo test --workspace --offline --locked -j 2 --no-fail-fast -- --test-threads=1 --nocapture: 1,436 passed, 4 failed, 47 ignored, with 25 explicit GPU skips in the pass count. The four DXIL fuzz seeds (70, 545, 1019, 1507) failed withCreateComputePipelineStatereturning0x8007000Eon both this branch and cleanmainb49be183.gpu_compute_e2e: seven ran and passed; one reported a heap-window skip. Separate release runs recorded one first-use event for cold eager, warm eager, and lazy creation. Tracing off produced no manifest.Regression run
Windows release, same retail title and 20-second startup run, no scripted input. XCL networking was disabled. Each run used a fresh XCL data/cache directory.
Main:
PR:
Not tested
AI use
@DavidM1911 on GitHub · 2026-11-25 19:28 UTC · original
Verification on RTX 3060 Ti (Windows 11), branch merged with current
main:cargo test -p xcl --lib: 1038 passed, 1 failed in one parallel run; the failing test passes on a single-threaded rerun (1039/0). Intermittent single-test flake / 0xc0000005 abort under parallel scheduling — tracked in #1978; clean on single-threaded rerun.Thanks!
@luckyteagirl on GitHub · 2026-11-26 07:59 UTC · original · reviewed
At head
cd9fb4d6bf752c655a196b4e573d21ae5c908537,READY_COMPUTEis keyed only by the raw PSO address. The finalpso_releasecalls the original COMReleasefirst (real.rs:1644-1648) and only then callsforget_pso, which removes the new ready entry (real.rs:1753-1754). If thread A'sReleaseof PSO A returns zero and pauses, thread B can create a synchronous compute PSO B at the freed address and register its key (real.rs:5068-5073); A's late cleanup then erases B's key. B's first bind will be absent from theXCL_PSO_MANIFEST=1output. Could cleanup be tied to the PSO generation/registration being released, or synchronized across final release and new registration so an older release cannot remove the newer entry? A small address-reuse interleaving test would cover the new map.This is a source-derived, opt-in manifest race, not a native reproduction. The broader address-keyed cleanup pattern predates this PR; the missing ready-compute first-use event is new here. AI use: OpenAI Codex (GPT-6.2 Sol) found the interleaving; I checked the exact-head release, creation, and manifest paths before posting.
cd9fb4d6bfto1ee46bda18@ettehn on GitHub · 2026-11-26 08:30 UTC · original · edited 2026-11-26 10:23 UTC
@Anon64 Thanks for offering to retest on your RTX 3060 in #2096. The updated head is
1ee46bda18efbc167f0dbaecc78a067766df2963. If you still have time to run it, a first-use check withXCL_LAZY_PSO=0would help. The paired retailxcl-smokeruns are now in the PR description, and both required GitHub checks are green.Thanks to luckyteagirl for spotting the address-reuse race. This head records the registration before COM release and removes it only if the same registration is still present. The deterministic regression fails with address-only cleanup and passes on this head. Windows CI also passed.
Assisted by OpenAI Codex (GPT-6.2 Sol).
View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.