This is the mail archive of the gcc-patches@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]

Re: [PATCH] Optimize abs(x) < 0.0


Richard Henderson <rth@redhat.com> writes:

| > 2) Even in the case where fabs(x)
| > may not cause a trap by itself, the expression
| > 
| >    fabs(x) < 0.0 
| > 
| > may because of the comparaison (SPARC V9 for example has mode to
| > trigger exception when comparing a signaling NaN against something).
| 
| We don't preserve signals anywere else in gcc (e.g. eliminated
| because the result is dead).  I don't see why we should start now.

Then, what does GCC return for fabs(x) when x is a signaling NaN?

-- Gaby


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