[PATCH 0/2] Add support for old systems based on LinuxThreads.
Leonard Crestez
lcrestez at ixiacom.com
Mon Oct 21 14:10:56 PDT 2013
Hello,
I attempted to port jemalloc to an old embedded system. It has linux
2.6.7/gcc 4.2.4/glibc 2.3.3 and uses linux threads instead of NPTL.
On this system there are a couple of additional recursive allocations
inside pthread_atfork and pthread_setspecific.
I fixed the first issues by delaying pthread_atfork (and hoping we don't
get forked during malloc_init_hard).
The second issue is nastier, see comments on the second patch.
Please let me know if you see anything obviously wrong. I did not test
much, without these patches I get an immediate deadlock on startup or on
the first allocation in a new thread. It should not affect systems with
real TLS (__thread) support.
Please keep me in CC, I'm not subscribed to the list.
Crestez Dan Leonard (2):
Delay pthread_atfork registering.
Add support for LinuxThreads.
include/jemalloc/internal/tsd.h | 63
+++++++++++++++++++++++++++++++++++++++++
src/jemalloc.c | 23 ++++++++-------
2 files changed, 75 insertions(+), 11 deletions(-)
--
1.8.4.rc3
More information about the jemalloc-discuss
mailing list