Commit Graph
14017 Commits
Author SHA1 Message Date
Alexej Szpevák cb9a4c7417 feat(libkernel): support EV_CLEAR on sockets and pipes in kevent on Linux
kevent threw for EV_CLEAR on a socket or the read end of a pipe; Boost.Asio's kqueue reactor, among others, registers every socket that way. On Linux such a knote now watches its host descriptor through an edge watch. It is armed when added, on every later EV_ADD or EV_ENABLE while enabled, and by each host wakeup; when armed it is checked with the level-triggered readiness test and reported with the current data and EV_EOF, or disarmed if no longer ready, as kqueue_scan re-runs the filter; reporting it disarms it until the next edge. Waits block on the watch's epoll descriptor, so a socket that stays readable does not wake them. Windows and macOS still throw. GuestSockets::NativeDescriptor exposes the host socket behind a guest one for the watch.
2026-10-19 15:05:28 +02:00
MarcZX100 c5f8a3ff22 test(agc): isolate allocation budget query counts 2026-10-19 15:05:18 +02:00
MarcZX100 415dcab140 test(agc): account for allocation budget queries 2026-10-19 15:05:18 +02:00
MarcZX100 e6a78f41bf chore(agc): report heap budgets on buffer allocation failure 2026-10-19 15:05:18 +02:00
Tomás Ortellado 1c993d1889 test(agc): bound shader helper test runtime 2026-10-19 10:05:12 -03:00
Alexej Szpevák 7e67261d5f feat(libkernel): add an epoll edge watch over a host descriptor
FreeBSD activates an EV_CLEAR knote on each state change the object reports through KNOTE (sorwakeup, sowwakeup, pipeselwakeup), not on its level, so polling the level cannot tell an EV_CLEAR knote when to fire again. EdgeWatch::Watch registers the host descriptor with a private epoll instance in edge-triggered mode: every wakeup of the descriptor with a matching mask (data arriving, buffer space freed, a hang-up) queues one edge, which TakeEdge consumes, and the epoll descriptor itself is readable while an edge is pending, so a wait can block on it. Off Linux opening a watch throws.
2026-10-19 15:05:11 +02:00
Alexej Szpevák 5cbc46029b refactor(libkernel): let an equeue filter name the descriptor its waits block on
WaitForDescriptors always handed the knote's own descriptor to the host wait. A filter that tracks readiness through a descriptor of its own, such as an edge watch, needs the wait to block on that descriptor instead, or a descriptor that stays ready keeps waking the wait. KernelFilter gets a waitDescriptor, and the filter's owner is held for the length of the wait so the descriptor cannot be closed under it.
2026-10-19 15:05:10 +02:00
Adrià 3bb15be094 Merge pull request #6799 from milescoviello/fix/cube-face-image-store
fix(shader): store through DIM 2D image_store to a cube T#'s BASE_ARRAY face
2026-10-19 15:04:02 +02:00
Adrià a1dfc73380 Merge pull request #6748 from milescoviello/perf/read-only-descriptor-tables
perf(shader): declare the read-only descriptor tables NonWritable
2026-10-19 15:02:57 +02:00
Adrià Franch f533fef893 docs(libSceRudp): drop stale and duplicate debt entries 2026-10-19 15:01:06 +02:00
Rajkamalcode cea6fabfae fix(libc): return -inf from y0f, y1f and ynf at zero
The guest's second-kind Bessel functions return -inf and raise the divide-by-zero exception for x = +-0 (see e_jn.c), but the UCRT returns NaN for y1 and yn. Route x == +-0 through a shared helper, cover ynf(2, 0) in the guest math test, and note the special case in the libc technical debt.
2026-10-19 18:31:00 +05:30
Aryan SharmaandClaude Haiku 5.5 3ef8925a99 feat(libSceRudp): implement sceRudpEnableInternalIOThread2
The managed SceRudp.Rudp.EnableInternalIOThread in PPSA06888's Unity
metadata takes (uint stackSize, uint priority, ulong affinity), which
gives the signature. Like sceRudpEnableInternalIOThread it reports
RUDP_ERROR_NOT_INITIALIZED before sceRudpInit and success after it,
without starting a thread.

Co-Authored-By: Claude Haiku 5.5 <[email protected]>
2026-10-19 15:00:54 +02:00
Aryan SharmaandClaude Haiku 5.5 7b626baa23 feat(libSceRudp): implement sceRudpNetReceived and declare sceRudpGetOption
sceRudpNetReceived follows sceRudpNetFlush: it reports
RUDP_ERROR_NOT_INITIALIZED before sceRudpInit and success after it, since
no packets are ever received. sceRudpGetOption now has the signature its
PPSA06888 call sites use, (ctx_id, option, value, len), and still throws
because the option codes, defaults and errors are unknown.

