kumulant

hash64

fun hash64(bytes: ByteArray): Long(source)

Default 64-bit hash of bytes for cardinality / sketch families. Currently delegates to SplitMixChunkHasher - pin to that hasher directly if you need a stable byte stream across library versions.

Prefer this over value.hashCode().toLong() when feeding HLL, MinHashStat, BloomFilterStat, or CountMinSketchStat - those rely on uniform 64-bit entropy, and JVM hashCode only provides 32 bits.

Not collision-resistant. Use a cryptographic hash for adversarial input.


fun hash64(value: String): Long(source)

UTF-8 byte hash convenience over hash64.

splitmix64

fun splitmix64(value: Long): Long(source)

SplitMix64 - a fast, high-quality 64-bit mixer suitable for spreading sequential or low-entropy keys into a uniform 64-bit hash before feeding them to cardinality sketches. Output passes BigCrush; not collision-resistant (use a cryptographic hash if adversarial input is a concern).

SplitMix64

Default LongHasher: the library's splitmix64 mixer. Pre-registered with Hashers.