LLVM: lib/Target/Mips/MipsAsmPrinter.h Source File (original) (raw)
1
2
3
4
5
6
7
8
9
10
11
12
13#ifndef LLVM_LIB_TARGET_MIPS_MIPSASMPRINTER_H
14#define LLVM_LIB_TARGET_MIPS_MIPSASMPRINTER_H
15
22#include
23#include
24#include
25
26namespace llvm {
27
41
44
46
47
48
49
50
51public:
52
56
57private:
58
59
61
62
63
64 bool InConstantPool = false;
65
66 std::map<const char *, const Mips16HardFloatInfo::FuncSignature *>
67 StubsNeeded;
68
70
71
73
74
75
76
79
80
82
83 void emitInlineAsmStart() const override;
84
87
90 unsigned uid) const override;
91
93
94 void EmitInstrReg(const MCSubtargetInfo &STI, unsigned Opcode, unsigned Reg);
95
96 void EmitInstrRegReg(const MCSubtargetInfo &STI, unsigned Opcode,
97 unsigned Reg1, unsigned Reg2);
98
99 void EmitInstrRegRegReg(const MCSubtargetInfo &STI, unsigned Opcode,
100 unsigned Reg1, unsigned Reg2, unsigned Reg3);
101
102 void EmitMovFPIntPair(const MCSubtargetInfo &STI, unsigned MovOpc,
103 unsigned Reg1, unsigned Reg2, unsigned FPReg1,
104 unsigned FPReg2, bool LE);
105
108 bool ToFP);
109
112
114
115 bool isLongBranchPseudo(int Opcode) const;
116
117public:
119
123
125 std::unique_ptr Streamer)
127
129
131
133 bool UsingConstantPools =
135 if (!UsingConstantPools)
137
138 }
139
140 void emitInstruction(const MachineInstr *MI) override;
141 void printSavedRegsBitmask();
142 void emitFrameDirective();
143 const char *getCurrentABIString() const;
144 void emitFunctionEntryLabel() override;
145 void emitFunctionBodyStart() override;
146 void emitFunctionBodyEnd() override;
148 bool PrintAsmOperand(const MachineInstr *MI, unsigned OpNo,
149 const char *ExtraCode, raw_ostream &O) override;
150 bool PrintAsmMemoryOperand(const MachineInstr *MI, unsigned OpNum,
151 const char *ExtraCode, raw_ostream &O) override;
157 void emitStartOfAsmFile(Module &M) override;
158 void emitEndOfAsmFile(Module &M) override;
160 void emitDebugValue(const MCExpr *Value, unsigned Size) const override;
161};
162
163}
164
165#endif
#define LLVM_LIBRARY_VISIBILITY
static bool printOperand(raw_ostream &OS, const SelectionDAG *G, const SDValue Value)
static void printMemOperand(raw_ostream &OS, const MachineMemOperand &MMO, const MachineFunction *MF, const Module *M, const MachineFrameInfo *MFI, const TargetInstrInfo *TII, LLVMContext &Ctx)
virtual void emitConstantPool()
Print to the current output stream assembly representations of the constants in the constant pool MCP...
TargetMachine & TM
Target machine description.
AsmPrinter(TargetMachine &TM, std::unique_ptr< MCStreamer > Streamer, char &ID=AsmPrinter::ID)
std::unique_ptr< MCStreamer > OutStreamer
This is the MCStreamer object for the file we are generating.
Base class for the full range of assembler expressions which are needed for parsing.
Instances of this class represent a single low-level machine instruction.
Instances of this class represent operands of the MCInst class.
Streaming machine code generation interface.
Generic base class for all target subtargets.
MCSymbol - Instances of this class represent a symbol name in the MC file, and MCSymbols are created ...
The MachineConstantPool class keeps track of constants referenced by a function which must be spilled...
Representation of each machine instruction.
MachineOperand class - Representation of each machine instruction operand.
MipsAsmPrinter(TargetMachine &TM, std::unique_ptr< MCStreamer > Streamer)
Definition MipsAsmPrinter.h:124
void emitConstantPool() override
Print to the current output stream assembly representations of the constants in the constant pool MCP...
Definition MipsAsmPrinter.h:132
void LowerPATCHABLE_FUNCTION_ENTER(const MachineInstr &MI)
MipsMCInstLower MCInstLowering
Definition MipsAsmPrinter.h:122
void LowerPATCHABLE_TAIL_CALL(const MachineInstr &MI)
const MipsSubtarget * Subtarget
Definition MipsAsmPrinter.h:120
const MipsFunctionInfo * MipsFI
Definition MipsAsmPrinter.h:121
void LowerPATCHABLE_FUNCTION_EXIT(const MachineInstr &MI)
StringRef getPassName() const override
getPassName - Return a nice clean name for a pass.
Definition MipsAsmPrinter.h:128
static char ID
Definition MipsAsmPrinter.h:118
MipsFunctionInfo - This class is derived from MachineFunction private Mips target-specific informatio...
MipsMCInstLower - This class is used to lower an MachineInstr into an MCInst.
A Module instance is used to store all the information related to an LLVM module.
StringRef - Represent a constant reference to a string, i.e.
Primary interface to the complete machine description for the target machine.
LLVM Value Representation.
This class implements an extremely fast bulk output stream that can only output to a stream.
This is an optimization pass for GlobalISel generic memory operations.
OutputIt move(R &&Range, OutputIt Out)
Provide wrappers to std::move which take ranges instead of having to pass begin/end explicitly.
Implement std::hash so that hash_code can be used in STL containers.