fix(libc): preserve tanh saturation flags and directed rounding #10506

Merged
JJenkx merged 11 commits from upstream-pr/10506 into main 2026-11-08 18:09:02 +00:00
JJenkx commented 2026-10-24 05:45:19 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by JJenkx on 2026-10-24T05:45:19Z.


What

The saturation branch introduced by #10316 evaluates 1 - tiny with a volatile operand. tanh(22) therefore raises FE_INEXACT; under downward or toward-zero rounding its result is the representable value below 1. The supplied libc.prx in FAR: Changing Tides (PPSA03766) returns exact signed 1 with no new exception flags for finite magnitudes of at least 22.

Return exact signed 1 from that branch. Add a regression covering positive/negative saturation, four rounding modes, all DAZ/FTZ combinations, and clean or pre-existing sticky flags. Record the remaining unsaturated discrepancies in debt.

This follows #10316 and its #10306 dependency; the new topic is one commit on their existing implementations. Base main is 6c52b649e7; a merge-tree check against current main a5a2c946a3 is clean. The overlap report lists shared math/test/debt anchors; the declared parent PRs supply the required implementations.

Tested

Current-main refresh — 2026-11-04. Head 9bed91fb373a0d29d27af064547ded5ec28b5207 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 e1d96ebdf91075b1783f614f65ce5b4fded0bb1c 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. Whitespace check passes.

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): 7028b1757c9e42d2e943e931d07ae5a5ee592795 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 54d349183697fe9e09f9a8e41eb77f81ca1590fc 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 and guest_math_exact, each three times: 6 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.

Current Linux refresh: 9c79f0a14c5e28fc6bc5c3a68d5ed2eb24a6ed3b is refreshed onto main a5a780eaaa7f187fe8f5c7f2ef244f6a6dab2762, with prerequisite authorship retained and no merge commits. The original production and regression function bodies are preserved, along with main's log1p implementation, regression calls and current public declarations.

Fresh Linux x86-64 Release: guest_math, guest_math_exact, guest_dinkumware_internals and public_headers each pass3/3 before and after the production-only main-Math negative control. The negative aborts as expected while exact-math/Dinkumware controls pass. Restored libc is byte-identical and sources clean. Conventions, whitespace and merge-tree checks pass.

Exact-head logs, negative/restoration results and preservation proof (SHA-256 f107a42be1dabc4ef72ffddcc6274d35e65ebd40146c811214558b28d4952a90). No fresh original-module matrix, Windows/macOS/title/console or performance measurement is claimed by this refresh. Earlier reports below retain their measured source pins.

Previous qualification (historical source pins)

Current Linux refresh: head 489726b9f600a42daf6e7f493d18f9dd867b5774, directly on #10316 at a5b452fa493d91a14fbb3e708f618171a9b3dcb4 (itself one commit on main 50a4f824fc3ee23177d8e1effbe306e50150187f). The merged #10306 commit is no longer duplicated in this stack. Production added/removed lines are byte-identical to the previous reviewed head. Fresh independent libc/math build; guest_math and guest_dinkumware_internals each pass three consecutive runs. With only Math.cpp reverted to the direct parent's production code and the new fixture retained, guest_math aborts; restoration returns both groups to passing and reproduces the original libc library hash. Conventions/whitespace pass.

Read-only merge-tree against fetched main dc15ed65375228a0f69c41d7770c4c118adb38f2 is clean; the checks above are on the explicitly stated tested base, not a build of that merge tree. Windows remains user-paused and has not been rerun on this head.

Exact-head Linux build, JUnit, negative/restoration controls and rebase proof, SHA-256 1087c9bf4d5bd4e0a9c5e54b5d18e710c1e576d7de607f0adc30d41d23af67a2.

Historical previous-head evidence (not rerun on the current head):

