Increase 8 times number of WaitFreeMap storages.
This commit is contained in:
parent
2a41ab0562
commit
5c5d19e76f
@ -17,9 +17,10 @@ namespace td {
|
||||
template <class KeyT, class ValueT, class HashT = std::hash<KeyT>, class EqT = std::equal_to<KeyT>>
|
||||
class WaitFreeHashMap {
|
||||
using Storage = FlatHashMap<KeyT, ValueT, HashT, EqT>;
|
||||
static constexpr size_t MAX_STORAGE_COUNT = 256;
|
||||
static constexpr size_t MAX_STORAGE_COUNT = 1 << 11;
|
||||
static_assert((MAX_STORAGE_COUNT & (MAX_STORAGE_COUNT - 1)) == 0, "");
|
||||
static constexpr size_t MAX_STORAGE_SIZE = MAX_STORAGE_COUNT * MAX_STORAGE_COUNT / 2;
|
||||
static constexpr size_t MAX_STORAGE_SIZE = 1 << 17;
|
||||
static_assert((MAX_STORAGE_SIZE & (MAX_STORAGE_SIZE - 1)) == 0, "");
|
||||
|
||||
Storage default_map_;
|
||||
struct WaitFreeStorage {
|
||||
|
@ -17,9 +17,10 @@ namespace td {
|
||||
template <class KeyT, class HashT = std::hash<KeyT>, class EqT = std::equal_to<KeyT>>
|
||||
class WaitFreeHashSet {
|
||||
using Storage = FlatHashSet<KeyT, HashT, EqT>;
|
||||
static constexpr size_t MAX_STORAGE_COUNT = 256;
|
||||
static constexpr size_t MAX_STORAGE_COUNT = 1 << 11;
|
||||
static_assert((MAX_STORAGE_COUNT & (MAX_STORAGE_COUNT - 1)) == 0, "");
|
||||
static constexpr size_t MAX_STORAGE_SIZE = MAX_STORAGE_COUNT * MAX_STORAGE_COUNT / 2;
|
||||
static constexpr size_t MAX_STORAGE_SIZE = 1 << 17;
|
||||
static_assert((MAX_STORAGE_SIZE & (MAX_STORAGE_SIZE - 1)) == 0, "");
|
||||
|
||||
Storage default_set_;
|
||||
struct WaitFreeStorage {
|
||||
|
Loading…
Reference in New Issue
Block a user