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