From patchwork Mon Apr 30 21:00:50 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Uros Bizjak X-Patchwork-Id: 155954 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]) by ozlabs.org (Postfix) with SMTP id 49CF2B6F9D for ; Tue, 1 May 2012 07:01:10 +1000 (EST) Comment: DKIM? See http://www.dkim.org DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d=gcc.gnu.org; s=default; x=1336424470; h=Comment: DomainKey-Signature:Received:Received:Received:Received: MIME-Version:Received:Received:Date:Message-ID:Subject:From:To: Content-Type:Mailing-List:Precedence:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:Sender:Delivered-To; bh=5A7xJBS pNLQ52nemxfYVLaendXI=; b=wP4H1paDo2gqGQRTes1lTcK7seuNUtk8RdmdzsF d2m3Fg+AF22UiDVYF9R31I6NlHFbtp275BVVK/4pzyZcm0OIVY+bhVooFUMlLkur 2jrDduIdkJlrVZ1om9QajIa4Z+fe3fVe0cTZ9GmOxLq9SDd7iAoZogg+uwp390Gz Ri9k= Comment: DomainKeys? See http://antispam.yahoo.com/domainkeys DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=default; d=gcc.gnu.org; h=Received:Received:X-SWARE-Spam-Status:X-Spam-Check-By:Received:Received:MIME-Version:Received:Received:Date:Message-ID:Subject:From:To:Content-Type:Mailing-List:Precedence:List-Id:List-Unsubscribe:List-Archive:List-Post:List-Help:Sender:Delivered-To; b=ic0tLmPjbbIaZO5uD5NERVwCCCaFP2Twv/6CpSx+LO9nTO/p54Vuxk6IkgxHJQ KiGOaCfXECdENuD8mYeugDMBnTv5oh6tbAt0DCZpcCnEzZYzuUp9n8vYFxaPuWqy bZg02frso1zYF6B1h0mi0WlKdjziAJQOEgePkDV4S7xJU=; Received: (qmail 18058 invoked by alias); 30 Apr 2012 21:01:06 -0000 Received: (qmail 18047 invoked by uid 22791); 30 Apr 2012 21:01:05 -0000 X-SWARE-Spam-Status: No, hits=-4.1 required=5.0 tests=AWL, BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, FREEMAIL_FROM, KHOP_RCVD_TRUST, RCVD_IN_DNSWL_LOW, RCVD_IN_HOSTKARMA_YE, TW_ZJ X-Spam-Check-By: sourceware.org Received: from mail-gy0-f175.google.com (HELO mail-gy0-f175.google.com) (209.85.160.175) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Mon, 30 Apr 2012 21:00:51 +0000 Received: by ghbz2 with SMTP id z2so1769525ghb.20 for ; Mon, 30 Apr 2012 14:00:50 -0700 (PDT) MIME-Version: 1.0 Received: by 10.236.182.131 with SMTP id o3mr23704020yhm.113.1335819650499; Mon, 30 Apr 2012 14:00:50 -0700 (PDT) Received: by 10.146.124.5 with HTTP; Mon, 30 Apr 2012 14:00:50 -0700 (PDT) Date: Mon, 30 Apr 2012 23:00:50 +0200 Message-ID: Subject: [PATCH, i386]: Fix PR53141, gcc.target/i386/bmi2-mulx32-[12]a.c FAIL From: Uros Bizjak To: gcc-patches@gcc.gnu.org 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 Hello! On BMI2 targets, we prefer mulx, so switch places of constraints 0 and 1. 2012-04-30 Uros Bizjak PR target/53141 * config/i386/i386.md (*umul3_1): Switch places of constraints 0 and 1. Tested on x86_64-pc-linux-gnu {,-m32}, committed to mainline SVN. Uros. Index: config/i386/i386.md =================================================================== --- config/i386/i386.md (revision 186999) +++ config/i386/i386.md (working copy) @@ -6814,29 +6814,29 @@ (set_attr "mode" "SI")]) (define_insn "*umul3_1" - [(set (match_operand: 0 "register_operand" "=A,r") + [(set (match_operand: 0 "register_operand" "=r,A") (mult: (zero_extend: - (match_operand:DWIH 1 "nonimmediate_operand" "%0,d")) + (match_operand:DWIH 1 "nonimmediate_operand" "%d,0")) (zero_extend: (match_operand:DWIH 2 "nonimmediate_operand" "rm,rm")))) (clobber (reg:CC FLAGS_REG))] "!(MEM_P (operands[1]) && MEM_P (operands[2]))" "@ - mul{}\t%2 - #" - [(set_attr "isa" "*,bmi2") - (set_attr "type" "imul,imulx") - (set_attr "length_immediate" "0,*") + # + mul{}\t%2" + [(set_attr "isa" "bmi2,*") + (set_attr "type" "imulx,imul") + (set_attr "length_immediate" "*,0") (set (attr "athlon_decode") - (cond [(eq_attr "alternative" "0") + (cond [(eq_attr "alternative" "1") (if_then_else (eq_attr "cpu" "athlon") (const_string "vector") (const_string "double"))] (const_string "*"))) - (set_attr "amdfam10_decode" "double,*") - (set_attr "bdver1_decode" "direct,*") - (set_attr "prefix" "orig,vex") + (set_attr "amdfam10_decode" "*,double") + (set_attr "bdver1_decode" "*,direct") + (set_attr "prefix" "vex,orig") (set_attr "mode" "")]) ;; Convert mul to the mulx pattern to avoid flags dependency.