LeviLamina
Loading...
Searching...
No Matches
MemoryTracker.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/deps/core/memory/MemoryCategory.h"
7
8// auto generated forward declare list
9// clang-format off
10namespace Memory { struct MemoryCategoryCounter; }
11// clang-format on
12
13namespace Memory {
14
16public:
17 // virtual functions
18 // NOLINTBEGIN
19 virtual ~MemoryTracker() = default;
20
21 virtual bool isTracking() const;
22
23 virtual ::Memory::MemoryCategory getCurrentCategory() const;
24
25 virtual void setCurrentCategory(::Memory::MemoryCategory category);
26
27 virtual uint64 getCategoryAllocationCount(uint) const;
28
29 virtual uint64 getCategoryAllocatedMemory(uint cat) const;
30
31 virtual uint64 getCategoryTotalAllocationCount(uint) const;
32
33 virtual void publish();
34
35 virtual void populateCounters(
36 ::std::vector<::Memory::MemoryCategoryCounter>& categoryCounters,
37 uint64 minimumThresholdBytes
38 ) const;
39 // NOLINTEND
40
41public:
42 // static functions
43 // NOLINTBEGIN
44#ifdef LL_PLAT_C
45 MCAPI static void disableTracking();
46#endif
47
48 MCAPI static ::Memory::MemoryTracker& get();
49 // NOLINTEND
50
51public:
52 // virtual function thunks
53 // NOLINTBEGIN
54 MCFOLD bool $isTracking() const;
55
56 MCFOLD ::Memory::MemoryCategory $getCurrentCategory() const;
57
58 MCFOLD void $setCurrentCategory(::Memory::MemoryCategory category);
59
60 MCFOLD uint64 $getCategoryAllocationCount(uint) const;
61
62 MCFOLD uint64 $getCategoryAllocatedMemory(uint cat) const;
63
64 MCFOLD uint64 $getCategoryTotalAllocationCount(uint) const;
65
66 MCFOLD void $publish();
67
68 MCFOLD void $populateCounters(
69 ::std::vector<::Memory::MemoryCategoryCounter>& categoryCounters,
70 uint64 minimumThresholdBytes
71 ) const;
72
73
74 // NOLINTEND
75
76public:
77 // vftables
78 // NOLINTBEGIN
79 MCNAPI static void** $vftable();
80 // NOLINTEND
81};
82
83} // namespace Memory
Definition MemoryTracker.h:15
static MCAPI void ** $vftable()
Definition MemoryCategoryCounter.h:10