Preload: let the shader step print a real total (files or bytes scanned) #1423

Closed
opened 2026-11-28 19:41:56 +00:00 by github-bot · 1 comment
Owner

@⁠Jesper-Andersson on GitHub · 2026-11-28 19:39 UTC · original

Related: #869 shows a last-run total and an ETA in the launcher window. This asks for a real total from the shader step itself, so neither the console line nor that window has to rely on the previous run's count.

During -Preload (which runs shaders, then warm, then the library step), the shader step's progress line only counts up:

25000 shaders in the cache, 173 s

In apps/victory/src/translate.rs (precompile), the total isn't known while the step runs: the walk reads each file and finds shader containers as it goes. A last-run count goes stale exactly when it matters most, after a build where translator changes make most shaders new.

Suggestion: before the loop, count the candidate files (those may_hold_shaders passes, under MAX_FILE) and their total size. That's a metadata-only walk, with no reads. Then print progress against that, e.g. (made-up numbers):

25000 shaders in the cache, file 812 of 2410 (34 %, 41 % of bytes), 173 s

An ETA from the bytes done, or #869's window, could then build on it.

Not measured: how long the extra walk takes on a full install.

**@⁠Jesper-Andersson** on GitHub · 2026-11-28 19:39 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/issues/1423) Related: #869 shows a last-run total and an ETA in the launcher window. This asks for a real total from the shader step itself, so neither the console line nor that window has to rely on the previous run's count. During `-Preload` (which runs `shaders`, then `warm`, then the library step), the shader step's progress line only counts up: ``` 25000 shaders in the cache, 173 s ``` In `apps/victory/src/translate.rs` (`precompile`), the total isn't known while the step runs: the walk reads each file and finds shader containers as it goes. A last-run count goes stale exactly when it matters most, after a build where translator changes make most shaders new. Suggestion: before the loop, count the candidate files (those `may_hold_shaders` passes, under `MAX_FILE`) and their total size. That's a metadata-only walk, with no reads. Then print progress against that, e.g. (made-up numbers): ``` 25000 shaders in the cache, file 812 of 2410 (34 %, 41 % of bytes), 173 s ``` An ETA from the bytes done, or #869's window, could then build on it. Not measured: how long the extra walk takes on a full install.
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-28 19:41:56 +00:00
Author
Owner

@⁠github-actions[bot] on GitHub · 2026-11-28 19:39 UTC · original

Please attach both logs from the run that went wrong. Without them we can only guess. Paste %LOCALAPPDATA% into the address bar of File Explorer to get there.

  1. The play log, in %LOCALAPPDATA%\victory\logs\: the newest victory-nvidia-play-<date>-<time>-<number>.log (from victory.exe) or victory-nvidia-<date>-<time>.log (from the script launcher). The window shows its path at the start, on the line Log: ....
  2. The crash log: %LOCALAPPDATA%\VIctory\data\7952987A\crashes.log, and, if there is one from that run, the newest victory-<date>-<time>-<number>.crash.log in %LOCALAPPDATA%\VIctory\data\7952987A\temp\.

Also say which GPU, Windows version (10 or 11)

**@⁠github-actions[bot]** on GitHub · 2026-11-28 19:39 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/issues/1423#issuecomment-7244707090) Please attach both logs from the run that went wrong. Without them we can only guess. Paste `%LOCALAPPDATA%` into the address bar of File Explorer to get there. 1. The play log, in `%LOCALAPPDATA%\victory\logs\`: the newest `victory-nvidia-play-<date>-<time>-<number>.log` (from `victory.exe`) or `victory-nvidia-<date>-<time>.log` (from the script launcher). The window shows its path at the start, on the line `Log: ...`. 2. The crash log: `%LOCALAPPDATA%\VIctory\data\7952987A\crashes.log`, and, if there is one from that run, the newest `victory-<date>-<time>-<number>.crash.log` in `%LOCALAPPDATA%\VIctory\data\7952987A\temp\`. Also say which GPU, Windows version (10 or 11)
This discussion has been locked. Commenting is limited to contributors.
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.

Dependencies

No dependencies set

Reference
github/trustno1-coder--VIctory-NVIDIA#1423
No description provided.