fix(libc): compute erfl and erfcl with FreeBSD msun's ld80 s_erfl.c #19342
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/19342"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Imported from boykopovar/AnyPS5. Originally posted by AlfaRojo on 2026-11-13T04:42:31Z.
What
erflanderfclreturned the host's results. They now follow FreeBSD msun's ld80s_erfl.c(release/11.4.0) over the msunexpl, including NaN, infinities, the tiny-argument branch that avoids spurious underflow, and the overflow-to-1, underflow-to-0 and2 - tinycut-offs. The unverified console behaviour is recorded indocs/dev/debt/libc.md.This branch is stacked on #18525 (msun
expl), so until that merges the diff also shows its commits. This PR is the two commits after765ca80990:53b4f14658(the port) andd3e19f99fc(one extra test).Tested
Windows 11 Pro 10.0.26200, WinLibs GCC 15.2.0 r7, Release.
Math.cppwith the new tests:Guest erfl failed for 0xc.ccccccccccccccdp-7, then abort.ctest -R '^guest_math'passes 3 of 3 (guest_math,guest_math_elementary,guest_math_exact), three runs.s_erfl.c,s_expl.candk_expl.hcompiled standalone on the host, not from the host libm. The tests cover 49erfland 57erfclinputs on every branch, the exception flags, 53-bit precision anderflleavingFE_UNDERFLOWclear for a tiny argument.libc.prx; the 11.4.0 source is the only evidence.tools/check_conventions.pyagainstmainand against the stacked base: 0 errors (one length warning on an existing debt entry, not mine).erflorerfcl(checked #10226, #18694, #18787, #18792, #19328 and every open libc/math PR).tools/pr_overlap.pylists open PRs that touchdocs/dev/debt/libc.md, and #11266 (exp2l) forMath.cppandGuestMath.cpp.ac6b3c4b4b(merged with upstream/main, which now has #18525 and #19328):guest_math,guest_math_elementaryandguest_math_exact, all three test executables rebuilt, pass in 3/3 runs;check_conventions.py --base upstream/mainreports no errors.Checklist
main; no other open PR implements the same functionsNotImplemented_nid_no_patch); silent stubs are listed under Silent stubs in their library's technical debt file.mdfiles or images added to the repository (attach them to this PR)Imported from boykopovar/AnyPS5. Originally posted by PrivacyOnion on 2026-11-13T04:44:25Z.
Review: CHANGES_REQUESTED
Verified on Linux (Ubuntu 24.04, GCC 13.3, Ninja, Release) against
d3e19f99fc:tools/check_conventions.pypassed;git diff --checkclean.guest_math_testsbuilt cleanly.guest_math,guest_math_elementary,guest_math_exact):Requesting changes for the points above.
Imported from boykopovar/AnyPS5. Originally posted by PrivacyOnion on 2026-11-15T20:23:54Z.
Review: APPROVED
Verified on Linux (Ubuntu 24.04, GCC 13.3, Ninja, Release) against
ac6b3c4b4b:tools/check_conventions.pypassed;git diff --checkclean.guest_math_testsbuilt cleanly.guest_math,guest_math_elementary,guest_math_exact):core/libs/prx/libc/src/Math.cppreverted tomainand the new tests kept, the suite fails: Restoring the change makes it pass again.Looks Good To Me
Imported from boykopovar/AnyPS5. Originally posted by PrivacyOnion on 2026-11-15T20:23:55Z.
Review: APPROVED
Verified on Linux (Ubuntu 24.04, GCC 13.3, Ninja, Release) against
ac6b3c4b4b:tools/check_conventions.pypassed;git diff --checkclean.guest_math_testsbuilt cleanly.guest_math,guest_math_elementary,guest_math_exact):core/libs/prx/libc/src/Math.cppreverted tomainand the new tests kept, the suite fails: Restoring the change makes it pass again.Looks Good To Me