Repository navigation
Conversation
A draw whose pipeline is not ready within the frame's budget is dropped and drawn again next frame. A dispatch may not be drawn again: the title runs some compute passes once, when a scene changes, and what they leave is read for as long as the scene lasts. A compute program met for the first time took 4.4 s to make on a 16 GB machine; its one dispatch was dropped after the half second of budget, and the windows of the room before stayed blended over the picture for minutes (run 195). A compute pipeline now waits for its own making, whatever the budget; a draw still waits within the budget. The pipeline library has it on the next run. `VICTORY_PIPELINE_COMPUTE_WAIT=0` restores the old behaviour. Ported from fxceless/victory-fork a42b627 (pull request #1312), GPL-3.0-or-later.
…ispatch With VICTORY_PIPELINE_COMPUTE_WAIT on (the default) a compute dispatch makes its pipeline on the spot, however long that takes. With an empty cache the first cutscene met 457 compute programs in one frame at about a second each: the frame did not end for over 30 s and the title's own hang watchdog stored to address 0 (+0x23cf683, #1420). A frame now waits for such pipelines up to VICTORY_PIPELINE_COMPUTE_WAIT_MS (8,000 by default, summed over threads); after that its dispatches wait within the frame's budget as with VICTORY_PIPELINE_COMPUTE_WAIT=0. The first 600 frames (loading) still make theirs whatever it costs.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Builds on #243. This branch is #243's commit plus one more, so merging this lands both. If #243 lands first, this one is only the second commit.
Problem
With #243, a compute dispatch waits for its pipeline however long that takes. With an empty cache, the first cutscene met 457 compute programs in one frame, at about a second each. That frame then ran for more than 30 s. The title's own hang watchdog fires after 30 s and stores to address 0 (
+0x23cf683), which crashes the title. This was reported on fxceless/victory-fork as #1420.Fix
The fix is armin's commit from fxceless/victory-fork#1450 (still open there). The author is kept.
VICTORY_PIPELINE_COMPUTE_WAIT_MS, summed over threads. The default is 8,000 ms, which leaves room under the watchdog's 30 s for makes that other threads have already started.Conflict resolution here: #243 has no 600-frame rule, so the condition is now
compute_waits() && (early || compute_room(frame)). WithVICTORY_PIPELINE_COMPUTE_WAIT=0, a dispatch waits within the budget exactly as before. Onlypipeline/make.rschanges.Verification
On Windows 11, RTX 5080:
cargo clippy -p victory-gpu --all-targets -- -D warnings: nothing inmake.rs. The errors it gives are in other files and are onmaintoo (clippy: the workspace passes clippy with -D warnings again #265 fixes those).cargo test -p victory-gpu --lib pipeline::make: 6 pass, andpending_pipeline_is_recorded_for_the_next_launchfails. It fails the same way on fix(gpu): a dispatch waits for its compute pipeline until it is made #243's head without this commit.cargo fmt --checkwas not used: it already fails onmain(inapps/victoryand in this file), so I kept the surrounding style.Not run in game on this branch.
AI use: Claude Code (Claude Opus 5.5) ported the commit, resolved the conflict with #243, ran the checks above and drafted this description.
🤖 Generated with Claude Code