Module hash

Module hash 

Source
Expand description

xxHash3 hashing utilities.

These functions provide fast, deterministic, non-cryptographic hashes that work reliably on the Internet Computer.

They are used across canic for tasks that require uniform and reproducible hashing such as:

  • routing / sharding decisions,
  • cache keys or internal identifiers,
  • stable yet non-secure fingerprinting of data.

✅ Extremely fast (optimized for 64-bit architectures) ✅ Deterministic across replicas and platforms ⚠️ Not cryptographically secure — do not use for signatures or certified data

Reference: https://cyan4973.github.io/xxHash/

Structs§

Xxh3
XXH3 Streaming algorithm

Functions§

hash_u64
Return a u64 hash from the provided bytes using the xxh3 hash algorithm.
hash_u128
Return a u128 hash from the provided bytes using the xxh3 hash algorithm.