diff --git a/include/jemalloc/internal/jemalloc_internal_defs.h.in b/include/jemalloc/internal/jemalloc_internal_defs.h.in index 6d557959..a4fce50d 100644 --- a/include/jemalloc/internal/jemalloc_internal_defs.h.in +++ b/include/jemalloc/internal/jemalloc_internal_defs.h.in @@ -258,6 +258,7 @@ /* * popcount*() functions to use for bitmapping. */ +#undef JEMALLOC_INTERNAL_POPCOUNTLL #undef JEMALLOC_INTERNAL_POPCOUNTL #undef JEMALLOC_INTERNAL_POPCOUNT diff --git a/src/jemalloc.c b/src/jemalloc.c index d958c8ca..ff61b6f0 100644 --- a/src/jemalloc.c +++ b/src/jemalloc.c @@ -2115,7 +2115,7 @@ malloc_init_narenas(tsdn_t *tsdn) { } else { if (ncpus >= MALLOCX_ARENA_LIMIT) { malloc_printf(": narenas w/ percpu" - "arena beyond limit (%d)\n", ncpus); + "arena beyond limit (%u)\n", ncpus); if (opt_abort) { abort(); } @@ -2163,7 +2163,7 @@ malloc_init_narenas(tsdn_t *tsdn) { */ if (narenas_auto >= MALLOCX_ARENA_LIMIT) { narenas_auto = MALLOCX_ARENA_LIMIT - 1; - malloc_printf(": Reducing narenas to limit (%d)\n", + malloc_printf(": Reducing narenas to limit (%u)\n", narenas_auto); } narenas_total_set(narenas_auto); @@ -3269,7 +3269,12 @@ JEMALLOC_EXPORT void *(*__memalign_hook)(size_t alignment, size_t size) = * be implemented also, so none of glibc's malloc.o functions are added to the * link. */ -# define ALIAS(je_fn) __attribute__((alias (#je_fn), used)) +# ifdef __clang__ + /* Clang doesn't support GCC's copy() attribute. */ +# define ALIAS(je_fn) __attribute__((alias (#je_fn), used)) +# else +# define ALIAS(je_fn) __attribute__((alias (#je_fn), copy(je_fn))) +# endif /* To force macro expansion of je_ prefix before stringification. */ # define PREALIAS(je_fn) ALIAS(je_fn) # ifdef JEMALLOC_OVERRIDE___LIBC_CALLOC