aboutsummaryrefslogtreecommitdiffstats
path: root/erts/emulator/beam/beam_load.c
diff options
context:
space:
mode:
authorBjörn Gustavsson <[email protected]>2011-02-26 07:12:05 +0100
committerBjörn Gustavsson <[email protected]>2011-03-29 07:13:27 +0200
commit459f531d22a16778d528d62978fc0772e30c9d30 (patch)
treee6bc7a3ce2a48421550708cb229694ae0bbab075 /erts/emulator/beam/beam_load.c
parenta76e46c02ae57a39178a5c663e2c0c5c4cbfb30f (diff)
downloadotp-459f531d22a16778d528d62978fc0772e30c9d30.tar.gz
otp-459f531d22a16778d528d62978fc0772e30c9d30.tar.bz2
otp-459f531d22a16778d528d62978fc0772e30c9d30.zip
BEAM loader: Simplify handling of the func_info/3 instruction
For some historical reason, the transformation of a func_info/3 instruction to the internal i_func_info/4 instruction is more involved than it needs to be. Remove the gen_func_info() function in the loader and use a simple transformation.
Diffstat (limited to 'erts/emulator/beam/beam_load.c')
-rw-r--r--erts/emulator/beam/beam_load.c32
1 files changed, 0 insertions, 32 deletions
diff --git a/erts/emulator/beam/beam_load.c b/erts/emulator/beam/beam_load.c
index 788cb4209c..c697b1ef31 100644
--- a/erts/emulator/beam/beam_load.c
+++ b/erts/emulator/beam/beam_load.c
@@ -480,8 +480,6 @@ static GenOp* gen_select_literals(LoaderState* stp, GenOpArg S,
GenOpArg* Rest);
static GenOp* const_select_val(LoaderState* stp, GenOpArg S, GenOpArg Fail,
GenOpArg Size, GenOpArg* Rest);
-static GenOp* gen_func_info(LoaderState* stp, GenOpArg mod, GenOpArg Func,
- GenOpArg arity, GenOpArg label);
static int freeze_code(LoaderState* stp);
@@ -3401,36 +3399,6 @@ const_select_val(LoaderState* stp, GenOpArg S, GenOpArg Fail,
return op;
}
-
-static GenOp*
-gen_func_info(LoaderState* stp, GenOpArg mod, GenOpArg func,
- GenOpArg arity, GenOpArg label)
-{
- GenOp* fi;
- GenOp* op;
-
- NEW_GENOP(stp, fi);
- fi->op = genop_i_func_info_4;
- fi->arity = 4;
- fi->a[0].type = TAG_u; /* untagged Zero */
- fi->a[0].val = 0;
- fi->a[1] = mod;
- fi->a[2] = func;
- fi->a[3] = arity;
-
- NEW_GENOP(stp, op);
- op->op = genop_label_1;
- op->arity = 1;
- op->a[0] = label;
-
- fi->next = op;
- op->next = NULL;
-
- return fi;
-}
-
-
-
static GenOp*
gen_make_fun2(LoaderState* stp, GenOpArg idx)
{