fix(libc): set EDOM in fmod and fmodf where titles' libc.prx does #10345

Merged
JJenkx merged 9 commits from upstream-pr/10345 into main 2026-11-05 20:53:51 +00:00
JJenkx commented 2026-10-23 18:30:11 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by JJenkx on 2026-10-23T18:30:11Z.


What

fmod and fmodf save and restore errno around the host call. #3600 did that for fmod and #9643 for fmodf, both following FreeBSD msun, which never stores errno. #9643's debt entry records that the console's errno was not measured. Measured now, the libc.prx that titles ship sets EDOM exactly where msun's e_fmod.c and e_fmodf.c return (x*y)/(x*y):

  • a zero divisor of either sign;
  • an infinite or NaN dividend;
  • a NaN divisor.

For example, fmod(1, 0) returns 0xfff8000000000000 with EDOM there, fmod(NaN, 2) returns that NaN with EDOM, and fmod(1, inf) returns 1 without errno.

The NaN on that path also differs from the host's:

  • a NaN divisor is returned quieted, even when the dividend is a NaN too;
  • otherwise a NaN dividend is returned quieted;
  • otherwise (zero divisor, infinite dividend) the result is the default NaN (x*y)/(x*y).

UCRT returns the dividend's NaN when both are NaNs, so the host's result differs on 19 of the 4,000,256 double pairs tested below and on 344 of the float ones.

Both functions now take that path themselves and set EDOM; every other argument still goes to the host std::fmod with errno preserved, whose finite results are exact.

Tested

Current integration — 2026-11-05. Head 3661c5c59cd9e96ac38af4f1c2926277aae6ecf9 includes pinned main 6d173c1a19788ff69d43b3d0ca62833e312ef939 and retains the previous public history, notices, main math implementations and actual prerequisites.

Linux x86-64 Release, GCC 16.2.1: rebuilt libc and the three math executables; guest_math, guest_math_exact and guest_dinkumware_internals each pass 3/3 (9 passes, zero skips). The same groups pass 3/3 on pinned main. Source/parent/macro/notice checks and conventions pass. All 34 recursive provider trees / 31,551 tracked blobs verify before and after the gate; QuickJS test262 is excluded as declared update=none test data.

Shared main blocker: public_headers fails on this head and pinned main for the same five missing WKSecurityOrigin declarations. PR #16010 restores them separately; a maintainer needs to merge that fix and rerun required checks. This math branch does not contain the unrelated WebKit patch. Header audits and all required CI are not claimed green.

The older Windows compile failure in DepthSurface.cpp was a shared main API mismatch, fixed upstream by merged PR #15855, already included in this head. Its own hosted Windows compile job passed; this is not a fresh Windows qualification of this math head.

Immutable source/audit/log/JUnit/hash and exact-lease push evidence, SHA-256 ef9e085442553c0fce1a4a6ce15781e4e890dc001a3424e1ef972f9b769f3065 (download and member hashes verified). Earlier dated platform/negative/reference reports retain their original source pins. No new Windows, console/SDK-module, GPU/title, exhaustive or performance result. AI-assisted: yes, Codex Sol6.1 medium.

All earlier qualification text below is historical and retains its recorded source/platform pins, including earlier linear/no-merge descriptions.

Current-main refresh — 2026-11-04. Head 1b44472417e479a90ea28bd3bbc6f089ad994acd merges main 9ab6a281ea61c9e62a7eb07eb4cef8f19ede1c5c while retaining the prior public head as an ancestor. Main’s newer code, regression fixtures and debt entries are preserved alongside this topic.

Linux x86-64, GCC16.2.1, Ninja Release: actual libc, libkernel and libSceAmpr CMake owners rebuilt coherently. guest_math, guest_math_exact, guest_dinkumware_internals each pass three consecutive runs (9 passes, zero skips). The same groups pass three times on pinned main. Public-header audit and conventions pass. Original licence-notice trailing whitespace is retained where present. The scoped recipe reuses frozen ZArchive/zstd providers; this is not a whole-project build. No new Windows, bundled-SDK, physical-console, title/GPU or FPS measurement is claimed; earlier reports retain their original pins.

Exact source/parent proofs, per-branch patches/input manifests, build and CTest logs/JUnit, library/executable hashes and scoped CMake recipe, SHA-256 97a2377bc996be1690e8853e1ea090a98b5ed808bcc37a15a5cdada5c2e00845 (download verified). AI-assisted: yes (Codex).

Current-main integration — 2026-11-03. Head b59beb9b4d1b457548fc811bd0a5adb17194903b includes main 4f41f4c375f5abb487dbd184fbc150f31994d762 and retains the prior public history and attribution/licence notices. Main’s newer math implementations and fixtures remain alongside this topic.

Linux x86-64 Release, GCC 16.2.1, Ninja, BUILD_TESTING=ON: rebuilt actual libc and math executables. guest_math, guest_math_exact, and guest_dinkumware_internals each pass 3/3 (9 passes, zero skips); public_headers and conventions pass. The same three groups pass 3/3 plus headers on pinned main. All 34 recursive dependency trees and 31,551 tracked blobs verify with zero errors; the update=none QuickJS test262 corpus is excluded from these library inputs. git diff --check reports the preserved verbatim licence trailing-space line; no other whitespace warnings occur.

Source/parent/gitlink proofs, exact library/test hashes, raw logs/JUnit, and head-leased push receipts: qualification archive, SHA-256 e6a50522bc28e30871fdc2c12a88d2537515914239e8166f6237f48895126a06 (download verified). Older platform/reference reports retain their original pins; no new Windows/macOS, SDK-module, console, title/GPU or performance claim. AI-assisted: yes (Codex).

Earlier dated qualifications below retain their recorded source/platform pins.

Current-main integration (2026-11-02): 9a1276994094707acc4b1c1f1ecbc7cdd873a07c includes main a4eca2a056bf3bbbec98ab42e9d28163e4ea9cb8 and retains the existing public commits. Conflicts preserve main’s math implementations, regression checks and debt entries alongside this topic. Linux x86-64 Release, GCC 16.2.1: rebuilt libc and the three math executables; guest_math, guest_math_exact and guest_dinkumware_internals each pass three times (9 passes, zero skips), and public_headers passes. The same baseline groups pass on main; conventions and whitespace pass. Source and dependency blobs, executable/library hashes, raw logs and JUnit are retained. This refresh adds no new console, Windows, title, GPU or numerical-reference measurement. Qualification evidence, SHA-256 22866bd2a060ba69cd4387d471605afe20ed644e3257174b2d1488635f8c9b52 (download verified).

Current-main conflict refresh, 2026-10-27 UTC: exact head 8b4b0ecdfc2fbdb9ae3f10ec929d627cb942fed9 on tested main 74acfad65b3f0fd4eab653f3a3989d298fba1157. Resolved overlapping test/debt context while preserving this branch's authored production/test edits and main's nextafter environment implementation and coverage. Existing prerequisite commits remain in their original series order.

Linux focused rebuild of libc and selected test executables passes guest_math, guest_math_exact, guest_dinkumware_internals, and public_headers, each three times: 12 passes, zero skips. Conventions and whitespace checks pass. Final fetched main cb45ae2ddf6e113a4619e8fed91fe7b9333c5c0f merges cleanly; its later change is an unrelated Windows crash-test pattern, and the executed qualification remains pinned to the stated base. No new Windows, console, GPU, title, full-suite or negative-control run is claimed. Earlier reference/Windows evidence keeps its original pins.

Exact pins, branch patches, preservation proofs, build/test logs, JUnit and lease-push receipts for this refresh batch. SHA-256: e33f98cc467f038af662cc5fa491c3acc1806bb47171cf77b748f0d4d052c1f2; downloaded copy verified.

Latest conflict refresh (2026-10-26): exact head 11d52c9a9f5cdce272b71217031fac5f397bf997 on main bf77a9e9cba4b02c358779b35295176dd9cae164. The conflict was in adjacent debt notes; the production implementations and regression checks are preserved. Main's unrelated _LCosh/_LSinh debt is retained.

Rebuilt libc and the focused test executables on Linux. guest_math, guest_math_exact, guest_dinkumware_internals, and public_headers pass: four groups × three repetitions (12 passes), zero skips. Conventions, whitespace and final main merge checks pass; the source tree is clean. This is a mechanical refresh with a debt-note resolution, so no new console, Windows, title, GPU or negative-control run is claimed. Earlier measurements retain their original exact pins.

Patch/preservation checks, exact pins, build/test logs, JUnit and push receipts. SHA-256: 196fbf4f07b96515f278558ca31d139759c24195adfd35ddebc93f03c186c92b; downloaded copy verified.

Current Linux rebase: 7385e2d9b96eac4c193f74c48cfa5a9a021f0540, one topic commit on main 16ff208dc32cf3927ba1bae492eee363a5ae7ae8, without merge commits. Production and regression function bodies are unchanged from 025a0c21203773de7ae94365aedaffd53beeceec; main's merged log1p implementation, regressions and calls remain intact. Additive regression insertions were retained on both sides.

Fresh Linux x86-64 Release: guest_math, guest_math_exact, guest_dinkumware_internals and public_headers each pass three repeats before and after the production-only main-Math negative control. The negative fails as expected while exact-math/Dinkumware controls pass; restored libc is byte-identical. Conventions and whitespace pass. The Release negative aborts without a named assertion; no more specific failure attribution is claimed.

Fresh exact-head logs, negative/restoration evidence and preservation proof (SHA-256 fba4546fd2ffc5ea33459b5cc498adc8d2844b835d01d33e301b09d530c93087). No new Windows/macOS, title/module matrix or performance result is claimed. Earlier independent reports below retain their original measured revisions.

Previous qualification (historical source pins)

Historical Linux refresh: head 025a0c21203773de7ae94365aedaffd53beeceec, one commit on main 50a4f824fc3ee23177d8e1effbe306e50150187f (no merge commits). Original fmod/fmodf function bodies and CheckFmodConsoleBits are byte-identical; main's expm1 test/function call and other debt entries are retained. The obsolete standalone fmodf debt entry remains removed as reviewed.

Linux 7.2.9 / Ryzen 9 7950X / GCC 16.2.1 / Release: fresh independent libc/math build; guest_math and guest_dinkumware_internals each pass three runs. With only production Math.cpp reverted to this main and the fixture retained, guest_math aborts; restoring the fix gives six passing invocations and the same libc library SHA-256 413501dad82cc3f36177cc0b5e0eb8727289232d67f778a33aef3293acaeae32. No named assertion is emitted by this Release negative control. Conventions and whitespace pass. Windows remains user-paused: the comparison below is historical and has not been rerun on this head.

Exact-head Linux build/test/negative-control receipts, SHA-256 81e2804b8c970b7a9605a8951dd685aeb1525c2976e4e9ac9713cf0ee166301c.

Hosted Build 40151994198 completed successfully on this exact head, including Linux, Windows and both macOS relinker builds. These relinker jobs do not run the libc math regressions; full platform math claims remain scoped to the evidence above/below.

