Host memory: the card's memory the driver maps is named in the memory line, and the texture line comes down while the PC is short of commit (VICTORY_TEXTURE_COMMIT_FLOOR_MB) #4288

Closed
Lyrnc wants to merge 5 commits from upstream-pr/4288 into main
Lyrnc commented 2026-11-30 18:13:10 +00:00 (Migrated from github.com)

Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by Lyrnc on 2026-11-30T18:13:10Z.


Problem

On a 32 GB PC (RTX 5080 16 GB, 9800X3D, Windows 11) the game's private bytes are ~29 GB on v2026.11.28.03 and 32-34 GB on 29.x builds over the same camera spin, and on every 29.x build they climb for the first minutes of play: 28.4 -> 33.1 GB in five minutes of walking. Free RAM is then 0.1-1.3 GB, the commit left 0.3-2.4 GB, Windows grows the page file during camera turns (24.6 -> 26.6 GB) and page-ins run at 2-10k/s.

The memory line names little of it. In #3674 (5090, 32 GB) "unnamed" private went from 14.7 to 26.7 GB in 29 minutes. 21 open issues (37 people) report this growth on 32 GB PCs (#3674 #3510 #3489 #3761 #3545 #3940 #3443 #3357 #3872 #3448 #3909 #3813 #3422 #3642 #3430 #2333 #3295 #3646 #3529 #3601 #3764). In #3443 the 28 -> 3 fps drops by camera direction went away with a 32-64 GB page file.

Result on a reviewer's PC (the main evidence)

nick0451, RTX 3090 24 GB (driver 610.88), i9-14900K, 32 GB RAM, 60 GB page file, Series S, DLSS Performance, 141d038d with #4694 applied locally. There were three arms of two runs each, alternating, 15 minutes in the world, the same pad tape every start (VICTORY_INPUT_REPLAY), and an allocation walk plus system counters every minute. The route still drifts between runs, so the frame columns are indicative; the memory columns don't depend on it.

