The conflict in core/libs/tests/GuestRudpContextLifecycle.cpp with #13799 keeps both changes: this branch's removal of the check that sceRudpActivate throws, and main's sceRudpBind(ctx, 5, 0, 2) call after it.
The check allocated three physical blocks and accepted whatever the allocator returned, so an ordinary run could coalesce them into one and never exercise a scattered result, and a layout where only the latter two are adjacent (two runs) failed its count. One four-page allocation mapped in the order 2,3,0,1 gives exactly two runs, with the latter mappings required to coalesce; the offsets, lengths, a partial-range query, the backing byte and the insufficient-capacity refusal are checked exactly.
Test patch by JJenkx (#4449 comment, deterministic-scattered-runs-linux-20261029).
Co-authored-by: JJenkx <[email protected]>
Co-Authored-By: Claude Fable 5.1 <[email protected]>
Conflicts: GuestArena.hpp/.cpp keep both sides' exports; GuestBufferMemory.cpp keeps this PR's run-list createBackingImport and resolves importStaysWatched's shared-backing check through the run resolver (sharedBacked), replacing main's BackingFile/sharedBacking; the debt file keeps this PR's sparse-import entry and main's presentation entry.
Co-Authored-By: Claude Fable 5.1 <[email protected]>
Mapping a direct memory range that includes an unallocated physical
page threw std::invalid_argument and ended the process. It now returns
ENOMEM before anything is mapped, as shadPS4's MemoryManager::MapMemory
does.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
KytyPS5 and shadPS4 return EFAULT for a null name. The test keeps that
and the rename and clear checks, and drops the null address, zero length
and past-the-end cases that no reference covers; the debt entry records
them as unknown, with the 32-byte name limit.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
RequireUnpinned waits for the GPU work that leases a range through the
driver's waiter, but GuestAllocationsAcquireAll and Acquire copy every
registered range into each new lease, so a driver worker that starts an
address-based build between the waiter's return and the re-lock pins the
range again. A title that draws every frame keeps replacing the lease,
and the free fails after APS5_PIN_WAIT_MS.
A mutation that finds a pinned range now records it as retiring until the
wait ends; Acquire and AcquireAll leave retiring ranges out and do not
cache the lease while one is recorded. guest_memory gains a check that
replaces the lease from the waiter the way a worker does: without the
change the unmap fails with "still pinned after 8 recorder syncs".
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
A guest mmap with PROT_EXEC and MAP_SHARED of a shared-memory object or a regular file threw on Windows. The section is now created from a handle reopened with GENERIC_EXECUTE, as PAGE_EXECUTE_READ or PAGE_EXECUTE_READWRITE, the owner ACE of named objects grants execute with read, and a writable shared mapping of a read-only descriptor fails with EACCES, as FreeBSD 11.4 shm_mmap and vn_mmap do.
Fixes#12337
A 900 byte block shrinking to 40 bytes and a 1 MiB block shrinking to 4 KiB have
to move and keep their data, while a 1 MiB block resized by 100 bytes stays put.
A 1000 byte block shrinks to 900, regrows to 1000 and is realigned to 800 at the
same address with the matching usable size and its data intact; growing it to
1 MiB moves it and keeps the data.
This reverts commit 780b33aea3, restoring the 13824 MiB direct memory pool.
With the pool at 12288 MiB, Astro Bot (PPSA21564) can no longer load its
level: DirectMemoryAllocator asserts "Can't allocate direct memory" for a
64 MB VideoPlayerTexture with 12228 of 12288 MB in use, then the process
faults about 26 s in (2 of 2 runs, RTX 4090, Linux, main cccdaa2734).
The same tree with only this merge reverted runs the full 150 s with no
direct memory assert (2 of 2 runs).