Co-Authored-By: Claude Haiku 5.5 <[email protected]>
2026-10-19 15:00:54 +02:00
Adrià c562814ca0 Merge pull request #6906 from Zinebyte/fix/nid-write-errors
fix(nid): report failed library writes
2026-10-19 15:00:31 +02:00
Adrià 27cbe9c154 Merge pull request #6904 from Zinebyte/fix/elf-sysv-nid-hash
fix(nid): rebuild SysV hashes after renaming ELF symbols
2026-10-19 15:00:25 +02:00
Rajkamalcode 368fb65ab2 fix(libc): keep the guest %ld argument 64-bit in the err test
The guest is LP64, so vwarnx consumes a full 64-bit slot for %ld. On LLP64 hosts (Windows) the 123456789L argument is only 32 bits wide and leaves the upper half of that slot undefined, so the check saw garbage in the high bits.
2026-10-19 18:29:59 +05:30
Adrià 6af4e4d17f Merge pull request #7011 from MarcZX10/codex/docs-video-output-resolution
docs(usage): explain video output resolution
2026-10-19 14:58:18 +02:00
Crimson bd03daa4f2 fix(shader): give the default NaN for an f16 fma invalid product with a NaN src2 2026-10-19 14:57:35 +02:00
Crimson 49d22c5b8f test(agc): require the default NaN for f16 fma invalid operations 2026-10-19 14:57:32 +02:00
Crimson de82860c94 fix(shader): leave a NaN src2 of an f16 fma invalid product to the driver 2026-10-19 14:57:32 +02:00
Crimson e98cf7f9a0 fix(shader): give f16 fma invalid operations the default NaN
v_fma_f16, v_fmac_f16, v_fmamk_f16, v_fmaak_f16 and v_fma_mix_f32 with
f16 sources left the NaN of an invalid operation to the driver, so
inf * 0 gave 0x7fff and 0x7fffffff on NVIDIA where the hardware gives
the default NaN 0xfe00 and 0xffc00000. An inf * 0 product, or a NaN
from sources that are not NaN, now gives the default NaN; NaN sources
are still left to the driver.
2026-10-19 14:57:26 +02:00
XairRrR 3f0d75025f docs(agc): keep the depth planes debt entry under the length limit
State the gap first and drop the mechanism details the code and the
pull request already carry.

AI-assisted: yes
2026-10-19 14:51:51 +02:00
XairRrR c505661ea9 fix(agc): store a depth plane over the guest writes made before the store
A storage image's write-back keeps the 64 KiB blocks written since its
layers were last in sync, since the memory may have been reused. A
depth plane's image is overwritten whole by every store, but it kept
the sync state of its creation or last reload. A plane bound behind an
HTILE fast clear never reloads, so once guest memory over it had been
written (another render target over the same memory), every later
store kept those blocks and the drawn depth never reached guest memory.
A store now marks the image as holding the whole plane, as a whole-image
copy does (StorageTexture::MarkWholeWritten, split out of CopyFrom).

agc_driver_depth_plane_buffer_memory gains the case: store a plane,
write its memory, clear its HTILE and draw, then fetch the plane. It
fails without the change (the fetch reads the guest write).

