Skip to content

switch MurmurHash3 to rapidhash ? #57235

Open
@adienes

Description

@adienes

probably better as an issue than a zulip thread

rapidhash is a non-cryptographic hash I've seen picking up some steam in a lot of other ecosystems.

its predecessor, wyhash, is already the default hashing algorithm in Zig, Nim, and Go. and in comparison rapidhash is both faster and a higher quality hash.

I did a sloppy mockup (pure Julia) and found suggestions that hashing UInt64 can be already 30% faster than current Base.hash and since pretty much all the other hash methods end up calling hash(::UInt64) then performance improvements here could propagate a long way. And due to the higher quality hash, seeing fewer collisions can also be a big performance benefit for many data structures

It's also a keyed hash with secrets easy enough to generate on startup if desired, so it could help address #37166 in practice (although not fully cryptographically)

if this seems like something that could plausibly be merged in a 1.x release I'd be interested in working on this.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions