gatb.core-API-0.0.0
|
Interface providing methods for dynamic allocation and memory statistics. More...
#include <IMemory.hpp>
Public Member Functions | |
virtual size_t | getNbBlocks ()=0 |
virtual TotalSize_t | getCurrentUsage ()=0 |
virtual TotalSize_t | getMaximumUsage ()=0 |
virtual | ~IMemory () |
Public Member Functions inherited from IMemoryAllocator | |
virtual void * | malloc (BlockSize_t size)=0 |
virtual void * | calloc (size_t nmemb, BlockSize_t size)=0 |
virtual void * | realloc (void *ptr, BlockSize_t size)=0 |
virtual void | free (void *ptr)=0 |
virtual | ~IMemoryAllocator () |
Public Member Functions inherited from IMemoryOperations | |
virtual void * | memset (void *s, int c, size_t n)=0 |
virtual void * | memcpy (void *dest, const void *src, size_t n)=0 |
virtual int | memcmp (const void *s1, const void *s2, size_t n)=0 |
virtual | ~IMemoryOperations () |
Additional Inherited Members | |
Public Types inherited from IMemoryAllocator | |
typedef u_int64_t | BlockSize_t |
typedef u_int64_t | TotalSize_t |
Interface providing methods for dynamic allocation and memory statistics.
This interface provides most common methods for creating/deleting dynamic allocation buffers.
It also provides information about its inner state (current memory usage, maximum reached).
Specific implementations could be:
|
inlinevirtual |
Destructor.
|
pure virtual |
Get the memory usage by the current process.
Implemented in MemoryCommon.
|
pure virtual |
Get the maximum reached size.
Implemented in MemoryCommon.
|
pure virtual |
Get the number of currently allocated memory blocks.
Implemented in MemoryCommon.