{
MonoInst *inst, *new_var;
int i, j, idx;
- GList *tmp;
+ GSList *tmp;
MonoInst **new_stack;
#ifdef DEBUG_SSA
if (inst->ssa_op == MONO_SSA_STORE && inst->inst_i1->ssa_op == MONO_SSA_LOAD &&
inst->inst_i0->inst_c0 == inst->inst_i1->inst_i0->inst_c0) {
inst->ssa_op = MONO_SSA_NOP;
- inst->opcode = CEE_NOP;
+ inst->opcode = OP_NOP;
}
}
}
/* remove the phi functions */
- inst->opcode = CEE_NOP;
+ inst->opcode = OP_NOP;
inst->ssa_op = MONO_SSA_NOP;
}
}
//mono_print_tree (u); printf ("\n");
- inst->opcode = CEE_NOP;
+ inst->opcode = OP_NOP;
inst->ssa_op = MONO_SSA_NOP;
}
}
i2->def = inst;
i1->def = NULL;
i1->uses = NULL;
- next->opcode = CEE_NOP;
+ next->opcode = OP_NOP;
next->ssa_op = MONO_SSA_NOP;
}
}
if (target) {
bb->out_bb [0] = target;
bb->out_count = 1;
- inst->opcode = CEE_BR;
+ inst->opcode = OP_BR;
inst->inst_target_bb = target;
}
} else if (inst->opcode == CEE_SWITCH && (evaluate_const_tree (cfg, inst->inst_left, &a, carray) == 1) && (a >= 0) && (a < GPOINTER_TO_INT (inst->klass))) {
bb->out_bb [0] = inst->inst_many_bb [a];
bb->out_count = 1;
inst->inst_target_bb = bb->out_bb [0];
- inst->opcode = CEE_BR;
+ inst->opcode = OP_BR;
}
}
}
}
}
+ } else if (inst->opcode == OP_BR) {
+ MonoBasicBlock *target = inst->inst_target_bb;
+
+ if (!(target->flags & BB_REACHABLE)) {
+ target->flags |= BB_REACHABLE;
+ *bblist = g_list_prepend (*bblist, target);
+ }
} else if ((inst->opcode >= CEE_BEQ && inst->opcode <= CEE_BLT_UN) &&
((inst->inst_i0->opcode == OP_COMPARE) || (inst->inst_i0->opcode == OP_LCOMPARE))) {
int a, b, r1, r2;
}
//if (i1->opcode != OP_PHI) printf ("SSA DEADCE DEAD LOCAL\n");
- info->def->opcode = CEE_NOP;
+ info->def->opcode = OP_NOP;
info->def->ssa_op = MONO_SSA_NOP;
}