diff options
author | Sverker Eriksson <[email protected]> | 2017-01-23 17:37:49 +0100 |
---|---|---|
committer | Sverker Eriksson <[email protected]> | 2017-01-23 17:37:49 +0100 |
commit | adce9147ba242a8aef7d10cbbe8e4375ecdff0aa (patch) | |
tree | 688710d8612f621f7bcec662d1cf6f6fc5804ee3 /erts/emulator/beam/erl_gc.c | |
parent | 3f5530bf1ec283bbb8fd75e57947fe3218148ca1 (diff) | |
parent | 9e862df2bf26b9b1d79ba3b447945b7c0612e3d0 (diff) | |
download | otp-adce9147ba242a8aef7d10cbbe8e4375ecdff0aa.tar.gz otp-adce9147ba242a8aef7d10cbbe8e4375ecdff0aa.tar.bz2 otp-adce9147ba242a8aef7d10cbbe8e4375ecdff0aa.zip |
Merge branch 'sverker/ASSERT_IN_ENV'
* sverker/ASSERT_IN_ENV:
erts: Add macro ERTS_PROC_LOCKS_HIGHER_THAN
erts: Cleanup and extra assertions in nif_SUITE.c
erts: Cleanup enif_make_reverse_list
erts: Add assertions for correct ErlNifEnv
erts: Make erts_dbg_within_proc available
# Conflicts:
# erts/emulator/beam/erl_gc.h
Diffstat (limited to 'erts/emulator/beam/erl_gc.c')
-rw-r--r-- | erts/emulator/beam/erl_gc.c | 12 |
1 files changed, 3 insertions, 9 deletions
diff --git a/erts/emulator/beam/erl_gc.c b/erts/emulator/beam/erl_gc.c index 6815d76776..3a3ad820b5 100644 --- a/erts/emulator/beam/erl_gc.c +++ b/erts/emulator/beam/erl_gc.c @@ -3439,8 +3439,8 @@ erts_max_heap_size(Eterm arg, Uint *max_heap_size, Uint *max_heap_flags) #if defined(DEBUG) || defined(ERTS_OFFHEAP_DEBUG) -static int -within2(Eterm *ptr, Process *p, Eterm *real_htop) +int +erts_dbg_within_proc(Eterm *ptr, Process *p, Eterm *real_htop) { ErlHeapFragment* bp; ErtsMessage* mp; @@ -3486,12 +3486,6 @@ within2(Eterm *ptr, Process *p, Eterm *real_htop) return 0; } -int -within(Eterm *ptr, Process *p) -{ - return within2(ptr, p, NULL); -} - #endif #ifdef ERTS_OFFHEAP_DEBUG @@ -3546,7 +3540,7 @@ erts_check_off_heap2(Process *p, Eterm *htop) else if (oheap <= u.ep && u.ep < ohtop) old = 1; else { - ERTS_CHK_OFFHEAP_ASSERT(within2(u.ep, p, htop)); + ERTS_CHK_OFFHEAP_ASSERT(erts_dbg_within_proc(u.ep, p, htop)); } } |