Lines Matching refs:bucketCount
36 size_t bucketCount; member
55 map->bucketCount = 1; in hashmapCreate()
56 while (map->bucketCount <= minimumBucketCount) { in hashmapCreate()
58 map->bucketCount <<= 1; in hashmapCreate()
61 map->buckets = static_cast<Entry**>(calloc(map->bucketCount, sizeof(Entry*))); in hashmapCreate()
96 static inline size_t calculateIndex(size_t bucketCount, int hash) { in calculateIndex() argument
97 return ((size_t) hash) & (bucketCount - 1); in calculateIndex()
102 if (map->size > (map->bucketCount * 3 / 4)) { in expandIfNecessary()
104 size_t newBucketCount = map->bucketCount << 1; in expandIfNecessary()
113 for (i = 0; i < map->bucketCount; i++) { in expandIfNecessary()
127 map->bucketCount = newBucketCount; in expandIfNecessary()
141 for (i = 0; i < map->bucketCount; i++) { in hashmapFree()
194 size_t index = calculateIndex(map->bucketCount, hash); in hashmapPut()
226 size_t index = calculateIndex(map->bucketCount, hash); in hashmapGet()
241 size_t index = calculateIndex(map->bucketCount, hash); in hashmapRemove()
264 for (i = 0; i < map->bucketCount; i++) { in hashmapForEach()