Lines Matching refs:hash

1401 /* The minimum utilization of the array part of a mixed hash/array table.  This
1503 static upb_tabent *getentry_mutable(upb_table *t, uint32_t hash) {
1504 return (upb_tabent*)upb_getentry(t, hash);
1508 uint32_t hash, eqlfunc_t *eql) {
1512 e = upb_getentry(t, hash);
1521 uint32_t hash, eqlfunc_t *eql) {
1522 return (upb_tabent*)findentry(t, key, hash, eql);
1526 uint32_t hash, eqlfunc_t *eql) {
1527 const upb_tabent *e = findentry(t, key, hash, eql);
1540 upb_value val, uint32_t hash,
1545 UPB_ASSERT(findentry(t, key, hash, eql) == NULL);
1548 mainpos_e = getentry_mutable(t, hash);
1560 /* Existing ent is in its main posisiton (it has the same hash as us, and
1567 * chain). This implies that no existing ent in the table has our hash.
1581 UPB_ASSERT(findentry(t, key, hash, eql) == our_e);
1585 upb_tabkey *removed, uint32_t hash, eqlfunc_t *eql) {
1586 upb_tabent *chain = getentry_mutable(t, hash);
1639 /* A simple "subclass" of upb_table that only adds a hash function for strings. */
1703 uint32_t hash;
1716 hash = upb_murmur_hash2(key.str.str, key.str.len, 0);
1717 insert(&t->t, key, tabkey, v, hash, &strhash, &streql);
1723 uint32_t hash = upb_murmur_hash2(key, len, 0);
1724 return lookup(&t->t, strkey2(key, len), v, hash, &streql);
1729 uint32_t hash = upb_murmur_hash2(key, len, 0);
1731 if (rm(&t->t, strkey2(key, len), val, &tabkey, hash, &streql)) {
1789 * array and large keys are put in the hash table. */
1842 * won't be in the hash part, which simplifies things. */
1878 /* Need to resize the hash part, but we re-use the array part. */
1888 uint32_t hash;
1892 hash = upb_inthash(e->key);
1893 insert(&new_table, intkey(e->key), e->key, v, hash, &inthash, &inteql);
2100 /* Initialize the hash to a 'random' value */
2103 /* Mix 4 bytes at a time into the hash */
2127 /* Do a few final mixes of the hash to ensure the last few