diff options
author | Juan Linietsky <reduzio@gmail.com> | 2017-08-01 16:52:56 -0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-08-01 16:52:56 -0300 |
commit | 083705c45dc8613858bf39a2e6a467b81990284e (patch) | |
tree | 0b6e73ddb6947bb6cf31f35d3bff8dfc6af983bc /main/performance.cpp | |
parent | daad16b7c7a10f0f1ede92899573e9e354c9d2cd (diff) | |
parent | 02607b3103d216dd49ad6fc9ded51773ddb47afd (diff) |
Merge pull request #9828 from RandomShaper/improve-mem-stats
Improve reliability of memory stats
Diffstat (limited to 'main/performance.cpp')
-rw-r--r-- | main/performance.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/main/performance.cpp b/main/performance.cpp index c819e15f71..3d8e21bf33 100644 --- a/main/performance.cpp +++ b/main/performance.cpp @@ -117,8 +117,8 @@ float Performance::get_monitor(Monitor p_monitor) const { case TIME_FIXED_PROCESS: return _fixed_process_time; case MEMORY_STATIC: return Memory::get_mem_usage(); case MEMORY_DYNAMIC: return MemoryPool::total_memory; - case MEMORY_STATIC_MAX: return MemoryPool::max_memory; - case MEMORY_DYNAMIC_MAX: return 0; + case MEMORY_STATIC_MAX: return Memory::get_mem_max_usage(); + case MEMORY_DYNAMIC_MAX: return MemoryPool::max_memory; case MEMORY_MESSAGE_BUFFER_MAX: return MessageQueue::get_singleton()->get_max_buffer_usage(); case OBJECT_COUNT: return ObjectDB::get_object_count(); case OBJECT_RESOURCE_COUNT: return ResourceCache::get_cached_resource_count(); |