You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by "Stefan Miklosovic (Jira)" <ji...@apache.org> on 2021/04/16 20:19:00 UTC
[jira] [Created] (CASSANDRA-16610) Implement XXHashPartitioner
Stefan Miklosovic created CASSANDRA-16610:
---------------------------------------------
Summary: Implement XXHashPartitioner
Key: CASSANDRA-16610
URL: https://issues.apache.org/jira/browse/CASSANDRA-16610
Project: Cassandra
Issue Type: New Feature
Components: Legacy/Core
Reporter: Stefan Miklosovic
I implemented partitioner based on XXHash algorithm.
There are two branches, the first xxhash, extracts common parts with Murmur as there is a lot of overlap between these two.
The second branch just copies everything from Murmur and changes just bits which are necessary.
I have written a microbenchmark measuring both partitioners and XXHash implementation is very fast, around 10x faster. Benchmark is included in xxhash-2 branch.
{code:java}
[java] Benchmark (bufferSize) Mode Cnt Score Error Units
[java] PartitionersBench.benchMurmur3Partitioner 31 avgt 20 157.942 ± 0.110 ns/op
[java] PartitionersBench.benchMurmur3Partitioner 67 avgt 20 204.670 ± 0.152 ns/op
[java] PartitionersBench.benchMurmur3Partitioner 131 avgt 20 361.068 ± 0.228 ns/op
[java] PartitionersBench.benchMurmur3Partitioner 517 avgt 20 1325.670 ± 1.255 ns/op
[java] PartitionersBench.benchMurmur3Partitioner 1031 avgt 20 2594.651 ± 2.725 ns/op
[java] PartitionersBench.benchMurmur3Partitioner 2041 avgt 20 5082.166 ± 1.721 ns/op
[java] PartitionersBench.benchMurmur3Partitioner 4097 avgt 20 10112.020 ± 3.637 ns/op
[java] PartitionersBench.benchXXHashPartitioner 31 avgt 20 40.650 ± 0.025 ns/op
[java] PartitionersBench.benchXXHashPartitioner 67 avgt 20 53.305 ± 0.035 ns/op
[java] PartitionersBench.benchXXHashPartitioner 131 avgt 20 67.098 ± 0.057 ns/op
[java] PartitionersBench.benchXXHashPartitioner 517 avgt 20 150.415 ± 0.107 ns/op
[java] PartitionersBench.benchXXHashPartitioner 1031 avgt 20 265.614 ± 0.140 ns/op
[java] PartitionersBench.benchXXHashPartitioner 2041 avgt 20 365.796 ± 0.225 ns/op
[java] PartitionersBench.benchXXHashPartitioner 4097 avgt 20 925.841 ± 0.664 ns/op
{code}
https://github.com/OpenHFT/Zero-Allocation-Hashing
https://cyan4973.github.io/xxHash/
--
This message was sent by Atlassian Jira
(v8.3.4#803005)
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@cassandra.apache.org
For additional commands, e-mail: commits-help@cassandra.apache.org