Streamline: break optimal-size ties by render ratio instead of DLAA (#4779) #4787
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!4787
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-4786"
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?
@dheerajc8073 on GitHub · 2026-12-01 08:15 UTC · original
dheerajc8073:fix/dlss-pick-mode-tiebreak→main· +50 −3 · 1 files · 1 commits · openFixes #4780
What it changes
In
crates/victory-gpu/src/streamline/plan.rs,pick_modebroke optimal-area ties usingIterator::min_by_keyoverMODES, which putsDLSS_DLAAfirst. WhenslDLSSGetOptimalSettingsreturns the same optimal render size across modes (for instance[1707, 960]for every mode on RTX 5080 / driver 621.24 in the #4780 logs),pick_modealways choseDLSS_DLAAeven when the scene was rendered atPerformance([1280, 720]->[2560, 1440]), misreportingmode=DLAAin logs / F3 and resolvingautopreset tokinstead ofm.tie_rank/sl_mode_scale) inplan::pick_mode: smallest optimal area fittingrenderstill wins; ties preferMode::of_size(render, output), then the smallest nominal DLSS scale covering the actualrender / outputratio (falling back toMODESorder only if everything else ties).one_size_for_every_mode_is_told_with_its_modeso a[640, 360]render into[1920, 1080]expectsDLSS_ULTRA_PERFORMANCErather thanDLAA, and addsuniform_optimal_sizes_pick_mode_for_render_ratio_instead_of_dlaacovering uniform[1707, 960]answers at[2560, 1440]for all modes, intermediate sub-native ratios ([1600, 900]), and native[2560, 1440](DLAA).How it was tested
pick_mode([1280, 720], [2560, 1440], |_| Some([1707, 960]))returnedDLSS_DLAA(verified against the attached #4780 play logslDLSSGetOptimalSettingssizes).cargo test --locked -p victory-gpu streamline(55 passed, 0 failed),cargo test --locked -p victory-gpu --features diagnostics --test replay --test replay_big(replay: 1 passed;replay_big: 1 ignored), andcargo xtask policy --staged(ok). Note: fullcargo test --locked -p victory-gpuhad 1168 passed / 1 pre-existing failure incompose::tests::bgrx_plane_selects_a_typed_view, andcargo clippy --locked -p victory-gpu --all-targets -- -D warningsshowed 0 errors instreamline/plan.rsand only the 5 pre-existingmainerrors inhost/{font,menu,panel}.rs(#4708).cargo testpassed for the crates it touches: yes (victory-gpustreamlinesuite: 55/55;replaytest: 1/1)Checked for overlap
mainClippy fixes)@andrewpozdnakov7-jpg on GitHub · 2026-12-01 08:28 UTC · original
I extracted the six Streamline query results from the public #4780 log. At 2560×1440, all six modes returned optimal 1707×960 and an input range of 1280×720 through 2560×1440. The actual Performance evaluation recorded DLAA with preset
k.I replayed the exact
pick_modeimplementations from main5fabb46and this head86f9863with those answers. Main selected DLAA for both 1280×720 and 1706×960. This PR selected Performance and Quality respectively. Both inputs are within the reported range.The Ultra Performance case selects Ultra Performance with this PR, but its 853×480 input is below the minimum returned by all six queries on this run. The chooser test establishes the selected mode there. DLSS evaluation and image quality below the reported minimum still need a device run. NVIDIA Streamline guide
@ums121, could you retry Performance on the same RTX 5080 with
86f9863and share the newupscaling recordedline and the failed-evaluation count? If you also retry Ultra Performance, please include the minimum sizes Streamline reports for that run.@ums121 on GitHub · 2026-12-01 15:30 UTC · original
Correcting my own numbers first, then the results on
86f9863.The line in the issue body came from a run before the fix, and I mixed the wrong
preset into it. This is the same line, unedited, from the old binary:
render=[1280, 720] output=[2560, 1440] mode="DLAA" asked="performance"
preset="k" optimal=Some([1707, 960]) ... evaluations=1
So optimal there is 1707x960, not 1280x720. Sorry for the noise.
Before the fix every asked mode came back as DLAA. All three of these are from my
own logs of the old binary, in game:
asked="quality" render=[1706, 960] mode="DLAA" (4 runs)
asked="performance" render=[1280, 720] mode="DLAA" (1 run)
asked="ultraperformance" render=[853, 480] mode="DLAA" (1 run)
The render sizes are right in all three, because the title sets them through the
FidelityFX path. Only the mode name was wrong, and it was wrong the same way no
matter what was asked, which is what pointed at the tie.
Built
86f9863(GNU toolchain, mingw dlltool) and ran the same title on it. Sameoutput size, same picture setting, same upscaler asked for; only the binary
differs:
render=[1280, 720] output=[2560, 1440] mode="performance" asked="performance"
preset="m" optimal=Some([1707, 960]) ... evaluations=1
mode now equals asked, and that is the only record line written in an 18.5
minute session, so the mode is picked once and not re-evaluated per frame.
Samples taken from that same run:
DLSS per frame: 1.00 upscalings by DLSS, 0.00 failed, 0.00 left to the title's
FidelityFX (183 by DLSS so far)
DLSS Frame Generation: 27 presents with it on, 0 off, 108 frames shown by it
(status 0x0)
26.4 fps, 37.8 ms/frame VRAM 12976 / 14520 MB
failed is 0.00 in every sample of the run.
Direct A/B with the probe in this build, --validate, at 2560x1440:
Validated SR: mode=performance render=[1707, 960] output=[2560, 1440] iterations=12
Validated SR: mode=ultraperformance render=[1707, 960] output=[2560, 1440] iterations=12
Readback PASS: 3686400 finite RGB pixels; blake3=fb4b49f4...; tolerance=0.02
Streamline shut down: ok (0)
12 iterations each, readback PASS, output bit-identical to the reference. Both
asked modes report what was asked, and no upscale is refused.
What the commit does not change: optimal is still [1707, 960] for every asked
mode, as both probe lines show. So a caller that takes its size from optimal -
the probe, or a title that lets the layer pick - still renders Ultra Performance
at the quality ratio. In game this does not show, because the title asks for its
own size. The tie in the sizes is therefore still there; the commit decides which
name to report when the sizes are equal, which is exactly what was broken.
Environment: RTX 5080 16 GB, driver 621.24.0, Windows 11 26300.9711, Streamline
2.14.16, NGX 310.9.16, retail game_scarlett_master.exe v1.0.2.1 unmodified. The
full log of the run is attached.
I compiled this build once to answer your question and I am not set up to iterate
on source, but I can run other probes on this binary if it helps.
victory-log-86f9863-20261201.zip
help of Doubao
View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.