Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 26 Jun 2007 10:02:22 -0400
From:      Mike Meyer <mwm-keyword-freebsdhackers2.e313df@mired.org>
To:        "=?ISO-8859-1?Q?Zavam,_Vin=EDcius?=" <egypcio@gmail.com>
Cc:        freebsd-hackers@freebsd.org
Subject:   Re: CPUTYPE in general - was Re: Which CPUTYPE for a dualcore Xeon on AMD64
Message-ID:  <18049.7278.769858.788831@bhuda.mired.org>
In-Reply-To: <8b5ad0e10706260545u6ad0b0c6w209548293809e993@mail.gmail.com>
References:  <467EF0C1.1010609@optiksecurite.com> <ab581e310706250250m4ec2432fide67251d7bcad132@mail.gmail.com> <467FFF41.10204@math.missouri.edu> <20070625192308.GA14544@freebsd.org> <18048.12032.316862.338084@bhuda.mired.org> <468033A8.8060103@gmail.com> <4680895A.5060700@u.washington.edu> <18048.40555.876785.219568@bhuda.mired.org> <4680F1E3.1010306@u.washington.edu> <8b5ad0e10706260545u6ad0b0c6w209548293809e993@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
In <8b5ad0e10706260545u6ad0b0c6w209548293809e993@mail.gmail.com>, Zavam=
, Vin=EDcius <egypcio@gmail.com> typed:
> 2007/6/26, Garrett Cooper <youshi10@u.washington.edu>:
> > Mike Meyer wrote:
> > nowadays).
> > >>     Intel suggests using -march=3Dprescott (32-bit) and -march=3D=
nocona
> > >> (64-bit) with gcc on Core2Duo processors and equivalent Xeons.
> > >>
> > >
> > > Note that /usr/share/mk/sys.mk includes bsd.mk.cpu, which overrid=
es
> > > CPUTYPE if it's set to prescott or nocona. It turns nocona into
> > > prescott if you're building for i386 and prescott into nocona if
> > > you're building for amd64. So the correct answer to the question =
"Do I
> > > set CPUTYPE to nocona or prescott in /etc/make.conf=3F" would see=
m to be
> > > "It doesn't matter."
> > Hmmm... interesting.. Seems like a bit ambitious for bsd.mk.cpu, if=
 the user knows what they're doing.
> please correct me if I'm wrong, but gcc(1) can help us a bit also;
> http://www.freebsd.org/cgi/man.cgi=3Fquery=3Dgcc&sektion=3D1&format=3D=
html

Right. We actually discussed this, then wondered into the history of
the CPU cores. You start with misc/cpuid to get a list of features
your CPU has, then use the gcc man page to figure out which cputype
will use the most features of your CPU without trying to use features
which your CPU doesn't have.

> z.B.:
> "
> (...)
> prescott
>        Improved version of Intel Pentium4 CPU with MMX, SSE, SSE2 and=

>        SSE3 instruction set support.
>=20
> nocona
>        Improved version of Intel Pentium4 CPU with 64-bit extensions,=

>        MMX, SSE, SSE2 and SSE3 instruction set support.
>=20
>        (...)
> athlon-4, athlon-xp, athlon-mp
>        Improved AMD Athlon CPU with MMX, 3dNOW!, enhanced 3dNOW! and
>        full SSE instruction set support.
>=20
> k8, opteron, athlon64, athlon-fx
>        AMD K8 core based CPUs with x86-64 instruction set support.
>        (This supersets MMX, SSE, SSE2, 3dNOW!, enhanced 3dNOW! and
>        64-bit instruction set extensions.)
> (...)
> "

=09<mike

--=20
Mike Meyer <mwm@mired.org>=09=09http://www.mired.org/consulting.html
Independent Network/Unix/Perforce consultant, email for more informatio=
n.



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