summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJulian Andres Klode <julian.klode@canonical.com>2020-12-08 11:52:26 +0100
committerJulian Andres Klode <julian.klode@canonical.com>2020-12-10 15:40:08 +0100
commit07808e0d08e8e95e06b754f4c37665015b1045a7 (patch)
tree8e85d4b61f69ecfc59f58ab60d4467dc4c64af39
parentd4bdd5faef84ef90966dd9dc9bbfc6243864747f (diff)
Raise APT::Cache-HashtableSize to 196613
We now have over 100k package names, my Ubuntu system has 125k arleady, so increase the hash table size to match, this will cost us about a MB in cache size, but give a very nice speed up somewhere around 3%-4% or so.
-rw-r--r--apt-pkg/pkgcache.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/apt-pkg/pkgcache.cc b/apt-pkg/pkgcache.cc
index 7eb5ab10b..64c97811a 100644
--- a/apt-pkg/pkgcache.cc
+++ b/apt-pkg/pkgcache.cc
@@ -94,7 +94,7 @@ pkgCache::Header::Header()
VerSysName = 0;
Architecture = 0;
SetArchitectures(0);
- SetHashTableSize(_config->FindI("APT::Cache-HashTableSize", 50503));
+ SetHashTableSize(_config->FindI("APT::Cache-HashTableSize", 196613));
memset(Pools,0,sizeof(Pools));
CacheFileSize = 0;