diff --git a/src/StorageCache.h b/src/StorageCache.h index a430572af..429795eb8 100644 --- a/src/StorageCache.h +++ b/src/StorageCache.h @@ -32,7 +32,7 @@ public: StorageCache *cache = new StorageCache(nullptr); if (pfactory->FSlow()) { - cache->m_setkeys = std::make_unique>(); + cache->m_setkeys = std::make_unique>(20); } load_iter_data data = {cache, fn, privdata}; cache->m_spstorage = std::shared_ptr(pfactory->create(db, key_load_itr, (void*)&data)); diff --git a/src/semiorderedset.h b/src/semiorderedset.h index 1b79e725b..c0281c35c 100644 --- a/src/semiorderedset.h +++ b/src/semiorderedset.h @@ -49,8 +49,11 @@ class semiorderedset } public: - semiorderedset() + semiorderedset(size_t bitsStart = 0) { + if (bitsStart < bits_min) + bitsStart = bits_min; + bits = bitsStart; m_data.resize((1ULL << bits)); }