Commit Graph
859 Commits
Author SHA1 Message Date
Dean Galvin 6ea7d0ee1c Merge commit '3c3b3cda739f9eb00a07fae50d94a3af5f6fb8f2' into HEAD
# Conflicts:
#	core/libs/prx/libc/src/Math.cpp
2026-11-02 23:35:08 +13:00
Dean 95175b5acf Merge pull request #11298 from Gruzzberry/fix/dangling-link-prefix-enoent
fix(libkernel): fail with ENOENT for a path below a dangling Windows symbolic link
2026-11-02 23:27:36 +13:00
Dean 57cfda019b Merge pull request #11214 from orezraey/fix/libc-wide-lp-measured-ps5
fix(libc): print %lp in the wide formatter as measured on a PS5
2026-11-02 23:27:08 +13:00
Dean 0f0452e319 Merge pull request #11077 from JJenkx/fix/libc-frexp-floating-environment
fix(libc): preserve frexp decomposition and exception behavior
2026-11-02 23:26:47 +13:00
Dean ce49d532f3 Merge pull request #10989 from edubox/feat/libc-sce-v2-filesystem
feat(libc): export the versioned std::__sce_v2 filesystem primitives
2026-11-02 23:26:31 +13:00
Dean 5c3e446c0b Merge pull request #10317 from JJenkx/windows/libc-log2-fdlibm
fix(libc): compute log2 with fdlibm's algorithm, as titles' libc.prx does
2026-11-02 23:25:45 +13:00
Dean ed08af6a2f Merge pull request #10953 from AZLisme/feat/batch2-libc-legacy-signals
fix(libSceLibcInternal): export sigvec through shared runtime
2026-11-02 23:25:28 +13:00
Dean 16bc34bfc8 Merge pull request #10620 from Retr0G28/fix/freopen-random-device
fix(libc): reopen a stream onto /dev/random or /dev/urandom with freopen
2026-11-02 23:23:29 +13:00
Dean 87524eb88e Merge pull request #10615 from edubox/feat/libc-cnd-at-thread-exit
feat(libc): register conditions for broadcast at thread exit
2026-11-02 23:23:18 +13:00
Dean 978a8ffb32 Merge pull request #10324 from MarrasFederico/feat/libc-fwide
feat(libc): track stream orientation and implement fwide
2026-11-02 23:22:33 +13:00
Dean Galvin 56b4b3d020 Merge commit '88e804b0a7df1f1ac373a9e2f72fb378d925fdd4' into HEAD
# Conflicts:
#	core/libs/prx/libc/src/Math.cpp
2026-11-02 21:17:24 +13:00
Dean 67a7602c33 Merge pull request #10247 from JJenkx/windows/libc-log10-msun
fix(libc): compute log10 with fdlibm's algorithm, as titles' libc.prx does
2026-11-02 21:00:20 +13:00
Dean 2aee0b06f6 Merge pull request #10229 from JJenkx/windows/libc-atan-atan2-msun
fix(libc): compute atan and atan2 with FreeBSD msun's algorithm, as titles' libc.prx does
2026-11-02 21:00:13 +13:00
Dean 30f2122781 Merge pull request #9953 from JJenkx/windows/wprintf-narrow-utf8
fix(libc): decode a wide printf %s as titles' libc.prx does, failing on invalid UTF-8
2026-11-02 20:59:39 +13:00
Dean c84005ee40 Merge pull request #9688 from JJenkx/windows/libc-qsort-console
fix(libc): sort like the console's qsort and qsort_s
2026-11-02 20:58:08 +13:00
Dean 25aeb9fa48 Merge pull request #12586 from voidlakhan/feat/libc-timingsafe-bcmp
feat(libc): implement timingsafe_bcmp
2026-11-02 20:54:59 +13:00
Dean 307dd57e50 Merge pull request #10729 from dwk001/fix/libc-wstoul-invalid-base
fix(libc): reject an invalid _WStoul base like Dinkumware instead of …
2026-11-02 20:54:37 +13:00
Dean 6d0fc32dea Merge pull request #8397 from hypermoist/feat/libc-dinkumware-float-bits
feat(libc): add Dinkumware float bit helpers from firmware
2026-11-02 13:43:07 +13:00
Dean c50acd1fc4 Merge pull request #10895 from StoneDC/fix/wcsftime-partial-output
fix(libc): preserve partial wcsftime output on overflow
2026-11-02 10:56:58 +13:00
orezraeyandClaude Opus 5.5 246110e525 docs(libc): keep the %p debt entry within the length limit
Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-11-01 17:31:20 -03:00
orezraeyandClaude Opus 5.5 813cbd96bb test(libc): check %lp through snwprintf_s
Since #11893 the plain wide forms drop the length on %p before the
branch this PR changes, so only the secure forms reach it. Check %lp
through snwprintf_s, which returns -1 without the change, and record in
the debt entry that no secure form was run with %lp on a console.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-11-01 17:30:49 -03:00
Dean b2620e56d1 Merge pull request #11733 from verusferro/feat/libc-wide-string-to-number
feat(libc): convert wide strings with _WStoull, _WStoll, _WStod, _WStof and _WStold as the console's libc does
2026-11-02 00:33:30 +13:00
Eduardo Ruiz 72775e627b docs(libc): keep a single versioned filesystem debt entry 2026-11-01 11:52:09 +01:00
Eduardo Ruiz 497e4a960e fix(libc): return guest errors for invalid versioned stat paths 2026-11-01 11:51:49 +01:00
Eduardo Ruiz 9e4e43d7b2 fix(libc): stat app0.zar entries in the versioned filesystem 2026-11-01 11:51:49 +01:00
Eduardo Ruiz c20d797450 feat(libc): export the versioned std::__sce_v2 filesystem primitives 2026-11-01 11:51:49 +01:00
Adrià a644edf30c Merge pull request #13499 from Gonic0/feat/agc-label-read-trap
perf(agc): trap CPU reads of label readbacks on macOS instead of storing them
2026-11-01 11:09:34 +01:00
AZLisme e7725d7111 feat(libc): implement shared legacy sigvec support 2026-11-01 17:21:10 +08:00
Adrià 26fa1212b8 Merge pull request #13819 from Ninot1Quyi/fix/libc-nearbyint-inexact
fix(libc): match nearbyint inexact flags to guest libc
2026-11-01 09:56:57 +01:00
Adrià 5c9837bfe7 Merge pull request #13442 from Gonic0/feat/libc-write-watch-read-trap
feat(libc): trap guest reads of write-watched pages on macOS
2026-11-01 09:13:34 +01:00
Dean Galvin c08fe413f8 Merge main into feat/libc-timingsafe-bcmp
# Conflicts:
#	docs/dev/debt/libc.md
2026-11-01 21:13:14 +13:00
Dean Galvin 21556548c4 Merge main into fix/libc-wstoul-invalid-base
# Conflicts:
#	docs/dev/debt/libc.md
2026-11-01 21:09:31 +13:00
Adrià 53fbe59956 Merge pull request #13732 from SnekPolylepis/feat/libc-radix64-conversions
feat(libc): implement a64l, l64a, and l64a_r radix-64 integer conversions
2026-11-01 08:30:07 +01:00
Qu Yi 4a65ddf97c chore(libc): synchronize nearbyint fix with main
Preserve the nearbyint implementation and regression coverage while incorporating current main. The write-watch registration prerequisite is now part of main.

