Lines Matching defs:curPage
428 MemPage* curPage = pool->currentPage;
459 DE_ASSERT(curPage);
462 void* curPagePtr = (void*)((deUint8*)(curPage + 1) + curPage->bytesAllocated);
466 if (numBytes + alignPadding > (size_t)(curPage->capacity - curPage->bytesAllocated))
470 int newPageCapacity = deMax32(deMin32(2*curPage->capacity, MAX_PAGE_SIZE), ((int)numBytes)+maxAlignPadding);
472 curPage = MemPage_create((size_t)newPageCapacity);
473 if (!curPage)
476 curPage->nextPage = pool->currentPage;
477 pool->currentPage = curPage;
479 DE_ASSERT(curPage->bytesAllocated == 0);
481 curPagePtr = (void*)(curPage + 1);
485 DE_ASSERT(numBytes + alignPadding <= (size_t)curPage->capacity);
488 curPage->bytesAllocated += (int)(numBytes + alignPadding);