RTX 5060 Ti: heap writes in pieces, Reflex's sleep off the submitting thread, launcher folding first #3411
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!3411
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-3411"
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?
@dragoso on GitHub · 2026-11-29 22:57 UTC · original
dragoso:perf/rtx-5060-ti→main· +2205 −874 · 43 files · 20 commits · closed without mergingRelated: #3050 (the device hung with folding off, RTX 5080), #2323 (the launcher against
victory play), #2440 and #2464 (glitter in windows)What it changes
Five commits from measuring one PC (RTX 5060 Ti 16 GB on PCIe 4.0 x8, Ryzen 7 7700X, 32 GB), each with its A/B in
docs/findings.md("What was learned on an RTX 5060 Ti" and the sections after it). Each stands on its own, in this order, so any of them can be dropped. Main has since rewritten what the second one did, so four are left in the diff:VICTORY_WIDE_PIECES(newcrate::wide, off unless asked for): the skinning passes' writes through the title's whole 174 MB heap are declared as the 64 KiB pieces found written instead of all of it. Heavy city stretches 83.4 -> 76.0 ms a frame (diagnostics A/B). A piece first written after a copy's first 64 frames is not declared until a look finds it, a few frames later, and a title write into it meanwhile sends the title's bytes over the shaders': so the launcher does not set it (see the review below).VICTORY_REFLEX_ASIDE(off unless asked for):slReflexSleepevery frame on a thread of its own. Without any call of the app's, the driver made Reflex's sleep inside our present, on the thread every submission is prepared on (3-6 ms a frame). Diagnostics A/B standing: median frame 46.8 -> 42.2 ms; moving through the city, 20.9 ms a frame less (no longer held at 71.4 ms). But nothing paces the frames then, so they come less evenly: the launcher does not set it (see the review below).VICTORY_FAULT_UNLOCKEDon in the launcher, and a faster compare of the card's copies (thirty-two loads at once, the parts nine at a time): 38.9 -> 37.5-37.8 ms a frame (release).VICTORY_GUARD_AHEAD(no gain standing or moving),VICTORY_SUBMIT_CORE,VICTORY_REFLEX_MODE; timeline recording fixes.send: the sweep keeps the send spares in use.Superseded by main.697590ad,1ecaa98aand8b801739rewrote the same 1 Hz sweep: the spares keep what the last sweeps used, and are let go on a thread of their own. The merge of84bd61e2therefore takes main'shost/send.rs, and nothing of this commit is left in the diff. What it measured stays indocs/findings.md: under host memory pressure the sweep let every spare go each second, and keeping the spares in use took release at the save point from 14.8-17.1 to 19.6-20.7 fps.VICTORY_SUBMIT_SPLIT=1(main's port of the split send, off by default): diagnostics A/B at the save point, frame 44.6 -> 42.0 ms, the submitting thread 41.6 -> 38.2 ms, screenshots alike.VICTORY_RAYMISS_CLEAR, default on;=0leaves the image as it was). Sincee2d7854ethe miss program is left out for opaque and transparent surfaces, and its image kept whatever the memory held; with the transient targets sharing memory, another target's bytes: red, green and purple glitter on every window on Series S. One diagnostics run alternating it every 8 s: the glitter in every shot without it, clean glass in every shot with it; 71.3 against 71.0 ms a frame.VICTORY_WAVE_FOLDED=1. With v2026.11.29.02's default (no folding) every release run here lost the device (DXGI_ERROR_DEVICE_HUNG, 43, 73 and 92 s into the world), as #3050 has on an RTX 5080; with folding first, none of ten runs did (three of them 5, 5 and 2 minutes in the world on the hotfix build). v2026.11.29.03 (05d1c564) folds more by default again; that default was not measured here.VICTORY_BVH_MISS=1andVICTORY_NAN_SCRUB=1, asvictory playdoes. Since84bd61e2(#4067)scripts/play-nvidia.ps1fills in play's shader-key defaults itself, so those two are main's now. Here they cost no card time: one recorded frame replayed with each shader set took 37.37 against 37.16 ms.VICTORY_SAMPLED_MARKS, which this commit had left out together withvictory play's texture switches. With all four the save point took 2.7 GB more of the card's memory and 3.5 GB more of the PC's, and ran slower (14.0 and 9.7 against 18.3 and 18.3 fps).SAMPLED_MARKSwas not measured on its own here, so the PR leaves main's choice as it is.After review
Two testers ran it (comments below). Without frame generation (RTX 5070) no gain, and one frame in 160 with some vegetation missing; with 3x frame generation (RTX 5070 Ti)
VICTORY_REFLEX_ASIDEgave 1.25 fps more on average but twice the frames over 50 ms. The A/B logs here, read again for pacing, agree (standing: p95 51.2 -> 57.3 ms, frames over 50 ms 10.3 -> 13.4 %). So the last commit takesVICTORY_WIDE_PIECESandVICTORY_REFLEX_ASIDEout of the launcher; both stay as switches, off unless asked for, with what each costs indocs/README-nvidia.md,docs/dlss.mdanddocs/findings.md.How it was tested
docs/findings.mdgives each one's); ray tracing off (the launcher's estimates of light and reflections).VICTORY_AB) wherever it could be, since the save point's time of day moves from run to run; release runs in turns otherwise.41adb551(v2026.11.29.05): the only conflict washost/send.rs's test module, where the new test sits beside main'sparallel_copy_threshold_requires_multiple_tasks; one more commit fixes a doc link (nothing_newis nownothing_new_with).c71899d9, at84bd61e2, and at5fabb46eafter main was rewritten (84bd61e2is4e6cf227there; the branch's diff over main stayed the same):host.rsthe card compare keeps main's capture (compare bits 2 and 4) with the faster hash.shadow.rsmain'sunified_statscount runs before the wide pieces.VICTORY_GUARD_AHEADpublishes with main'spublish_range.host/send.rsis main's (commit 2).scripts/play-nvidia.ps1, which replacedplay-foxhound.ps1.cargo check --workspace --all-targets --lockedpasses.cargo test -p victory-gpu --lib, filtered to them): 13 passed on WARP.hardware_card_compare_*tests, run with--ignoredon the RTX 5060 Ti, pass too.Shadow::rangedis never used,loop_capsis never read), and-D warningsturns them into errors in the clippy gates ofci.yml.cargo test --workspacewas not run here.Checked for overlap
VICTORY_RAYMISS_ZERO; whichever lands, commit 4 can go.play.rs, including the texture switches commit 5 left out; main's #4067 now fills in play's shader-key defaults.🤖 Generated with Claude Code
@DoubleD17 on GitHub · 2026-11-30 03:37 UTC · original · edited 2026-11-30 09:56 UTC
We ran a test of this PR with its two new switches,
VICTORY_REFLEX_ASIDE=1andVICTORY_WIDE_PIECES=1(VICTORY_RAYMISS_CLEARat its default, on).VICTORY_FAULT_UNLOCKEDandVICTORY_SUBMIT_SPLIT, which the PR's launcher script also sets, are main's own switches and were left at their defaults, so the comparison shows only this PR's code.No gain we can measure on this release build (the controls alone spread over 9 ms).
Picture: in round 1, one frame out of 160 had the palms and the potted plants by the house missing; they were back in the next frame. We saw none in the 320 control frames of this session, nor in 800 earlier control frames on this base. We have seen the same one-frame vegetation gap with #3502, #3476 and #1561. It may be a timing-sensitive problem in main that these changes make more likely, rather than this PR alone, but we wanted you to know.
Setup:
41adb551(only its own commits on top), against41adb551itself;41adb551spread through the session;Picture check: a burst of 10 captures a second at the end of each run (80 frames), looked at frame by frame.
AI Assisted
@ColorC on GitHub · 2026-11-30 08:58 UTC · original
Sharing controlled A/B data on RTX 5070 Ti + Ryzen 7 9800X3D with DLSS Quality + 3x MFG ON (so NVIDIA Reflex is actively engaged, complementing @DoubleD17's FG-off test):
slReflexSleepOff-ThreadVICTORY_REFLEX_ASIDE=0)VICTORY_REFLEX_ASIDE=1ONLY#3809switches (REFLEX_ASIDE=0)#3809+REFLEX_ASIDE=1+WIDE_PIECES=1Telemetry Notes
VICTORY_REFLEX_ASIDE=1is a clear win when MFG/Reflex is enabled: Standalone gain was+1.25 FPS (-1.9 ms), and once CPU prep got faster (withVICTORY_SUBMIT_SPLIT=1), movingslReflexSleepoff-thread slashedPresentstalls from3.99 ms (max 14.4 ms)down to0.45 ms (max 0.7 ms).VICTORY_WIDE_PIECES=1narrowing telemetry:big declared ranges per frame (VICTORY_WIDE_PIECES=1): 2784 MB asked of 1 copies, 389.0 MB declared, 28.9 MB looked at in turn; 389 pieces of 64 KiB found written in all, 0 new since the last line(-86% declared range).30.1 FPSavg,0/48 > 50 ms,0errors).Test Setup
--res 1440 --dlss quality --framegen 3 --fps 1000)-C target-cpu=znver5) rebased onmain(41adb551) with a curated local PR stack; all A/B numbers below are same-binary toggle ablations from the exact same restored save (~10.0k–10.4k draws/frame standing scene) after official 1-time warmup.@ColorC on GitHub · 2026-11-30 09:08 UTC · original
Important follow-up on per-frame pacing (ictory_gpu::frame_times P95 / P99 / >50 ms frames) under 3x MFG:
While the 5-second average FPS nudged up with VICTORY_REFLEX_ASIDE=1 in the table above, inspecting the exact per-frame ictory_gpu::frame_times lines from the exact same logs revealed a major frame-pacing / 1% Low regression when slReflexSleep is moved onto an unwaited thread with 3x MFG active:
Calling slReflexSleep off-thread without synchronizing back appears to break Reflex pacing under 3x MFG, turning steady ~32–41 ms frames into alternating sawtooth bursts (1.4% -> 18.4% of frames exceeding 50 ms). Sharing this correction so the pacing trade-off is completely transparent.
@dragoso on GitHub · 2026-11-30 10:03 UTC · original
Thank you both, @DoubleD17 and @ColorC: this changed the pull request (
904bc40e).VICTORY_REFLEX_ASIDE: our own A/B logs, read again for pacing, give the same picture as yours. RTX 5060 Ti with 2x frame generation, standing: the median frame 46.4 -> 42.3 ms, but p95 51.2 -> 57.3 ms and frames over 50 ms 10.3 -> 13.4 %. Moving through the city it does take the frame out of the 71.4 ms hold (median 71.4 -> 54.6 ms). With the sleep on a thread nothing waits for, nothing paces the frames. The launcher no longer sets it; it stays as a switch, off unless asked for, with that trade-off written down.VICTORY_WIDE_PIECES: it has a window that could make the one-frame vegetation gap. A piece the shaders write for the first time after a copy's first 64 frames is not declared until a look finds it, a few frames later, and a title write into that 64 KiB meanwhile sends the title's bytes over the shaders'. Not shown to be the cause, but the launcher no longer sets it either.VICTORY_REFLEX_ASIDEhad nothing to do in the RTX 5070 run: that one measuredVICTORY_WIDE_PIECESalone.🤖 Generated with Claude Code
RTX 5060 Ti: heap writes in pieces, Reflex's sleep off the submitting thread, send spares kept under pressure, launcher folding firstto RTX 5060 Ti: heap writes in pieces, Reflex's sleep off the submitting thread, launcher folding firstPull request closed