• Home
  • Raw
  • Download

Lines Matching refs:n_buckets

59     size_t n_buckets;  member
152 return table->n_buckets; in hash_get_n_buckets()
233 size_t n_buckets = hash_get_n_buckets (table); in hash_print_statistics() local
238 fprintf (stream, "# buckets: %lu\n", (unsigned long int) n_buckets); in hash_print_statistics()
241 (100.0 * n_buckets_used) / n_buckets); in hash_print_statistics()
251 size_t n = table->hasher (key, table->n_buckets); in safe_hasher()
252 if (! (n < table->n_buckets)) in safe_hasher()
405 hash_string (const char *string, size_t n_buckets) in hash_string() argument
415 return value % n_buckets; in hash_string()
428 hash_string (const char *string, size_t n_buckets) in hash_string() argument
434 value = (value * 31 + ch) % n_buckets; in hash_string()
622 table->n_buckets = compute_bucket_size (candidate, tuning); in hash_initialize()
623 if (!table->n_buckets) in hash_initialize()
626 table->bucket = calloc (table->n_buckets, sizeof *table->bucket); in hash_initialize()
629 table->bucket_limit = table->bucket + table->n_buckets; in hash_initialize()
951 if (new_size == table->n_buckets) in hash_rehash()
957 new_table->n_buckets = new_size; in hash_rehash()
992 table->n_buckets = new_table->n_buckets; in hash_rehash()
1064 > table->tuning->growth_threshold * table->n_buckets) in hash_insert_if_absent()
1070 > table->tuning->growth_threshold * table->n_buckets) in hash_insert_if_absent()
1075 ? (table->n_buckets * tuning->growth_factor) in hash_insert_if_absent()
1076 : (table->n_buckets * tuning->growth_factor in hash_insert_if_absent()
1166 < table->tuning->shrink_threshold * table->n_buckets) in hash_delete()
1172 < table->tuning->shrink_threshold * table->n_buckets) in hash_delete()
1177 ? table->n_buckets * tuning->shrink_factor in hash_delete()
1178 : (table->n_buckets * tuning->shrink_factor in hash_delete()