michael@0: Following are change highlights associated with official releases. Important michael@0: bug fixes are all mentioned, but internal enhancements are omitted here for michael@0: brevity (even though they are more fun to write about). Much more detail can be michael@0: found in the git revision history: michael@0: michael@0: http://www.canonware.com/cgi-bin/gitweb.cgi?p=jemalloc.git michael@0: git://canonware.com/jemalloc.git michael@0: michael@0: * 3.x.x (Not yet released) michael@0: michael@0: Bug fixes: michael@0: - Fix "arenas.extend" mallctl to output the number of arenas. michael@0: michael@0: * 3.2.0 (November 9, 2012) michael@0: michael@0: In addition to a couple of bug fixes, this version modifies page run michael@0: allocation and dirty page purging algorithms in order to better control michael@0: page-level virtual memory fragmentation. michael@0: michael@0: Incompatible changes: michael@0: - Change the "opt.lg_dirty_mult" default from 5 to 3 (32:1 to 8:1). michael@0: michael@0: Bug fixes: michael@0: - Fix dss/mmap allocation precedence code to use recyclable mmap memory only michael@0: after primary dss allocation fails. michael@0: - Fix deadlock in the "arenas.purge" mallctl. This regression was introduced michael@0: in 3.1.0 by the addition of the "arena..purge" mallctl. michael@0: michael@0: * 3.1.0 (October 16, 2012) michael@0: michael@0: New features: michael@0: - Auto-detect whether running inside Valgrind, thus removing the need to michael@0: manually specify MALLOC_CONF=valgrind:true. michael@0: - Add the "arenas.extend" mallctl, which allows applications to create michael@0: manually managed arenas. michael@0: - Add the ALLOCM_ARENA() flag for {,r,d}allocm(). michael@0: - Add the "opt.dss", "arena..dss", and "stats.arenas..dss" mallctls, michael@0: which provide control over dss/mmap precedence. michael@0: - Add the "arena..purge" mallctl, which obsoletes "arenas.purge". michael@0: - Define LG_QUANTUM for hppa. michael@0: michael@0: Incompatible changes: michael@0: - Disable tcache by default if running inside Valgrind, in order to avoid michael@0: making unallocated objects appear reachable to Valgrind. michael@0: - Drop const from malloc_usable_size() argument on Linux. michael@0: michael@0: Bug fixes: michael@0: - Fix heap profiling crash if sampled object is freed via realloc(p, 0). michael@0: - Remove const from __*_hook variable declarations, so that glibc can modify michael@0: them during process forking. michael@0: - Fix mlockall(2)/madvise(2) interaction. michael@0: - Fix fork(2)-related deadlocks. michael@0: - Fix error return value for "thread.tcache.enabled" mallctl. michael@0: michael@0: * 3.0.0 (May 11, 2012) michael@0: michael@0: Although this version adds some major new features, the primary focus is on michael@0: internal code cleanup that facilitates maintainability and portability, most michael@0: of which is not reflected in the ChangeLog. This is the first release to michael@0: incorporate substantial contributions from numerous other developers, and the michael@0: result is a more broadly useful allocator (see the git revision history for michael@0: contribution details). Note that the license has been unified, thanks to michael@0: Facebook granting a license under the same terms as the other copyright michael@0: holders (see COPYING). michael@0: michael@0: New features: michael@0: - Implement Valgrind support, redzones, and quarantine. michael@0: - Add support for additional platforms: michael@0: + FreeBSD michael@0: + Mac OS X Lion michael@0: + MinGW michael@0: + Windows (no support yet for replacing the system malloc) michael@0: - Add support for additional architectures: michael@0: + MIPS michael@0: + SH4 michael@0: + Tilera michael@0: - Add support for cross compiling. michael@0: - Add nallocm(), which rounds a request size up to the nearest size class michael@0: without actually allocating. michael@0: - Implement aligned_alloc() (blame C11). michael@0: - Add the "thread.tcache.enabled" mallctl. michael@0: - Add the "opt.prof_final" mallctl. michael@0: - Update pprof (from gperftools 2.0). michael@0: - Add the --with-mangling option. michael@0: - Add the --disable-experimental option. michael@0: - Add the --disable-munmap option, and make it the default on Linux. michael@0: - Add the --enable-mremap option, which disables use of mremap(2) by default. michael@0: michael@0: Incompatible changes: michael@0: - Enable stats by default. michael@0: - Enable fill by default. michael@0: - Disable lazy locking by default. michael@0: - Rename the "tcache.flush" mallctl to "thread.tcache.flush". michael@0: - Rename the "arenas.pagesize" mallctl to "arenas.page". michael@0: - Change the "opt.lg_prof_sample" default from 0 to 19 (1 B to 512 KiB). michael@0: - Change the "opt.prof_accum" default from true to false. michael@0: michael@0: Removed features: michael@0: - Remove the swap feature, including the "config.swap", "swap.avail", michael@0: "swap.prezeroed", "swap.nfds", and "swap.fds" mallctls. michael@0: - Remove highruns statistics, including the michael@0: "stats.arenas..bins..highruns" and michael@0: "stats.arenas..lruns..highruns" mallctls. michael@0: - As part of small size class refactoring, remove the "opt.lg_[qc]space_max", michael@0: "arenas.cacheline", "arenas.subpage", "arenas.[tqcs]space_{min,max}", and michael@0: "arenas.[tqcs]bins" mallctls. michael@0: - Remove the "arenas.chunksize" mallctl. michael@0: - Remove the "opt.lg_prof_tcmax" option. michael@0: - Remove the "opt.lg_prof_bt_max" option. michael@0: - Remove the "opt.lg_tcache_gc_sweep" option. michael@0: - Remove the --disable-tiny option, including the "config.tiny" mallctl. michael@0: - Remove the --enable-dynamic-page-shift configure option. michael@0: - Remove the --enable-sysv configure option. michael@0: michael@0: Bug fixes: michael@0: - Fix a statistics-related bug in the "thread.arena" mallctl that could cause michael@0: invalid statistics and crashes. michael@0: - Work around TLS deallocation via free() on Linux. This bug could cause michael@0: write-after-free memory corruption. michael@0: - Fix a potential deadlock that could occur during interval- and michael@0: growth-triggered heap profile dumps. michael@0: - Fix large calloc() zeroing bugs due to dropping chunk map unzeroed flags. michael@0: - Fix chunk_alloc_dss() to stop claiming memory is zeroed. This bug could michael@0: cause memory corruption and crashes with --enable-dss specified. michael@0: - Fix fork-related bugs that could cause deadlock in children between fork michael@0: and exec. michael@0: - Fix malloc_stats_print() to honor 'b' and 'l' in the opts parameter. michael@0: - Fix realloc(p, 0) to act like free(p). michael@0: - Do not enforce minimum alignment in memalign(). michael@0: - Check for NULL pointer in malloc_usable_size(). michael@0: - Fix an off-by-one heap profile statistics bug that could be observed in michael@0: interval- and growth-triggered heap profiles. michael@0: - Fix the "epoch" mallctl to update cached stats even if the passed in epoch michael@0: is 0. michael@0: - Fix bin->runcur management to fix a layout policy bug. This bug did not michael@0: affect correctness. michael@0: - Fix a bug in choose_arena_hard() that potentially caused more arenas to be michael@0: initialized than necessary. michael@0: - Add missing "opt.lg_tcache_max" mallctl implementation. michael@0: - Use glibc allocator hooks to make mixed allocator usage less likely. michael@0: - Fix build issues for --disable-tcache. michael@0: - Don't mangle pthread_create() when --with-private-namespace is specified. michael@0: michael@0: * 2.2.5 (November 14, 2011) michael@0: michael@0: Bug fixes: michael@0: - Fix huge_ralloc() race when using mremap(2). This is a serious bug that michael@0: could cause memory corruption and/or crashes. michael@0: - Fix huge_ralloc() to maintain chunk statistics. michael@0: - Fix malloc_stats_print(..., "a") output. michael@0: michael@0: * 2.2.4 (November 5, 2011) michael@0: michael@0: Bug fixes: michael@0: - Initialize arenas_tsd before using it. This bug existed for 2.2.[0-3], as michael@0: well as for --disable-tls builds in earlier releases. michael@0: - Do not assume a 4 KiB page size in test/rallocm.c. michael@0: michael@0: * 2.2.3 (August 31, 2011) michael@0: michael@0: This version fixes numerous bugs related to heap profiling. michael@0: michael@0: Bug fixes: michael@0: - Fix a prof-related race condition. This bug could cause memory corruption, michael@0: but only occurred in non-default configurations (prof_accum:false). michael@0: - Fix off-by-one backtracing issues (make sure that prof_alloc_prep() is michael@0: excluded from backtraces). michael@0: - Fix a prof-related bug in realloc() (only triggered by OOM errors). michael@0: - Fix prof-related bugs in allocm() and rallocm(). michael@0: - Fix prof_tdata_cleanup() for --disable-tls builds. michael@0: - Fix a relative include path, to fix objdir builds. michael@0: michael@0: * 2.2.2 (July 30, 2011) michael@0: michael@0: Bug fixes: michael@0: - Fix a build error for --disable-tcache. michael@0: - Fix assertions in arena_purge() (for real this time). michael@0: - Add the --with-private-namespace option. This is a workaround for symbol michael@0: conflicts that can inadvertently arise when using static libraries. michael@0: michael@0: * 2.2.1 (March 30, 2011) michael@0: michael@0: Bug fixes: michael@0: - Implement atomic operations for x86/x64. This fixes compilation failures michael@0: for versions of gcc that are still in wide use. michael@0: - Fix an assertion in arena_purge(). michael@0: michael@0: * 2.2.0 (March 22, 2011) michael@0: michael@0: This version incorporates several improvements to algorithms and data michael@0: structures that tend to reduce fragmentation and increase speed. michael@0: michael@0: New features: michael@0: - Add the "stats.cactive" mallctl. michael@0: - Update pprof (from google-perftools 1.7). michael@0: - Improve backtracing-related configuration logic, and add the michael@0: --disable-prof-libgcc option. michael@0: michael@0: Bug fixes: michael@0: - Change default symbol visibility from "internal", to "hidden", which michael@0: decreases the overhead of library-internal function calls. michael@0: - Fix symbol visibility so that it is also set on OS X. michael@0: - Fix a build dependency regression caused by the introduction of the .pic.o michael@0: suffix for PIC object files. michael@0: - Add missing checks for mutex initialization failures. michael@0: - Don't use libgcc-based backtracing except on x64, where it is known to work. michael@0: - Fix deadlocks on OS X that were due to memory allocation in michael@0: pthread_mutex_lock(). michael@0: - Heap profiling-specific fixes: michael@0: + Fix memory corruption due to integer overflow in small region index michael@0: computation, when using a small enough sample interval that profiling michael@0: context pointers are stored in small run headers. michael@0: + Fix a bootstrap ordering bug that only occurred with TLS disabled. michael@0: + Fix a rallocm() rsize bug. michael@0: + Fix error detection bugs for aligned memory allocation. michael@0: michael@0: * 2.1.3 (March 14, 2011) michael@0: michael@0: Bug fixes: michael@0: - Fix a cpp logic regression (due to the "thread.{de,}allocatedp" mallctl fix michael@0: for OS X in 2.1.2). michael@0: - Fix a "thread.arena" mallctl bug. michael@0: - Fix a thread cache stats merging bug. michael@0: michael@0: * 2.1.2 (March 2, 2011) michael@0: michael@0: Bug fixes: michael@0: - Fix "thread.{de,}allocatedp" mallctl for OS X. michael@0: - Add missing jemalloc.a to build system. michael@0: michael@0: * 2.1.1 (January 31, 2011) michael@0: michael@0: Bug fixes: michael@0: - Fix aligned huge reallocation (affected allocm()). michael@0: - Fix the ALLOCM_LG_ALIGN macro definition. michael@0: - Fix a heap dumping deadlock. michael@0: - Fix a "thread.arena" mallctl bug. michael@0: michael@0: * 2.1.0 (December 3, 2010) michael@0: michael@0: This version incorporates some optimizations that can't quite be considered michael@0: bug fixes. michael@0: michael@0: New features: michael@0: - Use Linux's mremap(2) for huge object reallocation when possible. michael@0: - Avoid locking in mallctl*() when possible. michael@0: - Add the "thread.[de]allocatedp" mallctl's. michael@0: - Convert the manual page source from roff to DocBook, and generate both roff michael@0: and HTML manuals. michael@0: michael@0: Bug fixes: michael@0: - Fix a crash due to incorrect bootstrap ordering. This only impacted michael@0: --enable-debug --enable-dss configurations. michael@0: - Fix a minor statistics bug for mallctl("swap.avail", ...). michael@0: michael@0: * 2.0.1 (October 29, 2010) michael@0: michael@0: Bug fixes: michael@0: - Fix a race condition in heap profiling that could cause undefined behavior michael@0: if "opt.prof_accum" were disabled. michael@0: - Add missing mutex unlocks for some OOM error paths in the heap profiling michael@0: code. michael@0: - Fix a compilation error for non-C99 builds. michael@0: michael@0: * 2.0.0 (October 24, 2010) michael@0: michael@0: This version focuses on the experimental *allocm() API, and on improved michael@0: run-time configuration/introspection. Nonetheless, numerous performance michael@0: improvements are also included. michael@0: michael@0: New features: michael@0: - Implement the experimental {,r,s,d}allocm() API, which provides a superset michael@0: of the functionality available via malloc(), calloc(), posix_memalign(), michael@0: realloc(), malloc_usable_size(), and free(). These functions can be used to michael@0: allocate/reallocate aligned zeroed memory, ask for optional extra memory michael@0: during reallocation, prevent object movement during reallocation, etc. michael@0: - Replace JEMALLOC_OPTIONS/JEMALLOC_PROF_PREFIX with MALLOC_CONF, which is michael@0: more human-readable, and more flexible. For example: michael@0: JEMALLOC_OPTIONS=AJP michael@0: is now: michael@0: MALLOC_CONF=abort:true,fill:true,stats_print:true michael@0: - Port to Apple OS X. Sponsored by Mozilla. michael@0: - Make it possible for the application to control thread-->arena mappings via michael@0: the "thread.arena" mallctl. michael@0: - Add compile-time support for all TLS-related functionality via pthreads TSD. michael@0: This is mainly of interest for OS X, which does not support TLS, but has a michael@0: TSD implementation with similar performance. michael@0: - Override memalign() and valloc() if they are provided by the system. michael@0: - Add the "arenas.purge" mallctl, which can be used to synchronously purge all michael@0: dirty unused pages. michael@0: - Make cumulative heap profiling data optional, so that it is possible to michael@0: limit the amount of memory consumed by heap profiling data structures. michael@0: - Add per thread allocation counters that can be accessed via the michael@0: "thread.allocated" and "thread.deallocated" mallctls. michael@0: michael@0: Incompatible changes: michael@0: - Remove JEMALLOC_OPTIONS and malloc_options (see MALLOC_CONF above). michael@0: - Increase default backtrace depth from 4 to 128 for heap profiling. michael@0: - Disable interval-based profile dumps by default. michael@0: michael@0: Bug fixes: michael@0: - Remove bad assertions in fork handler functions. These assertions could michael@0: cause aborts for some combinations of configure settings. michael@0: - Fix strerror_r() usage to deal with non-standard semantics in GNU libc. michael@0: - Fix leak context reporting. This bug tended to cause the number of contexts michael@0: to be underreported (though the reported number of objects and bytes were michael@0: correct). michael@0: - Fix a realloc() bug for large in-place growing reallocation. This bug could michael@0: cause memory corruption, but it was hard to trigger. michael@0: - Fix an allocation bug for small allocations that could be triggered if michael@0: multiple threads raced to create a new run of backing pages. michael@0: - Enhance the heap profiler to trigger samples based on usable size, rather michael@0: than request size. michael@0: - Fix a heap profiling bug due to sometimes losing track of requested object michael@0: size for sampled objects. michael@0: michael@0: * 1.0.3 (August 12, 2010) michael@0: michael@0: Bug fixes: michael@0: - Fix the libunwind-based implementation of stack backtracing (used for heap michael@0: profiling). This bug could cause zero-length backtraces to be reported. michael@0: - Add a missing mutex unlock in library initialization code. If multiple michael@0: threads raced to initialize malloc, some of them could end up permanently michael@0: blocked. michael@0: michael@0: * 1.0.2 (May 11, 2010) michael@0: michael@0: Bug fixes: michael@0: - Fix junk filling of large objects, which could cause memory corruption. michael@0: - Add MAP_NORESERVE support for chunk mapping, because otherwise virtual michael@0: memory limits could cause swap file configuration to fail. Contributed by michael@0: Jordan DeLong. michael@0: michael@0: * 1.0.1 (April 14, 2010) michael@0: michael@0: Bug fixes: michael@0: - Fix compilation when --enable-fill is specified. michael@0: - Fix threads-related profiling bugs that affected accuracy and caused memory michael@0: to be leaked during thread exit. michael@0: - Fix dirty page purging race conditions that could cause crashes. michael@0: - Fix crash in tcache flushing code during thread destruction. michael@0: michael@0: * 1.0.0 (April 11, 2010) michael@0: michael@0: This release focuses on speed and run-time introspection. Numerous michael@0: algorithmic improvements make this release substantially faster than its michael@0: predecessors. michael@0: michael@0: New features: michael@0: - Implement autoconf-based configuration system. michael@0: - Add mallctl*(), for the purposes of introspection and run-time michael@0: configuration. michael@0: - Make it possible for the application to manually flush a thread's cache, via michael@0: the "tcache.flush" mallctl. michael@0: - Base maximum dirty page count on proportion of active memory. michael@0: - Compute various addtional run-time statistics, including per size class michael@0: statistics for large objects. michael@0: - Expose malloc_stats_print(), which can be called repeatedly by the michael@0: application. michael@0: - Simplify the malloc_message() signature to only take one string argument, michael@0: and incorporate an opaque data pointer argument for use by the application michael@0: in combination with malloc_stats_print(). michael@0: - Add support for allocation backed by one or more swap files, and allow the michael@0: application to disable over-commit if swap files are in use. michael@0: - Implement allocation profiling and leak checking. michael@0: michael@0: Removed features: michael@0: - Remove the dynamic arena rebalancing code, since thread-specific caching michael@0: reduces its utility. michael@0: michael@0: Bug fixes: michael@0: - Modify chunk allocation to work when address space layout randomization michael@0: (ASLR) is in use. michael@0: - Fix thread cleanup bugs related to TLS destruction. michael@0: - Handle 0-size allocation requests in posix_memalign(). michael@0: - Fix a chunk leak. The leaked chunks were never touched, so this impacted michael@0: virtual memory usage, but not physical memory usage. michael@0: michael@0: * linux_2008082[78]a (August 27/28, 2008) michael@0: michael@0: These snapshot releases are the simple result of incorporating Linux-specific michael@0: support into the FreeBSD malloc sources. michael@0: michael@0: -------------------------------------------------------------------------------- michael@0: vim:filetype=text:textwidth=80