This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug middle-end/85811] Invalid optimization with fmax, fabs and nan


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=85811

--- Comment #9 from rguenther at suse dot de <rguenther at suse dot de> ---
On Thu, 17 May 2018, schwab@linux-m68k.org wrote:

> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=85811
> 
> --- Comment #8 from Andreas Schwab <schwab@linux-m68k.org> ---
> > Is there sth like -NaN?!
> 
> signbit can tell you.

True.  I guess that also asks for the guarantee on the operand
for tree_single_nonnegative_warnv_p returning true.  Does it
guarantee that OP >= 0 compares as true?  Or merely !(OP < 0)?
So does it make sense for the function to return true for +NaN
or should we err on the side of caution and not do that?

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]