public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Jeff Law <law@redhat.com>
To: Robin Dapp <rdapp@linux.vnet.ibm.com>,
	       Richard Biener <richard.guenther@gmail.com>
Cc: GCC Patches <gcc-patches@gcc.gnu.org>
Subject: Re: [PATCH] Tree-level fix for PR 69526
Date: Tue, 20 Sep 2016 15:31:00 -0000	[thread overview]
Message-ID: <219f9980-d5a2-e807-cd45-650f079cf6e1@redhat.com> (raw)
In-Reply-To: <6bc1abab-9b54-fb67-fe98-9aaf993859dd@linux.vnet.ibm.com>

On 09/20/2016 06:31 AM, Robin Dapp wrote:
> Hi,
>
>> I meant to do sth like
>>
>> Index: tree-ssa-propagate.c
>> ===================================================================
>> --- tree-ssa-propagate.c        (revision 240133)
>> +++ tree-ssa-propagate.c        (working copy)
>> @@ -1105,10 +1105,10 @@ substitute_and_fold_dom_walker::before_d
>>        /* Replace real uses in the statement.  */
>>        did_replace |= replace_uses_in (stmt, get_value_fn);
>>
>> -      /* If we made a replacement, fold the statement.  */
>> -      if (did_replace)
>> +      /* Fold the statement.  */
>> +      if (fold_stmt (&i, follow_single_use_edges))
>>         {
>> -         fold_stmt (&i, follow_single_use_edges);
>> +         did_replace = true;
>>           stmt = gsi_stmt (i);
>>         }
>>
>> this would need compile-time cost evaluation (and avoid the tree-vrp.c
>> folding part
>> of your patch).
>
> Using this causes the simplifications to be performed in ccp1 instead of
> fwprop1. I noticed two tests failing that rely on propagation being
> performed in fwprop. Should these be adapted or rather the patch be changed?
ISTM this is an indication that something changed the IL without folding 
prior to ccp & forwprop.  That's not in and of itself bad, but may be 
worth investigating to see if whatever prior pass that made this change 
ought to be adjusted.

That investigation would likely guide you with what to do with the 
testcase.  If you find that the earlier pass should have folded, then 
you fix it and change the testcase to verify the earlier pass folded 
properly.  Else you change the testcase to verify ccp folds the statement.

I'm going to let Richi own the review on this.  Just thought I'd chime 
in on that one topic.
jeff

  reply	other threads:[~2016-09-20 15:26 UTC|newest]

Thread overview: 47+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-07-21 10:42 Robin Dapp
2016-07-21 11:28 ` Richard Biener
2016-08-22 14:58   ` Robin Dapp
2016-09-05  7:50     ` Robin Dapp
2016-09-14 13:08     ` Richard Biener
2016-09-14 17:04       ` Jeff Law
2016-10-14  8:33         ` Robin Dapp
2016-09-20 12:39       ` Robin Dapp
2016-09-20 15:31         ` Jeff Law [this message]
2016-10-05 10:40         ` Robin Dapp
2016-10-14 11:49         ` Richard Biener
2016-11-16 15:54           ` Robin Dapp
2016-11-25  6:49             ` Robin Dapp
2016-11-25 13:47             ` Richard Biener
2016-11-28 11:13               ` Richard Biener
2016-11-28 13:26                 ` Robin Dapp
2016-12-05  7:57                   ` Robin Dapp
2016-12-06 13:03                   ` Richard Biener
2016-12-07 16:15                     ` Robin Dapp
2016-12-13 14:13                       ` Richard Biener
2017-01-10 13:33                         ` Robin Dapp
2017-01-17  7:34                           ` Robin Dapp
2017-01-17  9:48                           ` Richard Biener
2017-02-02  9:27                             ` Robin Dapp
2017-05-09  7:31                               ` Robin Dapp
2017-05-11 15:08                             ` Bin.Cheng
2017-05-18 14:47                               ` Robin Dapp
2017-05-18 14:48                               ` [PATCH 1/3] Simplify wrapped binops Robin Dapp
2017-05-18 14:49                               ` [PATCH 2/3] " Robin Dapp
2017-05-18 15:46                                 ` Bin.Cheng
2017-05-18 16:09                                   ` Robin Dapp
2017-05-18 17:15                                     ` Bin.Cheng
2017-05-19 10:13                                       ` Robin Dapp
2017-05-19 10:22                                         ` Bin.Cheng
2017-05-19 10:32                                           ` Richard Biener
2017-06-20 13:08                                           ` Robin Dapp
2017-06-20 13:49                                             ` Richard Biener
2017-06-21 11:44                                               ` Robin Dapp
2017-06-27  7:17                                                 ` Robin Dapp
2017-06-27 12:14                                                 ` Richard Biener
2017-06-28 14:35                                                   ` Robin Dapp
2017-07-03 13:10                                                     ` Richard Biener
2017-07-05  8:51                                                       ` Robin Dapp
2017-07-05  8:54                                                         ` Robin Dapp
2017-07-15  9:58                                                         ` Marc Glisse
2017-05-18 15:08                               ` [PATCH 3/3] " Robin Dapp
2016-08-23  7:11   ` [PATCH] Tree-level fix for PR 69526 Robin Dapp

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=219f9980-d5a2-e807-cd45-650f079cf6e1@redhat.com \
    --to=law@redhat.com \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=rdapp@linux.vnet.ibm.com \
    --cc=richard.guenther@gmail.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).