arm private, GB 64 MiB write-combined allocations available RAM, mean / min (after 3 min) the deepest cut (cap) s with a frame >100 ms frames >1 s
25 % (a) 25.0 → 27.5 91 → 114 1.5 / 1.2 GB 5,888 MB (5,888) 41 of 871 1
25 % (b) 24.8 → 27.8 89 → 112 1.8 / 1.0 GB 5,888 MB (5,888) 49 of 879 4
VICTORY_TEXTURE_PHYS_FLOOR_MB=0 (a) 26.6 → 30.6 95 → 158 1.7 / 1.4 GB none 21 of 908 1
VICTORY_TEXTURE_PHYS_FLOOR_MB=0 (b) 25.0 → 30.4 93 → 173 1.8 / 1.3 GB none 21 of 888 0
VICTORY_TEXTURE_CUT_MAX_PERCENT=40 (a) 25.0 → 26.5 97 → 105 2.1 / 1.8 GB 7,384 MB (9,421) 12 of 872 2
VICTORY_TEXTURE_CUT_MAX_PERCENT=40 (b) 25.0 → 25.3 90 → 89 2.2 / 2.1 GB 7,944 MB (9,421) 15 of 889 0
  • At 40 % the cut settles. It found its level at 7.4-7.9 GB without reaching the 9.4 GB cap. The 64 MiB write-combined allocations (the card's memory mapped into the process) stopped growing (+8, then -1), private memory stayed flat, and available RAM held at about 2 GB. That's why 40 % is now the default.
  • At 25 % the cut sat at its cap all run. The allocations still grew by about 23, and available RAM went lower. With the free-memory floor off, they grew by 63-80, and private memory passed 30 GB.
  • No cost was seen, within the route noise. The 40 % runs had the fewest seconds with a frame over 100 ms (12 and 15), and the per-minute shots showed nothing late or blurry. One shot a minute won't catch a brief blur.
  • What still drains free memory there is mostly the system file cache (the DirectStorage reads, about 1.0 → 1.5 GB over a run), plus about 0.7 GB of the game's own working set. No texture line can take that back.
  • In nick0451's earlier runs on cbfc55e4 (default floors, the 25 % cap), growth fell from about 0.5 to 0.04-0.08 GB a minute, and private memory stopped at 27-28 GB where it otherwise passes 32.

Analysis

The "unnamed" growth is the card's memory

The NVIDIA driver maps the card's memory the layer holds into the process: write-combined private pages, counted in the process's private bytes (the commit Windows backs with RAM or the page file).

  • copystat's memory maps (diagnostics builds) split the process's committed pages by kind. In 160 maps of 16 bench runs the write-combined private bytes were the card's use (DXGI local CurrentUsage) plus 0.54 GB (the median; -0.45 to +0.88 GB while the use moved). Only 1.2-1.7 GB of them were resident.
  • The 64 MiB texture blocks (DEFAULT heaps, not CPU-visible) show up there as 64 MiB write-combined regions: 138 of them in one 29.11 run, 8.3 GB, against 7.6 GB of blocks the pool reports.
  • From the 1-s "memory now" lines, the change of commit per second is 0.97-1.11 x the card's change plus 1.0-1.26 x the shared memory's change (least squares over 250-320 seconds a run, R² 0.95-0.98 in four runs, 0.88 in a fifth). In two runs the card's use dropped by ~1.1 GB within a second and commit did not drop with it.
  • A 22-minute walk on a 29.11-era build: the card went 12.4 -> 15.2 GB in five minutes (its budget; 15.4 GB after ten), "unnamed" 5.6 -> 10.0 GB, private 28.4 -> 33.1 GB. Private stopped growing the minute the card reached its budget, and stayed at 32.7-33.2 GB for the other 16 minutes. The page file grew to 27.7 GB; page-ins averaged 11.9k a second.
  • A game-free probe on the same PC (RTX 5080, NVIDIA driver 32.0.16.1088): a D3D12 device, heaps made, evicted and released, and after each step the process's PrivateUsage, its write-combined committed regions and DXGI's usage. 16 texture blocks of 64 MiB (DEFAULT, ALLOW_ONLY_NON_RT_DS_TEXTURES, as pool.rs makes them) added 1,026 MB of private bytes, 1,024 MB of write-combined regions and 1,024 MB of the card's use; a 1 GiB DEFAULT buffer heap the same again. ID3D12Device::Evict on the 16 blocks took 1,024 MB off the card's use and nothing off the private bytes. A 256 MiB CUSTOM L0 write-back heap added 256 MB of private bytes outside the write-combined regions (shared memory). Releasing the blocks gave the private bytes back (833 MB at once, the rest with the last release).

So on a 16 GB card the climb stops at the card's budget. On a 32 GB card it would go on for as long as the textures keep coming, which fits #3674's half hour (not checked: no 32 GB card here). What the texture queue keeps on the card costs the PC's commit one to one, while the queue fills the card up to its line (the budget less 768 MiB) whatever the PC's commit.

Holders, ranked by GB

Committed GB (resident GB in brackets), from the last memory map of each run (diagnostics builds, Series X, the same 32 GB PC). "29.11": six runs of 29.11-era builds (upstream main of 11-29 and 11-30 with our team's patches), 1440p walks. "29.01": two runs of 829188e9 + the compile-memory fix (a drive and a boat probe). 28.03 has no memory map: its numbers are from its release log and the 5-s timeline, over the same camera spin as five 29.01 runs.

Holder 29.11 29.01 28.03 Grew
The card's own memory, mapped into the process (write-combined) 15.3-16.3 (1.2-1.7) 11.3-12.3 (1.2) 12.5 GB dedicated (timeline) vs 13.4-14.0 on 29.01 +3-5 vs 29.01; climbs ~3 GB in the first minutes of each session
of it: texture blocks (64 MiB, DEFAULT) 8.0-10.0 4.9-5.9 the queue under its line ("room") in every report +2-5
of it: card copies of title buffers and windows 3.7-3.8 2.3-3.7 2.2 +1.5: the windows' card room on 16 GB cards went from 1,024 to 2,560 MiB after 28.03 (card room for windows window_card_mb in the logs); such a window keeps its CPU side in the PC's memory too
of it: copies of textures the host renders to 1.2-2.9 0.7-0.8 n/a +0.5-2.1
Memory shared with the card (GPU-visible system memory) 7.0-8.7 6.4-6.8 6.4 (spin) vs 7.1-7.3 on 29.01 +0.6-1.9
of it: windows of title memory in the PC's memory 2.4-3.9 1.8-2.3 n/a +0.6-1.6
CPU sides of windows and copies (6 MiB private regions) 4.5-4.9 (3.8-4.9) 3.9-4.4 (3.9-4.4) n/a +0.5
Process heap segments 2.3-2.4 (1.9-2.1) 2.2 (1.9) n/a flat
Two or three 1 GiB private allocations 1.9-2.0 (1.2-1.7) 2.0-2.1 (1.7-1.8) n/a flat
The driver's command lists ("private bytes grew while lists were made") 4.4-7.1 2.3-6.3 n/a varies with the scene

Over the same camera spin (Series X, DLSS Quality, one 28.03 run and five 29.01 runs) private was 29.0 GB median / 31.8 GB at most on 28.03 and 32.1-33.6 / 33.0-34.5 GB on 29.01. The page file grew in four of the five 29.01 runs (24.6 -> 25.6-26.6 GB) and not on 28.03. The commit left was 4.2 GB median on 28.03 and 1.5-2.3 GB on 29.01.

By what grew, the three largest:

  1. The texture blocks on the card (+2-5 GB since 29.01, and the climb in each session). 28.03 kept the texture queue under its line; 29.x builds fill the card to it ("no room, new textures wait") and past the budget. This branch names them in the memory line and lowers the texture line while the PC is short of commit (below).
  2. The windows' card sides (+1.5 GB since 28.03: the room went from 1,024 to 2,560 MiB on 16 GB cards, 6e008625). Not changed here: windows on the card take the reads of the title's allocator off the bus (the 1,024 MiB room took an RTX 4070 SUPER from 3 to 21-25 fps), and what the larger room gives on a 16 GB card was not measured, so taking it back may cost frames.
  3. The memory shared with the card (+0.6-1.9 GB since 29.01), mostly windows of title memory in the PC's memory. #2910 shrinks those windows to what is asked for; #3869 names the rest by heap. Not carried here.

What does not hold much on this PC:

  • The L0 spares 158d3177 sized (upload pool 1024 MiB per kind, exact pool 256, send spares 768). With under 5 GB of RAM free the pressure never clears, and the sweep trims them to the 16 MiB hot floor every second. They churn (64.6 GB of upload buffers made in a 7-minute run) rather than hold. Sends are #3994; the list copy sources are #3381.
  • Snapshot buffers (#2234): "snapshot buffers kept: 0 reserving 0 MB" in every run here.

Fix

1. The memory line names the card's memory the driver maps (procmem.rs)

  • The walk counts the write-combined private pages at host addresses apart.
  • The line says them inside the host private bytes, with the card's use beside them: ... at host addresses 27918 MB private (the layer's heap, stacks, the driver; N MB of it write-combined, the card's memory the driver maps into the process: the card's own in use M MB) ....
  • They count as named, so "unnamed" is what is left.
  • procmem::card_mapped() hands the last walk's bytes on.

2. The texture line comes down while the PC is short of commit (resource.rs, one call in the 1 Hz sweep in host.rs)

  • New switch VICTORY_TEXTURE_COMMIT_FLOOR_MB (4096 by default; 0 gives the old line).
  • While the PC's commit left is under the floor, the line the texture queue weighs the card against comes down by what is short. That is room, the sweep's card rule, slot eviction and the sweep's pressure test. The sweep and slot eviction then let idle textures go down to it, as on a smaller card.
  • The commit left is counted without the page file's growth (ullAvailPageFile), so the line moves before Windows has to grow the page file.
  • It only acts where the card's memory is in the process's commit: the last walk (every 5 s) found at least half of the card's use mapped write-combined. On a driver that does not map it, and with VICTORY_PROCESS_MEMORY=0 (no walk), the line is as before.
  • It comes down 256 MiB a second at most. It goes deeper only once the card's use (as the queue counts it) has followed the last step, and while the texture blocks hold under 512 MiB of free space. Textures let go out of blocks that stay (holes) give no commit back, and new textures fill those holes first, so the line does not go deeper for them.
  • It goes back up 128 MiB a second once the commit left is 1 GiB over the floor.
  • Also on free memory (third commit). nick0451 (RTX 3090 24 GB, 32 GB RAM, 60 GB page file) found the floor never engaged with a big page file, which is #3443's advice: commit left stayed over 66 GB while free memory sat at 1.4-4.0 GB, and the >1 s frames clustered under about 2.5 GB free. The line now also comes down while ullAvailPhys is under VICTORY_TEXTURE_PHYS_FLOOR_MB (3072; 0: commit alone, as before).
    • When both are short, the cut follows whichever lacks more (cut_for; commit on a tie).
    • The steps, the holds and the deepest cut are the same.
    • It goes back up only once both are a GiB over their floors (cut_clear).
    • Both floors at 0 turn the cut off.
  • It never goes deeper than VICTORY_TEXTURE_CUT_MAX_PERCENT of the budget (fourth commit; 40 by default since the fifth, from the result above; held to 90; 0: no cut), and never takes the line under the texture floor (2 GiB of textures, a quarter of the budget on small cards, are always admitted). On a 16 GB card the deepest cut is about 6.1 GB, and on a 24 GB card about 9.4 GB.
  • Windows and card copies of title buffers keep the old line. They are what shaders read most, and a window in card memory the CPU maps (the first 4 GiB of them on a 16 GB card) takes its bytes out of shared memory, which is resident RAM.
  • A line says when the cut starts and ends, and every 30 s while it lasts: texture line under the PC's commit or free memory (VICTORY_TEXTURE_COMMIT_FLOOR_MB=4096, VICTORY_TEXTURE_PHYS_FLOOR_MB=3072): N MB down for commit|free memory ..., with the free memory beside the commit left. The queue's own line ("the texture queue's room ... against a line of") shows the lowered line.
  • The decision is a pure function, next_cut, with unit tests.

Verification

Third commit (free-memory floor), on 5fabb46e + the first two: Windows 11, MSVC, own target dir, -j 4, one cargo command at a time: cargo check -p victory-gpu --tests --locked passes with no warning; cargo test -p victory-gpu --lib --locked -- procmem:: resource::tests::... 23 passed, 0 failed, with the four new tests (a_cut_is_for_whichever_floor_lacks_more, with_a_big_page_file_free_memory_cuts_the_line, the_line_goes_back_up_only_when_both_have_room, short_of_memory_the_line_waits_and_stops_as_for_commit) and every earlier one of this branch unchanged; cargo clippy -p victory-gpu --lib --tests --locked passes, its five warnings all outside this branch (host/font.rs, host/menu.rs, host/panel.rs). No game was run.

Fourth commit (the deepest cut as a switch): the same three commands, one at a time: cargo check passes with no warning; the filtered tests 24 passed, 0 failed, with the_deepest_cut_is_a_switch_and_keeps_the_texture_floor new (the default, held to 90, 0 for none, the RTX 3090's numbers, the texture floor binding on an 8 GB card at 90 %, the cut going past the quarter at 40 %); cargo clippy passes, its five warnings outside this branch.

Fifth commit (default 40 %): the same three commands, one at a time: cargo check passes with no warning; the filtered tests 24 passed, 0 failed, with the_cut_stops_at_its_most and the_deepest_cut_is_a_switch_and_keeps_the_texture_floor now checking 40 % (on an 8 GB card the default stays above the texture floor; 90 % still stops at it); cargo clippy passes, its five warnings outside this branch. No game was run.

Earlier, for the first two commits:

Rebased on .02 (84bd61e2): the only conflict was docs/bug-journal.md (both 2026-11-30 entries kept), and the commit that fixed a card_pass test call was dropped because upstream fixed it in 145f7722. The resource.rs call sites this branch changes are the same on .02. The cargo check and filtered tests below were run on the c71899d9 base. Their re-run on .02 is queued in the shared build slots and had not run when this was written.

Windows 11, MSVC, own target dir, -j 4, on the c71899d9 base:

  • cargo check -p victory-gpu --tests --locked: passes. Its one warning (Shadow::ranged never used, shadow.rs) is on main too.
  • cargo test -p victory-gpu --lib --locked -- procmem:: resource::tests::...: 18 passed, 0 failed. The seven new tests:
    • write_combined_private_pages_at_host_addresses_are_counted_apart (procmem: only private pages at host addresses, inside the private bytes);
    • the_line_is_not_cut_when_off_or_when_the_card_is_not_in_the_commit (switch 0, a driver that does not map the card, room on the PC);
    • short_of_commit_the_line_comes_down_a_step (one step, or what is short);
    • the_line_waits_for_the_card_and_for_blocks_to_go (no deeper while the card has not followed, or with 512 MiB free in blocks);
    • the_cut_stops_at_its_most (the deepest cut, the texture floor kept);
    • with_room_again_the_line_goes_back_up_slowly (hysteresis and the 128 MiB step);
    • a_walk_settles_at_the_floor_or_stops_at_holes: 120 seconds from the card at its line and 1.2 GB of commit left. When the textures that go empty whole blocks, the cut settles at exactly what was short (2,896 MiB) and the commit left at the floor; when they leave holes it stops after two steps.
    • The neighbours that read the same lines pass unchanged: room_line_follows_the_budget, copies_stop_at_the_texture_line, idle_sweep_policy_keeps_vram_eviction_active_under_host_pressure, the four slot_evict*/slot_eviction* tests, the_oldest_copies_covering_the_need_go, and procmem's three.
  • cargo clippy -p victory-gpu --lib --tests --locked: passes, no warning on a line this branch adds or changes. Its two warnings are elsewhere and on main (shadow.rs ranged never used; a manual is_multiple_of in host.rs at line 5082). -D warnings was not used, because main already fails it.
  • The probe (Analysis above) ran outside the game, in a build slot: 11 steps, the numbers as quoted.

NOT tested

  • The free-memory floor (third commit) was not run in game. On our 32 GB PC free memory is 0.1-1.3 GB in play, so the cut will be on nearly all the time there and may go down to its most (40 % of the budget) wherever the card can follow. nick0451's runs (above) show the effect on a 24 GB card, and no cost within their route noise. A 16 GB card on our bench, default against VICTORY_TEXTURE_PHYS_FLOOR_MB=0, is still to be run. The 3072 MiB floor is a choice from their stall cluster (under ~2.5 GB free), not a measurement of its own.
  • Nothing was run in the game. The bench steps, on the same 32 GB PC, Series X 1440p, the same open-world save, closing Discord and the browser first:
    1. A 20-minute walk on main and on this branch, then on this branch with VICTORY_TEXTURE_COMMIT_FLOOR_MB=0, alternating, two runs each.
    2. From the 5-s timeline and the log: private bytes and their write-combined part over time (minute 5 to 20 should be flat, and lower than main by what the cut took); page file size; page-ins per second; hard faults per second; free RAM; the commit left.
    3. From the texture line: how deep the cut went and how long it lasted; the card's use against the budget.
    4. fps, frames over 100 ms per 1,000, and the longest frame; texture uploads per second and copies "made again" within 2 s (churn), against main.
    5. Pictures at fixed seconds (late or blurry textures where the cut is deep).
  • Whether the sweep can bring the card down to the cut line on main. Slot eviction let go of 0 textures in our 29.x runs. The sweep takes only copies no slot shows. If neither can free enough, the line stays at its first step and new textures wait there, as they already do at the full line ("no room, new textures wait" in most reports on main). #3475 and our perf/slot-evict-frees make the sweep and slot eviction reach their line.
  • Whether letting textures go gives commit back depends on whole 64 MiB blocks being let go. The pool fills the fullest block first and keeps at most two empty ones. The line stops going deeper while 512 MiB lie free in blocks, but how much a cut gives back in play was not measured.
  • The 4 GiB floor, the steps, the 512 MiB of holes and the 1 GiB hysteresis are choices, not measurements. The floor is where the layer's own pressure starts.
  • AMD and Intel. Whether their drivers map the card's memory into the process was not checked. If they do not, the cut stays off.
  • Not run on 16 GB PCs or on a 32 GB card. On a 32 GB card the deepest cut at the default is 40 % of the budget (about 12 GB).
  • The 28.03 breakdown by holder. 28.03 has no memory map. Its private bytes, dedicated and shared memory come from the 5-s timeline only.

Overlap

  • #3869 (Trillazill, diagnostics): host buffers alive by heap, in the PC's memory the card uses. It names the shared part, not the card's memory mapped into the process. Both can land; the lines do not conflict.
  • #3475 (nyxctura, conflicting with main): makes the sweep free idle textures under RAM pressure without churn, and keeps slot-shown ones. It changes how the sweep reaches its line; this changes the line. Complementary; both touch let_go_idle() near the card rule, so whichever lands second needs a small rebase.
  • perf/slot-evict-frees (ours, Lyrnc/VIctory-NVIDIA, not opened): slot eviction lets go of copies no slot shows. Complementary in the same way.
  • #3848 (Trillazill): slot eviction counts the card's use as the queue does. It touches the same slot_evict() line computation (room_eff); a one-line rebase.
  • #2910 (Remorce): windows of title memory grown to what is asked for, -24 % shared memory. That is the third holder above (windows in the PC's memory and their CPU sides). Not carried here: it is 1,400 lines across 16 files, shaders included.
  • #3397 (Pierrot1398): texture copies held to 1 GB on 16 GB PCs with 8 GB cards, and a page-file warning. A fixed cap for small PCs; this one follows the commit left on any PC.
  • #2038, #3406, #1944, #3070: texture admission and eviction against the card's budget or critical commit. None lowers the line by the PC's commit headroom.
  • #2717, #1173, #3426: commit admission for pipelines and compiles. Complementary: they wait for commit, this gives some back.
  • #3994 (ours, sends) and #3381 (spares): the L0 spares' churn. Separate.
  • #2234 (snapshot pool), #2240 (detile buffers), #2671 (16 GB and smaller PCs): not the holders on this PC (see Analysis).

AI use

Claude Code (Claude Opus 5.5) read the procmem, "memory now", copystat memory-map and room lines of the bench's run logs with its own parsing scripts, fitted the commit change against the card's and the shared memory's, ran the game-free D3D12 probe, read the pools, caches and lines changed since 28.03, wrote both commits and their tests, ran cargo check / cargo test / cargo clippy, and wrote this description.

🤖 Generated with Claude Code

<!-- greyfinch-sync:trustno1-coder/VIctory-NVIDIA:issue:5571042997 --> Imported from [trustno1-coder/VIctory-NVIDIA](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/4288). Originally posted by [Lyrnc](https://github.com/Lyrnc) on 2026-11-30T18:13:10Z. --- ## Problem On a 32 GB PC (RTX 5080 16 GB, 9800X3D, Windows 11) the game's private bytes are ~29 GB on v2026.11.28.03 and 32-34 GB on 29.x builds over the same camera spin, and on every 29.x build they climb for the first minutes of play: 28.4 -> 33.1 GB in five minutes of walking. Free RAM is then 0.1-1.3 GB, the commit left 0.3-2.4 GB, Windows grows the page file during camera turns (24.6 -> 26.6 GB) and page-ins run at 2-10k/s. The memory line names little of it. In #3674 (5090, 32 GB) "unnamed" private went from 14.7 to 26.7 GB in 29 minutes. 21 open issues (37 people) report this growth on 32 GB PCs (#3674 #3510 #3489 #3761 #3545 #3940 #3443 #3357 #3872 #3448 #3909 #3813 #3422 #3642 #3430 #2333 #3295 #3646 #3529 #3601 #3764). In #3443 the 28 -> 3 fps drops by camera direction went away with a 32-64 GB page file. ## Result on a reviewer's PC (the main evidence) nick0451, RTX 3090 24 GB (driver 610.88), i9-14900K, 32 GB RAM, 60 GB page file, Series S, DLSS Performance, 141d038d with #4694 applied locally. There were three arms of two runs each, alternating, 15 minutes in the world, the same pad tape every start (`VICTORY_INPUT_REPLAY`), and an allocation walk plus system counters every minute. The route still drifts between runs, so the frame columns are indicative; the memory columns don't depend on it. | arm | private, GB | 64 MiB write-combined allocations | available RAM, mean / min (after 3 min) | the deepest cut (cap) | s with a frame >100 ms | frames >1 s | |---|---|---|---|---|---|---| | 25 % (a) | 25.0 → 27.5 | 91 → 114 | 1.5 / 1.2 GB | 5,888 MB (5,888) | 41 of 871 | 1 | | 25 % (b) | 24.8 → 27.8 | 89 → 112 | 1.8 / 1.0 GB | 5,888 MB (5,888) | 49 of 879 | 4 | | `VICTORY_TEXTURE_PHYS_FLOOR_MB=0` (a) | 26.6 → 30.6 | 95 → 158 | 1.7 / 1.4 GB | none | 21 of 908 | 1 | | `VICTORY_TEXTURE_PHYS_FLOOR_MB=0` (b) | 25.0 → 30.4 | 93 → 173 | 1.8 / 1.3 GB | none | 21 of 888 | 0 | | `VICTORY_TEXTURE_CUT_MAX_PERCENT=40` (a) | 25.0 → 26.5 | 97 → 105 | 2.1 / 1.8 GB | 7,384 MB (9,421) | 12 of 872 | 2 | | `VICTORY_TEXTURE_CUT_MAX_PERCENT=40` (b) | 25.0 → 25.3 | 90 → 89 | 2.2 / 2.1 GB | 7,944 MB (9,421) | 15 of 889 | 0 | - **At 40 % the cut settles.** It found its level at 7.4-7.9 GB without reaching the 9.4 GB cap. The 64 MiB write-combined allocations (the card's memory mapped into the process) stopped growing (+8, then -1), private memory stayed flat, and available RAM held at about 2 GB. That's why 40 % is now the default. - **At 25 % the cut sat at its cap all run.** The allocations still grew by about 23, and available RAM went lower. With the free-memory floor off, they grew by 63-80, and private memory passed 30 GB. - **No cost was seen, within the route noise.** The 40 % runs had the fewest seconds with a frame over 100 ms (12 and 15), and the per-minute shots showed nothing late or blurry. One shot a minute won't catch a brief blur. - **What still drains free memory there is mostly the system file cache** (the DirectStorage reads, about 1.0 → 1.5 GB over a run), plus about 0.7 GB of the game's own working set. No texture line can take that back. - In nick0451's earlier runs on cbfc55e4 (default floors, the 25 % cap), growth fell from about 0.5 to 0.04-0.08 GB a minute, and private memory stopped at 27-28 GB where it otherwise passes 32. ## Analysis ### The "unnamed" growth is the card's memory The NVIDIA driver maps the card's memory the layer holds into the process: write-combined private pages, counted in the process's private bytes (the commit Windows backs with RAM or the page file). - `copystat`'s memory maps (diagnostics builds) split the process's committed pages by kind. In 160 maps of 16 bench runs the write-combined private bytes were the card's use (DXGI local `CurrentUsage`) plus 0.54 GB (the median; -0.45 to +0.88 GB while the use moved). Only 1.2-1.7 GB of them were resident. - The 64 MiB texture blocks (DEFAULT heaps, not CPU-visible) show up there as 64 MiB write-combined regions: 138 of them in one 29.11 run, 8.3 GB, against 7.6 GB of blocks the pool reports. - From the 1-s "memory now" lines, the change of commit per second is 0.97-1.11 x the card's change plus 1.0-1.26 x the shared memory's change (least squares over 250-320 seconds a run, R² 0.95-0.98 in four runs, 0.88 in a fifth). In two runs the card's use dropped by ~1.1 GB within a second and commit did not drop with it. - A 22-minute walk on a 29.11-era build: the card went 12.4 -> 15.2 GB in five minutes (its budget; 15.4 GB after ten), "unnamed" 5.6 -> 10.0 GB, private 28.4 -> 33.1 GB. Private stopped growing the minute the card reached its budget, and stayed at 32.7-33.2 GB for the other 16 minutes. The page file grew to 27.7 GB; page-ins averaged 11.9k a second. - A game-free probe on the same PC (RTX 5080, NVIDIA driver 32.0.16.1088): a D3D12 device, heaps made, evicted and released, and after each step the process's `PrivateUsage`, its write-combined committed regions and DXGI's usage. 16 texture blocks of 64 MiB (`DEFAULT`, `ALLOW_ONLY_NON_RT_DS_TEXTURES`, as `pool.rs` makes them) added 1,026 MB of private bytes, 1,024 MB of write-combined regions and 1,024 MB of the card's use; a 1 GiB `DEFAULT` buffer heap the same again. `ID3D12Device::Evict` on the 16 blocks took 1,024 MB off the card's use and nothing off the private bytes. A 256 MiB `CUSTOM` L0 write-back heap added 256 MB of private bytes outside the write-combined regions (shared memory). Releasing the blocks gave the private bytes back (833 MB at once, the rest with the last release). So on a 16 GB card the climb stops at the card's budget. On a 32 GB card it would go on for as long as the textures keep coming, which fits #3674's half hour (not checked: no 32 GB card here). What the texture queue keeps on the card costs the PC's commit one to one, while the queue fills the card up to its line (the budget less 768 MiB) whatever the PC's commit. ### Holders, ranked by GB Committed GB (resident GB in brackets), from the last memory map of each run (diagnostics builds, Series X, the same 32 GB PC). "29.11": six runs of 29.11-era builds (upstream main of 11-29 and 11-30 with our team's patches), 1440p walks. "29.01": two runs of 829188e9 + the compile-memory fix (a drive and a boat probe). 28.03 has no memory map: its numbers are from its release log and the 5-s timeline, over the same camera spin as five 29.01 runs. | Holder | 29.11 | 29.01 | 28.03 | Grew | |---|---:|---:|---:|---| | The card's own memory, mapped into the process (write-combined) | 15.3-16.3 (1.2-1.7) | 11.3-12.3 (1.2) | 12.5 GB dedicated (timeline) vs 13.4-14.0 on 29.01 | +3-5 vs 29.01; climbs ~3 GB in the first minutes of each session | | of it: texture blocks (64 MiB, DEFAULT) | 8.0-10.0 | 4.9-5.9 | the queue under its line ("room") in every report | +2-5 | | of it: card copies of title buffers and windows | 3.7-3.8 | 2.3-3.7 | 2.2 | +1.5: the windows' card room on 16 GB cards went from 1,024 to 2,560 MiB after 28.03 (`card room for windows window_card_mb` in the logs); such a window keeps its CPU side in the PC's memory too | | of it: copies of textures the host renders to | 1.2-2.9 | 0.7-0.8 | n/a | +0.5-2.1 | | Memory shared with the card (GPU-visible system memory) | 7.0-8.7 | 6.4-6.8 | 6.4 (spin) vs 7.1-7.3 on 29.01 | +0.6-1.9 | | of it: windows of title memory in the PC's memory | 2.4-3.9 | 1.8-2.3 | n/a | +0.6-1.6 | | CPU sides of windows and copies (6 MiB private regions) | 4.5-4.9 (3.8-4.9) | 3.9-4.4 (3.9-4.4) | n/a | +0.5 | | Process heap segments | 2.3-2.4 (1.9-2.1) | 2.2 (1.9) | n/a | flat | | Two or three 1 GiB private allocations | 1.9-2.0 (1.2-1.7) | 2.0-2.1 (1.7-1.8) | n/a | flat | | The driver's command lists ("private bytes grew while lists were made") | 4.4-7.1 | 2.3-6.3 | n/a | varies with the scene | Over the same camera spin (Series X, DLSS Quality, one 28.03 run and five 29.01 runs) private was 29.0 GB median / 31.8 GB at most on 28.03 and 32.1-33.6 / 33.0-34.5 GB on 29.01. The page file grew in four of the five 29.01 runs (24.6 -> 25.6-26.6 GB) and not on 28.03. The commit left was 4.2 GB median on 28.03 and 1.5-2.3 GB on 29.01. By what grew, the three largest: 1. **The texture blocks on the card** (+2-5 GB since 29.01, and the climb in each session). 28.03 kept the texture queue under its line; 29.x builds fill the card to it ("no room, new textures wait") and past the budget. This branch names them in the memory line and lowers the texture line while the PC is short of commit (below). 2. **The windows' card sides** (+1.5 GB since 28.03: the room went from 1,024 to 2,560 MiB on 16 GB cards, 6e008625). Not changed here: windows on the card take the reads of the title's allocator off the bus (the 1,024 MiB room took an RTX 4070 SUPER from 3 to 21-25 fps), and what the larger room gives on a 16 GB card was not measured, so taking it back may cost frames. 3. **The memory shared with the card** (+0.6-1.9 GB since 29.01), mostly windows of title memory in the PC's memory. #2910 shrinks those windows to what is asked for; #3869 names the rest by heap. Not carried here. What does not hold much on this PC: - The L0 spares 158d3177 sized (upload pool 1024 MiB per kind, exact pool 256, send spares 768). With under 5 GB of RAM free the pressure never clears, and the sweep trims them to the 16 MiB hot floor every second. They churn (64.6 GB of upload buffers made in a 7-minute run) rather than hold. Sends are #3994; the list copy sources are #3381. - Snapshot buffers (#2234): "snapshot buffers kept: 0 reserving 0 MB" in every run here. ## Fix **1. The memory line names the card's memory the driver maps** (`procmem.rs`) - The walk counts the write-combined private pages at host addresses apart. - The line says them inside the host private bytes, with the card's use beside them: `... at host addresses 27918 MB private (the layer's heap, stacks, the driver; N MB of it write-combined, the card's memory the driver maps into the process: the card's own in use M MB) ...`. - They count as named, so "unnamed" is what is left. - `procmem::card_mapped()` hands the last walk's bytes on. **2. The texture line comes down while the PC is short of commit** (`resource.rs`, one call in the 1 Hz sweep in `host.rs`) - New switch `VICTORY_TEXTURE_COMMIT_FLOOR_MB` (4096 by default; `0` gives the old line). - While the PC's commit left is under the floor, the line the texture queue weighs the card against comes down by what is short. That is `room`, the sweep's card rule, slot eviction and the sweep's pressure test. The sweep and slot eviction then let idle textures go down to it, as on a smaller card. - The commit left is counted without the page file's growth (`ullAvailPageFile`), so the line moves before Windows has to grow the page file. - It only acts where the card's memory is in the process's commit: the last walk (every 5 s) found at least half of the card's use mapped write-combined. On a driver that does not map it, and with `VICTORY_PROCESS_MEMORY=0` (no walk), the line is as before. - It comes down 256 MiB a second at most. It goes deeper only once the card's use (as the queue counts it) has followed the last step, and while the texture blocks hold under 512 MiB of free space. Textures let go out of blocks that stay (holes) give no commit back, and new textures fill those holes first, so the line does not go deeper for them. - It goes back up 128 MiB a second once the commit left is 1 GiB over the floor. - **Also on free memory (third commit).** nick0451 (RTX 3090 24 GB, 32 GB RAM, 60 GB page file) found the floor never engaged with a big page file, which is #3443's advice: commit left stayed over 66 GB while free memory sat at 1.4-4.0 GB, and the >1 s frames clustered under about 2.5 GB free. The line now also comes down while `ullAvailPhys` is under `VICTORY_TEXTURE_PHYS_FLOOR_MB` (3072; `0`: commit alone, as before). - When both are short, the cut follows whichever lacks more (`cut_for`; commit on a tie). - The steps, the holds and the deepest cut are the same. - It goes back up only once both are a GiB over their floors (`cut_clear`). - Both floors at `0` turn the cut off. - It never goes deeper than `VICTORY_TEXTURE_CUT_MAX_PERCENT` of the budget (fourth commit; 40 by default since the fifth, from the result above; held to 90; `0`: no cut), and never takes the line under the texture floor (2 GiB of textures, a quarter of the budget on small cards, are always admitted). On a 16 GB card the deepest cut is about 6.1 GB, and on a 24 GB card about 9.4 GB. - Windows and card copies of title buffers keep the old line. They are what shaders read most, and a window in card memory the CPU maps (the first 4 GiB of them on a 16 GB card) takes its bytes out of shared memory, which is resident RAM. - A line says when the cut starts and ends, and every 30 s while it lasts: `texture line under the PC's commit or free memory (VICTORY_TEXTURE_COMMIT_FLOOR_MB=4096, VICTORY_TEXTURE_PHYS_FLOOR_MB=3072): N MB down for commit|free memory ...`, with the free memory beside the commit left. The queue's own line ("the texture queue's room ... against a line of") shows the lowered line. - The decision is a pure function, `next_cut`, with unit tests. ## Verification **Third commit (free-memory floor), on 5fabb46e + the first two:** Windows 11, MSVC, own target dir, `-j 4`, one cargo command at a time: `cargo check -p victory-gpu --tests --locked` passes with no warning; `cargo test -p victory-gpu --lib --locked -- procmem:: resource::tests::...` 23 passed, 0 failed, with the four new tests (`a_cut_is_for_whichever_floor_lacks_more`, `with_a_big_page_file_free_memory_cuts_the_line`, `the_line_goes_back_up_only_when_both_have_room`, `short_of_memory_the_line_waits_and_stops_as_for_commit`) and every earlier one of this branch unchanged; `cargo clippy -p victory-gpu --lib --tests --locked` passes, its five warnings all outside this branch (`host/font.rs`, `host/menu.rs`, `host/panel.rs`). No game was run. **Fourth commit (the deepest cut as a switch):** the same three commands, one at a time: `cargo check` passes with no warning; the filtered tests 24 passed, 0 failed, with `the_deepest_cut_is_a_switch_and_keeps_the_texture_floor` new (the default, held to 90, `0` for none, the RTX 3090's numbers, the texture floor binding on an 8 GB card at 90 %, the cut going past the quarter at 40 %); `cargo clippy` passes, its five warnings outside this branch. **Fifth commit (default 40 %):** the same three commands, one at a time: `cargo check` passes with no warning; the filtered tests 24 passed, 0 failed, with `the_cut_stops_at_its_most` and `the_deepest_cut_is_a_switch_and_keeps_the_texture_floor` now checking 40 % (on an 8 GB card the default stays above the texture floor; 90 % still stops at it); `cargo clippy` passes, its five warnings outside this branch. No game was run. **Earlier, for the first two commits:** Rebased on .02 (84bd61e2): the only conflict was `docs/bug-journal.md` (both 2026-11-30 entries kept), and the commit that fixed a `card_pass` test call was dropped because upstream fixed it in 145f7722. The resource.rs call sites this branch changes are the same on .02. **The `cargo check` and filtered tests below were run on the c71899d9 base. Their re-run on .02 is queued in the shared build slots and had not run when this was written.** Windows 11, MSVC, own target dir, `-j 4`, on the c71899d9 base: - `cargo check -p victory-gpu --tests --locked`: passes. Its one warning (`Shadow::ranged` never used, `shadow.rs`) is on main too. - `cargo test -p victory-gpu --lib --locked -- procmem:: resource::tests::...`: 18 passed, 0 failed. The seven new tests: - `write_combined_private_pages_at_host_addresses_are_counted_apart` (procmem: only private pages at host addresses, inside the private bytes); - `the_line_is_not_cut_when_off_or_when_the_card_is_not_in_the_commit` (switch `0`, a driver that does not map the card, room on the PC); - `short_of_commit_the_line_comes_down_a_step` (one step, or what is short); - `the_line_waits_for_the_card_and_for_blocks_to_go` (no deeper while the card has not followed, or with 512 MiB free in blocks); - `the_cut_stops_at_its_most` (the deepest cut, the texture floor kept); - `with_room_again_the_line_goes_back_up_slowly` (hysteresis and the 128 MiB step); - `a_walk_settles_at_the_floor_or_stops_at_holes`: 120 seconds from the card at its line and 1.2 GB of commit left. When the textures that go empty whole blocks, the cut settles at exactly what was short (2,896 MiB) and the commit left at the floor; when they leave holes it stops after two steps. - The neighbours that read the same lines pass unchanged: `room_line_follows_the_budget`, `copies_stop_at_the_texture_line`, `idle_sweep_policy_keeps_vram_eviction_active_under_host_pressure`, the four `slot_evict*`/`slot_eviction*` tests, `the_oldest_copies_covering_the_need_go`, and procmem's three. - `cargo clippy -p victory-gpu --lib --tests --locked`: passes, no warning on a line this branch adds or changes. Its two warnings are elsewhere and on main (`shadow.rs` `ranged` never used; a manual `is_multiple_of` in `host.rs` at line 5082). `-D warnings` was not used, because main already fails it. - The probe (Analysis above) ran outside the game, in a build slot: 11 steps, the numbers as quoted. ## NOT tested - **The free-memory floor (third commit) was not run in game.** On our 32 GB PC free memory is 0.1-1.3 GB in play, so the cut will be on nearly all the time there and may go down to its most (40 % of the budget) wherever the card can follow. nick0451's runs (above) show the effect on a 24 GB card, and no cost within their route noise. A 16 GB card on our bench, default against `VICTORY_TEXTURE_PHYS_FLOOR_MB=0`, is still to be run. The 3072 MiB floor is a choice from their stall cluster (under ~2.5 GB free), not a measurement of its own. - **Nothing was run in the game.** The bench steps, on the same 32 GB PC, Series X 1440p, the same open-world save, closing Discord and the browser first: 1. A 20-minute walk on main and on this branch, then on this branch with `VICTORY_TEXTURE_COMMIT_FLOOR_MB=0`, alternating, two runs each. 2. From the 5-s timeline and the log: private bytes and their write-combined part over time (minute 5 to 20 should be flat, and lower than main by what the cut took); page file size; page-ins per second; hard faults per second; free RAM; the commit left. 3. From the texture line: how deep the cut went and how long it lasted; the card's use against the budget. 4. fps, frames over 100 ms per 1,000, and the longest frame; texture uploads per second and copies "made again" within 2 s (churn), against main. 5. Pictures at fixed seconds (late or blurry textures where the cut is deep). - **Whether the sweep can bring the card down to the cut line on main.** Slot eviction let go of 0 textures in our 29.x runs. The sweep takes only copies no slot shows. If neither can free enough, the line stays at its first step and new textures wait there, as they already do at the full line ("no room, new textures wait" in most reports on main). #3475 and our perf/slot-evict-frees make the sweep and slot eviction reach their line. - **Whether letting textures go gives commit back depends on whole 64 MiB blocks being let go.** The pool fills the fullest block first and keeps at most two empty ones. The line stops going deeper while 512 MiB lie free in blocks, but how much a cut gives back in play was not measured. - **The 4 GiB floor, the steps, the 512 MiB of holes and the 1 GiB hysteresis are choices, not measurements.** The floor is where the layer's own pressure starts. - **AMD and Intel.** Whether their drivers map the card's memory into the process was not checked. If they do not, the cut stays off. - **Not run on 16 GB PCs or on a 32 GB card.** On a 32 GB card the deepest cut at the default is 40 % of the budget (about 12 GB). - **The 28.03 breakdown by holder.** 28.03 has no memory map. Its private bytes, dedicated and shared memory come from the 5-s timeline only. ## Overlap - **#3869** (Trillazill, diagnostics): host buffers alive by heap, in the PC's memory the card uses. It names the shared part, not the card's memory mapped into the process. Both can land; the lines do not conflict. - **#3475** (nyxctura, conflicting with main): makes the sweep free idle textures under RAM pressure without churn, and keeps slot-shown ones. It changes how the sweep reaches its line; this changes the line. Complementary; both touch `let_go_idle()` near the card rule, so whichever lands second needs a small rebase. - **perf/slot-evict-frees** (ours, Lyrnc/VIctory-NVIDIA, not opened): slot eviction lets go of copies no slot shows. Complementary in the same way. - **#3848** (Trillazill): slot eviction counts the card's use as the queue does. It touches the same `slot_evict()` line computation (`room_eff`); a one-line rebase. - **#2910** (Remorce): windows of title memory grown to what is asked for, -24 % shared memory. That is the third holder above (windows in the PC's memory and their CPU sides). Not carried here: it is 1,400 lines across 16 files, shaders included. - **#3397** (Pierrot1398): texture copies held to 1 GB on 16 GB PCs with 8 GB cards, and a page-file warning. A fixed cap for small PCs; this one follows the commit left on any PC. - **#2038**, **#3406**, **#1944**, **#3070**: texture admission and eviction against the card's budget or critical commit. None lowers the line by the PC's commit headroom. - **#2717**, **#1173**, **#3426**: commit admission for pipelines and compiles. Complementary: they wait for commit, this gives some back. - **#3994** (ours, sends) and **#3381** (spares): the L0 spares' churn. Separate. - **#2234** (snapshot pool), **#2240** (detile buffers), **#2671** (16 GB and smaller PCs): not the holders on this PC (see Analysis). ## AI use Claude Code (Claude Opus 5.5) read the procmem, "memory now", copystat memory-map and room lines of the bench's run logs with its own parsing scripts, fitted the commit change against the card's and the shared memory's, ran the game-free D3D12 probe, read the pools, caches and lines changed since 28.03, wrote both commits and their tests, ran `cargo check` / `cargo test` / `cargo clippy`, and wrote this description. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
Remorce commented 2026-12-01 02:15:32 +00:00 (Migrated from github.com)

Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by Remorce on 2026-12-01T02:15:32Z.


Tested on top of #2910 and #4204. They overlap on one line in procmem.rs, joined as private[0] + ours + write_combined. RTX 4070 Ti 12 GB, 31 GB RAM, 64 GB page file, Series X, DLSS Performance, unattended 12-min runs.

  • The naming matches here too. 16 min into a run without this PR, worked out by hand from the process line: 18.8 GB of host private was unnamed, and the card's use (9.1 GB) plus shared (6.8 GB) covered 15.9 GB of it.
  • At the default it never acts on this PC: commit left stayed at 35–37 GB of a 95 GB limit.
  • Forced (VICTORY_TEXTURE_COMMIT_FLOOR_MB=99999): the cut went to its 2,806 MB max with the line at 7,395 MB. Card held at 7.2–7.3 GB against 8.4 GB and rising without it; texture blocks 2.4–2.5 against 3.6 GB; private 27.8 against 28.7 GB.
<!-- greyfinch-sync:trustno1-coder/VIctory-NVIDIA:comment:7298414338 --> Imported from [trustno1-coder/VIctory-NVIDIA](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/4288#issuecomment-7298414338). Originally posted by [Remorce](https://github.com/Remorce) on 2026-12-01T02:15:32Z. --- Tested on top of #2910 and #4204. They overlap on one line in `procmem.rs`, joined as `private[0] + ours + write_combined`. RTX 4070 Ti 12 GB, 31 GB RAM, 64 GB page file, Series X, DLSS Performance, unattended 12-min runs. - The naming matches here too. 16 min into a run without this PR, worked out by hand from the process line: 18.8 GB of host private was unnamed, and the card's use (9.1 GB) plus shared (6.8 GB) covered 15.9 GB of it. - At the default it never acts on this PC: commit left stayed at 35–37 GB of a 95 GB limit. - Forced (`VICTORY_TEXTURE_COMMIT_FLOOR_MB=99999`): the cut went to its 2,806 MB max with the line at 7,395 MB. Card held at 7.2–7.3 GB against 8.4 GB and rising without it; texture blocks 2.4–2.5 against 3.6 GB; private 27.8 against 28.7 GB.
Lyrnc commented 2026-12-01 03:56:21 +00:00 (Migrated from github.com)

Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by Lyrnc on 2026-12-01T03:56:21Z.


Thanks @Remorce.

  • The naming holds on your 12 GB card too. Of 18.8 GB of unnamed host private memory, the card's use (9.1 GB) plus shared memory (6.8 GB) account for 15.9 GB.
  • At the default (VICTORY_TEXTURE_COMMIT_FLOOR_MB=4096) it should never act on your PC: with 35-37 GB of commit left under a 95 GB limit, you're far above the floor. It's meant for PCs with a small or fixed page file.
  • Forced, the texture line came down by its full 2,806 MB. The card held at 7.2-7.3 GB instead of 8.4 GB and rising, with texture blocks at 2.4-2.5 against 3.6 GB and private memory at 27.8 against 28.7 GB. So it does what it says when it acts. There are no frame-rate numbers yet, so what it costs when it acts is still open.
  • Thanks for noting the procmem.rs overlap with #2910 and #4204. Whichever lands second takes that join.

AI use: Claude Code (Claude Opus 5.5) read your results and wrote this.

<!-- greyfinch-sync:trustno1-coder/VIctory-NVIDIA:comment:7300214745 --> Imported from [trustno1-coder/VIctory-NVIDIA](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/4288#issuecomment-7300214745). Originally posted by [Lyrnc](https://github.com/Lyrnc) on 2026-12-01T03:56:21Z. --- Thanks @Remorce. - The naming holds on your 12 GB card too. Of 18.8 GB of unnamed host private memory, the card's use (9.1 GB) plus shared memory (6.8 GB) account for 15.9 GB. - At the default (`VICTORY_TEXTURE_COMMIT_FLOOR_MB=4096`) it should never act on your PC: with 35-37 GB of commit left under a 95 GB limit, you're far above the floor. It's meant for PCs with a small or fixed page file. - Forced, the texture line came down by its full 2,806 MB. The card held at 7.2-7.3 GB instead of 8.4 GB and rising, with texture blocks at 2.4-2.5 against 3.6 GB and private memory at 27.8 against 28.7 GB. So it does what it says when it acts. There are no frame-rate numbers yet, so what it costs when it acts is still open. - Thanks for noting the `procmem.rs` overlap with #2910 and #4204. Whichever lands second takes that join. AI use: Claude Code (Claude Opus 5.5) read your results and wrote this.
Lyrnc commented 2026-12-01 07:36:01 +00:00 (Migrated from github.com)

Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by Lyrnc on 2026-12-01T07:36:01Z.


Bench result for the A/B from "NOT tested", run this morning. RTX 5080 16 GB (budget 15,209 MB), Ryzen 7 9800X3D, 32 GB RAM, Windows 11. Release builds, one shared shader cache (warmed first):

  • A = main 84bd61e2.
  • B = this PR at 3d7808a8 (VICTORY_TEXTURE_COMMIT_FLOOR_MB default 4096).
  • C = B with VICTORY_TEXTURE_COMMIT_FLOOR_MB=0.

Series X native 1440p, DLSS off, same save. Order A B C A B C, two runs each.

The walks are 10 minutes, not the planned 20. Our bench feeds the route through VICTORY_KEYS_FILE, whose reader caps a line's start at 600 s after it is read, so the walk ends at about world+660 s. The runs were cut to 720 s and the numbers cover world+30..630 s. No other game was running on the PC during these runs, and no run was flagged.

arm window (world+s) fps >50 ms /1000 draws/frame card MB in use (med / max) private MB (median) free commit, min MB page-ins/s
A1 30-330 26.7 174 7,320 14,376 / 14,783 29,316 460 3,432
330-630 29.7 112 5,792 14,785 / 14,867 29,641 627 3,978
A2 30-330 25.5 206 8,700 14,359 / 14,725 29,555 363 3,924
330-630 28.5 71 5,798 14,430 / 14,610 28,971 928 3,549
B1 30-330 25.9 191 8,539 14,099 / 14,112 29,288 447 2,078
330-630 26.6 180 8,728 14,179 / 14,267 29,607 638 1,090
B2 30-330 26.1 191 8,090 14,446 / 14,835 29,530 289 3,833
330-630 28.0 142 5,902 14,738 / 14,844 30,318 922 1,677
C1 30-330 27.2 171 7,703 14,432 / 14,798 29,480 379 2,665
330-630 30.0 121 5,784 14,869 / 14,884 29,720 584 341
C2 30-330 27.2 159 7,271 14,145 / 14,329 28,923 471 2,729
330-630 26.8 166 8,338 14,332 / 14,396 29,404 895 7,205

Peak private bytes: A 30.1-30.2 GB, B 30.0-30.8, C 29.6-30.2. Free commit low: A 363-460 MB, B 289-362, C 366-471.

The new lines in B:

  • "texture line under the PC's commit": 22 lines per run. The cut was on for ~400 s of each run, at most 768 MB (B1) and 512 MB (B2) down, taking the line to 13,417 and 13,673 MB. The PC's commit left was as low as 450-490 MB while it was on.
  • The memory line names 15.5-16.3 GB of the process's private bytes as write-combined, the card's memory mapped in (card use 14.1-14.9 GB). C1 shows the same, 15.9-16.3 GB.

No device removed, DRED or "did not close" line in any run.

What this shows

  • The cut starts as designed: under the floor it lowers the texture line by 512-768 MB and says so. With =0 (C) there is no cut line, and C reads like A.
  • It gives no commit back in these runs. B's private bytes (29.3-30.3 GB by 5-minute median, peak 30.0-30.8 GB) and lowest free commit (289-362 MB) are no better than A's (29.0-29.6 GB, peak 30.1-30.2 GB, 363-460 MB). The card's use stayed above the lowered line, e.g. B1 at 14,099-14,267 MB against a line of 13,417. So the textures over it were not let go. This is the open point "whether the sweep can bring the card down to the cut line" under "NOT tested": here it could not.
  • The write-combined naming works: that part of private bytes is now visible, at about the card's use plus 1.3-1.5 GB.

What it does not show

  • Minutes 10-20. The climb the description reports (28.4 → 33.1 GB in five minutes) is not in these numbers. Private bytes here sit at 29-30 GB from the first window on.
  • Frame rates. No difference beyond the spread. Draws per frame differ by up to 50 % between runs in the second window, because the walks reach different views.
  • Pictures. None (release builds).
  • Not tested: 16 GB PCs, other GPUs, and a run with #3475 or slot-evict-frees, which would let the sweep reach the lowered line.

AI use: Claude Code (Claude Opus 5.5) ran these on our bench queue, parsed the run logs and the bench's 5 s timeline with its own scripts, and wrote this comment.

<!-- greyfinch-sync:trustno1-coder/VIctory-NVIDIA:comment:7304254819 --> Imported from [trustno1-coder/VIctory-NVIDIA](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/4288#issuecomment-7304254819). Originally posted by [Lyrnc](https://github.com/Lyrnc) on 2026-12-01T07:36:01Z. --- Bench result for the A/B from "NOT tested", run this morning. RTX 5080 16 GB (budget 15,209 MB), Ryzen 7 9800X3D, 32 GB RAM, Windows 11. Release builds, one shared shader cache (warmed first): - **A** = main 84bd61e2. - **B** = this PR at 3d7808a8 (`VICTORY_TEXTURE_COMMIT_FLOOR_MB` default 4096). - **C** = B with `VICTORY_TEXTURE_COMMIT_FLOOR_MB=0`. Series X native 1440p, DLSS off, same save. Order A B C A B C, two runs each. **The walks are 10 minutes, not the planned 20.** Our bench feeds the route through `VICTORY_KEYS_FILE`, whose reader caps a line's start at 600 s after it is read, so the walk ends at about world+660 s. The runs were cut to 720 s and the numbers cover world+30..630 s. No other game was running on the PC during these runs, and no run was flagged. | arm | window (world+s) | fps | >50 ms /1000 | draws/frame | card MB in use (med / max) | private MB (median) | free commit, min MB | page-ins/s | |---|---|---:|---:|---:|---|---:|---:|---:| | A1 | 30-330 | 26.7 | 174 | 7,320 | 14,376 / 14,783 | 29,316 | 460 | 3,432 | | | 330-630 | 29.7 | 112 | 5,792 | 14,785 / 14,867 | 29,641 | 627 | 3,978 | | A2 | 30-330 | 25.5 | 206 | 8,700 | 14,359 / 14,725 | 29,555 | 363 | 3,924 | | | 330-630 | 28.5 | 71 | 5,798 | 14,430 / 14,610 | 28,971 | 928 | 3,549 | | B1 | 30-330 | 25.9 | 191 | 8,539 | 14,099 / 14,112 | 29,288 | 447 | 2,078 | | | 330-630 | 26.6 | 180 | 8,728 | 14,179 / 14,267 | 29,607 | 638 | 1,090 | | B2 | 30-330 | 26.1 | 191 | 8,090 | 14,446 / 14,835 | 29,530 | 289 | 3,833 | | | 330-630 | 28.0 | 142 | 5,902 | 14,738 / 14,844 | 30,318 | 922 | 1,677 | | C1 | 30-330 | 27.2 | 171 | 7,703 | 14,432 / 14,798 | 29,480 | 379 | 2,665 | | | 330-630 | 30.0 | 121 | 5,784 | 14,869 / 14,884 | 29,720 | 584 | 341 | | C2 | 30-330 | 27.2 | 159 | 7,271 | 14,145 / 14,329 | 28,923 | 471 | 2,729 | | | 330-630 | 26.8 | 166 | 8,338 | 14,332 / 14,396 | 29,404 | 895 | 7,205 | Peak private bytes: A 30.1-30.2 GB, B 30.0-30.8, C 29.6-30.2. Free commit low: A 363-460 MB, B 289-362, C 366-471. The new lines in B: - "texture line under the PC's commit": 22 lines per run. The cut was on for ~400 s of each run, at most 768 MB (B1) and 512 MB (B2) down, taking the line to 13,417 and 13,673 MB. The PC's commit left was as low as 450-490 MB while it was on. - The memory line names 15.5-16.3 GB of the process's private bytes as write-combined, the card's memory mapped in (card use 14.1-14.9 GB). C1 shows the same, 15.9-16.3 GB. No device removed, DRED or "did not close" line in any run. **What this shows** - **The cut starts as designed:** under the floor it lowers the texture line by 512-768 MB and says so. With `=0` (C) there is no cut line, and C reads like A. - **It gives no commit back in these runs.** B's private bytes (29.3-30.3 GB by 5-minute median, peak 30.0-30.8 GB) and lowest free commit (289-362 MB) are no better than A's (29.0-29.6 GB, peak 30.1-30.2 GB, 363-460 MB). The card's use stayed above the lowered line, e.g. B1 at 14,099-14,267 MB against a line of 13,417. So the textures over it were not let go. This is the open point "whether the sweep can bring the card down to the cut line" under "NOT tested": here it could not. - **The write-combined naming works:** that part of private bytes is now visible, at about the card's use plus 1.3-1.5 GB. **What it does not show** - **Minutes 10-20.** The climb the description reports (28.4 → 33.1 GB in five minutes) is not in these numbers. Private bytes here sit at 29-30 GB from the first window on. - **Frame rates.** No difference beyond the spread. Draws per frame differ by up to 50 % between runs in the second window, because the walks reach different views. - **Pictures.** None (release builds). - Not tested: 16 GB PCs, other GPUs, and a run with #3475 or slot-evict-frees, which would let the sweep reach the lowered line. AI use: Claude Code (Claude Opus 5.5) ran these on our bench queue, parsed the run logs and the bench's 5 s timeline with its own scripts, and wrote this comment.
nick0451 commented 2026-12-01 10:01:02 +00:00 (Migrated from github.com)

Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by nick0451 on 2026-12-01T10:01:02Z.


Tested on the case your description couldn't check, a card with more memory than half the PC: RTX 3090 24 GB (driver 610.88), 32 GB RAM, i9-14900K, Series S, DLSS performance. Your head 746b77ec with #4694 applied locally (otherwise the #2469 retry storm dominates), release, LTO off. Off-screen, city save, the same scripted walk every start (forward, strafe, back), 15 minutes each, alternating, with a private-allocation walk (VirtualQueryEx, committed MEM_PRIVATE grouped by size and protection) every minute.

Your analysis holds here too. In every walk, the 64 MiB write-combined private allocations grew with the card's texture use and nothing else did:

run private, GB 64 MiB write-combined allocations the texture queue's use (line) growth seconds with a frame >100 ms
default (floor 4096), 1 25.5 → 33.5 89 → 195 20.1 GB (21.9) 0.49 GB/min 128 of 974
VICTORY_TEXTURE_COMMIT_FLOOR_MB=0, 1 25.8 → 34.0 96 → 192 20.4 GB (21.9) 0.50 GB/min 81 of 979
default, 2 25.8 → 34.0 91 → 189 20.2 GB (21.9) 0.52 GB/min 83 of 957
VICTORY_TEXTURE_COMMIT_FLOOR_MB=0, 2 25.0 → 33.3 95 → 198 20.5 GB (21.9) 0.54 GB/min 65 of 984

Standing still for 15 minutes gave +7 to +9 of those allocations; walking gave +81 to +106. With VICTORY_VRAM_BUDGET_MB=12000 (on main + #4694), the queue stopped at 10.7 GB against an 11.2 GB line, the allocations went 92 → 118 and 90 → 120, and growth was 0.13 / 0.08 GB/min, flat at about 28 GB from minute 3 in both. So lowering the line does stop it.

But the floor never engaged on this PC. There were no "texture line under the PC's commit" lines in either default run. commit_cut_tick measures headroom as ullAvailPageFile. This PC has a 60 GB page file (commit limit about 94 GB), so the commit left never went below 66 GB, while free physical memory sat at 1.4–4.0 GB the whole time. That's where the cost was: on a drive earlier tonight (main f5c3d243 + #4694, so without this branch), the >1 s frames clustered once free memory fell under about 2.5 GB (stalls of 4.5–7.4 s, with the card and the submitting thread idle).

A large page file is the advice #3443 gives, and on any PC that follows it, the floor stays off. Would it work to also cut the line on available physical memory (ullAvailPhys, perhaps against a floor like 3–4 GB), or on whichever of the two is shorter? The cut-down path you built is exactly what the 12 GB budget runs show is needed. It's only the trigger that doesn't see this PC.

<!-- greyfinch-sync:trustno1-coder/VIctory-NVIDIA:comment:7307542594 --> Imported from [trustno1-coder/VIctory-NVIDIA](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/4288#issuecomment-7307542594). Originally posted by [nick0451](https://github.com/nick0451) on 2026-12-01T10:01:02Z. --- Tested on the case your description couldn't check, a card with more memory than half the PC: RTX 3090 24 GB (driver 610.88), 32 GB RAM, i9-14900K, Series S, DLSS performance. Your head `746b77ec` with #4694 applied locally (otherwise the #2469 retry storm dominates), release, LTO off. Off-screen, city save, the same scripted walk every start (forward, strafe, back), 15 minutes each, alternating, with a private-allocation walk (`VirtualQueryEx`, committed `MEM_PRIVATE` grouped by size and protection) every minute. **Your analysis holds here too.** In every walk, the 64 MiB write-combined private allocations grew with the card's texture use and nothing else did: | run | private, GB | 64 MiB write-combined allocations | the texture queue's use (line) | growth | seconds with a frame >100 ms | |---|---|---|---|---|---| | default (floor 4096), 1 | 25.5 → 33.5 | 89 → 195 | 20.1 GB (21.9) | 0.49 GB/min | 128 of 974 | | `VICTORY_TEXTURE_COMMIT_FLOOR_MB=0`, 1 | 25.8 → 34.0 | 96 → 192 | 20.4 GB (21.9) | 0.50 GB/min | 81 of 979 | | default, 2 | 25.8 → 34.0 | 91 → 189 | 20.2 GB (21.9) | 0.52 GB/min | 83 of 957 | | `VICTORY_TEXTURE_COMMIT_FLOOR_MB=0`, 2 | 25.0 → 33.3 | 95 → 198 | 20.5 GB (21.9) | 0.54 GB/min | 65 of 984 | Standing still for 15 minutes gave +7 to +9 of those allocations; walking gave +81 to +106. With `VICTORY_VRAM_BUDGET_MB=12000` (on main + #4694), the queue stopped at 10.7 GB against an 11.2 GB line, the allocations went 92 → 118 and 90 → 120, and growth was 0.13 / 0.08 GB/min, flat at about 28 GB from minute 3 in both. So lowering the line does stop it. **But the floor never engaged on this PC.** There were no "texture line under the PC's commit" lines in either default run. `commit_cut_tick` measures headroom as `ullAvailPageFile`. This PC has a 60 GB page file (commit limit about 94 GB), so the commit left never went below 66 GB, while free physical memory sat at 1.4–4.0 GB the whole time. That's where the cost was: on a drive earlier tonight (main `f5c3d243` + #4694, so without this branch), the >1 s frames clustered once free memory fell under about 2.5 GB (stalls of 4.5–7.4 s, with the card and the submitting thread idle). A large page file is the advice #3443 gives, and on any PC that follows it, the floor stays off. Would it work to also cut the line on available physical memory (`ullAvailPhys`, perhaps against a floor like 3–4 GB), or on whichever of the two is shorter? The cut-down path you built is exactly what the 12 GB budget runs show is needed. It's only the trigger that doesn't see this PC.
Lyrnc commented 2026-12-01 10:17:25 +00:00 (Migrated from github.com)

Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by Lyrnc on 2026-12-01T10:17:25Z.


Thanks @nick0451, that's the case I couldn't test here, and the logging made it easy to follow.

You're right about the trigger. With a 60 GB page file the commit left never gets near 4 GB, so the floor could not engage on your PC, even though the cut itself works (your VICTORY_VRAM_BUDGET_MB=12000 runs show that).

What changed (cbfc55e4):

  • The line now also comes down while free memory (ullAvailPhys) is under a new VICTORY_TEXTURE_PHYS_FLOOR_MB, default 3072, above the ~2.5 GB where your >1 s frames clustered.
  • When both are short, the cut follows whichever of the two lacks more. The log line says which ("... MB down for free memory" or "for commit") and prints free memory next to the commit left.
  • The steps and holds are the same as before: 256 MiB a second at most. It goes no deeper until the card's use has followed, or while 512 MiB sit free in texture blocks, and never more than a quarter of the budget. It goes back up only once both commit and free memory are a GiB over their floors.
  • VICTORY_TEXTURE_PHYS_FLOOR_MB=0 gives the commit-only behaviour you tested. VICTORY_TEXTURE_COMMIT_FLOOR_MB=0 plus the new one at 0 turns the cut off.
  • There are four new unit tests: which floor a cut is for, your big-page-file case, recovery only once both are clear, and the same holds under memory pressure.

On your PC this should engage within a minute of the world loading, since free memory was 1.4-4.0 GB in your walks. The quarter-of-budget limit lets it take the line down by up to about 6 GB on your 24 GB card.

Could you rerun your walk on the new head, default against VICTORY_TEXTURE_PHYS_FLOOR_MB=0, with the same allocation walk every minute? The numbers that would settle it:

  • how deep the cut goes and for which floor (the "texture line under the PC's commit or free memory" lines);
  • whether free memory rises and the 64 MiB write-combined allocations stop growing;
  • the seconds with a frame over 100 ms, and especially the >1 s stalls;
  • any textures that look late or blurry where the cut is deep.

The open risk is cost, not effect. Textures the sweep lets go may come back, and the sweep can only bring the card down to the line if it finds idle copies to let go. Your 12 GB-budget runs suggest it can.

AI use: Claude Code (Claude Opus 5.5) read your review, wrote the change and its tests, ran cargo check / cargo test / cargo clippy on it, and wrote this reply. No game was run for this change.

<!-- greyfinch-sync:trustno1-coder/VIctory-NVIDIA:comment:7307958995 --> Imported from [trustno1-coder/VIctory-NVIDIA](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/4288#issuecomment-7307958995). Originally posted by [Lyrnc](https://github.com/Lyrnc) on 2026-12-01T10:17:25Z. --- Thanks @nick0451, that's the case I couldn't test here, and the logging made it easy to follow. You're right about the trigger. With a 60 GB page file the commit left never gets near 4 GB, so the floor could not engage on your PC, even though the cut itself works (your `VICTORY_VRAM_BUDGET_MB=12000` runs show that). **What changed (cbfc55e4):** - The line now also comes down while free memory (`ullAvailPhys`) is under a new `VICTORY_TEXTURE_PHYS_FLOOR_MB`, default 3072, above the ~2.5 GB where your >1 s frames clustered. - When both are short, the cut follows whichever of the two lacks more. The log line says which ("... MB down for free memory" or "for commit") and prints free memory next to the commit left. - The steps and holds are the same as before: 256 MiB a second at most. It goes no deeper until the card's use has followed, or while 512 MiB sit free in texture blocks, and never more than a quarter of the budget. It goes back up only once both commit and free memory are a GiB over their floors. - `VICTORY_TEXTURE_PHYS_FLOOR_MB=0` gives the commit-only behaviour you tested. `VICTORY_TEXTURE_COMMIT_FLOOR_MB=0` plus the new one at `0` turns the cut off. - There are four new unit tests: which floor a cut is for, your big-page-file case, recovery only once both are clear, and the same holds under memory pressure. On your PC this should engage within a minute of the world loading, since free memory was 1.4-4.0 GB in your walks. The quarter-of-budget limit lets it take the line down by up to about 6 GB on your 24 GB card. Could you rerun your walk on the new head, default against `VICTORY_TEXTURE_PHYS_FLOOR_MB=0`, with the same allocation walk every minute? The numbers that would settle it: - how deep the cut goes and for which floor (the "texture line under the PC's commit or free memory" lines); - whether free memory rises and the 64 MiB write-combined allocations stop growing; - the seconds with a frame over 100 ms, and especially the >1 s stalls; - any textures that look late or blurry where the cut is deep. The open risk is cost, not effect. Textures the sweep lets go may come back, and the sweep can only bring the card down to the line if it finds idle copies to let go. Your 12 GB-budget runs suggest it can. AI use: Claude Code (Claude Opus 5.5) read your review, wrote the change and its tests, ran `cargo check` / `cargo test` / `cargo clippy` on it, and wrote this reply. No game was run for this change.
nick0451 commented 2026-12-01 10:19:08 +00:00 (Migrated from github.com)

Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by nick0451 on 2026-12-01T10:19:08Z.


@Lyrnc Thanks, that was quick. cbfc55e4 (with #4694 applied locally, as before) is queued: default against VICTORY_TEXTURE_PHYS_FLOOR_MB=0, the same 15-minute walks with the allocation walk every minute, two rounds each. I'll report the cut lines and depth, free memory, the 64 MiB allocations, the >100 ms and >1 s frames, and whether the per-minute shots show late or blurry textures where the cut is deep. It starts after a test that's already running, so the numbers should be here in about three hours.

<!-- greyfinch-sync:trustno1-coder/VIctory-NVIDIA:comment:7308005403 --> Imported from [trustno1-coder/VIctory-NVIDIA](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/4288#issuecomment-7308005403). Originally posted by [nick0451](https://github.com/nick0451) on 2026-12-01T10:19:08Z. --- @Lyrnc Thanks, that was quick. `cbfc55e4` (with #4694 applied locally, as before) is queued: default against `VICTORY_TEXTURE_PHYS_FLOOR_MB=0`, the same 15-minute walks with the allocation walk every minute, two rounds each. I'll report the cut lines and depth, free memory, the 64 MiB allocations, the >100 ms and >1 s frames, and whether the per-minute shots show late or blurry textures where the cut is deep. It starts after a test that's already running, so the numbers should be here in about three hours.
nick0451 commented 2026-12-01 12:29:37 +00:00 (Migrated from github.com)

Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by nick0451 on 2026-12-01T12:29:37Z.


@Lyrnc Results for cbfc55e4, with #4694 applied locally as before. Same PC (RTX 3090 24 GB, driver 610.88, 32 GB RAM, 60 GB page file, Series S, DLSS performance), the same 15-minute off-screen walks, allocation walk and screenshot every minute, alternating, settings checked after every run.

run the cut private, GB 64 MiB write-combined allocations free memory, mean / min growth s with a frame >100 ms frames >1 s
default, 1 "for free memory", started ~1 min in, at its most (5,888 MB) from ~6 min: line 22,093 → 16,231 MB 25.2 → 28.4 97 → 115 1.6 / 1.0 GB 0.08 GB/min 117 of 967 19
VICTORY_TEXTURE_PHYS_FLOOR_MB=0, 1 none 25.0 → 33.5 96 → 204 1.6 / 0.44 GB 0.55 GB/min 49 of 986 5
default, 2 same, at its most 25.3 → 27.0 95 → 117 2.2 / 2.0 GB 0.04 GB/min 29 of 985 2
VICTORY_TEXTURE_PHYS_FLOOR_MB=0, 2 none 25.2 → 32.5 91 → 198 1.65 / 1.15 GB 0.46 GB/min 38 of 988 2

The effect is clear. The cut engaged within about a minute, and the log line names the floor ("… MB down for free memory"). The card then held at about 15.3–16.0 GB against roughly 20 GB without it. The 64 MiB allocations grew +18 / +22 against +107 / +108, and private memory stopped at 27–28.4 GB where it otherwise climbs past 32.

Two things to know:

  • The cut hit its cap and stayed there. Free memory stayed under the 3,072 MB floor in every run, so the line sat at the quarter-of-budget limit (5,888 MB down) for most of each run. In default run 1, free memory still fell from 2.7 to 1.0 GB, while the game's own working set (19.3–19.8 GB), private bytes and file-backed CPU mirrors (about 3.1 GB) were all flat. So the rest of that drain was outside this process, and no line could have fixed it. On a 24 GB card with 32 GB of RAM, the quarter cap may be what stops it short; I can't tell if a deeper cut would help.
  • The cost isn't settled by these runs. The stall columns favour =0 in round 1 and are close in round 2, but our walk is driven by held keys, and it wanders differently from start to start. Default run 2 spent its time in back yards and alleys, =0 run 1 crossed streets and parking lots. So the >100 ms counts reflect the route as much as the build. I'm switching the bench to a pad tape (VICTORY_INPUT_REPLAY, the same route every start) and will rerun the cost question on it.

Textures: looking at the per-minute shots from the two cut runs, the character's clothing, cars, posters, signs and a wrecked van all look right; nothing late or blurry at that size. One shot a minute won't catch a brief blur, though.

<!-- greyfinch-sync:trustno1-coder/VIctory-NVIDIA:comment:7311209869 --> Imported from [trustno1-coder/VIctory-NVIDIA](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/4288#issuecomment-7311209869). Originally posted by [nick0451](https://github.com/nick0451) on 2026-12-01T12:29:37Z. --- @Lyrnc Results for `cbfc55e4`, with #4694 applied locally as before. Same PC (RTX 3090 24 GB, driver 610.88, 32 GB RAM, 60 GB page file, Series S, DLSS performance), the same 15-minute off-screen walks, allocation walk and screenshot every minute, alternating, settings checked after every run. | run | the cut | private, GB | 64 MiB write-combined allocations | free memory, mean / min | growth | s with a frame >100 ms | frames >1 s | |---|---|---|---|---|---|---|---| | default, 1 | "for free memory", started ~1 min in, at its most (5,888 MB) from ~6 min: line 22,093 → 16,231 MB | 25.2 → 28.4 | 97 → 115 | 1.6 / 1.0 GB | 0.08 GB/min | 117 of 967 | 19 | | `VICTORY_TEXTURE_PHYS_FLOOR_MB=0`, 1 | none | 25.0 → 33.5 | 96 → 204 | 1.6 / 0.44 GB | 0.55 GB/min | 49 of 986 | 5 | | default, 2 | same, at its most | 25.3 → 27.0 | 95 → 117 | 2.2 / 2.0 GB | 0.04 GB/min | 29 of 985 | 2 | | `VICTORY_TEXTURE_PHYS_FLOOR_MB=0`, 2 | none | 25.2 → 32.5 | 91 → 198 | 1.65 / 1.15 GB | 0.46 GB/min | 38 of 988 | 2 | **The effect is clear.** The cut engaged within about a minute, and the log line names the floor ("… MB down for free memory"). The card then held at about 15.3–16.0 GB against roughly 20 GB without it. The 64 MiB allocations grew +18 / +22 against +107 / +108, and private memory stopped at 27–28.4 GB where it otherwise climbs past 32. **Two things to know:** - **The cut hit its cap and stayed there.** Free memory stayed under the 3,072 MB floor in every run, so the line sat at the quarter-of-budget limit (5,888 MB down) for most of each run. In default run 1, free memory still fell from 2.7 to 1.0 GB, while the game's own working set (19.3–19.8 GB), private bytes and file-backed CPU mirrors (about 3.1 GB) were all flat. So the rest of that drain was outside this process, and no line could have fixed it. On a 24 GB card with 32 GB of RAM, the quarter cap may be what stops it short; I can't tell if a deeper cut would help. - **The cost isn't settled by these runs.** The stall columns favour `=0` in round 1 and are close in round 2, but our walk is driven by held keys, and it wanders differently from start to start. Default run 2 spent its time in back yards and alleys, `=0` run 1 crossed streets and parking lots. So the >100 ms counts reflect the route as much as the build. I'm switching the bench to a pad tape (`VICTORY_INPUT_REPLAY`, the same route every start) and will rerun the cost question on it. **Textures:** looking at the per-minute shots from the two cut runs, the character's clothing, cars, posters, signs and a wrecked van all look right; nothing late or blurry at that size. One shot a minute won't catch a brief blur, though.
Lyrnc commented 2026-12-01 12:47:14 +00:00 (Migrated from github.com)

Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by Lyrnc on 2026-12-01T12:47:14Z.


Thanks @nick0451, that's a very clear result, and the per-minute allocation walk made it easy to read: the cut engaging on free memory within about a minute, growth down from ~0.5 to 0.04-0.08 GB/min, private memory stopping at 27-28 GB instead of passing 32, and the 64 MiB allocations at +18/+22 instead of +107.

You're right that the quarter cap is what limited it on your PC. The deepest cut is now a switch (141d038d):

  • VICTORY_TEXTURE_CUT_MAX_PERCENT, a percent of the card's budget. The default is 25, the same quarter as before. It is held to 90, and 0 turns the cut off.
  • It still never takes the line under the texture floor (2 GiB of textures are always admitted). On your card (budget about 23.5 GB, line about 22.1 GB), 40 % allows up to about 9.4 GB down and 50 % about 11.8 GB.
  • The log line prints the switch beside the "MB at most" figure, so a run shows which cap it had.
  • One new unit test covers the default, the 90 % limit, 0, your card's numbers and the floor on an 8 GB card. The other tests are unchanged.

Two questions:

  • Could your pad-tape replay rerun add one arm at VICTORY_TEXTURE_CUT_MAX_PERCENT=40, beside the default and VICTORY_TEXTURE_PHYS_FLOOR_MB=0? With the same route every start, that should show both what the cut costs and whether a deeper one keeps free memory any higher, or only takes more textures.
  • The drain outside the process: in default run 1, free memory fell from 2.7 to 1.0 GB while the game's working set, private bytes and file-backed mirrors stayed flat. Do you know what was taking it? For example the standby list or the file cache (the DirectStorage reads would land there), memory compression, or another process. If it's the file cache, no texture line can win that back, and the floor would only push the cut to its cap. A RAMMap or Process Explorer snapshot at the start and end of a run would tell.

AI use: Claude Code (Claude Opus 5.5) read your results, wrote the switch and its test, ran cargo check / cargo test / cargo clippy on it, and wrote this reply. No game was run for this change.

<!-- greyfinch-sync:trustno1-coder/VIctory-NVIDIA:comment:7311645712 --> Imported from [trustno1-coder/VIctory-NVIDIA](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/4288#issuecomment-7311645712). Originally posted by [Lyrnc](https://github.com/Lyrnc) on 2026-12-01T12:47:14Z. --- Thanks @nick0451, that's a very clear result, and the per-minute allocation walk made it easy to read: the cut engaging on free memory within about a minute, growth down from ~0.5 to 0.04-0.08 GB/min, private memory stopping at 27-28 GB instead of passing 32, and the 64 MiB allocations at +18/+22 instead of +107. You're right that the quarter cap is what limited it on your PC. **The deepest cut is now a switch (141d038d):** - `VICTORY_TEXTURE_CUT_MAX_PERCENT`, a percent of the card's budget. The default is 25, the same quarter as before. It is held to 90, and `0` turns the cut off. - It still never takes the line under the texture floor (2 GiB of textures are always admitted). On your card (budget about 23.5 GB, line about 22.1 GB), 40 % allows up to about 9.4 GB down and 50 % about 11.8 GB. - The log line prints the switch beside the "MB at most" figure, so a run shows which cap it had. - One new unit test covers the default, the 90 % limit, `0`, your card's numbers and the floor on an 8 GB card. The other tests are unchanged. Two questions: - **Could your pad-tape replay rerun add one arm at `VICTORY_TEXTURE_CUT_MAX_PERCENT=40`**, beside the default and `VICTORY_TEXTURE_PHYS_FLOOR_MB=0`? With the same route every start, that should show both what the cut costs and whether a deeper one keeps free memory any higher, or only takes more textures. - **The drain outside the process:** in default run 1, free memory fell from 2.7 to 1.0 GB while the game's working set, private bytes and file-backed mirrors stayed flat. Do you know what was taking it? For example the standby list or the file cache (the DirectStorage reads would land there), memory compression, or another process. If it's the file cache, no texture line can win that back, and the floor would only push the cut to its cap. A RAMMap or Process Explorer snapshot at the start and end of a run would tell. AI use: Claude Code (Claude Opus 5.5) read your results, wrote the switch and its test, ran `cargo check` / `cargo test` / `cargo clippy` on it, and wrote this reply. No game was run for this change.
nick0451 commented 2026-12-01 12:49:37 +00:00 (Migrated from github.com)

Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by nick0451 on 2026-12-01T12:49:37Z.


@Lyrnc Will do. The pad-tape route is being tried out this morning; once it repeats reliably, the rerun on 141d038d will have three arms (default, VICTORY_TEXTURE_PHYS_FLOOR_MB=0, VICTORY_TEXTURE_CUT_MAX_PERCENT=40), two rounds each, on the same route every start. For the drain, each minute will also log the system's memory counters (available, standby, modified, cache, the Memory Compression process) and the five processes using the most memory, so we can see whether it's the file cache, compression or something else. I don't know yet what took it in run 1.

<!-- greyfinch-sync:trustno1-coder/VIctory-NVIDIA:comment:7311702968 --> Imported from [trustno1-coder/VIctory-NVIDIA](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/4288#issuecomment-7311702968). Originally posted by [nick0451](https://github.com/nick0451) on 2026-12-01T12:49:37Z. --- @Lyrnc Will do. The pad-tape route is being tried out this morning; once it repeats reliably, the rerun on `141d038d` will have three arms (default, `VICTORY_TEXTURE_PHYS_FLOOR_MB=0`, `VICTORY_TEXTURE_CUT_MAX_PERCENT=40`), two rounds each, on the same route every start. For the drain, each minute will also log the system's memory counters (available, standby, modified, cache, the Memory Compression process) and the five processes using the most memory, so we can see whether it's the file cache, compression or something else. I don't know yet what took it in run 1.
nick0451 commented 2026-12-01 15:11:02 +00:00 (Migrated from github.com)

Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by nick0451 on 2026-12-01T15:11:02Z.


@Lyrnc Results for 141d038d (with #4694 applied locally): three arms, two runs each, alternating, on the same PC as before. 15 minutes in the world each, the allocation walk and system memory counters every minute; the frame columns cover the run after its first minute.

The route. Each run replayed the same pad tape (VICTORY_INPUT_REPLAY: stick walking with camera turns, started by the .go file once the world was in). It repeats less than I'd hoped. Two runs are in different places by 47 s, because the camera's start, the traffic and the load time differ, and the differences compound. So treat the frame columns as indicative, not a controlled comparison. The memory columns don't depend on the route.

arm private, GB 64 MiB write-combined allocations available RAM, mean / min (after 3 min) the deepest cut (cap) s with a frame >100 ms frames >1 s
default, 25 % (a) 25.0 → 27.5 91 → 114 1.5 / 1.2 GB 5,888 MB (5,888) 41 of 871 1
default, 25 % (b) 24.8 → 27.8 89 → 112 1.8 / 1.0 GB 5,888 MB (5,888) 49 of 879 4
VICTORY_TEXTURE_PHYS_FLOOR_MB=0 (a) 26.6 → 30.6 95 → 158 1.7 / 1.4 GB none 21 of 908 1
VICTORY_TEXTURE_PHYS_FLOOR_MB=0 (b) 25.0 → 30.4 93 → 173 1.8 / 1.3 GB none 21 of 888 0
VICTORY_TEXTURE_CUT_MAX_PERCENT=40 (a) 25.0 → 26.5 97 → 105 2.1 / 1.8 GB 7,384 MB (9,421) 12 of 872 2
VICTORY_TEXTURE_CUT_MAX_PERCENT=40 (b) 25.0 → 25.3 90 → 89 2.2 / 2.1 GB 7,944 MB (9,421) 15 of 889 0

(A third default run is left out: it got a 6-minute tape by my mistake and stood idle for the rest. It was 24.7 → 26.9 GB, 87 → 111, 40 of 889, in line with the two above.)

What it shows:

  • 40 % is the arm that settles. The cut found its level at 7.4–7.9 GB without reaching the 9.4 GB cap, and the write-combined allocations stopped growing (+8, then −1). Private memory stayed flat, and available RAM held at about 2 GB. At the default 25 % the cut sits at its cap all run, the allocations still grow about +23, and available RAM goes lower.
  • I see no cost from the cut, within this noise. 40 % had the fewest slow seconds of the three arms (12 and 15, against 21 and 21 without the free-memory floor and 41 and 49 at 25 %), and the per-minute shots show nothing late or blurry. My guess is that 25 % hits its cap while still short of free memory, so the PC pages, while 40 % lets it reach a balance. But with these routes I wouldn't call that more than a hint.

The drain outside the process. On this PC, "available" was almost all standby: truly free plus zeroed pages stayed at 3–155 MB in every run. Over a run, standby went from about 2.7–3.2 GB down to 1.6–2.0 GB. It went to:

  • the game's working set, +0.6–0.8 GB (17.9 → 18.7 GB);
  • the system file cache, about 1.0 → 1.5 GB, consistent with the DirectStorage reads.

Memory compression stayed flat at about 0.97 GB, and no other process grew (Edge about 1.1 GB, Defender 0.43 GB). So it is mostly the file cache, as you suspected, plus a little of the game's own working set. The floor can't take that back, which may be why 25 % runs into its cap here.

<!-- greyfinch-sync:trustno1-coder/VIctory-NVIDIA:comment:7315484680 --> Imported from [trustno1-coder/VIctory-NVIDIA](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/4288#issuecomment-7315484680). Originally posted by [nick0451](https://github.com/nick0451) on 2026-12-01T15:11:02Z. --- @Lyrnc Results for `141d038d` (with #4694 applied locally): three arms, two runs each, alternating, on the same PC as before. 15 minutes in the world each, the allocation walk and system memory counters every minute; the frame columns cover the run after its first minute. **The route.** Each run replayed the same pad tape (`VICTORY_INPUT_REPLAY`: stick walking with camera turns, started by the `.go` file once the world was in). It repeats less than I'd hoped. Two runs are in different places by 47 s, because the camera's start, the traffic and the load time differ, and the differences compound. So treat the frame columns as indicative, not a controlled comparison. The memory columns don't depend on the route. | arm | private, GB | 64 MiB write-combined allocations | available RAM, mean / min (after 3 min) | the deepest cut (cap) | s with a frame >100 ms | frames >1 s | |---|---|---|---|---|---|---| | default, 25 % (a) | 25.0 → 27.5 | 91 → 114 | 1.5 / 1.2 GB | 5,888 MB (5,888) | 41 of 871 | 1 | | default, 25 % (b) | 24.8 → 27.8 | 89 → 112 | 1.8 / 1.0 GB | 5,888 MB (5,888) | 49 of 879 | 4 | | `VICTORY_TEXTURE_PHYS_FLOOR_MB=0` (a) | 26.6 → 30.6 | 95 → 158 | 1.7 / 1.4 GB | none | 21 of 908 | 1 | | `VICTORY_TEXTURE_PHYS_FLOOR_MB=0` (b) | 25.0 → 30.4 | 93 → 173 | 1.8 / 1.3 GB | none | 21 of 888 | 0 | | `VICTORY_TEXTURE_CUT_MAX_PERCENT=40` (a) | 25.0 → 26.5 | 97 → 105 | 2.1 / 1.8 GB | 7,384 MB (9,421) | 12 of 872 | 2 | | `VICTORY_TEXTURE_CUT_MAX_PERCENT=40` (b) | 25.0 → 25.3 | 90 → 89 | 2.2 / 2.1 GB | 7,944 MB (9,421) | 15 of 889 | 0 | (A third default run is left out: it got a 6-minute tape by my mistake and stood idle for the rest. It was 24.7 → 26.9 GB, 87 → 111, 40 of 889, in line with the two above.) What it shows: - **40 % is the arm that settles.** The cut found its level at 7.4–7.9 GB without reaching the 9.4 GB cap, and the write-combined allocations stopped growing (+8, then −1). Private memory stayed flat, and available RAM held at about 2 GB. At the default 25 % the cut sits at its cap all run, the allocations still grow about +23, and available RAM goes lower. - **I see no cost from the cut, within this noise.** 40 % had the fewest slow seconds of the three arms (12 and 15, against 21 and 21 without the free-memory floor and 41 and 49 at 25 %), and the per-minute shots show nothing late or blurry. My guess is that 25 % hits its cap while still short of free memory, so the PC pages, while 40 % lets it reach a balance. But with these routes I wouldn't call that more than a hint. **The drain outside the process.** On this PC, "available" was almost all standby: truly free plus zeroed pages stayed at 3–155 MB in every run. Over a run, standby went from about 2.7–3.2 GB down to 1.6–2.0 GB. It went to: - the game's working set, +0.6–0.8 GB (17.9 → 18.7 GB); - the system file cache, about 1.0 → 1.5 GB, consistent with the DirectStorage reads. Memory compression stayed flat at about 0.97 GB, and no other process grew (Edge about 1.1 GB, Defender 0.43 GB). So it is mostly the file cache, as you suspected, plus a little of the game's own working set. The floor can't take that back, which may be why 25 % runs into its cap here.
Lyrnc commented 2026-12-01 15:37:30 +00:00 (Migrated from github.com)

Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by Lyrnc on 2026-12-01T15:37:30Z.


Thanks @nick0451, that settles the cap question. The memory columns are clean even with the route drifting, and the standby breakdown answered the drain question too.

The default is now 40 % (542a88bb), from your data. At 40 % the cut found its own level at 7.4-7.9 GB under the 9.4 GB cap. The write-combined allocations stopped growing (+8, then −1), private memory stayed flat and available RAM held at about 2 GB. At 25 % it sat at its cap all run. The switch, its 90 % limit and the texture floor are unchanged, and VICTORY_TEXTURE_CUT_MAX_PERCENT=25 gives the old cap. The tests and bug journal follow, and the PR description now leads with your table.

The drain outside the process is mostly the system file cache filling with the DirectStorage reads (about 1.0 → 1.5 GB a run), plus a little of the game's own working set. No texture line can take that back.

AI use: Claude Code (Claude Opus 5.5) read your results, changed the default and its tests, ran cargo check / cargo test / cargo clippy, updated the description and wrote this reply. No game was run for this change.

<!-- greyfinch-sync:trustno1-coder/VIctory-NVIDIA:comment:7316230499 --> Imported from [trustno1-coder/VIctory-NVIDIA](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/4288#issuecomment-7316230499). Originally posted by [Lyrnc](https://github.com/Lyrnc) on 2026-12-01T15:37:30Z. --- Thanks @nick0451, that settles the cap question. The memory columns are clean even with the route drifting, and the standby breakdown answered the drain question too. **The default is now 40 % (542a88bb), from your data.** At 40 % the cut found its own level at 7.4-7.9 GB under the 9.4 GB cap. The write-combined allocations stopped growing (+8, then −1), private memory stayed flat and available RAM held at about 2 GB. At 25 % it sat at its cap all run. The switch, its 90 % limit and the texture floor are unchanged, and `VICTORY_TEXTURE_CUT_MAX_PERCENT=25` gives the old cap. The tests and bug journal follow, and the PR description now leads with your table. **The drain outside the process** is mostly the system file cache filling with the DirectStorage reads (about 1.0 → 1.5 GB a run), plus a little of the game's own working set. No texture line can take that back. AI use: Claude Code (Claude Opus 5.5) read your results, changed the default and its tests, ran `cargo check` / `cargo test` / `cargo clippy`, updated the description and wrote this reply. No game was run for this change.
trustno1-coder commented 2026-12-01 18:44:34 +00:00 (Migrated from github.com)

Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by trustno1-coder on 2026-12-01T18:44:34Z.


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.

<!-- greyfinch-sync:trustno1-coder/VIctory-NVIDIA:comment:7321454953 --> Imported from [trustno1-coder/VIctory-NVIDIA](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/4288#issuecomment-7321454953). Originally posted by [trustno1-coder](https://github.com/trustno1-coder) on 2026-12-01T18:44:34Z. --- 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

Sign in to join this conversation.
No reviewers
No labels
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.

Reference
trustno1-coder/VIctory-NVIDIA!4288
No description provided.