From 563cb6be0f31cea2cece0482aff2ede0acc1d259 Mon Sep 17 00:00:00 2001 From: Diego Novillo Date: Sat, 9 Jul 2005 17:35:05 +0000 Subject: re PR tree-optimization/21356 (Dominance error after aggressive dead code elimination (cd_dce)) PR 21356 PR 22332 * passes.c (execute_todo): Cleanup the CFG before updating SSA. From-SVN: r101832 --- gcc/passes.c | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) (limited to 'gcc/passes.c') diff --git a/gcc/passes.c b/gcc/passes.c index 8d1411a..abc44e4 100644 --- a/gcc/passes.c +++ b/gcc/passes.c @@ -666,12 +666,7 @@ execute_todo (struct tree_opt_pass *pass, unsigned int flags, bool use_required) gcc_assert (flags & TODO_update_ssa_any); #endif - if (flags & TODO_update_ssa_any) - { - unsigned update_flags = flags & TODO_update_ssa_any; - update_ssa (update_flags); - } - + /* Always cleanup the CFG before doing anything else. */ if (flags & TODO_cleanup_cfg) { if (current_loops) @@ -680,6 +675,12 @@ execute_todo (struct tree_opt_pass *pass, unsigned int flags, bool use_required) cleanup_tree_cfg (); } + if (flags & TODO_update_ssa_any) + { + unsigned update_flags = flags & TODO_update_ssa_any; + update_ssa (update_flags); + } + if ((flags & TODO_dump_func) && dump_file && current_function_decl) { -- cgit v1.1