27 for (
auto Value : Longs)
30 const uint8_t *Remainder =
reinterpret_cast<const uint8_t *
>(Longs.end());
35 if (RemainderSize >= 2) {
43 if (RemainderSize == 1) {
44 Result ^= *(Remainder++);
47 const uint32_t toLowerMask = 0x20202020;
48 Result |= toLowerMask;
49 Result ^= (Result >> 11);
51 return Result ^ (Result >> 16);
62 reinterpret_cast<const ulittle32_t *>(Buffer.data()),
69 Buffer = Buffer.slice(Items.size() *
sizeof(
ulittle32_t));
70 for (uint8_t Item : Buffer) {
76 return Hash * 1664525U + 1013904223U;
uint32_t hashBufferV8(ArrayRef< uint8_t > Data)
uint32_t hashStringV2(StringRef Str)
This class represents lattice values for constants.
ArrayRef - Represent a constant reference to an array (0 or more elements consecutively in memory)...
LLVM_NODISCARD size_t size() const
size - Get the string size.
uint32_t hashStringV1(StringRef Str)
detail::packed_endian_specific_integral< uint32_t, little, unaligned > ulittle32_t
void update(ArrayRef< uint8_t > Data)
LLVM_NODISCARD const char * data() const
data - Get a pointer to the start of the string (which may not be null terminated).
LLVM Value Representation.
StringRef - Represent a constant reference to a string, i.e.