28 template <
class T,
class A>
179 accumulator += increment.
size;
void print_memory_usage(const MemoryUsage &usage)
MemoryUsage local_memory_usage()
Gather memory usage of this process.
std::string format_memory_usage(const VectorMemoryUsage &memory_usage)
Aligned, human readable representation of memory_usage.
std::string format_memory(size_t bytes)
Utility to format memory as a human readable string.
cache::ModelMemoryUsage memory_usage(const std::optional< neuron::cache::Model > &model)
Model & model()
Access the global Model instance.
Overall SoA datastructures related memory usage.
VectorMemoryUsage compute_total() const
const MemoryUsage & operator+=(const MemoryUsage &other)
cache::ModelMemoryUsage cache_model
VectorMemoryUsage stable_pointers
void add(const ModelMemoryUsage &model)
size_t convenient
Any memory that's (currently) required to run NEURON.
void add(size_t &accumulator, const VectorMemoryUsage &increment)
size_t leaked
Essentially leaked memory.
size_t oversized
Wasted memory due to the difference of size and capacity.
void add(const cache::ModelMemoryUsage &model)
size_t required
Data that are part of the algorithm.
void add(const StorageMemoryUsage &increment)
MemoryUsageSummary(const MemoryUsage &memory_usage)
Memory usage of a neuron::Model.
const ModelMemoryUsage & operator+=(const ModelMemoryUsage &other)
StorageMemoryUsage nodes
The memory usage of the nodes related data.
VectorMemoryUsage compute_total() const
StorageMemoryUsage mechanisms
The memory usage of all mechanisms.
Memory usage of a storage/soa container.
VectorMemoryUsage stable_identifiers
The memory usage for the stable identifiers in a soa.
VectorMemoryUsage compute_total() const
const StorageMemoryUsage & operator+=(const StorageMemoryUsage &other)
VectorMemoryUsage heavy_data
The memory usage of the heavy data in a soa.
Size and capacity in bytes.
VectorMemoryUsage(const std::vector< T, A > &vec)
Compute the memory requirements of the std::vector.
size_t size
Number of bytes used.
size_t capacity
Number of bytes allocated.
VectorMemoryUsage()=default
const VectorMemoryUsage & operator+=(const VectorMemoryUsage &other)
VectorMemoryUsage(size_t size, size_t capacity)
Memory usage of a neuron::cache::Model.
const ModelMemoryUsage & operator+=(const ModelMemoryUsage &other)
VectorMemoryUsage threads
Memory usage required for NRN threads.
VectorMemoryUsage compute_total() const
VectorMemoryUsage mechanisms
Memory usage related to caching mechanisms.