Compiler optimizations
bearophile
bearophileHUGS at lycos.com
Fri Dec 19 18:03:15 PST 2008
Walter Bright:
> The reason the optimizer doesn't replace floating divides with floating
> multiplies of the reciprocal is that one gets slightly different answers
> (due to roundoff).
Right. Because FP numbers are just approximations of the Real field. GCC has command line arguments (like -ffast-math -funsafe-math-optimizations and others) that force similar unsafe optimizations.
Bye,
bearophile
More information about the Digitalmars-d
mailing list