Repository navigation
Conversation
DispatchX(x, y, z, flags) dropped its flags. With USE_THREAD_DIMENSIONS (0x20; 0x8020 with the wave32 bit) x, y, z are thread counts: the console launches ceil(count / numthreads) groups and leaves the lanes past the count out of EXEC. XCL launched the counts as groups: 32-64x the groups for the retail title's BVH builder (its rehydration and reload passes pass node and primitive counts), past D3D12's 65,535 groups for a large mesh, and every extra thread of the unguarded Box32/Box16 rehydration shaders wrote outside its node array. The flags now reach the dispatch (also one put off to the submit). With 0x20 the counts become whole groups of the pipeline's console numthreads (kept with its user SGPRs at creation); a pipeline whose group shape is not known is not launched, skipped and counted as an untranslated one. The thread count of an axis that does not end on a whole group goes to io slots 114..116 (IO_THREAD_LIMIT), where the compute prologue will leave the lanes past it out of EXEC in a following change: until then the last group still runs whole. Each kind of flags is logged once. Part of a stack: EXEC masking of the last group follows. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Intersect the existing entry EXEC mask with DispatchX thread bounds in a separate compute entry. Keep ordinary compute emission unchanged. Cover excess-lane stores in 1-D, 2-D and 3-D, split and native wave modes, and ordinary translation byte identity. Runtime selection and precompile integration are separate work. Assisted-by: Codex (GPT-6.1-Sol)
Assisted-by: Codex (GPT-6.2-Sol)
|
Tested Clean detached
11 exercised passes, 0 failures, 0 ignores, 1 explicit skip. The Arc probe confirmed the actual adapter and an 8–32 wave-lane range. Both native GPU children and the shared lock wrapper exited 0. The executable hash matched before, under, and after the lock. Not tested Full wrapped command-list recording, submission and replay, runtime selection of a split PSO, retail smoke, and the full workspace suite. AI use T3 Code / Codex ( |
|
AMD run (runtime selection on AMD was untested), with an RTX 3060 in the same PC. The 13 new tests pass on both, and the native wave64 one ran on the RX 9070 XT. One thing first: applied on today's Doesn't build on current
Tested: at the PR head
New and ok on both: Not tested: the masked dispatches in a title, release, Intel. AI use: Claude Code (Claude Opus 5.5) ran the tests on this machine and wrote this report. |
|
RTX 3060 12 GB, retail title, 300 s: clean, but 1 722 frames against 2 234 on Both exit 0x0 with no device removals or crashes. Peak commit is 34 649 MB against 38 242 MB, and peak local video memory 15 762 MB against 18 893 MB. Both are lower because this run stopped earlier. Presenting stops at ~92 s here, against ~338 s on Regression run main: this PR: Edit: one more run of each, same setup, warm caches. This PR's second run stops at ~94 s again (1 766 frames, exit 0x0, no device removals or crashes, peak commit 34 597 MB). But RTX 3060 12 GB (driver 581.80), i9-14900KF, 64 GB RAM, Windows 11 26200. AI use: Claude Code (Claude Opus 5.5) built both commits, ran the title, read the logs and wrote this report. |
|
Thank you @JJAutoCompare, @DarkPanda69 and @Anon64. Added to the description. The native-wave64 run on the RX 9070 XT and the Arc readback were the coverage this needed. @DarkPanda69, you're right about the build: AI use: Claude Code (Claude Opus 5.5). |
|
AnyPS5 #26196 shows why it matters that a first visit does not compile on the caller before the deferred path takes it. For your partial DispatchX variant, use a fresh cache and then one warm-cache run. Record worker and caller build counts and the number of partial calls skipped. That separates a faster preparation path from silently dropping work, without assuming the graphics and compute mechanisms are interchangeable. |
|
@akimfomin, thanks. By construction, the masked variant never builds on the caller: it's queued with So the numbers that separate faster preparation from dropped work are the count of skipped partial calls on a fresh cache against a warm one. That's a fair ask. We'll add it with the next in-title run on the rebased head, rather than hold the rebase for it. AI use: Claude Code (Claude Opus 5.5). |
|
Source review of head The compute translator tries per-lane first and, on refusal, can successfully make the base pipeline with the per-instruction direct translator. But Please make registration follow the actual compiled translation, including its cached form, rather than the per-lane preference flag. For partial limits with no masked implementation available, This is a source-traced finding; I did not run that regression or a GPU test. AI use: Codex (GPT-6.2 Sol) checked the call path and drafted this review; Codex (GPT-6.2 Astra) independently audited the translator and fixture. |
|
@thehollowedone, confirmed, thank you. The same path is in the rebase onto current The fix will go in with the rebase, along the lines you describe:
AI use: Claude Code (Claude Opus 5.5) checked the path at the rebased head and wrote this reply. |
Stacked on #3015 (itself stacked on #2610); review only the last commit,
d8a1f5f1.What is in it
A partial thread-dimension
DispatchXselects the masked direct-DXIL compute pipeline. Whole groups keep the original pipeline. A 200-second diagnostic run counted 2,999 partial-group calls out of 3,009 thread-dimensionDispatchXcalls in the last logged sample, across four pipelines. The first appeared at world load.Only the first partial dispatch queues the variant. If the list can defer the dispatch, it replays with the same dimensions at submit. Title and submit threads wait for the variant without doing the driver build themselves. A build worker can take an unstarted dependency inline to avoid deadlock when the worker pool is full. For a split variant, the worker prepares the pieces and the whole-program scratch fallback. If the variant fails or exceeds the wait budget, the call is skipped.
Related #1751 / #1833.
Tested
At this head,
d8a1f5f1, release,XCL_NETWORK=0, RTX 5090 (621.24) and the Ryzen 7 9800X3D's AMD Radeon iGPU (RDNA2), Windows 11:cargo test --workspace --no-fail-fast -- --test-threads=4(RTX 5090): 1,438 passed, 4 failed, 47 ignored, 27 SKIPPED. The 4 failures are the knownfuzz_validate_and_gpu_0..3(DXIL GPU fuzz tests reproducibly fail with E_OUTOFMEMORY on RTX 5060 #1905). The SKIPPED includedispatchx_native_wave64_masks_excess_lanes(no native wave64 on this GPU).gpu::dxil::dispatchx_tests::: 7 passed on both adapters. The native-wave64 case ran and passed on the iGPU.hle::d3d12x::pso_async::(the worker queue): 19 passed on both adapters.224706a6: bypassing the selection returned the original PSO for a partial group and failed the regression test. With selection, a GPU readback had 100 expected writes and 28 untouched elements.DispatchXflag kinds the title used were both partial groups and took this path (0x8020, a 1×1×1 group with thread limits[1,0,0];0x20, 45 threads launched as 1 group with limits[45,0,0]). There were 0 masked-pipeline-unavailable errors and 0 skippedDispatchX. The code logs the flags line once per kind and nothing per variant selection, so the number of masked dispatches isn't in the log.Tested by others (thank you):
d8a1f5f1: the targeted CPU tests and the Arc runtime selection with a live partial-group readback passed (11 passed, 0 failed). D3D12.X: build masked pipelines for partial DispatchX groups on workers #3066 (comment)maindoesn't build (compute_containernow takes aComputeBuild). D3D12.X: build masked pipelines for partial DispatchX groups on workers #3066 (comment)main2c717a04: 0 removals and 0 crashes on both, but 1,722 frames against 2,234. This head is on an older base withoutmain's startup preparation, so it isn't like-for-like. D3D12.X: build masked pipelines for partial DispatchX groups on workers #3066 (comment)DispatchXcalls selected the worker-built masked direct-DXIL PSO. The last-group EXEC words written at the masked entry were00000000_01ffffff(2,841 threads, 25 of 64 active) and00000000_7fffffff(927 threads, 31 of 64), with full EXEC in the groups before. Reproduced at a second frame. The skinning input kept its value through both, and the vertex stores read back bit for bit. D3D12.X: a DispatchX with thread dimensions launches whole groups #2610 (comment) D3D12.X: a DispatchX with thread dimensions launches whole groups #2610 (comment)Not tested
Full wrapped-list replay; the in-title first-use wait and the rendered result of the masked dispatches (the frames are grey on this tree); a count of masked dispatches in the title; runtime selection on AMD in the title. The HLSL and per-lane paths are outside this change.
Regression run
main(08db8020, the base under #2610, #3015 and this change; the same block as in #2610 and #3015):This PR (
d8a1f5f1):Both: the retail title,
-Seconds 200, RTX 5090, a copy of the same precompiled cache, the same scripted input, full-size frame dumps. Themainrun used a never-used exe name; this head's run reused a warm one.AMD testing requested
Run from this source checkout in PowerShell with DXC available. Report the adapter, driver, and whether any focused case printed
SKIPPED.AI use
Codex (GPT-6.2-Sol) wrote the change, tests and description. Claude Code (Claude Opus 5.5) independently reviewed and validated the change at this head on both adapters, ran the smoke and in-title check, and finalised this description.
🤖 Generated with Claude Code
https://claude.ai/code/session_013oPUFCA9W9F8Qb5MPK33bR