[PATCH][alias-improvements] Fix bootstrap failure with release checking, PRE miscompiling caller-save.c

Daniel Berlin dberlin@dberlin.org
Fri Mar 13 20:26:00 GMT 2009


On Fri, Mar 13, 2009 at 11:27 AM, Richard Guenther <rguenther@suse.de> wrote:
>
> This patch fixes the miscompile of caller-save.c with release checking.
>
> The issue is that during computing ANTIC we seed ANTIC_OUT with
> the phi-translated maximal set.  clean() is supposed to clean all
> invalid members from it but fails to remove unavailable REFERENCE
> expressions (expressions which VUSE is not available in the block).
>
> Bootstrapped and tested on x86_64-unknown-linux-gnu, applied to the
> branch.
>
> Me and Danny are not yet settled over the patch, so it might end up
> getting reverted again, but this will trigger the SPEC tester so
> I can see if it breaks anything there.

I'm still a bit confused on how it gets into this situation.

You said it comes from a phi translation of the maximal set.
Which means we pick up a new vuse through a phi translation as well
(if we don't end up translating the original vuse then it was
definitely still available in our dominator), which in turn, should be
live at the point it was used in a pih node.

This means eventually value_dies_in_block_x should return true when it
gets to the def of that vuse, and the wrong expression should be
cleaned out past the point of the vuse's definition.

I still can't see a situation where we end up with vuses dominating
longer than they are actually available since we start at the end
block and work our way up the CFG, without the SSA having been invalid
in the first place.

I will take a look at the sets that get generated by this testcase
without this patch.



More information about the Gcc-patches mailing list