From ce653bf162c96e1da12b8a11688aa15ddf7d1a02 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B6rn=20Gustavsson?= Date: Mon, 13 Jun 2011 14:53:31 +0200 Subject: Remove redundant 'next_arg' before 'next_instr' Fix the incorrect code that attempted to remove a single 'next_arg' instructions before 'next_instr'. --- erts/emulator/utils/beam_makeops | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'erts/emulator/utils') 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'; } # -- cgit v1.2.1