From patchwork Tue Jul 3 16:11:46 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vladimir Makarov X-Patchwork-Id: 168840 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 C03FB2C00C2 for ; Wed, 4 Jul 2012 02:12:12 +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=1341936733; h=Comment: DomainKey-Signature:Received:Received:Received:Received:Received: Message-ID:Date:From:User-Agent:MIME-Version:To:Subject: Content-Type:Mailing-List:Precedence:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:Sender:Delivered-To; bh=EM3yGiq M0oZ2gtuaPV6kf+Acn+0=; b=XZrV+m+Dg+zBLCAD1JQDyrBSVVkceyKIrBE5gMj gOxkwx24oNxCgv80t5NDVUBYKc8J0JZ2hLYN9y8YGJUazFsEvkdvz/BfdYdT0BgL dUkdWfsVhnjWjrrQlwzFXQ+Nkj9exMFUZLaQdT7aHK4CETvhC6gDekeZDrcwBSUy 5/Lg= 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:Message-ID:Date:From:User-Agent:MIME-Version:To:Subject:Content-Type:X-IsSubscribed:Mailing-List:Precedence:List-Id:List-Unsubscribe:List-Archive:List-Post:List-Help:Sender:Delivered-To; b=VuKoEJjEw9fmPycfFPBwoREFUsNlXDMlQOukYp7jeTlwAmgm8wCL63c2fFmPXa 9pMoT6R3jZEhzM1GVCKBvQ4kMmt1NnpxQOTnxaloUrBmDIzjkqsgQRPdHi6EIjbR o1coUr0RNoQ5ysexO/xBAsp5bug+vMTxRMJoF1XhzovSc=; Received: (qmail 7800 invoked by alias); 3 Jul 2012 16:12:07 -0000 Received: (qmail 7789 invoked by uid 22791); 3 Jul 2012 16:12:06 -0000 X-SWARE-Spam-Status: No, hits=-6.0 required=5.0 tests=AWL, BAYES_00, KHOP_RCVD_UNTRUST, MAY_BE_FORGED, RCVD_IN_DNSWL_HI, RCVD_IN_HOSTKARMA_W, SPF_HELO_PASS, T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Tue, 03 Jul 2012 16:11:52 +0000 Received: from int-mx10.intmail.prod.int.phx2.redhat.com (int-mx10.intmail.prod.int.phx2.redhat.com [10.5.11.23]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id q63GBrIj028808 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Tue, 3 Jul 2012 12:11:53 -0400 Received: from toll.usersys.redhat.com (unused [10.15.16.165] (may be forged)) by int-mx10.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id q63GBqoZ024145 for ; Tue, 3 Jul 2012 12:11:53 -0400 Message-ID: <4FF319C2.3020206@redhat.com> Date: Tue, 03 Jul 2012 12:11:46 -0400 From: Vladimir Makarov User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:12.0) Gecko/20120430 Thunderbird/12.0.1 MIME-Version: 1.0 To: gcc-patches Subject: [lra] patch to fix ia64 testsuite regressions X-IsSubscribed: yes 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 The following patch fixes all testsuite regressions on ia64 in comparison with reload. The patch was successfully bootstrapped on ia64 and x86/x86-64. Committed as rev. 189235. 2012-07-03 Vladimir Makarov * lra-eliminations.c (lra_eliminate_regs_1): Use Pmode for plus_constant calls. (eliminate_regs_in_insn): Ditto. Index: lra-eliminations.c =================================================================== --- lra-eliminations.c (revision 189016) +++ lra-eliminations.c (working copy) @@ -304,12 +304,12 @@ lra_eliminate_regs_1 (rtx x, enum machin if ((ep = get_elimination (regno)) != NULL) { rtx to = subst_p ? ep->to_rtx : ep->from_rtx; - + if (update_p) - return plus_constant (GET_MODE (x), to, + return plus_constant (Pmode, to, ep->offset - ep->previous_offset); else if (full_p) - return plus_constant (GET_MODE (x), to, ep->offset); + return plus_constant (Pmode, to, ep->offset); else return to; } @@ -843,8 +843,7 @@ eliminate_regs_in_insn (rtx insn, bool r rtx src; offset -= (ep->offset - ep->previous_offset); - src = plus_constant (GET_MODE (SET_SRC (old_set)), - ep->to_rtx, offset); + src = plus_constant (Pmode, ep->to_rtx, offset); /* First see if this insn remains valid when we make the change. If not, keep the INSN_CODE @@ -930,8 +929,7 @@ eliminate_regs_in_insn (rtx insn, bool r before. */ if (offset == 0 || plus_src) { - rtx new_src = plus_constant (GET_MODE (XEXP (plus_cst_src, 0)), - to_rtx, offset); + rtx new_src = plus_constant (GET_MODE (to_rtx), to_rtx, offset); old_set = single_set (insn);