[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: CFLAGS ?



On Tue, Oct 15, 2002 at 08:53:59PM -0400, Robert L. Harris wrote:
> CFLAGS="-O -mcpu=k6"

If you're bothering to optimise, at least crank it up a little:)  Why
not -O2 or even -O3?

> My system is now an Intel P4.  Anyone know what would be "ideal" mcpu
> for a P4?

AFAIK, GCC 2.95.4 (the current default compiler in woody, sarge and sid)
doesn't know about anything past PentiumPro's, so I guess
-mcpu=pentiumpro would be the way to go.  Sid will switch to GCC 3.2
(which knows how to optimise for more recent chips) Real Soon Now(TM).
3.2 seems to optimise better even without the arch-specific options (or
so I've been told), so it'll be good to have around in general.

In the meantime, you could install GCC 3.2 and use it compile C programs
specially; read the documentation for how to optimise for P4s.
Compiling C++ programs with GCC 3.2, of course, won't work because the
C++ ABI has changed yet again, but you'll discover that if you try :)

-rob

Attachment: pgp2TGCrE_STh.pgp
Description: PGP signature


Reply to: