X-Git-Url: http://wien.tomnetworks.com/gitweb/?a=blobdiff_plain;f=mono%2Fmini%2Fgraph.c;h=79e06a323686b67038949e75ac34bd62d588aeaa;hb=cb4dfb5d9803365b73db03e34dc9900301b19a80;hp=16962ee3cb385b7687dc70d0062870d0e2b35e9b;hpb=38f320d19a29a3e7d6a92cdb0b3ebec149d7c1a7;p=mono.git diff --git a/mono/mini/graph.c b/mono/mini/graph.c index 16962ee3cb3..79e06a32368 100644 --- a/mono/mini/graph.c +++ b/mono/mini/graph.c @@ -11,8 +11,6 @@ #include "mini.h" -extern guint8 mono_burg_arity []; - static char * convert_name (const char *str) { @@ -151,6 +149,8 @@ mono_draw_cfg (MonoCompile *cfg, FILE *fp) fprintf (fp, "}\n"); } +#if 0 + static void mono_print_label (FILE *fp, MonoInst *tree) { int arity; @@ -189,8 +189,8 @@ mono_print_label (FILE *fp, MonoInst *tree) { 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: @@ -219,19 +219,16 @@ mono_print_label (FILE *fp, MonoInst *tree) { fprintf (fp, ")]"); break; } - 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_CALL_REG: case OP_FCALL_REG: case OP_LCALL_REG: @@ -265,6 +262,8 @@ mono_print_label (FILE *fp, MonoInst *tree) { fprintf (fp, ")"); } +#endif + static void mono_draw_code_cfg (MonoCompile *cfg, FILE *fp) { @@ -291,8 +290,8 @@ mono_draw_code_cfg (MonoCompile *cfg, FILE *fp) 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_print_label (fp, inst); + MONO_BB_FOR_EACH_INS (bb, inst) { + //mono_print_label (fp, inst); fprintf (fp, "\\n"); }