| 1 | #pragma once |
| 2 | |
| 3 | #include <Common/Allocator.h> |
| 4 | |
| 5 | |
| 6 | /** |
| 7 | * We are going to use the entire memory we allocated when resizing a hash |
| 8 | * table, so it makes sense to pre-fault the pages so that page faults don't |
| 9 | * interrupt the resize loop. Set the allocator parameter accordingly. |
| 10 | */ |
| 11 | using HashTableAllocator = Allocator<true /* clear_memory */, true /* mmap_populate */>; |
| 12 | |
| 13 | template <size_t N = 64> |
| 14 | using HashTableAllocatorWithStackMemory = AllocatorWithStackMemory<HashTableAllocator, N>; |
| 15 | |