Lines Matching refs:ptr
211 HashSet(const uint8_t* ptr, bool make_copy_of_data, size_t* read_count) noexcept { in HashSet() argument
214 offset = ReadFromBytes(ptr, offset, &temp); in HashSet()
216 offset = ReadFromBytes(ptr, offset, &temp); in HashSet()
219 offset = ReadFromBytes(ptr, offset, &temp); in HashSet()
221 offset = ReadFromBytes(ptr, offset, &min_load_factor_); in HashSet()
222 offset = ReadFromBytes(ptr, offset, &max_load_factor_); in HashSet()
225 data_ = const_cast<T*>(reinterpret_cast<const T*>(ptr + offset)); in HashSet()
232 offset = ReadFromBytes(ptr, offset, &data_[i]); in HashSet()
241 size_t WriteToMemory(uint8_t* ptr) const { in WriteToMemory() argument
243 offset = WriteToBytes(ptr, offset, static_cast<uint64_t>(num_elements_)); in WriteToMemory()
244 offset = WriteToBytes(ptr, offset, static_cast<uint64_t>(num_buckets_)); in WriteToMemory()
245 offset = WriteToBytes(ptr, offset, static_cast<uint64_t>(elements_until_expand_)); in WriteToMemory()
246 offset = WriteToBytes(ptr, offset, min_load_factor_); in WriteToMemory()
247 offset = WriteToBytes(ptr, offset, max_load_factor_); in WriteToMemory()
251 offset = WriteToBytes(ptr, offset, data_[i]); in WriteToMemory()
648 static size_t WriteToBytes(uint8_t* ptr, size_t offset, Elem n) { in WriteToBytes() argument
649 DCHECK_ALIGNED(ptr + offset, sizeof(n)); in WriteToBytes()
650 if (ptr != nullptr) { in WriteToBytes()
651 *reinterpret_cast<Elem*>(ptr + offset) = n; in WriteToBytes()
657 static size_t ReadFromBytes(const uint8_t* ptr, size_t offset, Elem* out) { in ReadFromBytes() argument
658 DCHECK(ptr != nullptr); in ReadFromBytes()
659 DCHECK_ALIGNED(ptr + offset, sizeof(*out)); in ReadFromBytes()
660 *out = *reinterpret_cast<const Elem*>(ptr + offset); in ReadFromBytes()