From: Michael Beck Date: Wed, 22 Oct 2008 15:59:41 +0000 (+0000) Subject: - kill keep-alive edges to dead blocks before doing apply_result(), X-Git-Url: http://nsz.repo.hu/git/?a=commitdiff_plain;h=468f669985c53e7c071d136564147c39a0b9948f;p=libfirm - kill keep-alive edges to dead blocks before doing apply_result(), this reduces the graph and fixes the problem of dead cf to dead blocks (which assert else) [r23114] --- diff --git a/ir/opt/combo.c b/ir/opt/combo.c index 688754586..e1dd01474 100644 --- a/ir/opt/combo.c +++ b/ir/opt/combo.c @@ -3430,8 +3430,11 @@ void combo(ir_graph *irg) { /* apply the result */ irg_block_walk_graph(irg, NULL, apply_cf, &env); - irg_walk_graph(irg, NULL, apply_result, &env); + /* Kill keep-alives of dead blocks: this speeds up apply_result() + * and fixes assertion because dead cf to dead blocks is NOT removed by + * apply_cf(). */ apply_end(get_irg_end(irg), &env); + irg_walk_graph(irg, NULL, apply_result, &env); if (env.modified) { /* control flow might changed */