public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Bernd Schmidt <bschmidt@redhat.com>
To: Kyrill Tkachov <kyrylo.tkachov@arm.com>,
	       GCC Patches <gcc-patches@gcc.gnu.org>
Subject: Re: [PATCH][RTL-ifcvt] PR rtl-optimization/68506: Fix emitting order of insns in IF-THEN-JOIN case
Date: Thu, 26 Nov 2015 13:50:00 -0000	[thread overview]
Message-ID: <56570BDB.9070804@redhat.com> (raw)
In-Reply-To: <5656E924.4030603@arm.com>

On 11/26/2015 12:12 PM, Kyrill Tkachov wrote:
> diff --git a/gcc/ifcvt.c b/gcc/ifcvt.c
> index af7a3b9..3e3dc8d 100644
> --- a/gcc/ifcvt.c
> +++ b/gcc/ifcvt.c
> @@ -2220,7 +2220,7 @@ noce_try_cmove_arith (struct noce_if_info *if_info)
>   	  }
>
>       }
> -    if (emit_a && modified_in_a)
> +    if (emit_a || modified_in_a)
>         {
Having stared at it in the debugger for a while, I think I managed to 
convince myself that this is correct. So, OK.

A few other comments. This whole if block is indented too far, please 
fix while you're there. Also eliminate the unnecessary blank lines 
before closing braces (two instances inside this if block). There are 
other formatting errors in this function, but those are best left alone 
for now.

>   	modified_in_b = emit_b != NULL_RTX && modified_in_p (orig_a, emit_b);

Can this ever be true? We arrange for emit_b to set a new pseudo, don't 
we? Are we allowing cases where we copy a pattern that sets more than 
one register, and is that safe?


Bernd

  reply	other threads:[~2015-11-26 13:40 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-11-26 11:15 Kyrill Tkachov
2015-11-26 13:50 ` Bernd Schmidt [this message]
2015-11-26 14:00   ` Kyrill Tkachov
2015-11-26 14:27     ` Bernd Schmidt
2015-11-26 14:35       ` Kyrill Tkachov
2015-11-26 14:37         ` Bernd Schmidt
2015-11-26 16:49         ` Kyrill Tkachov
2015-11-26 16:51           ` Bernd Schmidt
2015-11-26 17:05             ` Kyrill Tkachov
2015-11-27  9:45               ` Kyrill Tkachov
2015-11-27 14:09                 ` Richard Biener
2015-11-27 14:35                   ` Kyrill Tkachov
2015-11-27 14:38                     ` Bernd Schmidt
2015-11-27 14:41                       ` Kyrill Tkachov

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=56570BDB.9070804@redhat.com \
    --to=bschmidt@redhat.com \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=kyrylo.tkachov@arm.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).