diff options
author | Jeff Law <law@redhat.com> | 2013-09-03 14:43:46 -0600 |
---|---|---|
committer | Jeff Law <law@gcc.gnu.org> | 2013-09-03 14:43:46 -0600 |
commit | 3b18bc426a5c853bda2bdb9e646c5b00483e982a (patch) | |
tree | a84c9f73b9de44d8f8421f514d4b08f7eefa96d7 /gcc/tree-ssa-threadedge.c | |
parent | ae84e151ddf7908e0d7b90036c0754cc39209595 (diff) | |
download | gcc-3b18bc426a5c853bda2bdb9e646c5b00483e982a.zip gcc-3b18bc426a5c853bda2bdb9e646c5b00483e982a.tar.gz gcc-3b18bc426a5c853bda2bdb9e646c5b00483e982a.tar.bz2 |
tree-ssa-threadedge.c (thread_across_edge): Record entire path when not threading through a joiner block.
* tree-ssa-threadedge.c (thread_across_edge): Record entire path
when not threading through a joiner block. Pass joiner/no joiner
state to register_jump_thread.
* tree-ssa-threadupdate.c (register_jump_thread): Get joiner/no joiner
state from argument rather than implying on path length.
Dump the entire jump thread path into debugging dump.
* tree-flow.h (register_jump_thread): Update prototype.
* tree-ssa/ssa-dom-thread-3.c: Update due to changes in debug
dump output.
From-SVN: r202232
Diffstat (limited to 'gcc/tree-ssa-threadedge.c')
-rw-r--r-- | gcc/tree-ssa-threadedge.c | 18 |
1 files changed, 11 insertions, 7 deletions
diff --git a/gcc/tree-ssa-threadedge.c b/gcc/tree-ssa-threadedge.c index fc33647..dddcfce 100644 --- a/gcc/tree-ssa-threadedge.c +++ b/gcc/tree-ssa-threadedge.c @@ -901,6 +901,10 @@ thread_across_edge (gimple dummy_cond, if (dest == e->dest) goto fail; + vec<edge> path = vNULL; + path.safe_push (e); + path.safe_push (taken_edge); + /* DEST could be null for a computed jump to an absolute address. If DEST is not null, then see if we can thread through it as well, this helps capture secondary effects @@ -922,7 +926,10 @@ thread_across_edge (gimple dummy_cond, simplify, visited); if (e2) - taken_edge = e2; + { + taken_edge = e2; + path.safe_push (e2); + } } while (e2); BITMAP_FREE (visited); @@ -931,13 +938,10 @@ thread_across_edge (gimple dummy_cond, remove_temporary_equivalences (stack); if (taken_edge) { - vec<edge> path = vNULL; propagate_threaded_block_debug_into (taken_edge->dest, e->dest); - path.safe_push (e); - path.safe_push (taken_edge); - register_jump_thread (path); - path.release (); + register_jump_thread (path, false); } + path.release (); return; } } @@ -1009,7 +1013,7 @@ thread_across_edge (gimple dummy_cond, { propagate_threaded_block_debug_into (e3->dest, taken_edge->dest); - register_jump_thread (path); + register_jump_thread (path, true); } } |