Commit Graph
12196 Commits
Author SHA1 Message Date
Dean Galvin 064a6f98ab Merge main into pr-7427
# Conflicts:
#	core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
2026-10-20 04:25:03 +13:00
Adrià cded26c687 Merge pull request #7007 from MarcZX10/codex/filter-host-ca-pem
fix(libkernel): filter host CA bundle to certificate blocks
2026-10-19 17:25:03 +02:00
Lindamea1andClaude Opus 5.5 179316c452 fix(libkernel): return ENOMEM from sceKernelAvailableDirectMemorySize when the range has no free block
A search range with no free direct memory returned EAGAIN (0x80020023).
A PS5 returns ENOMEM (0x8002000c) for an occupied range, as the
PS5_RetroArch author's console capture records, and PS5_PayloadSDK's
ps5_memory_query, which RetroArch uses for its memory status, gives up
on any other error.

LargestFree now returns the error: ENOMEM when no block is found, and
EAGAIN as before for a negative start, an end at or below the start and
an alignment that overflows when rounded to a page. guest_memory expects
ENOMEM for an occupied range and EAGAIN for those arguments. The
unmeasured argument handling is recorded in the libkernel debt file.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-19 16:24:55 +01:00
Rajkamalcode 448cf78c69 fix(agc): skip storage write-back units that lie in no tiled slice
writeBackWindows retiles the kept 64 KiB units through the windows of the
surface's (layer, mip) slices. A unit can lie outside every window: the
tracking grid spans the whole guest range flat, while the slices of a 3D
surface taper in depth (HasLayer), so the upper depth slices' higher-level
blocks belong to no window. The empty window set then sized the retile
linear and scratch buffers at zero, and the zero-sized device buffer threw
'AGC graphics: zero-sized device buffer', aborting the process.

