[Bug c/112449] Arithmetic operations can produce signaling NaNs
vincent-gcc at vinc17 dot net
gcc-bugzilla@gcc.gnu.org
Tue Jun 2 21:01:21 GMT 2026
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=112449
--- Comment #17 from Vincent Lefèvre <vincent-gcc at vinc17 dot net> ---
(In reply to Joseph S. Myers from comment #15)
> In the absence of -fsignaling-nans, signaling NaN representations are
> non-value representations (formerly known as trap representations) and not
> considered to represent any valid value of their type.
Note that before ISO C23, signaling NaNs were out of scope of ISO C and
considering them as non-value representations was conforming. With ISO C23 (and
support of Annex F), this is no longer the case.
> "treated as an ISO/IEC 60559 quiet NaN" goes both ways
> (for results as well as operands).
I doubt that this is the intent. This would mean that now, an implementation
would be allowed to create signaling NaNs while signaling NaNs do not appear as
operands. This would be a major regression.
More information about the Gcc-bugs
mailing list