2aa7fed9c983d8dcde7c0cacf1b024c966758b88 |
|
29-May-2014 |
Richard Diamond <wichard@vitalitystudios.com> |
Try to use __builtin_ffsl if ffsl is unavailable. Some platforms (like those using Newlib) don't have ffs/ffsl. This commit adds a check to configure.ac for __builtin_ffsl if ffsl isn't found. __builtin_ffsl performs the same function as ffsl, and has the added benefit of being available on any platform utilizing Gcc-compatible compiler. This change does not address the used of ffs in the MALLOCX_ARENA() macro.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
8d8f9aeeaa77514d5732db5bd0111232af21fcfd |
|
29-May-2014 |
Jason Evans <je@fb.com> |
Add size class computation capability. Add size class computation capability, currently used only as validation of the size class lookup tables. Generalize the size class spacing used for bins, for eventual use throughout the full range of allocation sizes.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
f3e6d15d74194c37c72990d5b3d216f90fda5a46 |
|
27-May-2014 |
Mike Hommey <mh@glandium.org> |
Move platform headers and tricks from jemalloc_internal.h.in to a new jemalloc_internal_decls.h header
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
50544e64a7c24f6d58a189026486672731d4d6d9 |
|
21-May-2014 |
Mike Hommey <mh@glandium.org> |
Move __func__ to jemalloc_internal_macros.h test/integration/aligned_alloc.c needs it.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
12141150fdbda57651a53ae2fe0edaea4891d814 |
|
16-May-2014 |
Jason Evans <je@fb.com> |
Refactor huge allocation to be managed by arenas. Refactor huge allocation to be managed by arenas (though the global red-black tree of huge allocations remains for lookup during deallocation). This is the logical conclusion of recent changes that 1) made per arena dss precedence apply to huge allocation, and 2) made it possible to replace the per arena chunk allocation/deallocation functions. Remove the top level huge stats, and replace them with per arena huge stats. Normalize function names and types to *dalloc* (some were *dealloc*). Remove the --enable-mremap option. As jemalloc currently operates, this is a performace regression for some applications, but planned work to logarithmically space huge size classes should provide similar amortized performance. The motivation for this change was that mremap-based huge reallocation forced leaky abstractions that prevented refactoring.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
59113bcc94b9fc7549611afb99ca99cad1a7f196 |
|
06-May-2014 |
aravind <aravind@fb.com> |
Add support for user-specified chunk allocators/deallocators. Add new mallctl endpoints "arena<i>.chunk.alloc" and "arena<i>.chunk.dealloc" to allow userspace to configure jemalloc's chunk allocator and deallocator on a per-arena basis.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
3716407897bd1273da21b0987fd8184f86623626 |
|
22-Apr-2014 |
Lucian Adrian Grijincu <lucian@fb.com> |
prof_backtrace: use unw_backtrace unw_backtrace: - does internal per-thread caching - doesn't acquire an internal lock
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
3541a904d6fb949f3f0aea05418ccce7cbd4b705 |
|
17-Apr-2014 |
Jason Evans <je@fb.com> |
Refactor small_size2bin and small_bin2size. Refactor small_size2bin and small_bin2size to be inline functions rather than directly accessed arrays.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
3e3caf03af6ca579e473ace4daf25f63102aca4f |
|
17-Apr-2014 |
Jason Evans <jasone@canonware.com> |
Merge pull request #73 from bmaurer/smallmalloc Smaller malloc hot path
|
021136ce4db79f50031a1fd5dd751891888fbc7b |
|
16-Apr-2014 |
Ben Maurer <bmaurer@fb.com> |
Create a const array with only a small bin to size map
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
bd87b01999416ec7418ff8bdb504d9b6c009ff68 |
|
16-Apr-2014 |
Jason Evans <je@fb.com> |
Optimize Valgrind integration. Forcefully disable tcache if running inside Valgrind, and remove Valgrind calls in tcache-specific code. Restructure Valgrind-related code to move most Valgrind calls out of the fast path functions. Take advantage of static knowledge to elide some branches in JEMALLOC_VALGRIND_REALLOC().
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
ecd3e59ca351d7111ec72a327fe0c009f2aa69a0 |
|
15-Apr-2014 |
Jason Evans <je@fb.com> |
Remove the "opt.valgrind" mallctl. Remove the "opt.valgrind" mallctl because it is unnecessary -- jemalloc automatically detects whether it is running inside valgrind.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
4d434adb146375ad17f0d5e994ed5728d2942e3f |
|
15-Apr-2014 |
Jason Evans <je@fb.com> |
Make dss non-optional, and fix an "arena.<i>.dss" mallctl bug. Make dss non-optional on all platforms which support sbrk(2). Fix the "arena.<i>.dss" mallctl to return an error if "primary" or "secondary" precedence is specified, but sbrk(2) is not supported.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
9790b9667fd975b1f9a4f108f9d0a20ab265c6b6 |
|
15-Apr-2014 |
Jason Evans <jasone@canonware.com> |
Remove the *allocm() API, which is superceded by the *allocx() API.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
be8e59f5a64ef775c9694aee0d6a87d92336d303 |
|
06-Apr-2014 |
Ben Maurer <bmaurer@fb.com> |
Don't dereference chunk->arena in free() hot path When you call free() we load chunk->arena even though that data isn't used on the tcache hot path. In profiling some FB applications, I found that ~30% of the dTLB misses in the free() function come from this line. With 4 MB chunks, the arena_chunk_t->map is ~ 32 KB (1024 pages in the chunk, 4 8 byte pointers in arena_chunk_map_t). This means there's only a 1/8 chance of the page containing chunk->arena also comtaining the map bits.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
fbb31029a5c2f556f39e04a8781340d4ee4cf16c |
|
27-Mar-2014 |
Max Wang <mwang@fb.com> |
Use arena dss prec instead of default for huge allocs. Pass a dss_prec_t parameter to huge_{m,p,r}alloc instead of defaulting to the chunk dss prec.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
f234dc51b9740242d8ba69307db7c5a1312f5a03 |
|
17-Jan-2014 |
Jason Evans <je@fb.com> |
Fix name mangling for stress tests. Fix stress tests such that testlib code uses the jet_ allocator, but test code uses libjemalloc. Generate jemalloc_{rename,mangle}.h, the former because it's needed for the stress test name mangling fix, and the latter for consistency. As an artifact of this change, some (but not all) definitions related to the experimental API are absent from the headers unless the feature is enabled at configure time.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
b2c31660be917ea6d59cd54e6f650b06b5e812ed |
|
13-Jan-2014 |
Jason Evans <je@fb.com> |
Extract profiling code from [re]allocation functions. Extract profiling code from malloc(), imemalign(), calloc(), realloc(), mallocx(), rallocx(), and xallocx(). This slightly reduces the amount of code compiled into the fast paths, but the primary benefit is the combinatorial complexity reduction. Simplify iralloc[t]() by creating a separate ixalloc() that handles the no-move cases. Further simplify [mrxn]allocx() (and by implication [mrn]allocm()) to make request size overflows due to size class and/or alignment constraints trigger undefined behavior (detected by debug-only assertions). Report ENOMEM rather than EINVAL if an OOM occurs during heap profiling backtrace creation in imemalign(). This bug impacted posix_memalign() and aligned_alloc().
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
b954bc5d3a65966df0ce7801cd6102542b5e894b |
|
03-Jan-2014 |
Jason Evans <je@fb.com> |
Convert rtree from (void *) to (uint8_t) storage. Reduce rtree memory usage by storing booleans (1 byte each) rather than pointers. The rtree code is only used to record whether jemalloc manages a chunk of memory, so there's no need to store pointers in the rtree. Increase rtree node size to 64 KiB in order to reduce tree depth from 13 to 3 on 64-bit systems. The conversion to more compact leaf nodes was enough by itself to make the rtree depth 1 on 32-bit systems; due to the fact that root nodes are smaller than the specified node size if possible, the node size change has no impact on 32-bit systems (assuming default chunk size).
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
d82a5e6a34f20698ab9368bb2b4953b81d175552 |
|
13-Dec-2013 |
Jason Evans <jasone@canonware.com> |
Implement the *allocx() API. Implement the *allocx() API, which is a successor to the *allocm() API. The *allocx() functions are slightly simpler to use because they have fewer parameters, they directly return the results of primary interest, and mallocx()/rallocx() avoid the strict aliasing pitfall that allocm()/rallocx() share with posix_memalign(). The following code violates strict aliasing rules: foo_t *foo; allocm((void **)&foo, NULL, 42, 0); whereas the following is safe: foo_t *foo; void *p; allocm(&p, NULL, 42, 0); foo = (foo_t *)p; mallocx() does not have this problem: foo_t *foo = (foo_t *)mallocx(42, 0);
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
a4f124f59fa5f702231432a7e5fa45140ba81e2a |
|
09-Dec-2013 |
Jason Evans <jasone@canonware.com> |
Normalize #define whitespace. Consistently use a tab rather than a space following #define.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
dc1bed62272045651e4bbf2cd85f6fccaf7b1331 |
|
06-Dec-2013 |
Jason Evans <je@fb.com> |
Fix more test refactoring issues.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
14990b83d1dffe04638df0c09eb1a5c3b1118462 |
|
06-Dec-2013 |
Jason Evans <je@fb.com> |
Fix test refactoring issues for Linux.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
86abd0dcd8e478759fe409d338d11558c4cec427 |
|
01-Dec-2013 |
Jason Evans <jasone@canonware.com> |
Refactor to support more varied testing. Refactor the test harness to support three types of tests: - unit: White box unit tests. These tests have full access to all internal jemalloc library symbols. Though in actuality all symbols are prefixed by jet_, macro-based name mangling abstracts this away from test code. - integration: Black box integration tests. These tests link with the installable shared jemalloc library, and with the exception of some utility code and configure-generated macro definitions, they have no access to jemalloc internals. - stress: Black box stress tests. These tests link with the installable shared jemalloc library, as well as with an internal allocator with symbols prefixed by jet_ (same as for unit tests) that can be used to allocate data structures that are internal to the test code. Move existing tests into test/{unit,integration}/ as appropriate. Split out internal parts of jemalloc_defs.h.in and put them in jemalloc_internal_defs.h.in. This reduces internals exposure to applications that #include <jemalloc/jemalloc.h>. Refactor jemalloc.h header generation so that a single header file results, and the prototypes can be used to generate jet_ prototypes for tests. Split jemalloc.h.in into multiple parts (jemalloc_defs.h.in, jemalloc_macros.h.in, jemalloc_protos.h.in, jemalloc_mangle.h.in) and use a shell script to generate a unified jemalloc.h at configure time. Change the default private namespace prefix from "" to "je_". Add missing private namespace mangling. Remove hard-coded private_namespace.h. Instead generate it and private_unnamespace.h from private_symbols.txt. Use similar logic for public symbols, which aids in name mangling for jet_ symbols. Add test_warn() and test_fail(). Replace existing exit(1) calls with test_fail() calls.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
543abf7e6c7de06fe9654e91190b5c44a11b065e |
|
20-Oct-2013 |
Jason Evans <jasone@canonware.com> |
Fix inlining warning. Add the JEMALLOC_ALWAYS_INLINE_C macro and use it for always-inlined functions declared in .c files. This fixes a function attribute inconsistency for debug builds that resulted in (harmless) compiler warnings about functions not being inlinable. Reported by Ricardo Nabinger Sanchez.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
daf6d0446ce64fb563b7d96fda077e6406c602be |
|
18-Mar-2013 |
Riku Voipio <riku.voipio@linaro.org> |
Add aarch64 LG_QUANTUM size definition Signed-off-by: Riku Voipio <riku.voipio@linaro.org>
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
a4915851577c948cf9051d60152944ca2d1b2d59 |
|
06-Mar-2013 |
Jason Evans <je@fb.com> |
Add no-op bodies to VALGRIND_*() macro stubs. Add no-op bodies to VALGRIND_*() macro stubs so that they can be used in contexts like the following without generating a compiler warning about the 'if' statement having an empty body: if (config_valgrind) VALGRIND_MAKE_MEM_UNDEFINED(ret, size);
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
9f9897ad4275e540cf1bea5a6de762c809b7695c |
|
28-Jan-2013 |
Mike Frysinger <vapier@gentoo.org> |
fix building for s390 systems Checking for __s390x__ means you work on s390x, but not s390 (32bit) systems. So use __s390__ which works for both. With this, `make check` passes on s390. Signed-off-by: Mike Frysinger <vapier@gentoo.org>
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
06912756cccd0064a9c5c59992dbac1cec68ba3f |
|
01-Feb-2013 |
Jason Evans <je@fb.com> |
Fix Valgrind integration. Fix Valgrind integration to annotate all internally allocated memory in a way that keeps Valgrind happy about internal data structure access.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
dd0438ee6b7b3640516d5a48feec1490ca2f1cc3 |
|
23-Jan-2013 |
Jason Evans <je@fb.com> |
Specify 'inline' in addition to always_inline attribute. Specify both inline and __attribute__((always_inline)), in order to avoid warnings when using newer versions of gcc.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
ae03bf6a57f0dd6a009288fa6477a300cabf6d5e |
|
22-Jan-2013 |
Jason Evans <jasone@canonware.com> |
Update hash from MurmurHash2 to MurmurHash3. Update hash from MurmurHash2 to MurmurHash3, primarily because the latter generates 128 bits in a single call for no extra cost, which simplifies integration with cuckoo hashing.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
88393cb0eb9a046000d20809809d4adac11957ab |
|
22-Jan-2013 |
Jason Evans <jasone@canonware.com> |
Add and use JEMALLOC_ALWAYS_INLINE. Add JEMALLOC_ALWAYS_INLINE and use it to guarantee that the entire fast paths of the primary allocation/deallocation functions are inlined.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
13e4e24c42d17492f85cdd550c1e13d6f929307e |
|
03-Dec-2012 |
Garrett Cooper <yanegomi@gmail.com> |
Fix build break on *BSD Linux uses alloca.h; many other operating systems define alloca(3) in stdlib.h. Signed-off-by: Garrett Cooper <yanegomi@gmail.com>
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
609ae595f0358157b19311b0f9f9591db7cee705 |
|
11-Oct-2012 |
Jason Evans <je@fb.com> |
Add arena-specific and selective dss allocation. Add the "arenas.extend" mallctl, so that it is possible to create new arenas that are outside the set that jemalloc automatically multiplexes threads onto. Add the ALLOCM_ARENA() flag for {,r,d}allocm(), so that it is possible to explicitly allocate from a particular arena. Add the "opt.dss" mallctl, which controls the default precedence of dss allocation relative to mmap allocation. Add the "arena.<i>.dss" mallctl, which makes it possible to set the default dss precedence on a per arena or global basis. Add the "arena.<i>.purge" mallctl, which obsoletes "arenas.purge". Add the "stats.arenas.<i>.dss" mallctl.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
dd03a2e37702b21fd692bf05d46ee9f97133ab78 |
|
09-Oct-2012 |
Jason Evans <jasone@canonware.com> |
Define LG_QUANTUM for hppa. Submitted by Jory Pratt.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
781fe75e0a03f13bc1f5403acbbf87796ceea1dc |
|
15-May-2012 |
Jason Evans <je@fb.com> |
Auto-detect whether running inside Valgrind. Auto-detect whether running inside Valgrind, thus removing the need to manually specify MALLOC_CONF=valgrind:true.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
2e671ffbadc02fc7de8cbafdd1031e3b0ad73c5b |
|
10-May-2012 |
Jason Evans <je@fb.com> |
Add the --enable-mremap option. Add the --enable-mremap option, and disable the use of mremap(2) by default, for the same reason that freeing chunks via munmap(2) is disabled by default on Linux: semi-permanent VM map fragmentation.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
8d5865eb578e99369382d90bdd1e557e5b233277 |
|
02-May-2012 |
Jason Evans <je@fb.com> |
Make CACHELINE a raw constant. Make CACHELINE a raw constant in order to work around a __declspec(align()) limitation. Submitted by Mike Hommey.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
203484e2ea267e068a68fd2922263f0ff1d5ac6f |
|
02-May-2012 |
Jason Evans <je@fb.com> |
Optimize malloc() and free() fast paths. Embed the bin index for small page runs into the chunk page map, in order to omit [...] in the following dependent load sequence: ptr-->mapelm-->[run-->bin-->]bin_info Move various non-critcal code out of the inlined function chain into helper functions (tcache_event_hard(), arena_dalloc_small(), and locking).
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
fd97b1dfc76647c3f90f28dc63cc987041fe20df |
|
30-Apr-2012 |
Mike Hommey <mh@glandium.org> |
Add support for MSVC Tested with MSVC 8 32 and 64 bits.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
a14bce85e885f83c96116cc5438ae52d740f3727 |
|
30-Apr-2012 |
Mike Hommey <mh@glandium.org> |
Use Get/SetLastError on Win32 Using errno on win32 doesn't quite work, because the value set in a shared library can't be read from e.g. an executable calling the function setting errno. At the same time, since buferror always uses errno/GetLastError, don't pass it.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
8b49971d0ce0819af78aa2a278c26ecb298ee134 |
|
24-Apr-2012 |
Mike Hommey <mh@glandium.org> |
Avoid variable length arrays and remove declarations within code MSVC doesn't support C99, and building as C++ to be able to use them is dangerous, as C++ and C99 are incompatible. Introduce a VARIABLE_ARRAY macro that either uses VLA when supported, or alloca() otherwise. Note that using alloca() inside loops doesn't quite work like VLAs, thus the use of VARIABLE_ARRAY there is discouraged. It might be worth investigating ways to check whether VARIABLE_ARRAY is used in such context at runtime in debug builds and bail out if that happens.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
a5288ca93434d98f91438de40d99177ffdfd2a17 |
|
20-Apr-2012 |
Mike Hommey <mh@glandium.org> |
Remove unused #includes
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
a19e87fbad020e8dd3d26682032929e8e5ae71c1 |
|
22-Apr-2012 |
Mike Hommey <mh@glandium.org> |
Add support for Mingw
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
f7088e6c992d079bc3162e0c48ed4dc5def6d263 |
|
20-Apr-2012 |
Jason Evans <je@fb.com> |
Make arena_salloc() an inline function.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
b57d3ec571c6551231be62b7bf92c084a8c8291c |
|
17-Apr-2012 |
Jason Evans <jasone@canonware.com> |
Add atomic(9) implementations of atomic operations. Add atomic(9) implementations of atomic operations. These are used on FreeBSD for non-x86 architectures.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
45f208e112fcb82e0c98d572fc34259d65d6b6c1 |
|
16-Apr-2012 |
Mike Hommey <mh@glandium.org> |
Replace fprintf with malloc_printf in tests.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
7ca0fdfb85b2a9fc7a112e158892c098e004385b |
|
13-Apr-2012 |
Jason Evans <je@fb.com> |
Disable munmap() if it causes VM map holes. Add a configure test to determine whether common mmap()/munmap() patterns cause VM map holes, and only use munmap() to discard unused chunks if the problem does not exist. Unify the chunk caching for mmap and dss. Fix options processing to limit lg_chunk to be large enough that redzones will always fit.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
5ff709c264e52651de25b788692c62ff1f6f389c |
|
12-Apr-2012 |
Jason Evans <jasone@canonware.com> |
Normalize aligned allocation algorithms. Normalize arena_palloc(), chunk_alloc_mmap_slow(), and chunk_recycle_dss() to use the same algorithm for trimming over-allocation. Add the ALIGNMENT_ADDR2BASE(), ALIGNMENT_ADDR2OFFSET(), and ALIGNMENT_CEILING() macros, and use them where appropriate. Remove the run_size_p parameter from sa2u(). Fix a potential deadlock in chunk_recycle_dss() that was introduced by eae269036c9f702d9fa9be497a1a2aa1be13a29e (Add alignment support to chunk_alloc()).
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
122449b073bcbaa504c4f592ea2d733503c272d2 |
|
06-Apr-2012 |
Jason Evans <je@fb.com> |
Implement Valgrind support, redzones, and quarantine. Implement Valgrind support, as well as the redzone and quarantine features, which help Valgrind detect memory errors. Redzones are only implemented for small objects because the changes necessary to support redzones around large and huge objects are complicated by in-place reallocation, to the point that it isn't clear that the maintenance burden is worth the incremental improvement to Valgrind support. Merge arena_salloc() and arena_salloc_demote(). Refactor i[v]salloc() to expose the 'demote' option.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
b147611b5253921a873191bb0589d3b18f613946 |
|
05-Apr-2012 |
Jason Evans <jasone@canonware.com> |
Add utrace(2)-based tracing (--enable-utrace).
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
01b3fe55ff3ac8e4aa689f09fcb0729da8037638 |
|
03-Apr-2012 |
Jason Evans <jasone@canonware.com> |
Add a0malloc(), a0calloc(), and a0free(). Add a0malloc(), a0calloc(), and a0free(), which are used by FreeBSD's libc to allocate/deallocate TLS in static binaries.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
ae4c7b4b4092906c641d69b4bf9fcb4a7d50790d |
|
02-Apr-2012 |
Jason Evans <jasone@canonware.com> |
Clean up *PAGE* macros. s/PAGE_SHIFT/LG_PAGE/g and s/PAGE_SIZE/PAGE/g. Remove remnants of the dynamic-page-shift code. Rename the "arenas.pagesize" mallctl to "arenas.page". Remove the "arenas.chunksize" mallctl, which is redundant with "opt.lg_chunk".
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
f0047372673da7f213f733465dab0d8825eb1c9f |
|
03-Apr-2012 |
Jason Evans <jasone@canonware.com> |
Revert "Avoid NULL check in free() and malloc_usable_size()." This reverts commit 96d4120ac08db3f2d566e8e5c3bc134a24aa0afc. ivsalloc() depends on chunks_rtree being initialized. This can be worked around via a NULL pointer check. However, thread_allocated_tsd_get() also depends on initialization having occurred, and there is no way to guard its call in free() that is cheaper than checking whether ptr is NULL.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
96d4120ac08db3f2d566e8e5c3bc134a24aa0afc |
|
02-Apr-2012 |
Jason Evans <jasone@canonware.com> |
Avoid NULL check in free() and malloc_usable_size(). Generalize isalloc() to handle NULL pointers in such a way that the NULL checking overhead is only paid when introspecting huge allocations (or NULL). This allows free() and malloc_usable_size() to no longer check for NULL. Submitted by Igor Bukanov and Mike Hommey.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
80b25932ca52e9506d4e2b8ee0fa58aa5ae3306d |
|
02-Apr-2012 |
Mike Hommey <mh@glandium.org> |
Move last bit of zone initialization in zone.c, and lazy-initialize
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
4eeb52f080edb1f4b518249388f6c617386c00e5 |
|
02-Apr-2012 |
Jason Evans <jasone@canonware.com> |
Remove vsnprintf() and strtoumax() validation. Remove code that validates malloc_vsnprintf() and malloc_strtoumax() against their namesakes. The validation code has adequately served its usefulness at this point, and it isn't worth dealing with the different formatting for %p with glibc versus other implementations for NULL pointers ("(nil)" vs. "0x0"). Reported by Mike Hommey.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
1a0e7770243e0539fa8fef7bb1512f784f93389f |
|
27-Mar-2012 |
Mike Hommey <mh@glandium.org> |
Add a SYS_write definition on systems where it is not defined in headers Namely, in the Android NDK headers, SYS_write is not defined; but __NR_write is.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
41b6afb834b1f5250223678c52bd4f013d4234f6 |
|
03-Feb-2012 |
Jason Evans <jasone@canonware.com> |
Port to FreeBSD. Use FreeBSD-specific functions (_pthread_mutex_init_calloc_cb(), _malloc_{pre,post}fork()) to avoid bootstrapping issues due to allocation in libc and libthr. Add malloc_strtoumax() and use it instead of strtoul(). Disable validation code in malloc_vsnprintf() and malloc_strtoumax() until jemalloc is initialized. This is necessary because locale initialization causes allocation for both vsnprintf() and strtoumax(). Force the lazy-lock feature on in order to avoid pthread_self(), because it causes allocation. Use syscall(SYS_write, ...) rather than write(...), because libthr wraps write() and causes allocation. Without this workaround, it would not be possible to print error messages in malloc_conf_init() without substantially reworking bootstrapping. Fix choose_arena_hard() to look at how many threads are assigned to the candidate choice, rather than checking whether the arena is uninitialized. This bug potentially caused more arenas to be initialized than necessary.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
9225a1991a58190207cca2ff3cdba966bb322dd5 |
|
23-Mar-2012 |
Jason Evans <je@fb.com> |
Add JEMALLOC_CC_SILENCE_INIT(). Add JEMALLOC_CC_SILENCE_INIT(), which provides succinct syntax for initializing a variable to avoid a spurious compiler warning.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
cd9a1346e96f71bdecdc654ea50fc62d76371e74 |
|
22-Mar-2012 |
Jason Evans <je@fb.com> |
Implement tsd. Implement tsd, which is a TLS/TSD abstraction that uses one or both internally. Modify bootstrapping such that no tsd's are utilized until allocation is safe. Remove malloc_[v]tprintf(), and use malloc_snprintf() instead. Fix %p argument size handling in malloc_vsnprintf(). Fix a long-standing statistics-related bug in the "thread.arena" mallctl that could cause crashes due to linked list corruption.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
e24c7af35d1e9d24d02166ac98cfca7cf807ff13 |
|
19-Mar-2012 |
Jason Evans <je@fb.com> |
Invert NO_TLS to JEMALLOC_TLS.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
6508bc6931b54b50aaa0976ee7f0681482b2a80a |
|
16-Mar-2012 |
Jason Evans <je@fb.com> |
Remove #include <sys/sysctl.h>. Remove #include <sys/sysctl.h>, which is no longer needed (now using sysconf(3) to get number of CPUs).
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
4e2e3dd9cf19ed5991938a708a8b50611aa5bbf8 |
|
14-Mar-2012 |
Jason Evans <je@fb.com> |
Fix fork-related bugs. Acquire/release arena bin locks as part of the prefork/postfork. This bug made deadlock in the child between fork and exec a possibility. Split jemalloc_postfork() into jemalloc_postfork_{parent,child}() so that the child can reinitialize mutexes rather than unlocking them. In practice, this bug tended not to cause problems.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
4c2faa8a7c42a47a6bea509f5a23234bc5a66d40 |
|
13-Mar-2012 |
Jason Evans <je@fb.com> |
Fix a regression in JE_COMPILABLE(). Revert JE_COMPILABLE() so that it detects link errors. Cross-compiling should still work as long as a valid configure cache is provided. Clean up some comments/whitespace.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
d81e4bdd5c991bd5642c8b859ef1f752b51cd9be |
|
06-Mar-2012 |
Jason Evans <je@fb.com> |
Implement malloc_vsnprintf(). Implement malloc_vsnprintf() (a subset of vsnprintf(3)) as well as several other printing functions based on it, so that formatted printing can be relied upon without concern for inducing a dependency on floating point runtime support. Replace malloc_write() calls with malloc_*printf() where doing so simplifies the code. Add name mangling for library-private symbols in the data and BSS sections. Adjust CONF_HANDLE_*() macros in malloc_conf_init() to expose all opt_* variable use to cpp so that proper mangling occurs.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
3492daf1ce6fb85040d28dfd4dcb51cbf6b0da51 |
|
05-Mar-2012 |
Jason Evans <je@fb.com> |
Add SH4 and mips architecture support. Submitted by Andreas Vinsander.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
84f7cdb0c588322dfd50a26497fc1cb54b792018 |
|
03-Mar-2012 |
Jason Evans <je@fb.com> |
Rename prn to prng. Rename prn to prng so that Windows doesn't choke when trying to create a file named prn.h.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
0a5489e37da88a1a50fbf8552e0d3a7f8fd93ffc |
|
02-Mar-2012 |
Jason Evans <je@fb.com> |
Add --with-mangling. Add the --with-mangling configure option, which can be used to specify name mangling on a per public symbol basis that takes precedence over --with-jemalloc-prefix. Expose the memalign() and valloc() overrides even if --with-jemalloc-prefix is specified. This change does no real harm, and simplifies the code.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
7e15dab94d3f008b0a6c296ad7afec9ed47ff1ac |
|
29-Feb-2012 |
Jason Evans <je@fb.com> |
Add nallocm(). Add nallocm(), which computes the real allocation size that would result from the corresponding allocm() call. nallocm() is a functional superset of OS X's malloc_good_size(), in that it takes alignment constraints into account.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
4bb09830133ffa8b27a95bc3727558007722c152 |
|
29-Feb-2012 |
Jason Evans <je@fb.com> |
Use glibc allocator hooks. When jemalloc is used as a libc malloc replacement (i.e. not prefixed), some particular setups may end up inconsistently calling malloc from libc and free from jemalloc, or the other way around. glibc provides hooks to make its functions use alternative implementations. Use them. Submitted by Karl Tomlinson and Mike Hommey.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
c90ad71237c05473bcb968beddebb0a487c36e75 |
|
29-Feb-2012 |
Jason Evans <je@fb.com> |
Remove the sysv option.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
b172610317babc7f365584ddd7fdaf4eb8d9d04c |
|
29-Feb-2012 |
Jason Evans <je@fb.com> |
Simplify small size class infrastructure. Program-generate small size class tables for all valid combinations of LG_TINY_MIN, LG_QUANTUM, and PAGE_SHIFT. Use the appropriate table to generate all relevant data structures, and remove the distinction between tiny/quantum/cacheline/subpage bins. Remove --enable-dynamic-page-shift. This option didn't prove useful in practice, and it prevented optimizations. Add Tilera architecture support.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
ef8897b4b938111fcc9b54725067f1dbb33a4c20 |
|
13-Feb-2012 |
Jason Evans <je@fb.com> |
Make 8-byte tiny size class non-optional. When tiny size class support was first added, it was intended to support truly tiny size classes (even 2 bytes). However, this wasn't very useful in practice, so the minimum tiny size class has been limited to sizeof(void *) for a long time now. This is too small to be standards compliant, but other commonly used malloc implementations do not even bother using a 16-byte quantum on systems with vector units (SSE2+, AltiVEC, etc.). As such, it is safe in practice to support an 8-byte tiny size class on 64-bit systems that support 16-byte types.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
4162627757889ea999264c2ddbc3c354768774e2 |
|
13-Feb-2012 |
Jason Evans <je@fb.com> |
Remove the swap feature. Remove the swap feature, which enabled per application swap files. In practice this feature has not proven itself useful to users.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
fd56043c53f1cd1335ae6d1c0ee86cc0fbb9f12e |
|
13-Feb-2012 |
Jason Evans <je@fb.com> |
Remove magic. Remove structure magic, because 1) it is no longer conditional, and 2) it stopped being very effective at detecting memory corruption several years ago.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
7372b15a31c63ac5cb9ed8aeabc2a0a3c005e8bf |
|
11-Feb-2012 |
Jason Evans <je@fb.com> |
Reduce cpp conditional logic complexity. Convert configuration-related cpp conditional logic to use static constant variables, e.g.: #ifdef JEMALLOC_DEBUG [...] #endif becomes: if (config_debug) { [...] } The advantage is clearer, more concise code. The main disadvantage is that data structures no longer have conditionally defined fields, so they pay the cost of all fields regardless of whether they are used. In practice, this is only a minor concern; config_stats will go away in an upcoming change, and config_prof is the only other major feature that depends on more than a few special-purpose fields.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
04ca1efe35349a6114523b37abbd4ca066cd17fa |
|
31-Jul-2011 |
Jason Evans <jasone@canonware.com> |
Adjust relative #include for private_namespace.h.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
746e77a06bf1089d50fbd64e1759b96c1cfbd9f5 |
|
31-Jul-2011 |
Jason Evans <je@fb.com> |
Add the --with-private-namespace option. Add the --with-private-namespace option to make it possible to work around library-private symbols being exposed in static libraries.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|
7427525c28d58c423a68930160e3b0fe577fe953 |
|
01-Apr-2011 |
Jason Evans <jasone@canonware.com> |
Move repo contents in jemalloc/ to top level.
/external/jemalloc/include/jemalloc/internal/jemalloc_internal.h.in
|