FG snapshots: a host list gives its kept input snapshots back on reset (#1978 follow-up) #4297
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/4297"
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?
Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by CubeB on 2026-11-30T18:20:35Z.
Follow-up to #1978, merged today (2026-11-30 14:12Z).
What is wrong
Deferred::clear()(crates/victory-gpu/src/host.rs) resets every per-list record exceptfg_snapshots.HostList::keep_fg_snapshotpushes anArc<FgSnapshot>for each frame-generation input snapshot a list writes, and pooled host lists are reset and reused, not dropped, so each list keeps every snapshot it was ever given.With
VICTORY_FRAMEGEN_SNAPSHOT=1the snapshot pool then runs dry about 30 s into a run: the log showsall input snapshots are in flightand the fallback to unsnapshotted inputs on nearly every frame (so_far=32768in a 30-minute run), so the setting stops doing anything after start-up. I reported this on #1978 earlier and opened the same fix against its branch (SkivHisink/VIctory-NVIDIA#1); #1978 has been merged since, so this is the fix againstmain.Fix
One line in
Deferred::clear():self.fg_snapshots.clear();besideself.kept.clear().HostList::resetruns only after the list's last submission has finished, and the present path holds its own clone, so the GPU is done with the snapshot when the list lets go of it.Testing
cargo build --release --locked -p victoryandcargo test -p victory-gpu --lib -- --test-threads=1pass there, and a 70-minute play session on an RTX 5070 Ti ran without a crash with it in the build; frame generation was loaded but stayed off in that session, so the fix itself has not been exercised in play yet.main+ this commit) I have not built it; the change is the four lines shown.no input snapshot free/all input snapshots are in flightlines stop after start-up.🤖 Generated with Claude Code
Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by tyr0nsur on 2026-11-30T18:41:50Z.
I checked the reset path with a synthetic D3D12 snapshot on Windows 11 / RTX 4060. After a closed recording is reset, main (
e1251c31) still has two strong references (the test and the list). Withfe9cc1cf, it has one. The ten Streamline unit tests passed with the regression added. The test is available as a cherry-pick. Test commitFor the same-description reuse path,
proxied_queuereturns the native queue behind the same Streamline proxy used to create the swap chain. The D3D12 Streamline contract documents that its default mode blocks the presenting queue until the DLSS-G work completes. The test covers release of the list's reference after reset. An in-game run with snapshotting enabled would still be needed to measure pool recovery under frame generation. Queue setup · NVIDIA guideImported from trustno1-coder/VIctory-NVIDIA. Originally posted by andrewpozdnakov7-jpg on 2026-12-01T17:35:03Z.
There are now two field reports with a consistent cutoff this change can be tested against. In #5007 on an RTX 3070 Ti, FG at 2× switches off eight frame indices after it switches on with DLSS Quality, with the snapshot exhaustion warning in between. Both #5016 logs show the same eight-frame cutoff with Performance at 6× and Quality at 5×. Log comparison
Changing #5007 only to DLAA removed the warning and produced extra frames. That provides a workaround and a control. The open verification for this patch is whether the original Quality case releases and reuses snapshots and produces extra frames with #4297 applied. The existing reset test verifies the reference drop, which is one part of that check.
Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by andrewpozdnakov7-jpg on 2026-12-01T18:24:47Z.
The maintainer added the same
fg_snapshots.clear()reset tomainina82703f0. The commit also explains the test-build regression. Alias mode 2 started using snapshots for aliased depth or motion vectors, which made the eight-entry pool exhaustion show up with default play settings. Commit on mainThe v2026.12.01.01-test download still predates that commit. The remaining field check is the original DLSS Quality route on a build that contains it. The two checks are sustained extra frames and no recurrence of the snapshot exhaustion warning.
Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by trustno1-coder on 2026-12-01T18:44:26Z.
Closing this as part of moving main to the texture and video-memory rework (v2026.12.01.01-test). A lot of the code changed, and this pull request no longer applies cleanly to it; it would need to be rewritten against the new main rather than rebased. Thank you for the work. If the change is still needed, please open a new pull request based on the current main.
Pull request closed