Linux x86-64, Ryzen 9 7950X, GCC 16.2.1, Release. Final head 12826b49859a22e3896b7ff6670152ea94d22397.

  • Isolated libc/math builds pass. guest_math and guest_dinkumware_internals each pass three consecutive runs at the final head. The new saturation test makes 480 calls per run.
  • Same-test negative control 720c7318597f28501ea3c644ac744333120d85dd retains the original production code. guest_math aborts at the named saturation check (tanh(22) has unexpected inexact); guest_dinkumware_internals passes.
  • CPU-only differential fixture: 1,344 structured/deterministic-random double inputs × four rounding modes × four DAZ/FTZ states × three sticky-flag seeds = 64,512 calls per arm, for original module, control and change. The original module is loaded as a library; its title entrypoint is never called. The probe rejects loaded AGC, VideoOut or Vulkan libraries.
  • All 25,344 finite saturated cases match the original module in result bits, errno, exception flags and MXCSR control. The control differs on 21,120 of them. No nonsaturated observation changes between control and fix. Twelve pre-existing nonsaturated result-bit differences from the reference remain and are documented; all expanded flags/errno/control observations match the reference after this fix.
  • Reference tanh code is byte-identical in the original unwrapped module and its converted guest function. Both module hashes remain unchanged. Original module binaries are excluded from the evidence archive.
  • Diff and current-main conventions checks pass. The overlap report lists shared math/test/debt anchors; the open-PR search found no other double-tanh saturation fix.

Source patch, numeric comparison logs, fixture, build/test logs, negative-control result and overlap report. SHA256 496fc2f59831bb8ff5e71c3c9f288ea3fcbc8b4dac7e8c1baea56d333c583279.

Not tested: Windows, macOS, a physical console or unmasked floating-point exceptions. This is library correctness evidence; no title bring-up or FPS gain is established.

Current Linux qualification (2026-10-28)

