This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: GCC beaten by ICC in stupid trig test!
On Mon, 15 Mar 2004, Paolo Carlini wrote:
> Now, I have another question: when -ffast-math is passed, should we even
> collapse
> the loop to a single integer to be multiplied by the return value of doit?
I don't know whether this will occur in real code (and so whether it is
worth doing), but replacing repeated addition with multiplication seems
like the sort of thing -ffast-math can do. (The default for the
FP_CONTRACT pragma is implementation-defined, but that would only allow
contraction within a single expression, e.g. x+x+x+x --> 4*x, not in loops
like this.)
--
Joseph S. Myers
jsm@polyomino.org.uk