fix(victory-gpu): fix shader cache hit tracking, warm-bad pipeline skip, flush rollback and VICTORY_LATE_WAITS #28

Closed
SAZLEIB wants to merge 1 commit from upstream-pr/28 into main
SAZLEIB commented 2026-11-25 23:51:46 +00:00 (Migrated from github.com)

Imported from avatarmanz/VIctory-7900XTX. Originally posted by SAZLEIB on 2026-11-25T23:51:46Z.


Summary

  • Shader cache hit detection (#33): Use the per-call ran flag in precompile / host_shader_checked instead of comparing the global MISSES counter across parallel threads, and update unit tests (translations_come_back_from_the_cache) to verify the cache-hit boolean.
  • Known pipeline flush resilience (#43): Restore unwritten batch bytes and the added counter back into BOOK in memory if writing known-shaders.bin or known-pipelines.bin fails during flush().
  • Bad pipeline filtering (#61): Add is_bad(key) to load warm-bad.txt (with VICTORY_IGNORE_BAD_PIPELINES=1 bypass) and skip building host pipelines marked as bad in Pending::make().
  • Late wait condition (#50): Fix the inverted boolean check for VICTORY_LATE_WAITS=1 in frame::wait().

Notes & Investigation

  • Reviewed pipeline/make.rs (Queue / was_slow / slow_now promotion behavior), .github/workflows/ci.yml (diagnostics test coverage), and host.rs / pipeline.rs / texture.rs (VICTORY_BVH_BUILDER, VICTORY_TEXTURE_NO_WAIT, and device-removed diagnostics).

Verification

  • cargo check --workspace --profile diag --locked
  • cargo test --workspace --features victory-gpu/diagnostics --no-run --locked
  • cargo test -p victory-gpu --lib --features diagnostics --locked (373 passed, 34 ignored; pre-existing environment failure in descriptor::host::tests::views_are_made_beside_the_heap_and_copied_in)
<!-- greyfinch-sync:avatarmanz/VIctory-7900XTX:issue:6616198090 --> Imported from [avatarmanz/VIctory-7900XTX](https://github.com/avatarmanz/VIctory-7900XTX/pull/28). Originally posted by [SAZLEIB](https://github.com/SAZLEIB) on 2026-11-25T23:51:46Z. --- ## Summary - **Shader cache hit detection (`#33`):** Use the per-call `ran` flag in `precompile` / `host_shader_checked` instead of comparing the global `MISSES` counter across parallel threads, and update unit tests (`translations_come_back_from_the_cache`) to verify the cache-hit boolean. - **Known pipeline flush resilience (`#43`):** Restore unwritten batch bytes and the `added` counter back into `BOOK` in memory if writing `known-shaders.bin` or `known-pipelines.bin` fails during `flush()`. - **Bad pipeline filtering (`#61`):** Add `is_bad(key)` to load `warm-bad.txt` (with `VICTORY_IGNORE_BAD_PIPELINES=1` bypass) and skip building host pipelines marked as bad in `Pending::make()`. - **Late wait condition (`#50`):** Fix the inverted boolean check for `VICTORY_LATE_WAITS=1` in `frame::wait()`. ## Notes & Investigation - Reviewed `pipeline/make.rs` (`Queue` / `was_slow` / `slow_now` promotion behavior), `.github/workflows/ci.yml` (`diagnostics` test coverage), and `host.rs` / `pipeline.rs` / `texture.rs` (`VICTORY_BVH_BUILDER`, `VICTORY_TEXTURE_NO_WAIT`, and device-removed diagnostics). ## Verification - `cargo check --workspace --profile diag --locked` - `cargo test --workspace --features victory-gpu/diagnostics --no-run --locked` - `cargo test -p victory-gpu --lib --features diagnostics --locked` (373 passed, 34 ignored; pre-existing environment failure in `descriptor::host::tests::views_are_made_beside_the_heap_and_copied_in`)
avatarmanz commented 2026-11-26 07:31:42 +00:00 (Migrated from github.com)

Imported from avatarmanz/VIctory-7900XTX. Originally posted by avatarmanz on 2026-11-26T07:31:42Z.


Closed: contains changes unrelated to the title (the diff adds an ambient-light floor and a play.ps1 default, not the cache and flush fixes it describes), which this repo doesn't accept.

<!-- greyfinch-sync:avatarmanz/VIctory-7900XTX:comment:7185553846 --> Imported from [avatarmanz/VIctory-7900XTX](https://github.com/avatarmanz/VIctory-7900XTX/pull/28#issuecomment-7185553846). Originally posted by [avatarmanz](https://github.com/avatarmanz) on 2026-11-26T07:31:42Z. --- Closed: contains changes unrelated to the title (the diff adds an ambient-light floor and a play.ps1 default, not the cache and flush fixes it describes), which this repo doesn't accept.

Pull request closed

Sign in to join this conversation.
No reviewers
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
avatarmanz/VIctory-7900XTX!28
No description provided.