From 38a5b1ceeeca6ff530a2816a39bcd10d14c85d33 Mon Sep 17 00:00:00 2001 From: Julian Andres Klode Date: Sun, 3 Jan 2016 17:39:39 +0100 Subject: apt-cache: stats: Show a table utilization as percentage Gbp-Dch: ignore --- cmdline/apt-cache.cc | 1 + 1 file changed, 1 insertion(+) (limited to 'cmdline') 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; -- cgit v1.2.3