MCPcopy Create free account
hub / github.com/WolfireGames/overgrowth / GetAndResetMallocAllocationCount

Function GetAndResetMallocAllocationCount

Source/Memory/allocation.cpp:122–129  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

120void operator delete[](void* ptr) { og_free(ptr); }
121
122uint32_t GetAndResetMallocAllocationCount() {
123 uint32_t v;
124 pthread_mutex_lock(&fastmutex);
125 v = allocations_this_frame;
126 allocations_this_frame = 0;
127 pthread_mutex_unlock(&fastmutex);
128 return v;
129}
130
131uint64_t GetCurrentTotalMallocAllocation(int index) {
132 return total_memory_allocations[index];

Callers 2

UpdateMethod · 0.85
DrawImGuiFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected