32 #ifdef MEMORY_MANAGER_ADD_OWNER_INFORMATION
73 #ifdef MEMORY_MANAGER_ADD_OWNER_INFORMATION
89 #ifdef MEMORY_MANAGER_ADD_OWNER_INFORMATION
200 #ifdef MEMORY_MANAGER_ADD_OWNER_INFORMATION
206 #define new new ( __FILE__, __LINE__ )
207 #define delete( ptr ) MemoryManager.dllocMemory( ptr )
208 #define malloc( sz ) MemoryManager.allocMemory( (U32)sz, false, __FILE__, __LINE__ )
209 #define free( ptr ) MemoryManager.dllocMemory( ptr )
210 #define realloc( ptr, sz ) MemoryManager.rllocMemory( ptr, (U32)sz, __FILE__, __LINE__ )
211 #define calloc( cnt, sz ) MemoryManager.allocMemory( (U32)cnt * (U32)sz, true,__FILE__, __LINE__ )
215 inline VOID *
operator new(
size_t count,
const CHAR* File,
U32 Line )
225 inline VOID *
operator new[](
size_t count,
const CHAR* File,
U32 Line )
237 inline VOID operator delete[](
VOID* void_Pointer_To_Memory )
249 inline VOID operator delete(
VOID* void_Pointer_To_Memory )
264 #define delete delete
265 #define malloc( sz ) MemoryManager.allocMemory( (U32)sz, false )
266 #define free( ptr ) MemoryManager.dllocMemory( ptr )
267 #define realloc( ptr, sz ) MemoryManager.rllocMemory( ptr, (U32)sz )
268 #define calloc( cnt, sz ) MemoryManager.allocMemory( (U32)cnt * (U32)sz, true )
274 inline VOID *
operator new(
size_t count )
286 inline VOID *
operator new[](
size_t count )
298 inline VOID operator delete(
VOID* void_Pointer_To_Memory )
310 inline VOID operator delete[](
VOID* void_Pointer_To_Memory )
#define false
Definition: rtwtypes.h:24
ConOpSys data type definitions header file.
int BOOL
Boolean datatype definition.
Definition: Defines.h:124
void VOID
Datatypesess datatype definition.
Definition: Defines.h:105
unsigned long U32
Binary 32-Bit unsigned integer datatype defenition.
Definition: Defines.h:203
TMemoryManager MemoryManager
Definition: Memory_Manager.h:25
U32 Status
Definition: Memory_Manager.h:28
U32 Size
Definition: Memory_Manager.h:29
TAllocatedSegment * NextSegment
Definition: Memory_Manager.h:31
TAllocatedSegment * PreviousSegment
Definition: Memory_Manager.h:30
Definition: Memory_Manager.h:83
U32 MaximalUsedMemory
Definition: Memory_Manager.h:140
BOOL CheckIntegrity()
Definition: Memory_Manager.cpp:938
U32 MaximalFreeSegmentSize
Definition: Memory_Manager.h:155
U32 AllocationErrorCount
Definition: Memory_Manager.h:170
U32 WastedMemorySize
Definition: Memory_Manager.h:134
TAllocatedSegment * FirstFreeSegment
Definition: Memory_Manager.h:125
U32 TotalSegments
Definition: Memory_Manager.h:149
U32 ReallocationErrorCount
Definition: Memory_Manager.h:173
U32 TotalMemorySize
Definition: Memory_Manager.h:128
U32 AllocatedSegments
Definition: Memory_Manager.h:143
VOID * allocMemory(U32 Size, BOOL Clear)
Definition: Memory_Manager.cpp:284
TAllocatedSegment * BottomSegment
Definition: Memory_Manager.h:119
VOID MergeSegments(TAllocatedSegment *Segment)
Definition: Memory_Manager.cpp:783
VOID GetStatistics(TMemoryStatistics *Statistics)
Definition: Memory_Manager.cpp:1161
TAllocatedSegment * TopSegment
Definition: Memory_Manager.h:122
U32 AllocatedMemorySize
Definition: Memory_Manager.h:131
TMemoryManager(VOID *ParentBaseAddress, U32 MemorySize)
Definition: Memory_Manager.cpp:45
U32 DeallocationErrorCount
Definition: Memory_Manager.h:176
VOID * rllocMemory(VOID *Pointer, U32 Size)
Definition: Memory_Manager.cpp:540
U32 FailedSegmentSatus
Definition: Memory_Manager.h:182
VOID dllocMemory(VOID *Pointer)
Definition: Memory_Manager.cpp:682
VOID * BaseAddress
Definition: Memory_Manager.h:116
BOOL Is_Segment_Valid(TAllocatedSegment *object_Segment)
Definition: Memory_Manager.cpp:100
U32 AllocateClearedMemoryRequests
Definition: Memory_Manager.h:158
TAllocatedSegment * FailedSegment
Definition: Memory_Manager.h:179
BOOL Is_Segment_Free(TAllocatedSegment *object_Segment)
Definition: Memory_Manager.cpp:161
U32 AllocateMemoryRequests
Definition: Memory_Manager.h:161
U32 ReallocateMemoryRequests
Definition: Memory_Manager.h:167
BOOL SplitSegment(TAllocatedSegment *Segment, U32 SegmentSizeToAllocation)
Definition: Memory_Manager.cpp:833
U32 FreeSegments
Definition: Memory_Manager.h:146
VOID SetFirstFreeSegment(TAllocatedSegment *Segment)
Definition: Memory_Manager.cpp:907
BOOL Is_Segment_Allocated(TAllocatedSegment *object_Segment)
Definition: Memory_Manager.cpp:221
U32 DeallocateMemoryRequests
Definition: Memory_Manager.h:164
U32 MaximalAllocatedSegmentSize
Definition: Memory_Manager.h:152
U32 FreeMemorySize
Definition: Memory_Manager.h:137
Definition: Memory_Manager.h:42
U32 WastedMemorySize
Definition: Memory_Manager.h:49
VOID * BottomSegment
Definition: Memory_Manager.h:45
U32 FreeMemorySize
Definition: Memory_Manager.h:50
U32 MaximalUsedMemory
Definition: Memory_Manager.h:52
U32 TotalSegments
Definition: Memory_Manager.h:56
VOID * BaseAddress
Definition: Memory_Manager.h:44
U32 DeallocateMemoryRequests
Definition: Memory_Manager.h:63
U32 AllocatedMemorySize
Definition: Memory_Manager.h:48
U32 TotalMemorySize
Definition: Memory_Manager.h:47
U32 FailedSegmentSatus
Definition: Memory_Manager.h:71
U32 ReallocationErrorCount
Definition: Memory_Manager.h:67
U32 AllocateMemoryRequests
Definition: Memory_Manager.h:62
U32 ReallocateMemoryRequests
Definition: Memory_Manager.h:64
U32 MaximalAllocatedSegmentSize
Definition: Memory_Manager.h:58
U32 FreeSegments
Definition: Memory_Manager.h:55
VOID * TopSegment
Definition: Memory_Manager.h:46
U32 AllocationErrorCount
Definition: Memory_Manager.h:66
U32 AllocateClearedMemoryRequests
Definition: Memory_Manager.h:61
U32 AllocatedSegments
Definition: Memory_Manager.h:54
U32 DeallocationErrorCount
Definition: Memory_Manager.h:68
VOID * FailedSegment
Definition: Memory_Manager.h:70
U32 MaximalFreeSegmentSize
Definition: Memory_Manager.h:59