On Fri, Nov 7, 2014 at 12:53 AM, Richard Biener <rguent...@suse.de> wrote:
>
> This interleaves stmt folding and manual simplifications done in
> forwprop into a single loop over all basic-blocks.  It somewhat
> complicates things as we need to make sure the lattice stays
> valid when releasing SSA names from old code or when purging
> dead EH edges (which we now delay).  But this ensures we don't
> regress by exposing dependences between the transforms still
> in forwprop and those we moved to patterns.
>
> This patch also goes forward and implements the POINTER_PLUS_EXPR
> patterns from tree-ssa-forwprop.c as patterns.
>
> Bootstrapped and tested on x86_64-unknown-linux-gnu, applied to trunk.
>
> Richard.
>
> 2014-11-07  Richard Biener  <rguent...@suse.de>
>
>         * match.pd: Add patterns for POINTER_PLUS_EXPR association
>         and special patterns from tree-ssa-forwprop.c
>         * fold-const.c (fold_binary_loc): Remove them here.
>         * tree-ssa-forwprop.c (to_purge): New global bitmap.
>         (fwprop_set_lattice_val): New function.
>         (fwprop_invalidate_lattice): Likewise.
>         (remove_prop_source_from_use): Instead of purging dead EH
>         edges record blocks to do that in to_purge.
>         (tidy_after_forward_propagate_addr): Likewise.
>         (forward_propagate_addr_expr): Invalidate the lattice for
>         SSA names we release.
>         (simplify_conversion_from_bitmask): Likewise.
>         (simplify_builtin_call): Likewise.
>         (associate_pointerplus_align): Remove.
>         (associate_pointerplus_diff): Likewise.
>         (associate_pointerplus): Likewise.
>         (fold_all_stmts): Merge with ...
>         (pass_forwprop::execute): ... the original loop over all
>         basic-blocks.  Delay purging dead EH edges and invalidate
>         the lattice for SSA names we release.
>

This caused:

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63839

Reply via email to