Commit c334023f by Richard Guenther Committed by Richard Biener

tree-vect-loop-manip.c (slpeel_update_phi_nodes_for_guard1): Remove set-only bitmap of new names.

2012-05-16  Richard Guenther  <rguenther@suse.de>

	* tree-vect-loop-manip.c (slpeel_update_phi_nodes_for_guard1):
	Remove set-only bitmap of new names.
	(slpeel_tree_peel_loop_to_edge): Likewise.  Do not set
	CFG hooks.
	* tree-flow.h (ssa_names_to_replace): Remove.
	* tree-into-ssa.c (ssa_names_to_replace): Likewise.

From-SVN: r187591
parent a952cc06
2012-05-16 Richard Guenther <rguenther@suse.de> 2012-05-16 Richard Guenther <rguenther@suse.de>
* tree-vect-loop-manip.c (slpeel_update_phi_nodes_for_guard1):
Remove set-only bitmap of new names.
(slpeel_tree_peel_loop_to_edge): Likewise. Do not set
CFG hooks.
* tree-flow.h (ssa_names_to_replace): Remove.
* tree-into-ssa.c (ssa_names_to_replace): Likewise.
2012-05-16 Richard Guenther <rguenther@suse.de>
PR tree-optimization/53364 PR tree-optimization/53364
* tree-ssa-alias.c (indirect_ref_may_alias_decl_p): Properly * tree-ssa-alias.c (indirect_ref_may_alias_decl_p): Properly
detect a view-conversion of the decl. detect a view-conversion of the decl.
......
...@@ -576,7 +576,6 @@ tree create_new_def_for (tree, gimple, def_operand_p); ...@@ -576,7 +576,6 @@ tree create_new_def_for (tree, gimple, def_operand_p);
bool need_ssa_update_p (struct function *); bool need_ssa_update_p (struct function *);
bool name_mappings_registered_p (void); bool name_mappings_registered_p (void);
bool name_registered_for_update_p (tree); bool name_registered_for_update_p (tree);
bitmap ssa_names_to_replace (void);
void release_ssa_name_after_update_ssa (tree); void release_ssa_name_after_update_ssa (tree);
void compute_global_livein (bitmap, bitmap); void compute_global_livein (bitmap, bitmap);
void mark_sym_for_renaming (tree); void mark_sym_for_renaming (tree);
......
...@@ -3053,26 +3053,6 @@ name_registered_for_update_p (tree n ATTRIBUTE_UNUSED) ...@@ -3053,26 +3053,6 @@ name_registered_for_update_p (tree n ATTRIBUTE_UNUSED)
} }
/* Return the set of all the SSA names marked to be replaced. */
bitmap
ssa_names_to_replace (void)
{
unsigned i = 0;
bitmap ret;
sbitmap_iterator sbi;
gcc_assert (update_ssa_initialized_fn == NULL
|| update_ssa_initialized_fn == cfun);
ret = BITMAP_ALLOC (NULL);
EXECUTE_IF_SET_IN_SBITMAP (old_ssa_names, 0, i, sbi)
bitmap_set_bit (ret, i);
return ret;
}
/* Mark NAME to be released after update_ssa has finished. */ /* Mark NAME to be released after update_ssa has finished. */
void void
......
...@@ -489,8 +489,7 @@ LOOP-> loop1 ...@@ -489,8 +489,7 @@ LOOP-> loop1
static void static void
slpeel_update_phi_nodes_for_guard1 (edge guard_edge, struct loop *loop, slpeel_update_phi_nodes_for_guard1 (edge guard_edge, struct loop *loop,
bool is_new_loop, basic_block *new_exit_bb, bool is_new_loop, basic_block *new_exit_bb)
bitmap *defs)
{ {
gimple orig_phi, new_phi; gimple orig_phi, new_phi;
gimple update_phi, update_phi2; gimple update_phi, update_phi2;
...@@ -586,7 +585,6 @@ slpeel_update_phi_nodes_for_guard1 (edge guard_edge, struct loop *loop, ...@@ -586,7 +585,6 @@ slpeel_update_phi_nodes_for_guard1 (edge guard_edge, struct loop *loop,
gcc_assert (get_current_def (current_new_name) == NULL_TREE); gcc_assert (get_current_def (current_new_name) == NULL_TREE);
set_current_def (current_new_name, PHI_RESULT (new_phi)); set_current_def (current_new_name, PHI_RESULT (new_phi));
bitmap_set_bit (*defs, SSA_NAME_VERSION (current_new_name));
} }
} }
...@@ -1159,7 +1157,6 @@ slpeel_tree_peel_loop_to_edge (struct loop *loop, ...@@ -1159,7 +1157,6 @@ slpeel_tree_peel_loop_to_edge (struct loop *loop,
struct loop *new_loop = NULL, *first_loop, *second_loop; struct loop *new_loop = NULL, *first_loop, *second_loop;
edge skip_e; edge skip_e;
tree pre_condition = NULL_TREE; tree pre_condition = NULL_TREE;
bitmap definitions;
basic_block bb_before_second_loop, bb_after_second_loop; basic_block bb_before_second_loop, bb_after_second_loop;
basic_block bb_before_first_loop; basic_block bb_before_first_loop;
basic_block bb_between_loops; basic_block bb_between_loops;
...@@ -1172,12 +1169,6 @@ slpeel_tree_peel_loop_to_edge (struct loop *loop, ...@@ -1172,12 +1169,6 @@ slpeel_tree_peel_loop_to_edge (struct loop *loop,
if (!slpeel_can_duplicate_loop_p (loop, e)) if (!slpeel_can_duplicate_loop_p (loop, e))
return NULL; return NULL;
/* We have to initialize cfg_hooks. Then, when calling
cfg_hooks->split_edge, the function tree_split_edge
is actually called and, when calling cfg_hooks->duplicate_block,
the function tree_duplicate_bb is called. */
gimple_register_cfg_hooks ();
/* If the loop has a virtual PHI, but exit bb doesn't, create a virtual PHI /* If the loop has a virtual PHI, but exit bb doesn't, create a virtual PHI
in the exit bb and rename all the uses after the loop. This simplifies in the exit bb and rename all the uses after the loop. This simplifies
the *guard[12] routines, which assume loop closed SSA form for all PHIs the *guard[12] routines, which assume loop closed SSA form for all PHIs
...@@ -1259,7 +1250,6 @@ slpeel_tree_peel_loop_to_edge (struct loop *loop, ...@@ -1259,7 +1250,6 @@ slpeel_tree_peel_loop_to_edge (struct loop *loop,
second_loop = loop; second_loop = loop;
} }
definitions = ssa_names_to_replace ();
slpeel_update_phis_for_duplicate_loop (loop, new_loop, e == exit_e); slpeel_update_phis_for_duplicate_loop (loop, new_loop, e == exit_e);
rename_variables_in_loop (new_loop); rename_variables_in_loop (new_loop);
...@@ -1397,7 +1387,7 @@ slpeel_tree_peel_loop_to_edge (struct loop *loop, ...@@ -1397,7 +1387,7 @@ slpeel_tree_peel_loop_to_edge (struct loop *loop,
bb_before_second_loop, bb_before_first_loop); bb_before_second_loop, bb_before_first_loop);
slpeel_update_phi_nodes_for_guard1 (skip_e, first_loop, slpeel_update_phi_nodes_for_guard1 (skip_e, first_loop,
first_loop == new_loop, first_loop == new_loop,
&new_exit_bb, &definitions); &new_exit_bb);
/* 3. Add the guard that controls whether the second loop is executed. /* 3. Add the guard that controls whether the second loop is executed.
...@@ -1441,7 +1431,6 @@ slpeel_tree_peel_loop_to_edge (struct loop *loop, ...@@ -1441,7 +1431,6 @@ slpeel_tree_peel_loop_to_edge (struct loop *loop,
if (update_first_loop_count) if (update_first_loop_count)
slpeel_make_loop_iterate_ntimes (first_loop, *first_niters); slpeel_make_loop_iterate_ntimes (first_loop, *first_niters);
BITMAP_FREE (definitions);
delete_update_ssa (); delete_update_ssa ();
adjust_vec_debug_stmts (); adjust_vec_debug_stmts ();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment