From: Richard Biener <richard.guenther@gmail.com>
To: Marek Polacek <polacek@redhat.com>
Cc: Eric Botcazou <ebotcazou@adacore.com>, gcc-patches@gcc.gnu.org
Subject: Re: [PATCH] Don't bypass blocks with multiple latch edges (PR middle-end/54838)
Date: Thu, 29 Nov 2012 08:34:00 -0000 [thread overview]
Message-ID: <CAFiYyc2S_UoL3jPQEF9qQUA=ZK59fiDyvBMP65rRTWX-uqj3BQ@mail.gmail.com> (raw)
In-Reply-To: <20121128182457.GB26585@redhat.com>
On Wed, Nov 28, 2012 at 7:24 PM, Marek Polacek <polacek@redhat.com> wrote:
> On Wed, Nov 28, 2012 at 10:52:17AM +0100, Eric Botcazou wrote:
>> No, I don't think that's the problem. The above messages are admittedly a bit
>> terse, they should say:
>>
>> JUMP-BYPASS: Proved reg 59 in jump_insn 15 equals constant (const_int 3 [0x3])
>> when BB 4 is entered from BB 9. Redirect edge 9->4 to 5.
>>
>> so you can have different constants for BB 3 and BB 9. The patch to tweak the
>> dump messages along these lines is pre-approved.
>
> Ouch. Okay, I'll post a separate patch for improving the message.
>
>> The ICE in merge_latch_edges means that the loop structure and the CFG aren't
>> in sync anymore. Does the cprop pass modify the former without declaring it?
>
> I admit I'm not sure what to look at, maybe cprop should have in
> properties_destroyed PROP_loops? Well, then we need to remove one
> assert in loop-init.c. So something like:
Definitely not - that means to not preserve loops until after cprop. The goal
is to preserve loops everywhere!
Richard.
> --- gcc/cprop.c.mp 2012-11-28 16:55:03.520375191 +0100
> +++ gcc/cprop.c 2012-11-28 16:55:35.992246623 +0100
> @@ -1927,7 +1927,7 @@ struct rtl_opt_pass pass_rtl_cprop =
> TV_CPROP, /* tv_id */
> PROP_cfglayout, /* properties_required */
> 0, /* properties_provided */
> - 0, /* properties_destroyed */
> + PROP_loops, /* properties_destroyed */
> 0, /* todo_flags_start */
> TODO_df_finish | TODO_verify_rtl_sharing |
> TODO_verify_flow | TODO_ggc_collect /* todo_flags_finish */
> --- gcc/loop-init.c.mp 2012-11-28 16:55:08.924398879 +0100
> +++ gcc/loop-init.c 2012-11-28 16:55:17.684437276 +0100
> @@ -54,8 +54,6 @@ loop_optimizer_init (unsigned flags)
> }
> else
> {
> - gcc_assert (cfun->curr_properties & PROP_loops);
> -
> /* Ensure that the dominators are computed, like flow_loops_find does. */
> calculate_dominance_info (CDI_DOMINATORS);
>
> This quashes the ICE. I've regtested it, it caused one
> regression though:
> FAIL: gcc.dg/unroll_5.c scan-rtl-dump-times loop2_unroll "realistic
> bound: 2999999" 1
>
> But there probably is something else.
>
> Thanks for the review,
>
> Marek
next prev parent reply other threads:[~2012-11-29 8:34 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-11-26 14:28 Marek Polacek
2012-11-28 9:55 ` Eric Botcazou
2012-11-28 18:39 ` Marek Polacek
2012-11-29 8:34 ` Richard Biener [this message]
2012-11-29 8:57 ` Steven Bosscher
2012-11-29 9:35 ` Richard Biener
2012-11-29 15:39 ` Marek Polacek
2012-11-29 15:42 ` Marek Polacek
2012-11-29 15:51 ` Steven Bosscher
2012-11-29 16:56 ` Marek Polacek
2012-11-29 17:45 ` Eric Botcazou
2012-11-30 9:02 ` Richard Biener
2012-11-30 16:28 ` Marek Polacek
2012-11-30 22:01 ` Eric Botcazou
2012-11-30 22:33 ` Eric Botcazou
2012-12-01 16:18 ` Marek Polacek
2012-12-02 10:06 ` Eric Botcazou
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='CAFiYyc2S_UoL3jPQEF9qQUA=ZK59fiDyvBMP65rRTWX-uqj3BQ@mail.gmail.com' \
--to=richard.guenther@gmail.com \
--cc=ebotcazou@adacore.com \
--cc=gcc-patches@gcc.gnu.org \
--cc=polacek@redhat.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).