AI-assisted: yes
2026-10-19 14:51:51 +02:00
UAQ Taxi a968336825 fix(libc): remove Windows trees without the remove_all symlink hang
MinGW libstdc++ up to GCC 16 does not treat a reparse point as a link in
std::filesystem::remove_all, so a host tree that holds a symlink is walked
through the link and never returns. Add RemoveTree, which removes the tree
itself on Windows, and use it where save data, app content and the shader
disk cache removed host trees. The libstdc++ fix is in GCC 17 (88856ad855ae).
2026-10-19 14:49:49 +02:00
UAQ Taxi 379dca5cac test: raise the slow-host timeouts 2026-10-19 14:49:36 +02:00
Adrià Franch c8cc0380d0 docs(usage): move display resolution section below the relinker paragraphs it was splitting from Runtime layout 2026-10-19 14:48:42 +02:00
MarcZX100 4c3fca7e66 docs(usage): explain video output resolution 2026-10-19 14:48:42 +02:00
Adrià f3bb6a4f8d Merge pull request #6878 from Dragost/fix/libkernel-directory-descriptor-seek-end
fix(libkernel): support SEEK_END on directory descriptors
2026-10-19 14:48:26 +02:00
Adrià d5bbceb4f7 Merge pull request #6725 from johandavidcm/fix/agc-depth-write-address
fix(agc): compare the depth write base only when the depth plane is written
2026-10-19 14:48:21 +02:00
Adrià e3d401e6fe Merge pull request #6964 from Owes-UX/docs/debt-drop-implemented-imports
docs(debt): drop implemented functions from unknown-signature lists
2026-10-19 14:48:12 +02:00
Adrià a89d78a403 Merge pull request #6627 from mrfelek/docs/game-testing-guide
docs(dev): add a game testing guide
2026-10-19 14:48:08 +02:00
MarcZX100 4c0767c248 test(libkernel): remove stat loop symlink fixture 2026-10-19 14:44:53 +02:00
MarcZX100 7c7a590caa fix(libkernel): map Linux stat symlink loops 2026-10-19 14:44:53 +02:00
MarcZX100 41483e7a21 fix(libkernel): return ELOOP when stat follows a symlink loop 2026-10-19 14:44:32 +02:00
Crimson 317a323eec fix(shader): release the LDS lock with an exchange and drop fences inside it 2026-10-19 14:43:13 +02:00
xXPBSXxandClaude Sonnet 5.5 2368691a9e docs(debt): add the Radeon 860M symptom of the CMASK clear pass
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
2026-10-19 14:43:05 +02:00
T3cm0 6fdb88fd48 fix(libc): share slot 8 in ios_base::_Addstd as the console does 2026-10-19 14:41:10 +02:00
tecmo 4bf4fc9864 feat(libc): implement ios_base::_Addstd
Queue the stream in the table of the 8 standard stream
slots of Dinkumware's ios.cpp: the first free slot or the one
that already holds the stream, with a reference count per slot,
and the destructor suppresses the destruction of a standard
stream while its slot still has open references.
2026-10-19 14:41:10 +02:00
Hamidreza 186b2863ea perf(relinker): flat address-taken vector and region query caching in strict reachability 2026-10-19 14:40:17 +02:00
mopgobopotandClaude Opus 5.5 3f8184ae09 fix(relinker): sort PT_LOAD entries of Linux guest modules by address
The Linux executable sorts its PT_LOAD entries, but guest modules (*.guest.prx) kept them in the input table order. A module whose data segment comes before its text segment in the table was written with PT_LOAD entries out of address order, which the gABI forbids: glibc reserves the span from the first to the last entry, so with 0x2000, 0x1000, 0x4000 it reserved 0x2230 bytes instead of 0x3230 and mapped the text below the reservation. The PT_LOAD entries are now sorted in place, as for the executable.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-19 15:40:05 +03:00
mopgobopotandClaude Opus 5.5 87b53b18ca fix(relinker): accept relocations against symbol index 0 for Windows and macOS
Code analysis rejected R_X86_64_64, GLOB_DAT and JUMP_SLOT relocations whose symbol index is 0 (STN_UNDEF) with 'invalid relocation symbol', so the Windows and macOS conversions failed while Linux converted the same input. The pipeline already resolves such relocations to 0 plus the addend, as the gABI defines and as the relinker technical debt entry records for null symbol entries; only an all-zero entry at a nonzero index was accepted. Index 0 is now treated as an import slot like that entry.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-19 15:40:01 +03:00
mopgobopotandClaude Opus 5.5 104f54da7f fix(tools): place resolved debt entries after their predecessor in the same file
debt_split resolve anchored an added entry to the previous entry of the whole index. When that entry was in another section or another library's file, the new entry was appended to the end of its section instead of being placed before the entry it precedes.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-19 15:39:59 +03:00
mopgobopotandClaude Opus 5.5 e7262ddf99 fix(tools): report trace identity changes between consecutive intervals
Each interval was compared with the first one, so 'changed at interval' listed every interval that differed from the first instead of where a change happened: commits a, a, b, b, a gave 3, 4 instead of 3, 5.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-19 15:39:57 +03:00
mopgobopotandClaude Opus 5.5 de2244040d fix(tools): read a Depends on declaration after an empty one in pr_overlap
Only the first 'Depends on:' was read. When it was empty, such as the template checklist line with its placeholder comment, a later 'Depends on: #N' was ignored and the dependent pull requests were reported as overlapping.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-19 15:39:55 +03:00
babyhuey 4a5ce8a094 fix(libc): adopt the guest SDK allocator only when the title replaces the heap
A bundled libc.prx can export the ten allocator NIDs while forwarding
them to HLE, so adopting its exports for a title whose replacement
table is empty sends HLE allocations back into themselves. Keep the
default heap in that case, as before the guest SDK adoption.
2026-10-19 08:39:37 -04:00
ebosido444-ai 943b7007c9 fix(agc): resolve a relocated AGC header whose arrays hold the registered bytes
A title can relocate a registered shader header, and the register, special and
semantic arrays it points at, into memory of its own and resolve the ABI with
that copy (Astro's Playroom, PPSA01325, #2914). SameHeader accepted such a copy
only while every pointer inside it stayed put, so a moved array left the
resolution throwing "refers to a replaced shader header".

Accept the copy when every array it names still holds the registered bytes: the
registered header then decodes what the copy describes, nothing is copied and
ShaderSnapshot stays immutable. A copy whose arrays differ or are unreadable
still throws.
2026-10-19 14:36:11 +02:00
Owes Mehboob 33cd848ba9 docs(debt): drop implemented functions from unknown-signature lists 2026-10-19 14:34:26 +02:00
valenciana-nc 3eee6be59d test(savedata): update journal and Windows failure cases for exclusive staging 2026-10-19 06:33:14 -06:00
valenciana-nc f7fd9dbf9f fix(libkernel): check recvmsg guest copies on macOS 2026-10-19 06:33:13 -06:00
ABEL VALENCIANA 32b268fe0f fix(savedata): create exclusive temporary files for save replacement 2026-10-19 06:33:13 -06:00