#include <Allocator.h>
Inheritance diagram for nvutil::IAllocator:
Public Types | |
typedef Singleton< Allocator > | theAllocator |
Convenient typedef. More... | |
Public Methods | |
IAllocator () | |
Default constructor. More... | |
virtual | ~IAllocator () |
Destructor. More... | |
NVSG_API void * | operator new (size_t size) |
Operator new overload. More... | |
NVSG_API void * | operator new (size_t size, void *p) |
Placement operator new overload. More... | |
NVSG_API void | operator delete (void *p, size_t size) |
Operator delete overload. More... |
The IAllocator
interface provides overloads of the new
and delete
operators for heap allocation. This overloads make use of a specialized memory manager, that is highly optimized for small object allocation. For large objects, i.e. objects greater than 128 bytes, the IAllocator
interface utilizes the default memory manager.
|
Convenient typedef.
|
|
Default constructor.
Default constructs an |
|
Destructor.
|
|
Operator new overload. Allocates a memory block of size bytes from heap. Returns start address of allocated memory block. |
|
Placement operator new overload. Provides object creation at a specified memory address. p must point to a valid block of memory, large enough to hold an object of size bytes. Return start address of the specified memory block. |
|
Operator delete overload. Frees size bytes of memory at address p. |