LLVM 20.0.0git
GSIStreamBuilder.cpp
Go to the documentation of this file.
1//===- DbiStreamBuilder.cpp - PDB Dbi Stream Creation -----------*- C++ -*-===//
2//
3// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4// See https://llvm.org/LICENSE.txt for license information.
5// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6//
7//===----------------------------------------------------------------------===//
8//
9// The data structures defined in this file are based on the reference
10// implementation which is available at
11// https://github.com/Microsoft/microsoft-pdb/blob/master/PDB/dbi/gsi.cpp
12//
13//===----------------------------------------------------------------------===//
14
30#include "llvm/Support/xxhash.h"
31#include <algorithm>
32#include <vector>
33
34using namespace llvm;
35using namespace llvm::msf;
36using namespace llvm::pdb;
37using namespace llvm::codeview;
38
39// Helper class for building the public and global PDB hash table buckets.
41 // Sum of the size of all public or global records.
43
44 std::vector<PSHashRecord> HashRecords;
45
46 // The hash bitmap has `ceil((IPHR_HASH + 1) / 32)` words in it. The
47 // reference implementation builds a hash table with IPHR_HASH buckets in it.
48 // The last bucket is used to link together free hash table cells in a linked
49 // list, but it is always empty in the compressed, on-disk format. However,
50 // the bitmap must have a bit for it.
51 std::array<support::ulittle32_t, (IPHR_HASH + 32) / 32> HashBitmap;
52
53 std::vector<support::ulittle32_t> HashBuckets;
54
57
59 void finalizeGlobalBuckets(uint32_t RecordZeroOffset);
60
61 // Assign public and global symbol records into hash table buckets.
62 // Modifies the list of records to store the bucket index, but does not
63 // change the order.
64 void finalizeBuckets(uint32_t RecordZeroOffset,
66};
67
68// DenseMapInfo implementation for deduplicating symbol records.
70 static inline CVSymbol getEmptyKey() {
71 static CVSymbol Empty;
72 return Empty;
73 }
74 static inline CVSymbol getTombstoneKey() {
75 static CVSymbol Tombstone(
77 return Tombstone;
78 }
79 static unsigned getHashValue(const CVSymbol &Val) {
80 return xxh3_64bits(Val.RecordData);
81 }
82 static bool isEqual(const CVSymbol &LHS, const CVSymbol &RHS) {
83 return LHS.RecordData == RHS.RecordData;
84 }
85};
86
87namespace {
89struct PublicSym32Layout {
90 RecordPrefix Prefix;
92 // char Name[];
93};
95} // namespace
96
97// Calculate how much memory this public needs when serialized.
98static uint32_t sizeOfPublic(const BulkPublic &Pub) {
99 uint32_t NameLen = Pub.NameLen;
100 NameLen = std::min(NameLen,
101 uint32_t(MaxRecordLength - sizeof(PublicSym32Layout) - 1));
102 return alignTo(sizeof(PublicSym32Layout) + NameLen + 1, 4);
103}
104
105static CVSymbol serializePublic(uint8_t *Mem, const BulkPublic &Pub) {
106 // Assume the caller has allocated sizeOfPublic bytes.
107 uint32_t NameLen = std::min(
108 Pub.NameLen, uint32_t(MaxRecordLength - sizeof(PublicSym32Layout) - 1));
109 size_t Size = alignTo(sizeof(PublicSym32Layout) + NameLen + 1, 4);
110 assert(Size == sizeOfPublic(Pub));
111 auto *FixedMem = reinterpret_cast<PublicSym32Layout *>(Mem);
112 FixedMem->Prefix.RecordKind = static_cast<uint16_t>(codeview::S_PUB32);
113 FixedMem->Prefix.RecordLen = static_cast<uint16_t>(Size - 2);
114 FixedMem->Pub.Flags = Pub.Flags;
115 FixedMem->Pub.Offset = Pub.Offset;
116 FixedMem->Pub.Segment = Pub.Segment;
117 char *NameMem = reinterpret_cast<char *>(FixedMem + 1);
118 memcpy(NameMem, Pub.Name, NameLen);
119 // Zero the null terminator and remaining bytes.
120 memset(&NameMem[NameLen], 0, Size - sizeof(PublicSym32Layout) - NameLen);
121 return CVSymbol(ArrayRef(reinterpret_cast<uint8_t *>(Mem), Size));
122}
123
125 uint32_t Size = sizeof(GSIHashHeader);
126 Size += HashRecords.size() * sizeof(PSHashRecord);
127 Size += HashBitmap.size() * sizeof(uint32_t);
128 Size += HashBuckets.size() * sizeof(uint32_t);
129 return Size;
130}
131
133 GSIHashHeader Header;
134 Header.VerSignature = GSIHashHeader::HdrSignature;
135 Header.VerHdr = GSIHashHeader::HdrVersion;
136 Header.HrSize = HashRecords.size() * sizeof(PSHashRecord);
137 Header.NumBuckets = HashBitmap.size() * 4 + HashBuckets.size() * 4;
138
139 if (auto EC = Writer.writeObject(Header))
140 return EC;
141
142 if (auto EC = Writer.writeArray(ArrayRef(HashRecords)))
143 return EC;
144 if (auto EC = Writer.writeArray(ArrayRef(HashBitmap)))
145 return EC;
146 if (auto EC = Writer.writeArray(ArrayRef(HashBuckets)))
147 return EC;
148 return Error::success();
149}
150
151static bool isAsciiString(StringRef S) {
152 return llvm::all_of(S, [](char C) { return unsigned(C) < 0x80; });
153}
154
155// See `caseInsensitiveComparePchPchCchCch` in gsi.cpp
157 size_t LS = S1.size();
158 size_t RS = S2.size();
159 // Shorter strings always compare less than longer strings.
160 if (LS != RS)
161 return (LS > RS) - (LS < RS);
162
163 // If either string contains non ascii characters, memcmp them.
165 return memcmp(S1.data(), S2.data(), LS);
166
167 // Both strings are ascii, perform a case-insensitive comparison.
168 return S1.compare_insensitive(S2.data());
169}
170
171void GSIStreamBuilder::finalizePublicBuckets() {
172 PSH->finalizeBuckets(0, Publics);
173}
174
175void GSIStreamBuilder::finalizeGlobalBuckets(uint32_t RecordZeroOffset) {
176 // Build up a list of globals to be bucketed. Use the BulkPublic data
177 // structure for this purpose, even though these are global records, not
178 // public records. Most of the same fields are required:
179 // - Name
180 // - NameLen
181 // - SymOffset
182 // - BucketIdx
183 // The dead fields are Offset, Segment, and Flags.
184 std::vector<BulkPublic> Records;
185 Records.resize(Globals.size());
186 uint32_t SymOffset = RecordZeroOffset;
187 for (size_t I = 0, E = Globals.size(); I < E; ++I) {
188 StringRef Name = getSymbolName(Globals[I]);
189 Records[I].Name = Name.data();
190 Records[I].NameLen = Name.size();
191 Records[I].SymOffset = SymOffset;
192 SymOffset += Globals[I].length();
193 }
194
195 GSH->finalizeBuckets(RecordZeroOffset, Records);
196}
197
199 uint32_t RecordZeroOffset, MutableArrayRef<BulkPublic> Records) {
200 // Hash every name in parallel.
201 parallelFor(0, Records.size(), [&](size_t I) {
202 Records[I].setBucketIdx(hashStringV1(Records[I].Name) % IPHR_HASH);
203 });
204
205 // Count up the size of each bucket. Then, use an exclusive prefix sum to
206 // calculate the bucket start offsets. This is C++17 std::exclusive_scan, but
207 // we can't use it yet.
208 uint32_t BucketStarts[IPHR_HASH] = {0};
209 for (const BulkPublic &P : Records)
210 ++BucketStarts[P.BucketIdx];
211 uint32_t Sum = 0;
212 for (uint32_t &B : BucketStarts) {
213 uint32_t Size = B;
214 B = Sum;
215 Sum += Size;
216 }
217
218 // Place globals into the hash table in bucket order. When placing a global,
219 // update the bucket start. Every hash table slot should be filled. Always use
220 // a refcount of one for now.
221 HashRecords.resize(Records.size());
222 uint32_t BucketCursors[IPHR_HASH];
223 memcpy(BucketCursors, BucketStarts, sizeof(BucketCursors));
224 for (int I = 0, E = Records.size(); I < E; ++I) {
225 uint32_t HashIdx = BucketCursors[Records[I].BucketIdx]++;
226 HashRecords[HashIdx].Off = I;
227 HashRecords[HashIdx].CRef = 1;
228 }
229
230 // Within the buckets, sort each bucket by memcmp of the symbol's name. It's
231 // important that we use the same sorting algorithm as is used by the
232 // reference implementation to ensure that the search for a record within a
233 // bucket can properly early-out when it detects the record won't be found.
234 // The algorithm used here corresponds to the function
235 // caseInsensitiveComparePchPchCchCch in the reference implementation.
236 parallelFor(0, IPHR_HASH, [&](size_t I) {
237 auto B = HashRecords.begin() + BucketStarts[I];
238 auto E = HashRecords.begin() + BucketCursors[I];
239 if (B == E)
240 return;
241 auto BucketCmp = [Records](const PSHashRecord &LHash,
242 const PSHashRecord &RHash) {
243 const BulkPublic &L = Records[uint32_t(LHash.Off)];
244 const BulkPublic &R = Records[uint32_t(RHash.Off)];
245 assert(L.BucketIdx == R.BucketIdx);
246 int Cmp = gsiRecordCmp(L.getName(), R.getName());
247 if (Cmp != 0)
248 return Cmp < 0;
249 // This comparison is necessary to make the sorting stable in the presence
250 // of two static globals with the same name. The easiest way to observe
251 // this is with S_LDATA32 records.
252 return L.SymOffset < R.SymOffset;
253 };
254 llvm::sort(B, E, BucketCmp);
255
256 // After we are done sorting, replace the global indices with the stream
257 // offsets of each global. Add one when writing symbol offsets to disk.
258 // See GSI1::fixSymRecs.
259 for (PSHashRecord &HRec : make_range(B, E))
260 HRec.Off = Records[uint32_t(HRec.Off)].SymOffset + 1;
261 });
262
263 // For each non-empty bucket, push the bucket start offset into HashBuckets
264 // and set a bit in the hash bitmap.
265 for (uint32_t I = 0; I < HashBitmap.size(); ++I) {
266 uint32_t Word = 0;
267 for (uint32_t J = 0; J < 32; ++J) {
268 // Skip empty buckets.
269 uint32_t BucketIdx = I * 32 + J;
270 if (BucketIdx >= IPHR_HASH ||
271 BucketStarts[BucketIdx] == BucketCursors[BucketIdx])
272 continue;
273 Word |= (1U << J);
274
275 // Calculate what the offset of the first hash record in the chain would
276 // be if it were inflated to contain 32-bit pointers. On a 32-bit system,
277 // each record would be 12 bytes. See HROffsetCalc in gsi.h.
278 const int SizeOfHROffsetCalc = 12;
279 ulittle32_t ChainStartOff =
280 ulittle32_t(BucketStarts[BucketIdx] * SizeOfHROffsetCalc);
281 HashBuckets.push_back(ChainStartOff);
282 }
283 HashBitmap[I] = Word;
284 }
285}
286
288 : Msf(Msf), PSH(std::make_unique<GSIHashStreamBuilder>()),
289 GSH(std::make_unique<GSIHashStreamBuilder>()) {}
290
292
293uint32_t GSIStreamBuilder::calculatePublicsHashStreamSize() const {
294 uint32_t Size = 0;
295 Size += sizeof(PublicsStreamHeader);
296 Size += PSH->calculateSerializedLength();
297 Size += Publics.size() * sizeof(uint32_t); // AddrMap
298 // FIXME: Add thunk map and section offsets for incremental linking.
299
300 return Size;
301}
302
303uint32_t GSIStreamBuilder::calculateGlobalsHashStreamSize() const {
304 return GSH->calculateSerializedLength();
305}
306
308 // First we write public symbol records, then we write global symbol records.
309 finalizePublicBuckets();
310 finalizeGlobalBuckets(PSH->RecordByteSize);
311
312 Expected<uint32_t> Idx = Msf.addStream(calculateGlobalsHashStreamSize());
313 if (!Idx)
314 return Idx.takeError();
315 GlobalsStreamIndex = *Idx;
316
317 Idx = Msf.addStream(calculatePublicsHashStreamSize());
318 if (!Idx)
319 return Idx.takeError();
320 PublicsStreamIndex = *Idx;
321
322 uint32_t RecordBytes = PSH->RecordByteSize + GSH->RecordByteSize;
323
324 Idx = Msf.addStream(RecordBytes);
325 if (!Idx)
326 return Idx.takeError();
327 RecordStreamIndex = *Idx;
328 return Error::success();
329}
330
331void GSIStreamBuilder::addPublicSymbols(std::vector<BulkPublic> &&PublicsIn) {
332 assert(Publics.empty() && PSH->RecordByteSize == 0 &&
333 "publics can only be added once");
334 Publics = std::move(PublicsIn);
335
336 // Sort the symbols by name. PDBs contain lots of symbols, so use parallelism.
337 parallelSort(Publics, [](const BulkPublic &L, const BulkPublic &R) {
338 return L.getName() < R.getName();
339 });
340
341 // Assign offsets and calculate the length of the public symbol records.
342 uint32_t SymOffset = 0;
343 for (BulkPublic &Pub : Publics) {
344 Pub.SymOffset = SymOffset;
345 SymOffset += sizeOfPublic(Pub);
346 }
347
348 // Remember the length of the public stream records.
349 PSH->RecordByteSize = SymOffset;
350}
351
353 serializeAndAddGlobal(Sym);
354}
355
357 serializeAndAddGlobal(Sym);
358}
359
361 serializeAndAddGlobal(Sym);
362}
363
364template <typename T>
365void GSIStreamBuilder::serializeAndAddGlobal(const T &Symbol) {
366 T Copy(Symbol);
368 CodeViewContainer::Pdb));
369}
370
372 // Ignore duplicate typedefs and constants.
373 if (Symbol.kind() == S_UDT || Symbol.kind() == S_CONSTANT) {
374 auto Iter = GlobalsSeen.insert(Symbol);
375 if (!Iter.second)
376 return;
377 }
378 GSH->RecordByteSize += Symbol.length();
379 Globals.push_back(Symbol);
380}
381
382// Serialize each public and write it.
384 ArrayRef<BulkPublic> Publics) {
385 std::vector<uint8_t> Storage;
386 for (const BulkPublic &Pub : Publics) {
387 Storage.resize(sizeOfPublic(Pub));
388 serializePublic(Storage.data(), Pub);
389 if (Error E = Writer.writeBytes(Storage))
390 return E;
391 }
392 return Error::success();
393}
394
396 ArrayRef<CVSymbol> Records) {
398 ItemStream.setItems(Records);
399 BinaryStreamRef RecordsRef(ItemStream);
400 return Writer.writeStreamRef(RecordsRef);
401}
402
403Error GSIStreamBuilder::commitSymbolRecordStream(
405 BinaryStreamWriter Writer(Stream);
406
407 // Write public symbol records first, followed by global symbol records. This
408 // must match the order that we assume in finalizeMsfLayout when computing
409 // PSHZero and GSHZero.
410 if (auto EC = writePublics(Writer, Publics))
411 return EC;
412 if (auto EC = writeRecords(Writer, Globals))
413 return EC;
414
415 return Error::success();
416}
417
418static std::vector<support::ulittle32_t>
420 // Build a parallel vector of indices into the Publics vector, and sort it by
421 // address.
422 std::vector<ulittle32_t> PubAddrMap;
423 PubAddrMap.reserve(Publics.size());
424 for (int I = 0, E = Publics.size(); I < E; ++I)
425 PubAddrMap.push_back(ulittle32_t(I));
426
427 auto AddrCmp = [Publics](const ulittle32_t &LIdx, const ulittle32_t &RIdx) {
428 const BulkPublic &L = Publics[LIdx];
429 const BulkPublic &R = Publics[RIdx];
430 if (L.Segment != R.Segment)
431 return L.Segment < R.Segment;
432 if (L.Offset != R.Offset)
433 return L.Offset < R.Offset;
434 // parallelSort is unstable, so we have to do name comparison to ensure
435 // that two names for the same location come out in a deterministic order.
436 return L.getName() < R.getName();
437 };
438 parallelSort(PubAddrMap, AddrCmp);
439
440 // Rewrite the public symbol indices into symbol offsets.
441 for (ulittle32_t &Entry : PubAddrMap)
442 Entry = Publics[Entry].SymOffset;
443 return PubAddrMap;
444}
445
446Error GSIStreamBuilder::commitPublicsHashStream(
448 BinaryStreamWriter Writer(Stream);
449 PublicsStreamHeader Header;
450
451 // FIXME: Fill these in. They are for incremental linking.
452 Header.SymHash = PSH->calculateSerializedLength();
453 Header.AddrMap = Publics.size() * 4;
454 Header.NumThunks = 0;
455 Header.SizeOfThunk = 0;
456 Header.ISectThunkTable = 0;
457 memset(Header.Padding, 0, sizeof(Header.Padding));
458 Header.OffThunkTable = 0;
459 Header.NumSections = 0;
460 if (auto EC = Writer.writeObject(Header))
461 return EC;
462
463 if (auto EC = PSH->commit(Writer))
464 return EC;
465
466 std::vector<support::ulittle32_t> PubAddrMap = computeAddrMap(Publics);
467 assert(PubAddrMap.size() == Publics.size());
468 if (auto EC = Writer.writeArray(ArrayRef(PubAddrMap)))
469 return EC;
470
471 return Error::success();
472}
473
474Error GSIStreamBuilder::commitGlobalsHashStream(
476 BinaryStreamWriter Writer(Stream);
477 return GSH->commit(Writer);
478}
479
482 llvm::TimeTraceScope timeScope("Commit GSI stream");
484 Layout, Buffer, getGlobalsStreamIndex(), Msf.getAllocator());
486 Layout, Buffer, getPublicsStreamIndex(), Msf.getAllocator());
488 Layout, Buffer, getRecordStreamIndex(), Msf.getAllocator());
489
490 if (auto EC = commitSymbolRecordStream(*PRS))
491 return EC;
492 if (auto EC = commitGlobalsHashStream(*GS))
493 return EC;
494 if (auto EC = commitPublicsHashStream(*PS))
495 return EC;
496 return Error::success();
497}
static const LLT S1
static GCRegistry::Add< OcamlGC > B("ocaml", "ocaml 3.10-compatible GC")
#define LLVM_UNLIKELY(EXPR)
Definition: Compiler.h:241
#define LLVM_PACKED_END
Definition: Compiler.h:431
#define LLVM_PACKED_START
Definition: Compiler.h:430
Returns the sub type a function will return at a given Idx Should correspond to the result type of an ExtractValue instruction executed with just that one unsigned Idx
std::string Name
uint64_t Size
Symbol * Sym
Definition: ELF_riscv.cpp:479
static CVSymbol serializePublic(uint8_t *Mem, const BulkPublic &Pub)
static Error writePublics(BinaryStreamWriter &Writer, ArrayRef< BulkPublic > Publics)
static bool isAsciiString(StringRef S)
static Error writeRecords(BinaryStreamWriter &Writer, ArrayRef< CVSymbol > Records)
static int gsiRecordCmp(StringRef S1, StringRef S2)
static std::vector< support::ulittle32_t > computeAddrMap(ArrayRef< BulkPublic > Publics)
static uint32_t sizeOfPublic(const BulkPublic &Pub)
#define I(x, y, z)
Definition: MD5.cpp:58
Merge contiguous icmps into a memcmp
Definition: MergeICmps.cpp:911
#define P(N)
assert(ImpDefSCC.getReg()==AMDGPU::SCC &&ImpDefSCC.isDef())
Value * RHS
Value * LHS
ArrayRef - Represent a constant reference to an array (0 or more elements consecutively in memory),...
Definition: ArrayRef.h:41
BinaryItemStream represents a sequence of objects stored in some kind of external container but for w...
void setItems(ArrayRef< T > ItemArray)
BinaryStreamRef is to BinaryStream what ArrayRef is to an Array.
Provides write only access to a subclass of WritableBinaryStream.
Error writeArray(ArrayRef< T > Array)
Writes an array of objects of type T to the underlying stream, as if by using memcpy.
Error writeStreamRef(BinaryStreamRef Ref)
Efficiently reads all data from Ref, and writes it to this stream.
Error writeBytes(ArrayRef< uint8_t > Buffer)
Write the bytes specified in Buffer to the underlying stream.
Error writeObject(const T &Obj)
Writes the object Obj to the underlying stream, as if by using memcpy.
Lightweight error class with error context and mandatory checking.
Definition: Error.h:160
static ErrorSuccess success()
Create a success value.
Definition: Error.h:337
Tagged union holding either a T or a Error.
Definition: Error.h:481
MutableArrayRef - Represent a mutable reference to an array (0 or more elements consecutively in memo...
Definition: ArrayRef.h:307
StringRef - Represent a constant reference to a string, i.e.
Definition: StringRef.h:50
constexpr size_t size() const
size - Get the string size.
Definition: StringRef.h:137
constexpr const char * data() const
data - Get a pointer to the start of the string (which may not be null terminated).
Definition: StringRef.h:131
The TimeTraceScope is a helper class to call the begin and end functions of the time trace profiler.
Definition: TimeProfiler.h:163
CVRecord is a fat pointer (base + size pair) to a symbol or type record.
Definition: CVRecord.h:29
ArrayRef< uint8_t > RecordData
Definition: CVRecord.h:60
static CVSymbol writeOneSymbol(SymType &Sym, BumpPtrAllocator &Storage, CodeViewContainer Container)
BumpPtrAllocator & getAllocator()
Definition: MSFBuilder.h:119
Expected< uint32_t > addStream(uint32_t Size, ArrayRef< uint32_t > Blocks)
Add a stream to the MSF file with the given size, occupying the given list of blocks.
Definition: MSFBuilder.cpp:156
static std::unique_ptr< WritableMappedBlockStream > createIndexedStream(const MSFLayout &Layout, WritableBinaryStreamRef MsfData, uint32_t StreamIndex, BumpPtrAllocator &Allocator)
void addPublicSymbols(std::vector< BulkPublic > &&PublicsIn)
uint32_t getRecordStreamIndex() const
Error commit(const msf::MSFLayout &Layout, WritableBinaryStreamRef Buffer)
GSIStreamBuilder(msf::MSFBuilder &Msf)
void addGlobalSymbol(const codeview::ProcRefSym &Sym)
uint32_t getPublicsStreamIndex() const
uint32_t getGlobalsStreamIndex() const
@ C
The default llvm calling convention, compatible with C.
Definition: CallingConv.h:34
llvm::SmallVector< std::shared_ptr< RecordsSlice >, 4 > Records
Definition: RecordsSlice.h:197
CVRecord< SymbolKind > CVSymbol
Definition: CVRecord.h:65
StringRef getSymbolName(CVSymbol Sym)
Definition: RecordName.cpp:323
detail::packed_endian_specific_integral< uint32_t, llvm::endianness::little, unaligned > ulittle32_t
Definition: Endian.h:285
This is an optimization pass for GlobalISel generic memory operations.
Definition: AddressRanges.h:18
bool all_of(R &&range, UnaryPredicate P)
Provide wrappers to std::all_of which take ranges instead of having to pass begin/end explicitly.
Definition: STLExtras.h:1722
uint64_t xxh3_64bits(ArrayRef< uint8_t > data)
Definition: xxhash.cpp:553
iterator_range< T > make_range(T x, T y)
Convenience function for iterating over sub-ranges.
void parallelSort(RandomAccessIterator Start, RandomAccessIterator End, const Comparator &Comp=Comparator())
Definition: Parallel.h:219
void sort(IteratorTy Start, IteratorTy End)
Definition: STLExtras.h:1647
uint64_t alignTo(uint64_t Size, Align A)
Returns a multiple of A needed to store Size bytes.
Definition: Alignment.h:155
void parallelFor(size_t Begin, size_t End, function_ref< void(size_t)> Fn)
Definition: Parallel.cpp:236
Implement std::hash so that hash_code can be used in STL containers.
Definition: BitVector.h:858
An information struct used to provide DenseMap with the various necessary components for a given valu...
Definition: DenseMapInfo.h:52
This struct is equivalent to codeview::PublicSym32, but it has been optimized for size to speed up bu...
Header of the hash tables found in the globals and publics sections.
Definition: RawTypes.h:28
std::vector< support::ulittle32_t > HashBuckets
Error commit(BinaryStreamWriter &Writer)
std::array< support::ulittle32_t,(IPHR_HASH+32)/32 > HashBitmap
void finalizeGlobalBuckets(uint32_t RecordZeroOffset)
std::vector< PSHashRecord > HashRecords
void finalizeBuckets(uint32_t RecordZeroOffset, MutableArrayRef< BulkPublic > Globals)
support::ulittle32_t Off
Definition: RawTypes.h:41
static unsigned getHashValue(const CVSymbol &Val)
static bool isEqual(const CVSymbol &LHS, const CVSymbol &RHS)