![]() |
Plasma Engine
2.0
|
This policy implements a linear allocator that can only grow and at some point all allocations gets reset at once. More...
#include <AllocPolicyLinear.h>
Public Types | |
enum | { Alignment = 16 } |
Public Member Functions | |
PL_FORCE_INLINE | plAllocPolicyLinear (plAllocator *pParent) |
PL_FORCE_INLINE void * | Allocate (size_t uiSize, size_t uiAlign) |
PL_FORCE_INLINE void | Deallocate (void *pPtr) |
PL_FORCE_INLINE void | Reset () |
PL_FORCE_INLINE void | FillStats (plAllocator::Stats &ref_stats) |
PL_ALWAYS_INLINE plAllocator * | GetParent () const |
This policy implements a linear allocator that can only grow and at some point all allocations gets reset at once.
For debugging purposes, the policy can also overwrite all freed memory with 0xCDCDCDCD to make it easier to find use-after-free situations.