13#ifndef LLVM_LIB_TARGET_XTENSA_XTENSACONSTANTPOOLVALUE_H
14#define LLVM_LIB_TARGET_XTENSA_XTENSACONSTANTPOOLVALUE_H
29class MachineBasicBlock;
63 template <
typename Derived>
65 const std::vector<MachineConstantPoolEntry> &Constants = CP->getConstants();
66 for (
unsigned i = 0, e = Constants.size(); i != e; ++i) {
67 if (Constants[i].isMachineConstantPoolEntry() &&
68 (Constants[i].
getAlign() >= Alignment)) {
70 Constants[i].Val.MachineCPVal);
71 if (Derived *APC = dyn_cast<Derived>(CPV))
72 if (cast<Derived>(
this)->equals(APC))
98 Align Alignment)
override;
107 return this->LabelId ==
A->LabelId && this->Modifier ==
A->Modifier;
112#if !defined(NDEBUG) || defined(LLVM_ENABLE_DUMP)
138 Align Alignment)
override;
163 LLVMContext &
C,
const char *S,
unsigned Id,
bool PrivLinkage,
174 Align Alignment)
override;
210 Align Alignment)
override;
242 Align Alignment)
override;
static GCRegistry::Add< ErlangGC > A("erlang", "erlang-compatible garbage collector")
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
This file declares the MachineConstantPool class which is an abstract constant pool to keep track of ...
The address of a basic block.
This is an important base class in LLVM.
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.
Abstract base class for all machine specific constantpool value subclasses.
The MachineConstantPool class keeps track of constants referenced by a function which must be spilled...
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.
XtensaConstantPoolConstant - Xtensa-specific constant pool values for Constants (for example BlockAdd...
int getExistingMachineCPValue(MachineConstantPool *CP, Align Alignment) override
bool hasSameValue(XtensaConstantPoolValue *ACPV) override
hasSameValue - Return true if this Xtensa constpool value can share the same constantpool entry as an...
static bool classof(const XtensaConstantPoolValue *APV)
const BlockAddress * getBlockAddress() const
bool equals(const XtensaConstantPoolConstant *A) const
static XtensaConstantPoolConstant * Create(const Constant *C, unsigned ID, XtensaCP::XtensaCPKind Kind)
void print(raw_ostream &O) const override
print - Implement operator<<
void addSelectionDAGCSEId(FoldingSetNodeID &ID) override
XtensaConstantPoolJumpTable - Xtensa-specific constantpool values for Jump Table symbols.
static XtensaConstantPoolJumpTable * Create(LLVMContext &C, unsigned Idx)
unsigned getIndex() const
bool equals(const XtensaConstantPoolJumpTable *A) const
static bool classof(const XtensaConstantPoolValue *ACPV)
void addSelectionDAGCSEId(FoldingSetNodeID &ID) override
void print(raw_ostream &O) const override
print - Implement operator<<
int getExistingMachineCPValue(MachineConstantPool *CP, Align Alignment) override
bool hasSameValue(XtensaConstantPoolValue *ACPV) override
hasSameValue - Return true if this Xtensa constpool value can share the same constantpool entry as an...
XtensaConstantPoolMBB - Xtensa-specific constantpool value of a machine basic block.
static bool classof(const XtensaConstantPoolValue *ACPV)
bool equals(const XtensaConstantPoolMBB *A) const
static XtensaConstantPoolMBB * Create(LLVMContext &C, const MachineBasicBlock *M, unsigned ID)
void print(raw_ostream &O) const override
print - Implement operator<<
bool hasSameValue(XtensaConstantPoolValue *ACPV) override
hasSameValue - Return true if this Xtensa constpool value can share the same constantpool entry as an...
void addSelectionDAGCSEId(FoldingSetNodeID &ID) override
int getExistingMachineCPValue(MachineConstantPool *CP, Align Alignment) override
const MachineBasicBlock * getMBB() const
XtensaConstantPoolSymbol - Xtensa-specific constantpool values for external symbols.
void addSelectionDAGCSEId(FoldingSetNodeID &ID) override
bool equals(const XtensaConstantPoolSymbol *A) const
static bool classof(const XtensaConstantPoolValue *ACPV)
void print(raw_ostream &O) const override
print - Implement operator<<
static XtensaConstantPoolSymbol * Create(LLVMContext &C, const char *S, unsigned ID, bool PrivLinkage, XtensaCP::XtensaCPModifier Modifier=XtensaCP::no_modifier)
int getExistingMachineCPValue(MachineConstantPool *CP, Align Alignment) override
bool hasSameValue(XtensaConstantPoolValue *ACPV) override
hasSameValue - Return true if this Xtensa constpool value can share the same constantpool entry as an...
const char * getSymbol() const
XtensaConstantPoolValue - Xtensa specific constantpool value.
virtual bool hasSameValue(XtensaConstantPoolValue *ACPV)
hasSameValue - Return true if this Xtensa constpool value can share the same constantpool entry as an...
~XtensaConstantPoolValue() override
int getExistingMachineCPValue(MachineConstantPool *CP, Align Alignment) override
int getExistingMachineCPValueImpl(MachineConstantPool *CP, Align Alignment)
void print(raw_ostream &O) const override
print - Implement operator<<
bool equals(const XtensaConstantPoolValue *A) const
unsigned getLabelId() const
StringRef getModifierText() const
bool isMachineBasicBlock() const
bool isBlockAddress() const
void setLabelId(unsigned ID)
void addSelectionDAGCSEId(FoldingSetNodeID &ID) override
XtensaCP::XtensaCPModifier getModifier() const
This class implements an extremely fast bulk output stream that can only output to a stream.
@ C
The default llvm calling convention, compatible with C.
unsigned ID
LLVM IR allows to use arbitrary numbers as calling convention identifiers.
This is an optimization pass for GlobalISel generic memory operations.
MaybeAlign getAlign(const Function &F, unsigned Index)
raw_ostream & operator<<(raw_ostream &OS, const APFixedPoint &FX)
This struct is a compact representation of a valid (non-zero power of two) alignment.