CommonLibSSE (Parapets fork)
Loading...
Searching...
No Matches
RE::MemoryManager Class Reference

#include <MemoryManager.h>

Classes

struct  ThreadScrapHeap
 

Public Member Functions

void * Allocate (std::size_t a_size, std::int32_t a_alignment, bool a_alignmentRequired)
 
void Deallocate (void *a_mem, bool a_alignmentRequired)
 
ScrapHeapGetThreadScrapHeap ()
 
void * Reallocate (void *a_oldMem, std::size_t a_newSize, std::int32_t a_alignment, bool a_aligned)
 
void RegisterMemoryManager ()
 

Static Public Member Functions

static MemoryManagerGetSingleton ()
 

Public Attributes

bool initialized { false }
 
std::uint16_t numHeaps { 0 }
 
std::uint16_t numPhysicalHeaps { 0 }
 
IMemoryHeap ** heaps { nullptr }
 
bool * allowOtherContextAllocs { nullptr }
 
IMemoryHeapheapsByContext [127] { nullptr }
 
ThreadScrapHeapthreadScrapHeap { nullptr }
 
IMemoryHeap ** physicalHeaps { nullptr }
 
IMemoryHeapbigAllocHeap { nullptr }
 
IMemoryHeapemergencyHeap { nullptr }
 
BSSmallBlockAllocatorsmallBlockAllocator { nullptr }
 
CompactingStore::StorecompactingStore { nullptr }
 
IMemoryHeapexternalHavokAllocator { nullptr }
 
bool specialHeaps { false }
 
bool allowPoolUse { true }
 
std::uint32_t sysAllocBytes { 0 }
 
std::uint32_t mallocBytes { 0 }
 
std::uint32_t alignmentForPools { 4 }
 
std::uint32_t mainThreadMemoryProblemPassSignal { 0 }
 
std::size_t failedAllocationSize { 0 }
 
std::uint32_t numMemoryProblemPassesRun { 0 }
 
std::size_t timeOfLastMemoryProblemPass { 0 }
 
IMemoryHeapdefaultHeap { nullptr }
 

Member Function Documentation

◆ Allocate()

void * RE::MemoryManager::Allocate ( std::size_t  a_size,
std::int32_t  a_alignment,
bool  a_alignmentRequired 
)
inline

◆ Deallocate()

void RE::MemoryManager::Deallocate ( void *  a_mem,
bool  a_alignmentRequired 
)
inline

◆ GetSingleton()

static MemoryManager * RE::MemoryManager::GetSingleton ( )
inlinestatic

◆ GetThreadScrapHeap()

ScrapHeap * RE::MemoryManager::GetThreadScrapHeap ( )
inline

◆ Reallocate()

void * RE::MemoryManager::Reallocate ( void *  a_oldMem,
std::size_t  a_newSize,
std::int32_t  a_alignment,
bool  a_aligned 
)
inline

◆ RegisterMemoryManager()

void RE::MemoryManager::RegisterMemoryManager ( )
inline

Member Data Documentation

◆ alignmentForPools

std::uint32_t RE::MemoryManager::alignmentForPools { 4 }

◆ allowOtherContextAllocs

bool* RE::MemoryManager::allowOtherContextAllocs { nullptr }

◆ allowPoolUse

bool RE::MemoryManager::allowPoolUse { true }

◆ bigAllocHeap

IMemoryHeap* RE::MemoryManager::bigAllocHeap { nullptr }

◆ compactingStore

CompactingStore::Store* RE::MemoryManager::compactingStore { nullptr }

◆ defaultHeap

IMemoryHeap* RE::MemoryManager::defaultHeap { nullptr }

◆ emergencyHeap

IMemoryHeap* RE::MemoryManager::emergencyHeap { nullptr }

◆ externalHavokAllocator

IMemoryHeap* RE::MemoryManager::externalHavokAllocator { nullptr }

◆ failedAllocationSize

std::size_t RE::MemoryManager::failedAllocationSize { 0 }

◆ heaps

IMemoryHeap** RE::MemoryManager::heaps { nullptr }

◆ heapsByContext

IMemoryHeap* RE::MemoryManager::heapsByContext[127] { nullptr }

◆ initialized

bool RE::MemoryManager::initialized { false }

◆ mainThreadMemoryProblemPassSignal

std::uint32_t RE::MemoryManager::mainThreadMemoryProblemPassSignal { 0 }

◆ mallocBytes

std::uint32_t RE::MemoryManager::mallocBytes { 0 }

◆ numHeaps

std::uint16_t RE::MemoryManager::numHeaps { 0 }

◆ numMemoryProblemPassesRun

std::uint32_t RE::MemoryManager::numMemoryProblemPassesRun { 0 }

◆ numPhysicalHeaps

std::uint16_t RE::MemoryManager::numPhysicalHeaps { 0 }

◆ physicalHeaps

IMemoryHeap** RE::MemoryManager::physicalHeaps { nullptr }

◆ smallBlockAllocator

BSSmallBlockAllocator* RE::MemoryManager::smallBlockAllocator { nullptr }

◆ specialHeaps

bool RE::MemoryManager::specialHeaps { false }

◆ sysAllocBytes

std::uint32_t RE::MemoryManager::sysAllocBytes { 0 }

◆ threadScrapHeap

ThreadScrapHeap* RE::MemoryManager::threadScrapHeap { nullptr }

◆ timeOfLastMemoryProblemPass

std::size_t RE::MemoryManager::timeOfLastMemoryProblemPass { 0 }

The documentation for this class was generated from the following file: