[PATCH] Make FRE/PRE look through casts, improve/fix PRs 14287, 14844, 19792, 21608, 27090

Daniel Berlin dberlin@dberlin.org
Wed May 3 13:03:00 GMT 2006


On Wed, 2006-05-03 at 11:20 +0200, Richard Guenther wrote:
> This patch makes value numbering look through casts, effectively
> doing lightweight tree-combining.  It works as follows, on a
> value number expression of the form (T) VN, we use fold to see
> if we can simplify the expression by expanding VN to its expression.
> If that simplifies to an existing VN or an expression with a known
> VN, we register that as the VNs expression.
> 
> Bootstrapped and tested on x86_64-unknown-linux-gnu for all languages
> including Ada.  Unfortunately this hits PR26447 during the build of
> libjava (but you can "convince" it to go further) - I would really
> like someone to look at this PR.
> 
> Ok for mainline once PR26447 is fixed and the patch bootstraps without
> this problem?
> 

Is there any compile time effect of doing this expansion?
Also, could you move it out into a function?
compute_avail is already very busy, and should be split up :)






More information about the Gcc-patches mailing list