aboutsummaryrefslogtreecommitdiffstats
path: root/erts/emulator/beam/erl_message.c
diff options
context:
space:
mode:
authorBjörn-Egil Dahlberg <[email protected]>2016-07-29 17:16:53 +0200
committerBjörn-Egil Dahlberg <[email protected]>2016-08-01 11:00:22 +0200
commite52fa24451306080be39a35444cf52210982b41a (patch)
treef9e285a9c32330d1e1a0956682551aa0238145fc /erts/emulator/beam/erl_message.c
parentdbea5c4023ec6ac59bb1988711532682a032536d (diff)
downloadotp-e52fa24451306080be39a35444cf52210982b41a.tar.gz
otp-e52fa24451306080be39a35444cf52210982b41a.tar.bz2
otp-e52fa24451306080be39a35444cf52210982b41a.zip
erts: Refactor literal purge area arguments
Diffstat (limited to 'erts/emulator/beam/erl_message.c')
-rw-r--r--erts/emulator/beam/erl_message.c14
1 files changed, 6 insertions, 8 deletions
diff --git a/erts/emulator/beam/erl_message.c b/erts/emulator/beam/erl_message.c
index 14ee07a304..e9f0586edd 100644
--- a/erts/emulator/beam/erl_message.c
+++ b/erts/emulator/beam/erl_message.c
@@ -697,8 +697,8 @@ erts_send_message(Process* sender,
#ifdef SHCOPY_SEND
erts_shcopy_t info;
#else
- Eterm *lit_purge_ptr = erts_clrange.ptr;
- Uint lit_purge_sz = erts_clrange.sz;
+ erts_literal_area_t litarea;
+ INITIALIZE_LITERAL_PURGE_AREA(litarea);
#endif
#ifdef USE_VM_PROBES
@@ -744,7 +744,7 @@ erts_send_message(Process* sender,
INITIALIZE_SHCOPY(info);
msize = copy_shared_calculate(message, &info);
#else
- msize = size_object_litopt(message, lit_purge_ptr, lit_purge_sz);
+ msize = size_object_litopt(message, &litarea);
#endif
mp = erts_alloc_message_heap_state(receiver,
&receiver_state,
@@ -763,8 +763,7 @@ erts_send_message(Process* sender,
DESTROY_SHCOPY(info);
#else
if (is_not_immed(message))
- message = copy_struct_litopt(message, msize, &hp, ohp,
- lit_purge_ptr, lit_purge_sz);
+ message = copy_struct_litopt(message, msize, &hp, ohp, &litarea);
#endif
if (is_immed(stoken))
token = stoken;
@@ -800,7 +799,7 @@ erts_send_message(Process* sender,
INITIALIZE_SHCOPY(info);
msize = copy_shared_calculate(message, &info);
#else
- msize = size_object_litopt(message, lit_purge_ptr, lit_purge_sz);
+ msize = size_object_litopt(message, &litarea);
#endif
mp = erts_alloc_message_heap_state(receiver,
&receiver_state,
@@ -814,8 +813,7 @@ erts_send_message(Process* sender,
DESTROY_SHCOPY(info);
#else
if (is_not_immed(message))
- message = copy_struct_litopt(message, msize, &hp, ohp,
- lit_purge_ptr, lit_purge_sz);
+ message = copy_struct_litopt(message, msize, &hp, ohp, &litarea);
#endif
}
#ifdef USE_VM_PROBES