summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorTyge Løvset <[email protected]>2023-04-24 09:42:50 +0200
committerTyge Løvset <[email protected]>2023-04-24 09:42:50 +0200
commit3dcd44ce50df89e698bc9d85cc36518f033b8462 (patch)
tree48db5500fae287950856e3eb7932df79b86f2b3d
parent38aab1d6ae8f929084ae6c67256a87760cc07705 (diff)
downloadSTC-modified-3dcd44ce50df89e698bc9d85cc36518f033b8462.tar.gz
STC-modified-3dcd44ce50df89e698bc9d85cc36518f033b8462.zip
Final hash constants tunings.
-rw-r--r--include/stc/ccommon.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/include/stc/ccommon.h b/include/stc/ccommon.h
index 121bc566..c1f73e20 100644
--- a/include/stc/ccommon.h
+++ b/include/stc/ccommon.h
@@ -151,9 +151,9 @@ STC_INLINE uint64_t cfasthash(const void* key, intptr_t len) {
len &= 7;
while (n--) {
memcpy(&u8, x, 8), x += 8;
- h = (h ^ u8)*0x9e3779b97f4a7c15;
+ h = (h ^ u8)*0xc6a4a7935bd1e99d;
}
- while (len--) h = (h ^ *x++)*0xbf58476d1ce4e5b9;
+ while (len--) h = (h ^ *x++)*0x100000001b3;
return h;
}