From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 22867 invoked by alias); 27 Jun 2011 18:29:18 -0000 Received: (qmail 22856 invoked by uid 22791); 27 Jun 2011 18:29:17 -0000 X-SWARE-Spam-Status: No, hits=-1.7 required=5.0 tests=AWL,BAYES_00,MSGID_FROM_MTA_HEADER,T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from mtagate7.uk.ibm.com (HELO mtagate7.uk.ibm.com) (194.196.100.167) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Mon, 27 Jun 2011 18:29:02 +0000 Received: from d06nrmr1507.portsmouth.uk.ibm.com (d06nrmr1507.portsmouth.uk.ibm.com [9.149.38.233]) by mtagate7.uk.ibm.com (8.13.1/8.13.1) with ESMTP id p5RISs01020717 for ; Mon, 27 Jun 2011 18:28:54 GMT Received: from d06av02.portsmouth.uk.ibm.com (d06av02.portsmouth.uk.ibm.com [9.149.37.228]) by d06nrmr1507.portsmouth.uk.ibm.com (8.13.8/8.13.8/NCO v10.0) with ESMTP id p5RISsu92511076 for ; Mon, 27 Jun 2011 19:28:54 +0100 Received: from d06av02.portsmouth.uk.ibm.com (loopback [127.0.0.1]) by d06av02.portsmouth.uk.ibm.com (8.14.4/8.13.1/NCO v10.0 AVout) with ESMTP id p5RISs4O030448 for ; Mon, 27 Jun 2011 12:28:54 -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.13.1/NCO v10.0 AVin) with SMTP id p5RISq1L030434; Mon, 27 Jun 2011 12:28:52 -0600 Message-Id: <201106271828.p5RISq1L030434@d06av02.portsmouth.uk.ibm.com> Received: by tuxmaker.boeblingen.de.ibm.com (sSMTP sendmail emulation); Mon, 27 Jun 2011 20:28:52 +0200 Subject: Re: PATCH [10/n]: Prepare x32: PR rtl-optimization/49114: Reload failed to handle (set reg:X (plus:X (subreg:X (reg:Y) 0) (const To: hjl.tools@gmail.com (H.J. Lu) Date: Mon, 27 Jun 2011 18:51:00 -0000 From: "Ulrich Weigand" Cc: gcc-patches@gcc.gnu.org, bernds@codesourcery.com In-Reply-To: from "H.J. Lu" at Jun 27, 2011 11:03:14 AM MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit 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 X-SW-Source: 2011-06/txt/msg02043.txt.bz2 H.J. Lu wrote: > On Mon, Jun 27, 2011 at 7:47 AM, Ulrich Weigand wrote: > > The actual problem > > here is that this part of gen_reload takes the approach to transform > > > > out <- op0 + op1 > > > > into > > > > out <- op0 > > out <- out + op1 > > > > which is invalid if writing to out clobbers op1. > The problem is reload 0 puts OP1 in OUT. Adding > > gcc_assert (!reg_overlap_mentioned_p (out, op1)); > > doesn't help in reload 2. How can I check if OP1 overlaps with > OUT in previous reload? Sorry, I don't understand how previous reloads come into play here. gen_reload is supposed to load "in" (which happens to be of the form op0 + op1) into "out", which means it is of course supposed to clobber "out" (as long as that doesn't implictly clobber op0 or op1 before they're used). Any conflicts with other reloads ought to have been resolved earlier. Can you elaborate? Bye, Ulrich -- Dr. Ulrich Weigand GNU Toolchain for Linux on System z and Cell BE Ulrich.Weigand@de.ibm.com