Commit Graph
324 Commits
Author SHA1 Message Date
JJenkx 5b9155a418 Merge remote-tracking branch 'origin/main' into windows/libc-asin-acos-msun
# Conflicts:
#	core/libs/tests/GuestMath.cpp
2026-11-05 07:01:11 -05:00
Dean a7df91e4ba Merge pull request #10325 from JJenkx/windows/libc-hypot-msun
fix(libc): compute hypot with FreeBSD msun's algorithm, as titles' libc.prx does
2026-11-06 00:03:55 +13:00
JJenkx 65ff7f781d Merge remote-tracking branch 'origin/main' into windows/libc-asin-acos-msun
# Conflicts:
#	core/libs/tests/GuestMath.cpp
2026-11-04 23:30:25 -05:00
JJenkx b7fce16e8c Merge remote-tracking branch 'origin/main' into windows/libc-asin-acos-msun
# Conflicts:
#	core/libs/tests/GuestMath.cpp
2026-11-04 20:11:24 -05:00
JJenkx a0b58797d8 Merge remote-tracking branch 'origin/main' into windows/libc-cosh-msun
# Conflicts:
#	core/libs/tests/GuestMath.cpp
2026-11-04 20:10:46 -05:00
Dean 88bcfc7a7b Merge pull request #12366 from JJenkx/windows/libc-fdim-invalid
fix(libc): raise FE_INVALID from fdim and fdimf for equal infinities
2026-11-05 13:18:44 +13:00
Dean GalvinandJJenkx 6047b26a6e test(libc): restore the sin/cos/tan console-bit checks dropped by the main merge
The merge commit 1ccf0b9526 removed CheckTrigConsoleBits and its call from
GuestMath.cpp, so this branch carried the sin, cos and tan implementation
from #10250 but no longer tested it. The function and its call are restored
verbatim from the commit that added them (4d98e8148f by JJenkx); nothing
else changes.

Fix-up on the author's branch, credited to JJenkx.

