shbhar commented on PR #16859: URL: https://github.com/apache/lucene/pull/16859#issuecomment-6275209858
The size & complexity of this change is still iffy, so trying to make sure everything has earned its place and see what can be removed or simplified. Starting with XXHash3 64 vs existing Murmur3 128 implementation (take the first long for 64 bit hash) JMH results (5 forks, 10 iterations, 1s each with 5 iterations warmup) on JDK25 ``` Graviton4 (c8g.metal-24xl) ---------------------------------------------------------------------------------------------------------------------------------- Benchmark (function) (keyShape) Mode Cnt Score Error Units PrimaryKeyHashFunctionBenchmark.throughput xxh3 uuid16 thrpt 50 377.272 ± 0.101 ops/us PrimaryKeyHashFunctionBenchmark.throughput murmur3StringHelper uuid16 thrpt 50 99.298 ± 0.176 ops/us PrimaryKeyHashFunctionBenchmark.latency xxh3 uuid16 avgt 50 10.074 ± 0.009 ns/op PrimaryKeyHashFunctionBenchmark.latency murmur3StringHelper uuid16 avgt 50 17.684 ± 0.055 ns/op ---------------------------------------------------------------------------------------------------------------------------------- Intel Xeon 6975P-C (c8i.metal-48xl) Benchmark (function) (keyShape) Mode Cnt Score Error Units PrimaryKeyHashFunctionBenchmark.throughput xxh3 uuid16 thrpt 50 506.192 ± 4.584 ops/us PrimaryKeyHashFunctionBenchmark.throughput murmur3StringHelper uuid16 thrpt 50 144.471 ± 0.229 ops/us PrimaryKeyHashFunctionBenchmark.latency xxh3 uuid16 avgt 50 7.281 ± 0.003 ns/op PrimaryKeyHashFunctionBenchmark.latency murmur3StringHelper uuid16 avgt 50 12.557 ± 0.060 ns/op ``` So UUID16, xxHash is ~1.7x lower avg latency and ~3.5x higher throughput. This roughly matches benchmarks reported by XXHash project itself: https://github.com/Cyan4973/xxHash -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
