KMemoryReusePool Class Reference

#include <kmemory.h>
Inheritance diagram for KMemoryReusePool:
Inheritance graph
[legend]

List of all members.


Detailed Description

A pool of memory blocks of arbitrary size.

Definition at line 169 of file kmemory.h.


Protected Attributes

KMpMutex *  mLock
  Critical section on our pool (maintained by pointer only to not force a dependency on windows.h at large).
void **  mBuffer
  Our array of free lists, of size mBufferSize.
size_t const  mSizeRange
  Maximum alloc size.
size_t const  mBufferSize
  mSizeRange >> mStrideShift.
int const  mStrideShift
  Divider for mSizeRange.
int const  mStrideRemainder
  A mask of the remainder of a right shift done with mStrideShift.
int const  mAlignmentShift
  Multiplier, to specify an alignment in bytes.
size_t const  mTotalAllocatedMax
  Maximum total amount of memory handed out or managed by this pool (past this point, normal allocs are done).
size_t  mTotalAllocated
  The total amount of memory handed out or managed by this pool.
size_t  mTotalBlocks
  The total number of blocks handed out or managed by this pool.

Member Data Documentation

KMpMutex* mLock [protected]

Critical section on our pool (maintained by pointer only to not force a dependency on windows.h at large).

Definition at line 206 of file kmemory.h.

void* * mBuffer [protected]

Our array of free lists, of size mBufferSize.

Definition at line 207 of file kmemory.h.

size_t const mSizeRange [protected]

Maximum alloc size.

Definition at line 208 of file kmemory.h.

size_t const mBufferSize [protected]

mSizeRange >> mStrideShift.

Definition at line 209 of file kmemory.h.

int const mStrideShift [protected]

Divider for mSizeRange.

Definition at line 210 of file kmemory.h.

int const mStrideRemainder [protected]

A mask of the remainder of a right shift done with mStrideShift.

Definition at line 211 of file kmemory.h.

int const mAlignmentShift [protected]

Multiplier, to specify an alignment in bytes.

Definition at line 212 of file kmemory.h.

size_t const mTotalAllocatedMax [protected]

Maximum total amount of memory handed out or managed by this pool (past this point, normal allocs are done).

Definition at line 213 of file kmemory.h.

size_t mTotalAllocated [protected]

The total amount of memory handed out or managed by this pool.

Definition at line 214 of file kmemory.h.

size_t mTotalBlocks [protected]

The total number of blocks handed out or managed by this pool.

Definition at line 215 of file kmemory.h.

KMemoryReusePool KMemoryReusePool KMemoryReusePool KMemoryReusePool KMemoryReusePool KMemoryReusePool KMemoryReusePool KMemoryReusePool KMemoryReusePool KMemoryReusePool
KMemoryReusePool KMemoryReusePool KMemoryReusePool KMemoryReusePool KMemoryReusePool KMemoryReusePool KMemoryReusePool KMemoryReusePool KMemoryReusePool KMemoryReusePool