From: Kazu Hirata Date: Tue, 5 Oct 2004 18:48:44 +0000 (+0000) Subject: tree-cfg.c (cleanup_tree_cfg): Remove variable something_changed. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=1111ad788aeaa829e581c310efbd36f6d66bdbb0;p=gcc.git tree-cfg.c (cleanup_tree_cfg): Remove variable something_changed. * tree-cfg.c (cleanup_tree_cfg): Remove variable something_changed. Simplify the while loop. From-SVN: r88564 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index a94318e9d78..4dd70086bc5 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +2004-10-05 Kazu Hirata + + * tree-cfg.c (cleanup_tree_cfg): Remove variable + something_changed. Simplify the while loop. + 2004-10-05 Kaveh R. Ghazi * builtins.c (expand_builtin_memmove): Delete duplicate code diff --git a/gcc/tree-cfg.c b/gcc/tree-cfg.c index dde9aee0d0f..0c36f3e5d6a 100644 --- a/gcc/tree-cfg.c +++ b/gcc/tree-cfg.c @@ -712,7 +712,6 @@ make_goto_expr_edges (basic_block bb) bool cleanup_tree_cfg (void) { - bool something_changed = true; bool retval = false; timevar_push (TV_TREE_CLEANUP_CFG); @@ -723,16 +722,12 @@ cleanup_tree_cfg (void) /* thread_jumps() sometimes leaves further transformation opportunities for itself, so iterate on it until nothing changes. */ - while (something_changed) + while (thread_jumps ()) { - something_changed = thread_jumps (); - /* delete_unreachable_blocks() does its job only when thread_jumps() produces more unreachable blocks. */ - if (something_changed) - delete_unreachable_blocks (); - - retval |= something_changed; + delete_unreachable_blocks (); + retval = true; } #ifdef ENABLE_CHECKING