warm: scope warm-bad.txt by fingerprint, honor VICTORY_WARM_BAD=0 and --again (#280) #294
No reviewers
Labels
No labels
accessibility
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
question
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/Belobug--VIctory-Belobug-AMD!294
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-294"
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?
@BlueCatsz on GitHub · 2026-11-26 19:21 UTC · original
BlueCatsz:fix/warm-bad-fingerprint-and-retry→a-publier· +353 −28 · 5 files · 2 commits · merged 2026-11-26 22:30 UTCFixes #280.
Summary
Treats
warm-bad.txtconsistently acrossvictory warm(apps/victory/src/warm.rs) and runtime pipeline building (crates/victory-gpu/src/pipeline/make.rs), matchingwarm-done.txtwhile staying backwards- and forwards-compatible with older binaries:known::format_bad_entry,known::parse_bad_keys,known::fingerprint()):victory warm(apps/victory/src/warm.rs) and the runtime compiler-crash guard (pipeline::make::lost) record new entries as<32-hex-key> fp=<16-hex-fingerprint> <reason>(keeping the pipeline key in column 1 so older unmodified binaries reading the samewarm-bad.txtstill quarantine crashed pipelines safely).known::parse_bad_keysmatches<key> fp=<16-hex-fingerprint> ...(and<16-hex-fingerprint> <32-hex-key> ...for compatibility) against the currentknown::fingerprint(), so pipelines that previously crashed or hung are retried automatically after a driver or translator update.<key> ...) continue to apply regardless of fingerprint.#comments and blank lines inwarm.rs: Bothwarm.rsandpipeline::makeshareknown::WARM_BAD_FILEandknown::parse_bad_keys, ignoring blank lines and#comment lines instead of counting#or empty tokens as bad keys.VICTORY_WARM_BAD=0inwarm.rs: Shared viaknown::bad_list_disabled(). SettingVICTORY_WARM_BAD=0letsvictory warmignorewarm-bad.txtwhile still skipping pipelines already recorded inwarm-done.txtfor the current fingerprint.victory warm --againretry bad pipelines and document in--help: Extractedselect_pipelinesinapps/victory/src/warm.rsso--againretries bothdoneandbadpipelines, and updatedvictory warm --help(apps/victory/src/main.rs) to documentwarm-bad.txtfingerprint scoping,VICTORY_WARM_BAD=0, and--again.Verification
x86_64-unknown-linux-gnu):cargo --offline test -p xtask: 9 passed, 0 failed (includingpolicy::tests::repository_passes_policyandswitches::documented_switches_are_read).git diff --check: clean.windows-latestCI one7585d5(Scoped Run 45899040982):(Scoped workflow used to bypass untouched
a-publierblockers noted below.)victory&xtask): Strictcargo clippy -p victory -p xtask --no-deps --all-targets --locked -- -D warnings(Default) and--all-features(Diagnostics) both passed (0 warnings).victory-gpu):cargo clippy -p victory-gpu --no-deps --all-targets --locked(Default) and--all-features(Diagnostics) both passed when allowing the three untouched pre-existinga-publierlints (crates/victory-gpu/src/host/panel.rs:386clippy::missing_transmute_annotations,crates/victory-gpu/src/watch.rs:3626clippy::unnecessary_mut_passed, and--all-featurescrates/victory-gpu/src/texture.rs:46dead_code).victory: 23 unit tests (includingwarm::tests::select_pipelines_skips_current_bad_and_retries_on_again_or_new_fingerprint), 2census, 2translate_host_wave, and 1 end-to-end CLI test (apps/victory/tests/warm_bad.rs::warm_bad_fingerprint_override_again_and_help) — all passed, 0 failed.victory-gpu:pipeline::known::tests(5 passed, 0 failed) andpipeline::make::tests(7 passed, 0 failed).xtask: 9 passed, 0 failed.--all-features -- --test-threads=1):victory: 24 unit tests, 2census, 2translate_host_wave, and 1warm_bad_fingerprint_override_again_and_help— all passed, 0 failed.victory-gpu:pipeline::known::tests(5 passed, 0 failed) andpipeline::make::tests(7 passed, 0 failed).windows-latestCI on90e3770(Run 45881758143):victory-gpulib suite: 387 passed, 1 failed, 34 ignored (Default) and 436 passed, 1 failed, 34 ignored (--all-features), with all new tests passing; the 1 failure was untouchedpipeline::host::tests::depth_bounds_pipeline_loads_and_filters_draws(crates/victory-gpu/src/pipeline/host.rs:1464) on WARP, and workspace Clippy stopped early on untouchedcrates/victory-loader/src/descriptor_sites.rs:277(#246).AI Use
Prepared with AI assistance (Antigravity) and verified against the unit, CLI, and CI checks above.
@battledogegames-design on GitHub · 2026-11-26 20:38 UTC · original
Thanks, BlueCatsz. I independently validated the explicit retry behavior on Windows using synthetic pipeline records and real worker subprocesses. All five focused unit tests and nine subprocess selection checks passed.
One mixed-version compatibility issue reproduced: after this PR records a worker failure, its next default run correctly schedules zero pipelines. However, the unmodified base binary reading that same
warm-bad.txtreports1 bad; 1 to makeand retries the quarantined pipeline.The older reader interprets the first field as the pipeline key, while this PR writes the fingerprint first.
If rollback or shared caches across versions are supported, would preserving the pipeline key in column one and storing the fingerprint in a tagged field be preferable? Otherwise, documenting the compatibility boundary would help.
I'd also suggest updating
warm --helpto explain that--againnow retries crash-listed pipelines, not just previously completed ones.I support this PR rather than opening a competing implementation. The Windows subprocess tests add independent confirmation of the intended retry behavior.
AI-assisted investigation: Astra 6.2 (OpenAI).
@MamaLeVrai on GitHub · 2026-11-26 20:45 UTC · original
Tested on an RX 6950 XT 16 GB (RDNA 2), driver 32.0.21045.29003, Windows 11 build 26300, Rust 1.98.1, release, at
90e3770:cargo test --release -p victory-gpu --lib387 passed, 1 failed, 34 ignored. The one failure isviews_are_made_beside_the_heap_and_copied_in, which fails the same way oncd8dfc0on this card (fixed by #288).AI-assisted (Claude Code); no game data.
@BlueCatsz on GitHub · 2026-11-26 21:44 UTC · original
Thanks @battledogegames-design and @MamaLeVrai for the Windows subprocess and RX 6950 XT validation and feedback!
Pushed follow-up commit
e7585d5addressing both points:crates/victory-gpu/src/pipeline/known.rs,make.rs,apps/victory/src/warm.rs):known::format_bad_entrynow records<32-hex-key> fp=<16-hex-fingerprint> <reason>, keeping the pipeline key in column 1 so an unmodified base binary reading a sharedwarm-bad.txtcontinues to quarantine crashed pipelines on rollback.known::parse_bad_keysaccepts<key> fp=<16-hex> ..., legacy bare<key> ..., and<16-hex> <32-hex> ....victory warm --help(apps/victory/src/main.rs): Documentedwarm-bad.txtfingerprint scoping,VICTORY_WARM_BAD=0, and that--againalso retrieswarm-bad.txtentries.apps/victory/tests/warm_bad.rs): Addedwarm_bad_fingerprint_override_again_and_helpinvoking thevictorybinary end-to-end across--help,#comments/blank lines, column-1 entry formatting, default skipping,VICTORY_WARM_BAD=0,--again --used, and automatic expiration on a fingerprint change (VICTORY_WAVE_WIDE=0).Verification on
e7585d5cargo --offline test -p xtask(9 passed, 0 failed) andgit diff --check.windows-latestCI (Scoped Run45899040982):cargo clippy -p victory -p xtask --no-deps --all-targets --locked -- -D warnings(Default &--all-features): passed (0 warnings).cargo clippy -p victory-gpu --no-deps --all-targets --locked(Default &--all-features): passed when allowing the three untouched pre-existinga-publierlints (host/panel.rs:386,watch.rs:3626, andtexture.rs:46).Default tests:victory(23unit +2census+2translate_host_wave+1warm_bad),victory-gpu(known:5 passed,make:7 passed), andxtask(9 passed) all passed.Diagnostics tests(--all-features -- --test-threads=1):victory(24unit +2census+2translate_host_wave+1warm_bad) andvictory-gpu(known:5 passed,make:7 passed) all passed.AI-assisted follow-up (Antigravity).
@adrianmjim on GitHub · 2026-11-26 22:44 UTC · original
Checked by reading the code on a-publier
4eb6cfd, which includes this PR (merge70a2d5d); I did not build or run it. The cited files are unchanged sincee7585d5.What the fingerprint filter in
bad_keysnow means for the title on a-publier:cd8dfc0) the runtime honoured everywarm-bad.txtkey in every run (cd8dfc0make.rs:112-127). On a-publierbad_keysuses the same filter as warm (make.rs:114-126). So a tagged entry stops applying in the title as soon as the fingerprint changes. That happens on aTRANSLATOR_VERSIONbump, on a driver update, or on a run with different values for the switches inshader_cache.rs:112-126(for exampleVICTORY_WAVE_WIDE=0in the game when warm ran without it). Untilvictory warmruns again, the title compiles those pipelines itself.lostrecords the key again with the new fingerprint (make.rs:306). Each such key costs one stuck worker thread and one of the 128 guard slots (make.rs:143,:323).hung for 180 s. The runtime has no compile timeout. If the compile does not end, the worker stays inHostPipeline::new(make.rs:90). Every frame that draws with that pipeline waits inwait(make.rs:470) for whatever budget the frame has left. That is up to 500 ms, or up to 10 s for a pass over the screen (make.rs:367,:378). In the runtime onlylostwrites to the file, so this repeats on every launch untilvictory warmruns again and records it (warm.rs:115).make.rs:238). Any other compiler crash still ends the title process. warm workers compile with no guard (known.rs:354-355), so every warm crash is written asexit code: ..., and the file does not say which kind it was.warm-done.txthas the key under the current fingerprint. warm writes that line on success (warm.rs:111). Today no runtime code readswarm-done.txt.warm-bad.txtwritten before this PR has bare keys only (cd8dfc0warm.rs:96,make.rs:301). Those keep applying in warm and in the title, and nothing removes a line. Existing caches therefore still need the file deleted once.fingerprint()creates the host throughtranslation()before the host settings are hashed (known.rs:255,shader_cache.rs:89,descriptor/host.rs:1560,shader_cache.rs:146).Not checked: how often hang entries occur in practice, and whether they are endless hangs or slow compiles; no in-game run.