SpiecsEngine
 
Loading...
Searching...
No Matches
Spices::ThreadCache Class Reference

Thread memory cache. First level of memory allocator. More...

#include <ThrealCache.h>

Public Member Functions

 ThreadCache ()=default
 Constructor Function.
 
virtual ~ThreadCache ()
 Destructor Function.
 
 ThreadCache (const ThreadCache &)=delete
 Copy Constructor Function.
 
ThreadCacheoperator= (const ThreadCache &)=delete
 Copy Assignment Operation.
 
void * Allocate (size_t size)
 Allocate memory.
 
void Deallocate (void *obj, size_t size)
 Recycle object memory.
 

Private Member Functions

void * FetchFromCentralCache (size_t index, size_t alignSize)
 Fetch memory from central cache if this is run out.
 

Static Private Member Functions

static void ReleaseToCentralCache (scl::free_list &list, size_t size, size_t count)
 Release memory to cc.
 

Private Attributes

std::array< scl::free_list, MemoryPool::FREE_LIST_NUMm_FreeLists
 FreeList Array.
 

Detailed Description

Thread memory cache. First level of memory allocator.

Definition at line 18 of file ThrealCache.h.


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