LLVM: lib/Target/RISCV/RISCVConstantPoolValue.h Source File (original) (raw)
1
2
3
4
5
6
7
8
9
10
11
12
13#ifndef LLVM_LIB_TARGET_RISCV_RISCVCONSTANTPOOLVALUE_H
14#define LLVM_LIB_TARGET_RISCV_RISCVCONSTANTPOOLVALUE_H
15
20
21namespace llvm {
22
26
27
29 const GlobalValue *GV;
31
32 RISCVConstantPoolValue(Type *Ty, const GlobalValue *GV);
34
35private:
36 enum class RISCVCPKind { ExtSymbol, GlobalValue };
37 RISCVCPKind Kind;
38
39public:
41
42 static RISCVConstantPoolValue *Create(const GlobalValue *GV);
44
45 bool isGlobalValue() const { return Kind == RISCVCPKind::GlobalValue; }
46 bool isExtSymbol() const { return Kind == RISCVCPKind::ExtSymbol; }
47
50
52 Align Alignment) override;
53
55
57
59};
60
61}
62
63#endif
static GCRegistry::Add< ErlangGC > A("erlang", "erlang-compatible garbage collector")
This file declares the MachineConstantPool class which is an abstract constant pool to keep track of ...
The address of a basic block.
FoldingSetNodeID - This class is used to gather all the unique data bits of a node.
This is an important class for using LLVM in a threaded context.
MachineConstantPoolValue(Type *ty)
The MachineConstantPool class keeps track of constants referenced by a function which must be spilled...
A RISCV-specific constant pool value.
Definition RISCVConstantPoolValue.h:28
const GlobalValue * getGlobalValue() const
Definition RISCVConstantPoolValue.h:48
static RISCVConstantPoolValue * Create(const GlobalValue *GV)
bool equals(const RISCVConstantPoolValue *A) const
bool isExtSymbol() const
Definition RISCVConstantPoolValue.h:46
void print(raw_ostream &O) const override
print - Implement operator<<
StringRef getSymbol() const
Definition RISCVConstantPoolValue.h:49
bool isGlobalValue() const
Definition RISCVConstantPoolValue.h:45
void addSelectionDAGCSEId(FoldingSetNodeID &ID) override
~RISCVConstantPoolValue() override=default
int getExistingMachineCPValue(MachineConstantPool *CP, Align Alignment) override
StringRef - Represent a constant reference to a string, i.e.
The instances of the Type class are immutable: once they are created, they are never changed.
This class implements an extremely fast bulk output stream that can only output to a stream.
unsigned ID
LLVM IR allows to use arbitrary numbers as calling convention identifiers.
@ C
The default llvm calling convention, compatible with C.
This is an optimization pass for GlobalISel generic memory operations.
This struct is a compact representation of a valid (non-zero power of two) alignment.