From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 23227 invoked by alias); 21 Dec 2009 20:12:23 -0000 Received: (qmail 23219 invoked by uid 22791); 21 Dec 2009 20:12:23 -0000 X-SWARE-Spam-Status: No, hits=-2.6 required=5.0 tests=AWL,BAYES_00 X-Spam-Check-By: sourceware.org Received: from caramon.arm.linux.org.uk (HELO caramon.arm.linux.org.uk) (78.32.30.218) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Mon, 21 Dec 2009 20:11:37 +0000 Received: from n2100.arm.linux.org.uk ([2002:4e20:1eda:1:214:fdff:fe10:4f86]) by caramon.arm.linux.org.uk with esmtpsa (TLSv1:AES256-SHA:256) (Exim 4.69) (envelope-from ) id 1NMoar-0003mW-Ih; Mon, 21 Dec 2009 20:11:02 +0000 Received: from linux by n2100.arm.linux.org.uk with local (Exim 4.69) (envelope-from ) id 1NMoap-0006gP-PA; Mon, 21 Dec 2009 20:10:59 +0000 Date: Mon, 21 Dec 2009 20:12:00 -0000 From: Russell King - ARM Linux To: Richard Henderson Cc: Richard Guenther , David Daney , "gcc@gcc.gnu.org" , Jamie Lokier , linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Uwe =?iso-8859-1?Q?Kleine-K=F6nig?= Subject: Re: [PATCH] ARM: Convert BUG() to use unreachable() Message-ID: <20091221201059.GD11669@n2100.arm.linux.org.uk> References: <1260266138-17684-1-git-send-email-u.kleine-koenig@pengutronix.de> <20091217150120.GD24967@shareable.org> <4B2A65C6.7080009@caviumnetworks.com> <84fc9c000912170917y4b2772d0n47bb4dabc74b91ef@mail.gmail.com> <20091217181718.GA4440@n2100.arm.linux.org.uk> <4B2FCCE3.1090209@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <4B2FCCE3.1090209@redhat.com> User-Agent: Mutt/1.5.18 (2008-05-17) Mailing-List: contact gcc-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-owner@gcc.gnu.org X-SW-Source: 2009-12/txt/msg00300.txt.bz2 On Mon, Dec 21, 2009 at 11:30:43AM -0800, Richard Henderson wrote: > On 12/17/2009 10:17 AM, Russell King - ARM Linux wrote: >> How is "size-optimal trap" defined? > > E.g. Sparc and MIPS have "tcc" instructions that trap based on the > condition codes, and so we eliminate the branch. That's the only > optimization we apply with __builtin_trap. > >> Let me put it another way: I want this function to terminate with an >> explicit NULL pointer dereference in every case. > > Then just use that. That's precisely what we have been using for many years.