Rebased onto main 2227f1366188cda5699dd20e2e756a18006a5d4b. Linux CPU validation on 2026-10-28 at 6a8a2372a3c3932e23dce46dd388cfe9b06aa87a (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.

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
  • Generic behaviour, not specific to one title
  • Depends on: none (#10316 merged at cbee22480462; present in audited main 3fea2a937ba)
  • Fixes: none
  • Unblocks: none
  • GPUs tested: n/a
  • AI-assisted: yes
<!-- greyfinch-sync:boykopovar/AnyPS5:issue:4992888338 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/10506). Originally posted by [JJenkx](https://github.com/JJenkx) on 2026-10-24T05:45:19Z. --- ### What The saturation branch introduced by #10316 evaluates `1 - tiny` with a volatile operand. `tanh(22)` therefore raises `FE_INEXACT`; under downward or toward-zero rounding its result is the representable value below 1. The supplied `libc.prx` in FAR: Changing Tides (PPSA03766) returns exact signed 1 with no new exception flags for finite magnitudes of at least 22. Return exact signed 1 from that branch. Add a regression covering positive/negative saturation, four rounding modes, all DAZ/FTZ combinations, and clean or pre-existing sticky flags. Record the remaining unsaturated discrepancies in debt. This follows #10316 and its #10306 dependency; the new topic is one commit on their existing implementations. Base main is `6c52b649e7`; a merge-tree check against current main `a5a2c946a3` is clean. The overlap report lists shared math/test/debt anchors; the declared parent PRs supply the required implementations. ### Tested <!-- libc-main9ab-refresh-20261104-10506 --> **Current-main refresh — 2026-11-04.** Head `9bed91fb373a0d29d27af064547ded5ec28b5207` 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 `e1d96ebdf91075b1783f614f65ce5b4fded0bb1c` 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. Whitespace check passes. 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):** `7028b1757c9e42d2e943e931d07ae5a5ee592795` 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-pr10506 --> **Current-main conflict refresh, 2026-10-27 UTC:** exact head `54d349183697fe9e09f9a8e41eb77f81ca1590fc` 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` and `guest_math_exact`, each three times: **6 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. **Current Linux refresh:** `9c79f0a14c5e28fc6bc5c3a68d5ed2eb24a6ed3b` is refreshed onto main `a5a780eaaa7f187fe8f5c7f2ef244f6a6dab2762`, with prerequisite authorship retained and no merge commits. The original production and regression function bodies are preserved, along with main's log1p implementation, regression calls and current public declarations. Fresh Linux x86-64 Release: `guest_math`, `guest_math_exact`, `guest_dinkumware_internals` and `public_headers` each pass3/3 before and after the production-only main-Math negative control. The negative aborts as expected while exact-math/Dinkumware controls pass. Restored libc is byte-identical and sources clean. Conventions, whitespace and merge-tree checks pass. [Exact-head logs, negative/restoration results and preservation proof](https://github.com/JJenkx/AnyPS5/releases/download/linux-validation-20261023/pr10510-230d2ddc-pr10506-9c79f0a1-pr10468-946149ed-maina5a7-linux-validation.tar.gz) (SHA-256 `f107a42be1dabc4ef72ffddcc6274d35e65ebd40146c811214558b28d4952a90`). No fresh original-module matrix, Windows/macOS/title/console or performance measurement is claimed by this refresh. Earlier reports below retain their measured source pins. #### Previous qualification (historical source pins) Current Linux refresh: head `489726b9f600a42daf6e7f493d18f9dd867b5774`, directly on #10316 at `a5b452fa493d91a14fbb3e708f618171a9b3dcb4` (itself one commit on main `50a4f824fc3ee23177d8e1effbe306e50150187f`). The merged #10306 commit is no longer duplicated in this stack. Production added/removed lines are byte-identical to the previous reviewed head. Fresh independent libc/math build; guest_math and guest_dinkumware_internals each pass three consecutive runs. With only Math.cpp reverted to the direct parent's production code and the new fixture retained, guest_math aborts; restoration returns both groups to passing and reproduces the original libc library hash. Conventions/whitespace pass. Read-only merge-tree against fetched main `dc15ed65375228a0f69c41d7770c4c118adb38f2` is clean; the checks above are on the explicitly stated tested base, not a build of that merge tree. Windows remains user-paused and has not been rerun on this head. [Exact-head Linux build, JUnit, negative/restoration controls and rebase proof](https://github.com/JJenkx/AnyPS5/releases/download/linux-validation-20261023/pr10316-pr10506-linear-main50-linux-validation.tar.gz), SHA-256 `1087c9bf4d5bd4e0a9c5e54b5d18e710c1e576d7de607f0adc30d41d23af67a2`. Historical previous-head evidence (not rerun on the current head): Linux x86-64, Ryzen 9 7950X, GCC 16.2.1, Release. Final head `12826b49859a22e3896b7ff6670152ea94d22397`. - Isolated libc/math builds pass. `guest_math` and `guest_dinkumware_internals` each pass three consecutive runs at the final head. The new saturation test makes 480 calls per run. - Same-test negative control `720c7318597f28501ea3c644ac744333120d85dd` retains the original production code. `guest_math` aborts at the named saturation check (`tanh(22)` has unexpected inexact); `guest_dinkumware_internals` passes. - CPU-only differential fixture: 1,344 structured/deterministic-random double inputs × four rounding modes × four DAZ/FTZ states × three sticky-flag seeds = 64,512 calls per arm, for original module, control and change. The original module is loaded as a library; its title entrypoint is never called. The probe rejects loaded AGC, VideoOut or Vulkan libraries. - All 25,344 finite saturated cases match the original module in result bits, errno, exception flags and MXCSR control. The control differs on 21,120 of them. No nonsaturated observation changes between control and fix. Twelve pre-existing nonsaturated result-bit differences from the reference remain and are documented; all expanded flags/errno/control observations match the reference after this fix. - Reference `tanh` code is byte-identical in the original unwrapped module and its converted guest function. Both module hashes remain unchanged. Original module binaries are excluded from the evidence archive. - Diff and current-main conventions checks pass. The overlap report lists shared math/test/debt anchors; the open-PR search found no other double-tanh saturation fix. [Source patch, numeric comparison logs, fixture, build/test logs, negative-control result and overlap report](https://github.com/JJenkx/AnyPS5/releases/download/linux-validation-20261023/libc-tanh-saturation-fenv-head12826b49-linux-validation.tar.gz). SHA256 `496fc2f59831bb8ff5e71c3c9f288ea3fcbc8b4dac7e8c1baea56d333c583279`. Not tested: Windows, macOS, a physical console or unmasked floating-point exceptions. This is library correctness evidence; no title bring-up or FPS gain is established. <!-- OS, title or homebrew, what was checked. "Not tested" is a valid answer. A performance change: the summary lines of main and of this PR from the same machine and scene, with the traces attached, captured as the Performance report issue form describes. --> <!-- codex-math-refresh-20261028-repeat-pr10506 --> ### Current Linux qualification (2026-10-28) Rebased onto `main` `2227f1366188cda5699dd20e2e756a18006a5d4b`. Linux CPU validation on 2026-10-28 at `6a8a2372a3c3932e23dce46dd388cfe9b06aa87a` (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. ### Checklist <!-- Rules behind each item: https://github.com/boykopovar/AnyPS5/blob/main/CONTRIBUTING.md --> - [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 - [x] Generic behaviour, not specific to one title - [x] Depends on: none (#10316 merged at `cbee22480462`; present in audited main `3fea2a937ba`) - [x] Fixes: none <!-- issue it closes as Fixes #N, or none --> - [x] Unblocks: none <!-- title ID and Game bring-up discussion, e.g. PPSA01325 #3232, or none --> - [x] GPUs tested: n/a <!-- for AGC, shader recompiler or VideoOut changes: vendor, model, driver and OS of each GPU the GPU tests ran on; otherwise n/a --> - [x] AI-assisted: yes <!-- yes / no -->
MarcZX10 commented 2026-10-24 12:06:41 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-10-24T12:06:41Z.

Review: APPROVED


Reviewed exact head 12826b49859a22e3896b7ff6670152ea94d22397 against the pinned FreeBSD 11.4 s_tanh.c/s_expm1.c algorithms and the surrounding errno/floating-point handling. The saturation branch returns the signed exact unit value without an arithmetic operation, and the regression exercises both signs, four rounding modes, DAZ/FTZ combinations, sticky flags, infinities and maximum finite inputs. The author reports 64,512-call CPU differential comparisons and red/green test evidence; I did not reproduce that fixture locally. Hosted conventions, intake, eligibility, labels, report, register-context, relinker, write-watch and ASan checks pass. Full product Linux/Windows jobs were skipped by workflow selection, and no console run is claimed.

<!-- greyfinch-sync:boykopovar/AnyPS5:review:5638177916 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/10506#pullrequestreview-5638177916). Originally posted by [MarcZX10](https://github.com/MarcZX10) on 2026-10-24T12:06:41Z. **Review:** APPROVED --- Reviewed exact head `12826b49859a22e3896b7ff6670152ea94d22397` against the pinned FreeBSD 11.4 `s_tanh.c`/`s_expm1.c` algorithms and the surrounding errno/floating-point handling. The saturation branch returns the signed exact unit value without an arithmetic operation, and the regression exercises both signs, four rounding modes, DAZ/FTZ combinations, sticky flags, infinities and maximum finite inputs. The author reports 64,512-call CPU differential comparisons and red/green test evidence; I did not reproduce that fixture locally. Hosted conventions, intake, eligibility, labels, report, register-context, relinker, write-watch and ASan checks pass. Full product Linux/Windows jobs were skipped by workflow selection, and no console run is claimed.
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!10506
No description provided.