aboutsummaryrefslogtreecommitdiff
path: root/gcc/tree-ssa-threadedge.c
diff options
context:
space:
mode:
authorJeff Law <law@redhat.com>2015-09-16 21:01:03 -0600
committerJeff Law <law@gcc.gnu.org>2015-09-16 21:01:03 -0600
commite8ae63bb6ccbb7ec3dc5fbfbaf8236b71c59650e (patch)
treebeeb6ae89f5ced6e7def72c713e3e747502a1c12 /gcc/tree-ssa-threadedge.c
parenta481f93b12d748610b2ebe947f8532765e4890d0 (diff)
downloadgcc-e8ae63bb6ccbb7ec3dc5fbfbaf8236b71c59650e.zip
gcc-e8ae63bb6ccbb7ec3dc5fbfbaf8236b71c59650e.tar.gz
gcc-e8ae63bb6ccbb7ec3dc5fbfbaf8236b71c59650e.tar.bz2
[PATCH] Pass in avail_expr_stack and setup edge_infos earlier
PR tree-optimization/47679 * tree-ssa-dom.c (free_edge_info): Factored out of free_all_edge_infos. (free_all_edge_infos): Use it. (allocate_edge_info): Free preexisting edge info data. (pass_dominator::execute): Set up initial edge info structures. (dom_opt_dom_walker::thread_across_edge): Pass avail_expr_stack to thread_across_edge. * tree-ssa-threadedge.c (thread_across_edge): Accept new argument. If non-null, then push/pop markers appropriately. * tree-ssa-threadedge.h (thread_across_edge): Update prototype. * tree-vrp.c (identify_jump_threads): Pass NULL for new argument to thread-across_edge. From-SVN: r227842
Diffstat (limited to 'gcc/tree-ssa-threadedge.c')
-rw-r--r--gcc/tree-ssa-threadedge.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/gcc/tree-ssa-threadedge.c b/gcc/tree-ssa-threadedge.c
index 0ad2483..a72edc0 100644
--- a/gcc/tree-ssa-threadedge.c
+++ b/gcc/tree-ssa-threadedge.c
@@ -1358,6 +1358,7 @@ thread_across_edge (gcond *dummy_cond,
edge e,
bool handle_dominating_asserts,
const_and_copies *const_and_copies,
+ avail_exprs_stack *avail_exprs_stack,
tree (*simplify) (gimple, gimple))
{
bitmap visited = BITMAP_ALLOC (NULL);
@@ -1442,6 +1443,8 @@ thread_across_edge (gcond *dummy_cond,
/* Push a fresh marker so we can unwind the equivalences created
for each of E->dest's successors. */
const_and_copies->push_marker ();
+ if (avail_exprs_stack)
+ avail_exprs_stack->push_marker ();
/* Avoid threading to any block we have already visited. */
bitmap_clear (visited);
@@ -1493,6 +1496,8 @@ thread_across_edge (gcond *dummy_cond,
}
/* And unwind the equivalence table. */
+ if (avail_exprs_stack)
+ avail_exprs_stack->pop_to_marker ();
const_and_copies->pop_to_marker ();
}
BITMAP_FREE (visited);