Skip to content
  1. Feb 28, 2017
  2. Feb 27, 2017
  3. Feb 26, 2017
  4. Feb 24, 2017
  5. Feb 23, 2017
    • Jason Evans's avatar
      Use MALLOC_CONF rather than malloc_conf for tests. · de49674f
      Jason Evans authored
      malloc_conf does not reliably work with MSVC, which complains of
      "inconsistent dll linkage", i.e. its inability to support the
      application overriding malloc_conf when dynamically linking/loading.
      Work around this limitation by adding test harness support for per test
      shell script sourcing, and converting all tests to use MALLOC_CONF
      instead of malloc_conf.
      de49674f
  6. Feb 22, 2017
  7. Feb 21, 2017
  8. Feb 17, 2017
    • Jason Evans's avatar
      Disable coalescing of cached extents. · 2dfc5b5a
      Jason Evans authored
      Extent splitting and coalescing is a major component of large allocation
      overhead, and disabling coalescing of cached extents provides a simple
      and effective hysteresis mechanism.  Once two-phase purging is
      implemented, it will probably make sense to leave coalescing disabled
      for the first phase, but coalesce during the second phase.
      2dfc5b5a
    • Jason Evans's avatar
      Optimize extent coalescing. · c1ebfaa6
      Jason Evans authored
      Refactor extent_can_coalesce(), extent_coalesce(), and extent_record()
      to avoid needlessly repeating extent [de]activation operations.
      c1ebfaa6
    • Jason Evans's avatar
      Fix arena->stats.mapped accounting. · b0654b95
      Jason Evans authored
      Mapped memory increases when extent_alloc_wrapper() succeeds, and
      decreases when extent_dalloc_wrapper() is called (during purging).
      b0654b95
  9. Feb 16, 2017
  10. Feb 13, 2017
    • Jason Evans's avatar
      Do not generate unused tsd_*_[gs]et() functions. · 0721b895
      Jason Evans authored
      This avoids a gcc diagnostic note:
          note: The ABI for passing parameters with 64-byte alignment has
          changed in GCC 4.6
      This note related to the cacheline alignment of rtree_ctx_t, which was
      introduced by 4a346f55 (Replace rtree
      path cache with LRU cache.).
      0721b895
  11. Feb 10, 2017
  12. Feb 09, 2017
  13. Feb 07, 2017
    • Jason Evans's avatar
      3bd6d8e4
    • Jason Evans's avatar
      Fix extent_record(). · 51779955
      Jason Evans authored
      Read adjacent rtree elements while holding element locks, since the
      extents mutex only protects against relevant like-state extent mutation.
      
      Fix management of the 'coalesced' loop state variable to merge
      forward/backward results, rather than overwriting the result of forward
      coalescing if attempting to coalesce backward.  In practice this caused
      no correctness issues, but could cause extra iterations in rare cases.
      
      These regressions were introduced by
      d27f29b4 (Disentangle arena and extent
      locking.).
      51779955
  14. Feb 04, 2017
    • Jason Evans's avatar
      Fix a race in extent_grow_retained(). · 6737d5f6
      Jason Evans authored
      Set extent as active prior to registration so that other threads can't
      modify it in the absence of locking.
      
      This regression was introduced by
      d27f29b4 (Disentangle arena and extent
      locking.), via non-obvious means.  Removal of extents_mtx protection
      during extent_grow_retained() execution opened up the race, but in the
      presence of that locking, the code was safe.
      
      This resolves #599.
      6737d5f6
    • Jason Evans's avatar
      Optimize compute_size_with_overflow(). · 1bac516a
      Jason Evans authored
      Do not check for overflow unless it is actually a possibility.
      1bac516a
    • Jason Evans's avatar
      Fix compute_size_with_overflow(). · 767ffa2b
      Jason Evans authored
      Fix compute_size_with_overflow() to use a high_bits mask that has the
      high bits set, rather than the low bits.  This regression was introduced
      by 5154ff32 (Unify the allocation
      paths).
      767ffa2b
  15. Feb 02, 2017
    • Jason Evans's avatar
      Disentangle arena and extent locking. · d27f29b4
      Jason Evans authored
      Refactor arena and extent locking protocols such that arena and
      extent locks are never held when calling into the extent_*_wrapper()
      API.  This requires extra care during purging since the arena lock no
      longer protects the inner purging logic.  It also requires extra care to
      protect extents from being merged with adjacent extents.
      
      Convert extent_t's 'active' flag to an enumerated 'state', so that
      retained extents are explicitly marked as such, rather than depending on
      ring linkage state.
      
      Refactor the extent collections (and their synchronization) for cached
      and retained extents into extents_t.  Incorporate LRU functionality to
      support purging.  Incorporate page count accounting, which replaces
      arena->ndirty and arena->stats.retained.
      
      Assert that no core locks are held when entering any internal
      [de]allocation functions.  This is in addition to existing assertions
      that no locks are held when entering external [de]allocation functions.
      
      Audit and document synchronization protocols for all arena_t fields.
      
      This fixes a potential deadlock due to recursive allocation during
      gdump, in a similar fashion to b49c649b
      (Fix lock order reversal during gdump.), but with a necessarily much
      broader code impact.
      d27f29b4