Repository navigation
Conversation
|
merge-check
|
|
merge-check
|
|
Correction, December 1. On this RTX 4090, Setup: RTX 4090 24 GB, NVIDIA 621.40, 32 GB RAM, Windows 11 build 26300, NVIDIA shader heap 2048 MB (#2590).
Not tested: this commit on AI use: Claude Code (Claude Opus 5.5) built the trees, ran the replays and wrote this. The person running these tests checked it and asked for it to be posted. December 1 correction drafted with Codex (GPT-6) after checking the Git ancestry and replay logs. |
There was a problem hiding this comment.
[P2] Recheck whole-form readiness before recording the split chain
If the background build completes between the two chain.whole.ready() calls in execute_indirect, the second check sees Some(Ok(_)) but still records the split chain. For a dispatch that exceeds the slicer’s round budget, the split commands do no work. Before this PR, a successful build observed at this point let the tail command execute that dispatch.
Keep the fast path and replace the second check with:
match chain.whole.ready() {
Some(Ok(_)) => return Ok(Indirect::Whole),
None => { queue_whole(&chain); }
Some(Err(_)) => {}
}I checked that the patch applies to 49eb78e. In an isolated Rust harness, the completed-build case failed before the change. All three cases (completed, pending, and refused) passed afterward. The XCL suite and GPU tests were not run.
Codex assisted with the review, patch, and isolated tests.
|
@Kalmarv a run of this PR on the RTX 4080 16 GB (621.40), i9-12900K, release,
So it does bring the frame rate back (2.5 to 2.7 against 0.77, close to the 2.15 to 2.30 before #3499), but half of the runs with it lost the device about 140 to 150 s after the first frame, which none of my runs of My reading, not verified: the switch from the chain to the whole form happens mid-frame once the whole form becomes ready, and the first indirect dispatch on the whole form is where it hangs. If you have a switch to force the chain or the whole form from the start, I can run both. AI use: Claude Code (Claude Opus 5.5) made the runs and wrote this. |
|
Correction (edit of the report below): the device removals are not specific to this PR. Five more
AI use: Claude Code (Claude Opus 5.5) ran the runs, read the logs and drafted this correction; I checked it. Test report, RTX 3080 10 GB: with this PR a retail title draws its first in-engine cutscene, which Setup
Results
Against the other reports here: these runs end at the opening of the first in-engine cutscene. That is where the cold-cache stall on #505 happens too (118–126 s, with a title thread waiting in Not tested: a raised NVIDIA shader heap (#2590), which would tell whether the removals are #2403; the whole test suite, AI use: Claude Code (Claude Opus 5.5) built the trees, ran the tests and the runs, read the logs and drafted this; I watched the runs and checked it. |
|
How far the RTX 4090 runs with this PR got, to answer cj-tomlin's question above: past the load into the 3D scene, and on in it until the 600 s limit. With the NVIDIA shader heap at 2048 MB (#2590), none of them ended with the silent
AI use: Claude Code (Claude Opus 5.5) ran the replays, read the logs and wrote this. The person running these tests checked it and asked for it to be posted. December 1 correction drafted with Codex (GPT-6). |
|
@Kalmarv I checked the first
On the head, forcing the refusal case sent all 24 groups through each split piece again. Every completed readback preserved both guard words and returned the expected group-ID sums The fixture controls readiness directly. I didn’t test asynchronous readiness timing or reproduce the reported physical-GPU device removals. I used Codex GPT-6.2 Sol to write the fixture and run both revisions. A separate GPT-6.2 Sol agent verified the source and raw WARP logs. Codex GPT-6.2 Astra drafted this comment. I reviewed and approved this comment before posting. |
|
Test report: in-world frame rate on NVIDIA, Tested
Not tested
AI use
|
PR xcl-dev#3499 (c9aa9f8) routed Dispatch-only ExecuteIndirect of split compute PSOs through the split chain even after the background whole form had finished building. That claimed the full split scratch budget and recorded XCL_SPLIT_INDIRECT_ROUNDS rounds of every piece plus UAV barriers on every indirect dispatch, regressing world frame rate 2-3x across multiple GPUs. Return Indirect::Whole from dispatch_chain::execute_indirect once chain.whole.ready() is Some(Ok(_)) so bind.rs dispatches the single whole-form ExecuteIndirect immediately, while keeping the split chain for cold builds while the whole form is still pending or if the driver refused it. execute_indirect checks again before recording the chain and returns Indirect::Whole when the build finished in between: the chain has no tail for groups past the slicer's rounds, so such a dispatch was left out while counted as run. Also queue the whole form in dispatch_chain::build for programs already recorded in the indirect-use journal, as before xcl-dev#3499 only when the whole form's driver blob is already on disk (whole_blob_path, the DirectConstants chain root compute_container loads it under), so warm runs load the cached whole form before the first indirect dispatch and a cold driver cache does not compile every journalled whole form at pipeline creation. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
49eb78e to
ba8592a
Compare
|
Test report for #3528 at head
Retail title, in the world. Release builds of
Hardware: NVIDIA GeForce RTX 3090 24 GB (driver 621.24, wave32 only), Intel Core i5-10600K, 32 GB, Windows 11 Home build 26300, rustc 1.100.0. Tool and model: Claude Code (Claude Opus 5.5), results checked by me. |
|
merge-check |
|
merge-check
|
|
merge-check AI-written and posted by Foniass without a human check of each point. |
|
A third card, and one number I have not seen in the reports above: the peak video-memory overshoot falls as well. Setup
So the control is stable to within 2.5 s across three runs, and the PR is 1.4-1.9× faster to the same 1500-frame mark with a consistently lower peak overshoot. The dispatch count per 2 s goes up, which I read as the intended effect rather than a regression: a whole-form What it does not fix here: the frame rate after the world loads stays around 1-2 fps either way. On this card the title's texture pages alone come to 19,393 MB against the 15,152 MB budget Windows gives the process, so the driver pages continuously; that is a 16 GB limit, not something this PR can move. The gain is in how much of the load completes before that plays out. This is consistent with the reports above in one respect and not another: a clear win on a 10 GB card, a small one on a 24 GB one, and a clear one here — plausibly the cards where memory pressure is highest benefit most. AI use: an agent ran the builds and the runs and wrote this comment. |
|
One implementation detail for Foniass's cache review at head If the disk key is made driver-specific, carry one key/path helper through all three call sites. Changing prefetch alone would miss stale blobs in runtime; changing runtime alone would stop it finding offline-prepared blobs. XCL already computes an adapter/driver identity and exposes it to preparation. A focused regression can assert that preparation and runtime derive the same path for one identity, different identities derive different paths, and a legacy unkeyed file alone cannot trigger prefetch. If identity is unavailable, the disk path can be absent and the ordinary build path still works. This is a source-level implementation suggestion; I did not run a build or test. AI use: OpenAI Codex (GPT-6.2 Sol) traced the cache call sites and checked Microsoft's D3D12 contract. |
Summary
Fixes the 2–3× world frame-rate regression introduced by #3499 (
c9aa9f8a2), bisected and diagnosed by @throny, @tiagonleal, @CharlyRien, and @bmjask.Root cause:
dispatch_chain::execute_indirectalways routed Dispatch-onlyExecuteIndirectcalls of split compute PSOs through the split chain — claiming the full split scratch budget (256 MiB), running the slicer dispatch, and recordingXCL_SPLIT_INDIRECT_ROUNDS(default 16) rounds of every piece plus UAV barriers — even after the background whole form (chain.whole) had finished building.Fix:
dispatch_chain::execute_indirect, returnOk(Indirect::Whole)immediately oncechain.whole.ready()isSome(Ok(_))sobind.rsissues a single whole-formExecuteIndirectwithout claiming split scratch or recording multi-round piece chains.chain.wholeis still building (None) or if the driver refused the whole form (Some(Err(_))), preserving D3D12.X: indirect dispatches of a split program run its direct pieces #3499's cold-build and zero-indirect-variant behavior.dispatch_chain::build, immediately queuequeue_whole(&chain)for programs already recorded inEARLIER_INDIRECT_USEDso warm runs load the cached whole form onxcl-pso-wholebefore the first indirect dispatch.Regression run
Baseline (
main):PR head:
Tested
cargo test -q -p xcl --lib hle::d3d12x::real::dispatch_chain::tests -- --test-threads=1on Windows 11 + RTX 5070 Ti: 16 passed, 0 failed, includingindirect_prefers_whole_only_once_built_ok(pending / OOM retry / built Ok / driver-refused Err) andan_indirect_dispatch_runs_its_chain_without_any_whole_form(verifying transition fromIndirect::Ranwhile building toIndirect::Wholewithout binding the split chain oncechain.wholeisOk).49eb78efbvs91244db94): 1693 frames (60/60/60 per 2 s), 0 device removals, 0 crashes, 16774 MB peak commit.Not tested
cargo test --workspacelocally (covered by CI).AI use
dispatch_chain.rs/bind.rs, drafting the fix and unit test updates, running local tests and smoke, and writing this description.