aboutsummaryrefslogtreecommitdiffstats
path: root/erts/emulator/utils
diff options
context:
space:
mode:
authorBjörn Gustavsson <[email protected]>2017-09-05 08:30:30 +0200
committerBjörn Gustavsson <[email protected]>2017-09-14 10:16:14 +0200
commit76b4ff5c5db9610ecd09b11d3816f25b1e6b58f8 (patch)
treeaecb19fae8594e23d90ef7fcb387a6e5a8b766ee /erts/emulator/utils
parentef43e32b450df2fdf1c731e9be03693fb0b69e31 (diff)
downloadotp-76b4ff5c5db9610ecd09b11d3816f25b1e6b58f8.tar.gz
otp-76b4ff5c5db9610ecd09b11d3816f25b1e6b58f8.tar.bz2
otp-76b4ff5c5db9610ecd09b11d3816f25b1e6b58f8.zip
Add information about offset to common group start position
Diffstat (limited to 'erts/emulator/utils')
-rwxr-xr-xerts/emulator/utils/beam_makeops8
1 files changed, 7 insertions, 1 deletions
diff --git a/erts/emulator/utils/beam_makeops b/erts/emulator/utils/beam_makeops
index e55d3eadb5..ccbd0dbaf4 100755
--- a/erts/emulator/utils/beam_makeops
+++ b/erts/emulator/utils/beam_makeops
@@ -80,6 +80,7 @@ my %gen_opnum;
my %num_specific;
my %gen_to_spec;
my %specific_op;
+my %group_size; # Group size for specific operators.
my %gen_arity;
my @gen_arity;
@@ -623,7 +624,11 @@ sub emulator_output {
$sep = ",";
}
$init .= "}";
- init_item($print_name, $init, $involves_r, $size, $pack, $sign);
+ my $adj = 0;
+ if (defined $group_size{$print_name}) {
+ $adj = $size - $group_size{$print_name};
+ }
+ init_item($print_name, $init, $involves_r, $size, $adj, $pack, $sign);
$op_to_name[$spec_opnum] = $instr;
$spec_opnum++;
}
@@ -1171,6 +1176,7 @@ sub combine_instruction_group {
if ($opcase ne '') {
$gcode .= "OpCase($opcase):\n";
push @opcase_labels, $opcase;
+ $group_size{$opcase} = $group_size + 1;
}
if ($num_references{$label}) {
$gcode .= "$label:\n";