Hash Functions (primarily for hashmap/sets)
include/math/hash.h View source View on GitHubFunctions
Section titled “Functions”hash_djb2
Section titled “hash_djb2”uint32_t hash_djb2(const void *key, size_t len); hash_sdbm
Section titled “hash_sdbm”uint32_t hash_sdbm(const void *key, size_t len); hash_fnv1a
Section titled “hash_fnv1a”uint32_t hash_fnv1a(const void *key, size_t len); hash_jenkins_one_at_a_time
Section titled “hash_jenkins_one_at_a_time”uint32_t hash_jenkins_one_at_a_time(const void *key, size_t len); hash_murmur3_32
Section titled “hash_murmur3_32”uint32_t hash_murmur3_32(const void *key, size_t len, uint32_t seed); hash_elf
Section titled “hash_elf”uint32_t hash_elf(const void *key, size_t len); hash_bkdr
Section titled “hash_bkdr”uint32_t hash_bkdr(const void *key, size_t len);