[PATCH] Remove unused variables in tcache_dalloc_large

Mike Hommey mh+jemalloc at glandium.org
Tue Feb 21 05:12:24 PST 2012


From: Mike Hommey <mh at glandium.org>

---
 include/jemalloc/internal/tcache.h |    7 +------
 1 files changed, 1 insertions(+), 6 deletions(-)

diff --git a/include/jemalloc/internal/tcache.h b/include/jemalloc/internal/tcache.h
index 717682d..5de14f4 100644
--- a/include/jemalloc/internal/tcache.h
+++ b/include/jemalloc/internal/tcache.h
@@ -360,9 +360,7 @@ tcache_dalloc_small(tcache_t *tcache, void *ptr)
 JEMALLOC_INLINE void
 tcache_dalloc_large(tcache_t *tcache, void *ptr, size_t size)
 {
-	arena_t *arena;
-	arena_chunk_t *chunk;
-	size_t pageind, binind;
+	size_t binind;
 	tcache_bin_t *tbin;
 	tcache_bin_info_t *tbin_info;
 
@@ -370,9 +368,6 @@ tcache_dalloc_large(tcache_t *tcache, void *ptr, size_t size)
 	assert(arena_salloc(ptr) > small_maxclass);
 	assert(arena_salloc(ptr) <= tcache_maxclass);
 
-	chunk = (arena_chunk_t *)CHUNK_ADDR2BASE(ptr);
-	arena = chunk->arena;
-	pageind = ((uintptr_t)ptr - (uintptr_t)chunk) >> PAGE_SHIFT;
 	binind = nbins + (size >> PAGE_SHIFT) - 1;
 
 	if (config_fill && opt_junk)
-- 
1.7.9




More information about the jemalloc-discuss mailing list