Lines Matching refs:batch
101 // For large size classes we use one of the chunks to store the batch.
105 void *batch[kMaxNumCached];
306 typedef typename SizeClassMap::TransferBatch Batch;
332 NOINLINE Batch* AllocateBatch(AllocatorStats *stat, AllocatorCache *c,
336 Batch *b = region->free_list.Pop();
343 NOINLINE void DeallocateBatch(AllocatorStats *stat, uptr class_id, Batch *b) {
475 LFStack<Batch> free_list;
504 NOINLINE Batch* PopulateFreeList(AllocatorStats *stat, AllocatorCache *c,
507 Batch *b = region->free_list.Pop();
547 b = (Batch*)c->Allocate(this, SizeClassMap::ClassID(sizeof(Batch)));
549 b = (Batch*)(region_beg + beg_idx);
552 b->batch[i] = (void*)(region_beg + beg_idx + i * size);
616 typedef typename SizeClassMap::TransferBatch Batch;
654 NOINLINE Batch* AllocateBatch(AllocatorStats *stat, AllocatorCache *c,
662 Batch *b = sci->free_list.front();
667 NOINLINE void DeallocateBatch(AllocatorStats *stat, uptr class_id, Batch *b) {
759 IntrusiveList<Batch> free_list;
760 char padding[kCacheLineSize - sizeof(uptr) - sizeof(IntrusiveList<Batch>)];
796 Batch *b = 0;
800 b = (Batch*)c->Allocate(this, SizeClassMap::ClassID(sizeof(Batch)));
802 b = (Batch*)i;
805 b->batch[b->count++] = (void*)i;
849 void *res = c->batch[--c->count];
850 PREFETCH(c->batch[c->count - 1]);
865 c->batch[c->count++] = p;
878 typedef typename SizeClassMap::TransferBatch Batch;
882 void *batch[2 * SizeClassMap::kMaxNumCached];
899 Batch *b = allocator->AllocateBatch(&stats_, this, class_id);
902 c->batch[i] = b->batch[i];
905 Deallocate(allocator, SizeClassMap::ClassID(sizeof(Batch)), b);
911 Batch *b;
913 b = (Batch*)Allocate(allocator, SizeClassMap::ClassID(sizeof(Batch)));
915 b = (Batch*)c->batch[0];
918 b->batch[i] = c->batch[i];
919 c->batch[i] = c->batch[i + c->max_count / 2];