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

# Re: What is acceptable for -ffast-math? A numerical viewpoint

*To*: dewar at gnat dot com
*Subject*: Re: What is acceptable for -ffast-math? A numerical viewpoint
*From*: Wolfgang Bangerth <wolfgang dot bangerth at iwr dot uni-heidelberg dot de>
*Date*: Wed, 1 Aug 2001 15:25:45 +0200 (MET DST)
*cc*: gcc at gcc dot gnu dot org, wolfgang dot bangerth at iwr dot uni-heidelberg dot de

On Wed, 1 Aug 2001 dewar@gnat.com wrote:
> <<So, concluding: if you have programs that run for several days, you'd be
> happy if you could cut that time by some hours using optimizations that
> >>
>
> The idea that these optimizations can save time of this magnitude is without
> evidentiary foundation.
An n% increase in speed makes n hours on a 4-day run. But then you're
right that it is probably not worth the effort to implement optimizations
that get you 1 or 2 per cent. If it's 10%, it starts getting interesting.
> In the case where the result is also degraded, the burden is
> greater.
Well, the claim was that the result is not _degraded_, but just _altered_.
Solving a linear system of equations with IEEE is just one way to get at
an approximate of the true inverse. It would be interesting to see whether
the residual || A * A^-1 || is smaller if you compute an approximate
inverse A^-1 using IEEE or -fast-math, using the same algorithm. I'd claim
it does not make much of a difference.
Regards
Wolfgang
-------------------------------------------------------------------------
Wolfgang Bangerth email: wolfgang.bangerth@iwr.uni-heidelberg.de
www: http://gaia.iwr.uni-heidelberg.de/~wolf