Track the leaked VM space via the abandoned_vm counter.

The counter is 0 unless metadata allocation failed (indicates OOM), and is
mainly for sanity checking.
This commit is contained in:
Qi Wang
2019-07-15 15:56:05 -07:00
committed by Qi Wang
parent 42807fcd9e
commit 4e36ce34c1
5 changed files with 26 additions and 5 deletions

View File

@@ -112,6 +112,9 @@ struct arena_stats_s {
arena_stats_u64_t nflushes_large; /* Derived. */
arena_stats_u64_t nrequests_large; /* Derived. */
/* VM space had to be leaked (undocumented). Normally 0. */
atomic_zu_t abandoned_vm;
/* Number of bytes cached in tcache associated with this arena. */
atomic_zu_t tcache_bytes; /* Derived. */