-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1
On 16.05.2014 15:20, Partha Bagchi wrote:
On Fri, May 16, 2014 at 7:03 AM, LRN wrote:
On 16.05.2014 14:44, Partha Bagchi wrote:
On Thu, May 15, 2014 at 5:56 PM, Johan Engelen wrote:
Hi all, Why do we build with -O2 instead of O3? We are missing out on: -O3: Optimize yet more. -O3 turns on all optimizations specified by -O2and also turns on the -finline-functions, -funswitch-loops, -fpredictive-commoning, -fgcse-after-reload, -ftree-loop-vectorize, -ftree-slp-vectorize, -fvect-cost-model, -ftree-partial-pre and -fipa-cp-clone options.
from a Windows (or Mac for that matter), I have built the dev libraries with the following flags: "-std=c++11 -O3 -ffast-math -ftree-vectorize"
By the way, this reminded me: you may be able to get better results by building with appropriate -march and -mtune options.
I am not sure you need mtune and march together. Also, how would this work if someone uses a Pentium 3 and you use AMD 64?
The same way it would work if someone uses an i686 OS, while you're using x86_64 OS - provide separate binaries.
As far as i've been told, the best results (optimization-wise) are achieved by "-march=the_oldest_supported_CPU -mtune=generic". Hence my suggestion.
- -- O< ascii ribbon - stop html email! - www.asciiribbon.org