Function zerovec::hashmap::algorithms::split_hash64

source ·
pub const fn split_hash64(hash: u64, m: usize) -> (usize, u32, u32)
Expand description

Split the 64bit hash into (g, f0, f1).

g denotes the highest 16bits of the hash modulo m, and is referred to as first level hash. (f0, f1) denotes the middle, and lower 24bits of the hash respectively. (f0, f1) are used to distribute the keys with same g, into distinct slots.

§Arguments

  • hash - The hash to split.
  • m - The modulo used to split the hash.