Validation: freshly compiled production MathExact.cpp regression passes; ASan/UBSan passes with detect_leaks=0. The same fixture compiles against main Math.cpp and fails at the FE_INEXACT assertion (exit 134). Conventions, whitespace and 235 script registrations pass. Full product build and full CTest were not rerun for this synchronization.
2026-11-01 14:56:40 +08:00
Dean 0b2c52e9c2 Merge pull request #12597 from JJenkx/windows/libc-fopen-s-constraints
fix(libc): report fopen_s and freopen_s argument errors to the constraint handler
2026-11-01 19:48:43 +13:00
Nicolas GonzalezandClaude Opus 5.5 2cf5b41ec8 perf(agc): trap CPU reads of label readbacks on macOS instead of storing them
Before a label, a pending linear or small storage image that shares no page
with another pending or storing image now gets a write-watch read trap
instead of its store. The first access to its pages stores it through the
host-read hook; any other store releases the trap first.
APS5_NO_LABEL_READ_TRAP=1 keeps the store at the label.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-11-01 03:37:51 -03:00
Nicolas GonzalezandClaude Opus 5.5 6b16f90d5a feat(libc): trap guest reads of write-watched pages on macOS
GuestWriteWatchTrapReads takes all access to the pages of a range until
the resolver set with GuestWriteWatchSetReadTrapResolver has run for it.
A fault on a trapped page waits while the resolver runs on the watch's
own thread; host writes and GuestWriteWatchProtect run it first on the
calling thread. Collections keep trapped pages inaccessible, and
registering or unregistering memory drops its traps.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-11-01 07:33:02 +01:00
Dean 803889adab Merge pull request #8937 from UnhealthyKraken/feat/libc-fesetenv
feat(libc): implement fesetenv
2026-11-01 19:16:41 +13:00
Dean Galvin 7b52262718 Merge main into feat/libc-fwide 2026-11-01 18:45:39 +13:00
SnekPolylepisandClaude Opus 5.5 23bff0dd7d fix(libc): match FreeBSD a64l and l64a_r, use HostThreadLocal for l64a
Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-11-01 00:18:47 -05:00
Nicolas GonzalezandClaude Opus 5.5 132bceac18 Merge remote-tracking branch 'upstream/main' into perf/libc-write-watch-fault-ahead
Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-11-01 00:49:29 -03:00
Dean 88b7503129 Merge pull request #10222 from JJenkx/windows/libc-expm1f-msun
fix(libc): compute expm1f with FreeBSD msun's algorithm, as titles' libc.prx does
2026-11-01 14:57:48 +13:00
GruzzberryandClaude Sonnet 5.5 bfef134a9a fix(libkernel): fail with ENOENT for a path below a dangling Windows symbolic link
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
2026-10-31 10:16:00 +00:00
Qu Yi 4c41442276 fix(libc): match nearbyint inexact flags to guest libc 2026-10-31 15:51:17 +08:00
Nicolas GonzalezandClaude Opus 5.5 2c15fa59b4 fix(libc): keep write-watch fault-ahead inside the faulting page's 64 KiB block
libSceAgcDriver decides per 64 KiB block whether a pending storage image
keeps the CPU's bytes. A window that ran into the next block marked it
CPU-written and dropped the GPU results there (agc_storage_write_back,
agc_idle_publish_wait, array layer and depth plane tests).

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-31 02:32:46 -03:00
Zain 02bcf26141 feat(libc): implement a64l, l64a, and l64a_r radix-64 integer conversions 2026-10-30 21:54:02 -05:00
Nicolas GonzalezandClaude Opus 5.5 54080056ff perf(libc): unprotect the pages ahead of a sequential write fault on macOS
A guest thread that writes a large watched range in order takes one
write-watch fault per page. Under Rosetta 2 each fault is a Mach
exception round trip. When the two pages before the faulting one were
written since the last collection, the handler now unprotects up to 32
pages from it that have the same protection and records them as
written. APS5_WRITE_WATCH_FAULT_AHEAD sets the count; 0 or 1 keeps one
page per fault.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-30 23:13:12 -03:00
Retr0 9586a81211 Merge remote-tracking branch 'origin/main' into fix/freopen-random-device
# Conflicts:
#	docs/dev/debt/libc.md
2026-10-31 02:12:35 +02:00
Adrià 21a556f567 Merge pull request #12553 from JJenkx/codex/libc-unscaled-hex-parser-20261028
fix(libc): match unscaled hexadecimal Dinkumware conversion
2026-10-30 21:24:48 +01:00
Adrià 91cd8ac6fd Merge pull request #13049 from JJenkx/fix/libc-character-scan-lengths
fix(libc): ignore non-wide lengths on character scans
2026-10-30 16:25:56 +01:00