play: auto-tune worker thread pools for 24+ logical CPUs (keep defaults on <24) #499
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/499"
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 tiadiff on 2026-11-27T23:35:30Z.
Problem
victory.exedirectly (victory play/ double-click) omitsVICTORY_PLACED_ORDER=1and the24+logical CPU worker-pool tuning (VICTORY_THIN_THREADS=12,VICTORY_UNDER_THREADS=8,VICTORY_LAND_THREADS=8, noted at +22-29% in heavy scenes inscripts/play-gta6-framegen.ps1).12 / 8 / 6override (26worker threads total) to16..23logical CPU machines (such as 8C/16T Ryzen 7 5700X) oversubscribes the CPU alongsideVICTORY_HELPER_PRIORITY=1and the title's own streaming threads, causing heavy initial 3D streaming stalls compared to the crate defaults (8thin /6under /4land).Change
VICTORY_PLACED_ORDER=1for all CPUs and restrict worker-pool scaling (12 / 8 / 8) tocpus >= 24viaapply_cpu_tuninginapps/victory/src/play.rsbeforevictory-settings.txtand--setoverrides (GTA6_NO_TUNE=1disables).16..23logical CPU12 / 8 / 6override fromscripts/play-gta6-framegen.ps1soPLAY_FRAMEGEN.cmdandvictory.exestay consistent and leave< 24logical CPUs (e.g., 8C/16T) on the crate defaults (8 / 6 / 4).victory-settings.txt) and--setflags still take precedence and can override or clear any value.Verification
cargo test --release --locked -p victory --bin victory(24 passed; 0 failed, including updatedcpu_tuning_scales_worker_pools_by_logical_corescovering 8, 16, and 24 logical CPUs)cargo xtask policy(290 files ok)cargo build --release --locked -p victory(succeeded)Part of the low-stutter patch stack (with prebuilt Windows releases) in https://github.com/tiadiff/VIctory-NVIDIA-LowStutter.
Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by POMXARK on 2026-11-28T00:29:35Z.
Testing feedback on an 8C/16T CPU (AMD Ryzen 7 5700X, RTX 5080 16 GB, 32 GB RAM, Series X 1440p + DLSS Quality + DLSS MFG 4×, on top of
v2026.11.27.8):The
cpus >= 16tier setsVICTORY_THIN_THREADS=12,VICTORY_UNDER_THREADS=8, andVICTORY_LAND_THREADS=6(26 worker threads total alongside the title's own threads +VICTORY_HELPER_PRIORITY=1). On an 8-physical-core / 16-logical-thread CPU, this caused noticeable thread oversubscription during initial 3D load and heavy streaming:copiesspikes up to101.1 ms,texturesup to49.9 ms, visibly slower texture streaming compared to default worker counts on the same hardware).Suggestion: consider distinguishing 16-logical-thread (8C/16T) CPUs from 24+ thread CPUs with lower worker counts (or scaling by physical/logical core count so total worker threads stay below
cpus) so 8C/16T systems don't oversubscribe during heavy streaming.Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by tiadiff on 2026-11-28T01:12:34Z.
If you want to re-test on your 5700X + RTX 5080 without building from source, I just published a prebuilt drop-in Windows release with this 8C/16T fix (along with the rest of the low-stutter patch stack — u64 descriptor bitset, dense HeapRanges, single-wait PSO budget, Wave32 waterfall prover, and the 6-mode launcher):
https://github.com/tiadiff/VIctory-NVIDIA-LowStutter/releases/tag/v2026.11.27.8-tiadiff-rev1
Would love to hear if initial 3D entry and texture streaming are back to normal on your 5700X (feel free to post results here or in the repo's benchmark reports/discussions)
Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by Luqueze on 2026-11-28T01:32:03Z.
Tested on RTX 4070 SUPER + Ryzen 7 5700X3D (8C/16T, so this PR's 16+ branch), Windows 11, Series X profile at native 1440p, DLSS off, warm pipeline cache,
main64d4931. I set the same switches via-More(THIN_THREADS=12, UNDER_THREADS=8, LAND_THREADS=6, PLACED_ORDER=1). Two runs, same save and route:No clear gain here. The heavy-scene difference is within what the different samples could explain, and the submitting thread, which is the limit on this CPU, is unchanged. Subjectively no better, maybe slightly worse. It may be worth gating on physical cores rather than logical CPUs: 12+8+6 workers on 8 cores may oversubscribe.
Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by tiadiff on 2026-11-28T01:47:11Z.
a00b354) still shows the original 16+ (12/8/6) branch that was mirrored from upstream's scripts/play-gta6-framegen.ps1.After @POMXARK's report, I dropped the 16..23 tier in my fork (1b8a1d2) so anything under 24 logical CPUs stays on the crate defaults (8/6/4) — in both play.rs and play-gta6-framegen.ps1.
Good point on gating by physical cores as well. std:🧵:available_parallelism() only reports logical CPUs, so raising the cutoff to >= 24 logical CPUs already excludes all 8C/16T parts (it only triggers on 12C/24T or 16C/24T+ hybrid CPUs), though querying physical cores via GetLogicalProcessorInformationEx on Windows would be cleaner if we ever want finer-grained scaling (especially for hybrid P+E topologies).
Your numbers are also a good signal that upstream's elseif ($cpus -ge 16) (12/8/6) in scripts/play-gta6-framegen.ps1 is likely net-neutral or slightly negative on 8C/16T.
Out of curiosity, did you happen to notice whether VICTORY_PLACED_ORDER=1 by itself (with default 8/6/4 pools) makes any difference on the 5700X3D, or is it also submitting-thread bound?
Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by tiadiff on 2026-11-28T22:33:16Z.
This PR was auto-closed by GitHub when the original fork was detached into standalone repo
tiadiff/VIctory-NVIDIA-LowStutter, before the 8C/16T follow-up fix could be pushed here.I rebased the updated patch cleanly onto current
main(d4b5d51) — keeping defaults (8 / 6 / 4) on< 24logical CPUs in bothapps/victory/src/play.rsandscripts/play-gta6-framegen.ps1(only scaling12 / 8 / 8on>= 24logical CPUs, withVICTORY_PLACED_ORDER=1enabled unlessGTA6_NO_TUNE=1), and verifiedcargo test --release --locked -p victory --bin victory(30 passed; 0 failed):github.com/tiadiff/VIctory-NVIDIA-LowStutter@cfcc539781git am):github.com/tiadiff/VIctory-NVIDIA-LowStutter@cfcc539781.patchPull request closed