X-Git-Url: http://nsz.repo.hu/git/?a=blobdiff_plain;f=ir%2Fopt%2Ftailrec.c;h=371219315e148606ef753cdaa0b1e72a95ac8bc3;hb=762b472fc81c73cf7a1b0041b8cd286b7206d79d;hp=d1af572a4fdca65e716db1dc1dd7120138b18333;hpb=6f068af98daa4725d60e5d23a8f98ec2841cfa44;p=libfirm diff --git a/ir/opt/tailrec.c b/ir/opt/tailrec.c index d1af572a4..371219315 100644 --- a/ir/opt/tailrec.c +++ b/ir/opt/tailrec.c @@ -151,16 +151,10 @@ static void do_opt_tail_rec(ir_graph *irg, tr_env *env) assert(env->n_tail_calls > 0); - /* we add new nodes, so the outs are inconsistent */ - set_irg_outs_inconsistent(irg); - /* we add new blocks and change the control flow */ set_irg_doms_inconsistent(irg); set_irg_extblk_inconsistent(irg); - /* we add a new loop */ - set_irg_loopinfo_inconsistent(irg); - /* calls are removed */ set_trouts_inconsistent(); @@ -234,7 +228,6 @@ static void do_opt_tail_rec(ir_graph *irg, tr_env *env) if (n_params > 0) { ir_node *calls; ir_node *args; - ir_node *args_bl; NEW_ARR_A(ir_node **, call_params, env->n_tail_calls); @@ -247,7 +240,6 @@ static void do_opt_tail_rec(ir_graph *irg, tr_env *env) /* build new Proj's and Phi's */ args = get_irg_args(irg); - args_bl = get_nodes_block(args); for (i = 0; i < n_params; ++i) { ir_mode *mode = get_type_mode(get_method_param_type(method_tp, i)); @@ -274,7 +266,6 @@ static void do_opt_tail_rec(ir_graph *irg, tr_env *env) /* tail recursion was done, all info is invalid */ set_irg_doms_inconsistent(irg); - set_irg_outs_inconsistent(irg); set_irg_extblk_inconsistent(irg); set_irg_loopinfo_state(irg, loopinfo_cf_inconsistent); set_trouts_inconsistent(); @@ -346,7 +337,7 @@ static void do_opt_tail_rec(ir_graph *irg, tr_env *env) /* create a new tuple for the return values */ tuple = new_r_Tuple(block, env->n_ress, in); - turn_into_tuple(call, pn_Call_max); + turn_into_tuple(call, pn_Call_max+1); set_Tuple_pred(call, pn_Call_M, mem); set_Tuple_pred(call, pn_Call_X_regular, jmp); set_Tuple_pred(call, pn_Call_X_except, new_r_Bad(irg, mode_X));