aboutsummaryrefslogtreecommitdiffstats
path: root/include/jemalloc/internal/ckh.h
diff options
context:
space:
mode:
authorJason Evans <jasone@canonware.com>2013-01-22 12:02:08 -0800
committerJason Evans <jasone@canonware.com>2013-01-22 12:02:08 -0800
commitae03bf6a57f0dd6a009288fa6477a300cabf6d5e (patch)
tree573678d430fdc3acab20236be49b38f788b639e1 /include/jemalloc/internal/ckh.h
parent7329a4f038ed096f3cfa11cb60433f44009fbe16 (diff)
downloadplatform_external_jemalloc_new-ae03bf6a57f0dd6a009288fa6477a300cabf6d5e.tar.gz
platform_external_jemalloc_new-ae03bf6a57f0dd6a009288fa6477a300cabf6d5e.tar.bz2
platform_external_jemalloc_new-ae03bf6a57f0dd6a009288fa6477a300cabf6d5e.zip
Update hash from MurmurHash2 to MurmurHash3.
Update hash from MurmurHash2 to MurmurHash3, primarily because the latter generates 128 bits in a single call for no extra cost, which simplifies integration with cuckoo hashing.
Diffstat (limited to 'include/jemalloc/internal/ckh.h')
-rw-r--r--include/jemalloc/internal/ckh.h8
1 files changed, 3 insertions, 5 deletions
diff --git a/include/jemalloc/internal/ckh.h b/include/jemalloc/internal/ckh.h
index 05d1fc03..50c39ed9 100644
--- a/include/jemalloc/internal/ckh.h
+++ b/include/jemalloc/internal/ckh.h
@@ -5,7 +5,7 @@ typedef struct ckh_s ckh_t;
typedef struct ckhc_s ckhc_t;
/* Typedefs to allow easy function pointer passing. */
-typedef void ckh_hash_t (const void *, unsigned, size_t *, size_t *);
+typedef void ckh_hash_t (const void *, size_t[2]);
typedef bool ckh_keycomp_t (const void *, const void *);
/* Maintain counters used to get an idea of performance. */
@@ -75,11 +75,9 @@ bool ckh_insert(ckh_t *ckh, const void *key, const void *data);
bool ckh_remove(ckh_t *ckh, const void *searchkey, void **key,
void **data);
bool ckh_search(ckh_t *ckh, const void *seachkey, void **key, void **data);
-void ckh_string_hash(const void *key, unsigned minbits, size_t *hash1,
- size_t *hash2);
+void ckh_string_hash(const void *key, size_t r_hash[2]);
bool ckh_string_keycomp(const void *k1, const void *k2);
-void ckh_pointer_hash(const void *key, unsigned minbits, size_t *hash1,
- size_t *hash2);
+void ckh_pointer_hash(const void *key, size_t r_hash[2]);
bool ckh_pointer_keycomp(const void *k1, const void *k2);
#endif /* JEMALLOC_H_EXTERNS */