summaryrefslogtreecommitdiff
path: root/hash.h
Commit message (Collapse)AuthorAgeFilesLines
* hash: add XXH3 to list of hash algorithms.dormando2021-06-091-1/+1
| | | | | | | | | | | | needs more testing. in a "pure miss" test to help show hashing overhead, with four worker threads and large ascii multigets there is a measurable performance boost for longer keys. Very short keys (10-15 bytes) are about even. for 150ish byte keys 12m rps -> 13m rps roughly. Not too bad! need to test hash table distribution for large sets of keys before merging. need to consider if worth switching the defaults now or later.
* hash: fix build failure against gcc-10Sergei Trofimovich2020-02-011-1/+1
| | | | | | | | | | | | | | | | | | | | On gcc-10 (and gcc-9 -fno-common) build fails as: ``` gcc -g -O2 -pthread -pthread -Wall -Werror -pedantic -Wmissing-prototypes \ -Wmissing-declarations -Wredundant-decls -o memcached ... -levent ld: memcached-hash.o:memcached/hash.h:5: multiple definition of `hash'; memcached-memcached.o:memcached/hash.h:5: first defined here ``` gcc-10 will change the default from -fcommon to fno-common: https://gcc.gnu.org/PR85678. The error also happens if CFLAGS=-fno-common passed explicitly. Reported-by: Brian Evans Bug: https://bugs.gentoo.org/706196 Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org>
* Make hash table algorithm selectabledormando2014-04-161-7/+6
| | | | | jenkins hash is old. Lets try murmur3 to start! Default is the old one, so people aren't surprised.
* Refactor: moved the hash function from assoc.c to hash.cTrond Norbye2009-03-021-0/+15