From patchwork Wed Nov 20 09:22:20 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yvan Roux X-Patchwork-Id: 292696 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id 20AD32C00C8 for ; Wed, 20 Nov 2013 20:22:40 +1100 (EST) DomainKey-Signature: a=rsa-sha1; c=nofws; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender :mime-version:in-reply-to:references:date:message-id:subject :from:to:cc:content-type; q=dns; s=default; b=l+HHM0EV4TJ3EE2EmL /GzBLitxTefVgCfVUfJrHGITRX8imnnvKidKPUQrBNEfvxsartOC5N3qybRJp4wM PASCRWFYKaJNtnqTHBBNNarnu4xJm2xZUkEXf3lk7p1Thju6xa/Y6Gj4BA293eM9 W8cKQZzmwjzRYJABST5WXIg80= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender :mime-version:in-reply-to:references:date:message-id:subject :from:to:cc:content-type; s=default; bh=BfBMOg64o6VfV05VZUYUJ+3F qJA=; b=iKftLwSHcnbB2gqTmFE0S0V0N955vdVix6t7xgWuyUummsLVceDFJa71 +pfMPV7E2TXLnWhZm/xmsAjNXCqVRRK2neS4NzvyTbQOPCfFt/Jth6laqa6OwlVw DHw2Ha0mUTnmBVY7x34Ko8vrQbe8igCPl/zBghhzXgI8V6TFrPo= Received: (qmail 6118 invoked by alias); 20 Nov 2013 09:22:31 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org Received: (qmail 6081 invoked by uid 89); 20 Nov 2013 09:22:30 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=0.9 required=5.0 tests=AWL, BAYES_50, RDNS_NONE, SPF_PASS, URIBL_BLOCKED autolearn=no version=3.3.2 X-HELO: mail-we0-f169.google.com Received: from Unknown (HELO mail-we0-f169.google.com) (74.125.82.169) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES128-SHA encrypted) ESMTPS; Wed, 20 Nov 2013 09:22:29 +0000 Received: by mail-we0-f169.google.com with SMTP id t60so3972460wes.28 for ; Wed, 20 Nov 2013 01:22:20 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=ySn04sBNFwpIuRgluIJan2rWP/JOMbH0Rm49jGUe8qo=; b=J9FQ2MpJymmPS6qX3BkiTeQDnt4R8Z4ZXgNg0fUwNxLnvb57trsSsfYI8Hd5kwquID PddJnt06nfzlSQmT5PR4KEChj3p25aOyTfo2t/ga+p0pMJ1R3HAiFIlDeiG6uguGPtiG mx7qrVBdM9lcC02sCdw/MTZi005BZC+7hrWB6Jlrum+TgWJG7WvEWWvT0hqpT2fDW/fy 1dnc3a5zHTbWyuBOejKK1Y3XGXK64OFQscC+RWBzTo09Qu7dteJNoUBT+b/60FMwxWZU zEeL3fOf1Uk6BEkwAHEt4XhhsPysnJRWdDqh8eHrb/3InpuMlQXx8PXxmxNtZgxWPMdV WW4A== X-Gm-Message-State: ALoCoQloaKyQRKOpAo0a26UL2V/Q3tBGUhW9uwShoYk720JcfWlc8d4A++PVVg2BCsklX1Xq2hPC MIME-Version: 1.0 X-Received: by 10.180.184.112 with SMTP id et16mr474547wic.4.1384939340460; Wed, 20 Nov 2013 01:22:20 -0800 (PST) Received: by 10.217.92.194 with HTTP; Wed, 20 Nov 2013 01:22:20 -0800 (PST) In-Reply-To: <7C7B53E4-4C82-4310-AEA2-8676023C96AF@buzzard.freeserve.co.uk> References: <52712245.1090509@redhat.com> <7C7B53E4-4C82-4310-AEA2-8676023C96AF@buzzard.freeserve.co.uk> Date: Wed, 20 Nov 2013 10:22:20 +0100 Message-ID: Subject: Re: RFA: patch to fix PR58785 (an ARM LRA crash) From: Yvan Roux To: Richard Earnshaw Cc: Vladimir Makarov , GCC Patches , Patch Tracking X-IsSubscribed: yes Hi, as Richard said, only a subset of rclass is allowed to be returned by preferred_reload_class. I've tested the attached patched in Thumb mode, on ARMv5, A9 and A9hf and on cross A15 without regression. Yvan 2013-11-20 Yvan Roux PR target/58785 * config/arm/arm.c (arm_preferred_reload_class): Only return LO_REGS when rclass is GENERAL_REGS. diff --git a/gcc/config/arm/arm.c b/gcc/config/arm/arm.c index 5c53440..63f10bd 100644 --- a/gcc/config/arm/arm.c +++ b/gcc/config/arm/arm.c @@ -6882,10 +6882,7 @@ arm_preferred_reload_class (rtx x ATTRIBUTE_UNUSED, reg_class_t rclass) return rclass; else { - if (rclass == GENERAL_REGS - || rclass == HI_REGS - || rclass == NO_REGS - || rclass == STACK_REG) + if (rclass == GENERAL_REGS) return LO_REGS; else return rclass;