LLVM: include/llvm/IR/ModuleSlotTracker.h Source File (original) (raw)
1
2
3
4
5
6
7
8
9#ifndef LLVM_IR_MODULESLOTTRACKER_H
10#define LLVM_IR_MODULESLOTTRACKER_H
11
13#include
14#include
15#include
16#include
17
18namespace llvm {
19
25
26
36
37
38
39
40
41
42
43
44
46
47 std::unique_ptr MachineStorage;
48 bool ShouldCreateStorage = false;
49 bool ShouldInitializeAllMetadata = false;
50
51 const Module *M = nullptr;
54
56 ProcessModuleHookFn;
58 ProcessFunctionHookFn;
59
60public:
61
64
65
66
67
68
69
70
71
73 bool ShouldInitializeAllMetadata = true);
74
75
77
78
80
83
84
85
86
87
88 void incorporateFunction(const Function &F);
89
90
91
92
93
94
95 int getLocalSlot(const Value *V);
96
97 void setProcessHook(
101
103 std::vector<std::pair<unsigned, const MDNode *>>;
104
106};
107
108}
109
110#endif
Abstract interface of slot tracker storage.
Definition ModuleSlotTracker.h:27
virtual unsigned getNextMetadataSlot()=0
virtual int getMetadataSlot(const MDNode *)=0
virtual ~AbstractSlotTrackerStorage()
virtual void createMetadataSlot(const MDNode *)=0
const Module * getModule() const
Definition ModuleSlotTracker.h:81
ModuleSlotTracker(SlotTracker &Machine, const Module *M, const Function *F=nullptr)
Wrap a preinitialized SlotTracker.
virtual ~ModuleSlotTracker()
Destructor to clean up storage.
std::vector< std::pair< unsigned, const MDNode * > > MachineMDNodeListType
Definition ModuleSlotTracker.h:102
void collectMDNodes(MachineMDNodeListType &L, unsigned LB, unsigned UB) const
SlotTracker * getMachine()
Lazily creates a slot tracker.
const Function * getCurrentFunction() const
Definition ModuleSlotTracker.h:82
A Module instance is used to store all the information related to an LLVM module.
This class provides computation of slot numbers for LLVM Assembly writing.
LLVM Value Representation.
This is an optimization pass for GlobalISel generic memory operations.