7#define ROTL(x, b) (uint64_t)(((x) << (b)) | ((x) >> (64 - (b))))
28 v[0] = 0x736f6d6570736575ULL ^ k0;
29 v[1] = 0x646f72616e646f6dULL ^
k1;
30 v[2] = 0x6c7967656e657261ULL ^ k0;
31 v[3] = 0x7465646279746573ULL ^
k1;
static const uint8_t k1[32]
uint64_t Finalize() const
Compute the 64-bit SipHash-2-4 of the data written so far.
CSipHasher(uint64_t k0, uint64_t k1)
Construct a SipHash calculator initialized with 128-bit key (k0, k1)
CSipHasher & Write(uint64_t data)
Hash a 64-bit integer worth of data.
uint64_t GetUint64(int pos) const
T GetRand(T nMax=std::numeric_limits< T >::max()) noexcept
Generate a uniform random integer of type T in the range [0..nMax) nMax defaults to std::numeric_limi...
uint64_t SipHashUint256Extra(uint64_t k0, uint64_t k1, const uint256 &val, uint32_t extra)
uint64_t SipHashUint256(uint64_t k0, uint64_t k1, const uint256 &val)
Optimized SipHash-2-4 implementation for uint256.