Historical Windows evidence (original implementation):
Windows 11 Enterprise 10.0.22621, Ryzen 9 5950X, WinLibs GCC 15.2.0 UCRT r7, Ninja, Release, BUILD_TESTING=ON, main 65ac1d3b50.

  • Comparison: a scratch loader runs the decrypted libc.prx of eleven titles natively and supplies __error: PPSA04158, PPSA05916, PPSA07923, PPSA09614, PPSA13934, PPSA20423, PPSA25636, PPSA26528, PPSA33655, PPSA34008 and PPSA35169. It compared their fmod and fmodf with this PR's code on 4,000,256 pairs per title:

    • every pair of 16 special values (±0, subnormals, ±1, 2, DBL_MAX, ±inf, signalling and quiet NaNs of both signs);
    • 4 million random pairs, half random bit patterns and half with the divisor's exponent up to 80 below the dividend's;
    • the float check uses the high 32 bits of each pair.

    All eleven give identical bits and errno for both functions on all of them. EDOM is set on 3,118 of the double pairs and 23,617 of the float pairs. A separate 76-row edge probe (remainder, fmod, remquo, logb, ilogb and nextafter, double and float) prints byte-identical output on all eleven.

  • guest_math: the new CheckFmodConsoleBits has 15 double and 15 float cases with the console's results and errno. They cover each error class with NaN payloads in both positions, a signalling NaN in each position, an infinite divisor, ±0 over ±0, subnormals, and ordinary remainders.

  • Changed tests:

    • CheckFmodErrno (#3600) now expects EDOM from fmod(1, 0).
    • #9643's fmodf table now expects EDOM for its NaN-result rows and the untouched sentinel for the others. Its environment check now expects EDOM after fmodf(1, 0).

    Their result, FE_INVALID and environment expectations are unchanged and pass. cc @CouchRiv @Noxy-HNR

  • guest_math, guest_floating_point and guest_dinkumware_internals pass in three runs out of three on the exact head.

  • Negative control: with main's Math.cpp and these tests, guest_math aborts, while the other two still pass.

  • A standalone -O0 and -O3 build of the new code with the new vectors, #9643's fmodf table and its environment check passes.

  • python tools/check_conventions.py --base origin/main and git diff --check pass.

  • Not tested: Linux and macOS (the error path no longer depends on the host; finite results come from the host's exact fmod), a console, the exception flags against the console, and fmodl.

Independent macOS integration evidence

imellag reports Apple M4 Pro, macOS27.0.1, x86-64 under Rosetta2, using main 61fc572cee plus open macOS build changes. Without this PR, four fmodf domain cases return NaN without FE_INVALID, and guest_math fails at the reported (1,0) case. With this PR's domain expression, plus #9668 and the denormal-operand test adjustment #10907, the reporter gets three passing guest_math runs; omitting this PR restores the failure. The comment does not give this PR's exact tested head, so this is attributed integration evidence, not a new exact-head or title run by us.

Current Linux qualification (2026-10-28)

Rebased onto main 2227f1366188cda5699dd20e2e756a18006a5d4b. Linux CPU validation on 2026-10-28 at 760f4f9386287b626560c16bcbe7363936741872 (Arch Linux 7.2.9, AMD Ryzen 9 7950X, GCC 16.2.1, Ninja Release, BUILD_TESTING=ON).

libc, guest_math_tests and guest_math_exact_tests rebuilt from this exact source. guest_math and guest_math_exact each passed three consecutive runs (6/6, no skips); the same two suites each passed three runs on the pinned main (6/6). Conventions and whitespace checks pass.

Exact source pins, preservation proofs, dependency checks, build logs and JUnit, SHA-256 1176269c9e6948b5252a5db9e660978d7f978fb2d9f4ed6c68bc050b10b5ae68. This is focused Linux CPU qualification; earlier Windows/title/reference measurements retain their original pins. No new title or performance result is claimed.

Current Linux qualification — 2026-10-29

Refreshed against main 5454cd2e455994d992aca39335ce60507eeda1eb.

Linux qualification at 5b596a5d104db3f81d0241afa562fb8726f0c944 (Arch Linux 7.2.9, Ryzen 9 7950X, GCC 16.2.1, Ninja Release, BUILD_TESTING=ON): guest_math, guest_math_exact, guest_dinkumware_internals each pass three consecutive runs (9/9, no skips). The public_headers audit passes at this exact head. All tracked public-header files match the pinned main; the affected test targets rebuild against those headers. Conventions and whitespace checks pass. The same focused groups passed three times on the pinned main.

Evidence: immutable Linux qualification bundle. Its SHA-256 is 53b095da2f67f55b8aa56ba273681e0330fb39739be844458038dde410fb8cc4. No fresh Windows runtime execution is claimed; older measurements retain their recorded source pins.

AI-assisted: yes (Codex).

Additional main-conflict refresh — 2026-10-30

Refreshed to 6215d19689c83c8bd0d33239a341e7394cac215e against tested main de2ba4cecb30ffb1c04d7e7dd693b03eace96b1b. Original authored changes, authorship and main gitlinks are preserved; publication used an exact old-head lease.

The conflict was in debt documentation. Main's newer WebAssembly and license notes are preserved alongside this PR's measured fmod qualification. The production fmod/fmodf bodies and CheckFmodConsoleBits match the previous public head byte for byte; main's other math changes and tests remain. Fresh libc and test builds pass guest_math, guest_math_exact, guest_dinkumware_internals and public_headers three times: 12 executions, zero skips. Earlier reference-library and platform measurements retain their original pins.

Conventions, whitespace and source preservation checks pass. Latest main 42d009f5f37c8f388b01fbfe38d2e704c792c46f has a clean merge preview; that preview tree was not executed. This refresh adds Linux CPU qualification; it adds no Windows/macOS, SDK, GPU, title or performance execution.

Immutable source, build and test receipts, SHA-256 098ecc93f56b576370b295af428157ef9e4b8ae2dabfdcb9816869be02270985 (download verified). AI-assisted: yes (Codex).

Packaging note: the archive's nested result.json retains an earlier packaging digest. The download SHA-256 above is authoritative; all 81 source/test proof files were checked unchanged, including the raw JUnit counts and published-head patches.

Checklist

  • Based on current main; no other open PR implements the same functions
  • One topic per PR; follow-ups go in a new PR
  • No comments in code except technical debt
  • Unimplemented paths throw (NotImplemented_nid_no_patch); silent stubs are listed under Silent stubs in their library's technical debt file
  • No notes, investigation .md files or images added to the repository (attach them to this PR)
  • New third-party code is a submodule built from source: none
  • Generic behaviour, not specific to one title
  • Depends on: none
  • Fixes: none
  • Unblocks: none
  • GPUs tested: n/a
  • AI-assisted: yes

AI-assisted (Claude Code).

Contributor-reported Windows follow-up: @ycbuzi tested earlier head 11d52c9a9f merged onto main f616a1397f, Windows 11 Home 10.0.26200, WinLibs GCC 15.2.0 UCRT r7, Release. Four groups (guest_math, guest_math_exact, guest_dinkumware_internals, public_headers) each passed three times. Their main-production Math.cpp control aborted guest_math; the other three groups passed. This is an attributed report on that earlier tree, without independently inspected raw logs or an assertion stack; it is not a Windows rerun of subsequent rebased heads. Original report.

<!-- greyfinch-sync:boykopovar/AnyPS5:issue:4987500144 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/10345). Originally posted by [JJenkx](https://github.com/JJenkx) on 2026-10-23T18:30:11Z. --- ### What `fmod` and `fmodf` save and restore `errno` around the host call. #3600 did that for `fmod` and #9643 for `fmodf`, both following FreeBSD msun, which never stores `errno`. #9643's debt entry records that the console's `errno` was not measured. Measured now, the `libc.prx` that titles ship sets `EDOM` exactly where msun's [`e_fmod.c`](https://github.com/freebsd/freebsd-src/blob/release/11.4.0/lib/msun/src/e_fmod.c) and [`e_fmodf.c`](https://github.com/freebsd/freebsd-src/blob/release/11.4.0/lib/msun/src/e_fmodf.c) return `(x*y)/(x*y)`: - a zero divisor of either sign; - an infinite or NaN dividend; - a NaN divisor. For example, `fmod(1, 0)` returns `0xfff8000000000000` with `EDOM` there, `fmod(NaN, 2)` returns that NaN with `EDOM`, and `fmod(1, inf)` returns 1 without `errno`. The NaN on that path also differs from the host's: - a NaN divisor is returned quieted, even when the dividend is a NaN too; - otherwise a NaN dividend is returned quieted; - otherwise (zero divisor, infinite dividend) the result is the default NaN `(x*y)/(x*y)`. UCRT returns the dividend's NaN when both are NaNs, so the host's result differs on 19 of the 4,000,256 double pairs tested below and on 344 of the float ones. Both functions now take that path themselves and set `EDOM`; every other argument still goes to the host `std::fmod` with `errno` preserved, whose finite results are exact. ### Tested <!-- codex-numeric-refresh-20261105-10345 --> **Current integration — 2026-11-05.** Head `3661c5c59cd9e96ac38af4f1c2926277aae6ecf9` includes pinned main `6d173c1a19788ff69d43b3d0ca62833e312ef939` and retains the previous public history, notices, main math implementations and actual prerequisites. Linux x86-64 Release, GCC 16.2.1: rebuilt libc and the three math executables; `guest_math`, `guest_math_exact` and `guest_dinkumware_internals` each pass 3/3 (9 passes, zero skips). The same groups pass 3/3 on pinned main. Source/parent/macro/notice checks and conventions pass. All 34 recursive provider trees / 31,551 tracked blobs verify before and after the gate; QuickJS test262 is excluded as declared update=none test data. **Shared main blocker:** `public_headers` fails on this head and pinned main for the same five missing `WKSecurityOrigin` declarations. [PR #16010](https://github.com/boykopovar/AnyPS5/pull/16010) restores them separately; a maintainer needs to merge that fix and rerun required checks. This math branch does not contain the unrelated WebKit patch. Header audits and all required CI are not claimed green. The older Windows compile failure in `DepthSurface.cpp` was a shared main API mismatch, fixed upstream by merged [PR #15855](https://github.com/boykopovar/AnyPS5/pull/15855), already included in this head. Its own [hosted Windows compile job passed](https://github.com/boykopovar/AnyPS5/actions/runs/41901908835/job/126840906295); this is not a fresh Windows qualification of this math head. [Immutable source/audit/log/JUnit/hash and exact-lease push evidence](https://github.com/JJenkx/AnyPS5/releases/download/linux-validation-20261023/numeric5-main6d-linux-20261105.tar.gz), SHA-256 `ef9e085442553c0fce1a4a6ce15781e4e890dc001a3424e1ef972f9b769f3065` (download and member hashes verified). Earlier dated platform/negative/reference reports retain their original source pins. No new Windows, console/SDK-module, GPU/title, exhaustive or performance result. AI-assisted: yes, Codex Sol6.1 medium. All earlier qualification text below is historical and retains its recorded source/platform pins, including earlier linear/no-merge descriptions. <!-- libc-main9ab-refresh-20261104-10345 --> **Current-main refresh — 2026-11-04.** Head `1b44472417e479a90ea28bd3bbc6f089ad994acd` merges main `9ab6a281ea61c9e62a7eb07eb4cef8f19ede1c5c` while retaining the prior public head as an ancestor. Main’s newer code, regression fixtures and debt entries are preserved alongside this topic. Linux x86-64, GCC16.2.1, Ninja Release: actual libc, libkernel and libSceAmpr CMake owners rebuilt coherently. `guest_math`, `guest_math_exact`, `guest_dinkumware_internals` each pass three consecutive runs (**9 passes, zero skips**). The same groups pass three times on pinned main. Public-header audit and conventions pass. Original licence-notice trailing whitespace is retained where present. The scoped recipe reuses frozen ZArchive/zstd providers; this is not a whole-project build. No new Windows, bundled-SDK, physical-console, title/GPU or FPS measurement is claimed; earlier reports retain their original pins. [Exact source/parent proofs, per-branch patches/input manifests, build and CTest logs/JUnit, library/executable hashes and scoped CMake recipe](https://github.com/JJenkx/AnyPS5/releases/download/linux-validation-20261023/owned-libc11-main9ab-linux-20261104.tar.gz), SHA-256 `97a2377bc996be1690e8853e1ea090a98b5ed808bcc37a15a5cdada5c2e00845` (download verified). AI-assisted: yes (Codex). **Current-main integration — 2026-11-03.** Head `b59beb9b4d1b457548fc811bd0a5adb17194903b` includes main `4f41f4c375f5abb487dbd184fbc150f31994d762` and retains the prior public history and attribution/licence notices. Main’s newer math implementations and fixtures remain alongside this topic. Linux x86-64 Release, GCC 16.2.1, Ninja, BUILD_TESTING=ON: rebuilt actual libc and math executables. `guest_math`, `guest_math_exact`, and `guest_dinkumware_internals` each pass 3/3 (**9 passes, zero skips**); `public_headers` and conventions pass. The same three groups pass 3/3 plus headers on pinned main. All 34 recursive dependency trees and 31,551 tracked blobs verify with zero errors; the update=none QuickJS test262 corpus is excluded from these library inputs. `git diff --check` reports the preserved verbatim licence trailing-space line; no other whitespace warnings occur. Source/parent/gitlink proofs, exact library/test hashes, raw logs/JUnit, and head-leased push receipts: [qualification archive](https://github.com/JJenkx/AnyPS5/releases/download/linux-validation-20261023/math15-main4f41-linux-20261103.tar.gz), SHA-256 `e6a50522bc28e30871fdc2c12a88d2537515914239e8166f6237f48895126a06` (download verified). Older platform/reference reports retain their original pins; no new Windows/macOS, SDK-module, console, title/GPU or performance claim. AI-assisted: yes (Codex). Earlier dated qualifications below retain their recorded source/platform pins. **Current-main integration (2026-11-02):** `9a1276994094707acc4b1c1f1ecbc7cdd873a07c` includes main `a4eca2a056bf3bbbec98ab42e9d28163e4ea9cb8` and retains the existing public commits. Conflicts preserve main’s math implementations, regression checks and debt entries alongside this topic. Linux x86-64 Release, GCC 16.2.1: rebuilt libc and the three math executables; `guest_math`, `guest_math_exact` and `guest_dinkumware_internals` each pass three times (9 passes, zero skips), and `public_headers` passes. The same baseline groups pass on main; conventions and whitespace pass. Source and dependency blobs, executable/library hashes, raw logs and JUnit are retained. This refresh adds no new console, Windows, title, GPU or numerical-reference measurement. [Qualification evidence](https://github.com/JJenkx/AnyPS5/releases/download/linux-validation-20261023/math-root14-maina4eca-linux-20261102-terminal.tar.gz), SHA-256 `22866bd2a060ba69cd4387d471605afe20ed644e3257174b2d1488635f8c9b52` (download verified). <!-- codex-main-refresh-20261027-pr10345 --> **Current-main conflict refresh, 2026-10-27 UTC:** exact head `8b4b0ecdfc2fbdb9ae3f10ec929d627cb942fed9` on tested main `74acfad65b3f0fd4eab653f3a3989d298fba1157`. Resolved overlapping test/debt context while preserving this branch's authored production/test edits and main's nextafter environment implementation and coverage. Existing prerequisite commits remain in their original series order. Linux focused rebuild of `libc` and selected test executables passes `guest_math`, `guest_math_exact`, `guest_dinkumware_internals`, and `public_headers`, each three times: **12 passes, zero skips**. Conventions and whitespace checks pass. Final fetched main `cb45ae2ddf6e113a4619e8fed91fe7b9333c5c0f` merges cleanly; its later change is an unrelated Windows crash-test pattern, and the executed qualification remains pinned to the stated base. No new Windows, console, GPU, title, full-suite or negative-control run is claimed. Earlier reference/Windows evidence keeps its original pins. [Exact pins, branch patches, preservation proofs, build/test logs, JUnit and lease-push receipts for this refresh batch](https://github.com/JJenkx/AnyPS5/releases/download/linux-validation-20261023/owned-math14-main74acfad-linux-refresh-20261027.tar.gz). SHA-256: `e33f98cc467f038af662cc5fa491c3acc1806bb47171cf77b748f0d4d052c1f2`; downloaded copy verified. <!-- codex-review-refresh-20261026-pr10345-final --> Latest conflict refresh (2026-10-26): exact head `11d52c9a9f5cdce272b71217031fac5f397bf997` on main `bf77a9e9cba4b02c358779b35295176dd9cae164`. The conflict was in adjacent debt notes; the production implementations and regression checks are preserved. Main's unrelated `_LCosh`/`_LSinh` debt is retained. Rebuilt `libc` and the focused test executables on Linux. `guest_math`, `guest_math_exact`, `guest_dinkumware_internals`, and `public_headers` pass: **four groups × three repetitions (12 passes)**, zero skips. Conventions, whitespace and final main merge checks pass; the source tree is clean. This is a mechanical refresh with a debt-note resolution, so no new console, Windows, title, GPU or negative-control run is claimed. Earlier measurements retain their original exact pins. [Patch/preservation checks, exact pins, build/test logs, JUnit and push receipts](https://github.com/JJenkx/AnyPS5/releases/download/linux-validation-20261023/pr10345-pr11139-mainbf77-linux-refresh-20261026.tar.gz). SHA-256: `196fbf4f07b96515f278558ca31d139759c24195adfd35ddebc93f03c186c92b`; downloaded copy verified. **Current Linux rebase:** `7385e2d9b96eac4c193f74c48cfa5a9a021f0540`, one topic commit on main `16ff208dc32cf3927ba1bae492eee363a5ae7ae8`, without merge commits. Production and regression function bodies are unchanged from `025a0c21203773de7ae94365aedaffd53beeceec`; main's merged log1p implementation, regressions and calls remain intact. Additive regression insertions were retained on both sides. Fresh Linux x86-64 Release: `guest_math`, `guest_math_exact`, `guest_dinkumware_internals` and `public_headers` each pass three repeats before and after the production-only main-Math negative control. The negative fails as expected while exact-math/Dinkumware controls pass; restored libc is byte-identical. Conventions and whitespace pass. The Release negative aborts without a named assertion; no more specific failure attribution is claimed. [Fresh exact-head logs, negative/restoration evidence and preservation proof](https://github.com/JJenkx/AnyPS5/releases/download/linux-validation-20261023/pr10345-7385e2d9-pr10529-1f3b3024-main16ff-linux-validation.tar.gz) (SHA-256 `fba4546fd2ffc5ea33459b5cc498adc8d2844b835d01d33e301b09d530c93087`). No new Windows/macOS, title/module matrix or performance result is claimed. Earlier independent reports below retain their original measured revisions. #### Previous qualification (historical source pins) Historical Linux refresh: head `025a0c21203773de7ae94365aedaffd53beeceec`, one commit on main `50a4f824fc3ee23177d8e1effbe306e50150187f` (no merge commits). Original fmod/fmodf function bodies and CheckFmodConsoleBits are byte-identical; main's expm1 test/function call and other debt entries are retained. The obsolete standalone fmodf debt entry remains removed as reviewed. Linux 7.2.9 / Ryzen 9 7950X / GCC 16.2.1 / Release: fresh independent libc/math build; `guest_math` and `guest_dinkumware_internals` each pass three runs. With only production Math.cpp reverted to this main and the fixture retained, `guest_math` aborts; restoring the fix gives six passing invocations and the same libc library SHA-256 `413501dad82cc3f36177cc0b5e0eb8727289232d67f778a33aef3293acaeae32`. No named assertion is emitted by this Release negative control. Conventions and whitespace pass. Windows remains user-paused: the comparison below is historical and has not been rerun on this head. [Exact-head Linux build/test/negative-control receipts](https://github.com/JJenkx/AnyPS5/releases/download/linux-validation-20261023/pr10345-head025a0c21-linux-validation.tar.gz), SHA-256 `81e2804b8c970b7a9605a8951dd685aeb1525c2976e4e9ac9713cf0ee166301c`. Hosted [Build 40151994198](https://github.com/boykopovar/AnyPS5/actions/runs/40151994198) completed successfully on this exact head, including Linux, Windows and both macOS relinker builds. These relinker jobs do not run the libc math regressions; full platform math claims remain scoped to the evidence above/below. Historical Windows evidence (original implementation): Windows 11 Enterprise 10.0.22621, Ryzen 9 5950X, WinLibs GCC 15.2.0 UCRT r7, Ninja, Release, `BUILD_TESTING=ON`, `main` 65ac1d3b50. - **Comparison:** a scratch loader runs the decrypted `libc.prx` of eleven titles natively and supplies `__error`: PPSA04158, PPSA05916, PPSA07923, PPSA09614, PPSA13934, PPSA20423, PPSA25636, PPSA26528, PPSA33655, PPSA34008 and PPSA35169. It compared their `fmod` and `fmodf` with this PR's code on 4,000,256 pairs per title: - every pair of 16 special values (±0, subnormals, ±1, 2, `DBL_MAX`, ±`inf`, signalling and quiet NaNs of both signs); - 4 million random pairs, half random bit patterns and half with the divisor's exponent up to 80 below the dividend's; - the float check uses the high 32 bits of each pair. All eleven give identical bits and `errno` for both functions on all of them. `EDOM` is set on 3,118 of the double pairs and 23,617 of the float pairs. A separate 76-row edge probe (`remainder`, `fmod`, `remquo`, `logb`, `ilogb` and `nextafter`, double and float) prints byte-identical output on all eleven. - **`guest_math`:** the new `CheckFmodConsoleBits` has 15 double and 15 float cases with the console's results and `errno`. They cover each error class with NaN payloads in both positions, a signalling NaN in each position, an infinite divisor, ±0 over ±0, subnormals, and ordinary remainders. - **Changed tests:** - `CheckFmodErrno` (#3600) now expects `EDOM` from `fmod(1, 0)`. - #9643's `fmodf` table now expects `EDOM` for its NaN-result rows and the untouched sentinel for the others. Its environment check now expects `EDOM` after `fmodf(1, 0)`. Their result, `FE_INVALID` and environment expectations are unchanged and pass. cc @CouchRiv @Noxy-HNR - `guest_math`, `guest_floating_point` and `guest_dinkumware_internals` pass in three runs out of three on the exact head. - **Negative control:** with `main`'s `Math.cpp` and these tests, `guest_math` aborts, while the other two still pass. - A standalone `-O0` and `-O3` build of the new code with the new vectors, #9643's `fmodf` table and its environment check passes. - `python tools/check_conventions.py --base origin/main` and `git diff --check` pass. - **Not tested:** Linux and macOS (the error path no longer depends on the host; finite results come from the host's exact `fmod`), a console, the exception flags against the console, and `fmodl`. ### Independent macOS integration evidence [imellag reports](https://github.com/boykopovar/AnyPS5/pull/10345#issuecomment-6395865475) Apple M4 Pro, macOS27.0.1, x86-64 under Rosetta2, using main `61fc572cee` plus open macOS build changes. Without this PR, four fmodf domain cases return NaN without `FE_INVALID`, and `guest_math` fails at the reported `(1,0)` case. With this PR's domain expression, plus #9668 and the denormal-operand test adjustment #10907, the reporter gets three passing `guest_math` runs; omitting this PR restores the failure. The comment does not give this PR's exact tested head, so this is attributed integration evidence, not a new exact-head or title run by us. <!-- codex-math-refresh-20261028-repeat-pr10345 --> ### Current Linux qualification (2026-10-28) Rebased onto `main` `2227f1366188cda5699dd20e2e756a18006a5d4b`. Linux CPU validation on 2026-10-28 at `760f4f9386287b626560c16bcbe7363936741872` (Arch Linux 7.2.9, AMD Ryzen 9 7950X, GCC 16.2.1, Ninja Release, BUILD_TESTING=ON). `libc`, `guest_math_tests` and `guest_math_exact_tests` rebuilt from this exact source. `guest_math` and `guest_math_exact` each passed three consecutive runs (6/6, no skips); the same two suites each passed three runs on the pinned main (6/6). Conventions and whitespace checks pass. [Exact source pins, preservation proofs, dependency checks, build logs and JUnit](https://github.com/JJenkx/AnyPS5/releases/download/linux-validation-20261023/owned-math25-main2227-linux-20261028-repeat.tar.gz), SHA-256 `1176269c9e6948b5252a5db9e660978d7f978fb2d9f4ed6c68bc050b10b5ae68`. This is focused Linux CPU qualification; earlier Windows/title/reference measurements retain their original pins. No new title or performance result is claimed. <!-- codex-maintenance-20261029-repeat-10345 --> **Current Linux qualification — 2026-10-29** Refreshed against main `5454cd2e455994d992aca39335ce60507eeda1eb`. Linux qualification at `5b596a5d104db3f81d0241afa562fb8726f0c944` (Arch Linux 7.2.9, Ryzen 9 7950X, GCC 16.2.1, Ninja Release, BUILD_TESTING=ON): `guest_math`, `guest_math_exact`, `guest_dinkumware_internals` each pass three consecutive runs (9/9, no skips). The `public_headers` audit passes at this exact head. All tracked public-header files match the pinned main; the affected test targets rebuild against those headers. Conventions and whitespace checks pass. The same focused groups passed three times on the pinned main. Evidence: [immutable Linux qualification bundle](https://github.com/JJenkx/AnyPS5/releases/download/linux-validation-20261023/owned-math10-main5454-linux-20261029-repeat.tar.gz). Its SHA-256 is `53b095da2f67f55b8aa56ba273681e0330fb39739be844458038dde410fb8cc4`. No fresh Windows runtime execution is claimed; older measurements retain their recorded source pins. AI-assisted: yes (Codex). <!-- codex-maintenance-20261030-repeat2-final-10345 --> **Additional main-conflict refresh — 2026-10-30** Refreshed to `6215d19689c83c8bd0d33239a341e7394cac215e` against tested main `de2ba4cecb30ffb1c04d7e7dd693b03eace96b1b`. Original authored changes, authorship and main gitlinks are preserved; publication used an exact old-head lease. The conflict was in debt documentation. Main's newer WebAssembly and license notes are preserved alongside this PR's measured fmod qualification. The production `fmod`/`fmodf` bodies and `CheckFmodConsoleBits` match the previous public head byte for byte; main's other math changes and tests remain. Fresh libc and test builds pass `guest_math`, `guest_math_exact`, `guest_dinkumware_internals` and `public_headers` three times: 12 executions, zero skips. Earlier reference-library and platform measurements retain their original pins. Conventions, whitespace and source preservation checks pass. Latest main `42d009f5f37c8f388b01fbfe38d2e704c792c46f` has a clean merge preview; that preview tree was not executed. This refresh adds Linux CPU qualification; it adds no Windows/macOS, SDK, GPU, title or performance execution. [Immutable source, build and test receipts](https://github.com/JJenkx/AnyPS5/releases/download/linux-validation-20261023/final-three-main-de2-cpu-linux-refresh-20261030.tar.gz), SHA-256 `098ecc93f56b576370b295af428157ef9e4b8ae2dabfdcb9816869be02270985` (download verified). AI-assisted: yes (Codex). Packaging note: the archive's nested `result.json` retains an earlier packaging digest. The download SHA-256 above is authoritative; all 81 source/test proof files were checked unchanged, including the raw JUnit counts and published-head patches. ### Checklist - [x] Based on current `main`; no other open PR implements the same functions - [x] One topic per PR; follow-ups go in a new PR - [x] No comments in code except [technical debt](https://github.com/boykopovar/AnyPS5/blob/main/docs/dev/CONVENTIONS.md) - [x] Unimplemented paths throw (`NotImplemented_nid_no_patch`); silent stubs are listed under Silent stubs in their library's [technical debt](https://github.com/boykopovar/AnyPS5/tree/main/docs/dev/debt) file - [x] No notes, investigation `.md` files or images added to the repository (attach them to this PR) - [x] New third-party code is a submodule built from source: none - [x] Generic behaviour, not specific to one title - [x] Depends on: none - [x] Fixes: none - [x] Unblocks: none - [x] GPUs tested: n/a - [x] AI-assisted: yes AI-assisted (Claude Code). <!-- codex-contributor-note-20261027-pr10345 --> Contributor-reported Windows follow-up: @ycbuzi tested earlier head `11d52c9a9f` merged onto main `f616a1397f`, Windows 11 Home 10.0.26200, WinLibs GCC 15.2.0 UCRT r7, Release. Four groups (`guest_math`, `guest_math_exact`, `guest_dinkumware_internals`, `public_headers`) each passed three times. Their main-production `Math.cpp` control aborted `guest_math`; the other three groups passed. This is an attributed report on that earlier tree, without independently inspected raw logs or an assertion stack; it is not a Windows rerun of subsequent rebased heads. [Original report](https://github.com/boykopovar/AnyPS5/pull/10345#issuecomment-6418359478).
harisibrar1 commented 2026-10-24 01:10:29 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by harisibrar1 on 2026-10-24T01:10:29Z.

Review: APPROVED


Checked against main 11d6efa06c and FreeBSD 11.4 msun e_fmod.c/e_fmodf.c:

  • It still merges cleanly. On main, fmod has moved to Math.cpp:648 and fmodf is at :292, and both still just save and restore errno.
  • The checks in both functions match the msun condition for the (x*y)/(x*y) return (zero divisor, non-finite dividend, NaN divisor), and finite pairs still go to std::fmod with errno preserved.
  • This matches main's fmodl (MathExact.cpp, around lines 91-98), which already sets EDOM and returns (x*y)/(x*y) for the same classes, so all three widths now agree.
  • The debt entry replaces the old fmodf one under Functional, next to the other measured msun entries.

Reviewed with AI assistance (Claude Code); the checks above were run locally on my machine.

<!-- greyfinch-sync:boykopovar/AnyPS5:review:5636031134 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/10345#pullrequestreview-5636031134). Originally posted by [harisibrar1](https://github.com/harisibrar1) on 2026-10-24T01:10:29Z. **Review:** APPROVED --- Checked against main 11d6efa06c and FreeBSD 11.4 msun `e_fmod.c`/`e_fmodf.c`: - It still merges cleanly. On main, `fmod` has moved to `Math.cpp:648` and `fmodf` is at `:292`, and both still just save and restore errno. - The checks in both functions match the msun condition for the `(x*y)/(x*y)` return (zero divisor, non-finite dividend, NaN divisor), and finite pairs still go to `std::fmod` with errno preserved. - This matches main's `fmodl` (`MathExact.cpp`, around lines 91-98), which already sets `EDOM` and returns `(x*y)/(x*y)` for the same classes, so all three widths now agree. - The debt entry replaces the old `fmodf` one under Functional, next to the other measured msun entries. Reviewed with AI assistance (Claude Code); the checks above were run locally on my machine.
MarcZX10 commented 2026-10-24 20:57:19 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-10-24T20:57:19Z.

Review: APPROVED


Reviewed exact head 8bee26992d127a7fa5b2c3df543188f6fa7883b2. The new binary64 and binary32 paths follow the stated FreeBSD msun exceptional-input ordering, set EDOM for zero divisors and invalid operands, preserve incoming errno for finite valid inputs, and leave finite result calculation to std::fmod. The added bit-pattern cases cover signed zero divisors, infinities, quiet/signaling NaNs, payload preference, valid finite results and subnormals. The stale standalone fmodf debt claim is removed; the combined entry records the unverified exception flags.

The author reports guest_math passing three times on this exact head. Hosted eligibility, conventions, Ubuntu/Windows/macOS relinker, ASan, register-context and write-watch checks pass; product Linux/Windows jobs are skipped by policy. I independently ran the conventions check and git diff --check successfully. A local full CMake configure could not complete because the SDL2 submodule has no CMakeLists.txt and the environment lacks SDL XRandR support, so I did not run guest_math locally.

Current #10742 also edits docs/dev/debt/libc.md; combining the heads conflicts only in that document. The code and tests merge cleanly, and the combined debt file should retain both entries. I found no implementation blocker.

<!-- greyfinch-sync:boykopovar/AnyPS5:review:5639995719 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/10345#pullrequestreview-5639995719). Originally posted by [MarcZX10](https://github.com/MarcZX10) on 2026-10-24T20:57:19Z. **Review:** APPROVED --- Reviewed exact head `8bee26992d127a7fa5b2c3df543188f6fa7883b2`. The new binary64 and binary32 paths follow the stated FreeBSD msun exceptional-input ordering, set `EDOM` for zero divisors and invalid operands, preserve incoming errno for finite valid inputs, and leave finite result calculation to `std::fmod`. The added bit-pattern cases cover signed zero divisors, infinities, quiet/signaling NaNs, payload preference, valid finite results and subnormals. The stale standalone `fmodf` debt claim is removed; the combined entry records the unverified exception flags. The author reports `guest_math` passing three times on this exact head. Hosted eligibility, conventions, Ubuntu/Windows/macOS relinker, ASan, register-context and write-watch checks pass; product Linux/Windows jobs are skipped by policy. I independently ran the conventions check and `git diff --check` successfully. A local full CMake configure could not complete because the SDL2 submodule has no `CMakeLists.txt` and the environment lacks SDL XRandR support, so I did not run `guest_math` locally. Current #10742 also edits `docs/dev/debt/libc.md`; combining the heads conflicts only in that document. The code and tests merge cleanly, and the combined debt file should retain both entries. I found no implementation blocker.
MarcZX10 commented 2026-10-24 21:04:00 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-10-24T21:04:00Z.

Review: CHANGES_REQUESTED


Follow-up to my earlier approval: I refreshed upstream/main and found this branch's merge base is fe204e1a8d3d, with 6,693 current-main commits since it. CONTRIBUTING.md asks contributors to keep branches up to date with main. The local full configure was also blocked, and the available guest_math runs were reported on the older base; the current hosted product jobs are skipped. Please update the branch to current main and rerun guest_math on the resulting tree so the changed fmod implementation and regression cases are validated against the supported base. I will revisit approval after that evidence is available.

<!-- greyfinch-sync:boykopovar/AnyPS5:review:5640020688 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/10345#pullrequestreview-5640020688). Originally posted by [MarcZX10](https://github.com/MarcZX10) on 2026-10-24T21:04:00Z. **Review:** CHANGES_REQUESTED --- Follow-up to my earlier approval: I refreshed `upstream/main` and found this branch's merge base is `fe204e1a8d3d`, with 6,693 current-main commits since it. `CONTRIBUTING.md` asks contributors to keep branches up to date with main. The local full configure was also blocked, and the available `guest_math` runs were reported on the older base; the current hosted product jobs are skipped. Please update the branch to current main and rerun `guest_math` on the resulting tree so the changed `fmod` implementation and regression cases are validated against the supported base. I will revisit approval after that evidence is available.
MarcZX10 commented 2026-10-28 22:13:46 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-10-28T22:13:46Z.

Review: APPROVED


Reviewing exact head 760f4f9386287b626560c16bcbe7363936741872.

What I ran

  • Inspected both commits, the final fmod/fmodf paths and tests, current review discussion, and hosted checks.
  • Confirmed the branch's last tested main was 2227f13661. Current main has added adjacent math and test changes in the same files, but the affected hunks are separate and GitHub reports a clean merge.
  • Hosted conventions, eligibility, labels, register-context, relinker, ASan, write-watch, Windows, and report checks pass. The product Linux job is skipped.
  • I did not run a local build or tests.

Results

Check Result Evidence
Domain/NaN ordering, EDOM and FE_INVALID behavior Reviewed Exact current diff
Linux focused math tests Pass, author-reported guest_math and guest_math_exact, three runs on the tested sync
Windows tests and title-libc comparisons Pass, author-reported Multiple titles and broad input samples; older measured heads
Hosted Windows and supporting platform/policy checks Pass GitHub Actions
Hosted Linux product build Skipped GitHub Actions
Local build and tests Not run This review

Findings

Blocking

None.

Non-blocking

  • The fast bit checks select the same domain cases as the referenced FreeBSD implementation. NaN divisor precedence, NaN dividend handling, zero divisors, and infinite dividends use the measured quiet-NaN/EDOM path; finite results continue through host std::fmod with the prior errno restored.
  • The head documents that finite-result exception flags still come from the host and were not compared with the console. The PR's eleven-title comparisons cover result bits and errno, not console floating-point flags.
  • Main's later adjacent math/test edits remain in separate hunks. Keep them when resolving the resulting textual overlap.

Sources

Not verified

  • I did not locally build or run CTest.
  • Windows title comparisons and Linux focused runs are author-reported; hosted Linux product tests did not run on this PR.

To get this to a good state

No blocking issue remains on the reviewed head. Preserve current main's adjacent math/test changes when merging.

<!-- greyfinch-sync:boykopovar/AnyPS5:review:5690392628 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/10345#pullrequestreview-5690392628). Originally posted by [MarcZX10](https://github.com/MarcZX10) on 2026-10-28T22:13:46Z. **Review:** APPROVED --- Reviewing exact head `760f4f9386287b626560c16bcbe7363936741872`. ## What I ran - Inspected both commits, the final fmod/fmodf paths and tests, current review discussion, and hosted checks. - Confirmed the branch's last tested main was `2227f13661`. Current main has added adjacent math and test changes in the same files, but the affected hunks are separate and GitHub reports a clean merge. - Hosted conventions, eligibility, labels, register-context, relinker, ASan, write-watch, Windows, and report checks pass. The product Linux job is skipped. - I did not run a local build or tests. ## Results | Check | Result | Evidence | |---|---|---| | Domain/NaN ordering, EDOM and FE_INVALID behavior | Reviewed | Exact current diff | | Linux focused math tests | Pass, author-reported | guest_math and guest_math_exact, three runs on the tested sync | | Windows tests and title-libc comparisons | Pass, author-reported | Multiple titles and broad input samples; older measured heads | | Hosted Windows and supporting platform/policy checks | Pass | GitHub Actions | | Hosted Linux product build | Skipped | GitHub Actions | | Local build and tests | Not run | This review | ## Findings ### Blocking None. ### Non-blocking - The fast bit checks select the same domain cases as the referenced FreeBSD implementation. NaN divisor precedence, NaN dividend handling, zero divisors, and infinite dividends use the measured quiet-NaN/EDOM path; finite results continue through host `std::fmod` with the prior errno restored. - The head documents that finite-result exception flags still come from the host and were not compared with the console. The PR's eleven-title comparisons cover result bits and errno, not console floating-point flags. - Main's later adjacent math/test edits remain in separate hunks. Keep them when resolving the resulting textual overlap. ## Sources - [Repository contribution and test rules](https://github.com/boykopovar/AnyPS5/blob/main/AGENTS.md) - [Current pull request and title comparison evidence](https://github.com/boykopovar/AnyPS5/pull/10345) ## Not verified - I did not locally build or run CTest. - Windows title comparisons and Linux focused runs are author-reported; hosted Linux product tests did not run on this PR. ## To get this to a good state No blocking issue remains on the reviewed head. Preserve current main's adjacent math/test changes when merging.
Sign in to join this conversation.
No reviewers
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
boykopovar/AnyPS5!10345
No description provided.