diff options
author | Sverker Eriksson <[email protected]> | 2011-07-26 17:18:10 +0200 |
---|---|---|
committer | Sverker Eriksson <[email protected]> | 2011-07-26 17:18:10 +0200 |
commit | cc6f835e0b93156cab0d2cbd563af7b6ca68bf6d (patch) | |
tree | d5aa9d46f805ea3c2ea76f03a29b3973563fa3e5 /erts | |
parent | d551ab8c2c6b11f43be8844b951a81c780e25e3c (diff) | |
parent | 9cd77a455b7faa05e8f9364bdbd16c57836e71c9 (diff) | |
download | otp-cc6f835e0b93156cab0d2cbd563af7b6ca68bf6d.tar.gz otp-cc6f835e0b93156cab0d2cbd563af7b6ca68bf6d.tar.bz2 otp-cc6f835e0b93156cab0d2cbd563af7b6ca68bf6d.zip |
Merge branch 'dev' into major
Diffstat (limited to 'erts')
-rw-r--r-- | erts/emulator/beam/erl_alloc.c | 2 | ||||
-rw-r--r-- | erts/emulator/beam/erl_alloc.h | 8 | ||||
-rw-r--r-- | erts/emulator/beam/erl_alloc_util.c | 9 | ||||
-rw-r--r-- | erts/emulator/beam/erl_instrument.c | 8 |
4 files changed, 12 insertions, 15 deletions
diff --git a/erts/emulator/beam/erl_alloc.c b/erts/emulator/beam/erl_alloc.c index 840534ec5e..57127963fc 100644 --- a/erts/emulator/beam/erl_alloc.c +++ b/erts/emulator/beam/erl_alloc.c @@ -597,7 +597,7 @@ erts_alloc_init(int *argc, char **argv, ErtsAllocInitOpts *eaiop) /* Init low memory variants by cloning */ init.sbmbc_low_alloc = init.sbmbc_alloc; init.sbmbc_low_alloc.init.util.name_prefix = "sbmbc_low_"; - init.sbmbc_low_alloc.init.util.alloc_no = ERTS_ALC_A_STANDARD_LOW; + init.sbmbc_low_alloc.init.util.alloc_no = ERTS_ALC_A_SBMBC_LOW; init.sbmbc_low_alloc.init.util.low_mem = 1; init.std_low_alloc = init.std_alloc; diff --git a/erts/emulator/beam/erl_alloc.h b/erts/emulator/beam/erl_alloc.h index ce792d4d17..c35a60da22 100644 --- a/erts/emulator/beam/erl_alloc.h +++ b/erts/emulator/beam/erl_alloc.h @@ -99,6 +99,14 @@ unsigned long erts_alc_test(unsigned long, #define ERTS_ALC_MIN_LONG_LIVED_TIME (10*60*1000) +#if HALFWORD_HEAP +#define ERTS_IS_SBMBC_ALLOCATOR_NO__(NO) \ + ((NO) == ERTS_ALC_A_SBMBC || (NO) == ERTS_ALC_A_SBMBC_LOW) +#else +#define ERTS_IS_SBMBC_ALLOCATOR_NO__(NO) \ + ((NO) == ERTS_ALC_A_SBMBC) +#endif + typedef struct { int alloc_util; int enabled; diff --git a/erts/emulator/beam/erl_alloc_util.c b/erts/emulator/beam/erl_alloc_util.c index 19c552d8cd..d51ed0c36d 100644 --- a/erts/emulator/beam/erl_alloc_util.c +++ b/erts/emulator/beam/erl_alloc_util.c @@ -3436,10 +3436,7 @@ erts_alcu_start(Allctr_t *allctr, AllctrInit_t *init) allctr->sbmbc_threshold = init->sbmbct; if (!erts_have_sbmbc_alloc -#if HALFWORD_HEAP - || allctr->alloc_no == ERTS_ALC_A_SBMBC_LOW -#endif - || allctr->alloc_no == ERTS_ALC_A_SBMBC) + || ERTS_IS_SBMBC_ALLOCATOR_NO__(allctr->alloc_no)) allctr->sbmbc_threshold = 0; if (!allctr->sbmbc_threshold) @@ -3466,14 +3463,14 @@ erts_alcu_start(Allctr_t *allctr, AllctrInit_t *init) #ifdef ERTS_ENABLE_LOCK_COUNT erts_mtx_init_x_opt(&allctr->mutex, - allctr->alloc_no == ERTS_ALC_A_SBMBC + ERTS_IS_SBMBC_ALLOCATOR_NO__(allctr->alloc_no) ? "sbmbc_alloc" : "alcu_allocator", make_small(allctr->alloc_no), ERTS_LCNT_LT_ALLOC); #else erts_mtx_init_x(&allctr->mutex, - allctr->alloc_no == ERTS_ALC_A_SBMBC + ERTS_IS_SBMBC_ALLOCATOR_NO__(allctr->alloc_no) ? "sbmbc_alloc" : "alcu_allocator", make_small(allctr->alloc_no)); diff --git a/erts/emulator/beam/erl_instrument.c b/erts/emulator/beam/erl_instrument.c index c5615818f2..04ea004ef7 100644 --- a/erts/emulator/beam/erl_instrument.c +++ b/erts/emulator/beam/erl_instrument.c @@ -1152,14 +1152,6 @@ erts_instr_get_type_info(Process *proc) return res; } -#if HALFWORD_HEAP -#define ERTS_IS_SBMBC_ALLOCATOR_NO__(NO) \ - ((NO) == ERTS_ALC_A_SBMBC || (NO) == ERTS_ALC_A_SBMBC_LOW) -#else -#define ERTS_IS_SBMBC_ALLOCATOR_NO__(NO) \ - ((NO) == ERTS_ALC_A_SBMBC) -#endif - Uint erts_instr_init(int stat, int map_stat) { |