fix(guest-arena): place guest address space in the PS5 window on Linux #861
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/861"
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 boykopovar/AnyPS5. Originally posted by jeffrey12cali on 2026-10-06T10:15:07Z.
What
Guest address space on Linux is placed inside the PS5 window instead of wherever the kernel's top-down
mmaphappens to land, so a title's allocator accepts the mapping.sceKernelAllocateDirectMemory/sceKernelMapDirectMemorywithaddr == NULLnow return addresses in[0x2_0000_0000, 0xFC_0000_0000), which is the boundsceLibcMspaceCreateenforces.The arena reserves the free intervals of that window up front (
PROT_NONE | MAP_NORESERVE, 1 GiB chunks), so no later host mapping - driver, library, hintedmmap- can appear inside it, and commit can keepMAP_FIXEDsemantics, which is what committing over the arena's own reservation requires.Also in this change, from review:
EEXISTis recorded as occupied, so the arena cannot hand it out. Any other failure throws, with the address and the size.PROT_NONEreplacement thatGuestArenaResetuses.addr == NULL, not only the arena entry points.GuestArenaReset_nid_postfixno longer releases address-space accounting on Linux (@blawesom). The Linux variant released the range in addition to resetting the memory, while the Windows variant only resets and leaves accounting to the caller. Two call sites released again after the reset, andContainsis span-based, so both released twice under two separate lock acquisitions: a thread that allocated the range in between had its entry erased and the arena handed the range out twice. Every caller already releases explicitly, so the contract is restored rather than duplicated.mmap,PROT_READ,PROT_WRITE,MAP_FIXED_NOREPLACEandEEXISTdirectly, which does not compile under MinGW.Fixes #692.
Tested
Arch Linux, kernel 7.2.8-arch1-2, GCC,
Release,cmake -DBUILD_TESTING=ON:ctest491/491 on this head, rebased onto currentmain. The slowest test in the suite takes 4.19 s and the two tests added here take 0.01 s each, so nothing approaches the 30 s limit.The Windows build cannot be compiled here (no MinGW). The guard was verified by tracking preprocessor nesting: before the change the probe body and its call site are outside every
__linux__block, after it both are inside. CI has to confirm the build itself.The new kernel-API tests were verified to fail without the change. Making
ArenaAvailable()return false gives0% tests passed, 1 tests failed, and restoring it gives100%.Reservation feasibility was measured before adopting it. With an unlimited address space, 1000 GiB of the window reserves in 1 GiB
PROT_NONE | MAP_NORESERVE | MAP_FIXED_NOREPLACEchunks, with zero failures on kernel 7.2.8-arch1-2. Underulimit -v 67108864(64 GiB) the arena aborts withguest arena: cannot reserve 0x19c0000000+0x40000000 (Cannot allocate memory)instead of passing in silence, and at 128 GiB it fails at0x29c0000000.The reservation does not reduce allocatable device memory. A probe that reserves the same 997 GiB window and then allocates
VK_MEMORY_HEAP_DEVICE_LOCAL_BITmemory gives identical totals with and without the reservation: 22 GiB beforeVK_ERROR_OUT_OF_DEVICE_MEMORYon an RTX 4070 Laptop, and 4 GiB on the AMD 780M, at both 1 GiB and 256 MiB step sizes. This is reported against #861's head in the discussion below.Title evidence (PPSA28997, native Linux relink): the window placement is what the boot stands on.
sceKernelGetDirectMemorySizereports0x360000000on both platforms, and with the window in place the bundled player/JSON chain stops rejecting the address and the title reaches on-screen video.Independent reports on other titles:
sceKernelMapNamedFlexibleMemory→sceLibcMspaceCreatenow lands inside[0x400000, 0xFC00000001)andCommon::initializestops failing with0x80553504.0x7fff94400000into0x200000000/0x200300000, and the title passes the allocator fault._dl_initin 2 of 2 runs; with headc2e15098it boots, plays the attract movie at about 30 fps, and exits with code 0 in 2 of 2 runs.#1370 (partly overlapped allocations) has since merged and this head is rebased on top of it. #1360 remains an alternative to the eager reservation; I will rebase onto it or drop the reservation on the maintainer's call.
Checklist
main(rebased; the head is3c54adf0)Imported from boykopovar/AnyPS5. Originally posted by alfalfa-star on 2026-10-06T12:33:49Z.
@jeffrey12cali I don't have an arena PR in flight, so please keep #861. What I described in #692 was only a local experiment.
Tested #861 (
c9ce0789) with LEGO Horizon Adventures (PPSA14632) on Linux (Arch, GCC 16.2,--to-intel), in place of that experiment. This title reaches the window through flexible memory: the bundledlibSceNpCppWebApi.prxmaps its 0x80000-byte heap withsceKernelMapNamedFlexibleMemory(prot 2, no address) and passes it to the bundled libc'ssceLibcMspaceCreate, which only accepts[0x400000, 0xFC_0000_0001). WithAPS5_TRACE_MEMORY=1:Every traced mapping is inside the window.
Common::initializeno longer fails with0x80553504, and the title runs past the online-subsystem segfault. With a separate fix forsceAudioOut2Set3DLatency(0xFF, 1)it continues toscePadReadState: invalid argument, which is unrelated. The test suite on that tree shows no new failures (only three RADV pixel tests fail, as without #861).Edit: the first version of this comment showed a trace from a run where the patched prx in
build/core/libs/libswere stale (I had built without thelibstarget), so it still used my local experiment. The trace above is from a rebuild with #861's libraries.Imported from boykopovar/AnyPS5. Originally posted by jeffrey12cali on 2026-10-06T23:09:15Z.
Thanks for testing on a second title — that is the strongest thing this PR could get, and the
sceKernelMapNamedFlexibleMemory→sceLibcMspaceCreateroute is a path I had not reproduced: my measurements came fromsceKernelAllocateDirectMemory, same window, same[0x400000, 0xFC00000001)bound, andsceKernelGetDirectMemorySizereporting0x360000000on both targets.On PPSA28997 this PR is what the boot stands on: with the window in place the title reaches on-screen video at about 60 FPS with the allocator counters matching the Windows reference built from the same commit; without it the bundled player/JSON chain asserts on the rejected address.
Good catch on the stale
build/core/libs/libstrap, and worth writing down somewhere: our runner copies from exactly that directory, so a rebuild that skips thelibstarget silently tests the wrong binaries. If you agree it belongs in the contributor notes, I can send that as a small docs-only PR.Imported from boykopovar/AnyPS5. Originally posted by fisherjoey on 2026-10-06T23:46:51Z.
On NVIDIA (595.91), with #861, #864 and #732 merged, Demon's Souls reaches the main loop and renders, then every
vkAllocateMemoryreturnsVK_ERROR_OUT_OF_DEVICE_MEMORYwith about 14 GB of VRAM free. Without #861 it segfaults during init.Imported from boykopovar/AnyPS5. Originally posted by jeffrey12cali on 2026-10-07T05:16:25Z.
Thank you for the data point, and sorry it is a mixed one. Reading it carefully: without #861 the title segfaults during init, and with it the title reaches the main loop and then fails at
vkAllocateMemory- so this PR uncovers the NVIDIA failure rather than causing it, but that is no consolation if you want the title running, so here is what I can add.First, a theory I tested and discarded, so nobody chases it: I suspected the arena size (
sceKernelGetDirectMemorySizereports0x360000000, 13824 MiB) of eating the card. It does not - the guest arena and direct memory are host anonymousmmapin this code path, notvkAllocateMemory-backed, so the window consumes address space and committed host pages, not VRAM. The size coincidence is still worth ruling in or out, but by the route below rather than by shrinking the arena.What would actually pin it down:
vkAllocateMemory, or the first large one and everything after it because the backend is wedged? "Every call fails with plenty free" usually means the memory-type/properties the backend selected are not satisfiable on that driver, not that the card is full.allocationSize,memoryTypeIndexandmemoryHeapIndex, plus theVkMemoryHeapsizes and flags the backend read at instance setup. If the title sizes its pools from a platform limit (the same family as0x360000000) while ANV reports a smaller device-local heap, the request overshoots and the driver answersOUT_OF_DEVICE_MEMORY; on RADV the same request can be satisfied from a host-visible heap, which is exactly the asymmetry you would expect to see.I can only test on AMD here (PPSA28997 on RADV: on-screen video at ~60 FPS with every mapping inside
[0x400000, 0xFC00000001)and no allocator complaints), so I cannot reproduce the NVIDIA half myself. If those numbers are cheap to grab, post them here or in a new issue and I will work out whether the fix belongs in the placement (a reservation that can dodge driver-reserved ranges) or in the memory-type selection, and send a PR either way. If you would prefer I open the follow-up issue with your configuration quoted, say the word.Imported from boykopovar/AnyPS5. Originally posted by jeffrey12cali on 2026-10-07T09:24:31Z.
Two corrections, then measurements from an actual NVIDIA device, because it turns out I can test this half after all.
I was wrong twice in my previous comment. I wrote that I could only test on AMD. This machine has both GPUs, and the engine has always selected the discrete one - our own startup log says
Selected GPU name=NVIDIA GeForce RTX 4070 Laptop GPU vendor=0x10de, driver 615.71.09,Memory heap 0 size=8188.0 MiB flags=0x1,Memory heap 1 size=23527.8 MiB flags=0x0. So "PPSA28997 on RADV" was an assumption I never checked. Second, my size-overshoot theory does not survive contact with the device either, and I would rather say so than leave it standing.I wrote a small probe (
vkCreateInstance-> select by device name ->vkAllocateMemoryat fixed sizes, once on a device-local memory type and once on a host-visible coherent type, each freed immediately) and ran it on the idle card:VK_SUCCESSVK_SUCCESSVK_SUCCESSVK_SUCCESSVK_SUCCESSVK_SUCCESSVK_ERROR_OUT_OF_DEVICE_MEMORY(expected: that heap is 8188 MiB)VK_ERROR_OUT_OF_DEVICE_MEMORYThe two results that actually matter for your report:
0x360000000failure, a 1 MiB allocation on the same device-local type returnedVK_SUCCESS; same after the 1 TiB failure on the host-visible type. So "everyvkAllocateMemoryfails" cannot be explained by one early oversized call poisoning the allocator on this driver family. Either every request is independently too large for the budget its type is charged against, or the memory type the backend picks is not the one it believes it chose.What I would need to go further, and I think it is enough to settle it: for the failing calls,
allocationSize,memoryTypeIndex, and that type'sheapIndexwith the heapsizeand property flags; plus, if it is cheap,VK_EXT_memory_budget'sbudget/usageper heap at that moment. If the failing sizes cluster around one value, the title is almost certainly computing them from a platform limit - our family reports0x360000000(13824 MiB) for direct memory, which is suspiciously close to a "one big allocation" - and the fix belongs in the reported limit, not in the placement change.Two control tests worth running on your side: whether the failure persists with nothing else on the GPU, and whether it moves at all when the allocation is forced onto the host-visible type.
On my side, PPSA28997 with this arena in place is unaffected - the largest GPU-side block I can observe is 3407872 bytes, so this title never approaches the sizes in question, which is why I could not feel your failure from it. Nothing here makes me think #861 causes your problem, but I now have a probe that can test your exact numbers, and I will keep it pointed at this. Say the word and I will paste the whole ~130-line file into a comment, or add it to the repo under
tools/so anyone with an affected card can run it in one command (gcc -O2 vkprobe.c -o vkprobe -lvulkan).Imported from boykopovar/AnyPS5. Originally posted by alfalfa-star on 2026-10-07T11:04:48Z.
@jeffrey12cali Yes, please send the docs PR. The trap cost me one wrong comment here, so a line in the contributor notes would have saved it.
On the NVIDIA failure: @fisherjoey traced it in #1022, and #1051 is the fix. On NVIDIA, a refused
VK_EXT_external_memory_hostimport of a read-only range (the relinked image's read-only sections) makes every latervkAllocateMemoryon the device fail with -2. That fits "every allocation fails with 14 GB free" better than a size limit, and it would also explain why it only shows up once #861 gets the title far enough to import those ranges.Imported from boykopovar/AnyPS5. Originally posted by jeffrey12cali on 2026-10-07T11:51:23Z.
That closes it, and #1022/#1051 explain what I could not: a refused
VK_EXT_external_memory_hostimport of a read-only range poisoning the device allocation path is exactly the shape of "everyvkAllocateMemoryfails with plenty free", and your account also explains why it only surfaced once #861 got a title far enough to import those ranges at all.For the record, the measurements I did get are consistent with that and rule the other theory out. On an idle NVIDIA device here (RTX 4070 Laptop, 6185 driver line, 8188 MiB device-local heap, 23528 MiB host heap): single
vkAllocateMemoryrequests succeeded up to 7168 MiB and failed above the heap, and - the useful part - one rejected request did not wedge anything: the next 1 MiB allocation on the same memory type returnedVK_SUCCESS, both on the device-local and on the host-visible type. So "every call fails" cannot come from an oversized allocation having been refused earlier; it needs a stateful failure like the refused import in #1022. My earlier size-overshoot guess was wrong and I have retracted it on this thread.Docs PR for the stale
build/core/libs/libstrap is on its way now - thanks for confirming where it belongs.Imported from boykopovar/AnyPS5. Originally posted by adriadam10 on 2026-10-07T16:23:01Z.
Review: CHANGES_REQUESTED
Built and ran ctest on this PR merged onto current
main(Linux, GCC): all green,guest_memoryincluded. No CI ran onc9ce0789(no checks on the head); the PR needs green CI, including the Windows/MinGW job, because the header moves theCommit/Resetdeclarations out of#ifdef _WIN32.Before this can go in:
GuestArena.cpp:291-297(// PAGE_*on each case) andGuestMemory.cpp:452(// PAGE_READWRITE). CONTRIBUTING says no code comments, and the description says there are none.TryMarkUsedresult is ignored (GuestArena.cpp:318). If the range partly overlaps a used one, it returnstrueand the commitMAP_FIXEDs over it anyway, whereMarkUsedwould throw. That case should throw too. Also, on failure thecatchat:322releases the whole range, including the part the caller had already reserved withGuestArenaAllocate(theGuestHeappath).MAP_FIXEDon arena-chosen addresses (GuestArena.cpp:303,DirectMemory.cpp:406). The used map is seeded from/proc/self/mapsonce, on the firstArena()call. A host mapping created later inside the window (driver, another library, a hintedmmap) isn't in the map, so the arena can hand out its range andMAP_FIXEDsilently replaces it. The objection toMAP_FIXED_NOREPLACEwas that it returnsEEXISTon reserved space, but nothing is reserved up front anymore. For ranges the arena picked and forGuestMapNoOverwrite,MAP_FIXED_NOREPLACEturns that case into an error instead of corruption.PROT_NONEreservation because the kernel's top-downmmap"picks addresses just below the stack inside the range". On x86-64 with 47-bit user space, the stack andmmap_basesit near0x7ff..., far above0xFC_0000_0000. Could you share the failing case (kernel,ulimit -v, the/proc/self/mapsat the failure)? If aMAP_NORESERVEreservation works, it also removes the seed race above.GuestArena.cpp:298). Throw for values the switch doesn't model ("exact or throw").addr == NULLlands in[0x2_0000_0000, 0xFC_0000_0000), which is #692, or thatmunmapfollowed by a same-size map reuses the freed range (claimed under "Hole reuse"). Linux tests for both, plus the hinted path (addr != NULLwithoutMAP_FIXED), would cover what the PR changes.Imported from boykopovar/AnyPS5. Originally posted by jeffrey12cali on 2026-10-07T16:46:58Z.
Thank you - the seed-race point is the important one and it changes the design, so I am taking it rather than defending it.
MAP_FIXEDon arena-chosen addresses is wrong; switching toMAP_FIXED_NOREPLACE. You are right that the used map is seeded once from/proc/self/mapson the firstArena()call, so any host mapping created later inside the window - driver, another library, a hintedmmap- is invisible to the arena andMAP_FIXEDsilently replaces it. The original objection toMAP_FIXED_NOREPLACEwas the up-frontPROT_NONEreservation returningEEXIST, and that objection is gone now that nothing is reserved up front. I will useMAP_FIXED_NOREPLACEfor arena-chosen ranges and forGuestMapNoOverwrite, and treatEEXISTas the retry/failure path rather than as corruption.Eager reservation: I will re-measure and hand you the data. My note that top-down
mmappicks addresses just below the stack inside the range was from a failing run, and your objection is reasonable - on 47-bit user spacemmap_basesits far above0xFC_0000_0000. I will re-test with aMAP_NORESERVEreservation and post the kernel version,ulimit -v, and the/proc/self/mapsat the failure. If the reservation works, I would rather restore it, because it also removes the seed race above rather than mitigating it.TryMarkUsedresult ignored - agreed, it should throw. If the range partly overlaps a used one, returningtrueand thenMAP_FIXED-ing over it is exactly the corruption case, andMarkUsedthrows for it. I will make that path throw too. The second half of your point also stands: thecatchcurrently releases the whole range, including the part the caller had already reserved throughGuestArenaAllocateon theGuestHeappath - that has to unwind only what this call added.Unknown protection becoming RW is wrong; it will throw. "Exact or throw" is the rule and I broke it.
Code comments removed -
GuestArena.cpp:291-297andGuestMemory.cpp:452. You are right that the description claimed there were none; that was wrong and the description will be corrected with the code.Tests do not pin the fix - agreed, and this is the part I under-served. Both re-enabled checks map at fixed addresses, so neither would catch a regression of the actual bug. I will add Linux tests for: a direct and a flexible mapping with
addr == NULLlanding inside[0x2_0000_0000, 0xFC_0000_0000)(that is #692),munmapfollowed by a same-size map reusing the freed range (the "Hole reuse" claim, currently untested), and the hinted path (addr != NULLwithoutMAP_FIXED) honouring or declining the hint explicitly.CI. Noted on the missing checks for
c9ce0789and on the header movingCommit/Resetout of#ifdef _WIN32- I will get the Windows/MinGW job green on the head before asking for another look, and will rebase onto currentmainas it moves.Imported from boykopovar/AnyPS5. Originally posted by jeffrey12cali on 2026-10-07T18:27:50Z.
All six points addressed; head is
c4a8217c. The reservation question went better for you than for me - you were right and I was wrong, and the design changed because of it.Eager reservation: it works, and it is now in. Measured on this box before touching the design:
So my "the kernel's top-down
mmappicks addresses just below the stack inside the range" was a misattribution: what actually failed was a singlemmapof the whole window, which returnsEEXISTbecause existing host mappings intersect it. Reserving the free intervals in chunks works fine, and the arena now does exactly that in its constructor, after seeding. That removes the race you described rather than mitigating it, which is the better place to be.Why commit still uses
MAP_FIXED. I implemented yourMAP_FIXED_NOREPLACEsuggestion first, and it brokeguest_memorywithArena mapping failed: File exists: commit legitimately replaces the arena's ownPROT_NONEreservation, andNOREPLACEcannot tell that mapping from a foreign one. With the window reserved up front, no foreign mapping can exist inside it, soMAP_FIXEDis correct for commit and the corruption you were protecting against is closed at the source. I would rather have it that way round anyway - the guard is now "nothing else can be in there" instead of "hope the map is up to date".TryMarkUsed- the contract was the bug, not just the ignored result. It returnedfalseboth when the range was already fully used and when it had just marked it, so the caller could not tell those apart, and a partial overlap returnedtruewithout marking anything. Replaced with a commit-specific marker that returns whether this call inserted the range: a fully-covered range is accepted (callers pre-reserve throughGuestArenaAllocate, which is what made the naiveMarkUsedthrow in six tests), a partial overlap throws, and thecatchnow releases only when this call did the marking - so theGuestHeappath's reservation is no longer unwound by someone else's failure.TryMarkUsedis deleted rather than left as a trap.Unknown protection throws.
default:no longer returnsPROT_READ | PROT_WRITE.Comments gone - the
// PAGE_*cases and the// PAGE_READWRITEin the test. My description claimed there were none while the diff carried them; that was wrong and is fixed in both.Tests now pin the change, which was the fairest criticism: three Linux cases added - unhinted placement lands inside the arena window (that is #692), a released range is handed out again for the same size (this is the "Hole reuse" claim from my description, which was previously untested - it passes, and now cannot silently regress), and the hinted path never returns below the hint and always inside the arena. Suite: 322/322 on this base.
CI / freshness, one thing I cannot fix from my side: I cannot rebase onto current
main, because pushingmain's commits that touch.github/workflows/conventions.ymlinto my fork is refused - the OAuth token has noworkflowscope. This head is therefore based on931109b3. If there is a standard way to handle that for contributor forks (web-UI sync of the fork'smain, or a scoped token), tell me and I will rebase and re-run.Imported from boykopovar/AnyPS5. Originally posted by adriadam10 on 2026-10-07T20:07:09Z.
Review: CHANGES_REQUESTED
Built and ran ctest on this head merged onto current
main(Linux, GCC): 400/400,guest_memoryincluded. Approved the pending CI runs; Linux/Windows still running. The design is fine now, but a few things need fixing before it can go in:GuestArena.cpp:175-182). Underulimit -v 67108864(64 GiB), 929 of the 992 1 GiBPROT_NONE | MAP_NORESERVE | MAP_FIXED_NOREPLACEchunks fail withENOMEM, andguest_memorystill passes. AnEEXISTchunk (something mapped between reading/proc/self/mapsand reserving) isn't recorded in_usedeither, so the arena can hand that range out later andPlaceAt/ArenaCommitwillMAP_FIXEDover the host mapping. A failed chunk should either go into_used/_hostRegions(forEEXIST, re-read the maps or mark the chunk) or make the arena unavailable or throw (ENOMEM). It shouldn't fall back to unreserved without anything saying so.Unmapreopens the window (DirectMemory.cpp:416-417):munmapfollowed byArenaForgetleaves the range unreserved, so after the first unmap a host mapping can land in the window again, which is the race the description says is closed. Inside the arena, replace the range with thePROT_NONE | MAP_NORESERVEreservation, asGuestArenaReset_nid_postfixalready does (GuestArena.cpp:355).sceKernelAllocateDirectMemory+sceKernelMapDirectMemory(orsceKernelMapNamedFlexibleMemory) withaddr == NULLand check that the result is in[0x2_0000_0000, 0xFC_0000_0000). They callGuestArenadirectly. Without the change the tests don't compile (they useGuestArenaCommit/Reset, which used to be Windows-only), so right now nothing shows the kernel-level behaviour failing onmain. Please add a kernel API test for the direct and the flexible path, and ideally another that unmaps and checks the range is reserved again.GuestArena.cpp:73andGuestMemory.cpp:493.Imported from boykopovar/AnyPS5. Originally posted by jeffrey12cali on 2026-10-08T00:45:47Z.
All four points were correct. I reproduced each one before changing anything. Head is
9bee827b, and the suite is100% tests passed out of 322.1. Reservation failures were ignored. Confirmed, then fixed. Your case reproduces exactly. Before the change,
guest_memorypassed underulimit -v 67108864even though most chunks cannot be reserved. Now:The handling now splits by cause, as you proposed:
EEXISTmeans something else owns that chunk. It is recorded in_usedand_hostRegions, so the arena can never hand it out.2.
Unmapreopened the window. Confirmed.munmapfollowed byArenaForgetleft the range free, so a host mapping could take it after the first unmap. In-arena unmapped ranges now go throughGuestArenaReset_nid_postfix, which mapsPROT_NONEover the range instead of releasing it, so the reservation survives the unmap. There is no window betweenmunmapand re-reserve, because the replacement is a singleMAP_FIXEDmapping.3. No test for the kernel-level behaviour. Confirmed, and added. Two new tests use only the kernel API:
CheckUnhintedKernelMappingsLandInTheWindowcallssceKernelAllocateDirectMemoryplussceKernelMapDirectMemoryandsceKernelMapNamedFlexibleMemorywithaddr == NULL, and asserts the result is inside[0x2_0000_0000, 0xFC_0000_0000).CheckUnmappedArenaRangeStaysReservedmaps, unmaps, and then asserts that a hostileMAP_FIXED_NOREPLACEat that address returnsEEXIST.I verified the first one fails without the change, by making
ArenaAvailable()return false and rebuilding:0% tests passed, 1 tests failed, and100%with it restored. Your note about compilation is still true for the older arena-level tests, which useGuestArenaCommit/GuestArenaResetand do not build onmain. The two new ones do not depend on that.4. Double blank lines removed in
GuestArena.cppandGuestMemory.cpp.Two overlaps I should not have found last. Checking open PRs again, I see work in the same files, and I would rather raise it than let a reviewer find it:
DirectMemory.cppandtests/GuestMemory.cppand deals with partly overlapped allocations, which is the same problem as myTryMarkUsedchange.GuestAllocations. That is a different answer to the same race my eager reservation closes. If #1360 lands, the reservation may be redundant, and I would drop it.Tell me which way you want this to go. I am happy to rebase onto either, or to cut the reservation out of this PR and keep only the placement and the overlap handling.
CI and rebase. Same limit as #864: I cannot push a branch that carries
main's.github/workflows/conventions.ymlcommits without aworkflow-scoped token, so this head is based on931109b3. You mentioned approving the pending CI runs, and I can see those. A "Sync fork" on my fork would let me rebase onto currentmainand re-run everything here.Imported from boykopovar/AnyPS5. Originally posted by oneandonlydean on 2026-10-08T05:12:40Z.
The Windows build fails on this head:
Please put the new
<unistd.h>/<sys/mman.h>includes, and the code that needs them, under#ifndef _WIN32.Imported from boykopovar/AnyPS5. Originally posted by jeffrey12cali on 2026-10-08T11:56:22Z.
Fixed, and thank you for catching it. Head is
90172a19.The three POSIX headers were added at the top of
GuestArena.cppoutside any guard, which is exactly the reported failure:They are now inside
#ifndef _WIN32, together. The code that needs them was already guarded:TryReserve,ReserveFreeRangesand the constructor call sit inside#if defined(__linux__), andMarkUsedForCommituses only standard facilities, so it compiles on both.How I checked it, and the limit of that check. I have no MinGW toolchain on this machine, so I could not run the Windows build. I verified the reported failure specifically, with the preprocessor:
g++ -E -D_WIN32over the file: exit 0, and no request forsys/mman.horunistd.h(previously that was the fatal error).g++ -Efor Linux: exit 0, headers still resolve.ctest:100% tests passed out of 438.So this removes the reported error, but only CI on the MinGW job can confirm the Windows compile. Please approve the run when convenient.
@ghreprimand thank you for the careful independent check on PPSA01341, and for stating its limits as clearly as the result. The mapping movement is the part this PR is about: high addresses such as
0x7fff94400000on the base, versus0x200000000and0x200300000with the change, and the title passing the allocator-initialisation fault at RVA0x812b49. I also take your two caveats as written: this is an early-startup result and not a playability claim, and the later fault at RVA0x1452ee3is a separate matter with no established cause. TheuserfaultfdENOSYSskip on your kernel is worth noting for anyone else reading this thread, because it meansagc_write_trackingis not evidence either way there.Imported from boykopovar/AnyPS5. Originally posted by blawesom on 2026-10-08T12:29:13Z.
Review: DISMISSED
Two findings on the current head, both pre-merge. Everything else from the earlier rounds I re-verified still holds: eager reservation, the commit-specific
MarkUsedForCommit, protection switch, and the new kernel-level tests all check out against the source.1. Windows CI is red on this head:
GuestMemory.cppdoes not compile.The MinGW job fails at
core/libs/tests/GuestMemory.cpp:553:Moving the
#endiffence down pastCheckFixedMappingsReachTheApplicationAreaEndmadeCheckUnmappedArenaRangeStaysReservedcompile on Windows, and it uses rawmmap/PROT_READ | PROT_WRITE/MAP_FIXED_NOREPLACE/EEXIST. The preprocessor check after the include fix coveredGuestArena.cppbut not the test file. The function (and its call site inmain) needs a#if defined(__linux__)guard — the hostileMAP_FIXED_NOREPLACEprobe is Linux-specific anyway. The other new tests compile cross-platform, so the guard can be tight: only this one function.2. The Linux
GuestArenaReset_nid_postfixreleases arena accounting internally, breaking theResetcontract every other caller follows — causing a double release (and a race) on every Linux call site.The Windows
Reset(WindowsMappings::Reset) resets memory and never touchesArena::_used; accounting is always the caller's job. That is the contract everywhere in the tree:GuestHeap.cpp:171:GuestArenaReset_nid_postfix(...)thenGuestArenaRelease_nid_postfix(...)munmapshim inDirectMemory.cpp(~line 104):GuestArenaReset_nid_postfix(...)thenarena.Release(...)BdaResources.cppandRecorder.cpp:GuestArenaReset_nid_postfixpaired withGuestArenaRelease_nid_postfixThe new Linux implementation ends with
Arena::Get().Release(pointer, bytes);, so on Linux every caller now releases twice:Unmap(DirectMemory.cpp):GuestArenaResetreleases, thenArenaForget→Containsis span-based, still true →GuestArenaReleasereleases againGuestHeap::release:GuestArenaResetreleases, then the explicitGuestArenaReleasereleases againIn the single-threaded case the second
Releasehappens to be idempotent. But the two releases take the arena lock in separate acquisitions, so between them another thread canGuestArenaAllocatethe just-freed range — and the secondReleasethen erases the new owner's entry from_used, after which the arena hands the range out again. Guest heap frees and kernel mappings run on different threads in real titles, so this is reachable, not theoretical.The minimal fix is to delete
Arena::Get().Release(pointer, bytes);from the LinuxGuestArenaReset_nid_postfixand restore the Windows contract (memory-level reset only, accounting by the caller). With that line gone,Unmap'sArenaForgetstops being a redundant double release and becomes the single release it was evidently written to be, andGuestHeap::releaseis correct as on Windows. NoteArenaForgettoday is never load-bearing: on the arena path it double-releases, and on themunmappathContainsis false so it does nothing.Imported from boykopovar/AnyPS5. Originally posted by jeffrey12cali on 2026-10-08T14:31:37Z.
Both findings confirmed in the source, and both are fixed on head
e0731456. Two commits, one per finding.1. The Windows build failure was mine, and my earlier check could not have found it.
CheckUnmappedArenaRangeStaysReservedusedmmap,PROT_READ,PROT_WRITE,MAP_FIXED_NOREPLACEandEEXISTwith no guard, and its call site had none either. I verified the guard by tracking conditionalnesting: before the change, the probe body (line 554) and the call (line 1167) are outside every
__linux__block; after it, both are inside one. The other
PROT_READ | PROT_WRITEuse in the file, line 1010, wasalready guarded.
I should also correct what I said last round. I reported that I had verified the include fix with
g++ -E -D_WIN32. That check can only find preprocessor errors such as a missing header. An undeclaredidentifier is a semantic error, so no amount of
-Eoutput would have shown this. The guard is what fixesit, and only CI can confirm the build itself.
2. The double release is real, and your description of the mechanism is exact.
I confirmed each part in the source:
Arena::Containscompares against_baseand_endonly, so it stays true after the range is freed.Arena::Releaseerases every overlapping entry in_used, under its own lock acquisition.Unmapreleases insideGuestArenaReset_nid_postfixand then again throughArenaForget.GuestHeap::releasecallsGuestArenaReset_nid_postfixand thenGuestArenaRelease_nid_postfixdirectly.I then checked that no caller is left without a release, which is the only way your minimal fix could go
wrong. Every caller already releases explicitly:
Recorder.cpp:68,DccKeysFirstWrite.cpp:107,Srgb8ColorTarget.cpp:140and three sites inBdaResources.cppeach follow a reset with a release, and theWindows paths in
DirectMemory.cpprelease in the caller as well. So the deleted line was the only placewhere the reset did the accounting itself.
ArenaForgetbecoming the single release on the arena path is the outcome I expected from your note.Suite: 438 of 438 pass on this head.
Imported from boykopovar/AnyPS5. Originally posted by jeffrey12cali on 2026-10-08T15:47:38Z.
Rebased onto current
main. Head isc2e15098, three commits, base4b005b22. The branch wasmergeable=falsebefore this, so the stale base was not harmless after all. I had assumed a three-way merge would absorb it;
that was wrong and I am correcting it here.
The conflict, and how I resolved it.
c01044eeadded commit-generation and private-mapping-observermachinery to
GuestArena.cppinside the#ifdef _WIN32region, which also carried its own copy of theOutsideArenahelper. This branch hoists that helper out of the region so the Linux path can throw it too.The resolution keeps both intents:
OutsideArenadefinition, outside the region, visible to both platformsGuestArenaCommitGeneration_nid_postfixandGuestArenaSetPrivateMappingObserver_nid_postfixkeptWindows-only, in the header and in the source, matching the
#ifdef _WIN32atomics they readGuestArenaCommit_nid_postfixkeeps the generation and observer logic unchangedGuestArenaCommit_nid_postfixandGuestArenaReset_nid_postfixare untouched by the rebaseI checked that structure with a preprocessor-nesting pass rather than by eye, because the two duplicated
function names are easy to get wrong: definitions per platform, and the new symbols inside the region in both
files.
Validation. Suite on Linux: 463 of 463. The two fixes from your review are preserved: the guarded
fixed-mapping probe and the release-contract change. What I cannot check here is the Windows build, because
the resolved code is Windows-only and this machine has no MinGW. CI has to confirm it.
cmake --build buildalso fails on a
jpeg_turbo_externalinstall step that wants/opt/libjpeg-turbo, which is unrelated to thischange and is why
scripts/build.shnames its targets.Written with AI assistance.
Imported from boykopovar/AnyPS5. Originally posted by fisherjoey on 2026-10-08T19:30:56Z.
Linux data from a retail title.
Demon's Souls (PPSA01341 v1.07), Nobara 44 (Linux 7.2), GCC 16.2.1, Release, RTX 5070 Ti (595.91.07). Same relinked binary in all runs, no env vars.
main4b005b22without this PR: SIGSEGV 4-11 s after launch, under_dl_init, before the title opens any file. The fault is a guest byte store in an init function (mov %cl,(%rdx)) to 0x7fe19adb0d96 (SEGV_MAPERR, an unmapped address up in the host mmap range). It happened in 2 of 2 runs, and in 2 more with a modified libc.main4b005b22+ this PR (head c2e15098): boots, loads/app0/packagecmdlineargs.txt(#1321 resolves the case), and plays the attract movie at about 30 fps. Closing the window exited with code 0, in 2 of 2 runs.So on this setup the title doesn't start on Linux without this PR.
AI-assisted: yes.
Imported from boykopovar/AnyPS5. Originally posted by jeffrey12cali on 2026-10-08T22:30:56Z.
This is the most useful report on the thread, and one part of it I can answer with a measurement.
On the reservation and
VK_ERROR_OUT_OF_DEVICE_MEMORY. I tested whether the eager reservation is whatstarves device allocations. The probe reserves the same window this PR uses -
0x200000000to0xFC00000000, 1 GiB chunks,PROT_NONE | MAP_PRIVATE | MAP_ANONYMOUS | MAP_NORESERVE | MAP_FIXED_NOREPLACE, 1000 chunks, zero failures - and then allocatesVkDeviceMemoryfrom a heap withVK_MEMORY_HEAP_DEVICE_LOCAL_BITuntil it fails, once with the reservation and once without.-2-2-2-2-2So on my hardware the reservation does not reduce how much device memory can be allocated. Note also that
NVIDIA accepted 22 GiB of device-local allocations against an 8 GiB heap before failing: the limit reached
here is not the heap size.
Two limits on that conclusion, so it is not over-read. My card is a 4070 Laptop on driver 615.71.09, not a
5070 Ti on 595.91.07. And the probe allocates unbound
VkDeviceMemory, while a title binds buffers andimages and may import host memory, so this rules out "the reservation steals device memory" narrowly, not
"the reservation is unrelated to your failure".
What would help. Since the title cannot run at all without this PR on your setup, the OOM cannot be
bisected against the PR alone. Two things would settle it:
allocationSize,memoryTypeIndex, and that type's heap index and flags. AnOUT_OF_DEVICE_MEMORYwith 14 GiB free usually means a constrained memory type (host-visible, or a BARwindow) rather than an exhausted heap.
SOS-style reservation disabled - if you can run a build where the reservation isskipped but the window placement is kept, that separates the two halves of this PR.
I can post the probe source if it is useful to run against your card.
Housekeeping. The branch is rebased onto current
main(head3c54adf0) and the description now carriesyour result, the two fixes from @blawesom, and the measured test times. Your run was against
c2e15098, sothe numbers should be re-checked against the new head if you get a chance - no rush, and thank you for the
detail either way.
Imported from boykopovar/AnyPS5. Originally posted by jeffrey12cali on 2026-10-08T22:39:59Z.
Rebased onto current
mainafter @fisherjoey's report; head is3c54adf0, five files. CI is now green on it,which closes the first finding directly:
windows: success. The MinGW build that failed with'PROT_READ' was not declared in this scopenowcompiles, so the
__linux__guard on the fixed-mapping probe was the right fix.linux: success. Suite locally: 491 of 491.conventions: success.Two notes for whoever re-reviews. The branch was 100+ commits behind, but no commit in that range touched
GuestArena.cpp,GuestArena.hpp,GuestHeap.cpp,DirectMemory.cpportests/GuestMemory.cpp, so therebase applied without conflict. And
CONTRIBUTING.mdgained a rule in that range: every test must finish in30 s on the runners, cold. The slowest test in the suite is 4.19 s, and the two tests added here take 0.01 s
each, so this head is inside it.
The second finding, the double release, is unchanged by the rebase:
GuestArenaReset_nid_postfixresets only,and each caller releases once.
Imported from boykopovar/AnyPS5. Originally posted by hugodearaujo on 2026-10-09T12:36:39Z.
Another title for this one: Hades (PPSA03355 v01.003) on Linux (Arch, GCC, RX 9070 XT).
Its bundled
libc.prxcreates the title's 4 GiB mspace frommalloc_init:sceKernelAllocateDirectMemory(0, 0x360000000, 0x100000000, 0x200000, 0xC), thensceKernelMapDirectMemory, thensceLibcMspaceCreate. Onmainthe mapping lands at0x7ffef3a00000. The bundled libc's ownsceLibcMspaceCreaterefuses that address (its range checks shift by 40 and 43 bits),malloc_initreturns 1, and libc's start-up raises:(
0xa0020013), followed by a crash.With this branch (
3c54adf01) merged onto currentmain, the raise is gone. The title creates its Vulkan device and swapchain, uploads its first textures, and stops much later on an unrelated renderer issue.Note: on
main, Hades first stops at load on the missingpthread_getname_np(#1798), so these runs include that PR as well.Imported from boykopovar/AnyPS5. Originally posted by jeffrey12cali on 2026-10-09T14:46:48Z.
One more reason this PR matters on Linux, found while chasing a frame-rate problem on a title.
PageStates::initializeinlibSceAgcDriver/Execution/src/GuestMemory.cppasksGuestArenaRangefor theguest window in order to size a per-page bitmap, and
describePagesconsults that bitmap before it queriesthe kernel. Because the
Arenaconstructor here is inside#ifdef _WIN32, on Linux the range isbase = 0 size = 0,PageSpan::allocate()fails,spanOf()always returns null, and every guest-memoryvalidation falls through to reading and parsing
/proc/self/maps- once per loop iteration. Measured on aretail title: 1,172,045 map parses and 64,207,427 parsed lines in one run, 50.8 % of all CPU inside
std::istream, with the game's own code at 3 %.Populating the span and caching the query results moved the CPU-bound frame rate from 7.40 to 60.32 FPS.
So a non-empty arena span on Linux is a precondition for that fix to do anything, which is what this PR
provides. Noting the dependency here as well, since AnyPS5#1791
and #1810 already cover the caching half: without #861 the
Linux effect of #1810 is nil, because there is nowhere to store.
Also worth knowing:
PageStates::initializeonly registers theForgetPagesinvalidator when a spanallocated successfully, so on Linux today no page invalidation is installed at all. Making the span exist
activates it as a side effect.
Written with AI assistance.
Imported from boykopovar/AnyPS5. Originally posted by hugodearaujo on 2026-10-09T15:30:29Z.
One more title for this one: Hollow Knight: Silksong (PPSA12544) on Linux, through flexible memory this time.
The title's bundled
libSceNpCppWebApirunsCppWebApi::Common::initializewhen the PSN plugin starts. It callssceKernelMapNamedFlexibleMemory, then the bundled libc'ssceLibcMspaceCreateon the result. That returns NULL for the addressmainhands out, and the title stops:followed by an uncaught
Unity.PSN.PS5.PSNExceptioncarrying0x80553504.Base:
maind70b89989+ #1836 + #1431 + #846 + #2323. With this branch (3c54adf01) merged on top, that stop is gone and the title reaches its title menu at about 60 fps.Imported from boykopovar/AnyPS5. Originally posted by Mouhand-Kaddo on 2026-10-09T21:10:07Z.
Independent Windows and Arch WSL validation of head
3c54adf0195ed10b0b246a0e552d069025f9cbe5(all three commits), cherry-picked without source edits onto main8b393b6e. No other runtime PRs were included in these isolated suite runs.libstarget succeed. CTest: 507 passed, 1 skipped, 3 failed / 511, 36.09 s.guest_memory,fiber, andwindows_exceptionspass, including the Windows compilation of the guarded mapping probe. The three failures (agc_driver_pixel_interlock,agc_driver_sdwa_float_selectors,agc_driver_sdwa_ldexp_f16) also fail after rebuilding their targets on unchanged main8b393b6e;guest_memorypasses there too.libssucceed. CTest: 489 passed, 27 skipped, 1 timeout / 517, 45.00 s.guest_memoryandfiberpass.agc_driver_flat_storereaches the 30 s timeout both here and after rebuilding its target on unchanged main8b393b6e. This is software-Vulkan coverage, not Linux hardware-GPU validation.Demon's Souls startup also advances on Linux. Keeping the PR #1559 relinker conversion fixed, main runtime libraries fail during heap setup with a high host mapping around
0x7fffd4500000. Replacing only the runtime libraries with this isolated PR's build moves allocations into the console window (including0x200000000) and passes heap setup, worker-thread creation, and Vulkan device initialization. It still stops later with a bad worker-queue pointer or a wiped saved fiber context; I am not reporting playable compatibility. PR #2054 and #2310 are absent from that Linux runtime comparison.I have now rebased the separate integration branch onto main
4c367419for further investigation. The suite counts above specifically describe8b393b6e+ this PR, not that newer integration branch. Testing and this report were AI-assisted.Imported from boykopovar/AnyPS5. Originally posted by adriadam10 on 2026-10-09T22:00:21Z.
Review: DISMISSED
Rebuilt this head merged onto current
main(Linux, GCC):guest_memorypasses, butguest_mlockaborts (it passes onmainwithout this PR;patched_librariesfails here with or without it, so I'm ignoring that one).guest_mlockregression. The lastmlockbefore the abort is on the range just unmapped withsceKernelMunmap(mapped, length)(core/libs/tests/GuestMlock.cpp:112-114), which expects-1/ENOMEM. With this PR an in-arena unmap goes throughGuestArenaResetand leaves the range as aPROT_NONEreservation (DirectMemory.cpp:452-455), sosceKernelMlock/sceKernelMunlockno longer see an unmapped range. The test landed withmunlock; the head was green before it was onmain. Please makemlock/munlock(and anything else that asks the kernel "is this mapped?") answer from the allocation registry instead of the host mapping, or otherwise restoreENOMEMfor unregistered ranges, and keepguest_mlockpassing.Arena::PageSize()(GuestArena.cpp:222) is unused;<sstream>/<fstream>sit outside the#ifndef _WIN32block they belong with; double blank line atcore/libs/tests/GuestMemory.cpp:522.The rest looks right to me, and the title reports in the thread (Demon's Souls, Hades, Silksong, LEGO Horizon) are good evidence for the placement. Once
guest_mlockis green I expect to merge.Imported from boykopovar/AnyPS5. Originally posted by alfalfa-star on 2026-10-10T08:48:38Z.
On current
main(6cc33583), this branch (3c54adf0) merges cleanly but breaksguest_mlock. That test came in withmlock/munlock(892aa8b5,107860878), after this branch's base, so CI here never ran it.mainalone:guest_mlockpasses.main+ this PR: it aborts.GuestMlock.cpp:118: aftersceKernelMunmap(mapped, length),munlock(mapped, page)should return -1 with ENOMEM (12), but it returns 0. Themlockcheck just before it (line 116) still fails with ENOMEM as expected.sceKernelReserveVirtualRangereservation. The test expectsmunlockon a reservation to succeed (line 110) and on a freed range to fail (line 118), and those two states now look the same to the host. SosceKernelMunlockprobably needs to ask the guest mapping state, asmsyncdoes withRangeMapped, rather than the host.Setup: Linux (Arch), GCC, Release. Found while rebuilding our PPSA14632 test branch on current
main.Imported from boykopovar/AnyPS5. Originally posted by oneandonlydean on 2026-10-10T10:00:00Z.
@jeffrey12cali @adriadam10 Rebased onto current main and pushed to the branch; your three commits are unchanged apart from the test-file conflict with
CheckGuestModuleImageProtection(kept under#ifdef _WIN32). Two commits on top:guest_mlock: an unmapped arena range stays aPROT_NONEreservation, so hostmunlocksucceeded on it. On LinuxsceKernelMunlocknow checks the guest mapping state first, the same checkmsyncuses (RangeMapped, moved toDirectMemory.hppasGuestRangeMapped), and returnsENOMEMfor ranges that are neither mapped nor reserved.mlockalready returnsENOMEMthere from the host./proc/self/mapscan't be read or parsed, and when the kernel places a chunk somewhere other than the requested address (kernels that treatMAP_FIXED_NOREPLACEas a hint). Also removed the unusedPageSize()and moved<fstream>/<sstream>into the non-Windows block.Linux, GCC, Release: ctest 694/695 on this head,
guest_mlockandguest_memoryincluded. The one failure,agc_driver_dcc_keys_first_write, fails the same way on main.Imported from boykopovar/AnyPS5. Originally posted by jeffrey12cali on 2026-10-10T11:02:55Z.
Thank you for the rebase and for fixing
guest_mlockrather than asking me to. The diagnosis matches what weassumed when we wrote the reservation: an unmapped range inside the arena stays a host reservation, so a host
munlockon it succeeds while the guest contract saysENOMEM. Checking the guest mapping state first, thesame test
msyncuses, is the right shape, and exporting it asGuestRangeMappedis better than a secondcopy of the logic.
Two notes from the far end of this change, on the title #692 was filed for (
PPSA28997):reach its main menu at all. It now holds 60 FPS through 15 minutes of continuous play.
/proc/self/mapsto place the window. That is fine where it is,because it runs once at start-up. I only mention it because the same file on the per-frame path is the
subject of #1791 and was fixed for the hot path by #157, so a reader may otherwise take the two readings to
be the same problem.
One process note against myself: the Windows
sys/mman.hfailure you caught is the second portability mistakeI have shipped in this area. I now guard every Linux-only include in the same
#ifndef _WIN32block as thecode that needs it, which is also what the fork change in #1791's shape should do.
For the maintainers coordinating the queue: with #861 merged, #1810 and #2660 are no longer blocked by the
empty arena span, and the branch referenced in #1791 can now store anything on Linux.
Imported from boykopovar/AnyPS5. Originally posted by EdouardSence on 2026-10-10T11:36:05Z.
Ratchet & Clank: Rift Apart (PPSA01474) on Linux faults about 11 s in since this merged (3 of 3 runs on
b5f5362d3, gone in 2 of 2 with only this PR reverted). The trace and the placement sequence are in #2704: an address-less 64 GiB reservation is now placed at the bottom of the arena and covers the addresses the title hints for its next direct maps.Tested and written by Claude (AI assistant) on a contributor's machine.
Imported from boykopovar/AnyPS5. Originally posted by jeffrey12cali on 2026-10-11T14:46:14Z.
Author of the arena here, and the bisect is right: this is my change, not something the title was already doing.
What I got wrong. #861 places an address-less reservation at the lowest free address of the arena. For
PPSA01474that put a 64 GiBPROT_NONEreservation directly over the addresses the title then hints for itsnext two direct maps, so the non-fixed maps were relocated above it while the title went on using the hinted
address. Before the arena, the reservation went to the host's top-down area and the hints were honoured by
accident. Placing at the bottom was chosen for contiguity and was never tested against a title that hints after
reserving.
Status, for anyone reading this later. The fix is already on
main:PlaceHintInReservationincore/libs/prx/libkernel/DirectMemory/DirectMemory.cpp(from #2667), which came through #2687; #2704 wasclosed as a duplicate of it. Resolving it at map time rather than by moving the reservation is the right call,
and it is better than anything I would have proposed, because it leaves the placement policy alone.
The constraint from the other side, which the fix has to keep.
PPSA28997is a title that needs what #861provides: with address-less mappings landing top-down it asserts at start-up, which is #692, and the low-window
arena is what lets it reach its main menu and hold 60 FPS. So the two titles pull in opposite directions - one
needs address-less reservations kept inside the low window, the other needs its hints to survive a reservation
that covers them. Honouring the hint at map time satisfies both, and I would not want a later simplification to
revert to "place address-less reservations high" just because that made the second case work.
What I can test, and what I cannot. I cannot run
PPSA28997on baremaintoday: our engine tree is a forkpinned behind
main, andmainlacks theUmtx,PthreadandExceptionshapes this title needs, plus thebundled-
libc.prxheap handshake still aborts at start-up there (see #693). So the honest test I can offer ison our fork once it merges
main: 15 minutes of scripted play with the mapping count and the start-upmilestones sampled, to confirm
PlaceHintInReservationdoes not take the low window away from the titles thatneed it. Say the word if that is worth having and I will run it and post the numbers here.
Thanks for the bisect and for writing it up with the trace - the
hint=lines are what made this diagnosableat all.