Keep such units as the guest left them: there is no tiled data of the
surface to retile or store. The caller alone accounts for the unit.
2026-10-19 20:54:46 +05:30
Agnibha Mukherjee 904bb59c25 fix(relinker): decode explicitly enqueued CFG targets at full bounds
The padding bound in buildGraph's decoding loop skipped worklist targets inside the trailing zero region without decoding them, so malformed mandatory roots were accepted silently and complete instructions at targeted zero offsets lost their reachable marking. Decode the first instruction at each popped target against text.size() and keep the codeSize bound for sequential fall-through only. Covers the entry, extra-entry, branch-target, complete-zero-instruction and zero-immediate cases in the direct API test and in the CLI fixture.
2026-10-19 17:24:04 +02:00
Agnibha Mukherjee 1f28b37898 fix(relinker): stop the unused-filter CFG walk before trailing zero padding
buildGraph fell through from the entry points into the segment's zero
padding; an odd-length zero tail left a lone 0x00 the decoder needs a
ModRM byte for, and the non-speculative walk let that truncation escape
the pipeline, so unused-filter=1 exited 2 on input the other levels
convert. Bound the walk before the trailing zeros the way
StrictReachability does; mandatory roots still decode strictly.
2026-10-19 17:23:57 +02:00
Kovalev Vladislav 3955cd3379 fix(shader): skip unsafe prefixed cache directory traversal 2026-10-19 21:23:28 +06:00
Nicolas Abosch 876ad540ff Merge remote-tracking branch 'origin/main' into perf/gpu-wake-sleeps 2026-10-19 12:17:18 -03:00
Kovalev Vladislav 91853d299b test(shader): isolate cache housekeeping safety regressions 2026-10-19 21:17:12 +06:00
MarcZX10 82be87f185 fix(agc): refuse LDS split before allocation 2026-10-19 15:16:58 +00:00
Adrià 43a2abaf77 Merge pull request #6969 from jotitadev/fix/macos-generic-category-test-cast
fix(tests): keep generic category vtable entries castable to functions
2026-10-19 17:13:03 +02:00
pushkarreddyy a1b6caaf0a feat(libkernel): implement setgid 2026-10-19 20:41:52 +05:30
MarcZX100 0e03a753cd test(agc): inject failed Windows write collections 2026-10-19 17:01:06 +02:00
plokmklo 1b6419caae fix(agc): run the unwatch hook when a failed collect leaves the write watch
A MarkWritten whose fresh collect fails (a no-access or unwatchable
resident page inside the 64 KiB block span) took the span out of the
write watch without running the unwatch hook, so pending storage-image
results over it kept no saved guest bytes and their write-back refused:
storing storage image results pending over memory outside the write
watch without the guest bytes saved before them is not implemented
(#7017, Palworld PPSA23126 among others).

The hook now runs over the block span before the blocks leave the
watch, as Unwatch and the import fallback do, with the tracker lock
released for it like #6308 does for imports. The debt entry drops the
failed collect from the unsaved cases.

The check makes a collect fail over a no-access arena page and requires
the hook to have covered the block; it needs the WindowsMappings
protection failure, so it runs in the Windows-only section of the write
tracking test.
2026-10-19 17:00:48 +02:00
Nithishvelan M 89e1425662 fix(libScePlayGoDialog): return COMMON_DIALOG_ERROR_NOT_FINISHED for uncompleted dialog
Align scePlayGoDialogGetResult unfinished error code with the other common dialog modules across the tree (0x80B80005, COMMON_DIALOG_ERROR_NOT_FINISHED) instead of 0x80ED0005. Update GuestPlayGoDialog test and technical debt entry accordingly.
2026-10-19 16:58:29 +02:00
Nithishvelan M a9264aa7e9 docs(libScePlayGoDialog): record unverified status check and rename test variable 2026-10-19 16:58:29 +02:00
Nithishvelan M 061b9fa426 fix(libScePlayGoDialog): return error for uncompleted dialog in scePlayGoDialogGetResult
Validate that the dialog is in finished state before returning results in scePlayGoDialogGetResult, returning ERROR_INVALID_STATE when called while initialized, and cover this case in GuestPlayGoDialog.
2026-10-19 16:58:29 +02:00
Nicolas Abosch b131d2db5d Merge remote-tracking branch 'origin/main' into perf/gpu-wake-sleeps 2026-10-19 11:58:20 -03:00
Dean Galvin 88f64ec265 x
# Conflicts:
#	docs/dev/debt/libSceAgcDriver.md
2026-10-20 03:54:33 +13:00
Dean Galvin 1d8d67f8d3 x
# Conflicts:
#	docs/dev/debt/libSceAgcDriver.md
2026-10-20 03:54:32 +13:00
Dean Galvin f3751e96ad Merge main into pr-6457
# Conflicts:
#	docs/dev/debt/libSceAgcDriver.md
2026-10-20 03:54:07 +13:00
Dean 00d7e611ef Merge pull request #7363 from plokmklo/fix/relinker-gnu-stack-relro
fix(relinker): synthesise a non-executable PT_GNU_STACK for Linux executables
2026-10-20 03:52:18 +13:00
Dean 7b18fa8d5d Merge pull request #7802 from ionut27001/fix/agc-kept-set-weak-textures
fix(agc): let a kept descriptor set's table record hold its textures weakly
2026-10-20 03:52:02 +13:00
Whitesun123andClaude Opus 5.5 f59fe02b81 fix(libc): reduce extreme localtime_s inputs without overflow
On Windows, localtime_s moves a time outside the host range into it by
subtracting whole 400-year cycles, computed as
cycles * CALENDAR_CYCLE_SECONDS. For times within about 7.2e9 seconds of
INT64_MIN that product overflows int64, which is undefined behaviour:
built with -fsanitize=undefined -fsanitize-trap=all, guest_time_conversion
traps there on its INT64_MIN case.

Take the remainder of the time by the cycle length instead. It is the
same value for every input that did not overflow, so results do not
change, and the extreme inputs still fail the year range check.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-19 16:50:10 +02:00
Adrià c92eb8da1e Merge pull request #6931 from AnthonyClemens/perf/agc-pipelined-indirect-draws
perf(agc): queue CPU-path indirect draws on the draw pipeline
2026-10-19 16:48:13 +02:00
Adrià 73c59b7be6 Merge pull request #6958 from Pipodi/fix/pipeline-cache-save-try-lock
fix(agc): skip a periodic pipeline cache save while a pipeline creation holds the cache
2026-10-19 16:48:06 +02:00
Adrià 8aa454f9a7 Merge pull request #6944 from EagleBearerYS/fix/agc-lookup-log-fits-build
fix(agc): keep a build's own texture lookup records past the log bound
2026-10-19 16:47:59 +02:00
m335671andClaude Opus 5.5 21fb50f1d2 fix(agc): skip null storage images in a dispatch's write ranges
DispatchWriteRanges decoded the T# of every written storage image
element before checking its base address, and DecodeTextureResource
throws on a null base, so a dispatch that writes a null storage image
slot threw instead of contributing no range. On main the
APS5_PIPELINE_DISPATCH item path reaches it.

Check IsNullTextureResource first and skip the element, as
DrawWriteRanges does for draws. The draw write ranges test now also
runs DispatchWriteRanges on its written-plus-null image program.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01PqKN8pgLXDvWRPSucJTLU7
2026-10-19 16:45:15 +02:00
ps54allandClaude Opus 5.5 b0558ce95f feat(shader): model ds_ordered_count swap
A ds_ordered_count with offset1 bit 4 set swaps the first active lane's value into the GDS counter instead of adding it. Emit it as one device-scope atomic exchange through the same path as the ordered add, and return the counter's previous value to every active lane.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-19 16:41:03 +02:00
Tomás Ortellado 87d5e16c10 test(agc): skip invalid Windows vouch probe 2026-10-19 11:38:55 -03:00
Adrià a4440ed938 Merge pull request #6945 from MarcZX10/codex/carry-alarm-range
fix(libkernel): reject alarm seconds beyond the itimer range
2026-10-19 16:38:41 +02:00
Adrià 863486cc32 Merge pull request #6836 from DavidSamir/fix/libkernel-open-file-limit-macos
fix(libkernel): set the open file limit at load on macOS
2026-10-19 16:38:18 +02:00
Nicolas AboschandClaude Opus 5.5 09093bfa26 fix(libkernel): reset the wake event before a wakeable sleep and keep coarse and sub-50 us sleeps as before
A wake set after the previous wait returned left the per-thread
auto-reset event signalled, so the next short sleep returned from its
wait at once and spun to its deadline. With APS5_COARSE_TIMED_WAITS or
a request under 50 us the sleep now takes TimedWait::SleepNanos as on
main.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-19 11:31:17 -03:00
pushkarreddyy 91abb61be6 fix(recompiler): use ActiveMaskImplies in SrtTape and restore debt entry 2026-10-19 20:00:18 +05:30
Nithishvelan M 83189d22b3 fix(libSceLoginDialog): transition to finished on dialog close
Transition dialog status to finished in sceLoginDialogClose, matching the behavior in libSceSigninDialog, and add unit test coverage in GuestLoginDialog.
2026-10-19 16:30:17 +02:00
Nithishvelan M 826f1abafd fix(libSceNpAuthAuthorizedAppDialog): transition to finished on dialog close
Transition dialog status to finished in sceNpAuthAuthorizedAppDialogClose, matching the behavior in libSceSigninDialog, and add unit test coverage in GuestNpAuthAuthorizedAppDialog.
2026-10-19 16:28:38 +02:00
David 63e763f443 Merge remote-tracking branch 'origin/main' into feat/shader-barycentric-tessellation-last-vertex
# Conflicts:
#	docs/dev/debt/shader.md
2026-10-19 18:27:34 +04:00
ntamas94andClaude Opus 5.5 522e67dcf6 test(libSceNet): place the sceNetInetPton whitespace checks before CheckInetPtonEx
#7924 adds its check between CheckInetPtonEx and CheckUsleep, where
these checks were, so the two pull requests conflicted in
GuestSceNet.cpp. The checks now sit after CheckAddressText.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-19 16:24:21 +02:00
thuanquangandClaude Opus 5.5 1ed8eb6d8b fix(shader): sample a 3D T# through DIM 2D_ARRAY as a volume
Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-19 16:19:13 +02:00
Adrià 0037336b63 Merge pull request #6943 from Ondra97/codex/fix-buffer-slab-return-oom
fix(agc): avoid host allocations when returning slab slots
2026-10-19 16:18:51 +02:00
Adrià 4f10164198 Merge pull request #6901 from akkadbakkad89/feat/np-cpp-web-api
feat(libs): restore libSceNpCppWebApi for dumps that ship no copy
2026-10-19 16:18:42 +02:00
mrfelekandClaude Opus 5.5 2234121856 fix(recompiler): fold draw offsets that the shader only reloads after the fetch add
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01BywPXoZACVi8ALV4JKvuPZ
2026-10-19 16:15:55 +02:00
Adrià 3686960c5b Merge pull request #6593 from Ondra97/codex/fix-json-copy-exception-cleanup
fix(json2): release partial copies on allocation failure
2026-10-19 16:15:27 +02:00
ShinMalphur d16086d841 test(net): cover process-relative system time 2026-10-19 20:40:37 +06:30
ShinMalphur e36b6274b6 feat(net): implement process-relative system time 2026-10-19 20:40:01 +06:30
Adrià c4708fa207 Merge pull request #6916 from MarcZX10/codex/carry-tz-6910
fix(libc): honor guest TZ in time conversions
2026-10-19 16:08:10 +02:00
ntamas94andClaude Opus 5.5 be7068bd81 fix(libSceNet): end IPv4 sceNetInetPton text at whitespace as the PS4 does
PS4 firmware 10.71 converts "1.2.3.4" followed by a space, tab, LF,
VT, FF or CR, and anything after it ("1.2.3.4 x"), to 1.2.3.4 and
returns 1, where host inet_pton returns 0. Leading whitespace, other
trailing bytes (0x01, 0xa0), "1.2.3 " and IPv6 text with whitespace
still fail there.

A failed conversion leaves the destination and sceNetErrnoLoc
unchanged on the console; Winsock inet_pton writes the parsed prefix
before failing, so the conversion now goes through a local buffer.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-19 16:05:36 +02:00
Adrià ebb478c055 Merge pull request #6939 from milescoviello/fix/systemservice-psmkit-exports
fix(libSceSystemService): declare the PsmKit local process exports
2026-10-19 16:05:00 +02:00
Adrià 04078b1073 Merge pull request #6927 from jotitadev/fix/relinker-case-only-output-collisions
fix(relinker): detect output aliases with a filesystem probe outside Windows
2026-10-19 15:54:05 +02:00
Gjon Gojcevic deb0ba305f test(agc): render layered draws into 2D array color views
A vertex shader exporting the render target index draws one value per
layer into a CB_COLOR_VIEW of slices 1 to 3 of a four-slice 2D array and
into slices 0 to 2 of a surface of one slice. After the write-back every
slice of guest memory must hold its layer's value, and the slices
outside the view (slice 0, and slice 3 of the one-slice surface) their
initial bytes.

AI-assisted: yes
2026-10-19 15:52:35 +02:00