aboutsummaryrefslogtreecommitdiffstats
path: root/erts
diff options
context:
space:
mode:
authorBjörn Gustavsson <[email protected]>2011-06-13 14:53:31 +0200
committerBjörn Gustavsson <[email protected]>2011-10-11 11:35:38 +0200
commitce653bf162c96e1da12b8a11688aa15ddf7d1a02 (patch)
tree0f44003bb53d510eaf2e3f4ce92e8263342f655a /erts
parent3b3bb767433a333750b090908fa370d957bbbfa2 (diff)
downloadotp-ce653bf162c96e1da12b8a11688aa15ddf7d1a02.tar.gz
otp-ce653bf162c96e1da12b8a11688aa15ddf7d1a02.tar.bz2
otp-ce653bf162c96e1da12b8a11688aa15ddf7d1a02.zip
Remove redundant 'next_arg' before 'next_instr'
Fix the incorrect code that attempted to remove a single 'next_arg' instructions before 'next_instr'.
Diffstat (limited to 'erts')
-rwxr-xr-xerts/emulator/utils/beam_makeops3
1 files changed, 2 insertions, 1 deletions
diff --git a/erts/emulator/utils/beam_makeops b/erts/emulator/utils/beam_makeops
index 75047f22bd..b5187dd676 100755
--- a/erts/emulator/utils/beam_makeops
+++ b/erts/emulator/utils/beam_makeops
@@ -1446,8 +1446,9 @@ sub tr_gen_from {
push(@code, &make_op('', 'next_arg'));
}
}
+ # Remove redundant 'next_arg' instructions before 'next_instr'.
+ pop(@code) while is_instr($code[$#code], 'next_arg');
push(@code, &make_op('', 'next_instr'));
- pop(@code) if $code[$#code]->[1][0] eq 'next_arg';
}
#