diff options
author | Lennart Poettering <lennart@poettering.net> | 2009-09-15 22:26:59 +0200 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2009-09-15 22:26:59 +0200 |
commit | 208e3c94ae00e35444bfee434031319b7981b1ab (patch) | |
tree | e16958490f9dba8e304ec0f6a4e7731e8e171775 | |
parent | 31bbf1ba735cbeff5640424d5d0c06a94614764d (diff) |
explain in more detail why we don't support jemalloc
-rw-r--r-- | mutrace.c | 10 |
1 files changed, 10 insertions, 0 deletions
@@ -228,6 +228,16 @@ static void setup(void) { "mutrace: alternative memory allocator (jemalloc?) which is not compatible with\n" "mutrace: mutrace. Please rebuild your program with the standard memory\n" "mutrace: allocator or fix mutrace to handle yours correctly.\n"); + + /* The reason for this is that jemalloc and other + * allocators tend to call pthread_mutex_xxx() from + * the allocator. However, we need to call malloc() + * ourselves from some mutex operations so this might + * create an endless loop eventually overflowing the + * stack. glibc's malloc() does locking too but uses + * lock routines that do not end up calling + * pthread_mutex_xxx(). */ + real_exit(1); } |