Re: Optimizer flags?

Rob Byrnes <[email protected]> Mon, 06 May 2002 15:45:44 +1000
Newsgroups gmane.linux.suse.axp
Message-ID <[email protected]>
At 03:16 4/05/2002, Rikard "DustPuppy" Johnels sent this up the stick:
>Hi all!
>I am building a "linux From Scratch" on my AlphaStation 255
>
>What flags shall i set for GCC to be as fast and small as possible?

I use the following:

CFLAGS="-O2 -march=ev56 -funroll-loops -fforce-mem -fforce-addr 
-malign-double -fno-exceptions"

You will need to adjust the -march flag for your particular processor.

I have seen warnings that high optimisations (-O3 and above) break code on 
the Alpha, but gcc3.x may have changed that.  Remember that fast does not 
mean small, higher optimisations will _increase_ the compiled code size.

Cheers,
Rob