D3D12.X: drop overflow pooled resources and preludes outside bind locks #2710
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!2710
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-2710"
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?
@Saksukella on GitHub · 2026-11-26 07:55 UTC · original
Saksukella:fix/bind-release-drop-outside-lock→amd-dev· +16 −0 · 1 files · 1 commits · openWhat is in it
crates/xcl/src/hle/d3d12x/bind.rs(release_allocator_res): collect overflowFREE_RES,FREE_IO, andFREE_PRELUDEentries into localVecs and drop them only after releasing the pool mutexes.FREE_PRELUDEreachedFREE_PRELUDE_CAP(256), dropping an excessPreludeEntryinside theFREE_PRELUDE.lock()scope released its adoptedID3D12CommandAllocator, re-enteringreal::alloc_release->console_list::allocator_reset->bind::release_allocator_res->FREE_PRELUDE.lock()on the same thread (re-entrant self-deadlock).amd-dev(whereFREE_PRELUDE/release_allocator_reslive).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 bind::tests -- --test-threads=1: 41 passed, 0 failed (0.43s).XCL_THREAD_DUMP_AT=62) had previously caught the exactbind::release_allocator_res->real::alloc_release->console_list::allocator_reset->bind::release_allocator_resdeadlock att=56s; with this fix the deadlock is eliminated completely.Regression run
Not tested
AI use
FREE_PRELUDEre-entrant deadlock, editingrelease_allocator_res, and running unit tests and smoke verification. All diffs and results were reviewed and verified locally on hardware.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.