From patchwork Tue Aug 30 14:32:15 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andrew Stubbs X-Patchwork-Id: 3798 Return-Path: X-Original-To: patchwork@peony.canonical.com Delivered-To: patchwork@peony.canonical.com Received: from fiordland.canonical.com (fiordland.canonical.com [91.189.94.145]) by peony.canonical.com (Postfix) with ESMTP id A33D323F22 for ; Tue, 30 Aug 2011 14:32:20 +0000 (UTC) Received: from mail-ew0-f52.google.com (mail-ew0-f52.google.com [209.85.215.52]) by fiordland.canonical.com (Postfix) with ESMTP id 84D35A18266 for ; Tue, 30 Aug 2011 14:32:20 +0000 (UTC) Received: by ewy28 with SMTP id 28so4009468ewy.11 for ; Tue, 30 Aug 2011 07:32:20 -0700 (PDT) Received: by 10.223.24.21 with SMTP id t21mr9057751fab.24.1314714740322; Tue, 30 Aug 2011 07:32:20 -0700 (PDT) X-Forwarded-To: linaro-patchwork@canonical.com X-Forwarded-For: patch@linaro.org linaro-patchwork@canonical.com Delivered-To: patches@linaro.org Received: by 10.152.11.8 with SMTP id m8cs142223lab; Tue, 30 Aug 2011 07:32:19 -0700 (PDT) Received: by 10.216.195.212 with SMTP id p62mr5453334wen.30.1314714738918; Tue, 30 Aug 2011 07:32:18 -0700 (PDT) Received: from mail-wy0-f178.google.com (mail-wy0-f178.google.com [74.125.82.178]) by mx.google.com with ESMTPS id t73si13539310weq.79.2011.08.30.07.32.18 (version=TLSv1/SSLv3 cipher=OTHER); Tue, 30 Aug 2011 07:32:18 -0700 (PDT) Received-SPF: pass (google.com: domain of andrew.stubbs@gmail.com designates 74.125.82.178 as permitted sender) client-ip=74.125.82.178; Authentication-Results: mx.google.com; spf=pass (google.com: domain of andrew.stubbs@gmail.com designates 74.125.82.178 as permitted sender) smtp.mail=andrew.stubbs@gmail.com; dkim=pass (test mode) header.i=@gmail.com Received: by wyg19 with SMTP id 19so5770661wyg.37 for ; Tue, 30 Aug 2011 07:32:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=message-id:date:from:user-agent:mime-version:to:cc:subject :references:in-reply-to:content-type; bh=wE65G8KknW2wb3ry7vyMM8iw7LkbeVZRqph5GCqhJM8=; b=kfm+vdNJ4LJaQ4ia5aBfLQ9r2suifW92tv4Zcr2x0KRvXOZdkcSsySPTnabhqeNS9D amULTvd8aZdtgH0cqONZTbkrvPtYjdmlb07ji/FHHYuXlVhf3pYBg3qNK7q6/YUOxJNn at8giE/8zh+djPxKE4gg+dDh+OgtQzl9YtHkA= Received: by 10.216.37.198 with SMTP id y48mr787056wea.100.1314714738618; Tue, 30 Aug 2011 07:32:18 -0700 (PDT) Received: from [192.168.0.104] (cpc2-hawk4-0-0-cust828.aztw.cable.virginmedia.com [82.32.123.61]) by mx.google.com with ESMTPS id eo6sm1810807wbb.65.2011.08.30.07.32.16 (version=SSLv3 cipher=OTHER); Tue, 30 Aug 2011 07:32:17 -0700 (PDT) Message-ID: <4E5CF46F.5090809@codesourcery.com> Date: Tue, 30 Aug 2011 15:32:15 +0100 From: Andrew Stubbs User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:6.0) Gecko/20110812 Thunderbird/6.0 MIME-Version: 1.0 To: gcc-patches@gcc.gnu.org CC: Richard Earnshaw , patches@linaro.org Subject: Re: [PATCH][ARM] Thumb2 replicated constants References: <4DB013B7.4090504@codesourcery.com> <1304677098.5165.7.camel@e102346-lin.cambridge.arm.com> <4DC814EA.4070608@codesourcery.com> <4E576F60.2000100@codesourcery.com> In-Reply-To: <4E576F60.2000100@codesourcery.com> On 26/08/11 11:03, Andrew Stubbs wrote: > There was a bug I found in final testing, so this has been delayed > somewhat. > > I've just committed this version. There are a few minor changes to the > way negative/inverted constants are generated. Bernd found another bug whist testing for arm. Apparently there was a bug that didn't show up in my thumb tests, although I have no clue why? Anyway, fixed thusly and committed as obvious (and urgent). Andrew 2011-08-30 Andrew Stubbs gcc/ * config/arm/arm.c (arm_gen_constant): Set can_negate correctly when code is SET. --- a/gcc/config/arm/arm.c +++ b/gcc/config/arm/arm.c @@ -3367,8 +3367,8 @@ arm_gen_constant (enum rtx_code code, enum machine_mode mode, rtx cond, if (code == SET) { + can_negate = can_invert; can_invert = 0; - can_negate = 1; code = PLUS; } else if (code == MINUS)