From ef4cc6de5bb7cf4fd0ad3fa31762de1f99f699e2 Mon Sep 17 00:00:00 2001 From: Michael Beck Date: Tue, 7 Oct 2008 14:54:04 +0000 Subject: [PATCH] - fixed strange code: when did it break? [r22579] --- ir/opt/cfopt.c | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/ir/opt/cfopt.c b/ir/opt/cfopt.c index dbaecd6ae..583466fdb 100644 --- a/ir/opt/cfopt.c +++ b/ir/opt/cfopt.c @@ -788,13 +788,15 @@ restart: ir_node *ka = get_End_keepalive(end, i); if (!irn_visited(ka)) { - if (is_Block(ka) && !Block_block_visited(ka)) { - /* irg_block_walk() will increase the block visited flag, but we must visit only - these blocks that are not visited yet, so decrease it first. */ - set_irg_block_visited(irg, get_irg_block_visited(irg) - 1); - irg_block_walk(ka, optimize_blocks, remove_simple_blocks, &env.changed); - mark_irn_visited(ka); - in[j++] = ka; + if (is_Block(ka)) { + if (!Block_block_visited(ka)) { + /* irg_block_walk() will increase the block visited flag, but we must visit only + these blocks that are not visited yet, so decrease it first. */ + set_irg_block_visited(irg, get_irg_block_visited(irg) - 1); + irg_block_walk(ka, optimize_blocks, remove_simple_blocks, &env.changed); + mark_irn_visited(ka); + in[j++] = ka; + } } else { mark_irn_visited(ka); /* don't keep alive dead blocks */ -- 2.20.1