Commit Graph

2070 Commits

Author SHA1 Message Date
Jason Evans
3ee7a5c5b0 Remove the dynamic rebalancing code, since magazines reduce its utility. 2009-12-29 00:09:15 -08:00
Jason Evans
569432cffd Implement thread-aware allocation event tracing. 2009-12-29 00:09:15 -08:00
Jason Evans
90895cf859 Add --with-jemalloc-prefix, which supports API mangling.
Rename jemalloc_options-->malloc_options and jemalloc_message-->malloc_message.
2009-12-29 00:09:15 -08:00
Jason Evans
bca042dfeb Use __restrict rather than restrict. 2009-12-29 00:09:15 -08:00
Jason Evans
87704ea339 Make sure that there are no more than 256 size clases, since size2bin can only
encode bin indices in [0..255].
2009-11-12 17:57:57 -08:00
Jason Evans
1517cc6df7 Integrate architecture portability fixes.
Submitted by:	Ingvar Hagelund
2009-11-09 15:25:02 -08:00
Jason Evans
a162402282 Fix configure docs (--enable-lazy-lock --> --disable-lazy-lock).
Fix some style nits.

Ignore the jemalloc/bin directory.
2009-11-09 14:58:12 -08:00
Jason Evans
d3068c3f46 _pt_thread_death_internal(), which is part of Linux's nptl pthreads
implementation, calls free() after calling TSD destructors.  This was causing a
crash during thread exit, since the magazine rack was no longer valid for the
thread.  Fix this by using a special mag_rack value to indicate that
deallocation should bypass the magazine machinery.
2009-11-09 14:58:12 -08:00
Jason Evans
6f89d4b806 Modify chunk_alloc_mmap() to support address space layout randomization (ASLR). 2009-11-09 14:58:12 -08:00
Jason Evans
a25d0a8a72 Update assertions in realloc() and free() to allow for deallocation during
initializtion.
2009-11-09 14:57:38 -08:00
Jason Evans
662a017c1d Integrate mtrgraph and mtrplay. 2009-07-01 19:24:31 -07:00
Jason Evans
f3340ca8d5 Add configure tests for CFLAGS settings.
Add configure test for __asm__ syntax.

Add configure test for __attribute__ syntax.
2009-06-30 16:17:05 -07:00
Jason Evans
b8f0a65173 Fix various compiler warnings.
Reported by:	Mark Rabkin
2009-06-29 09:41:43 -07:00
Jason Evans
a9b0125e97 Minor documentation and comment cleanups. 2009-06-26 16:34:13 -07:00
Jason Evans
cc00a15770 Clean up the manpage and conditionalize various portions according to how
jemalloc is configured.

Modify arena_malloc() API to avoid unnecessary choose_arena() calls.  Remove
unnecessary code from choose_arena().

Enable lazy-lock by default, now that choose_arena() is both faster and out of
the critical path.

Implement objdir support in the build system.
2009-06-25 18:06:48 -07:00
Jason Evans
b7924f50c0 Implement configuration system.
Implement minimal Makefile.

Make compile-time-optional jemalloc features controllable via configure
options (debug, stats, tiny, mag, balance, dss).

Conditionally exclude most of the opt_* run-time options, based on configure
options (fill, xmalloc, sysv).

Implement optional --enable-dynamic-page-shift.

Implement optional --enable-lazy-lock.

Re-order malloc_init_hard() and use the malloc_initializer variable to support
recursive allocation in malloc_ncpus().

Add mag_rack_tsd in order to receive notifications of thread termination.

Add jemalloc.h.
2009-06-23 19:01:18 -07:00
Jason Evans
4450b830b6 Merge FreeBSD's malloc(3) and posix_memalign(3) manpages to create jemalloc(3). 2009-06-22 17:44:39 -07:00
Jason Evans
804c9ec3af Fix various namespace issues. 2009-06-22 17:44:33 -07:00
Jason Evans
c9658dd35c Merge code from the original jemalloc_linux port. 2009-06-22 14:44:08 -07:00
Jason Evans
289053c95b Import pristine FreeBSD sources. 2009-06-22 12:08:42 -07:00