Lines Matching defs:key
203 -- that the key be an array of uint32_t's, and
204 -- that the length be the number of uint32_t's in the key
210 hashlittle() has to dance around fitting the key bytes into registers.
214 const uint32_t *k, /* the key, an array of uint32_t values */
215 size_t length, /* the length of the key, in uint32_ts */
223 /*------------------------------------------------- handle most of the key */
260 const uint32_t *k, /* the key, an array of uint32_t values */
261 size_t length, /* the length of the key, in uint32_ts */
271 /*------------------------------------------------- handle most of the key */
300 hashlittle() -- hash a variable-length key into a 32-bit value
301 k : the key (the unaligned variable-length array of bytes)
302 length : the length of the key, counting by bytes
304 Returns a 32-bit value. Every bit of the key affects every bit of
325 uint32_t hashlittle( const void *key, size_t length, uint32_t initval)
333 u.ptr = key;
335 const uint32_t *k = (const uint32_t *)key; /* read 32-bit chunks */
403 const uint16_t *k = (const uint16_t *)key; /* read 16-bit chunks */
449 } else { /* need to read the key one byte at a time */
450 const uint8_t *k = (const uint8_t *)key;
505 * the key. *pc is better mixed than *pb, so use *pc first. If you want
509 const void *key, /* the key to hash */
510 size_t length, /* length of the key */
521 u.ptr = key;
523 const uint32_t *k = (const uint32_t *)key; /* read 32-bit chunks */
591 const uint16_t *k = (const uint16_t *)key; /* read 16-bit chunks */
637 } else { /* need to read the key one byte at a time */
638 const uint8_t *k = (const uint8_t *)key;
694 uint32_t hashbig( const void *key, size_t length, uint32_t initval)
697 union { const void *ptr; size_t i; } u; /* to cast key to (size_t) happily */
702 u.ptr = key;
704 const uint32_t *k = (const uint32_t *)key; /* read 32-bit chunks */
771 } else { /* need to read the key one byte at a time */
772 const uint8_t *k = (const uint8_t *)key;
1025 driver1(); /* test that the key is hashed: used for timings */
1026 driver2(); /* test that whole key is hashed thoroughly */
1027 driver3(); /* test that nothing but the key is hashed */