aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBjörn Gustavsson <[email protected]>2017-09-11 06:47:22 +0200
committerBjörn Gustavsson <[email protected]>2017-09-11 12:40:09 +0200
commit87b57377864d3161a79c65e32844d7539d1a9264 (patch)
tree0a02105a685f306c173e37bb08f675d38d71ddbc
parent3a7bddaae1b1d3c499f0c03f65a6986ad3bdeefe (diff)
downloadotp-87b57377864d3161a79c65e32844d7539d1a9264.tar.gz
otp-87b57377864d3161a79c65e32844d7539d1a9264.tar.bz2
otp-87b57377864d3161a79c65e32844d7539d1a9264.zip
beam_debug: Add support for printing 'S' operands
The 'S' operand type was added in 5bf73db9fd77.
-rw-r--r--erts/emulator/beam/beam_debug.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/erts/emulator/beam/beam_debug.c b/erts/emulator/beam/beam_debug.c
index 49414ae8fc..21e295c63a 100644
--- a/erts/emulator/beam/beam_debug.c
+++ b/erts/emulator/beam/beam_debug.c
@@ -489,6 +489,14 @@ print_op(fmtfn_t to, void *to_arg, int op, int size, BeamInstr* addr)
case 'n': /* Nil */
erts_print(to, to_arg, "[]");
break;
+ case 'S': /* Register */
+ {
+ Uint reg_type = (*ap & 1) ? 'y' : 'x';
+ Uint n = ap[0] / sizeof(Eterm);
+ erts_print(to, to_arg, "%c(%d)", reg_type, n);
+ ap++;
+ break;
+ }
case 's': /* Any source (tagged constant or register) */
tag = loader_tag(*ap);
if (tag == LOADER_X_REG) {