diff options
author | Julian Andres Klode <jak@debian.org> | 2016-01-03 17:39:39 +0100 |
---|---|---|
committer | Julian Andres Klode <jak@debian.org> | 2016-01-03 17:42:17 +0100 |
commit | 38a5b1ceeeca6ff530a2816a39bcd10d14c85d33 (patch) | |
tree | ce479b562cb96f11d1f8d1cd3cc9deaec05ee702 /cmdline | |
parent | 6d7fc45ed4e22163bba6478c7523f4509d200c58 (diff) |
apt-cache: stats: Show a table utilization as percentage
Gbp-Dch: ignore
Diffstat (limited to 'cmdline')
-rw-r--r-- | cmdline/apt-cache.cc | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/cmdline/apt-cache.cc b/cmdline/apt-cache.cc index 7139bdeac..481833084 100644 --- a/cmdline/apt-cache.cc +++ b/cmdline/apt-cache.cc @@ -172,6 +172,7 @@ static void ShowHashTableStats(std::string Type, cout << "Total buckets in " << Type << ": " << NumBuckets << std::endl; cout << " Unused: " << UnusedBuckets << std::endl; cout << " Used: " << UsedBuckets << std::endl; + cout << " Utilization: " << 100.0 * UsedBuckets/NumBuckets << "%" << std::endl; cout << " Average entries: " << Entries/(double)UsedBuckets << std::endl; cout << " Longest: " << LongestBucket << std::endl; cout << " Shortest: " << ShortestBucket << std::endl; |