зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1278796, part 3 - Inline StartBlock. r=smaug
This method doesn't do much, and in a later patch it will do even less.
This commit is contained in:
Родитель
6e83659330
Коммит
21a0cf7d40
|
@ -1064,15 +1064,8 @@ public:
|
|||
void InitBlocks()
|
||||
{
|
||||
mCount = 0;
|
||||
mFreeList = nullptr;
|
||||
StartBlock(&mFirstBlock);
|
||||
}
|
||||
|
||||
void StartBlock(PurpleBlock* aBlock)
|
||||
{
|
||||
MOZ_ASSERT(!mFreeList, "should not have free list");
|
||||
mFreeList = aBlock->mEntries;
|
||||
aBlock->InitNextPointers();
|
||||
mFreeList = mFirstBlock.mEntries;
|
||||
mFirstBlock.InitNextPointers();
|
||||
}
|
||||
|
||||
void FreeBlocks()
|
||||
|
@ -1130,7 +1123,8 @@ public:
|
|||
{
|
||||
if (MOZ_UNLIKELY(!mFreeList)) {
|
||||
PurpleBlock* b = new PurpleBlock;
|
||||
StartBlock(b);
|
||||
mFreeList = b->mEntries;
|
||||
b->InitNextPointers();
|
||||
|
||||
// Add the new block as the second block in the list.
|
||||
b->mNext = mFirstBlock.mNext;
|
||||
|
|
Загрузка…
Ссылка в новой задаче