8 GB cards and 6-core CPUs: narrow fence waits, first uploads under the budget, submit-thread and RAM relief #3500
No reviewers
Labels
No labels
AMD
audio
bug
confirmed
crash
cutscene
dlss
documentation
duplicate
enhancement
fixed-on-main
frame-generation
good first issue
help wanted
input
INTEL
invalid
lighting
linux-proton
memory
needs-info
needs-logs
needs-rebase
NVIDIA
performance
pr-diagnostics
pr-docs
pr-feature
pr-fix
pr-performance
pr-refactor
pr-tests
question
RAYTRACING
rendering
report
series-s
shaders
spam
startup
upstream
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/trustno1-coder--VIctory-NVIDIA!3500
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-3500"
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?
@Zedwhyrex on GitHub · 2026-11-30 00:06 UTC · original
Zedwhyrex:perf-8gb-pr→main· +1576 −76 · 16 files · 3 commits · closed without mergingFrame time and memory on an 8 GB card / 6-core CPU / 32 GB PC (RTX 4060 8 GB on PCIe 4.0 x8, Resizable BAR on, Ryzen 5 7600, Windows 11). Three commits, each change logged once at start and switchable; the opt-in ones change nothing unless set.
What changes
1. 8 GB cards and the submitting thread (
fence.rs,resource.rs,streamline.rs,draw.rs,watch.rs,host.rs,host/panel.rs)VICTORY_FENCE_NARROW(on with the relay;0: as before). A title thread blocked on a fence (null-eventSetEventOnCompletion) waits for that value alone instead of settling every flight while it holds the submission lock. With the relay, the landing thread sets the fence (late_signal→set, andfence::writtennow wakesWaitOnAddresswaiters too), so the settle moved nothing and only held the lock. The settle still runs once at the 250 msFORCE_AFTER.VICTORY_FIRST_UPLOAD_CARD_PERCENT(92;0: off). First uploads past the room line that need new card memory stop at 92 % of the budget, weighed against use less the free texture blocks. An upload that fits a free range still goes in (widest_freeis looked up from that line). In a 30-minute run, texture copies went from 3.4 to 5.8 GB and the card's use to 9.7 GB of a 6.9 GB budget, and nothing could evict them.VICTORY_TARGETS_PEAK_DECAY(on for budgets ≤ 8.5 GiB): the render-target reserve's peak halves every 20 s once targets hold still. 1.7–2.1 GB stayed reserved for the whole run, and 183 of 190 room checks said "no room".VICTORY_FG_ROOM_ONCE(on for budgets ≤ 8.5 GiB): the launcher's 80 % frame-generation line (VICTORY_FRAMEGEN_ROOM_RESERVE) is lifted after 5 s of DLSS frame generation, once its resources are counted in the card's use. It ignores gaps under 10 s. A line set by hand is never lifted.VICTORY_WROTE_PARTS(on):watch::wrotemarks only the 4 KiB parts a write of ours met, not the whole 64 KiB page.2. Submitting thread (
cores.rs,list/thin.rs,host.rs,host/card_steps.rs,shadow.rs)VICTORY_LIST_BELOW_SUBMIT(on;0: as before): list translators run one priority belowvictory-submitunless set by hand. WithVICTORY_HELPER_PRIORITY=1and no placing, they ran at its ownABOVE_NORMAL, with 653 ms of translation a frame beside it on 12 logical processors.VICTORY_SWEEP_ASIDE=1(opt-in): the once-a-second sweep runs on avictory-sweepthread, without the slot eviction. A flush (F7/F8) stays on the submitting thread. It cost 9–13 ms a frame plus a ~100 ms stall once a second.VICTORY_THIN_THREADS=auto(physical cores less two);VICTORY_REFRESH_INLINE=<n>(default 0: nothing changes); planning-time split by part in the card-steps line; slot writes split from 64 a submission.3. RAM on a 32 GB PC (
shadow.rs,procmem.rs,cores.rs,land.rs,pipeline/make.rs,host.rs,host/send.rs)VICTORY_BUFFER_COPY_IDLE_S(30;0: never) andVICTORY_BUFFER_COPY_IDLE_FREE_MB(4096): while the PC has under 4 GiB free, host copies of title buffers idle 30 s and 60 frames are let go. This applies only to copies nothing holds (no list, pass, snapshot or descriptor slot), never shader-written or kept for stores by address, and not a window, placed, mapped or an arena's. Before, a title buffer's copy was never let go while the title kept the buffer: 4,355 copies held 6 GB with 572 MB of the PC's memory free.VICTORY_THREADS_BY_CORES=1(opt-in): pools sized by physical cores (translators 8→5, wide, land, pipeline workers, DirectStorage), the last physical core for the submitting thread atHIGHEST, translators atNORMAL.process memory:line splits private bytes at host addresses by region size, and splits write-combined bytes by whether they are in the working set. With Resizable BAR the driver maps the card's own memory write-combined: the "8.1 GB of upload memory" was VRAM, not RAM (checked with a small probe). It also prints the layer's upload pools.Measured
All measurements are on the RTX 4060 PC above, open world, Series S profile, from release-build log lines. They were taken on v2026.11.29.01/.02 with these changes (plus #1944 and #1937 merged locally, which are not part of this PR). They have not yet been re-measured on .05.
Most of these come from separate free-roam sessions, so scenes differ. The last two runs replayed one recorded controller route (
VICTORY_INPUT_REPLAY) and were compared at matching draw counts. Those runs also showed that renderer port 1 with the title's 32-bit heap in system memory costs 10–20 ms a frame on this PCIe x8 card. It is left as it is in this PR.Tests
On this branch (on v2026.11.29.05):
cargo build --release -p victory: OK.cargo test -p victory-gpu --lib -- --test-threads=1: 931 passed, 1 failed. The failure,shader_cache::tests::every_switch_of_the_translator_is_in_the_key, fails on the plain release too (KEYEDstill namesVICTORY_SCALAR_SPLITS, which the translator no longer reads).cargo test -p victory: 83 passed.cargo clippy -p victory-gpu --release: 29 warnings, the same per file as plain v2026.11.29.05, so none are new.🤖 Generated with Claude Code
@Zedwhyrex on GitHub · 2026-11-30 01:07 UTC · original
Re-measured on v2026.11.29.05. Same PC (RTX 4060 8 GB, PCIe 4.0 x8, Ryzen 5 7600, 32 GB). The settings were Series X, DLSS Balanced and frame generation 2x; the opt-ins were off for the PR build. I replayed one recorded controller route (
VICTORY_INPUT_REPLAY) four times, alternating plain .05 and .05 with this PR, each build warmed first.Result: on .05 this route shows no measurable difference. Medians over gameplay seconds (more than 3,000 draws a frame, stall frames excluded):
On .05 no blocking fence wait happens on this route, so
VICTORY_FENCE_NARROWhas nothing to act on there. On .01 the same path cost 33.4 ms a frame. The ten memory-tracking PRs in .05 already removed much of the submit-thread load measured before. Frame times at matching draw counts range from −20 % to +9 % between the builds. That is within the noise of these replays: the runs drifted into different scenes, and the last PR run overlapped with compile work on the same PC.What this PR still does on .05:
Unrelated to this PR, found in the plain .05 replay: going into water drops to 0.1 fps. Each frame waits about 10 s (title threads "waited 10075.8 ms at presents") while
pipeline::makelogs "draws dropped for pipelines not made yet ... keys=860c083c452e76d06f0063ae9d750323 a6d3d14fe71eae87bd70a363c8c79692" with 0 being made. I'm looking into it separately.github-bot referenced this pull request2026-11-30 01:14:29 +00:00
@korbannour578-alt on GitHub · 2026-12-01 12:05 UTC · original
Test result on an RTX 4060 Laptop 8 GB (i7-13620H 6P+4E, 32 GB RAM, NVIDIA 610.78), Series S profile, build
5fabb46e+ the warpGTAIV/VIctory-8GB small-card policy.I applied parts 1 and 3 (narrowed fence waits, first uploads under the budget, idle buffer copies let go). Part 2 and the thread sizing didn't apply cleanly on top of my build, so I skipped them.
Small but real gain, so I'm keeping it. Thanks!
Full laptop report: #4868
Pull request closed