30 #ifndef __MemoryNedPooling_H__
31 #define __MemoryNedPooling_H__
33 #if OGRE_MEMORY_ALLOCATOR == OGRE_MEMORY_ALLOCATOR_NEDPOOLING
48 static void* allocBytes(
size_t count,
49 const char* file,
int line,
const char* func);
50 static void deallocBytes(
void* ptr);
51 static void* allocBytesAligned(
size_t align,
size_t count,
52 const char* file,
int line,
const char* func);
53 static void deallocBytesAligned(
size_t align,
void* ptr);
69 const char* file = 0,
int line = 0,
const char* func = 0)
80 return std::numeric_limits<size_t>::max();
102 template <
size_t Alignment = 0>
108 [Alignment <= 128 && ((Alignment & (Alignment-1)) == 0) ? +1 : -1];
111 const char* file = 0,
int line = 0,
const char* func = 0)
124 return std::numeric_limits<size_t>::max();
142 #endif // __MemoryNedPooling_H__
Non-templated utility class just to hide nedmalloc.
static size_t getMaxAllocationSize()
Get the maximum size of a single allocation.
static void * allocBytes(size_t count, const char *file, int line, const char *func)
static void deallocBytes(void *ptr)
static size_t getMaxAllocationSize()
Get the maximum size of a single allocation.
static void * allocBytesAligned(size_t align, size_t count, const char *file, int line, const char *func)
int IsValidAlignment[Alignment<=128 &&((Alignment &(Alignment-1))==0)?+1:-1]
NedPoolingAlignedPolicy()
An allocation policy for use with AllocatedObject and STLAllocator.
static void * allocateBytes(size_t count, const char *file=0, int line=0, const char *func=0)
An allocation policy for use with AllocatedObject and STLAllocator, which aligns memory at a given bo...
static void deallocBytesAligned(size_t align, void *ptr)
static void deallocateBytes(void *ptr)
static void deallocateBytes(void *ptr)
static void * allocateBytes(size_t count, const char *file=0, int line=0, const char *func=0)