Page MenuHomePhabricator

[FPEnv] Remove inaccurate comments regarding signaling NaN for isless
ClosedPublic

Authored by eopXD on Wed, Sep 21, 7:22 PM.

Details

Summary

By draft of C23 (https://www.open-std.org/jtc1/sc22/wg14/www/docs/n2912.pdf),
the description for isless macro under 7.12.17.3 says,

The isless macro determines whether its first argument is less than its second
argument. The value of isless(x,y) is always equal to (x)< (y); however, unlike
(x) < (y), isless(x,y) does not raise the invalid floating-point exception when
x and y are unordered and neither is a signaling NaN.

isless should trap when encountering signaling NaN.

Diff Detail

Event Timeline

eopXD created this revision.Wed, Sep 21, 7:22 PM
Herald added a project: Restricted Project. · View Herald TranscriptWed, Sep 21, 7:22 PM
eopXD requested review of this revision.Wed, Sep 21, 7:22 PM
Herald added a project: Restricted Project. · View Herald TranscriptWed, Sep 21, 7:22 PM
Herald added a subscriber: cfe-commits. · View Herald Transcript
jcranmer-intel accepted this revision.Thu, Sep 22, 12:13 PM

This looks fine to me, but as clang is not normally my wheelhouse, I'd still prefer to see someone else approve this as well.

This revision is now accepted and ready to land.Thu, Sep 22, 12:13 PM
This revision was landed with ongoing or failed builds.Thu, Sep 22, 6:13 PM
This revision was automatically updated to reflect the committed changes.