[PATCH] Fix DEBUG stmt handling in the vectorizer (PR debug/42604)
Alexandre Oliva
aoliva@redhat.com
Wed Jan 6 17:16:00 GMT 2010
On Jan 6, 2010, Richard Guenther <richard.guenther@gmail.com> wrote:
> I'd say drop Jakubs fix for now - I'd rather have a testcase that shows it
> is still needed.
'k
> Also I wonder why you need the delayed debug-stmt processing
Oops, sorry, I forgot to explain it. See below.
> I suppose you have a testcase that breaks otherwise?
The same testcase, pr42604.c. We have to “propagate” the last PHI
substitution first. If we propagate the first one first, the debug uses
will end up referencing a non-dominating use, and when we get to the one
that would get us the right answer, it wouldn't find anything to adjust.
Think of it this way, given:
x = foo;
...
x = bar;
...
y = x;
If you propagate the first x into y= first, you'll get foo rather than
bar, which is what you need. The case at hand isn't exactly the same
because we're not talking about assignments, but rather about adjusting
PHI nodes, but it's kind of similar: substitute the closest dominating
equivalence first.
>> There's a trivial fix for vec.h “hidden” in the patch, that might as
>> well go in regardless of the rest of the patch.
> Indeed - please commit this separately (it's obvious).
Okiedokie. I'll adjust some comments, too.
Combined and split out patches will be posted momentarily.
--
Alexandre Oliva, freedom fighter http://FSFLA.org/~lxoliva/
You must be the change you wish to see in the world. -- Gandhi
Be Free! -- http://FSFLA.org/ FSF Latin America board member
Free Software Evangelist Red Hat Brazil Compiler Engineer
More information about the Gcc-patches
mailing list