Index: compiler-rt/trunk/lib/sanitizer_common/sanitizer_allocator_local_cache.h =================================================================== --- compiler-rt/trunk/lib/sanitizer_common/sanitizer_allocator_local_cache.h +++ compiler-rt/trunk/lib/sanitizer_common/sanitizer_allocator_local_cache.h @@ -102,7 +102,7 @@ NOINLINE void Refill(PerClass *c, SizeClassAllocator *allocator, uptr class_id) { InitCache(); - uptr num_requested_chunks = SizeClassMap::MaxCachedHint(class_id); + uptr num_requested_chunks = c->max_count / 2; allocator->GetFromAllocator(&stats_, class_id, c->chunks, num_requested_chunks); c->count = num_requested_chunks;