XMem: the title's spare defaults to 6,300 MiB, a little more than its 6,236 MiB heap (#3273) #3353
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/3353"
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 kibagami-nc on 2026-11-29T22:10:20Z.
From #3273, measured by @straperlu.
What happens
v2026.11.29.04 (
f72cec77) reserves 8,192 MiB of address space for the title at start, top-down in [4 GiB, 128 GiB). The spare only has to hold room for the title's 6,236 MiB heap: when the heap is refused, the spare is given back and the request is tried again.On a PC where that window is already tight, the extra room the spare takes is what the start was missing. The PC in #3273 is an RTX 3090, 32 GB, where DLSS's driver holds 36 + 28 GiB of the range (#2081, #2133). There, .04 as shipped stopped for good in the start's shader-cache walk: 19,000 of 27,591, 16 s of CPU, no error, no window.
Three runs there, all with the .04 release asset, the same switches and the same warm cache:
VICTORY_TITLE_SPARE_MB+0x1e6c284, the #2081 stop)The change
xmem.rs, with a compile-time check that the default stays above the heap.VICTORY_TITLE_SPARE_MBstill sets any other size, and 0 turns the spare off.Where the spare still covers the heap, nothing else changes: it is given back and the heap is tried again, as before.
A design that holds the spare only until the title asks for its heap, as #3273 suggests, would not depend on the number at all. That is a bigger change, and this one keeps f72cec77's design as it is.
Tests
cargo test -p victory-hle --locked: 423 passed.a_read_by_range_waits_only_for_a_remapping_that_meets_itfailed once in a full run, and passes alone (3 of 3). It's timing-sensitive under parallel tests and unrelated to this constant.TITLE_SPARE_MB > TITLE_HEAP_MBholds.cargo clippy -p victory-hle --all-targets: nothing in the changed lines.Not run here: no PC here has a window this tight. The numbers are #3273's.
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.Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.