1 | //----------------------------------------------------------------------------- |
2 | // MurmurHash2 was written by Austin Appleby, and is placed in the public |
3 | // domain. The author hereby disclaims copyright to this source code. |
4 | |
5 | #pragma once |
6 | |
7 | //----------------------------------------------------------------------------- |
8 | // Platform-specific functions and macros |
9 | |
10 | // Microsoft Visual Studio |
11 | |
12 | #if defined(_MSC_VER) && (_MSC_VER < 1600) |
13 | |
14 | typedef unsigned char uint8_t; |
15 | typedef unsigned int uint32_t; |
16 | typedef unsigned __int64 uint64_t; |
17 | |
18 | // Other compilers |
19 | |
20 | #else // defined(_MSC_VER) |
21 | |
22 | #include <stdint.h> |
23 | |
24 | #endif // !defined(_MSC_VER) |
25 | |
26 | uint32_t MurmurHash2 (const void * key, int len, uint32_t seed); |
27 | uint64_t MurmurHash64A (const void * key, int len, uint64_t seed); |
28 | uint64_t MurmurHash64B (const void * key, int len, uint64_t seed); |
29 | uint32_t MurmurHash2A (const void * key, int len, uint32_t seed); |
30 | uint32_t MurmurHashNeutral2 (const void * key, int len, uint32_t seed); |
31 | uint32_t MurmurHashAligned2 (const void * key, int len, uint32_t seed); |
32 | |