CommonLibSSE (Parapets fork)
|
#include <bhkThreadMemorySource.h>
Classes | |
struct | BlockPage |
struct | FreeBlock |
struct | MegaBlockPage |
struct | Row |
Public Member Functions | |
~bhkThreadMemorySource () override | |
void * | BlockAlloc (std::int32_t a_numBytes) override |
void | BlockFree (void *a_ptr, std::int32_t a_numBytes) override |
void * | BufAlloc (std::int32_t &a_reqNumBytesInOut) override |
void | BufFree (void *a_ptr, std::int32_t a_numBytes) override |
void * | BufRealloc (void *a_ptrOld, std::int32_t a_oldNumBytes, std::int32_t &a_reqNumBytesInOut) override |
void | BlockAllocBatch (void **a_ptrsOut, std::int32_t a_numPtrs, std::int32_t a_blockSize) override |
void | BlockFreeBatch (void **a_ptrsIn, std::int32_t a_numPtrs, std::int32_t a_blockSize) override |
void | GetMemoryStatistics (MemoryStatistics &a_usage) override |
std::int32_t | GetAllocatedSize (const void *a_obj, std::int32_t a_numBytes) override |
std::size_t | Size (const void *a_block) const override |
void | GetMemoryStats (MemoryStats *a_stats) override |
const char * | GetName () const override |
void * | Allocate (std::size_t a_size, std::uint32_t a_alignment) override |
void | Deallocate (void *a_pointer, std::uint32_t) override |
bool | PointerInHeap (const void *a_pointer) const override |
std::size_t | TotalSize (const void *a_pointer) const override |
void | GetHeapStats (HeapStats *a_stats, bool a_fullBlockInfo) override |
bool | ShouldTrySmallBlockPools (std::size_t a_size, MEM_CONTEXT a_context) override |
std::uint32_t | GetPageSize () const override |
Public Member Functions inherited from RE::hkMemoryAllocator | |
virtual | ~hkMemoryAllocator () |
virtual void * | BlockAlloc (std::int32_t a_numBytes)=0 |
virtual void | BlockFree (void *a_ptr, std::int32_t a_numBytes)=0 |
virtual void * | BufAlloc (std::int32_t &a_reqNumBytesInOut) |
virtual void | BufFree (void *a_ptr, std::int32_t a_numBytes) |
virtual void * | BufRealloc (void *a_ptrOld, std::int32_t a_oldNumBytes, std::int32_t &a_reqNumBytesInOut) |
virtual void | BlockAllocBatch (void **a_ptrsOut, std::int32_t a_numPtrs, std::int32_t a_blockSize) |
virtual void | BlockFreeBatch (void **a_ptrsIn, std::int32_t a_numPtrs, std::int32_t a_blockSize) |
virtual void | GetMemoryStatistics (MemoryStatistics &a_usage)=0 |
virtual std::int32_t | GetAllocatedSize (const void *a_obj, std::int32_t a_numBytes)=0 |
virtual void | ResetPeakMemoryStatistics () |
Public Member Functions inherited from RE::IMemoryHeap | |
~IMemoryHeap () override=default | |
bool | ContainsBlockImpl (const void *a_block) const override |
void * | AllocateAlignImpl (std::size_t a_size, std::uint32_t a_alignment) override |
void | DeallocateAlignImpl (void *&a_block) override |
virtual const char * | GetName () const =0 |
virtual void * | Allocate (std::size_t a_size, std::uint32_t a_alignment)=0 |
virtual void | Deallocate (void *a_mem, std::uint32_t)=0 |
virtual bool | PointerInHeap (const void *a_pointer) const =0 |
virtual std::size_t | TotalSize (const void *a_pointer) const =0 |
virtual void | GetHeapStats (HeapStats *a_stats, bool a_fullBlockInfo)=0 |
virtual bool | ShouldTrySmallBlockPools (std::size_t a_size, MEM_CONTEXT a_context)=0 |
virtual std::uint32_t | GetPageSize () const =0 |
Public Member Functions inherited from RE::IMemoryStore | |
~IMemoryStore () override=default | |
virtual void * | AllocateAlignImpl (std::size_t a_size, std::uint32_t a_alignment)=0 |
virtual void | DeallocateAlignImpl (void *&a_block)=0 |
virtual void * | TryAllocateImpl (std::size_t a_size, std::uint32_t a_alignment) |
void * | AllocateAlign (std::size_t a_size, std::uint32_t a_alignment) |
void | DeallocateAlign (void *&a_freeBlock) |
Public Member Functions inherited from RE::IMemoryStoreBase | |
virtual | ~IMemoryStoreBase ()=default |
virtual std::size_t | Size (const void *a_mem) const =0 |
virtual void | GetMemoryStats (MemoryStats *a_stats)=0 |
virtual bool | ContainsBlockImpl (const void *a_block) const =0 |
Public Attributes | |
BSCriticalSection | lock |
Row * | rows |
std::uint16_t * | smallRowIndexes |
std::uint16_t * | largeRowIndexes |
HeapBlock ** | lists |
HeapBlockFreeHead * | largeFreeTrees |
HeapBlock * | firstBlock |
HeapBlock * | lastBlock |
void * | memoryRoot |
char * | allocBase |
char * | blockStart |
char * | allocEnd |
char * | commitEnd |
char * | blockPageCommit |
char * | addressSpaceEnd |
MegaBlockPage * | megaBlockPageList |
MegaBlockPage * | currMegaBlockPageAlloc |
std::int32_t | addressSpaceSize |
std::int32_t | totalFreeBlockPages |
std::uint32_t | usedRows |
std::int32_t | totalAllocated |
std::int32_t | totalFreeBlocks |
std::int32_t | totalBlocks |
bool | allowDecommits |
std::uint8_t | padD1 |
std::uint16_t | padD2 |
std::uint32_t | padD4 |
Static Public Attributes | |
static constexpr auto | RTTI = RTTI_bhkThreadMemorySource |
Static Public Attributes inherited from RE::hkMemoryAllocator | |
static constexpr auto | RTTI = RTTI_hkMemoryAllocator |
Static Public Attributes inherited from RE::IMemoryHeap | |
static constexpr auto | RTTI = RTTI_IMemoryHeap |
Static Public Attributes inherited from RE::IMemoryStore | |
static constexpr auto | RTTI = RTTI_IMemoryStore |
Static Public Attributes inherited from RE::IMemoryStoreBase | |
static constexpr auto | RTTI = RTTI_IMemoryStoreBase |
Additional Inherited Members | |
Public Types inherited from RE::hkMemoryAllocator | |
enum class | MemoryState { kOK , kOutOfMemory } |
using | MemoryWalkCallback = void(void *a_start, std::size_t a_size, bool a_allocated, std::int32_t a_pool, void *a_param) |
|
override |
|
overridevirtual |
Implements RE::IMemoryHeap.
|
overridevirtual |
Implements RE::hkMemoryAllocator.
|
overridevirtual |
Reimplemented from RE::hkMemoryAllocator.
|
overridevirtual |
Implements RE::hkMemoryAllocator.
|
overridevirtual |
Reimplemented from RE::hkMemoryAllocator.
|
overridevirtual |
Reimplemented from RE::hkMemoryAllocator.
|
overridevirtual |
Reimplemented from RE::hkMemoryAllocator.
|
overridevirtual |
Reimplemented from RE::hkMemoryAllocator.
|
overridevirtual |
Implements RE::IMemoryHeap.
|
overridevirtual |
Implements RE::hkMemoryAllocator.
|
overridevirtual |
Implements RE::IMemoryHeap.
|
overridevirtual |
Implements RE::hkMemoryAllocator.
|
overridevirtual |
Implements RE::IMemoryStoreBase.
|
overridevirtual |
Implements RE::IMemoryHeap.
|
overridevirtual |
Implements RE::IMemoryHeap.
|
overridevirtual |
Implements RE::IMemoryHeap.
|
overridevirtual |
Implements RE::IMemoryHeap.
|
overridevirtual |
Implements RE::IMemoryStoreBase.
|
overridevirtual |
Implements RE::IMemoryHeap.
char* RE::bhkThreadMemorySource::addressSpaceEnd |
std::int32_t RE::bhkThreadMemorySource::addressSpaceSize |
char* RE::bhkThreadMemorySource::allocBase |
char* RE::bhkThreadMemorySource::allocEnd |
bool RE::bhkThreadMemorySource::allowDecommits |
char* RE::bhkThreadMemorySource::blockPageCommit |
char* RE::bhkThreadMemorySource::blockStart |
char* RE::bhkThreadMemorySource::commitEnd |
MegaBlockPage* RE::bhkThreadMemorySource::currMegaBlockPageAlloc |
HeapBlock* RE::bhkThreadMemorySource::firstBlock |
HeapBlockFreeHead* RE::bhkThreadMemorySource::largeFreeTrees |
std::uint16_t* RE::bhkThreadMemorySource::largeRowIndexes |
HeapBlock* RE::bhkThreadMemorySource::lastBlock |
HeapBlock** RE::bhkThreadMemorySource::lists |
BSCriticalSection RE::bhkThreadMemorySource::lock |
MegaBlockPage* RE::bhkThreadMemorySource::megaBlockPageList |
void* RE::bhkThreadMemorySource::memoryRoot |
std::uint8_t RE::bhkThreadMemorySource::padD1 |
std::uint16_t RE::bhkThreadMemorySource::padD2 |
std::uint32_t RE::bhkThreadMemorySource::padD4 |
Row* RE::bhkThreadMemorySource::rows |
|
inlinestaticconstexpr |
std::uint16_t* RE::bhkThreadMemorySource::smallRowIndexes |
std::int32_t RE::bhkThreadMemorySource::totalAllocated |
std::int32_t RE::bhkThreadMemorySource::totalBlocks |
std::int32_t RE::bhkThreadMemorySource::totalFreeBlockPages |
std::int32_t RE::bhkThreadMemorySource::totalFreeBlocks |
std::uint32_t RE::bhkThreadMemorySource::usedRows |