warm: the "done" bookkeeping is keyed by the exe's full path, so every new install folder re-warms all pipelines; warm --used does not fill the pipeline library #1483

Closed
opened 2026-11-28 20:45:55 +00:00 by github-bot · 5 comments
Owner

@⁠Jesper-Andersson on GitHub · 2026-11-28 20:42 UTC · original

Checked on main 923e38c. The code reading below is from main; I have not run main for this. The re-warm cost was measured on our fork, which has the same code.

What the code does (main)

  • apps/victory/src/warm.rs:43-52: the warm fingerprint is a hash of known::fingerprint(), the lowercased full path of the running exe (current_exe, line 44) and the adapter name. The comment at lines 39-42 gives the reason: the driver keeps what is made here by program path and card.
  • crates/victory-gpu/src/pipeline/known.rs:204-212: known::fingerprint() is the translator hash, the driver version and the sampler order. No path in it.
  • warm-done.txt lines are matched against that fingerprint (warm.rs:57-62), so a copy of the exe in another folder, or a new build in a new folder, sees none of them as done.
  • known.rs:214-215: use_translations says the pipeline library "is not used" for warm. warm::run (warm.rs:29-151) never calls use_library/keep_library. Only into_library (from warm.rs:160) does, and it is called only at the end of preload (main.rs:513-514), for the early and slow lists.
  • The library is named by a hash of the host description (pipeline/library.rs:1-9, hash at line 575). I saw no path in that hash; I did not check what else makes the host refuse a library.

Effect (measured on our fork, in an earlier session; not on main)
Each new worktree or build folder re-warms the used set: about 4,250 pipelines, about 6.5 minutes on an RTX 2070 SUPER + Ryzen 7 5800X (10 worker processes), with a byte-identical translator. A plain warm --used leaves nothing in host-pipelines.bin that a second folder could load.

Not known

  • Whether the driver's own cache really depends on the program path (the comment says so; I did not test it). If it does, the path term protects the driver cache and cannot simply be dropped.
  • Whether a run from a second folder reports "0 being made" when only the library was filled. We have not run that check yet.

Proposal (not tested)

  1. Let warm --used also store what it makes in host-pipelines.bin (the call into_library uses).
  2. Keep the path in the key only for the driver-cache part, or skip the warm for pipelines the library already holds.
  3. Optionally: skip files that start with #![cfg(test)] when hashing the translator sources, so a test-only edit does not re-translate and re-warm everything.

Related, not the same: #1253 (preload reusing warm --used), #1001 (warm uses the launcher's switch set), #779 (quarantine follows the fingerprint).

PC: RTX 2070 SUPER 8 GB, Ryzen 7 5800X, 32 GB, Windows 11, driver 621.40.

This was written with AI assistance (Claude Code).

**@⁠Jesper-Andersson** on GitHub · 2026-11-28 20:42 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/issues/1483) Checked on main `923e38c`. The code reading below is from main; I have not run main for this. The re-warm cost was measured on our fork, which has the same code. **What the code does (main)** - `apps/victory/src/warm.rs:43-52`: the warm fingerprint is a hash of `known::fingerprint()`, the lowercased full path of the running exe (`current_exe`, line 44) and the adapter name. The comment at lines 39-42 gives the reason: the driver keeps what is made here by program path and card. - `crates/victory-gpu/src/pipeline/known.rs:204-212`: `known::fingerprint()` is the translator hash, the driver version and the sampler order. No path in it. - `warm-done.txt` lines are matched against that fingerprint (`warm.rs:57-62`), so a copy of the exe in another folder, or a new build in a new folder, sees none of them as done. - `known.rs:214-215`: `use_translations` says the pipeline library "is not used" for `warm`. `warm::run` (`warm.rs:29-151`) never calls `use_library`/`keep_library`. Only `into_library` (from `warm.rs:160`) does, and it is called only at the end of `preload` (`main.rs:513-514`), for the early and slow lists. - The library is named by a hash of the host description (`pipeline/library.rs:1-9`, hash at line 575). I saw no path in that hash; I did not check what else makes the host refuse a library. **Effect (measured on our fork, in an earlier session; not on main)** Each new worktree or build folder re-warms the used set: about 4,250 pipelines, about 6.5 minutes on an RTX 2070 SUPER + Ryzen 7 5800X (10 worker processes), with a byte-identical translator. A plain `warm --used` leaves nothing in `host-pipelines.bin` that a second folder could load. **Not known** - Whether the driver's own cache really depends on the program path (the comment says so; I did not test it). If it does, the path term protects the driver cache and cannot simply be dropped. - Whether a run from a second folder reports "0 being made" when only the library was filled. We have not run that check yet. **Proposal (not tested)** 1. Let `warm --used` also store what it makes in `host-pipelines.bin` (the call `into_library` uses). 2. Keep the path in the key only for the driver-cache part, or skip the warm for pipelines the library already holds. 3. Optionally: skip files that start with `#![cfg(test)]` when hashing the translator sources, so a test-only edit does not re-translate and re-warm everything. Related, not the same: #1253 (`preload` reusing `warm --used`), #1001 (warm uses the launcher's switch set), #779 (quarantine follows the fingerprint). PC: RTX 2070 SUPER 8 GB, Ryzen 7 5800X, 32 GB, Windows 11, driver 621.40. This was written with AI assistance (Claude Code).
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-28 20:45:56 +00:00
Author
Owner

@⁠github-actions[bot] on GitHub · 2026-11-28 20:42 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 20:42 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/issues/1483#issuecomment-7245486180) 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)
Author
Owner

@⁠Jesper-Andersson on GitHub · 2026-11-28 22:24 UTC · original

/claim: the warm-mark side (warm --used filling the pipeline library, exe-free marks); a draft PR follows. The translator-key side is #1581.

**@⁠Jesper-Andersson** on GitHub · 2026-11-28 22:24 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/issues/1483#issuecomment-7246719322) /claim: the warm-mark side (warm --used filling the pipeline library, exe-free marks); a draft PR follows. The translator-key side is #1581.
Author
Owner

@⁠kalberts0089-hash on GitHub · 2026-11-29 08:00 UTC · original

I tested the open question about the driver cache. On my PC (driver 621.01), the NVIDIA cache files followed the exe's file name, not its folder. I also checked the code reading at main e1f2eb6.

Warm fingerprint follows the folder (measured)

I copied the same victory.exe into two folders: the release build of e1f2eb6, sha256 ec154d06… for both copies. I ran warm --used from each, with VICTORY_CACHE_DIR/VICTORY_DATA_DIR set to a scratch folder:

installA\victory.exe warm --used  ->  0 pipelines known, 0 made before (7e7c9068d80f72b4, on NVIDIA GeForce RTX 4070 Ti) ...
installB\victory.exe warm --used  ->  0 pipelines known, 0 made before (46fd2b5a178f58fb, on NVIDIA GeForce RTX 4070 Ti) ...
installA\victory.exe warm --used  ->  0 pipelines known, 0 made before (7e7c9068d80f72b4, on NVIDIA GeForce RTX 4070 Ti) ...

The binary and the card are the same, but the fingerprint changes with the folder, so warm-done.txt lines written from one folder don't count in the other (apps/victory/src/warm.rs:43-52 and 57-63). The rest of the code is as the issue describes:

  • known::fingerprint() has no path in it (crates/victory-gpu/src/pipeline/known.rs:204-212).
  • warm::run never calls use_library/keep_library. Only into_library does (warm.rs:163, 197), and only preload calls it (apps/victory/src/main.rs:513-514).

Does the driver cache depend on the program path? (measured, RTX 4070 Ti, driver 621.01)

I don't have the game, so I used crates/victory-gpu/examples/lut3d_probe.rs from e1f2eb6, which creates compute pipelines (CreateComputePipelineState) on the real device. I built it with cargo build --locked --release -p victory-gpu --example lut3d_probe, copied the exe byte-identically into several folders, and listed %LOCALAPPDATA%\NVIDIA\DXCache before and after each run:

run exe DXCache change
1, 2 probeA\lut3d_probe.exe the 0000/0002/e1ef …a93bf494922e.nvph set written
3, 4 probeB\lut3d_probe.exe (same file, other folder) no new files; the same *f494922e files rewritten, sizes unchanged
5 probeC\other_probe.exe (same file, renamed) new set: 0000a93b2b10ba6b.nvph, 0002a93b2b10ba6b.nvph, e1efa93b2b10ba6b.nvph

I repeated it in fresh folders and got the same result. lut3d_probe.exe in two more folders added no files, and a copy renamed review_probe.exe got its own new 0000/0002/e1ef set.

So on this driver, the cache file set follows the exe name: a second folder reused the first folder's files, and a new name got a new set. I don't know whether the driver keys on the name alone or on the name plus something else, because I didn't test a same-named exe with different contents. I also didn't time pipeline creation, so I can't say the second folder actually got cache hits. I only saw that it used the same files.

If that holds on other drivers, putting the full path in the warm key is stricter than the driver cache is. A new install folder with the same victory.exe name gets re-warmed even though the driver cache may already have those pipelines. The card term (warm.rs:45) covers the two-GPU case in the comment at warm.rs:39-42, which I can't test here (one GPU).

For #1618: hashing the exe file name instead of the full path might be enough for the driver-cache side. That's a hypothesis I haven't tested in game.

PC: RTX 4070 Ti 12 GB, driver 621.01, Windows 11 Pro 26300.

**@⁠kalberts0089-hash** on GitHub · 2026-11-29 08:00 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/issues/1483#issuecomment-7252828794) I tested the open question about the driver cache. On my PC (driver 621.01), the NVIDIA cache files followed the exe's **file name**, not its folder. I also checked the code reading at main `e1f2eb6`. **Warm fingerprint follows the folder (measured)** I copied the same `victory.exe` into two folders: the release build of `e1f2eb6`, sha256 `ec154d06…` for both copies. I ran `warm --used` from each, with `VICTORY_CACHE_DIR`/`VICTORY_DATA_DIR` set to a scratch folder: ``` installA\victory.exe warm --used -> 0 pipelines known, 0 made before (7e7c9068d80f72b4, on NVIDIA GeForce RTX 4070 Ti) ... installB\victory.exe warm --used -> 0 pipelines known, 0 made before (46fd2b5a178f58fb, on NVIDIA GeForce RTX 4070 Ti) ... installA\victory.exe warm --used -> 0 pipelines known, 0 made before (7e7c9068d80f72b4, on NVIDIA GeForce RTX 4070 Ti) ... ``` The binary and the card are the same, but the fingerprint changes with the folder, so `warm-done.txt` lines written from one folder don't count in the other (`apps/victory/src/warm.rs:43-52` and `57-63`). The rest of the code is as the issue describes: - `known::fingerprint()` has no path in it (`crates/victory-gpu/src/pipeline/known.rs:204-212`). - `warm::run` never calls `use_library`/`keep_library`. Only `into_library` does (`warm.rs:163`, `197`), and only `preload` calls it (`apps/victory/src/main.rs:513-514`). **Does the driver cache depend on the program path? (measured, RTX 4070 Ti, driver 621.01)** I don't have the game, so I used `crates/victory-gpu/examples/lut3d_probe.rs` from `e1f2eb6`, which creates compute pipelines (`CreateComputePipelineState`) on the real device. I built it with `cargo build --locked --release -p victory-gpu --example lut3d_probe`, copied the exe byte-identically into several folders, and listed `%LOCALAPPDATA%\NVIDIA\DXCache` before and after each run: | run | exe | DXCache change | |---|---|---| | 1, 2 | `probeA\lut3d_probe.exe` | the `0000`/`0002`/`e1ef` `…a93bf494922e.nvph` set written | | 3, 4 | `probeB\lut3d_probe.exe` (same file, other folder) | no new files; the same `*f494922e` files rewritten, sizes unchanged | | 5 | `probeC\other_probe.exe` (same file, renamed) | new set: `0000a93b2b10ba6b.nvph`, `0002a93b2b10ba6b.nvph`, `e1efa93b2b10ba6b.nvph` | I repeated it in fresh folders and got the same result. `lut3d_probe.exe` in two more folders added no files, and a copy renamed `review_probe.exe` got its own new `0000`/`0002`/`e1ef` set. So on this driver, the cache file set follows the exe name: a second folder reused the first folder's files, and a new name got a new set. I don't know whether the driver keys on the name alone or on the name plus something else, because I didn't test a same-named exe with different contents. I also didn't time pipeline creation, so I can't say the second folder actually got cache hits. I only saw that it used the same files. If that holds on other drivers, putting the full path in the warm key is stricter than the driver cache is. A new install folder with the same `victory.exe` name gets re-warmed even though the driver cache may already have those pipelines. The card term (`warm.rs:45`) covers the two-GPU case in the comment at `warm.rs:39-42`, which I can't test here (one GPU). For #1618: hashing the exe file name instead of the full path might be enough for the driver-cache side. That's a hypothesis I haven't tested in game. PC: RTX 4070 Ti 12 GB, driver 621.01, Windows 11 Pro 26300.
Author
Owner

@⁠github-actions[bot] on GitHub · 2026-11-29 08:00 UTC · original

@⁠kalberts0089-hash we can't help with where to get the game, a dump or any of its files, and it can't be discussed here at all: if this repository is used for that, GitHub can take it down for everyone. Please don't ask for or post links, torrents or sources here.

**@⁠github-actions[bot]** on GitHub · 2026-11-29 08:00 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/issues/1483#issuecomment-7252830321) @⁠kalberts0089-hash we can't help with where to get the game, a dump or any of its files, and it can't be discussed here at all: if this repository is used for that, GitHub can take it down for everyone. Please don't ask for or post links, torrents or sources here.
Author
Owner

@⁠trustno1-coder on GitHub · 2026-11-30 15:42 UTC · original

Closing this because it was opened before v2026.11.29.01, and a great deal has changed since then. The latest release is v2026.11.30.01.

If this still happens, or still applies, on the latest release, please open a new issue. For a bug, attach both logs from that run:

  1. The play log: the newest victory-nvidia-play-<date>-<time>-<number>.log in %LOCALAPPDATA%\victory\logs\.
  2. The crash log: %LOCALAPPDATA%\VIctory\data\7952987A\crashes.log, plus the newest .crash.log in %LOCALAPPDATA%\VIctory\data\7952987A\temp\ if there is one from that run.
**@⁠trustno1-coder** on GitHub · 2026-11-30 15:42 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/issues/1483#issuecomment-7283456016) Closing this because it was opened before v2026.11.29.01, and a great deal has changed since then. The latest release is [v2026.11.30.01](https://github.com/trustno1-coder/VIctory-NVIDIA/releases/tag/v2026.11.30.01). If this still happens, or still applies, on the latest release, please open a new issue. For a bug, attach both logs from that run: 1. The play log: the newest `victory-nvidia-play-<date>-<time>-<number>.log` in `%LOCALAPPDATA%\victory\logs\`. 2. The crash log: `%LOCALAPPDATA%\VIctory\data\7952987A\crashes.log`, plus the newest `.crash.log` in `%LOCALAPPDATA%\VIctory\data\7952987A\temp\` if there is one from that run.
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#1483
No description provided.