From: Vladimir Prus (ghost_at_[hidden])
Date: 2007-07-11 07:59:16
On Wednesday 11 July 2007 15:32, Jos Hickson wrote:
> > > One thing I was wonder was why -O3 is the default as that is usually
> > > considered a bit risky?
> > Is it? I'm not aware of that.
> To quote from the Gentoo Linux "Safe CFLAGS" page
> (http://gentoo-wiki.com/Safe_Cflags) as an example:
> Note that -O2 is regarded as safer than "-O3", and "-O3" can often be
> a counter-productive attempt at optimization.
To quote from gcc manual:
Optimize yet more. -O3 turns on all optimizations specified by
-O2 and also turns on the -finline-functions,
-funswitch-loops and -fgcse-after-reload options.
Nothing here say that -03 enables any risky optimization.
Boost-Build list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk