Lines Matching refs:_Size
31 template <class _Size>
33 _Size
36 _Size __r; in __loadword()
44 template <class _Size, size_t = sizeof(_Size)*__CHAR_BIT__>
47 template <class _Size>
48 struct __murmur2_or_cityhash<_Size, 32>
50 inline _Size operator()(const void* __key, _Size __len)
55 template <class _Size>
56 _Size
57 __murmur2_or_cityhash<_Size, 32>::operator()(const void* __key, _Size __len)
59 const _Size __m = 0x5bd1e995;
60 const _Size __r = 24;
61 _Size __h = __len;
65 _Size __k = __loadword<_Size>(__data);
75 __h ^= static_cast<_Size>(__data[2] << 16);
78 __h ^= static_cast<_Size>(__data[1] << 8);
90 template <class _Size>
91 struct __murmur2_or_cityhash<_Size, 64>
93 …inline _Size operator()(const void* __key, _Size __len) _LIBCPP_DISABLE_UBSAN_UNSIGNED_INTEGER_CH…
97 static const _Size __k0 = 0xc3a5c85c97cb3127ULL;
98 static const _Size __k1 = 0xb492b66fbe98f273ULL;
99 static const _Size __k2 = 0x9ae16a3b2f90404fULL;
100 static const _Size __k3 = 0xc949d7c7509e6557ULL;
102 static _Size __rotate(_Size __val, int __shift) {
106 static _Size __rotate_by_at_least_1(_Size __val, int __shift) {
110 static _Size __shift_mix(_Size __val) {
114 static _Size __hash_len_16(_Size __u, _Size __v)
117 const _Size __mul = 0x9ddfea08eb382d69ULL;
118 _Size __a = (__u ^ __v) * __mul;
120 _Size __b = (__v ^ __a) * __mul;
126 static _Size __hash_len_0_to_16(const char* __s, _Size __len)
130 const _Size __a = __loadword<_Size>(__s);
131 const _Size __b = __loadword<_Size>(__s + __len - 8);
151 static _Size __hash_len_17_to_32(const char *__s, _Size __len)
154 const _Size __a = __loadword<_Size>(__s) * __k1;
155 const _Size __b = __loadword<_Size>(__s + 8);
156 const _Size __c = __loadword<_Size>(__s + __len - 8) * __k2;
157 const _Size __d = __loadword<_Size>(__s + __len - 16) * __k0;
164 static pair<_Size, _Size> __weak_hash_len_32_with_seeds(
165 _Size __w, _Size __x, _Size __y, _Size __z, _Size __a, _Size __b)
170 const _Size __c = __a;
174 return pair<_Size, _Size>(__a + __z, __b + __c);
178 static pair<_Size, _Size> __weak_hash_len_32_with_seeds(
179 const char* __s, _Size __a, _Size __b)
182 return __weak_hash_len_32_with_seeds(__loadword<_Size>(__s),
183 __loadword<_Size>(__s + 8),
184 __loadword<_Size>(__s + 16),
185 __loadword<_Size>(__s + 24),
191 static _Size __hash_len_33_to_64(const char *__s, size_t __len)
194 _Size __z = __loadword<_Size>(__s + 24);
195 _Size __a = __loadword<_Size>(__s) +
196 (__len + __loadword<_Size>(__s + __len - 16)) * __k0;
197 _Size __b = __rotate(__a + __z, 52);
198 _Size __c = __rotate(__a, 37);
199 __a += __loadword<_Size>(__s + 8);
201 __a += __loadword<_Size>(__s + 16);
202 _Size __vf = __a + __z;
203 _Size __vs = __b + __rotate(__a, 31) + __c;
204 __a = __loadword<_Size>(__s + 16) + __loadword<_Size>(__s + __len - 32);
205 __z += __loadword<_Size>(__s + __len - 8);
208 __a += __loadword<_Size>(__s + __len - 24);
210 __a += __loadword<_Size>(__s + __len - 16);
211 _Size __wf = __a + __z;
212 _Size __ws = __b + __rotate(__a, 31) + __c;
213 _Size __r = __shift_mix((__vf + __ws) * __k2 + (__wf + __vs) * __k0);
219 template <class _Size>
220 _Size
221 __murmur2_or_cityhash<_Size, 64>::operator()(const void* __key, _Size __len)
236 _Size __x = __loadword<_Size>(__s + __len - 40);
237 _Size __y = __loadword<_Size>(__s + __len - 16) +
238 __loadword<_Size>(__s + __len - 56);
239 _Size __z = __hash_len_16(__loadword<_Size>(__s + __len - 48) + __len,
240 __loadword<_Size>(__s + __len - 24));
241 pair<_Size, _Size> __v = __weak_hash_len_32_with_seeds(__s + __len - 64, __len, __z);
242 pair<_Size, _Size> __w = __weak_hash_len_32_with_seeds(__s + __len - 32, __y + __k1, __x);
243 __x = __x * __k1 + __loadword<_Size>(__s);
246 __len = (__len - 1) & ~static_cast<_Size>(63);
248 __x = __rotate(__x + __y + __v.first + __loadword<_Size>(__s + 8), 37) * __k1;
249 __y = __rotate(__y + __v.second + __loadword<_Size>(__s + 48), 42) * __k1;
251 __y += __v.first + __loadword<_Size>(__s + 40);
255 __y + __loadword<_Size>(__s + 16));