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, wolfgang dot bangerth at iwr dot uni-heidelberg dot de
*Subject*: Re: What is acceptable for -ffast-math? A numerical viewpoint
*From*: dewar at gnat dot com
*Date*: Wed, 1 Aug 2001 09:27:17 -0400 (EDT)
*Cc*: gcc at gcc dot gnu dot org

<<LWell, 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.
>>
That's probably true in some cases, but most certainly NOT true in the case
of carefully constructed numerical codes, which depend on careful analysis
assuming the expected computational model.
Whether fast-math is acceptable in such cases depends on what it implements.
There is no point in being other than conservative with transformations in
the absence of any demonstration of any value of a transformation.