Hasher

Java implementation of Murmur2, Murmur3, XXHash, FNV1 and FNV1A.

Download as .zip Download as .tar.gz View on GitHub

Hasher

This project contains Java implementation for the following fast non-cryptographic hash algorithms

JMH Microbenchmark

Running locally

To run the benchmark on your local machine

git clone https://github.com/prasanthj/hasher.git

cd hasher

mvn clean install

To run all benchmarks

java -jar target/benchmarks.jar

(OR) with custom iterations (wi - warmup iterations, i - iterations, f - fork)

java -jar target/benchmarks.jar -wi 5 -i 10 -f 1

To run a specific benchmark

java -jar target/benchmarks.jar Benchmark32BitHash -wi 5 -i 10 -f 1

Results

NOTE: Its always good to run the benchmarks on your local machine as YMMV.

Latest results can be found here. All results are generated with the following setup.

Benchmark Setup

results

Issues

Bug fixes or improvements are welcome! Please fork the project and send pull request on github. Or report issues here https://github.com/prasanthj/hasher/issues