diff options
Diffstat (limited to 'src/memory.cpp')
| -rw-r--r-- | src/memory.cpp | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/memory.cpp b/src/memory.cpp index ee99fc8..87d5eca 100644 --- a/src/memory.cpp +++ b/src/memory.cpp @@ -123,3 +123,16 @@ uint64_t Buckets_NewHandle(std::size_t bucketBytes, uint64_t bucketItemCount, ui return newHandle; } + +void Pke_DebugPrint() { + printf("Memory Manager printout:\nBucket count: %li\n", bucketHead + 1); + for (long i = 0; i < bucketHead + 1; ++i) { + printf("- bucket #%li\n", i); + printf("\tsize: %li\n", buckets[i].size); + printf("\thead: %li\n", buckets[i].head); + printf("\tfree: %li\n", buckets[i].free); + printf("\tallocs: %li\n", buckets[i].allocs); + printf("\ttransient: %i\n", buckets[i].transient); + printf("\tptr: %p\n", buckets[i].ptr); + } +} |
