You are not logged in.
Code compiled -O3 has better performance in the processor core, but its installed size on the hard drive is much larger than -O or -O2 optimized code. Given that hard drives don't have the same throughput as a standard RAM to CPU bus has, the hard drive becomes the benefactor of the memory "bottleneck" described here.
This factor is likely negligible, due to the fact that many things are left in memory, is likely will not need to be so again. Compiling with -O3 will introduce a higher disk-access cost, but it will likely be more of a one-time penalty than a consistent penalty.
Not seen benchmarks, but that'd be my guess. I'd take -O3 over -Os for almost any application. GCC gurus feel free to correct me.
Last edited by B-Con (2008-06-26 01:52:28)
Offline