From patchwork Thu May 15 08:47:07 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kyrylo Tkachov X-Patchwork-Id: 349098 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)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 8A9F51400DA for ; Thu, 15 May 2014 18:47:20 +1000 (EST) DomainKey-Signature: a=rsa-sha1; c=nofws; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender :message-id:date:from:mime-version:to:cc:subject:content-type; q=dns; s=default; b=ok0wVnvEs1FgDPfqyDmi0kRGzbYDdWTKRrHT1PEzl9C G4dPjz79kX6/yr0V4vjFr0/bYzZH5pH2iS2SAN+QgMC3Mrrboh6Gc6xUynCt7RXy I5JkLE0REszxv/cvk3ah1SvWMiyQO2XWrB7I/9nyxRhXflfqr057AoSLAsqVv8Ss = 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 :message-id:date:from:mime-version:to:cc:subject:content-type; s=default; bh=Hv09jc9R0NkioV09UzQxN3AZA4c=; b=LV91Qgo9V7l1EMSwA +BNgXXD7ZZpstiYwHZI8+4JC0b7lOap3FoJuA5NrRNUoez3L5dmjJIGAx/z8cHaw L9cBcQTVyFf1Dra0Xref1AoHWWPdiGQUme3YLfEO6FxJ94mscDYGDpM70pTGstIV 7if8a4qZNA12m31Gee2Qvb32hU= Received: (qmail 8605 invoked by alias); 15 May 2014 08:47:13 -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 8590 invoked by uid 89); 15 May 2014 08:47:12 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.1 required=5.0 tests=AWL, BAYES_00, RCVD_IN_DNSWL_LOW, SPF_PASS autolearn=ham version=3.3.2 X-HELO: service87.mimecast.com Received: from service87.mimecast.com (HELO service87.mimecast.com) (91.220.42.44) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Thu, 15 May 2014 08:47:10 +0000 Received: from cam-owa2.Emea.Arm.com (fw-tnat.cambridge.arm.com [217.140.96.21]) by service87.mimecast.com; Thu, 15 May 2014 09:47:07 +0100 Received: from [10.1.208.24] ([10.1.255.212]) by cam-owa2.Emea.Arm.com with Microsoft SMTPSVC(6.0.3790.3959); Thu, 15 May 2014 09:47:16 +0100 Message-ID: <53747F0B.2060107@arm.com> Date: Thu, 15 May 2014 09:47:07 +0100 From: Kyrill Tkachov User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130804 Thunderbird/17.0.8 MIME-Version: 1.0 To: GCC Patches CC: Ramana Radhakrishnan , Richard Earnshaw Subject: [PATCH][ARM] Adjust arith_shiftsi for ARMv8-style X-MC-Unique: 114051509470704201 X-IsSubscribed: yes Hi all, Shifted arithmetic operations can never be encoded in 16-bits in and therefore can not appear in Thumb2 IT blocks under ARMv8-A rules (and the -mrestrict-it rules). This patch adjusts the relevant pattern for that purpose. Tested and bootstrapped on arm-none-linux-gnueabihf and made sure no performance regressions on a number of benchmarks. This is a bug (not wrong-code though) in -mrestrict-it that affects 4.9 as well as trunk, so is it ok to backport it there? Thanks, Kyrill 2014-05-15 Kyrylo Tkachov * config/arm/arm.md (arith_shiftsi): Do not predicate for arm_restrict_it. commit 8d54d43e84925ee5c53e70ecc7036bc5a7e867ba Author: Kyrylo Tkachov Date: Fri Apr 4 16:10:39 2014 +0100 [ARM] Adjust arith_shiftsi for arm_restrict_it diff --git a/gcc/config/arm/arm.md b/gcc/config/arm/arm.md index 38ca058..9468c70 100644 --- a/gcc/config/arm/arm.md +++ b/gcc/config/arm/arm.md @@ -9860,6 +9860,7 @@ "TARGET_32BIT" "%i1%?\\t%0, %2, %4%S3" [(set_attr "predicable" "yes") + (set_attr "predicable_short_it" "no") (set_attr "shift" "4") (set_attr "arch" "a,t2,t2,a") ;; Thumb2 doesn't allow the stack pointer to be used for