diff options
author | Björn Gustavsson <[email protected]> | 2016-09-05 11:43:24 +0200 |
---|---|---|
committer | Björn Gustavsson <[email protected]> | 2016-09-05 11:43:24 +0200 |
commit | 727f08889ab2096b540d466858ded1271bf261a8 (patch) | |
tree | ee9f45e63766d76ff3d7df52db294c26c0b1a92c /erts/emulator/beam/beam_emu.c | |
parent | 5dba22121d77237edae5cf805b9da5f7e056e532 (diff) | |
parent | d5ba65f0aa25768c1af7a1639eb73298b029eaf3 (diff) | |
download | otp-727f08889ab2096b540d466858ded1271bf261a8.tar.gz otp-727f08889ab2096b540d466858ded1271bf261a8.tar.bz2 otp-727f08889ab2096b540d466858ded1271bf261a8.zip |
Merge branch 'bjorn/erts/help-clang'
* bjorn/erts/help-clang:
Slightly reduce code size of process_main()
Diffstat (limited to 'erts/emulator/beam/beam_emu.c')
-rw-r--r-- | erts/emulator/beam/beam_emu.c | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/erts/emulator/beam/beam_emu.c b/erts/emulator/beam/beam_emu.c index c704323bb2..0ba06058a5 100644 --- a/erts/emulator/beam/beam_emu.c +++ b/erts/emulator/beam/beam_emu.c @@ -1078,7 +1078,7 @@ static Eterm make_arglist(Process* c_p, Eterm* reg, int a); void init_emulator(void) { - process_main(); + process_main(0, 0); } /* @@ -1225,7 +1225,7 @@ init_emulator(void) * the instructions' C labels to the loader. * The second call starts execution of BEAM code. This call never returns. */ -void process_main(void) +void process_main(Eterm * x_reg_array, FloatDef* f_reg_array) { static int init_done = 0; Process* c_p = NULL; @@ -1237,7 +1237,7 @@ void process_main(void) /* Pointer to X registers: x(1)..x(N); reg[0] is used when doing GC, * in all other cases x0 is used. */ - register Eterm* reg REG_xregs = NULL; + register Eterm* reg REG_xregs = x_reg_array; /* * Top of heap (next free location); grows upwards. @@ -1264,7 +1264,7 @@ void process_main(void) * X registers and floating point registers are located in * scheduler specific data. */ - register FloatDef *freg; + register FloatDef *freg = f_reg_array; /* * For keeping the negative old value of 'reds' when call saving is active. @@ -1350,8 +1350,6 @@ void process_main(void) start_time_i = c_p->i; } - reg = erts_proc_sched_data(c_p)->x_reg_array; - freg = erts_proc_sched_data(c_p)->f_reg_array; ERL_BITS_RELOAD_STATEP(c_p); { int reds; |