Co-Authored-By: JJenkx <[email protected]>
2026-11-05 08:06:22 +13:00
JJenkx 3135ae2586 test(libc): retain merged asin conformance expectations 2026-11-04 13:44:33 -05:00
JJenkx 1ccf0b9526 chore(libc): merge main and preserve numeric regressions 2026-11-04 13:32:27 -05:00
JJenkxandClaude Opus 5.5 7080ae351b Merge main 9ab6a281ea into the hypot branch
Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-11-04 13:26:22 -05:00
Dean ee42ed3c17 Merge pull request #10265 from JJenkx/windows/libc-pow-fdlibm
fix(libc): compute pow with fdlibm's algorithm, as titles' libc.prx does
2026-11-05 06:34:47 +13:00
JJenkx c5d31ec4d7 chore(libc): integrate current main regressions 2026-11-04 10:14:26 -05:00
Dean cecb4b205b Merge pull request #11632 from AlexFigas/fix/libc-cbrtl-msun-ld80
fix(libc): compute cbrtl with FreeBSD msun's ld80 code as the bundled libc.prx does
2026-11-04 17:49:26 +13:00
Dean eecbc4f185 Merge pull request #10349 from JJenkx/windows/libc-remainder-fprem1
fix(libc): compute remainder and remquo with fprem1, as titles' libc.prx does
2026-11-04 17:48:30 +13:00
Dean 19a34af158 Merge pull request #9873 from JJenkx/windows/libc-log10f-log2f-msun
fix(libc): compute log10f and log2f with FreeBSD msun 9.0's algorithms, as titles' libc.prx does
2026-11-04 16:58:47 +13:00
JJenkx 598429f215 test(libc): retain one merged exp regression fixture 2026-11-03 08:19:54 -05:00
JJenkx 89e5c25586 chore(libc): integrate current main math regressions 2026-11-03 08:08:29 -05:00
JJenkx ddd5928f09 chore(libc): integrate current main math regressions 2026-11-03 08:08:28 -05:00
JJenkx 9079b1e8c3 chore(libc): integrate current main math regressions 2026-11-03 08:08:18 -05:00
JJenkx 3bf30fd492 chore(libc): integrate current main math regressions 2026-11-03 08:08:15 -05:00
JJenkxandClaude Opus 5.5 f1bd618376 Merge main into windows/libc-fdim-invalid
Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-11-03 04:13:43 -05:00
JJenkxandClaude Opus 5.5 2c8a5d59f8 chore: merge main into the exp topic
Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-11-02 18:24:28 -05:00
Alexandre Figueiredo b2a99b137f Merge upstream main into fix/libc-cbrtl-msun-ld80 2026-11-02 19:40:39 +00:00
JJenkxandClaude Opus 5.5 0d0d95368d fix(libc): compute hypot with FreeBSD msun's algorithm, as titles' libc.prx does
hypot returned the host's hypot after an infinity check, so its last bit
and its NaN payloads depended on the host. The titles' copy is FreeBSD
msun's e_hypot.c, which sets no errno even on overflow; hypot now
computes that algorithm.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-11-02 12:52:55 -05:00
JJenkx 2181a5edab chore(libc): retain current prerequisite #10250 ancestry 2026-11-02 12:50:14 -05:00
JJenkx 4947eef356 chore(libc): integrate current main math implementations 2026-11-02 12:46:53 -05:00
JJenkx e02f1f640e fix(libc): integrate current math ports with measured cosh 2026-11-02 12:46:31 -05:00
JJenkx f7a1526101 chore(libc): integrate current main math regressions 2026-11-02 12:46:26 -05:00
JJenkx 1c4650937d chore(libc): integrate current main math regressions 2026-11-02 12:46:25 -05:00
JJenkx 904fbdca7e chore(libc): integrate current main math regressions 2026-11-02 12:46:22 -05:00
Dean f133e5e326 Merge pull request #11892 from JJenkx/windows/libc-wcstod-subnormal-erange
fix(libc): set ERANGE for decimal subnormals in wcstod as strtod does
2026-11-03 01:28:05 +13:00
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 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 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 Galvin 56b4b3d020 Merge commit '88e804b0a7df1f1ac373a9e2f72fb378d925fdd4' into HEAD
# Conflicts:
#	core/libs/prx/libc/src/Math.cpp
2026-11-02 21:17:24 +13:00
Dean Galvin d68b404d4a Merge commit '88e804b0a7df1f1ac373a9e2f72fb378d925fdd4' into HEAD
# Conflicts:
#	core/libs/prx/libc/src/Math.cpp
#	core/libs/tests/GuestMath.cpp
#	docs/dev/debt/libc.md
2026-11-02 21:06:56 +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
JJenkxandClaude Opus 5.5 3ae4cd1429 fix(libc): compute remainder and remquo with fprem1, as titles' libc.prx does
remainder, remainderf, remquo and remquof returned the host's functions.
The titles' copies are FreeBSD's amd64 e_remainder.S and s_remquo.S: an
x87 fprem1 loop whose remquo quotient is the sign and the three low bits
from C0, C3 and C1, and whose NaN results follow x87 NaN selection. Sony's
wrapper sets EDOM for a zero divisor or an infinite dividend when neither
argument is a NaN. All four now run that loop and set that errno.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-11-01 20:17:52 -05:00
Alexandre Figueiredo 5ab9b2926a Merge upstream main into fix/libc-cbrtl-msun-ld80 2026-11-01 20:16:42 +00: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 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
Alexandre Figueiredo 02c58684e5 Merge upstream main into fix/libc-cbrtl-msun-ld80 2026-11-01 00:16:16 +00:00
JJenkx 5abea905c2 test(libc): pin cosh at positive and negative one 2026-10-31 17:30:37 -04:00
JJenkxandClaude Opus 5.5 af2d1f35e3 fix(libc): compute exp with FreeBSD msun's algorithm, as titles' libc.prx does
exp returned the host's exp, whose last bit differs from the titles' copy on
Windows on 9,892,285 of 320 million random arguments. The titles' copy is
FreeBSD msun's e_exp.c, except that exp(1) returns the correctly rounded e,
and it sets ERANGE only in msun's overflow and underflow branches. exp now
computes that and sets ERANGE there.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-31 10:24:02 -04:00
Qu Yi 4c41442276 fix(libc): match nearbyint inexact flags to guest libc 2026-10-31 15:51:17 +08:00
Oscar45397andClaude Opus 5.5 66f151fd7d test(libc): cover remainderf
Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-30 18:35:56 +01:00
JJenkx 250f5b51de fix(libc): integrate expm1f on refreshed tanhf parent 2026-10-30 07:33:46 -04:00
JJenkx a06ed844e3 fix(libc): integrate current main into tanhf port 2026-10-30 07:32:57 -04:00
Alexandre Figueiredo 554c60b29f Merge upstream main into fix/libc-cbrtl-msun-ld80 2026-10-30 08:39:26 +00:00