From 300925cc0de95650cf5b13e938ccf702a8eadc9e Mon Sep 17 00:00:00 2001 From: Lukas Larsson Date: Thu, 4 May 2017 17:07:41 +0200 Subject: erts: temp_alloc can no longer be disabled temp_alloc is used in such a way that if it ever results in a malloc/free sequence it will slow down the system alot. So it will no longer be possible to disable it and it will not be disabled when using +Mea min. OTP-14651 --- erts/doc/src/erts_alloc.xml | 6 +++--- erts/emulator/beam/erl_alloc.c | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) (limited to 'erts') diff --git a/erts/doc/src/erts_alloc.xml b/erts/doc/src/erts_alloc.xml index d3f725ef99..580780e73b 100644 --- a/erts/doc/src/erts_alloc.xml +++ b/erts/doc/src/erts_alloc.xml @@ -87,9 +87,9 @@ the number of system calls made. -

sys_alloc and literal_alloc are always enabled and - cannot be disabled. exec_alloc is only available if it is needed - and cannot be disabled. mseg_alloc is always enabled if it is +

sys_alloc, literal_alloc and temp_alloc are always + enabled and cannot be disabled. exec_alloc is only available if it + is needed and cannot be disabled. mseg_alloc is always enabled if it is available and an allocator that uses it is enabled. All other allocators can be enabled or disabled. By default all allocators are enabled. diff --git a/erts/emulator/beam/erl_alloc.c b/erts/emulator/beam/erl_alloc.c index 1c365f906b..88285d8be6 100644 --- a/erts/emulator/beam/erl_alloc.c +++ b/erts/emulator/beam/erl_alloc.c @@ -385,6 +385,7 @@ set_default_temp_alloc_opts(struct au_init *ip) SET_DEFAULT_ALLOC_OPTS(ip); ip->enable = AU_ALLOC_DEFAULT_ENABLE(1); ip->thr_spec = 1; + ip->disable_allowed = 0; ip->carrier_migration_allowed = 0; ip->atype = AFIT; ip->init.util.name_prefix = "temp_"; @@ -1492,8 +1493,7 @@ handle_args(int *argc, char **argv, erts_alc_hndl_args_init_t *init) &init->ll_alloc, &init->driver_alloc, &init->fix_alloc, - &init->sl_alloc, - &init->temp_alloc + &init->sl_alloc /* test_alloc not affected by +Mea??? or +Mu??? */ }; int aui_sz = (int) sizeof(aui)/sizeof(aui[0]); -- cgit v1.2.3