This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: Sine and Cosine Accuracy
- From: Scott Robert Ladd <scott dot ladd at coyotegulch dot com>
- To: Dave Korn <dave dot korn at artimi dot com>
- Cc: 'Morten Welinder' <mwelinder at gmail dot com>, gcc at gcc dot gnu dot org
- Date: Thu, 26 May 2005 14:09:00 -0400
- Subject: Re: Sine and Cosine Accuracy
- References: <SERRANOVWDKpzxDPHpr0000017f@SERRANO.CAM.ARTIMI.COM>
Dave Korn wrote:
> Well, as long as they're under the control of a flag that also makes it
> clear that they are *also* unsafe math optimisations, I wouldn't object.
But they are *not* unsafe for *all* applications.
An ignorant user may not understand the ramifications of "unsafe" math
-- however, the current documentation is quite vague as to why these
optimizations are unsafe, and people thus become paranoid and avoid
-ffast-math when it would be to their benefit.
First and foremost, GCC should conform to standards. *However*, I see
nothing wrong with providing additional capability for those who need
it, without combining everything "unsafe" under one umbrella.
> But you can't just replace a call to the ANSI C 'sin' function with an
> invocation of the x87 fsin intrinsic, because they aren't the same, and the
> intrinsic is non-ansi-compliant.
Nobody said they were.
..Scott