xxHash64 hashing functions for Parquet bloom filter support.
More...
|
| namespace | detail |
| | Implementation details – not part of the public API.
|
| |
|
| uint64_t | hash64 (const void *data, size_t length, uint64_t seed=0) |
| | Compute xxHash64 of an arbitrary byte buffer.
|
| |
| uint64_t | hash64 (const std::string &s, uint64_t seed=0) |
| | Convenience overload: hash a std::string.
|
| |
| template<typename T > |
| uint64_t | hash64_value (const T &val, uint64_t seed=0) |
| | Convenience overload: hash a trivially-copyable typed value.
|
| |
xxHash64 hashing functions for Parquet bloom filter support.
◆ hash64() [1/2]
| uint64_t signet::forge::xxhash::hash64 |
( |
const std::string & |
s, |
|
|
uint64_t |
seed = 0 |
|
) |
| |
|
inline |
Convenience overload: hash a std::string.
- Parameters
-
| s | The string to hash. |
| seed | Hash seed (default 0). |
- Returns
- 64-bit hash value.
Definition at line 249 of file xxhash.hpp.
◆ hash64() [2/2]
| uint64_t signet::forge::xxhash::hash64 |
( |
const void * |
data, |
|
|
size_t |
length, |
|
|
uint64_t |
seed = 0 |
|
) |
| |
|
inline |
Compute xxHash64 of an arbitrary byte buffer.
This is the primary entry point. For inputs >= 32 bytes, four parallel accumulators are used (Steps 1-3); for smaller inputs, a single accumulator seeded with PRIME5 is used. All remaining bytes are consumed in 8-byte, 4-byte, and 1-byte chunks before a final avalanche mix.
- Parameters
-
| data | Pointer to input data (may be nullptr if length == 0). |
| length | Number of bytes to hash. |
| seed | Hash seed (default 0). Different seeds produce independent hashes. |
- Returns
- 64-bit hash value.
Definition at line 159 of file xxhash.hpp.
◆ hash64_value()
template<typename T >
| uint64_t signet::forge::xxhash::hash64_value |
( |
const T & |
val, |
|
|
uint64_t |
seed = 0 |
|
) |
| |
|
inline |
Convenience overload: hash a trivially-copyable typed value.
Hashes sizeof(T) bytes of the value's object representation. This is suitable for primitive types (int32_t, int64_t, float, double, etc.).
- Template Parameters
-
| T | A trivially-copyable type (enforced via static_assert). |
- Parameters
-
| val | The value to hash. |
| seed | Hash seed (default 0). |
- Returns
- 64-bit hash value.
Definition at line 263 of file xxhash.hpp.