From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 27143 invoked by alias); 3 Sep 2014 18:12:40 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Received: (qmail 27102 invoked by uid 89); 3 Sep 2014 18:12:39 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.6 required=5.0 tests=AWL,BAYES_00,MSGID_FROM_MTA_HEADER,RP_MATCHES_RCVD,SPF_PASS autolearn=ham version=3.3.2 X-HELO: e06smtp11.uk.ibm.com Received: from e06smtp11.uk.ibm.com (HELO e06smtp11.uk.ibm.com) (195.75.94.107) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES256-SHA encrypted) ESMTPS; Wed, 03 Sep 2014 18:12:38 +0000 Received: from /spool/local by e06smtp11.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Wed, 3 Sep 2014 19:12:35 +0100 Received: from d06dlp01.portsmouth.uk.ibm.com (9.149.20.13) by e06smtp11.uk.ibm.com (192.168.101.141) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; Wed, 3 Sep 2014 19:12:33 +0100 Received: from b06cxnps4074.portsmouth.uk.ibm.com (d06relay11.portsmouth.uk.ibm.com [9.149.109.196]) by d06dlp01.portsmouth.uk.ibm.com (Postfix) with ESMTP id 3B10717D8047 for ; Wed, 3 Sep 2014 19:14:30 +0100 (BST) Received: from d06av02.portsmouth.uk.ibm.com (d06av02.portsmouth.uk.ibm.com [9.149.37.228]) by b06cxnps4074.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id s83ICWea38797436 for ; Wed, 3 Sep 2014 18:12:32 GMT Received: from d06av02.portsmouth.uk.ibm.com (localhost [127.0.0.1]) by d06av02.portsmouth.uk.ibm.com (8.14.4/8.14.4/NCO v10.0 AVout) with ESMTP id s83ICVO7004943 for ; Wed, 3 Sep 2014 12:12:31 -0600 Received: from tuxmaker.boeblingen.de.ibm.com (tuxmaker.boeblingen.de.ibm.com [9.152.85.9]) by d06av02.portsmouth.uk.ibm.com (8.14.4/8.14.4/NCO v10.0 AVin) with SMTP id s83ICUxg004905; Wed, 3 Sep 2014 12:12:30 -0600 Message-Id: <201409031812.s83ICUxg004905@d06av02.portsmouth.uk.ibm.com> Received: by tuxmaker.boeblingen.de.ibm.com (sSMTP sendmail emulation); Wed, 03 Sep 2014 20:12:30 +0200 Subject: Re: [PATCH][IRA] Analysis of register usage of functions for usage by IRA. To: Tom_deVries@mentor.com (Tom de Vries) Date: Wed, 03 Sep 2014 18:12:00 -0000 From: "Ulrich Weigand" Cc: vmakarov@redhat.com (Vladimir Makarov), stevenb.gcc@gmail.com (Steven Bosscher), gcc-patches@gcc.gnu.org (gcc-patches@gcc.gnu.org), robradovic@mips.com (Radovan Obradovic) In-Reply-To: <540748BE.9070205@mentor.com> from "Tom de Vries" at Sep 03, 2014 06:58:38 PM MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-TM-AS-MML: disable X-Content-Scanned: Fidelis XPS MAILER x-cbid: 14090318-5024-0000-0000-0000012C08EB X-SW-Source: 2014-09/txt/msg00258.txt.bz2 Tom de Vries wrote: > thanks for noticing this. I agree, this looks wrong, and is probably an > oversight. [ It seems that s390 is the only target defining > IRA_HARD_REGNO_ADD_COST_MULTIPLIER, so this problem didn't show up on any other > target. ] > > I think attached patch fixes it. > > I've build the patch and ran the fuse-caller-save tests, and I'm currently > bootstrapping and reg-testing it on x86_64. Thanks! > Can you check whether this patches fixes the issue for s390 ? Yes, this (which is equivalent to a patch I had been using) does fix the s390 issue again. Just for my curiosity, why is the second condition (after &&) needed in this clause in the first place? > if (ira_hard_reg_set_intersection_p (regno, mode, > + *crossed_calls_clobber_regs) > + && (ira_hard_reg_set_intersection_p (regno, mode, > call_used_reg_set) > - || HARD_REGNO_CALL_PART_CLOBBERED (regno, mode)) If a register is in crossed_calls_clobber_regs, can it ever *not* be a call-clobbered register? Bye, Ulrich -- Dr. Ulrich Weigand GNU/Linux compilers and toolchain Ulrich.Weigand@de.ibm.com