Skip to content

Commit

Permalink
improve flowgraph debug utility
Browse files Browse the repository at this point in the history
  • Loading branch information
carljm committed Sep 14, 2023
1 parent baaac99 commit 7c9b8f7
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions Python/flowgraph.c
Original file line number Diff line number Diff line change
Expand Up @@ -261,8 +261,8 @@ dump_instr(cfg_instr *i)
if (HAS_TARGET(i->i_opcode)) {
sprintf(arg, "target: %p [%d] ", i->i_target, i->i_oparg);
}
fprintf(stderr, "line: %d, opcode: %d %s%s\n",
i->i_loc.lineno, i->i_opcode, arg, jump);
fprintf(stderr, "line: %d, opcode: %d (%s) %s%s\n",
i->i_loc.lineno, i->i_opcode, _PyOpcode_OpName[i->i_opcode], arg, jump);
}

static inline int
Expand Down Expand Up @@ -2661,4 +2661,3 @@ _PyCfg_OptimizedCfgToInstructionSequence(cfg_builder *g,

return SUCCESS;
}

0 comments on commit 7c9b8f7

Please sign in to comment.