From patchwork Mon Nov 12 05:34:39 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Gopalasubramanian, Ganesh" X-Patchwork-Id: 198319 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 2C09A2C0082 for ; Mon, 12 Nov 2012 16:35:08 +1100 (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=1353303309; h=Comment: DomainKey-Signature:Received:Received:Received:Received:Received: Received:Received:Received:Received:Received:Received:From:To:CC: Subject:Date:Message-ID:References:In-Reply-To:Content-Type: Content-Transfer-Encoding:MIME-Version:Mailing-List:Precedence: List-Id:List-Unsubscribe:List-Archive:List-Post:List-Help:Sender: Delivered-To; bh=A7OrBEXUfWFkckAo+hZS1ZWtpko=; b=QxoEldN1sgW4i5c I3bHaizzwYO+SNjTczlwGO1dlpwusezsZURoFBAnkmtUIm8SqmQzPhhAWFTnsyTn jQUSECJaSE9u2wSs3Hc6/pIkaYY+fKtFwBaAJHBIkAO5T1Q50PJ+ln6chIdGSMxp 1nQE0jJWhfFivAIUlV3M29eORRaY= 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:Received:X-Forefront-Antispam-Report:X-SpamScore:X-BigFish:Received:Received:Received:X-M-MSG:Received:Received:Received:From:To:CC:Subject:Date:Message-ID:References:In-Reply-To:Content-Type:Content-Transfer-Encoding:MIME-Version:X-OriginatorOrg:Mailing-List:Precedence:List-Id:List-Unsubscribe:List-Archive:List-Post:List-Help:Sender:Delivered-To; b=hqcg0ClHurqJHk7N60mr85IKK8IoWj04vSGUckrARawCIwmvUHLgScHC/jt9Wv e5P104VDwaqRs4u4/SCoHRIwjRHM3m5zkWW2lt5qYeWgDT7TT30vFk30/wKEi7Bq eURFemQ6C2NxA3jgWZTUBxuhRP3IiSeuqqjktwg8Qq0FM=; Received: (qmail 31452 invoked by alias); 12 Nov 2012 05:35:03 -0000 Received: (qmail 31199 invoked by uid 22791); 12 Nov 2012 05:35:01 -0000 X-SWARE-Spam-Status: No, hits=-4.8 required=5.0 tests=AWL, BAYES_00, KHOP_RCVD_UNTRUST, KHOP_THREADED, RCVD_IN_DNSWL_LOW, RCVD_IN_HOSTKARMA_NO, RCVD_IN_HOSTKARMA_W, RCVD_IN_HOSTKARMA_WL, TW_BD, TW_ZJ X-Spam-Check-By: sourceware.org Received: from ch1ehsobe004.messaging.microsoft.com (HELO ch1outboundpool.messaging.microsoft.com) (216.32.181.184) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Mon, 12 Nov 2012 05:34:55 +0000 Received: from mail243-ch1-R.bigfish.com (10.43.68.245) by CH1EHSOBE014.bigfish.com (10.43.70.64) with Microsoft SMTP Server id 14.1.225.23; Mon, 12 Nov 2012 05:34:52 +0000 Received: from mail243-ch1 (localhost [127.0.0.1]) by mail243-ch1-R.bigfish.com (Postfix) with ESMTP id 95B52E800AB; Mon, 12 Nov 2012 05:34:52 +0000 (UTC) X-Forefront-Antispam-Report: CIP:163.181.249.108; KIP:(null); UIP:(null); IPV:NLI; H:ausb3twp01.amd.com; RD:none; EFVD:NLI X-SpamScore: -5 X-BigFish: VPS-5(zz98dI9371I936eI542M1432Izz1de0h1202h1d1ah1d2ahz8dhz8275bh8275dhz2dh668h839h944hd25hf0ah1220h1288h12a5h12a9h12bdh137ah13b6h1441h14ddh1504h1537h153bh15d0l1155h) Received: from mail243-ch1 (localhost.localdomain [127.0.0.1]) by mail243-ch1 (MessageSwitch) id 1352698489850263_24411; Mon, 12 Nov 2012 05:34:49 +0000 (UTC) Received: from CH1EHSMHS002.bigfish.com (snatpool3.int.messaging.microsoft.com [10.43.68.229]) by mail243-ch1.bigfish.com (Postfix) with ESMTP id CD5D7FC0067; Mon, 12 Nov 2012 05:34:49 +0000 (UTC) Received: from ausb3twp01.amd.com (163.181.249.108) by CH1EHSMHS002.bigfish.com (10.43.70.2) with Microsoft SMTP Server id 14.1.225.23; Mon, 12 Nov 2012 05:34:45 +0000 X-M-MSG: Received: from sausexedgep02.amd.com (sausexedgep02-ext.amd.com [163.181.249.73]) (using TLSv1 with cipher AES128-SHA (128/128 bits)) (No client certificate requested) by ausb3twp01.amd.com (Axway MailGate 3.8.1) with ESMTP id 28DCC10280CC; Sun, 11 Nov 2012 23:34:40 -0600 (CST) Received: from SAUSEXDAG05.amd.com (163.181.55.6) by sausexedgep02.amd.com (163.181.36.59) with Microsoft SMTP Server (TLS) id 8.3.192.1; Sun, 11 Nov 2012 23:52:02 -0600 Received: from SAUSEXDAG06.amd.com ([fe80::cc99:d0a6:b4b:ef8b]) by sausexdag05.amd.com ([fe80::94d8:2d17:10c5:6039%20]) with mapi id 14.02.0318.004; Sun, 11 Nov 2012 23:34:40 -0600 From: "Gopalasubramanian, Ganesh" To: Uros Bizjak CC: "gcc-patches@gcc.gnu.org" Subject: RE: [PATCH, i386]: AMD bdver3 enablement Date: Mon, 12 Nov 2012 05:34:39 +0000 Message-ID: References: In-Reply-To: MIME-Version: 1.0 X-OriginatorOrg: amd.com 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 > You can see from the changes of sse.md that this is functionally a no-op change. Sseshuf replaces sselog. So, do you mean it should be added with sselog instead of sseadd? Adding it with sseadd (instead of sselog) influences the latency information. Regards Ganesh -----Original Message----- From: Uros Bizjak [mailto:ubizjak@gmail.com] Sent: Monday, November 12, 2012 2:30 AM To: Gopalasubramanian, Ganesh Cc: gcc-patches@gcc.gnu.org Subject: Re: [PATCH, i386]: AMD bdver3 enablement On Fri, Nov 9, 2012 at 4:39 AM, Gopalasubramanian, Ganesh wrote: > Changes done with respect to the review comments. > Conditionally setting "sseshuf" type attribute has been removed. > Instead new attribute is added and is included for other attribute calculations. > > The patch is attached as (difflog.txt). > The new file (bdver3.md) describing the pipelines is also attached. > > Bootstrapping and "make -k check" passes. > > OK for upstream? > > 2012-11-09 Ganesh Gopalasubramanian > > bdver3 Enablement > * gcc/doc/extend.texi: Add details about bdver3. > * gcc/doc/invoke.texi: Add details about bdver3. > * config.gcc (i[34567]86-*-linux* | ...): Add bdver3. > (case ${target}): Add bdver3. > * config/i386/i386.h (TARGET_BDVER3): New definition. > * config/i386/i386.md (define_attr "cpu"): Add bdver3. > * config/i386/sse.md (sseshuf): New type attribute. > * config/i386/athlon.md (sseshuf):Likewise. > * config/i386/atom.md (sseshuf):Likewise. > * config/i386/ppro.md (sseshuf):Likewise. You can see from the changes of sse.md that this is functionally a no-op change. Uros. Index: gcc/config/i386/atom.md =================================================================== --- gcc/config/i386/atom.md (revision 193132) +++ gcc/config/i386/atom.md (working copy) @@ -455,6 +455,30 @@ (eq_attr "memory" "!none"))) "atom-simple-0") +(define_insn_reservation "atom_sseshuf" 1 + (and (eq_attr "cpu" "atom") + (and (eq_attr "type" "sseshuf") + (eq_attr "memory" "none"))) + "atom-simple-either") + +(define_insn_reservation "atom_sseshuf_mem" 1 + (and (eq_attr "cpu" "atom") + (and (eq_attr "type" "sseshuf") + (eq_attr "memory" "!none"))) + "atom-simple-either") + +(define_insn_reservation "atom_sseshuf1" 1 + (and (eq_attr "cpu" "atom") + (and (eq_attr "type" "sseshuf1") + (eq_attr "memory" "none"))) + "atom-simple-0") + +(define_insn_reservation "atom_sseshuf1_mem" 1 + (and (eq_attr "cpu" "atom") + (and (eq_attr "type" "sseshuf1") + (eq_attr "memory" "!none"))) + "atom-simple-0") + ;; not pmad, not psad (define_insn_reservation "atom_sseiadd" 1 (and (eq_attr "cpu" "atom") This was not what I had in mind for changes in existing .md files. Just change them in this way: Index: atom.md =================================================================== --- atom.md (revision 193407) +++ atom.md (working copy) @@ -594,7 +594,7 @@ ;; no memory simple (define_insn_reservation "atom_sseadd" 5 (and (eq_attr "cpu" "atom") - (and (eq_attr "type" "sseadd,sseadd1") + (and (eq_attr "type" "sseadd,sseshuf,sseadd1,sseshuf1") (and (eq_attr "memory" "none") (and (eq_attr "mode" "!V2DF") (eq_attr "atom_unit" "!complex"))))) @@ -603,7 +603,7 @@ ;; memory simple (define_insn_reservation "atom_sseadd_mem" 5 (and (eq_attr "cpu" "atom") - (and (eq_attr "type" "sseadd,sseadd1") + (and (eq_attr "type" "sseadd,sseshuf,sseadd1,sseshuf1") (and (eq_attr "memory" "!none") (and (eq_attr "mode" "!V2DF") (eq_attr "atom_unit" "!complex"))))) @@ -612,7 +612,7 @@ ;; maxps, minps, *pd, hadd, hsub (define_insn_reservation "atom_sseadd_3" 8 (and (eq_attr "cpu" "atom") - (and (eq_attr "type" "sseadd,sseadd1") + (and (eq_attr "type" "sseadd,sseshuf,sseadd1,sseshuf1") (ior (eq_attr "mode" "V2DF") (eq_attr "atom_unit" "complex")))) "atom-complex, atom-all-eu*7")