diff options
author | jakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4> | 2011-08-20 07:48:35 +0000 |
---|---|---|
committer | jakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4> | 2011-08-20 07:48:35 +0000 |
commit | 0ab72b537f7f56b9c283befc916be4d8af6fefca (patch) | |
tree | 38b9a46cb1baeda8f77519f552d451311011a8d7 /gcc/tree-ssa.c | |
parent | 25155ea4c8129b5b5a1ad28de549e4301722d193 (diff) | |
download | gcc-0ab72b537f7f56b9c283befc916be4d8af6fefca.tar.gz |
PR tree-optimization/48739
* tree-ssa.c: Include cfgloop.h.
(execute_update_addresses_taken): When updating ssa, if in
loop closed SSA form, call rewrite_into_loop_closed_ssa instead of
update_ssa.
* Makefile.in (tree-ssa.o): Depend on $(CFGLOOP_H).
* gcc.dg/pr48739-1.c: New test.
* gcc.dg/pr48739-2.c: New test.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@177924 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/tree-ssa.c')
-rw-r--r-- | gcc/tree-ssa.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/gcc/tree-ssa.c b/gcc/tree-ssa.c index 980716944ff..7564a52fabf 100644 --- a/gcc/tree-ssa.c +++ b/gcc/tree-ssa.c @@ -43,6 +43,7 @@ along with GCC; see the file COPYING3. If not see #include "tree-dump.h" #include "tree-pass.h" #include "diagnostic-core.h" +#include "cfgloop.h" /* Pointer map of variable mappings, keyed by edge. */ static struct pointer_map_t *edge_var_maps; @@ -2208,7 +2209,10 @@ execute_update_addresses_taken (void) } /* Update SSA form here, we are called as non-pass as well. */ - update_ssa (TODO_update_ssa); + if (number_of_loops () > 1 && loops_state_satisfies_p (LOOP_CLOSED_SSA)) + rewrite_into_loop_closed_ssa (NULL, TODO_update_ssa); + else + update_ssa (TODO_update_ssa); } BITMAP_FREE (not_reg_needs); |