summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* Add pthread_atfork(3) feature test.Jason Evans2016-11-173-2/+14
| | | | | | Some versions of Android provide a pthreads library without providing pthread_atfork(), so in practice a separate feature test is necessary for the latter.
* Update a comment.Jason Evans2016-11-171-1/+1
|
* Refactor madvise(2) configuration.Jason Evans2016-11-173-30/+39
| | | | | | | | | Add feature tests for the MADV_FREE and MADV_DONTNEED flags to madvise(2), so that MADV_FREE is detected and used for Linux kernel versions 4.5 and newer. Refactor pages_purge() so that on systems which support both flags, MADV_FREE is preferred over MADV_DONTNEED. This resolves #387.
* Remove a residual comment.Jason Evans2016-11-171-1/+0
|
* Avoid gcc type-limits warnings.Jason Evans2016-11-171-12/+30
|
* Remove size_t -> unsigned -> size_t conversion.Maks Naumov2016-11-161-2/+1
|
* Document how to use --cache configure option.Jason Evans2016-11-161-0/+15
| | | | This resolves #494.
* Revert "Add JE_RUNNABLE() and use it for os_unfair_lock_*() test."Jason Evans2016-11-161-16/+1
| | | | | | This reverts commit a2e601a2236315fb6f994ff364ea442ed0aed07b. JE_RUNNABLE() causes general cross-compilation issues.
* Uniformly cast mallctl[bymib]() oldp/newp arguments to (void *).Jason Evans2016-11-153-10/+11
| | | | | This avoids warnings in some cases, and is otherwise generally good hygiene.
* Add packing test, which verifies stable layout policy.Jason Evans2016-11-152-0/+168
|
* Add extent serial numbers.Jason Evans2016-11-157-35/+126
| | | | | | | | Add extent serial numbers and use them where appropriate as a sort key that is higher priority than address, so that the allocation policy prefers older extents. This resolves #147.
* Fix arena_reset() crashing bug.Jason Evans2016-11-151-41/+42
| | | | | This regression was caused by 498856f44a30b31fe713a18eb2fc7c6ecf3a9f63 (Move slabs out of chunks.).
* Add JE_RUNNABLE() and use it for os_unfair_lock_*() test.Jason Evans2016-11-121-1/+16
| | | | This resolves #494.
* Reduce memory usage for sdallocx() test_alignment_and_size.Jason Evans2016-11-121-2/+2
|
* Add configure support for *-*-linux-android.Jason Evans2016-11-101-0/+12
| | | | | | | This is tailored to Android, i.e. more specific than the *-*-linux* configuration. This resolves #471.
* Update config.{guess,sub} from upstream.Jason Evans2016-11-102-90/+160
|
* Update ChangeLog for 4.3.1.Jason Evans2016-11-081-0/+8
|
* Fix test_prng_lg_range_zu() to work on 32-bit systems.Jason Evans2016-11-071-10/+10
|
* Rename atomic_*_{uint32,uint64,u}() to atomic_*_{u32,u64,zu}().Jason Evans2016-11-078-139/+139
| | | | This change conforms to naming conventions throughout the codebase.
* Revert "Define 64-bits atomics unconditionally"Jason Evans2016-11-071-8/+10
| | | | | | This reverts commit c2942e2c0e097e7c75a3addd0b9c87758f91692e. This resolves #495.
* Refactor prng to not use 64-bit atomics on 32-bit platforms.Jason Evans2016-11-078-52/+334
| | | | This resolves #495.
* Update ChangeLog for 4.3.0.Jason Evans2016-11-041-0/+2
|
* Fixes to Visual Studio Project filesMatthew Parkinson2016-11-042-6/+14
|
* Use -std=gnu11 if available.Jason Evans2016-11-041-2/+8
| | | | This supersedes -std=gnu99, and enables C11 atomics.
* Update ChangeLog for 4.3.0.Jason Evans2016-11-041-3/+9
|
* Fix/simplify extent_recycle() allocation size computations.Jason Evans2016-11-041-6/+5
| | | | | | | | | | | Do not call s2u() during alloc_size computation, since any necessary ceiling increase is taken care of later by extent_first_best_fit() --> extent_size_quantize_ceil(), and the s2u() call may erroneously cause a higher quantization result. Remove an overly strict overflow check that was added in 4a7852137d8b6598fdb90ea8e1fd3bc8a8b94a3a (Fix extent_recycle()'s cache-oblivious padding support.).
* Fix extent_recycle()'s cache-oblivious padding support.Jason Evans2016-11-041-5/+6
| | | | | | | Add padding *after* computing the size class, so that the optimal size class isn't skipped during search for a usable extent. This regression was caused by b46261d58b449cc4c099ed2384451a2499688f0e (Implement cache-oblivious support for huge size classes.).
* Fix psz/pind edge cases.Jason Evans2016-11-047-53/+39
| | | | | | | | | Add an "over-size" extent heap in which to store extents which exceed the maximum size class (plus cache-oblivious padding, if enabled). Remove psz2ind_clamp() and use psz2ind() instead so that trying to allocate the maximum size class can in principle succeed. In practice, this allows assertions to hold so that OOM errors can be successfully generated.
* Fix extent_alloc_cache[_locked]() to support decommitted allocation.Jason Evans2016-11-044-20/+19
| | | | | | | | | Fix extent_alloc_cache[_locked]() to support decommitted allocation, and use this ability in arena_stash_dirty(), so that decommitted extents are not needlessly committed during purging. In practice this does not happen on any currently supported systems, because both extent merging and decommit must be implemented; all supported systems implement one xor the other.
* Update symbol mangling.Jason Evans2016-11-031-0/+2
|
* Update ChangeLog for 4.3.0.Jason Evans2016-11-031-0/+37
|
* Support Debian GNU/kFreeBSD.Samuel Moritz2016-11-031-1/+1
| | | | Treat it exactly like Linux since they both use GNU libc.
* Fix long spinning in rtree_node_initDave Watson2016-11-034-19/+15
| | | | | | | | | | | | | | | | | rtree_node_init spinlocks the node, allocates, and then sets the node. This is under heavy contention at the top of the tree if many threads start to allocate at the same time. Instead, take a per-rtree sleeping mutex to reduce spinning. Tested both pthreads and osx OSSpinLock, and both reduce spinning adequately Previous benchmark time: ./ttest1 500 100 ~15s New benchmark time: ./ttest1 500 100 .57s
* Check for existance of CPU_COUNT macro before using it.Dave Watson2016-11-031-1/+7
| | | | This resolves #485.
* Fix sycall(2) configure test for Linux.Jason Evans2016-11-031-2/+1
|
* Do not use syscall(2) on OS X 10.12 (deprecated).Jason Evans2016-11-034-4/+24
|
* Add os_unfair_lock support.Jason Evans2016-11-037-0/+42
| | | | | OS X 10.12 deprecated OSSpinLock; os_unfair_lock is the recommended replacement.
* Fix/refactor zone allocator integration code.Jason Evans2016-11-032-85/+108
| | | | | | | | | Fix zone_force_unlock() to reinitialize, rather than unlocking mutexes, since OS X 10.12 cannot tolerate a child unlocking mutexes that were locked by its parent. Refactor; this was a side effect of experimenting with zone {de,re}registration during fork(2).
* Call _exit(2) rather than exit(3) in forked child.Jason Evans2016-11-031-1/+1
| | | | _exit(2) is async-signal-safe, whereas exit(3) is not.
* Force no lazy-lock on Windows.Jason Evans2016-11-021-5/+11
| | | | | | | Monitoring thread creation is unimplemented for Windows, which means lazy-lock cannot function correctly. This resolves #310.
* malloc_stats_print() fixes/cleanups.Jason Evans2016-11-011-18/+3
| | | | | | Fix and clean up various malloc_stats_print() issues caused by 0ba5b9b6189e16a983d8922d8c5cb6ab421906e8 (Add "J" (JSON) support to malloc_stats_print().).
* Use <quote>...</quote> rather than &ldquo;...&rdquo; or "..." in XML.Jason Evans2016-11-012-31/+33
|
* Add "J" (JSON) support to malloc_stats_print().Jason Evans2016-11-012-335/+738
| | | | This resolves #474.
* Fix extent_rtree acquire() to release element on error.Jason Evans2016-10-311-1/+3
| | | | This resolves #480.
* Add an assertion in witness_owner().Jason Evans2016-10-311-0/+3
|
* Refactor witness_unlock() to fix undefined test behavior.Jason Evans2016-10-312-11/+29
| | | | This resolves #396.
* Use CLOCK_MONOTONIC_COARSE rather than COARSE_MONOTONIC_RAW.Jason Evans2016-10-303-10/+10
| | | | | | | | The raw clock variant is slow (even relative to plain CLOCK_MONOTONIC), whereas the coarse clock variant is faster than CLOCK_MONOTONIC, but still has resolution (~1ms) that is adequate for our purposes. This resolves #479.
* Use syscall(2) rather than {open,read,close}(2) during boot.Jason Evans2016-10-301-0/+19
| | | | | | | | | Some applications wrap various system calls, and if they call the allocator in their wrappers, unexpected reentry can result. This is not a general solution (many other syscalls are spread throughout the code), but this resolves a bootstrapping issue that is apparently common. This resolves #443.
* Fix EXTRA_CFLAGS to not affect configuration.Jason Evans2016-10-302-5/+4
|
* Do not mark malloc_conf as weak on Windows.Jason Evans2016-10-291-1/+1
| | | | | | | This works around malloc_conf not being properly initialized by at least the cygwin toolchain. Prior build system changes to use -Wl,--[no-]whole-archive may be necessary for malloc_conf resolution to work properly as a non-weak symbol (not tested).