Date: 08 May 2001 22:12:39 +0200 From: Peter Mutsaers <peter@mutsaers.com> To: Nuno Teixeira <nuno.mailinglists@pt-quorum.com> Cc: <freebsd-stable@FreeBSD.ORG> Subject: Re: CFLAGS Optimization Message-ID: <87wv7rmwg8.fsf@mutsaers.com> In-Reply-To: Nuno Teixeira's message of "Mon, 7 May 2001 23:36:31 %2B0100 (WEST)" References: <20010507230417.F508-100000@gateway.bogus>
next in thread | previous in thread | raw e-mail | index | archive | help
>> "Nuno" == Nuno Teixeira <nuno.mailinglists@pt-quorum.com> writes:
Nuno> I came from Linux and at that time I used CFLAGS to optimize
Nuno> general programs and linux kernel.
Nuno> For example:
Nuno> [i686]: CFLAGS='-O9 -funroll-loops -ffast-math
Nuno> -malign-double -mcpu=pentiumpro -march=pentiumpro
Nuno> -fomit-frame-pointer -fno-exceptions'
On an AMD Athlon (i686 like) I use in ætc/make.conf:
CFLAGS= -O2 -pipe -march=pentiumpro
and
# To compile just the kernel with special optimisations, you should use
# this instead of CFLAGS (which is not applicable to kernel builds anyway):
#
COPTFLAGS= -O2 -pipe -march=pentiumpro
-O2, according to man gcc, turns on all optimizations except those
that involve a space-speed tradeoff, such as
-funroll-loops. Especially for the kernel, the effect of that one
might be negative (cache memory is small and precious).
The correct -m... options are all implied by -march=pentiumpro
--
Peter Mutsaers | Dübendorf | UNIX - Live free or die
plm@gmx.li | Switzerland | Sent via FreeBSD 4.3-stable
To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-stable" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?87wv7rmwg8.fsf>
