Skip to content
  1. Mar 24, 2012
    • Jason Evans's avatar
      Remove ephemeral mutexes. · 6da5418d
      Jason Evans authored
      Remove ephemeral mutexes from the prof machinery, and remove
      malloc_mutex_destroy().  This simplifies mutex management on systems
      that call malloc()/free() inside pthread_mutex_{create,destroy}().
      
      Add atomic_*_u() for operation on unsigned values.
      
      Fix prof_printf() to call malloc_vsnprintf() rather than
      malloc_snprintf().
      6da5418d
    • Jason Evans's avatar
      Forcibly disable TLS on OS X. · b80581d3
      Jason Evans authored
      Forcibly disable TLS on OS X.  gcc and llvm-gcc on OS X do not support
      TLS, but clang does.  Unfortunately, the implementation calls malloc()
      internally during TLS initialization, which causes an unresolvable
      bootstrapping issue.
      b80581d3
    • Jason Evans's avatar
      Remove -no-cpp-precomp compiler flag for OS X. · 9022bf9b
      Jason Evans authored
      Remove the -no-cpp-precomp compiler flag when compiling on OS X.  clang
      does not support the flag, and gcc works fine without it.
      9022bf9b
    • Jason Evans's avatar
      Restructure atomic_*_z(). · 06304a97
      Jason Evans authored
      Restructure atomic_*_z() so that no casting within macros is necessary.
      This avoids warnings when compiling with clang.
      06304a97
  2. Mar 23, 2012
    • Jason Evans's avatar
      Add JEMALLOC_CC_SILENCE_INIT(). · 9225a199
      Jason Evans authored
      Add JEMALLOC_CC_SILENCE_INIT(), which provides succinct syntax for
      initializing a variable to avoid a spurious compiler warning.
      9225a199
    • Jason Evans's avatar
      Implement tsd. · cd9a1346
      Jason Evans authored
      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.
      cd9a1346
  3. Mar 20, 2012
  4. Mar 19, 2012
  5. Mar 17, 2012
  6. Mar 16, 2012
  7. Mar 14, 2012
    • Jason Evans's avatar
      Fix fork-related bugs. · 4e2e3dd9
      Jason Evans authored
      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.
      4e2e3dd9
  8. Mar 13, 2012
    • Jason Evans's avatar
      Modify malloc_vsnprintf() validation code. · 824d34e5
      Jason Evans authored
      Modify malloc_vsnprintf() validation code to verify that output is
      identical to vsnprintf() output, even if both outputs are truncated due
      to buffer exhaustion.
      824d34e5
    • Jason Evans's avatar
      Implement aligned_alloc(). · 0a0bbf63
      Jason Evans authored
      Implement aligned_alloc(), which was added in the C11 standard.  The
      function is weakly specified to the point that a minimally compliant
      implementation would be painful to use (size must be an integral
      multiple of alignment!), which in practice makes posix_memalign() a
      safer choice.
      0a0bbf63
    • Jason Evans's avatar
      Fix a regression in JE_COMPILABLE(). · 4c2faa8a
      Jason Evans authored
      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.
      4c2faa8a
    • Jason Evans's avatar
      Fix malloc_stats_print() option support. · eb239810
      Jason Evans authored
      Fix malloc_stats_print() to honor 'b' and 'l' in the opts parameter.
      eb239810
  9. Mar 12, 2012
  10. Mar 08, 2012
    • Jason Evans's avatar
      Implement malloc_vsnprintf(). · d81e4bdd
      Jason Evans authored
      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.
      d81e4bdd
  11. Mar 05, 2012
  12. Mar 04, 2012
    • Jason Evans's avatar
      Unify license. · c71b9946
      Jason Evans authored
      Update Facebook's software license (with permission from Facebook) to
      merge with that of the other copyright holders.
      c71b9946
  13. Mar 03, 2012
  14. Mar 02, 2012
    • Jason Evans's avatar
      Reorder macros. · 62320b85
      Jason Evans authored
      62320b85
    • Jason Evans's avatar
      Add --with-mangling. · 0a5489e3
      Jason Evans authored
      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.
      0a5489e3
  15. Feb 29, 2012
    • Jason Evans's avatar
      Simplify zone_good_size(). · 166a745b
      Jason Evans authored
      Simplify zone_good_size() to avoid memory allocation.
      
      Submitted by Mike Hommey.
      166a745b
    • Jason Evans's avatar
      Add nallocm(). · 7e15dab9
      Jason Evans authored
      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.
      7e15dab9
    • Jason Evans's avatar
      Use glibc allocator hooks. · 4bb09830
      Jason Evans authored
      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.
      4bb09830