| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
| |
- Combine multiple runtime branches into a single malloc_slow check.
- Avoid calling arena_choose / size2index / index2size on fast path.
- A few micro optimizations.
|
| |
|
|
|
|
|
|
|
| |
ex_destroy iterates over the tree using post-order traversal so nodes
can be removed and processed by the callback function without paying the
cost to rebalance the tree. The destruction process cannot be stopped
once started.
|
|
|
|
|
|
| |
Signed-off-by: Steve Dougherty <sdougherty@barracuda.com>
This resolves #281.
|
|
|
|
|
|
| |
Signed-off-by: Joshua Kahn <jkahn@barracuda.com>
This resolves #280.
|
|
|
|
| |
This resolves #284.
|
|
|
|
|
|
|
|
|
|
| |
clang-cl, an MSVC-compatible frontend built on top of clang, defined
_MSC_VER *and* supports __attribute__ syntax. The ordering of the
checks in jemalloc_macros.h.in, however, do the wrong thing for
clang-cl, as we want the Windows-specific macro definitions for
clang-cl. To support this use case, we reorder the checks so that
_MSC_VER is checked first (which includes clang-cl), and then
JEMALLOC_HAVE_ATTR) is checked. No functionality change intended.
|
| |
|
|\ |
|
| | |
|
| | |
|
| |
| |
| |
| |
| |
| |
| |
| | |
Modify xallocx() tests that expect to expand in place to use a separate
arena. This avoids the potential for interposed internal allocations
from e.g. heap profile sampling to disrupt the tests.
This resolves #286.
|
|/
|
|
|
|
|
|
| |
Fix xallocx(..., MALLOCX_ZERO to zero the last full trailing page of
large allocations that have been randomly assigned an offset of 0 when
--enable-cache-oblivious configure option is enabled. This addresses a
special case missed in d260f442ce693de4351229027b37b3293fcbfd7d (Fix
xallocx(..., MALLOCX_ZERO) bugs.).
|
|\ |
|
| | |
|
| |
| |
| |
| |
| | |
In addition to depending on map coalescing, the test depended on
munmap() being disabled so that chunk recycling would always succeed.
|
| |
| |
| |
| |
| |
| |
| | |
Work around a potentially bad thread-specific data initialization
interaction with NPTL (glibc's pthreads implementation).
This resolves #283.
|
| |
| |
| |
| |
| |
| | |
Make mallocx() OOM testing work correctly even on systems that can
allocate the majority of virtual address space in a single contiguous
region.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Zero all trailing bytes of large allocations when
--enable-cache-oblivious configure option is enabled. This regression
was introduced by 8a03cf039cd06f9fa6972711195055d865673966 (Implement
cache index randomization for large allocations.).
Zero trailing bytes of huge allocations when resizing from/to a size
class that is not a multiple of the chunk size.
|
|/
|
|
|
|
|
| |
Fix prof_tctx_dump_iter() to filter out nodes that were created after
heap profile dumping started. Prior to this fix, spurious entries with
arbitrary object/byte counts could appear in heap profiles, which
resulted in jeprof inaccuracies or failures.
|
|\ |
|
| | |
|
| | |
|
| | |
|
| | |
|
| |
| |
| |
| |
| | |
Run integration tests with MALLOC_CONF="prof:true,prof_active:false" in
addition to MALLOC_CONF="prof:true".
|
| |
| |
| |
| |
| | |
Fix prof_alloc_rollback() to read tdata from thread-specific data rather
than dereferencing a potentially invalid tctx.
|
| |
| |
| |
| |
| |
| |
| | |
Simplify imallocx_prof_sample() to always operate on usize rather than
sometimes using size. This avoids redundant usize computations and
more closely fits the style adopted by i[rx]allocx_prof_sample() to fix
sampling bugs.
|
| |
| |
| |
| |
| | |
Fix irallocx_prof_sample() to always allocate large regions, even when
alignment is non-zero.
|
|/
|
|
|
|
| |
Fix ixallocx_prof_sample() to never modify nor create sampled small
allocations. xallocx() is in general incapable of moving small
allocations, so this fix removes buggy code without loss of generality.
|
|\ |
|
| | |
|
| |
| |
| |
| |
| | |
Systems that do not support chunk split/merge cannot shrink/grow huge
allocations in place.
|
| |
| |
| |
| | |
This resolves #257.
|
| | |
|
| | |
|
| |
| |
| |
| | |
This resolves #274.
|
| |
| |
| |
| |
| |
| |
| |
| | |
Don't assume Bourne shell is in /bin/sh when running size_classes.sh .
Consider __sparcv9 a synonym for __sparc64__ when defining LG_QUANTUM.
This resolves #275.
|
| | |
|
| |
| |
| |
| |
| |
| | |
This change was intended as part of
8f57e3f1aeb86021b3d078b825bc8c42b2a9af6f (Remove check_stress from check
target's dependencies.).
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Add arena_prof_tctx_reset() and use it instead of arena_prof_tctx_set()
when resetting the tctx pointer during reallocation, which happens
whenever an originally sampled reallocated object is not sampled during
reallocation.
This regression was introduced by
594c759f37c301d0245dc2accf4d4aaf9d202819 (Optimize
arena_prof_tctx_set().)
|
| |
| |
| |
| |
| |
| | |
Fix prof_realloc() to call prof_free_sampled_object() after calling
prof_malloc_sample_object(). Prior to this fix, if tctx and old_tctx
were the same, the tctx could have been prematurely destroyed.
|
| |
| |
| |
| |
| | |
Fix ixallocx_prof() to pass usize_max and zero to ixallocx_prof_sample()
in the correct order.
|
| | |
|
| | |
|
| |
| |
| |
| |
| |
| |
| | |
Make one call to prof_active_get_unlocked() per allocation event, and
use the result throughout the relevant functions that handle an
allocation event. Also add a missing check in prof_realloc(). These
fixes protect allocation events against concurrent prof_active changes.
|
| | |
|
| | |
|
| |
| |
| |
| |
| | |
Fix ixallocx_prof() to clamp the extra parameter if size+extra would
overflow HUGE_MAXCLASS.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Prior to this change the debug build/test command needed to look like:
make all tests && make check_unit && make check_integration && \
make check_integration_prof
This is now simply:
make check
Rename the check_stress target to stress.
|