LLVM: include/llvm/CodeGen/NonRelocatableStringpool.h Source File (original) (raw)
1
2
3
4
5
6
7
8
9#ifndef LLVM_CODEGEN_NONRELOCATABLESTRINGPOOL_H
10#define LLVM_CODEGEN_NONRELOCATABLESTRINGPOOL_H
11
15#include
16#include
17
18namespace llvm {
19
20
21
22
23
25public:
26
27
28
30
32 if (PutEmptyString)
34 }
35
37
38
39
41
42
43
44
45
46
47
49
51
52
53
55
56private:
57 MapTy Strings;
58 uint64_t CurrentEndOffset = 0;
59 unsigned NumEntries = 0;
60};
61
62
63template <typename T, typename S> class StrongType : public T {
64public:
65 template <typename... Args>
67};
68
69
70
71
76
77}
78
79#endif
This file defines the BumpPtrAllocator interface.
static GCRegistry::Add< ErlangGC > A("erlang", "erlang-compatible garbage collector")
DwarfStringPoolEntryRef: Dwarf string pool entry reference.
uint64_t getOffset() const
LLVM_ABI StringRef internString(StringRef S)
Get permanent storage for S (but do not necessarily emit S in the output section).
StringMap< DwarfStringPoolEntry, BumpPtrAllocator > MapTy
Entries are stored into the StringMap and simply linked together through the second element of this p...
Definition NonRelocatableStringpool.h:29
NonRelocatableStringpool(bool PutEmptyString=false)
Definition NonRelocatableStringpool.h:31
LLVM_ABI DwarfStringPoolEntryRef getEntry(StringRef S)
uint64_t getSize()
Definition NonRelocatableStringpool.h:50
LLVM_ABI std::vector< DwarfStringPoolEntryRef > getEntriesForEmission() const
Return the list of strings to be emitted.
uint64_t getStringOffset(StringRef S)
Get the offset of string S in the string table.
Definition NonRelocatableStringpool.h:40
StringMap - This is an unconventional map that is specialized for handling keys that are "strings",...
StringRef - Represent a constant reference to a string, i.e.
Helper for making strong types.
Definition NonRelocatableStringpool.h:63
StrongType(Args... A)
Definition NonRelocatableStringpool.h:66
This is an optimization pass for GlobalISel generic memory operations.
StrongType< NonRelocatableStringpool, UniqueTag > UniquingStringPool
Definition NonRelocatableStringpool.h:74
StrongType< NonRelocatableStringpool, OffsetsTag > OffsetsStringPool
Definition NonRelocatableStringpool.h:75
Implement std::hash so that hash_code can be used in STL containers.
It's very easy to introduce bugs by passing the wrong string pool.
Definition NonRelocatableStringpool.h:72