#include "mini.h"
-extern guint8 mono_burg_arity [];
-
static char *
convert_name (const char *str)
{
switch (tree->opcode) {
case OP_ICONST:
- fprintf (fp, "[%d]", tree->inst_c0);
+ fprintf (fp, "[%ld]", (long)tree->inst_c0);
break;
case OP_I8CONST:
- fprintf (fp, "[%lld]", tree->inst_l);
+ fprintf (fp, "[%lld]", (long long)tree->inst_l);
break;
case OP_R8CONST:
fprintf (fp, "[%f]", *(double*)tree->inst_p0);
break;
case OP_ARG:
case OP_LOCAL:
- fprintf (fp, "[%d]", tree->inst_c0);
+ fprintf (fp, "[%d]", (int)tree->inst_c0);
break;
case OP_REGOFFSET:
- fprintf (fp, "[0x%x(%s)]", tree->inst_offset, mono_arch_regname (tree->inst_basereg));
+ fprintf (fp, "[0x%x(%s)]", (int)tree->inst_offset, mono_arch_regname (tree->inst_basereg));
break;
case OP_REGVAR:
fprintf (fp, "[%s]", mono_arch_regname (tree->dreg));
fprintf (fp, "[%s]", tree->inst_newa_class->name);
mono_print_label (fp, tree->inst_newa_len);
break;
- case CEE_CALL:
- case CEE_CALLVIRT:
+ case OP_CALL:
+ case OP_CALLVIRT:
case OP_FCALL:
case OP_FCALLVIRT:
case OP_LCALL:
case OP_VOIDCALLVIRT: {
MonoCallInst *call = (MonoCallInst*)tree;
if (call->method) {
- if (call->method->signature->hasthis && tree->inst_left) {
+ if (mono_method_signature (call->method)->hasthis && tree->inst_left) {
mono_print_label (fp, tree->inst_left);
}
fprintf (fp, "[%s]", call->method->name);
}
case OP_PHI: {
int i;
- fprintf (fp, "[%d\\ (", tree->inst_c0);
+ fprintf (fp, "[%d\\ (", (int)tree->inst_c0);
for (i = 0; i < tree->inst_phi_args [0]; i++) {
if (i)
fprintf (fp, ",\\ ");
}
case OP_RENAME:
case OP_RETARG:
- case CEE_NOP:
- case CEE_JMP:
- case CEE_BREAK:
+ case OP_NOP:
+ case OP_JMP:
+ case OP_BREAK:
break;
- case CEE_BR:
+ case OP_BR:
fprintf (fp, "[B%d]", tree->inst_target_bb->block_num);
break;
- case CEE_SWITCH:
+ case OP_SWITCH:
case CEE_ISINST:
case CEE_CASTCLASS:
case OP_OUTARG:
case OP_LCALL_REG:
case OP_VCALL_REG:
case OP_VOIDCALL_REG:
+ case OP_TRAMPCALL_VTABLE:
+ case OP_CALL_RGCTX:
+ case OP_FCALL_RGCTX:
+ case OP_VOIDCALL_RGCTX:
+ case OP_LCALL_RGCTX:
+ case OP_VCALL_RGCTX:
+ case OP_CALL_REG_RGCTX:
+ case OP_FCALL_REG_RGCTX:
+ case OP_VOIDCALL_REG_RGCTX:
+ case OP_LCALL_REG_RGCTX:
+ case OP_VCALL_REG_RGCTX:
+ case OP_CALLVIRT_IMT:
+ case OP_VOIDCALLVIRT_IMT:
+ case OP_FCALLVIRT_IMT:
+ case OP_LCALLVIRT_IMT:
+ case OP_VCALLVIRT_IMT:
mono_print_label (fp, tree->inst_left);
break;
case CEE_BNE_UN:
fprintf (fp, "BB%d [%sshape=record,labeljust=l,label=\"{BB%d|", bb->block_num, color, bb->block_num);
- for (inst = bb->code; inst; inst = inst->next) {
+ MONO_BB_FOR_EACH_INS (bb, inst) {
mono_print_label (fp, inst);
fprintf (fp, "\\n");
}