From e1019cbba7a66788a068b6df1a1caf2d643ef65b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B6rn=20Gustavsson?= Date: Fri, 30 Mar 2012 11:54:04 +0200 Subject: Eliminate R_REG_DEF --- erts/emulator/beam/beam_debug.c | 22 ++-------------------- 1 file changed, 2 insertions(+), 20 deletions(-) (limited to 'erts/emulator/beam/beam_debug.c') diff --git a/erts/emulator/beam/beam_debug.c b/erts/emulator/beam/beam_debug.c index 8a35ad17c6..00d0b27178 100644 --- a/erts/emulator/beam/beam_debug.c +++ b/erts/emulator/beam/beam_debug.c @@ -452,21 +452,13 @@ print_op(int to, void *to_arg, int op, int size, BeamInstr* addr) case 's': /* Any source (tagged constant or register) */ tag = beam_reg_tag(*ap); if (tag == X_REG_DEF) { - if (reg_index(*ap) == 0) { - erts_print(to, to_arg, "x[0]"); - } else { - erts_print(to, to_arg, "x(%d)", reg_index(*ap)); - } + erts_print(to, to_arg, "x(%d)", reg_index(*ap)); ap++; break; } else if (tag == Y_REG_DEF) { erts_print(to, to_arg, "y(%d)", reg_index(*ap) - CP_SIZE); ap++; break; - } else if (tag == R_REG_DEF) { - erts_print(to, to_arg, "x(0)"); - ap++; - break; } /*FALLTHROUGH*/ case 'a': /* Tagged atom */ @@ -483,18 +475,11 @@ print_op(int to, void *to_arg, int op, int size, BeamInstr* addr) case 'd': /* Destination (x(0), x(N), y(N)) */ switch (beam_reg_tag(*ap)) { case X_REG_DEF: - if (reg_index(*ap) == 0) { - erts_print(to, to_arg, "x[0]"); - } else { - erts_print(to, to_arg, "x(%d)", reg_index(*ap)); - } + erts_print(to, to_arg, "x(%d)", reg_index(*ap)); break; case Y_REG_DEF: erts_print(to, to_arg, "y(%d)", reg_index(*ap) - CP_SIZE); break; - case R_REG_DEF: - erts_print(to, to_arg, "x(0)"); - break; } ap++; break; @@ -677,9 +662,6 @@ print_op(int to, void *to_arg, int op, int size, BeamInstr* addr) erts_print(to, to_arg, " %T", (Eterm) ap[0]); } else { switch ((ap[0] >> 2) & 0x03) { - case R_REG_DEF: - erts_print(to, to_arg, " x(0)"); - break; case X_REG_DEF: erts_print(to, to_arg, " x(%d)", ap[0] >> 4); break; -- cgit v1.2.3