From owner-freebsd-arch@FreeBSD.ORG Tue Oct 9 02:34:14 2007 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 2A0BD16A41A for ; Tue, 9 Oct 2007 02:34:14 +0000 (UTC) (envelope-from brde@optusnet.com.au) Received: from mail35.syd.optusnet.com.au (mail35.syd.optusnet.com.au [211.29.133.51]) by mx1.freebsd.org (Postfix) with ESMTP id A5E6F13C47E for ; Tue, 9 Oct 2007 02:34:13 +0000 (UTC) (envelope-from brde@optusnet.com.au) Received: from besplex.bde.org (c220-239-235-248.carlnfd3.nsw.optusnet.com.au [220.239.235.248]) by mail35.syd.optusnet.com.au (8.13.1/8.13.1) with ESMTP id l992XurJ012893 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Tue, 9 Oct 2007 12:33:59 +1000 Date: Tue, 9 Oct 2007 12:33:56 +1000 (EST) From: Bruce Evans X-X-Sender: bde@besplex.bde.org To: d@delphij.net In-Reply-To: <470ACEA1.3030309@delphij.net> Message-ID: <20071009122751.X54949@besplex.bde.org> References: <470ACEA1.3030309@delphij.net> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Cc: freebsd-arch@freebsd.org Subject: Re: Why we optimize by time by default for < -O2 case? X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 09 Oct 2007 02:34:14 -0000 On Mon, 8 Oct 2007, LI Xin wrote: > I wonder why we want to optimize by time by default and not by space by > default for the system compiler, does the reasoning still hold true? -O means optimize for time if possible. > The commit log said: > > Modified files: > contrib/gcc toplev.c > Log: > Clarify revision 1.14: > Gcc 3.1's -O0 and -O1 actually optimized alignment for space, but we feel > it should optimize alignment for time like Gcc 2.95 used to. Optimization > for space should give 1-byte alignment on i386's, but doesn't quite. > > Revision Changes Path > 1.15 +0 -0 src/contrib/gcc/toplev.c Without this change, -O pessimizes for time. Bruce