Qt
Internal/Contributor docs for the Qt SDK. <b>Note:</b> These are NOT official API docs; those are found <a href='https://doc.qt.io/'>here</a>.
|
#include <qv4mm_p.h>
Public Types | |
enum | { NumBins = 8 } |
Public Member Functions | |
BlockAllocator (ChunkAllocator *chunkAllocator, ExecutionEngine *engine) | |
HeapItem * | allocate (size_t size, bool forceAllocation=false) |
size_t | totalSlots () const |
size_t | allocatedMem () const |
size_t | usedMem () const |
void | sweep () |
void | freeAll () |
void | resetBlackBits () |
Static Public Member Functions | |
static size_t | binForSlots (size_t nSlots) |
Public Attributes | |
HeapItem * | nextFree = nullptr |
size_t | nFree = 0 |
size_t | usedSlotsAfterLastSweep = 0 |
HeapItem * | freeBins [NumBins] |
ChunkAllocator * | chunkAllocator |
ExecutionEngine * | engine |
std::vector< Chunk * > | chunks |
uint * | allocationStats = nullptr |
|
inline |
Definition at line 445 of file qv4mm.cpp.
References done, engine, QV4::HeapItem::freeData, i, Q_ASSERT, and Q_V4_PROFILE_ALLOC.
|
inline |
Definition at line 120 of file qv4mm_p.h.
References chunks, and QV4::Chunk::DataSize.
Referenced by QV4::MemoryManager::getAllocatedMem(), QV4::MemoryManager::runGC(), and QV4::MemoryManager::updateUnmanagedHeapSizeGCLimit().
|
inlinestatic |
void QV4::BlockAllocator::freeAll | ( | ) |
Definition at line 583 of file qv4mm.cpp.
References engine, and Q_V4_PROFILE_DEALLOC.
Referenced by QV4::MemoryManager::~MemoryManager().
void QV4::BlockAllocator::resetBlackBits | ( | ) |
Definition at line 593 of file qv4mm.cpp.
Referenced by QV4::MemoryManager::~MemoryManager(), and QV4::MemoryManager::sweep().
void QV4::BlockAllocator::sweep | ( | ) |
Definition at line 555 of file qv4mm.cpp.
Referenced by QV4::MemoryManager::sweep().
|
inline |
Definition at line 116 of file qv4mm_p.h.
References QV4::Chunk::AvailableSlots, and chunks.
|
inline |
Definition at line 123 of file qv4mm_p.h.
References chunks, and QV4::Chunk::SlotSize.
Referenced by QV4::MemoryManager::getUsedMem(), and QV4::MemoryManager::updateUnmanagedHeapSizeGCLimit().
Definition at line 142 of file qv4mm_p.h.
Referenced by QV4::MemoryManager::MemoryManager().
ChunkAllocator* QV4::BlockAllocator::chunkAllocator |
std::vector<Chunk *> QV4::BlockAllocator::chunks |
Definition at line 141 of file qv4mm_p.h.
Referenced by allocatedMem(), QV4::MemoryManager::runGC(), totalSlots(), and usedMem().
ExecutionEngine* QV4::BlockAllocator::engine |
Definition at line 138 of file qv4mm_p.h.
Referenced by BlockAllocator().
size_t QV4::BlockAllocator::usedSlotsAfterLastSweep = 0 |
Definition at line 137 of file qv4mm_p.h.
Referenced by QV4::MemoryManager::sweep().