Repository navigation
Conversation
log1pf now runs the whole of FreeBSD's s_log1pf.c for finite inputs above -1 instead of mapping negative inputs to -log1p(-x/(1+x)). Compared with the pinned source over every finite float above -1 it has no differing result bit; the old mapping differed on about 82 million inputs, the first at 0xb3000001.
…duction boundaries The expected bits come from the pinned s_log1pf.c.
log1pf now runs the whole of FreeBSD's s_log1pf.c for finite inputs above -1 instead of mapping negative inputs to -log1p(-x/(1+x)). Compared with the pinned source over every finite float above -1 it has no differing result bit; the old mapping differed on about 82 million inputs, the first at 0xb3000001.
…duction boundaries The expected bits come from the pinned s_log1pf.c.
(cherry picked from commit 87f635c)
(cherry picked from commit 134201f)
log1pf now runs the whole of FreeBSD's s_log1pf.c for finite inputs above -1 instead of mapping negative inputs to -log1p(-x/(1+x)). Compared with the pinned source over every finite float above -1 it has no differing result bit; the old mapping differed on about 82 million inputs, the first at 0xb3000001. (cherry picked from commit ae53b71)
…duction boundaries The expected bits come from the pinned s_log1pf.c. (cherry picked from commit 3fcdc09)
(cherry picked from commit 780fa4b)
…c.prx does (cherry picked from commit 81fa0ec)
# Conflicts: # core/libs/prx/libc/src/Math.cpp
expf follows lib/msun/src/e_expf.c and log1pf follows lib/msun/src/s_log1pf.c, both at release/11.4.0. Add their source line, the float-conversion credit and the Sun notice as those files carry them. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
# Conflicts: # docs/dev/debt/libc.md
# Conflicts: # docs/dev/debt/libc.md
main's boykopovar#21714 set expf's ERANGE in the Math.cpp expf this branch replaces. The branch's msun expf in MathExpf.cpp keeps the console's errno (overflow and the underflows the console reports; guest_math pins those bits), so the Math.cpp definition stays removed. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Other open pull requests touch the same code. Merging one will break the other, or both implement the same thing. If this one builds on them, list them in Depends on.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Current public head
4296b2ca68e85c6efc42e068cea49dcc3d5bd3e9incorporates boykopovar#10113 atf876efc0ef1c529370c6304149e3adb8443e27f4and main atf73d791b3df4dcaa773297a93f5ae2c062ee95a3without rewriting history. The merge retains main's scalar and fusedlogfpaths alongside the error-function implementation. The diff against boykopovar#10113 is five files. The existing 38erffand 38erfcfresult-bit/errno cases now live inGuestErf.cpp, registered independently asguest_erffandguest_erfcf. An expf failure in the broad math suite can no longer hide these focused checks. The entire error-function implementation/helper/licence block is byte-identical to the preceding public head.Implements the older fdlibm
erffanderfcfalgorithms used by the title-bundled references, including their five argument ranges, rational approximations and split inputs to the twoexpfcalls. This removes the host-library dependence of their last result bits and range errors.Earlier public head
ca8a86166e6fed9ca62c5b74b43b090c3afa0560merges the earlier child324fde3a393e4acb1b0c88a0ae1d9799852924f6with canonical boykopovar#10113 head86fc4fc9c2f04da5210c6cf23a69aa2f4eed05ce, without rewriting history. At that earlier head, against its actual parent, this topic changed onlyMath.cpp,GuestMath.cppand the erff/erfcf debt note. The parent'sMathExpf.cpp, compiler options and regression fixture are inherited unchanged.The earlier prerequisite refresh incorporated boykopovar#10113
61549d86c2a61edbd005d9b441748b3d9bd906aaand removed the old inlinedexpfconflict. The child's error-function implementation, helpers and licence were preserved byte-for-byte from5969599111d26ea3015e496655c5ff5f919f6651. Existing public commits and authorship are preserved.The retained
log1pfandexpfchanges are intentional prerequisites from boykopovar#10007 and boykopovar#10113. The current boykopovar#10113 head is an actual ancestor; the evidence includes this PR's topic patch against that parent.Tested
Current public head
4296b2ca68e85c6efc42e068cea49dcc3d5bd3e9passed 8/8 Linux x86-64 Release CTests with zero skips. The suite ranguest_erff,guest_erfcf,guest_expf_environment,guest_math,guest_math_exact,guest_math_elementary,guest_dinkumware_internalsandguest_floating_point. The environment fixture passed all 1,128 checks. Conventions passed on the five-file stacked diff. Exact-head Linux report.Historical test-isolation qualification (2026-11-26): Linux x86-64 / Ryzen 9 7950X / GCC 16.2.1 / Release Ninja, head
f03f9759b5d2bd3c3faea0074c8b9381b6c96996on mainfae9876e971fda0345aa828625389b9f2ffcd487. 7/7 CPU CTests pass, zero skips: the two new independent registrations plusguest_expf_environment,guest_math,guest_math_exact,guest_math_elementary, andguest_floating_point. With the identicalguest_erf_testsexecutable, the exact boykopovar#10113 prerequisite996aaa42e5f8c7d72bf09031e317b2c9e7228bcffails bothguest_erffandguest_erfcfat their respective bit assertions.ldd -r, actual raw-provider initialization paths, unchanged hashes and registration backtraces are verified. Both original case tables and every expected result are retained byte for byte. This is raw-provider CPU validation; no original-module differential, exhaustive-input or new exception-flag comparison is claimed. Reproducer, maintenance patch, logs, pins and hash/loader receipts — 28 payloads, anonymously downloaded and verified; SHA-256149f295aa0ef8cd06ffdbd3cd2e85885cfe7711eeacb18c6d399abb3b6ef9630.Historical Linux qualification before the later parent merge: Arch Linux x86-64, GCC 16.2.1, Release. Full SDK
libs, relinker and all five focused CPU groups pass at4e397fc892882d7705ab91090adb930282227fd3:guest_mathguest_math_exactguest_dinkumware_internalsguest_floating_pointguest_expf_environment(1,128 inherited parent regression checks)Same-fixture negative control: this child's
guest_math_testsexecutable fails with parent-only61549d86c2a61edbd005d9b441748b3d9bd906aaat an addederffbit assertion (line 4715), then passes with the child SDK. The failure line is verified against the actual child-only diff. Both selected raw-library paths are checked withldd, dependencies useLD_BIND_NOW=1, and source/bank hashes remain unchanged. Loader failures do not count as the negative control.Earlier head
324fde3a393e4acb1b0c88a0ae1d9799852924f6adds only the debt-note clarification after that Linux gate. Its completecore/tree, including CMake, is identical to the tested4e397fc89288head. The conventions and merge-tree check against089d2df72e4a019e37dd707a8574a1081e060fffbelong to that earlier qualification; they are not new checks of the current head or today's main.Build/test logs, same-fixture controls, pinned source and ancestry proofs — SHA-256
251da0a6024e203da9c990f3124d2e9c0a21d6e14eea8759108c048ca8288e32, 57 payloads; downloaded and every payload verified. The official function/branch overlap scans and all fifteen pinned manual shared-file comparisons are included. boykopovar#24322 is source splitting, not a separate implementation of these corrections.Earlier exact-public-head Linux CPU qualification: seven tests and the same-fixture prerequisite negative control at
ca8a86166e6fed9ca62c5b74b43b090c3afa0560. Fresh raw libc plus focused tests: 7/7 pass, zero skips; the actual prerequisite with the identical child fixture passes 6/7 and fails the new erff bit assertion. Loader/provider and source hashes are verified, and the reproducible archive is anonymously hash-checked. This supplements the historical full-SDK gate above; it is not a new full patched-SDK build or original-module oracle.Earlier-head Windows qualification is reported in the existing validation comment:
ca8a86166emerged onto main87b7ef3891asbeb7e8bb0c, Windows 11 Enterprise 22621, WinLibs GCC 15.2 UCRT, Release.guest_expf_environment,guest_lgamma_polesandguest_matheach pass in three runs. The same three tests pass three runs on parent-only86fc4fc9c2merged onto that same main asc553316ef1. The comment also reports conventions passing onca8a86166e. These are the existing contributor-reported Windows results, not tests rerun for this description update.The older all-float Windows result/errno measurements are historical and were not rerun after the prerequisite refresh. No fresh native erff/erfcf differential oracle, current-head full patched-SDK build, new macOS, console, GPU or game qualification is claimed here. FMA-contracted title variants can retain different last bits. The parent's larger expf reference matrix is separate evidence, not a rerun claimed for this child. No performance or title-unblock claim.
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)Summary by CodeRabbit
Bug Fixes
Tests
Documentation