TachyonUI 0.1.0
High-performance UI for building tools.
Loading...
Searching...
No Matches
gui_tracking_allocator.h
Go to the documentation of this file.
1#pragma once
2
4
5#include <cstddef>
6
7namespace tachyon
8{
11
15 {
16 public:
21
24
25 size_t LiveAllocations() const;
26 size_t LiveBytes() const;
27 size_t TotalAllocations() const;
28
30 size_t ReportLeaks() const;
31
32 private:
33 struct State;
34 State* m_state;
35 };
36
37}
TrackingAllocator & operator=(const TrackingAllocator &)=delete
size_t ReportLeaks() const
Logs a warning per live allocation; returns how many there are.
size_t LiveBytes() const
Their total size in bytes, as requested.
TrackingAllocator(const TrackingAllocator &)=delete
AllocationHooks Hooks()
Hooks that allocate through this allocator; valid while it lives.
size_t TotalAllocations() const
Ever made, including freed ones.
size_t LiveAllocations() const
Allocations not freed yet.
Definition gui_logging.h:24
Memory functions a host gives the library, for the allocations that can be routed: Vulkan objects,...
Definition gui_allocation_hooks.h:15