public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/60237] New: isnan fails with -ffast-math
@ 2014-02-17 10:41 nathanael.schaeffer at gmail dot com
  2014-02-17 10:53 ` [Bug c++/60237] " jakub at gcc dot gnu.org
                   ` (6 more replies)
  0 siblings, 7 replies; 8+ messages in thread
From: nathanael.schaeffer at gmail dot com @ 2014-02-17 10:41 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60237

            Bug ID: 60237
           Summary: isnan fails with -ffast-math
           Product: gcc
           Version: 4.8.1
            Status: UNCONFIRMED
          Severity: major
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: nathanael.schaeffer at gmail dot com

With -ffast-math, isnan should return true if passed a NaN value.
Otherwise, how is isnan different than (x!=x) ?

isnan worked as expected with gcc 4.7, but does not with 4.8.1 and 4.8.2

How can I check if x is a NaN in a portable way (not presuming any compilation
option) ?


^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2014-02-17 17:28 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-02-17 10:41 [Bug c++/60237] New: isnan fails with -ffast-math nathanael.schaeffer at gmail dot com
2014-02-17 10:53 ` [Bug c++/60237] " jakub at gcc dot gnu.org
2014-02-17 11:16 ` nathanael.schaeffer at gmail dot com
2014-02-17 11:26 ` glisse at gcc dot gnu.org
2014-02-17 11:38 ` nathanael.schaeffer at gmail dot com
2014-02-17 12:46 ` rguenth at gcc dot gnu.org
2014-02-17 16:16 ` nathanael.schaeffer at gmail dot com
2014-02-17 17:28 ` glisse at gcc dot gnu.org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).