5 ms·
I just did a comparison between almost every hashing algorithm I could find on crates.io. On my machine t1ha2 (under the t1ha crate) beat the pants off of every
by indiv0 4y ago
I just did a comparison between almost every hashing algorithm I could find on crates.io. On my machine t1ha2 (under the t1ha crate) beat the pants off of every other algorithm. By like an order of magnitude. Others in the lead were blake3 (from the blake3 crate) and metrohash. Worth taking a look at those if you’re going for hash speed.
I don’t have the exact numbers on me right now but I can share them tomorrow (along with the benchmark code) if you’re interested.
- insanitybit 4y agoThe PR I have lets you provide the algorithm as the caller, although I did benchmark against fxhash and I think it would be a good idea to suggest `ahash`. I'm certainly interested. `ahash` has some good benchmarks here: https://github.com/tkaitchuck/aHash/blob/master/FAQ.md https://github.com/tkaitchuck/aHash/blob/master/FAQ.md
- ComputerGuru 4y agoFYI Small hashes beat better quality hashes for hash table purposes.
- virtualritz 4y agoaHash claims it is faster than t1ha[1]. The t1ha crate also hasn't been updated in over three years so the benchmark in this link should be current. [1] https://github.com/tkaitchuck/aHash/blob/master/compare/readme.md#t1ha-and-xxhash https://github.com/tkaitchuck/aHash/blob/master/compare/read... Edit: if you really think tha1 is faster I would open an issue on the aHash repo to update their benchmark.