Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 15 Jan 2004 11:24:54 -0500
From:      John Baldwin <jhb@FreeBSD.org>
To:        Kris Kennaway <kris@obsecurity.org>, Christer Solskogen <solskogen@carebears.mine.nu>
Cc:        chat@freebsd.org
Subject:   Re: CFLAGS and such
Message-ID:  <200401151124.56182.jhb@FreeBSD.org>
In-Reply-To: <20040115154105.GA13188@xor.obsecurity.org>
References:  <2303.148.121.98.106.1074172159.squirrel@mail.carebears.mine.nu> <20040115154105.GA13188@xor.obsecurity.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On Thursday 15 January 2004 10:41 am, Kris Kennaway wrote:
> On Thu, Jan 15, 2004 at 02:09:19PM +0100, Christer Solskogen wrote:
> > When a release('make release' og TIER) is made, is there some kind of
> > optimization using CPUTYPE or CFLAGS?
> > If yes, what? If no, why?
>
> CFLAGS has the default value of "-O -pipe".  Further
> (e.g. CPU-specific) optimizations are not used by default, because
> FreeBSD releases are required to work on anything down to a 386 (5.x
> kernels excepted).

Incorrect.  We use -mcpu=pentiumpro which optimizes the code flow for a PII or 
later, but still only uses i386 instructions.  Thus, we do optimize for more 
recent CPUs while still generating code that will run on all CPUs.  Check the 
gcc info pages for the difference between -march and -mcpu on i386 and -mcpu 
and -mtune on all other archs.

-- 
John Baldwin <jhb@FreeBSD.org>  <><  http://www.FreeBSD.org/~jhb/
"Power Users Use the Power to Serve"  =  http://www.FreeBSD.org



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200401151124.56182.jhb>