MCPcopy Create free account
hub / github.com/F-Stack/f-stack / hash32_str

Function hash32_str

freebsd/sys/hash.h:60–69  ·  view source on GitHub ↗

* Return a 32-bit hash of the given string. */

Source from the content-addressed store, hash-verified

58 * Return a 32-bit hash of the given string.
59 */
60static __inline uint32_t
61hash32_str(const void *buf, uint32_t hash)
62{
63 const unsigned char *p = buf;
64
65 while (*p)
66 hash = HASHSTEP(hash, *p++);
67
68 return hash;
69}
70
71/*
72 * Return a 32-bit hash of the given string, limited by N.

Callers 10

stats_tpl_update_hashFunction · 0.85
ngs_rehashFunction · 0.85
ngs_newhookFunction · 0.85
ngs_findhookFunction · 0.85
ng_name_nodeFunction · 0.85
ng_name2noderefFunction · 0.85
ng_name_rehashFunction · 0.85
ng_name_nodeFunction · 0.85
ng_name2noderefFunction · 0.85
ng_name_rehashFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected