DynamicUsage overloads
Synopses
Declared in <memusage.h>
Dynamic memory used by a list's nodes.
template<typename X>
static
size_t
DynamicUsage(std::list<X> const& l);
Dynamic memory owned by a shared_ptr, including its control block.
template<typename X>
static
size_t
DynamicUsage(std::shared_ptr<X> const& p);
Dynamic memory owned by a unique_ptr.
template<typename X>
static
size_t
DynamicUsage(std::unique_ptr<X> const& p);
Dynamic memory usage of a raw pointer is zero (the pointee is not owned).
template<typename X>
static
size_t
DynamicUsage(X const*& v);
Dynamic memory usage of a raw pointer‐to‐const is zero (the pointee is not owned).
template<typename X>
static
size_t
DynamicUsage(X const const*& v);
Dynamic memory used by an indirectmap's tree nodes.
template<
typename X,
typename Y>
static
size_t
DynamicUsage(indirectmap<X, Y> const& m);
Dynamic memory used by a set's tree nodes.
template<
typename X,
typename Y>
static
size_t
DynamicUsage(std::set<X, Y> const& s);
Dynamic memory used by an unordered_set's nodes and bucket array.
template<
typename X,
typename Y>
static
size_t
DynamicUsage(std::unordered_set<X, Y> const& s);
Dynamic memory used by a vector's element buffer.
template<
typename T,
typename Allocator>
static
size_t
DynamicUsage(std::vector<T, Allocator> const& v);
Dynamic memory used by a map's tree nodes.
template<
typename X,
typename Y,
typename Z>
static
size_t
DynamicUsage(std::map<X, Y, Z> const& m);
Dynamic memory used by an unordered_map's nodes and bucket array.
template<
typename X,
typename Y,
typename Z>
static
size_t
DynamicUsage(std::unordered_map<X, Y, Z> const& m);
Dynamic memory used by a prevector's overflow buffer.
template<
unsigned int N,
typename X,
typename S,
typename D>
static
size_t
DynamicUsage(prevector<N, X, S, D> const& v);
Dynamic memory used by a pool‐allocated unordered_map, including the pool resource.
template<
class Key,
class T,
class Hash,
class Pred,
std::size_t MAX_BLOCK_SIZE_BYTES,
std::size_t ALIGN_BYTES>
static
size_t
DynamicUsage(std::unordered_map<Key, T, Hash, Pred, PoolAllocator<std::pair<Key const, T>, MAX_BLOCK_SIZE_BYTES, ALIGN_BYTES>> const& m);
Return Value
-
The bytes allocated for all of the list's nodes.
-
The bytes allocated for the pointee and control block, or 0 if empty.
-
The bytes allocated for the pointee, or 0 if empty.
-
Always 0.
-
The bytes allocated for all of the map's nodes.
-
The bytes allocated for all of the set's nodes.
-
The bytes allocated for the nodes plus the bucket array.
-
The bytes allocated for the vector's capacity.
-
The bytes allocated outside the prevector's inline storage.
-
The bytes allocated for the pool chunks plus the bucket array.
Parameters
Name |
Description |
l |
The list to measure. |
p |
The shared_ptr to measure. |
v |
The pointer whose dynamic usage is queried. |
m |
The indirectmap to measure. |
s |
The set to measure. |
Created with MrDocs