From owner-freebsd-toolchain@FreeBSD.ORG Tue Nov 8 07:55:39 2011 Return-Path: Delivered-To: freebsd-toolchain@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id F257D106566B; Tue, 8 Nov 2011 07:55:39 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from tensor.andric.com (cl-327.ede-01.nl.sixxs.net [IPv6:2001:7b8:2ff:146::2]) by mx1.freebsd.org (Postfix) with ESMTP id B6E0E8FC14; Tue, 8 Nov 2011 07:55:39 +0000 (UTC) Received: from [IPv6:2001:7b8:3a7:0:e5f2:b2e3:287d:70bb] (unknown [IPv6:2001:7b8:3a7:0:e5f2:b2e3:287d:70bb]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (No client certificate requested) by tensor.andric.com (Postfix) with ESMTPSA id 0530D5C59; Tue, 8 Nov 2011 08:55:37 +0100 (CET) Message-ID: <4EB8E07B.5070908@FreeBSD.org> Date: Tue, 08 Nov 2011 08:55:39 +0100 From: Dimitry Andric Organization: The FreeBSD Project User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:8.0) Gecko/20111031 Thunderbird/8.0 MIME-Version: 1.0 To: Alexander Best References: <20111108002556.GA91218@freebsd.org> In-Reply-To: <20111108002556.GA91218@freebsd.org> X-Enigmail-Version: 1.3.3 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: freebsd-toolchain@freebsd.org Subject: Re: CPUTYPE=native handling X-BeenThere: freebsd-toolchain@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Maintenance of FreeBSD's integrated toolchain List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 08 Nov 2011 07:55:40 -0000 On 2011-11-08 01:25, Alexander Best wrote: > i've seen dozens of issues, where people set CPUTYPE=native. although this > works in a lot of cases, it doesn't in others. why don't we simply add > something like > > . if ${CPUTYPE} == "native" > . error "bla" > . endif > > in share/mk/bsd.cpu.mk for now? or at least for the archs, where "native" is > known to cause problems. What does this solve? Don't you think it is better to try to fix the actual problems? Some people like being able to optimize for their specific CPU, however much you can shoot yourself in the foot with it. I haven't seen any consistent bug reports yet, just a lot of complaints that indicate a rather high probability of PEBKAC. And just to counter the nay-saying, I compiled a number of boxes with clang -march=native (mostly of the Xeon/i7 variant) and I haven't seen any problems at all.