TachyonUI
0.1.0
High-performance UI for building tools.
Toggle main menu visibility
Loading...
Searching...
No Matches
gui_tracking_allocator.h
Go to the documentation of this file.
1
#pragma once
2
3
#include <
gui_core/memory/gui_allocation_hooks.h
>
4
5
#include <cstddef>
6
7
namespace
tachyon
8
{
11
14
class
TrackingAllocator
15
{
16
public
:
17
TrackingAllocator
();
18
~TrackingAllocator
();
19
TrackingAllocator
(
const
TrackingAllocator
&) =
delete
;
20
TrackingAllocator
&
operator=
(
const
TrackingAllocator
&) =
delete
;
21
23
AllocationHooks
Hooks
();
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
}
tachyon::TrackingAllocator::operator=
TrackingAllocator & operator=(const TrackingAllocator &)=delete
tachyon::TrackingAllocator::ReportLeaks
size_t ReportLeaks() const
Logs a warning per live allocation; returns how many there are.
tachyon::TrackingAllocator::TrackingAllocator
TrackingAllocator()
tachyon::TrackingAllocator::LiveBytes
size_t LiveBytes() const
Their total size in bytes, as requested.
tachyon::TrackingAllocator::~TrackingAllocator
~TrackingAllocator()
tachyon::TrackingAllocator::TrackingAllocator
TrackingAllocator(const TrackingAllocator &)=delete
tachyon::TrackingAllocator::Hooks
AllocationHooks Hooks()
Hooks that allocate through this allocator; valid while it lives.
tachyon::TrackingAllocator::TotalAllocations
size_t TotalAllocations() const
Ever made, including freed ones.
tachyon::TrackingAllocator::LiveAllocations
size_t LiveAllocations() const
Allocations not freed yet.
gui_allocation_hooks.h
tachyon
Definition
gui_logging.h:24
tachyon::AllocationHooks
Memory functions a host gives the library, for the allocations that can be routed: Vulkan objects,...
Definition
gui_allocation_hooks.h:15
gui_core
memory
gui_tracking_allocator.h
Generated by
1.18.0