Expand description
§metricus-allocator
Contains allocator.
Structs§
- Counting
Allocator - This allocator will use instrumentation to count the number of allocations and de-allocations
occurring in the program. All calls to allocate (and free) memory are delegated to the concrete
allocator (
std::alloc::Systemby default). Once the allocator has been registered asglobal_allocatoryou need to call enable_allocator_instrumentation from each thread that wants to include its allocation and de-allocation metrics.
Functions§
- enable_
allocator_ instrumentation - This should be called by a thread that wants to opt in to send allocation and de-allocation metrics. By default, per thread instrumentation is disabled. This is usually backend dependent as some backends can support sending metrics from multiple threads whereas others can be limited to the main thread only.