13 #ifndef LLVM_LIB_CODEGEN_MIRPARSER_MIPARSER_H 14 #define LLVM_LIB_CODEGEN_MIRPARSER_MIPARSER_H 23 class MachineBasicBlock;
24 class MachineFunction;
31 class TargetRegisterClass;
32 class TargetSubtargetInfo;
84 void initNames2InstrOpCodes();
85 void initNames2Regs();
86 void initNames2RegMasks();
87 void initNames2SubRegIndices();
88 void initNames2TargetIndices();
89 void initNames2DirectTargetFlags();
90 void initNames2BitmaskTargetFlags();
91 void initNames2MMOTargetFlags();
93 void initNames2RegClasses();
94 void initNames2RegBanks();
99 bool parseInstrName(
StringRef InstrName,
unsigned &OpCode);
103 bool getRegisterByName(
StringRef RegName,
unsigned &
Reg);
130 bool getBitmaskTargetFlag(
StringRef Name,
unsigned &Flag);
150 initNames2RegClasses();
151 initNames2RegBanks();
181 VRegInfo &getVRegInfo(
unsigned Num);
183 const Value *getIRValue(
unsigned Slot);
237 #endif // LLVM_LIB_CODEGEN_MIRPARSER_MIPARSER_H
bool parseMachineBasicBlockDefinitions(PerFunctionMIParsingState &PFS, StringRef Src, SMDiagnostic &Error)
Parse the machine basic block definitions, and skip the machine instructions.
DenseMap< unsigned, unsigned > JumpTableSlots
DenseMap< unsigned, unsigned > ConstantPoolSlots
This class represents lattice values for constants.
amdgpu Simplify well known AMD library false FunctionCallee Value const Twine & Name
DenseMap< unsigned, int > StackObjectSlots
bool parseMBBReference(PerFunctionMIParsingState &PFS, MachineBasicBlock *&MBB, StringRef Src, SMDiagnostic &Error)
const TargetRegisterClass * RC
This file defines the MallocAllocator and BumpPtrAllocator interfaces.
StringMap< VRegInfo * > VRegInfosNamed
static int getRegClass(RegisterKind Is, unsigned RegWidth)
DenseMap< unsigned, int > FixedStackObjectSlots
bool parseVirtualRegisterReference(PerFunctionMIParsingState &PFS, VRegInfo *&Info, StringRef Src, SMDiagnostic &Error)
union llvm::VRegInfo::@178 D
Analysis containing CSE Info
Flag
These should be considered private to the implementation of the MCInstrDesc class.
bool parseStackObjectReference(PerFunctionMIParsingState &PFS, int &FI, StringRef Src, SMDiagnostic &Error)
Allocate memory in an ever growing pool, as if by bump-pointer.
BumpPtrAllocator Allocator
bool parseNamedRegisterReference(PerFunctionMIParsingState &PFS, unsigned &Reg, StringRef Src, SMDiagnostic &Error)
This owns the files read by a parser, handles include stacks, and handles diagnostic wrangling...
const SlotMapping & IRSlots
PerTargetMIParsingState(const TargetSubtargetInfo &STI)
bool parseMachineInstructions(PerFunctionMIParsingState &PFS, StringRef Src, SMDiagnostic &Error)
Parse the machine instructions.
enum llvm::VRegInfo::uint8_t Kind
DenseMap< unsigned, const Value * > Slots2Values
Maps from slot numbers to function's unnamed values.
This class implements the register bank concept.
StringMap - This is an unconventional map that is specialized for handling keys that are "strings"...
This struct contains the mappings from the slot numbers to unnamed metadata nodes, global values and types.
bool parseMDNode(PerFunctionMIParsingState &PFS, MDNode *&Node, StringRef Src, SMDiagnostic &Error)
RegisterBank & getRegBank(unsigned ID)
Get the register bank identified by ID.
Flags
Flags values. These may be or'd together.
TargetSubtargetInfo - Generic base class for all target subtargets.
bool Explicit
VReg was explicitly specified in the .mir file.
DenseMap< unsigned, MachineBasicBlock * > MBBSlots
LLVM Value Representation.
Lightweight error class with error context and mandatory checking.
StringRef - Represent a constant reference to a string, i.e.
const RegisterBank * RegBank
PerTargetMIParsingState & Target
DenseMap< unsigned, VRegInfo * > VRegInfos
bool parseRegisterReference(PerFunctionMIParsingState &PFS, unsigned &Reg, StringRef Src, SMDiagnostic &Error)
Instances of this class encapsulate one diagnostic report, allowing printing to a raw_ostream as a ca...