|
|
The shared mempager uses a mutex to protect key access methods. This class is used when a mempager will be shared by multiple threads.
SharedMemPager (int pg = 4096) |
Create a mempager mutex pool.
Parameters:
pagesize | for allocation. |
void purge (void) |
Purge the memory pool while locked.
Reimplemented from MemPager
void * first (int size) |
Get the first memory page after locking.
Parameters:
size | of request. |
Returns: allocated memory space.
Reimplemented from MemPager
void * alloc (int size) |
Get the last memory page after locking.
Parameters:
size | of request. |
Returns: allocated memory space.
Reimplemented from MemPager