Idea: sparse mirrors cost 1-4 ms of GPU a frame on an RX 5600 XT; whole mirrors are faster until their budget fills (runs wanted on other 6 GB cards) #585
Labels
No labels
area/accessibility
area/audio
area/input
area/install
area/menu
area/renderer
area/saves
area/upscaling
beanstalk: approved @ 1697603
beanstalk: approved @ 2c5a62e
beanstalk: approved @ 4fd82b7
beanstalk: approved @ 64d6d09
beanstalk: approved @ 6f91fae
beanstalk: approved @ 70a78f9
beanstalk: approved @ 8d361dc
beanstalk: approved @ 9d8356e
beanstalk: approved @ abf2227
beanstalk: approved @ d82f202
beanstalk: approved @ e5f1e40
beanstalk: approved @ ee8ab5f
ci: approved
good first issue
gpu/amd
gpu/igpu
gpu/intel
gpu/nvidia
help wanted
kind
bug
kind
chore
kind
docs
kind
feature
kind
performance
kind
question
needs measurements
platform/linux
platform/macos
platform/steam-deck
platform/windows
preview
priority
critical
priority
high
priority
low
regression
status
blocked
status
confirmed
status
duplicate
status
invalid
status
needs-info
status
wontfix
testing wanted
ci: approved
No milestone
No project
No assignees
2 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
MagicBeanDev/Longshot#585
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
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?
The idea
On a 6 GB AMD card without mesh shaders the default, sparse mirrors, is slower than
RX_VK_MIRROR_SPARSE=0in most areas, but whole mirrors run into the 1,468 MB mirror budget and then lose a whole area. Neither is right for this card as it stands. I am looking for whoever knows the sparse mirrors to say where their extra GPU time could come from on this driver, and for the same comparison from other 6 GB cards.The comparison. RX 5600 XT 6 GB (RDNA1, the compute fallback), Adrenalin 26.10.1, Ryzen 5 5600X, 24 GB, Windows 11. Main
cf605c85withea6dc5f5(the mirror retry of #288) cherry-picked, the same renderer on both sides. Render resolution 50% of 1920x1080. Twelve areas by teleport, 25 s each after 10 s; six runs interleaved: sparse, whole, sparse, whole standing still, then whole and sparse walking. fps, sparse then whole:The same cliff in play. A 56-minute session on main
9c9d69edwith the same commit andRX_VK_MIRROR_SPARSE=0(Goron City, Death Mountain Trail, Dodongo's Cavern, the trail again, Kakariko) ran at 48-67 fps for 52 minutes. The first refused pool came on leaving the cavern, and on entering Kakariko five more, 296 MB between them:Kakariko then swung between 20 and 47 fps, under 30 for 1.5 of its 3.5 minutes.
The questions:
Who can help without writing code: anyone with a 6 GB card, on a nightly from
nightly-127on (sparse mirrors came in withcf605c85) or a build of main. AddRX_VK_MIRROR_SPARSE=0tolongshot_env.txtin the game's folder, walk the same stretch of Hyrule Field or Zora's River with and without the line, and comment with the card, the driver, the fps and GPU time of each side (the FPS counter's Breakdown level), and whether the log hasstays in system memorylines with the line set.Anything else
cf605c85and one run a pair: later runs on this card all hadRX_VK_MIRROR_SPARSE=0, so there is no sparse side on9c9d69edyet. I will add one here when the PC is free.docs/tested/2026-11-12-sparse-mirror-gumminaomi-run01.md), so this may be particular to this driver or to the compute fallback.A 10 GB NVIDIA data point for question 1. On this card sparse and whole mirrors cost the same GPU time. Whole mirrors hold about 0.4 GB more, and with this much VRAM they never reach their budget.
Setup: RTX 3080 10 GB, NVIDIA 621.14, i9-12900K, 64 GB, Windows 11. One scripted route in a window that never took focus, with the input kept out. It went through Hyrule Field, Zora's River, Kakariko and Kokiri Forest, then 6 minutes on Death Mountain Trail. Runs were about 26 minutes each, after a warm-up, interleaved sparse / whole / sparse / whole. Whole =
RX_VK_MIRROR_SPARSE=0. Medians over the whole run:dc390e59+ DLSS, 1920x1080 (DLSS 1120x630, preset K), the player's nightly options5e072fc8, 2560x1440, no upscalerstays in system memoryrefusals on either side. The process's peak working set is a little lower with whole mirrors: 12.0 / 11.8 GB against 12.7 / 12.3 GB sparse.Not covered: a 6 GB card, AMD, the compute fallback, and a fixed-scene standing comparison like yours. The 1440p pair is one run each way.
RX_VK_LOAD=createmeasured on a second such card (RX 5600 XT): same fps or better, loads of 50 ms at worst #805The run on current main that I owed. It changes the picture: on this card the sparse mirrors' extra GPU time is there only while every program is loaded before the title, which is what a GPU on the compute fallback gets by default. With
RX_VK_LOAD=createsparse and whole mirrors run the same, and sparse ones refuse no pool.Setup. Main
6c9edffewithea6dc5f5(the mirror retry of #288) cherry-picked, the renderer built with the committed play profile. RX 5600 XT 6 GB, Adrenalin 26.10.1, Ryzen 5 5600X (12 logical processors, so Threaded rendering's Auto is on), 24 GB, Windows 11; render resolution 50% of 1920x1080;RX_VK_WB_MAX_KB=1024,RX_VK_NO_PREDICT=1,RX_VK_NO_WARM=1on every side. Five areas by teleport, standing, 25 s each after 10 s; the sides interleaved, three rounds (two for the last column). fps, then the GPU's frame in ms; one cell a run:RX_VK_LOAD=createRX_VK_LOAD=createcommit limit nearlines a runstays in system memorylines a run6c9edffe, by 2-5 ms of GPU a frame, as oncf605c85.RX_VK_LOAD=createthey are level with whole mirrors in every area (the Market swings by run on both), 5 GB lighter than either side loaded at start, and no pool is refused.program loads at create (play): 6294 queued, 6294 loaded (median 1.85 ms, 99th percentile 13.88 ms, worst 50.28 ms, 18768 ms and 1385.6 MB read in all), and 0.0-0.1 draws a frame left out.gpu/vk/load_default.hkeepsstartfor the compute fallback from one RX 580 where first uses waited 0.7-1.3 s; this is a second card on the fallback, and it does not show that. That question has its own issue now: #805.commit limit near: 2507 MB of commit left (reserve 2560 MB); the textures' budget down to 0 MB of their 304 MBjust before. The PC has 24.5 GB of RAM and a 15.6 GB page file (Windows-managed), and the game's private memory was at 26.2 GB.So for question 1 my reading is now that the cost is not in the sparse mirrors themselves but in how little memory is left around them when every program is loaded at the start: that agrees with the RTX 3080 above, which has the room. I have not looked for which memory it is (the pipelines' 1.2-1.4 GB of VRAM, or the commit).
Not covered: a long session with
RX_VK_LOAD=create(these are five-minute runs, so I do not know yet whether whole mirrors still reach their budget after an hour, as in the play session above), Kakariko (the draw count there changed between runs standing still, 680 to 2,170, so it is left out), and Linux.RX_VK_LOAD=createmeasured on a second such card (RX 5600 XT): same fps or better, loads of 50 ms at worst #805