From owner-freebsd-questions@FreeBSD.ORG Wed Jan 31 16:59:10 2007 Return-Path: X-Original-To: freebsd-questions@freebsd.org Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id CCF2416A40A for ; Wed, 31 Jan 2007 16:59:10 +0000 (UTC) (envelope-from almarrie@gmail.com) Received: from an-out-0708.google.com (an-out-0708.google.com [209.85.132.250]) by mx1.freebsd.org (Postfix) with ESMTP id 9066313C4A8 for ; Wed, 31 Jan 2007 16:59:10 +0000 (UTC) (envelope-from almarrie@gmail.com) Received: by an-out-0708.google.com with SMTP id c24so139148ana for ; Wed, 31 Jan 2007 08:59:10 -0800 (PST) DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=Efg5tRvOvuk1nT4SDIBfXuegqFpts0sAhpdBQOvMT5dzMN6tLQmlYL147PQm/I8ITtWoRV2laLXoJhj0r/JgMo2/6HR9lJBODfoOmC1LiaUdSY5wqx56Gu9b/QISRHrQX8GaKnzTigIOTEMj2VE5AowXDil+lQNYlF17iru6420= Received: by 10.114.111.1 with SMTP id j1mr65932wac.1170262749233; Wed, 31 Jan 2007 08:59:09 -0800 (PST) Received: by 10.115.91.7 with HTTP; Wed, 31 Jan 2007 08:59:09 -0800 (PST) Message-ID: <499c70c0701310859g6bfca627t794e8b6a5580820c@mail.gmail.com> Date: Wed, 31 Jan 2007 16:59:09 +0000 From: "Abdullah Ibn Hamad Al-Marri" To: "Jorn Argelo" In-Reply-To: <209e855bb68d64550ec4e384b3983664@mail.wcborstel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <200701312340.38593.salkillen@internode.on.net> <209e855bb68d64550ec4e384b3983664@mail.wcborstel.com> Cc: Scott Killen , freebsd-questions@freebsd.org Subject: Re: gcc compiler cputype, prescott or nocona confusion X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 31 Jan 2007 16:59:10 -0000 On 1/31/07, Jorn Argelo wrote: > > > On Wed, 31 Jan 2007 23:40:38 +1100, Scott Killen wrote: > > Hi, > > > > When recompiling the world or kernel in FreeBSD i386 Rel 6.1 with, > > > > "# make buildworld" > > or > > "# make buildkernel KERNCONF=MYSMPCONF" > > > > (or building anything anything else for that matter), even though I have > > "CPUTYPE?=nocona" set in my "/etc/make.conf" file the compiler seems to > > head > > back to a default of "-march=prescott" when compiling many of the > > functions > > on a Dual Xeon 3.6g (nocona) machine! > > > > This doesn't happen when compiling for other machine types, I've tried it > > on a > > Dual PentiumPro, Dual PII, Dual PIII setting the CPUTYPE to the correct > > cpu > > type and the -march sticks to the assigned cpu type through all operations > > and produces nice quick optimized code. > > > > Why is this so? > > > > Is it because the "nocona" machine type optimization refers to the EMT64 > > technology and thus is rejected when compiling for i386 targets rather > > than > > amd64 or emt64 targets and Gcc rejects it? > > That's right. AFAIK the Nocona core is a prescott with EM64T support (feel free to correct me if I am wrong). Basically you have an i386 version of FreeBSD, and with EM64T instructions enabled GCC will build a 64-bit version of FreeBSD. I think that's the reason it switches back to prescott. > > Jorn > > > > > Regards > > Scott K For the record I used "nocona" with my dual xeon emt64 2.8 GHz and it broke my kernel. -- Regards, -Abdullah Ibn Hamad Al-Marri Arab Portal http://www.WeArab.Net/