Lines Matching refs:BG
380 // FreeList - > BG -> BG -> BG
388 // Each BlockGroup(BG) will associate with unique group id and the free blocks
410 BatchGroup *BG = nullptr;
414 BG = reinterpret_cast<BatchGroup *>(
416 BG->Batches.clear();
422 BG = C->createGroup();
423 BG->Batches.clear();
429 BG->GroupId = GroupId;
430 BG->Batches.push_front(TB);
431 BG->PushedBlocks = 0;
432 BG->PushedBlocksAtLastCheckpoint = 0;
433 BG->MaxCachedPerBatch =
436 return BG;
439 auto InsertBlocks = [&](BatchGroup *BG, CompactPtrT *Array, u32 Size) {
440 SinglyLinkedList<TransferBatch> &Batches = BG->Batches;
445 DCHECK_GE(BG->MaxCachedPerBatch, CurBatch->getCount());
447 static_cast<u16>(BG->MaxCachedPerBatch - CurBatch->getCount());
454 UnusedSlots = BG->MaxCachedPerBatch;
462 BG->PushedBlocks += Size;
548 BatchGroup *BG = Region->FreeList.front();
557 C->deallocate(SizeClassMap::BatchClassId, BG);
701 for (BatchGroup &BG : Region->FreeList) {
703 BG.PushedBlocks - BG.PushedBlocksAtLastCheckpoint;
735 Max(batchGroupBase(CompactPtrBase, BG.GroupId), Region->RegionBeg);
738 batchGroupBase(CompactPtrBase, BG.GroupId) + GroupSize;
745 // TransferBatches are pushed in front of BG.Batches. The first one may
747 const uptr NumBlocks = (BG.Batches.size() - 1) * BG.MaxCachedPerBatch +
748 BG.Batches.front()->getCount();
759 BG.PushedBlocksAtLastCheckpoint = BG.PushedBlocks;
762 Context.markFreeBlocks(BG.Batches, DecompactPtr, Region->RegionBeg);