[BACK]Return to jemalloc.c CVS log [TXT][DIR] Up to [cvs.NetBSD.org] / src / lib / libc / stdlib

Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.

Diff for /src/lib/libc/stdlib/jemalloc.c between version 1.44 and 1.44.4.1

version 1.44, 2017/12/01 22:47:06 version 1.44.4.1, 2019/06/10 22:05:21
Line 704  static chunk_tree_t huge;
Line 704  static chunk_tree_t huge;
  * base_pages_alloc() also uses sbrk(), but cannot lock chunks_mtx (doing so   * base_pages_alloc() also uses sbrk(), but cannot lock chunks_mtx (doing so
  * could cause recursive lock acquisition).   * could cause recursive lock acquisition).
  */   */
   #ifdef _REENTRANT
 static malloc_mutex_t   brk_mtx;  static malloc_mutex_t   brk_mtx;
   #endif
 /* Result of first sbrk(0) call. */  /* Result of first sbrk(0) call. */
 static void             *brk_base;  static void             *brk_base;
 /* Current end of brk, or ((void *)-1) if brk is exhausted. */  /* Current end of brk, or ((void *)-1) if brk is exhausted. */
Line 1704  arena_run_reg_alloc(arena_run_t *run, ar
Line 1706  arena_run_reg_alloc(arena_run_t *run, ar
                     + (bin->reg_size * regind));                      + (bin->reg_size * regind));
   
                 /* Clear bit. */                  /* Clear bit. */
                 mask ^= (1 << bit);                  mask ^= (1U << bit);
                 run->regs_mask[i] = mask;                  run->regs_mask[i] = mask;
   
                 return (ret);                  return (ret);
Line 1721  arena_run_reg_alloc(arena_run_t *run, ar
Line 1723  arena_run_reg_alloc(arena_run_t *run, ar
                             + (bin->reg_size * regind));                              + (bin->reg_size * regind));
   
                         /* Clear bit. */                          /* Clear bit. */
                         mask ^= (1 << bit);                          mask ^= (1U << bit);
                         run->regs_mask[i] = mask;                          run->regs_mask[i] = mask;
   
                         /*                          /*
Line 1836  arena_run_reg_dalloc(arena_run_t *run, a
Line 1838  arena_run_reg_dalloc(arena_run_t *run, a
         if (elm < run->regs_minelm)          if (elm < run->regs_minelm)
                 run->regs_minelm = elm;                  run->regs_minelm = elm;
         bit = regind - (elm << (SIZEOF_INT_2POW + 3));          bit = regind - (elm << (SIZEOF_INT_2POW + 3));
         assert((run->regs_mask[elm] & (1 << bit)) == 0);          assert((run->regs_mask[elm] & (1U << bit)) == 0);
         run->regs_mask[elm] |= (1 << bit);          run->regs_mask[elm] |= (1U << bit);
 #undef SIZE_INV  #undef SIZE_INV
 #undef SIZE_INV_SHIFT  #undef SIZE_INV_SHIFT
 }  }

Legend:
Removed from v.1.44  
changed lines
  Added in v.1.44.4.1

CVSweb <webmaster@jp.NetBSD.org>