aboutsummaryrefslogtreecommitdiff
path: root/gcc/tree-ssa-forwprop.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/tree-ssa-forwprop.c')
-rw-r--r--gcc/tree-ssa-forwprop.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/gcc/tree-ssa-forwprop.c b/gcc/tree-ssa-forwprop.c
index e4cae68..17da0f1 100644
--- a/gcc/tree-ssa-forwprop.c
+++ b/gcc/tree-ssa-forwprop.c
@@ -446,12 +446,16 @@ static void
tidy_after_forward_propagate_addr (tree stmt)
{
mark_new_vars_to_rename (stmt);
- update_stmt (stmt);
/* We may have turned a trapping insn into a non-trapping insn. */
if (maybe_clean_or_replace_eh_stmt (stmt, stmt)
&& tree_purge_dead_eh_edges (bb_for_stmt (stmt)))
cfg_changed = true;
+
+ if (TREE_CODE (TREE_OPERAND (stmt, 1)) == ADDR_EXPR)
+ recompute_tree_invarant_for_addr_expr (TREE_OPERAND (stmt, 1));
+
+ update_stmt (stmt);
}
/* STMT defines LHS which is contains the address of the 0th element