panel: F3's VRAM row shows what the texture queue weighs, and its line #3634
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/3634"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by nevasouls on 2026-11-30T02:23:12Z.
The problem
F3's memory row gives the card's use against the budget. The texture queue decides against a
different number on both sides of the comparison.
From a log at
VICTORY_VRAM_BUDGET_MB=7256(the measured budget of a real 8 GB card,docs/windows-memory.md):So the line is
room_line(budget)minus the face headroom (6,530 → 6,274 MB), and the useweighed against it is the card's use less what lies free in texture blocks, plus the room kept
for card copies and for render targets a world has not made yet. The panel showed neither. A player
reading
VRAM 5.9/7.1would think the queue had 1.2 GB of room when it had already stopped.TEXis the queue's own pair: what it weighs, over the line it refuses at.SHis the PC's sharedmemory in use, unchanged, shortened to fit the box.
The change
resource::queue_use(memory)— the sumroom()compared inline.room()and the panel now bothcall it, so the two cannot drift.
resource::refusal_line(budget)—room_line(budget) - face_headroom_bytes(), replacing the threeinline copies (in
room(), the reclaim line, androom_terms, whose log line is unchanged).resource::queue_against_line(memory)—(weighed, line), orNonewhereroom()consults noline at all: no budget from the system, or
VICTORY_TEXTURE_BUDGET_MBset, which weighs thetextures' own bytes instead (
room_termsreturnsNonefor the same two cases).panel::vram_row()— formats the row and fitsCOLUMNS(40); without a queue pair it prints theold
SHAREDform.Why it is safe at 12 GiB+
No behaviour changes. Every value is computed by the same expression as before, moved behind a name:
room()'s comparison, the reclaim line, androom_terms' log line all produce identical bytes.The panel only formats numbers, and nothing reads them back.
Verification
the_vram_row_fits_the_boxformats the row at a 7,256 MiB budget with the queue over its line, at11,229 MiB, and at 24 GiB, asserts each fits the 40-column box, and checks the no-line form prints
SHAREDand noTEX.Cost of the row. A run with
VICTORY_PANEL=1at the same budget and seed measured 11.5 fpsmedian (87.2 ms) against a baseline spread of 11.4-11.8 fps over two runs without the panel, so the
row costs nothing measurable; it builds two
format!strings on the panel's existing update, whichalready calls
video_memory()there.cargo clippy -p victory-gpu --lib: no warning on the changed lines. The warnings that cratereports are on
maintoo (wide_chunk,nothing_new_withinshadow.rs, etc.).What is not verified
I have not seen the row on screen: the bench's captured frames do not include the panel overlay (it
is drawn at present, after the capture), so the text is pinned by the test rather than a screenshot.
VICTORY_PANEL=1shows it at once.This patch is the second version. An independent review of the first — which paired
LINEwith thesystem's raw
used— found exactly the mismatch this version fixes: the line only means somethingbeside the use the queue weighs, and that was not the number on screen.
Turning it off
VICTORY_PANEL=0hides the panel; there is nothing else to switch.Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by trustno1-coder on 2026-12-01T18:50:15Z.
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