[ tree-ssa] PRE problem
Daniel Berlin
dberlin@dberlin.org
Sat Feb 21 01:11:00 GMT 2004
On Feb 20, 2004, at 7:49 PM, law@redhat.com wrote:
> In message <1077321774.3219.22.camel@localhost.localdomain>, Diego
> Novillo writ
> es:
>> On Fri, 2004-02-20 at 18:48, Daniel Berlin wrote:
>>
>>> Um, Diego, when do you think that code was written?
>>> Last week?
>>> It hasn't been fundamentally touched in ages (I believe someone
>>> touched
>>> the generate_vops part when we moved to having VUSE_OPS_PTR).
>>>
>> Dan, what is happening here is that we are only *now* discovering that
>> the changes made to the copy propagation of pointers were affecting
>> PRE.
> True. Basically I suspect this could be summed up as "we weren't aware
> that PRE did this kind of thing internally.
It says so in the comment :)
/* Generate EXPR as it would look in basic block PRED (using the phi in
block BB). We do this by replacing the variables with the phi
argument definitions for block J if they are defined by a phi in
block BB. */
Though admittedly, you'd have to think about it for a second to realize
that this is propagating values.
> Though this does bring up a documentation issue -- I don't think we
> discuss these issues anywhere in the documentation (source or
> external).
>
>> When I introduced propagate_copy and may_propagate_copy, I simply
>> didn't
>> run into this problem. The fix is simple, just teach PRE to use the
>> value propagation API.
> Given that we've got two fixes for these issues, let's get one tested
> and installed and get on with our lives.
Neither fix is quite correct (and in fact, both would introduce silent
but deadly bugs :P), which is why i'm testing the third fix.
--Dan
More information about the Gcc
mailing list