Findings: VIctory-Neo's automatic memory hand-back, ported onto this tree, halved the working set on a 31 GB PC (5070 Ti, 34-min mission) #4688
Labels
No labels
AMD
audio
bug
confirmed
crash
cutscene
dlss
documentation
duplicate
enhancement
fixed-on-main
frame-generation
good first issue
help wanted
input
INTEL
invalid
lighting
linux-proton
memory
needs-info
needs-logs
needs-rebase
NVIDIA
performance
pr-diagnostics
pr-docs
pr-feature
pr-fix
pr-performance
pr-refactor
pr-tests
question
RAYTRACING
rendering
report
series-s
shaders
spam
startup
upstream
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/trustno1-coder--VIctory-NVIDIA#4688
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
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?
@futurepro62 on GitHub · 2026-12-01 01:48 UTC · original
Credit: the hand-back is the work of KyleS98 in VIctory-Neo (GPL-3.0); all of the design, its safeguards and the measurements in its
docs/memory.mdare theirs. This issue only reports what it did when ported onto this tree.Searched first. This tree empties the working set only on the F7 hard flush (
resource.rsempty_working_set, documented there as "a long hitch"), and launchers pin a 14 GB hard minimum working set (#568, keep in RAM). I found no issue or PR about an automatic hand-back.What it is. KyleS98/VIctory-Neo (GPL-3.0, built on foxhound and fxceless's fork) hands the process's untouched memory back to Windows, using
K32EmptyWorkingSeton a thread of its own, in two cases:It never does this while the driver makes pipelines, because Neo traced a launch stall, the watchdog at
+0x23cf683, to the driver's cache files being trimmed mid-build. The code ismod trimin Neo'scrates/victory-gpu/src/residency.rs(commits87f89c5,18231b9,bbb0995,d9d2c3d), with its reasoning indocs/memory.md. Most of what it frees is NVIDIA's own shader-cache files (*.nvph), which the driver maps into the process, plus title memory left untouched after loading.Ported here onto main
93008750plus local commits, it needs about 270 lines:mod trim,quiet(),physical_free();pipeline::made_so_far()fromlibrary::MADE+library::LOADED;residency::refresh.Neo's unit test passes. The #568 floor has to be off (
KEEP_RAM_GB=0in our launcher), orEmptyWorkingSetstops at 14 GB.Measured, 34-minute story mission, against two long sessions of the same build without it:
Method, build, setup and confounds are as in the full report on Neo's tracker: https://github.com/KyleS98/VIctory-Neo/issues/39. In short:
frame_timeslines (game frames, before frame generation).VICTORY_CARD_AWAKE=0was new in this run too (#1405), so part of the fps gain may be that. The working-set and free-RAM figures are the hand-back's.AI-assisted (Claude Code, Claude Opus 5.5). Played by the PC's owner. No game data.
@github-actions[bot] on GitHub · 2026-12-01 01:49 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.%LOCALAPPDATA%\victory\logs\: the newestvictory-nvidia-play-<date>-<time>-<number>.log(fromvictory.exe) orvictory-nvidia-<date>-<time>.log(from the script launcher). The window shows its path at the start, on the lineLog: ....%LOCALAPPDATA%\VIctory\data\7952987A\crashes.log, and, if there is one from that run, the newestvictory-<date>-<time>-<number>.crash.login%LOCALAPPDATA%\VIctory\data\7952987A\temp\.Also say which GPU you have and which Windows version (10 or 11).
If this issue needs logs and none are posted here within 12 hours, it will be closed. Add them by editing your post or in a comment.
@futurepro62 on GitHub · 2026-12-01 04:44 UTC · original
This is a findings report on a memory change, not a crash report: no run in it failed. The full method, settings and measurements are in https://github.com/KyleS98/VIctory-Neo/issues/39, where the feature's author has replied.
Short follow-up from two more sessions on the same PC:
VICTORY_WINDOWS_BAR_MB=2048on top of the hand-back, fps at matching draws per frame rose about 5-10 % in busy scenes, and median free RAM went from 5.0 to 7.4 GB.VICTORY_TRIM_SET_MB=18000), only one hand-back ran in 14 minutes (for low memory) and free RAM held about the same.A proper 30-minute test of the size line set above what the game holds (
VICTORY_TRIM_SET_MB=24000, the author's suggestion) is planned for tomorrow, and the result will go on #39 linked above.I can attach a play log if a maintainer wants one. It's 25-45 MB per session, and I'd strip the user paths first.
@futurepro62 on GitHub · 2026-12-01 05:08 UTC · original
Log lines for the bot, from the round-9 run in #39 of VIctory-Neo (34-minute mission, no crash). This issue reports a memory change, not a crash, so there is no crash log:
crashes.loghas no entry for this run.PC: RTX 5070 Ti 16 GB (driver 621.40), 31 GB RAM, Windows 11 (10.0.26300). Build: this fork's
93008750plus local commits, with the hand-back from KyleS98/VIctory-Neo ported (commitd9e49f80on a local branch). Paths below are shortened toC:\Users\<user>.Launcher switch line (first line of the play log)
Every hand-back line in the run (victory_gpu::memory)
12 hand-backs in 31 minutes of play: 4 because free RAM fell under the line (3,185 MB), 8 because the process held more than two fifths of RAM (12,743 MB). Each took 1.7-2.1 s on its own thread and took the working set from 13-20 GB to 1.7-3.4 GB. The whole 43 MB log is available if anyone wants it.