GCC beaten by ICC in stupid trig test!
Paul Brook
paul@codesourcery.com
Wed Mar 24 20:57:00 GMT 2004
> IIUIC the fact that the + operator is specified in the standard as
> binding left-to-right imply that "a + b + c" with no brackets *has* to be
> interpreted as "(a + b) + c".
Specific examples of allowable transformations (taken directly from the f95
standard):
original written form-> allowable form
x+y -> y+x
-x+y -> y-x
x+y+z -> (x+y)+z
a+b-c -> a+(b-c)
x+y+z -> x+(y+z)
x*y+x*z -> x*(y+z)
a/b/c -> a/(b*c)
a/5.0 -> 0.2*a
However, the following transformation is not allowed:
a+(b-c)->(a+b)-c
Paul
More information about the Gcc
mailing list