Crate umash

source
Expand description

UMASH is an almost-universal family of hash functions. Each Params struct defines a specific hash function; when the parameters are generated pseudorandomly, the probability that two different inputs of up to s bytes collide (for an independently generated set of parameters) is at most ceil(s / 4096) 2^-55 for the 64-bit hash. The 128-bit fingerprint reduces that probability to less than 2^-70 for inputs of 1 GB or less.

See the reference repo for more details and proofs.

Structs§

Enums§

  • A given Params struct defines a pair of 64-bit hash functions. The UmashComponent::Hash is the primary hash value; we find a 128-bit fingerprint by combining that primary value with the UmashComponent::Secondary hash (in practice, it’s more efficient to compute both hash values concurrently, when one knows they want a fingerprint).