[Bug 294214] clang builtin functions break libm
- In reply to: bugzilla-noreply_a_freebsd.org: "[Bug 294214] clang builtin functions break libm"
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Thu, 02 Apr 2026 20:27:31 UTC
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=294214
Robert Clausecker <fuz@FreeBSD.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |fuz@FreeBSD.org
--- Comment #1 from Robert Clausecker <fuz@FreeBSD.org> ---
This is the same story as memcmp(). The C standard does not specify whether +0
or -0 is returned if the two are passed to fmax() or fmin() and compilers will
optimise this.
We should instead document that our libm supports a stricter behaviour than
what
the C standard guarantees (as we did with memcmp()) and recommend that users
pass
-fno-builtin-fmax and -fno-builtin-fmin or use one of the new C23 functions if
they wish to have the stricter behaviour guaranteed.
--
You are receiving this mail because:
You are the assignee for the bug.