[Bug tree-optimization/18694] [4.0 regression] loop miscompilation at -O1 (-ftree-ch)
------- Additional Comments From law at redhat dot com 2004-12-10 19:18 -------
Subject: Re: [4.0 regression] loop
miscompilation at -O1 (-ftree-ch)
On Fri, 2004-12-10 at 19:08 +0000, kazu at cs dot umass dot edu wrote:
> I think so. :-)
I don't. :( I think it'll record tmp_1 = next_2, which is actually
wrong, even though it doesn't actually cause problems with this
testcase.
> What thread_across_edge is really trying to do is "What would these
> statements in E->dest look like if they appeared at the end of
> E->src?" Then the question is reduced to whether each statement in
> E->dest is translated correctly. To do the translation, we use
> SSA_NAME_VALUE, but note that we don't use it iteratively. In other
> words, given a SSA_NAME variable VAR, we don't do this
>
> while (TREE_CODE (var) == SSA_NAME
> && SSA_NAME_VALUE (var) != NULL_TREE)
> var = SSA_NAME_VALUE (var);
And the reason we don't do that is we can actually get into a loop
due to equivalences created by equality tests.
> p.s.
> By the way, I am now wondering how many times we succeed in threading
> a back edge.
It does happen, but I don't know how often.
jeff
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=18694
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.
Reply to: