1a78e148bSantirezFollowing are change highlights associated with official releases. Important 2*5268379eSantirezbug fixes are all mentioned, but some internal enhancements are omitted here for 3*5268379eSantirezbrevity. Much more detail can be found in the git revision history: 4a78e148bSantirez 5fceef8e0Santirez https://github.com/jemalloc/jemalloc 6fceef8e0Santirez 7*5268379eSantirez* 4.0.3 (September 24, 2015) 8*5268379eSantirez 9*5268379eSantirez This bugfix release continues the trend of xallocx() and heap profiling fixes. 10*5268379eSantirez 11*5268379eSantirez Bug fixes: 12*5268379eSantirez - Fix xallocx(..., MALLOCX_ZERO) to zero all trailing bytes of large 13*5268379eSantirez allocations when --enable-cache-oblivious configure option is enabled. 14*5268379eSantirez - Fix xallocx(..., MALLOCX_ZERO) to zero trailing bytes of huge allocations 15*5268379eSantirez when resizing from/to a size class that is not a multiple of the chunk size. 16*5268379eSantirez - Fix prof_tctx_dump_iter() to filter out nodes that were created after heap 17*5268379eSantirez profile dumping started. 18*5268379eSantirez - Work around a potentially bad thread-specific data initialization 19*5268379eSantirez interaction with NPTL (glibc's pthreads implementation). 20*5268379eSantirez 21*5268379eSantirez* 4.0.2 (September 21, 2015) 22*5268379eSantirez 23*5268379eSantirez This bugfix release addresses a few bugs specific to heap profiling. 24*5268379eSantirez 25*5268379eSantirez Bug fixes: 26*5268379eSantirez - Fix ixallocx_prof_sample() to never modify nor create sampled small 27*5268379eSantirez allocations. xallocx() is in general incapable of moving small allocations, 28*5268379eSantirez so this fix removes buggy code without loss of generality. 29*5268379eSantirez - Fix irallocx_prof_sample() to always allocate large regions, even when 30*5268379eSantirez alignment is non-zero. 31*5268379eSantirez - Fix prof_alloc_rollback() to read tdata from thread-specific data rather 32*5268379eSantirez than dereferencing a potentially invalid tctx. 33*5268379eSantirez 34*5268379eSantirez* 4.0.1 (September 15, 2015) 35*5268379eSantirez 36*5268379eSantirez This is a bugfix release that is somewhat high risk due to the amount of 37*5268379eSantirez refactoring required to address deep xallocx() problems. As a side effect of 38*5268379eSantirez these fixes, xallocx() now tries harder to partially fulfill requests for 39*5268379eSantirez optional extra space. Note that a couple of minor heap profiling 40*5268379eSantirez optimizations are included, but these are better thought of as performance 41*5268379eSantirez fixes that were integral to disovering most of the other bugs. 42*5268379eSantirez 43*5268379eSantirez Optimizations: 44*5268379eSantirez - Avoid a chunk metadata read in arena_prof_tctx_set(), since it is in the 45*5268379eSantirez fast path when heap profiling is enabled. Additionally, split a special 46*5268379eSantirez case out into arena_prof_tctx_reset(), which also avoids chunk metadata 47*5268379eSantirez reads. 48*5268379eSantirez - Optimize irallocx_prof() to optimistically update the sampler state. The 49*5268379eSantirez prior implementation appears to have been a holdover from when 50*5268379eSantirez rallocx()/xallocx() functionality was combined as rallocm(). 51*5268379eSantirez 52*5268379eSantirez Bug fixes: 53*5268379eSantirez - Fix TLS configuration such that it is enabled by default for platforms on 54*5268379eSantirez which it works correctly. 55*5268379eSantirez - Fix arenas_cache_cleanup() and arena_get_hard() to handle 56*5268379eSantirez allocation/deallocation within the application's thread-specific data 57*5268379eSantirez cleanup functions even after arenas_cache is torn down. 58*5268379eSantirez - Fix xallocx() bugs related to size+extra exceeding HUGE_MAXCLASS. 59*5268379eSantirez - Fix chunk purge hook calls for in-place huge shrinking reallocation to 60*5268379eSantirez specify the old chunk size rather than the new chunk size. This bug caused 61*5268379eSantirez no correctness issues for the default chunk purge function, but was 62*5268379eSantirez visible to custom functions set via the "arena.<i>.chunk_hooks" mallctl. 63*5268379eSantirez - Fix heap profiling bugs: 64*5268379eSantirez + Fix heap profiling to distinguish among otherwise identical sample sites 65*5268379eSantirez with interposed resets (triggered via the "prof.reset" mallctl). This bug 66*5268379eSantirez could cause data structure corruption that would most likely result in a 67*5268379eSantirez segfault. 68*5268379eSantirez + Fix irealloc_prof() to prof_alloc_rollback() on OOM. 69*5268379eSantirez + Make one call to prof_active_get_unlocked() per allocation event, and use 70*5268379eSantirez the result throughout the relevant functions that handle an allocation 71*5268379eSantirez event. Also add a missing check in prof_realloc(). These fixes protect 72*5268379eSantirez allocation events against concurrent prof_active changes. 73*5268379eSantirez + Fix ixallocx_prof() to pass usize_max and zero to ixallocx_prof_sample() 74*5268379eSantirez in the correct order. 75*5268379eSantirez + Fix prof_realloc() to call prof_free_sampled_object() after calling 76*5268379eSantirez prof_malloc_sample_object(). Prior to this fix, if tctx and old_tctx were 77*5268379eSantirez the same, the tctx could have been prematurely destroyed. 78*5268379eSantirez - Fix portability bugs: 79*5268379eSantirez + Don't bitshift by negative amounts when encoding/decoding run sizes in 80*5268379eSantirez chunk header maps. This affected systems with page sizes greater than 8 81*5268379eSantirez KiB. 82*5268379eSantirez + Rename index_t to szind_t to avoid an existing type on Solaris. 83*5268379eSantirez + Add JEMALLOC_CXX_THROW to the memalign() function prototype, in order to 84*5268379eSantirez match glibc and avoid compilation errors when including both 85*5268379eSantirez jemalloc/jemalloc.h and malloc.h in C++ code. 86*5268379eSantirez + Don't assume that /bin/sh is appropriate when running size_classes.sh 87*5268379eSantirez during configuration. 88*5268379eSantirez + Consider __sparcv9 a synonym for __sparc64__ when defining LG_QUANTUM. 89*5268379eSantirez + Link tests to librt if it contains clock_gettime(2). 90*5268379eSantirez 91*5268379eSantirez* 4.0.0 (August 17, 2015) 92*5268379eSantirez 93*5268379eSantirez This version contains many speed and space optimizations, both minor and 94*5268379eSantirez major. The major themes are generalization, unification, and simplification. 95*5268379eSantirez Although many of these optimizations cause no visible behavior change, their 96*5268379eSantirez cumulative effect is substantial. 97*5268379eSantirez 98*5268379eSantirez New features: 99*5268379eSantirez - Normalize size class spacing to be consistent across the complete size 100*5268379eSantirez range. By default there are four size classes per size doubling, but this 101*5268379eSantirez is now configurable via the --with-lg-size-class-group option. Also add the 102*5268379eSantirez --with-lg-page, --with-lg-page-sizes, --with-lg-quantum, and 103*5268379eSantirez --with-lg-tiny-min options, which can be used to tweak page and size class 104*5268379eSantirez settings. Impacts: 105*5268379eSantirez + Worst case performance for incrementally growing/shrinking reallocation 106*5268379eSantirez is improved because there are far fewer size classes, and therefore 107*5268379eSantirez copying happens less often. 108*5268379eSantirez + Internal fragmentation is limited to 20% for all but the smallest size 109*5268379eSantirez classes (those less than four times the quantum). (1B + 4 KiB) 110*5268379eSantirez and (1B + 4 MiB) previously suffered nearly 50% internal fragmentation. 111*5268379eSantirez + Chunk fragmentation tends to be lower because there are fewer distinct run 112*5268379eSantirez sizes to pack. 113*5268379eSantirez - Add support for explicit tcaches. The "tcache.create", "tcache.flush", and 114*5268379eSantirez "tcache.destroy" mallctls control tcache lifetime and flushing, and the 115*5268379eSantirez MALLOCX_TCACHE(tc) and MALLOCX_TCACHE_NONE flags to the *allocx() API 116*5268379eSantirez control which tcache is used for each operation. 117*5268379eSantirez - Implement per thread heap profiling, as well as the ability to 118*5268379eSantirez enable/disable heap profiling on a per thread basis. Add the "prof.reset", 119*5268379eSantirez "prof.lg_sample", "thread.prof.name", "thread.prof.active", 120*5268379eSantirez "opt.prof_thread_active_init", "prof.thread_active_init", and 121*5268379eSantirez "thread.prof.active" mallctls. 122*5268379eSantirez - Add support for per arena application-specified chunk allocators, configured 123*5268379eSantirez via the "arena.<i>.chunk_hooks" mallctl. 124*5268379eSantirez - Refactor huge allocation to be managed by arenas, so that arenas now 125*5268379eSantirez function as general purpose independent allocators. This is important in 126*5268379eSantirez the context of user-specified chunk allocators, aside from the scalability 127*5268379eSantirez benefits. Related new statistics: 128*5268379eSantirez + The "stats.arenas.<i>.huge.allocated", "stats.arenas.<i>.huge.nmalloc", 129*5268379eSantirez "stats.arenas.<i>.huge.ndalloc", and "stats.arenas.<i>.huge.nrequests" 130*5268379eSantirez mallctls provide high level per arena huge allocation statistics. 131*5268379eSantirez + The "arenas.nhchunks", "arenas.hchunk.<i>.size", 132*5268379eSantirez "stats.arenas.<i>.hchunks.<j>.nmalloc", 133*5268379eSantirez "stats.arenas.<i>.hchunks.<j>.ndalloc", 134*5268379eSantirez "stats.arenas.<i>.hchunks.<j>.nrequests", and 135*5268379eSantirez "stats.arenas.<i>.hchunks.<j>.curhchunks" mallctls provide per size class 136*5268379eSantirez statistics. 137*5268379eSantirez - Add the 'util' column to malloc_stats_print() output, which reports the 138*5268379eSantirez proportion of available regions that are currently in use for each small 139*5268379eSantirez size class. 140*5268379eSantirez - Add "alloc" and "free" modes for for junk filling (see the "opt.junk" 141*5268379eSantirez mallctl), so that it is possible to separately enable junk filling for 142*5268379eSantirez allocation versus deallocation. 143*5268379eSantirez - Add the jemalloc-config script, which provides information about how 144*5268379eSantirez jemalloc was configured, and how to integrate it into application builds. 145*5268379eSantirez - Add metadata statistics, which are accessible via the "stats.metadata", 146*5268379eSantirez "stats.arenas.<i>.metadata.mapped", and 147*5268379eSantirez "stats.arenas.<i>.metadata.allocated" mallctls. 148*5268379eSantirez - Add the "stats.resident" mallctl, which reports the upper limit of 149*5268379eSantirez physically resident memory mapped by the allocator. 150*5268379eSantirez - Add per arena control over unused dirty page purging, via the 151*5268379eSantirez "arenas.lg_dirty_mult", "arena.<i>.lg_dirty_mult", and 152*5268379eSantirez "stats.arenas.<i>.lg_dirty_mult" mallctls. 153*5268379eSantirez - Add the "prof.gdump" mallctl, which makes it possible to toggle the gdump 154*5268379eSantirez feature on/off during program execution. 155*5268379eSantirez - Add sdallocx(), which implements sized deallocation. The primary 156*5268379eSantirez optimization over dallocx() is the removal of a metadata read, which often 157*5268379eSantirez suffers an L1 cache miss. 158*5268379eSantirez - Add missing header includes in jemalloc/jemalloc.h, so that applications 159*5268379eSantirez only have to #include <jemalloc/jemalloc.h>. 160*5268379eSantirez - Add support for additional platforms: 161*5268379eSantirez + Bitrig 162*5268379eSantirez + Cygwin 163*5268379eSantirez + DragonFlyBSD 164*5268379eSantirez + iOS 165*5268379eSantirez + OpenBSD 166*5268379eSantirez + OpenRISC/or1k 167*5268379eSantirez 168*5268379eSantirez Optimizations: 169*5268379eSantirez - Maintain dirty runs in per arena LRUs rather than in per arena trees of 170*5268379eSantirez dirty-run-containing chunks. In practice this change significantly reduces 171*5268379eSantirez dirty page purging volume. 172*5268379eSantirez - Integrate whole chunks into the unused dirty page purging machinery. This 173*5268379eSantirez reduces the cost of repeated huge allocation/deallocation, because it 174*5268379eSantirez effectively introduces a cache of chunks. 175*5268379eSantirez - Split the arena chunk map into two separate arrays, in order to increase 176*5268379eSantirez cache locality for the frequently accessed bits. 177*5268379eSantirez - Move small run metadata out of runs, into arena chunk headers. This reduces 178*5268379eSantirez run fragmentation, smaller runs reduce external fragmentation for small size 179*5268379eSantirez classes, and packed (less uniformly aligned) metadata layout improves CPU 180*5268379eSantirez cache set distribution. 181*5268379eSantirez - Randomly distribute large allocation base pointer alignment relative to page 182*5268379eSantirez boundaries in order to more uniformly utilize CPU cache sets. This can be 183*5268379eSantirez disabled via the --disable-cache-oblivious configure option, and queried via 184*5268379eSantirez the "config.cache_oblivious" mallctl. 185*5268379eSantirez - Micro-optimize the fast paths for the public API functions. 186*5268379eSantirez - Refactor thread-specific data to reside in a single structure. This assures 187*5268379eSantirez that only a single TLS read is necessary per call into the public API. 188*5268379eSantirez - Implement in-place huge allocation growing and shrinking. 189*5268379eSantirez - Refactor rtree (radix tree for chunk lookups) to be lock-free, and make 190*5268379eSantirez additional optimizations that reduce maximum lookup depth to one or two 191*5268379eSantirez levels. This resolves what was a concurrency bottleneck for per arena huge 192*5268379eSantirez allocation, because a global data structure is critical for determining 193*5268379eSantirez which arenas own which huge allocations. 194*5268379eSantirez 195*5268379eSantirez Incompatible changes: 196*5268379eSantirez - Replace --enable-cc-silence with --disable-cc-silence to suppress spurious 197*5268379eSantirez warnings by default. 198*5268379eSantirez - Assure that the constness of malloc_usable_size()'s return type matches that 199*5268379eSantirez of the system implementation. 200*5268379eSantirez - Change the heap profile dump format to support per thread heap profiling, 201*5268379eSantirez rename pprof to jeprof, and enhance it with the --thread=<n> option. As a 202*5268379eSantirez result, the bundled jeprof must now be used rather than the upstream 203*5268379eSantirez (gperftools) pprof. 204*5268379eSantirez - Disable "opt.prof_final" by default, in order to avoid atexit(3), which can 205*5268379eSantirez internally deadlock on some platforms. 206*5268379eSantirez - Change the "arenas.nlruns" mallctl type from size_t to unsigned. 207*5268379eSantirez - Replace the "stats.arenas.<i>.bins.<j>.allocated" mallctl with 208*5268379eSantirez "stats.arenas.<i>.bins.<j>.curregs". 209*5268379eSantirez - Ignore MALLOC_CONF in set{uid,gid,cap} binaries. 210*5268379eSantirez - Ignore MALLOCX_ARENA(a) in dallocx(), in favor of using the 211*5268379eSantirez MALLOCX_TCACHE(tc) and MALLOCX_TCACHE_NONE flags to control tcache usage. 212*5268379eSantirez 213*5268379eSantirez Removed features: 214*5268379eSantirez - Remove the *allocm() API, which is superseded by the *allocx() API. 215*5268379eSantirez - Remove the --enable-dss options, and make dss non-optional on all platforms 216*5268379eSantirez which support sbrk(2). 217*5268379eSantirez - Remove the "arenas.purge" mallctl, which was obsoleted by the 218*5268379eSantirez "arena.<i>.purge" mallctl in 3.1.0. 219*5268379eSantirez - Remove the unnecessary "opt.valgrind" mallctl; jemalloc automatically 220*5268379eSantirez detects whether it is running inside Valgrind. 221*5268379eSantirez - Remove the "stats.huge.allocated", "stats.huge.nmalloc", and 222*5268379eSantirez "stats.huge.ndalloc" mallctls. 223*5268379eSantirez - Remove the --enable-mremap option. 224*5268379eSantirez - Remove the "stats.chunks.current", "stats.chunks.total", and 225*5268379eSantirez "stats.chunks.high" mallctls. 226*5268379eSantirez 227*5268379eSantirez Bug fixes: 228*5268379eSantirez - Fix the cactive statistic to decrease (rather than increase) when active 229*5268379eSantirez memory decreases. This regression was first released in 3.5.0. 230*5268379eSantirez - Fix OOM handling in memalign() and valloc(). A variant of this bug existed 231*5268379eSantirez in all releases since 2.0.0, which introduced these functions. 232*5268379eSantirez - Fix an OOM-related regression in arena_tcache_fill_small(), which could 233*5268379eSantirez cause cache corruption on OOM. This regression was present in all releases 234*5268379eSantirez from 2.2.0 through 3.6.0. 235*5268379eSantirez - Fix size class overflow handling for malloc(), posix_memalign(), memalign(), 236*5268379eSantirez calloc(), and realloc() when profiling is enabled. 237*5268379eSantirez - Fix the "arena.<i>.dss" mallctl to return an error if "primary" or 238*5268379eSantirez "secondary" precedence is specified, but sbrk(2) is not supported. 239*5268379eSantirez - Fix fallback lg_floor() implementations to handle extremely large inputs. 240*5268379eSantirez - Ensure the default purgeable zone is after the default zone on OS X. 241*5268379eSantirez - Fix latent bugs in atomic_*(). 242*5268379eSantirez - Fix the "arena.<i>.dss" mallctl to handle read-only calls. 243*5268379eSantirez - Fix tls_model configuration to enable the initial-exec model when possible. 244*5268379eSantirez - Mark malloc_conf as a weak symbol so that the application can override it. 245*5268379eSantirez - Correctly detect glibc's adaptive pthread mutexes. 246*5268379eSantirez - Fix the --without-export configure option. 247*5268379eSantirez 248fceef8e0Santirez* 3.6.0 (March 31, 2014) 249fceef8e0Santirez 250fceef8e0Santirez This version contains a critical bug fix for a regression present in 3.5.0 and 251fceef8e0Santirez 3.5.1. 252fceef8e0Santirez 253fceef8e0Santirez Bug fixes: 254fceef8e0Santirez - Fix a regression in arena_chunk_alloc() that caused crashes during 255fceef8e0Santirez small/large allocation if chunk allocation failed. In the absence of this 256fceef8e0Santirez bug, chunk allocation failure would result in allocation failure, e.g. NULL 257fceef8e0Santirez return from malloc(). This regression was introduced in 3.5.0. 258fceef8e0Santirez - Fix backtracing for gcc intrinsics-based backtracing by specifying 259fceef8e0Santirez -fno-omit-frame-pointer to gcc. Note that the application (and all the 260fceef8e0Santirez libraries it links to) must also be compiled with this option for 261fceef8e0Santirez backtracing to be reliable. 262fceef8e0Santirez - Use dss allocation precedence for huge allocations as well as small/large 263fceef8e0Santirez allocations. 264*5268379eSantirez - Fix test assertion failure message formatting. This bug did not manifest on 265fceef8e0Santirez x86_64 systems because of implementation subtleties in va_list. 266fceef8e0Santirez - Fix inconsequential test failures for hash and SFMT code. 267fceef8e0Santirez 268fceef8e0Santirez New features: 269fceef8e0Santirez - Support heap profiling on FreeBSD. This feature depends on the proc 270fceef8e0Santirez filesystem being mounted during heap profile dumping. 271fceef8e0Santirez 272fceef8e0Santirez* 3.5.1 (February 25, 2014) 273fceef8e0Santirez 274fceef8e0Santirez This version primarily addresses minor bugs in test code. 275fceef8e0Santirez 276fceef8e0Santirez Bug fixes: 277fceef8e0Santirez - Configure Solaris/Illumos to use MADV_FREE. 278fceef8e0Santirez - Fix junk filling for mremap(2)-based huge reallocation. This is only 279fceef8e0Santirez relevant if configuring with the --enable-mremap option specified. 280fceef8e0Santirez - Avoid compilation failure if 'restrict' C99 keyword is not supported by the 281fceef8e0Santirez compiler. 282fceef8e0Santirez - Add a configure test for SSE2 rather than assuming it is usable on i686 283fceef8e0Santirez systems. This fixes test compilation errors, especially on 32-bit Linux 284fceef8e0Santirez systems. 285fceef8e0Santirez - Fix mallctl argument size mismatches (size_t vs. uint64_t) in the stats unit 286fceef8e0Santirez test. 287fceef8e0Santirez - Fix/remove flawed alignment-related overflow tests. 288fceef8e0Santirez - Prevent compiler optimizations that could change backtraces in the 289fceef8e0Santirez prof_accum unit test. 290fceef8e0Santirez 291fceef8e0Santirez* 3.5.0 (January 22, 2014) 292fceef8e0Santirez 293fceef8e0Santirez This version focuses on refactoring and automated testing, though it also 294fceef8e0Santirez includes some non-trivial heap profiling optimizations not mentioned below. 295fceef8e0Santirez 296fceef8e0Santirez New features: 297fceef8e0Santirez - Add the *allocx() API, which is a successor to the experimental *allocm() 298fceef8e0Santirez API. The *allocx() functions are slightly simpler to use because they have 299fceef8e0Santirez fewer parameters, they directly return the results of primary interest, and 300fceef8e0Santirez mallocx()/rallocx() avoid the strict aliasing pitfall that 301fceef8e0Santirez allocm()/rallocm() share with posix_memalign(). Note that *allocm() is 302fceef8e0Santirez slated for removal in the next non-bugfix release. 303fceef8e0Santirez - Add support for LinuxThreads. 304fceef8e0Santirez 305fceef8e0Santirez Bug fixes: 306fceef8e0Santirez - Unless heap profiling is enabled, disable floating point code and don't link 307fceef8e0Santirez with libm. This, in combination with e.g. EXTRA_CFLAGS=-mno-sse on x64 308fceef8e0Santirez systems, makes it possible to completely disable floating point register 309fceef8e0Santirez use. Some versions of glibc neglect to save/restore caller-saved floating 310fceef8e0Santirez point registers during dynamic lazy symbol loading, and the symbol loading 311fceef8e0Santirez code uses whatever malloc the application happens to have linked/loaded 312fceef8e0Santirez with, the result being potential floating point register corruption. 313fceef8e0Santirez - Report ENOMEM rather than EINVAL if an OOM occurs during heap profiling 314fceef8e0Santirez backtrace creation in imemalign(). This bug impacted posix_memalign() and 315fceef8e0Santirez aligned_alloc(). 316fceef8e0Santirez - Fix a file descriptor leak in a prof_dump_maps() error path. 317fceef8e0Santirez - Fix prof_dump() to close the dump file descriptor for all relevant error 318fceef8e0Santirez paths. 319fceef8e0Santirez - Fix rallocm() to use the arena specified by the ALLOCM_ARENA(s) flag for 320fceef8e0Santirez allocation, not just deallocation. 321fceef8e0Santirez - Fix a data race for large allocation stats counters. 322fceef8e0Santirez - Fix a potential infinite loop during thread exit. This bug occurred on 323fceef8e0Santirez Solaris, and could affect other platforms with similar pthreads TSD 324fceef8e0Santirez implementations. 325fceef8e0Santirez - Don't junk-fill reallocations unless usable size changes. This fixes a 326fceef8e0Santirez violation of the *allocx()/*allocm() semantics. 327fceef8e0Santirez - Fix growing large reallocation to junk fill new space. 328fceef8e0Santirez - Fix huge deallocation to junk fill when munmap is disabled. 329fceef8e0Santirez - Change the default private namespace prefix from empty to je_, and change 330fceef8e0Santirez --with-private-namespace-prefix so that it prepends an additional prefix 331fceef8e0Santirez rather than replacing je_. This reduces the likelihood of applications 332fceef8e0Santirez which statically link jemalloc experiencing symbol name collisions. 333fceef8e0Santirez - Add missing private namespace mangling (relevant when 334fceef8e0Santirez --with-private-namespace is specified). 335fceef8e0Santirez - Add and use JEMALLOC_INLINE_C so that static inline functions are marked as 336fceef8e0Santirez static even for debug builds. 337fceef8e0Santirez - Add a missing mutex unlock in a malloc_init_hard() error path. In practice 338fceef8e0Santirez this error path is never executed. 339fceef8e0Santirez - Fix numerous bugs in malloc_strotumax() error handling/reporting. These 340fceef8e0Santirez bugs had no impact except for malformed inputs. 341fceef8e0Santirez - Fix numerous bugs in malloc_snprintf(). These bugs were not exercised by 342fceef8e0Santirez existing calls, so they had no impact. 343fceef8e0Santirez 344fceef8e0Santirez* 3.4.1 (October 20, 2013) 345fceef8e0Santirez 346fceef8e0Santirez Bug fixes: 347fceef8e0Santirez - Fix a race in the "arenas.extend" mallctl that could cause memory corruption 348fceef8e0Santirez of internal data structures and subsequent crashes. 349fceef8e0Santirez - Fix Valgrind integration flaws that caused Valgrind warnings about reads of 350fceef8e0Santirez uninitialized memory in: 351fceef8e0Santirez + arena chunk headers 352fceef8e0Santirez + internal zero-initialized data structures (relevant to tcache and prof 353fceef8e0Santirez code) 354fceef8e0Santirez - Preserve errno during the first allocation. A readlink(2) call during 355fceef8e0Santirez initialization fails unless /etc/malloc.conf exists, so errno was typically 356fceef8e0Santirez set during the first allocation prior to this fix. 357fceef8e0Santirez - Fix compilation warnings reported by gcc 4.8.1. 358fceef8e0Santirez 359fceef8e0Santirez* 3.4.0 (June 2, 2013) 360fceef8e0Santirez 361fceef8e0Santirez This version is essentially a small bugfix release, but the addition of 362fceef8e0Santirez aarch64 support requires that the minor version be incremented. 363fceef8e0Santirez 364fceef8e0Santirez Bug fixes: 365fceef8e0Santirez - Fix race-triggered deadlocks in chunk_record(). These deadlocks were 366fceef8e0Santirez typically triggered by multiple threads concurrently deallocating huge 367fceef8e0Santirez objects. 368fceef8e0Santirez 369fceef8e0Santirez New features: 370fceef8e0Santirez - Add support for the aarch64 architecture. 371fceef8e0Santirez 372fceef8e0Santirez* 3.3.1 (March 6, 2013) 373fceef8e0Santirez 374fceef8e0Santirez This version fixes bugs that are typically encountered only when utilizing 375fceef8e0Santirez custom run-time options. 376fceef8e0Santirez 377fceef8e0Santirez Bug fixes: 378fceef8e0Santirez - Fix a locking order bug that could cause deadlock during fork if heap 379fceef8e0Santirez profiling were enabled. 380fceef8e0Santirez - Fix a chunk recycling bug that could cause the allocator to lose track of 381fceef8e0Santirez whether a chunk was zeroed. On FreeBSD, NetBSD, and OS X, it could cause 382fceef8e0Santirez corruption if allocating via sbrk(2) (unlikely unless running with the 383fceef8e0Santirez "dss:primary" option specified). This was completely harmless on Linux 384fceef8e0Santirez unless using mlockall(2) (and unlikely even then, unless the 385fceef8e0Santirez --disable-munmap configure option or the "dss:primary" option was 386fceef8e0Santirez specified). This regression was introduced in 3.1.0 by the 387fceef8e0Santirez mlockall(2)/madvise(2) interaction fix. 388fceef8e0Santirez - Fix TLS-related memory corruption that could occur during thread exit if the 389fceef8e0Santirez thread never allocated memory. Only the quarantine and prof facilities were 390fceef8e0Santirez susceptible. 391fceef8e0Santirez - Fix two quarantine bugs: 392fceef8e0Santirez + Internal reallocation of the quarantined object array leaked the old 393fceef8e0Santirez array. 394fceef8e0Santirez + Reallocation failure for internal reallocation of the quarantined object 395fceef8e0Santirez array (very unlikely) resulted in memory corruption. 396fceef8e0Santirez - Fix Valgrind integration to annotate all internally allocated memory in a 397fceef8e0Santirez way that keeps Valgrind happy about internal data structure access. 398fceef8e0Santirez - Fix building for s390 systems. 399fceef8e0Santirez 400fceef8e0Santirez* 3.3.0 (January 23, 2013) 401fceef8e0Santirez 402fceef8e0Santirez This version includes a few minor performance improvements in addition to the 403fceef8e0Santirez listed new features and bug fixes. 404fceef8e0Santirez 405fceef8e0Santirez New features: 406fceef8e0Santirez - Add clipping support to lg_chunk option processing. 407fceef8e0Santirez - Add the --enable-ivsalloc option. 408fceef8e0Santirez - Add the --without-export option. 409fceef8e0Santirez - Add the --disable-zone-allocator option. 410fceef8e0Santirez 411fceef8e0Santirez Bug fixes: 412fceef8e0Santirez - Fix "arenas.extend" mallctl to output the number of arenas. 413fceef8e0Santirez - Fix chunk_recycle() to unconditionally inform Valgrind that returned memory 414fceef8e0Santirez is undefined. 415fceef8e0Santirez - Fix build break on FreeBSD related to alloca.h. 416a78e148bSantirez 4177383c3b1Santirez* 3.2.0 (November 9, 2012) 4187383c3b1Santirez 4197383c3b1Santirez In addition to a couple of bug fixes, this version modifies page run 4207383c3b1Santirez allocation and dirty page purging algorithms in order to better control 4217383c3b1Santirez page-level virtual memory fragmentation. 4227383c3b1Santirez 4237383c3b1Santirez Incompatible changes: 4247383c3b1Santirez - Change the "opt.lg_dirty_mult" default from 5 to 3 (32:1 to 8:1). 4257383c3b1Santirez 4267383c3b1Santirez Bug fixes: 4277383c3b1Santirez - Fix dss/mmap allocation precedence code to use recyclable mmap memory only 4287383c3b1Santirez after primary dss allocation fails. 4297383c3b1Santirez - Fix deadlock in the "arenas.purge" mallctl. This regression was introduced 4307383c3b1Santirez in 3.1.0 by the addition of the "arena.<i>.purge" mallctl. 4317383c3b1Santirez 4327383c3b1Santirez* 3.1.0 (October 16, 2012) 4337383c3b1Santirez 4347383c3b1Santirez New features: 4357383c3b1Santirez - Auto-detect whether running inside Valgrind, thus removing the need to 4367383c3b1Santirez manually specify MALLOC_CONF=valgrind:true. 4377383c3b1Santirez - Add the "arenas.extend" mallctl, which allows applications to create 4387383c3b1Santirez manually managed arenas. 4397383c3b1Santirez - Add the ALLOCM_ARENA() flag for {,r,d}allocm(). 4407383c3b1Santirez - Add the "opt.dss", "arena.<i>.dss", and "stats.arenas.<i>.dss" mallctls, 4417383c3b1Santirez which provide control over dss/mmap precedence. 4427383c3b1Santirez - Add the "arena.<i>.purge" mallctl, which obsoletes "arenas.purge". 4437383c3b1Santirez - Define LG_QUANTUM for hppa. 4447383c3b1Santirez 4457383c3b1Santirez Incompatible changes: 4467383c3b1Santirez - Disable tcache by default if running inside Valgrind, in order to avoid 4477383c3b1Santirez making unallocated objects appear reachable to Valgrind. 4487383c3b1Santirez - Drop const from malloc_usable_size() argument on Linux. 4497383c3b1Santirez 4507383c3b1Santirez Bug fixes: 4517383c3b1Santirez - Fix heap profiling crash if sampled object is freed via realloc(p, 0). 4527383c3b1Santirez - Remove const from __*_hook variable declarations, so that glibc can modify 4537383c3b1Santirez them during process forking. 4547383c3b1Santirez - Fix mlockall(2)/madvise(2) interaction. 4557383c3b1Santirez - Fix fork(2)-related deadlocks. 4567383c3b1Santirez - Fix error return value for "thread.tcache.enabled" mallctl. 4577383c3b1Santirez 458ad4c0b41Santirez* 3.0.0 (May 11, 2012) 459ad4c0b41Santirez 460ad4c0b41Santirez Although this version adds some major new features, the primary focus is on 461ad4c0b41Santirez internal code cleanup that facilitates maintainability and portability, most 462ad4c0b41Santirez of which is not reflected in the ChangeLog. This is the first release to 463ad4c0b41Santirez incorporate substantial contributions from numerous other developers, and the 464ad4c0b41Santirez result is a more broadly useful allocator (see the git revision history for 465ad4c0b41Santirez contribution details). Note that the license has been unified, thanks to 466ad4c0b41Santirez Facebook granting a license under the same terms as the other copyright 467ad4c0b41Santirez holders (see COPYING). 468ad4c0b41Santirez 469ad4c0b41Santirez New features: 470ad4c0b41Santirez - Implement Valgrind support, redzones, and quarantine. 471ad4c0b41Santirez - Add support for additional platforms: 472ad4c0b41Santirez + FreeBSD 473ad4c0b41Santirez + Mac OS X Lion 474ad4c0b41Santirez + MinGW 475ad4c0b41Santirez + Windows (no support yet for replacing the system malloc) 476ad4c0b41Santirez - Add support for additional architectures: 477ad4c0b41Santirez + MIPS 478ad4c0b41Santirez + SH4 479ad4c0b41Santirez + Tilera 480ad4c0b41Santirez - Add support for cross compiling. 481ad4c0b41Santirez - Add nallocm(), which rounds a request size up to the nearest size class 482ad4c0b41Santirez without actually allocating. 483ad4c0b41Santirez - Implement aligned_alloc() (blame C11). 484ad4c0b41Santirez - Add the "thread.tcache.enabled" mallctl. 485ad4c0b41Santirez - Add the "opt.prof_final" mallctl. 486ad4c0b41Santirez - Update pprof (from gperftools 2.0). 487ad4c0b41Santirez - Add the --with-mangling option. 488ad4c0b41Santirez - Add the --disable-experimental option. 489ad4c0b41Santirez - Add the --disable-munmap option, and make it the default on Linux. 490ad4c0b41Santirez - Add the --enable-mremap option, which disables use of mremap(2) by default. 491ad4c0b41Santirez 492ad4c0b41Santirez Incompatible changes: 493ad4c0b41Santirez - Enable stats by default. 494ad4c0b41Santirez - Enable fill by default. 495ad4c0b41Santirez - Disable lazy locking by default. 496ad4c0b41Santirez - Rename the "tcache.flush" mallctl to "thread.tcache.flush". 497ad4c0b41Santirez - Rename the "arenas.pagesize" mallctl to "arenas.page". 498ad4c0b41Santirez - Change the "opt.lg_prof_sample" default from 0 to 19 (1 B to 512 KiB). 499ad4c0b41Santirez - Change the "opt.prof_accum" default from true to false. 500ad4c0b41Santirez 501ad4c0b41Santirez Removed features: 502ad4c0b41Santirez - Remove the swap feature, including the "config.swap", "swap.avail", 503ad4c0b41Santirez "swap.prezeroed", "swap.nfds", and "swap.fds" mallctls. 504ad4c0b41Santirez - Remove highruns statistics, including the 505ad4c0b41Santirez "stats.arenas.<i>.bins.<j>.highruns" and 506ad4c0b41Santirez "stats.arenas.<i>.lruns.<j>.highruns" mallctls. 507ad4c0b41Santirez - As part of small size class refactoring, remove the "opt.lg_[qc]space_max", 508ad4c0b41Santirez "arenas.cacheline", "arenas.subpage", "arenas.[tqcs]space_{min,max}", and 509ad4c0b41Santirez "arenas.[tqcs]bins" mallctls. 510ad4c0b41Santirez - Remove the "arenas.chunksize" mallctl. 511ad4c0b41Santirez - Remove the "opt.lg_prof_tcmax" option. 512ad4c0b41Santirez - Remove the "opt.lg_prof_bt_max" option. 513ad4c0b41Santirez - Remove the "opt.lg_tcache_gc_sweep" option. 514ad4c0b41Santirez - Remove the --disable-tiny option, including the "config.tiny" mallctl. 515ad4c0b41Santirez - Remove the --enable-dynamic-page-shift configure option. 516ad4c0b41Santirez - Remove the --enable-sysv configure option. 517ad4c0b41Santirez 518ad4c0b41Santirez Bug fixes: 519ad4c0b41Santirez - Fix a statistics-related bug in the "thread.arena" mallctl that could cause 520ad4c0b41Santirez invalid statistics and crashes. 521ad4c0b41Santirez - Work around TLS deallocation via free() on Linux. This bug could cause 522ad4c0b41Santirez write-after-free memory corruption. 523ad4c0b41Santirez - Fix a potential deadlock that could occur during interval- and 524ad4c0b41Santirez growth-triggered heap profile dumps. 525ad4c0b41Santirez - Fix large calloc() zeroing bugs due to dropping chunk map unzeroed flags. 526ad4c0b41Santirez - Fix chunk_alloc_dss() to stop claiming memory is zeroed. This bug could 527ad4c0b41Santirez cause memory corruption and crashes with --enable-dss specified. 528ad4c0b41Santirez - Fix fork-related bugs that could cause deadlock in children between fork 529ad4c0b41Santirez and exec. 530ad4c0b41Santirez - Fix malloc_stats_print() to honor 'b' and 'l' in the opts parameter. 531ad4c0b41Santirez - Fix realloc(p, 0) to act like free(p). 532ad4c0b41Santirez - Do not enforce minimum alignment in memalign(). 533ad4c0b41Santirez - Check for NULL pointer in malloc_usable_size(). 534ad4c0b41Santirez - Fix an off-by-one heap profile statistics bug that could be observed in 535ad4c0b41Santirez interval- and growth-triggered heap profiles. 536ad4c0b41Santirez - Fix the "epoch" mallctl to update cached stats even if the passed in epoch 537ad4c0b41Santirez is 0. 538ad4c0b41Santirez - Fix bin->runcur management to fix a layout policy bug. This bug did not 539ad4c0b41Santirez affect correctness. 540ad4c0b41Santirez - Fix a bug in choose_arena_hard() that potentially caused more arenas to be 541ad4c0b41Santirez initialized than necessary. 542ad4c0b41Santirez - Add missing "opt.lg_tcache_max" mallctl implementation. 543ad4c0b41Santirez - Use glibc allocator hooks to make mixed allocator usage less likely. 544ad4c0b41Santirez - Fix build issues for --disable-tcache. 545ad4c0b41Santirez - Don't mangle pthread_create() when --with-private-namespace is specified. 546ad4c0b41Santirez 5471d03c1c9Sjbergstroem* 2.2.5 (November 14, 2011) 5481d03c1c9Sjbergstroem 5491d03c1c9Sjbergstroem Bug fixes: 5501d03c1c9Sjbergstroem - Fix huge_ralloc() race when using mremap(2). This is a serious bug that 5511d03c1c9Sjbergstroem could cause memory corruption and/or crashes. 5521d03c1c9Sjbergstroem - Fix huge_ralloc() to maintain chunk statistics. 5531d03c1c9Sjbergstroem - Fix malloc_stats_print(..., "a") output. 5541d03c1c9Sjbergstroem 5551d03c1c9Sjbergstroem* 2.2.4 (November 5, 2011) 5561d03c1c9Sjbergstroem 5571d03c1c9Sjbergstroem Bug fixes: 5581d03c1c9Sjbergstroem - Initialize arenas_tsd before using it. This bug existed for 2.2.[0-3], as 5591d03c1c9Sjbergstroem well as for --disable-tls builds in earlier releases. 5601d03c1c9Sjbergstroem - Do not assume a 4 KiB page size in test/rallocm.c. 5611d03c1c9Sjbergstroem 5621d03c1c9Sjbergstroem* 2.2.3 (August 31, 2011) 5631d03c1c9Sjbergstroem 5641d03c1c9Sjbergstroem This version fixes numerous bugs related to heap profiling. 5651d03c1c9Sjbergstroem 5661d03c1c9Sjbergstroem Bug fixes: 5671d03c1c9Sjbergstroem - Fix a prof-related race condition. This bug could cause memory corruption, 5681d03c1c9Sjbergstroem but only occurred in non-default configurations (prof_accum:false). 5691d03c1c9Sjbergstroem - Fix off-by-one backtracing issues (make sure that prof_alloc_prep() is 5701d03c1c9Sjbergstroem excluded from backtraces). 5711d03c1c9Sjbergstroem - Fix a prof-related bug in realloc() (only triggered by OOM errors). 5721d03c1c9Sjbergstroem - Fix prof-related bugs in allocm() and rallocm(). 5731d03c1c9Sjbergstroem - Fix prof_tdata_cleanup() for --disable-tls builds. 5741d03c1c9Sjbergstroem - Fix a relative include path, to fix objdir builds. 5751d03c1c9Sjbergstroem 5761d03c1c9Sjbergstroem* 2.2.2 (July 30, 2011) 5771d03c1c9Sjbergstroem 5781d03c1c9Sjbergstroem Bug fixes: 5791d03c1c9Sjbergstroem - Fix a build error for --disable-tcache. 5801d03c1c9Sjbergstroem - Fix assertions in arena_purge() (for real this time). 5811d03c1c9Sjbergstroem - Add the --with-private-namespace option. This is a workaround for symbol 5821d03c1c9Sjbergstroem conflicts that can inadvertently arise when using static libraries. 5831d03c1c9Sjbergstroem 584a78e148bSantirez* 2.2.1 (March 30, 2011) 585a78e148bSantirez 586a78e148bSantirez Bug fixes: 587a78e148bSantirez - Implement atomic operations for x86/x64. This fixes compilation failures 588a78e148bSantirez for versions of gcc that are still in wide use. 589a78e148bSantirez - Fix an assertion in arena_purge(). 590a78e148bSantirez 591a78e148bSantirez* 2.2.0 (March 22, 2011) 592a78e148bSantirez 593a78e148bSantirez This version incorporates several improvements to algorithms and data 594a78e148bSantirez structures that tend to reduce fragmentation and increase speed. 595a78e148bSantirez 596a78e148bSantirez New features: 597a78e148bSantirez - Add the "stats.cactive" mallctl. 598a78e148bSantirez - Update pprof (from google-perftools 1.7). 599a78e148bSantirez - Improve backtracing-related configuration logic, and add the 600a78e148bSantirez --disable-prof-libgcc option. 601a78e148bSantirez 602a78e148bSantirez Bug fixes: 603a78e148bSantirez - Change default symbol visibility from "internal", to "hidden", which 604a78e148bSantirez decreases the overhead of library-internal function calls. 605a78e148bSantirez - Fix symbol visibility so that it is also set on OS X. 606a78e148bSantirez - Fix a build dependency regression caused by the introduction of the .pic.o 607a78e148bSantirez suffix for PIC object files. 608a78e148bSantirez - Add missing checks for mutex initialization failures. 609a78e148bSantirez - Don't use libgcc-based backtracing except on x64, where it is known to work. 610a78e148bSantirez - Fix deadlocks on OS X that were due to memory allocation in 611a78e148bSantirez pthread_mutex_lock(). 612a78e148bSantirez - Heap profiling-specific fixes: 613a78e148bSantirez + Fix memory corruption due to integer overflow in small region index 614a78e148bSantirez computation, when using a small enough sample interval that profiling 615a78e148bSantirez context pointers are stored in small run headers. 616a78e148bSantirez + Fix a bootstrap ordering bug that only occurred with TLS disabled. 617a78e148bSantirez + Fix a rallocm() rsize bug. 618a78e148bSantirez + Fix error detection bugs for aligned memory allocation. 619a78e148bSantirez 620a78e148bSantirez* 2.1.3 (March 14, 2011) 621a78e148bSantirez 622a78e148bSantirez Bug fixes: 623a78e148bSantirez - Fix a cpp logic regression (due to the "thread.{de,}allocatedp" mallctl fix 624a78e148bSantirez for OS X in 2.1.2). 625a78e148bSantirez - Fix a "thread.arena" mallctl bug. 626a78e148bSantirez - Fix a thread cache stats merging bug. 627a78e148bSantirez 628a78e148bSantirez* 2.1.2 (March 2, 2011) 629a78e148bSantirez 630a78e148bSantirez Bug fixes: 631a78e148bSantirez - Fix "thread.{de,}allocatedp" mallctl for OS X. 632a78e148bSantirez - Add missing jemalloc.a to build system. 633a78e148bSantirez 634a78e148bSantirez* 2.1.1 (January 31, 2011) 635a78e148bSantirez 636a78e148bSantirez Bug fixes: 637a78e148bSantirez - Fix aligned huge reallocation (affected allocm()). 638a78e148bSantirez - Fix the ALLOCM_LG_ALIGN macro definition. 639a78e148bSantirez - Fix a heap dumping deadlock. 640a78e148bSantirez - Fix a "thread.arena" mallctl bug. 641a78e148bSantirez 642a78e148bSantirez* 2.1.0 (December 3, 2010) 643a78e148bSantirez 644a78e148bSantirez This version incorporates some optimizations that can't quite be considered 645a78e148bSantirez bug fixes. 646a78e148bSantirez 647a78e148bSantirez New features: 648a78e148bSantirez - Use Linux's mremap(2) for huge object reallocation when possible. 649a78e148bSantirez - Avoid locking in mallctl*() when possible. 650a78e148bSantirez - Add the "thread.[de]allocatedp" mallctl's. 651a78e148bSantirez - Convert the manual page source from roff to DocBook, and generate both roff 652a78e148bSantirez and HTML manuals. 653a78e148bSantirez 654a78e148bSantirez Bug fixes: 655a78e148bSantirez - Fix a crash due to incorrect bootstrap ordering. This only impacted 656a78e148bSantirez --enable-debug --enable-dss configurations. 657a78e148bSantirez - Fix a minor statistics bug for mallctl("swap.avail", ...). 658a78e148bSantirez 659a78e148bSantirez* 2.0.1 (October 29, 2010) 660a78e148bSantirez 661a78e148bSantirez Bug fixes: 662a78e148bSantirez - Fix a race condition in heap profiling that could cause undefined behavior 663a78e148bSantirez if "opt.prof_accum" were disabled. 664a78e148bSantirez - Add missing mutex unlocks for some OOM error paths in the heap profiling 665a78e148bSantirez code. 666a78e148bSantirez - Fix a compilation error for non-C99 builds. 667a78e148bSantirez 668a78e148bSantirez* 2.0.0 (October 24, 2010) 669a78e148bSantirez 670a78e148bSantirez This version focuses on the experimental *allocm() API, and on improved 671a78e148bSantirez run-time configuration/introspection. Nonetheless, numerous performance 672a78e148bSantirez improvements are also included. 673a78e148bSantirez 674a78e148bSantirez New features: 675a78e148bSantirez - Implement the experimental {,r,s,d}allocm() API, which provides a superset 676a78e148bSantirez of the functionality available via malloc(), calloc(), posix_memalign(), 677a78e148bSantirez realloc(), malloc_usable_size(), and free(). These functions can be used to 678a78e148bSantirez allocate/reallocate aligned zeroed memory, ask for optional extra memory 679a78e148bSantirez during reallocation, prevent object movement during reallocation, etc. 680a78e148bSantirez - Replace JEMALLOC_OPTIONS/JEMALLOC_PROF_PREFIX with MALLOC_CONF, which is 681a78e148bSantirez more human-readable, and more flexible. For example: 682a78e148bSantirez JEMALLOC_OPTIONS=AJP 683a78e148bSantirez is now: 684a78e148bSantirez MALLOC_CONF=abort:true,fill:true,stats_print:true 685a78e148bSantirez - Port to Apple OS X. Sponsored by Mozilla. 686a78e148bSantirez - Make it possible for the application to control thread-->arena mappings via 687a78e148bSantirez the "thread.arena" mallctl. 688a78e148bSantirez - Add compile-time support for all TLS-related functionality via pthreads TSD. 689a78e148bSantirez This is mainly of interest for OS X, which does not support TLS, but has a 690a78e148bSantirez TSD implementation with similar performance. 691a78e148bSantirez - Override memalign() and valloc() if they are provided by the system. 692a78e148bSantirez - Add the "arenas.purge" mallctl, which can be used to synchronously purge all 693a78e148bSantirez dirty unused pages. 694a78e148bSantirez - Make cumulative heap profiling data optional, so that it is possible to 695a78e148bSantirez limit the amount of memory consumed by heap profiling data structures. 696a78e148bSantirez - Add per thread allocation counters that can be accessed via the 697a78e148bSantirez "thread.allocated" and "thread.deallocated" mallctls. 698a78e148bSantirez 699a78e148bSantirez Incompatible changes: 700a78e148bSantirez - Remove JEMALLOC_OPTIONS and malloc_options (see MALLOC_CONF above). 701a78e148bSantirez - Increase default backtrace depth from 4 to 128 for heap profiling. 702a78e148bSantirez - Disable interval-based profile dumps by default. 703a78e148bSantirez 704a78e148bSantirez Bug fixes: 705a78e148bSantirez - Remove bad assertions in fork handler functions. These assertions could 706a78e148bSantirez cause aborts for some combinations of configure settings. 707a78e148bSantirez - Fix strerror_r() usage to deal with non-standard semantics in GNU libc. 708a78e148bSantirez - Fix leak context reporting. This bug tended to cause the number of contexts 709a78e148bSantirez to be underreported (though the reported number of objects and bytes were 710a78e148bSantirez correct). 711a78e148bSantirez - Fix a realloc() bug for large in-place growing reallocation. This bug could 712a78e148bSantirez cause memory corruption, but it was hard to trigger. 713a78e148bSantirez - Fix an allocation bug for small allocations that could be triggered if 714a78e148bSantirez multiple threads raced to create a new run of backing pages. 715a78e148bSantirez - Enhance the heap profiler to trigger samples based on usable size, rather 716a78e148bSantirez than request size. 717a78e148bSantirez - Fix a heap profiling bug due to sometimes losing track of requested object 718a78e148bSantirez size for sampled objects. 719a78e148bSantirez 720a78e148bSantirez* 1.0.3 (August 12, 2010) 721a78e148bSantirez 722a78e148bSantirez Bug fixes: 723a78e148bSantirez - Fix the libunwind-based implementation of stack backtracing (used for heap 724a78e148bSantirez profiling). This bug could cause zero-length backtraces to be reported. 725a78e148bSantirez - Add a missing mutex unlock in library initialization code. If multiple 726a78e148bSantirez threads raced to initialize malloc, some of them could end up permanently 727a78e148bSantirez blocked. 728a78e148bSantirez 729a78e148bSantirez* 1.0.2 (May 11, 2010) 730a78e148bSantirez 731a78e148bSantirez Bug fixes: 732a78e148bSantirez - Fix junk filling of large objects, which could cause memory corruption. 733a78e148bSantirez - Add MAP_NORESERVE support for chunk mapping, because otherwise virtual 734a78e148bSantirez memory limits could cause swap file configuration to fail. Contributed by 735a78e148bSantirez Jordan DeLong. 736a78e148bSantirez 737a78e148bSantirez* 1.0.1 (April 14, 2010) 738a78e148bSantirez 739a78e148bSantirez Bug fixes: 740a78e148bSantirez - Fix compilation when --enable-fill is specified. 741a78e148bSantirez - Fix threads-related profiling bugs that affected accuracy and caused memory 742a78e148bSantirez to be leaked during thread exit. 743a78e148bSantirez - Fix dirty page purging race conditions that could cause crashes. 744a78e148bSantirez - Fix crash in tcache flushing code during thread destruction. 745a78e148bSantirez 746a78e148bSantirez* 1.0.0 (April 11, 2010) 747a78e148bSantirez 748a78e148bSantirez This release focuses on speed and run-time introspection. Numerous 749a78e148bSantirez algorithmic improvements make this release substantially faster than its 750a78e148bSantirez predecessors. 751a78e148bSantirez 752a78e148bSantirez New features: 753a78e148bSantirez - Implement autoconf-based configuration system. 754a78e148bSantirez - Add mallctl*(), for the purposes of introspection and run-time 755a78e148bSantirez configuration. 756a78e148bSantirez - Make it possible for the application to manually flush a thread's cache, via 757a78e148bSantirez the "tcache.flush" mallctl. 758a78e148bSantirez - Base maximum dirty page count on proportion of active memory. 759*5268379eSantirez - Compute various additional run-time statistics, including per size class 760a78e148bSantirez statistics for large objects. 761a78e148bSantirez - Expose malloc_stats_print(), which can be called repeatedly by the 762a78e148bSantirez application. 763a78e148bSantirez - Simplify the malloc_message() signature to only take one string argument, 764a78e148bSantirez and incorporate an opaque data pointer argument for use by the application 765a78e148bSantirez in combination with malloc_stats_print(). 766a78e148bSantirez - Add support for allocation backed by one or more swap files, and allow the 767a78e148bSantirez application to disable over-commit if swap files are in use. 768a78e148bSantirez - Implement allocation profiling and leak checking. 769a78e148bSantirez 770a78e148bSantirez Removed features: 771a78e148bSantirez - Remove the dynamic arena rebalancing code, since thread-specific caching 772a78e148bSantirez reduces its utility. 773a78e148bSantirez 774a78e148bSantirez Bug fixes: 775a78e148bSantirez - Modify chunk allocation to work when address space layout randomization 776a78e148bSantirez (ASLR) is in use. 777a78e148bSantirez - Fix thread cleanup bugs related to TLS destruction. 778a78e148bSantirez - Handle 0-size allocation requests in posix_memalign(). 779a78e148bSantirez - Fix a chunk leak. The leaked chunks were never touched, so this impacted 780a78e148bSantirez virtual memory usage, but not physical memory usage. 781a78e148bSantirez 782a78e148bSantirez* linux_2008082[78]a (August 27/28, 2008) 783a78e148bSantirez 784a78e148bSantirez These snapshot releases are the simple result of incorporating Linux-specific 785a78e148bSantirez support into the FreeBSD malloc sources. 786a78e148bSantirez 787a78e148bSantirez-------------------------------------------------------------------------------- 788a78e148bSantirezvim:filetype=text:textwidth=80 789