From 2628784ff604bdea0280d12c2f341e323838f9c9 Mon Sep 17 00:00:00 2001 From: Jamie Reece Wilson Date: Fri, 19 Jul 2024 08:25:30 +0100 Subject: [PATCH] [*] Refactor heap stats --- Include/Aurora/Memory/HeapStats.hpp | 4 ++-- Source/Memory/AuHeapProxy.cpp | 4 ++-- Source/Memory/AuHeapProxy.hpp | 8 ++++---- 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/Include/Aurora/Memory/HeapStats.hpp b/Include/Aurora/Memory/HeapStats.hpp index a40ca8f7..52153353 100644 --- a/Include/Aurora/Memory/HeapStats.hpp +++ b/Include/Aurora/Memory/HeapStats.hpp @@ -11,8 +11,8 @@ namespace Aurora::Memory { struct HeapStats { - AuUInt64 qwBytesAllocatedLifetime {}; - AuUInt64 qwBytesFreeLifetime {}; + AuUInt uBytesAllocatedLifetime {}; + AuUInt uBytesFreeLifetime {}; AuUInt uBytesCapacity {}; diff --git a/Source/Memory/AuHeapProxy.cpp b/Source/Memory/AuHeapProxy.cpp index f467f954..ecfb2661 100644 --- a/Source/Memory/AuHeapProxy.cpp +++ b/Source/Memory/AuHeapProxy.cpp @@ -26,9 +26,9 @@ namespace Aurora::Memory auto &stats = this->pHeap->GetStats(); this->stats.uBytesLiveCounter = this->uBytesAllocated; - this->stats.qwBytesAllocatedLifetime = this->uBytesLifetime; + this->stats.uBytesAllocatedLifetime = this->uBytesLifetime; this->stats.uBytesPeakCounter = this->uBytesPeak; - this->stats.qwBytesFreeLifetime = this->uBytesFree; + this->stats.uBytesFreeLifetime = this->uBytesFree; this->stats.uBytesCapacity = stats.uBytesCapacity; } diff --git a/Source/Memory/AuHeapProxy.hpp b/Source/Memory/AuHeapProxy.hpp index d035a130..aa038eef 100644 --- a/Source/Memory/AuHeapProxy.hpp +++ b/Source/Memory/AuHeapProxy.hpp @@ -13,10 +13,10 @@ namespace Aurora::Memory std::shared_ptr pHeap; LeakFinderAlloc_f pAlloc; LeakFinderFree_f pFree; - AuUInt64 uBytesAllocated {}; // current - AuUInt64 uBytesPeak {}; // max - AuUInt64 uBytesFree {}; // free count - AuUInt64 uBytesLifetime {}; // alloc count + AuUInt uBytesAllocated {}; // current + AuUInt uBytesPeak {}; // max + AuUInt uBytesFree {}; // free count + AuUInt uBytesLifetime {}; // alloc count ProxyHeap(std::shared_ptr pHeap, LeakFinderAlloc_f pAlloc = {},