From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from pigeon.gentoo.org ([69.77.167.62] helo=lists.gentoo.org) by finch.gentoo.org with esmtp (Exim 4.60) (envelope-from ) id 1LA2dc-0002VI-78 for garchives@archives.gentoo.org; Tue, 09 Dec 2008 13:28:32 +0000 Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 4890AE062B; Tue, 9 Dec 2008 13:28:28 +0000 (UTC) Received: from poseidon.rz.tu-clausthal.de (poseidon.rz.tu-clausthal.de [139.174.2.21]) by pigeon.gentoo.org (Postfix) with ESMTP id 17E1AE062B for ; Tue, 9 Dec 2008 13:28:28 +0000 (UTC) Received: from poseidon.rz.tu-clausthal.de (localhost [127.0.0.1]) by localhost (Postfix) with SMTP id 3C05321262E for ; Tue, 9 Dec 2008 14:28:27 +0100 (CET) Received: from tu-clausthal.de (poseidon [139.174.2.21]) by poseidon.rz.tu-clausthal.de (Postfix) with ESMTP id 2B6A7211C4B for ; Tue, 9 Dec 2008 14:28:27 +0100 (CET) Received: from [139.174.197.94] (account wevah HELO energy.localnet) by tu-clausthal.de (CommuniGate Pro SMTP 5.2.10) with ESMTPSA id 39463804 for gentoo-amd64@lists.gentoo.org; Tue, 09 Dec 2008 14:28:26 +0100 From: Volker Armin Hemmann To: gentoo-amd64@lists.gentoo.org Subject: Re: [gentoo-amd64] CFLAGS question from a AMD64 newbie Date: Tue, 9 Dec 2008 14:28:21 +0100 User-Agent: KMail/1.10.92 (Linux/2.6.27.8r4_ehci; KDE/4.1.82; x86_64; ; ) References: <200812091423.30562.sn.ml@keijukammari.fi> In-Reply-To: <200812091423.30562.sn.ml@keijukammari.fi> Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-amd64@lists.gentoo.org Reply-to: gentoo-amd64@lists.gentoo.org MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Message-Id: <200812091428.21434.volker.armin.hemmann@tu-clausthal.de> X-Virus-Scanned: by PureMessage V5.5 at tu-clausthal.de X-Archives-Salt: 3c7a1761-fc9c-4309-ada3-a1b22e6384fa X-Archives-Hash: 14ca125e1917830b61c3487c514bc4a1 On Dienstag 09 Dezember 2008, Sami N=E4=E4t=E4nen wrote: > So hi from a amd64 newbie. Not so newbie with Gentoo though. :) > > My system is an Intel quad core core2 with a 2.4 GHz clock speed coupled > with a 4GB of memory. No overclocking etc. Want this to be stable. :) > > I'm just curious what people use as their stable CFLAGS in amd64 Gentoo? > (Sorry if this has been up lately, but I just switched to 64bit env so...) > > > Here is mine and some explanation of why (And I use ~arch system with gcc > 4.3) > > The flags are in order they are used in my CFLAGS and CXXFLAGS. > > Gives stable base > -O2 yes > > Want to optimize for my system, but don't want "native" > -march=3Dcore2 ok > > If some ebuilds filter march this will still cache optimize etc for my > system -mtune=3Dcore2 I would scrap that. > > Faster floating point math and better chance of vectorization > -mfpmath=3Dsse superfluos. March with amd64 sse is used by default. > > These because of the march might get filtered > -mmmx -msse -msse2 -msse3 -mssse3 if march get filtered, these might one of the reasons, I would remove them. > > For loop vectorization > -ftree-vectorize scrap that. > -pipe > once upon a time I used this flags: #CFLAGS=3D"-march=3Dk8 -O2 -pipe -fweb -ftracer -fpeel-loops -msse3" and even #CFLAGS=3D"-march=3Dk8 -O2 -fweb -ftracer -fpeel-loops -ftree-vectorize -fr= ename- registers -floop-optimize2 -msse3 -pipe" to hunt down a java bug, I recompiled the whole system with: CFLAGS=3D"-march=3Dk8 -O2 -msse3 -pipe" and surprise - it was as fast as before - and compiling was faster too!