docs: diagnose Windows memory exhaustion during world loading

(cherry picked from commit b3ec90a65719b545d654d7ce3cc2a143a10e4502)
This commit is contained in:
mattiolocoding authored and trustno1-coder committed 2026-11-27 17:29:33 -08:00
1 parent 805c77f65c
commit f8eab8b01f
2 files changed
+73

No files matched your search

+4
View File
@@ -343,6 +343,10 @@ delete that file to go back to them. Full screen: start the game, then run
`.\scripts\fullscreen.ps1` in another window. Logs go to
`%LOCALAPPDATA%\victory\logs`, saves to `%LOCALAPPDATA%\victory\data`.
If the menu works but loading a scene closes the game, see the
[Windows memory troubleshooting guide](docs/windows-memory.md). It shows how
to check memory on systems with 32 GB of RAM or GPUs with 8 GB of VRAM.
## How it works, and the findings
- [docs/README-foxhound.md](docs/README-foxhound.md): foxhound's own README
+69
View File
@@ -0,0 +1,69 @@
# Windows memory troubleshooting
If the menu works and the game closes during the first scene load, check
Windows' **Committed** counter in Task Manager under **Performance > Memory**.
It shows current system commit and the limit. Free physical RAM can remain
while committed memory is near its limit. A Windows page file raises that
limit. See [Microsoft's page file guidance](https://learn.microsoft.com/en-us/troubleshoot/windows-client/performance/how-to-determine-the-appropriate-page-file-size-for-64-bit-versions-of-windows).
## Check the failure
In Event Viewer, check **Windows Logs > System** for **Resource-Exhaustion-Detector,
event 2004** near the exit. In the VIctory log, look for `memory allocation of`
or `left to commit`. An application error with `0xc0000409` needs context:
the allocation failure and the system event can identify a Rust out-of-memory
abort. For GPU pressure, check **Dedicated GPU memory** and **Shared GPU memory**
under **Performance > GPU**, and compare them with the application's log.
If commit is near the limit and paging is disabled, open `sysdm.cpl` and go to
**Advanced > Performance Settings > Advanced > Virtual memory > Change**.
Enable **Automatically manage paging file size for all drives**, restart Windows,
and check that the file is active:
```powershell
Get-CimInstance Win32_PageFileUsage | Select-Object Name, AllocatedBaseSize
```
Repeat the same load after restarting. Keep the first and second run's commit
and GPU memory readings so the effect can be checked.
## A starting profile for 8 GB GPUs
Start with the Series S profile and frame generation disabled to keep the
initial test small. The following command uses the title's upscaler and a
30 FPS cap. Check the startup log's `console` and `switches` line, since saved
F1 preferences can override launcher options.
```powershell
.\target\release\victory.exe play 'D:\Games\MyDump\game_scarlett_master.exe' --series-s --dlss off --no-framegen-ready --fps 30
```
## Reproduction on 32 GB RAM and an 8 GB RTX 3060 Ti
On Windows 11 with NVIDIA driver 617.14, the Series S configuration above
reached the menu, then exited while loading the first scene. Windows logged
event 2004 before the exit. The system commit limit was 32,686 MiB, with no
active page file. A retry with two pipeline workers reached 32,647 MiB of
system commit while 7,620 MiB of physical RAM was still available. Its next
reported failure was a 2,228,240-byte allocation. Turning off `VICTORY_THIN`
and setting `VICTORY_JOIN_PARTS=1` also reached the commit limit and exited.
The last in-process report before the original exit showed approximately
1,380 MiB of local GPU memory used against a 7,256 MiB budget. The same scene
load with an active page file remains to be tested.
## Related work
- fxceless reports a similar allocation abort during a scene transition with
32 GB RAM and a 16 GB GPU. An open proposal throttles pipeline workers and
pauses speculative prewarming as commit headroom falls.
[Report #771](https://github.com/fxceless/victory-fork/issues/771),
[proposal #777](https://github.com/fxceless/victory-fork/pull/777)
- A VIctory-NVIDIA report on a 16 GB RAM machine found pressure on shared GPU
memory. The author used CPU-mapped VRAM for some buffers. The launcher work
was later made opt-in and predates the current foxhound base.
[Report #6](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/6),
[follow-up #8](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/8)
- DexNom reports a repeatable game breakpoint after reaching the world on a
different 8 GB GPU. Matching the failure signature helps separate that
issue from Windows commit exhaustion.
[Report #104](https://github.com/DexNom/VIctory/pull/104)