34 "mips-round-section-sizes",
cl::init(
false),
120 bool SaveLocationIsRegister) {}
198 unsigned Reg2,
SMLoc IDLoc,
204 int16_t Imm,
SMLoc IDLoc,
210 unsigned Reg1, int16_t Imm0, int16_t Imm1,
211 int16_t Imm2,
SMLoc IDLoc,
225 unsigned TrgReg,
bool Is64Bit,
227 emitRRR(Is64Bit ? Mips::DADDu : Mips::ADDu, DstReg, SrcReg, TrgReg,
SMLoc(),
232 int16_t ShiftAmount,
SMLoc IDLoc,
234 if (ShiftAmount >= 32) {
235 emitRRI(Mips::DSLL32, DstReg, SrcReg, ShiftAmount - 32, IDLoc, STI);
239 emitRRI(Mips::DSLL, DstReg, SrcReg, ShiftAmount, IDLoc, STI);
244 if (hasShortDelaySlot)
245 emitRR(Mips::MOVE16_MM, Mips::ZERO, Mips::ZERO, IDLoc, STI);
247 emitRRI(Mips::SLL, Mips::ZERO, Mips::ZERO, 0, IDLoc, STI);
252 if (Features[Mips::FeatureMicroMips])
253 emitRR(Mips::MOVE16_MM, Mips::ZERO, Mips::ZERO, IDLoc, STI);
255 emitRRI(Mips::SLL, Mips::ZERO, Mips::ZERO, 0, IDLoc, STI);
267 unsigned Opcode,
unsigned SrcReg,
unsigned BaseReg, int64_t Offset,
271 emitRRI(Opcode, SrcReg, BaseReg, Offset, IDLoc, STI);
279 unsigned ATReg = GetATReg();
283 unsigned LoOffset = Offset & 0x0000ffff;
284 unsigned HiOffset = (Offset & 0xffff0000) >> 16;
288 if (LoOffset & 0x8000)
292 emitRI(Mips::LUi, ATReg, HiOffset, IDLoc, STI);
293 if (BaseReg != Mips::ZERO)
294 emitRRR(Mips::ADDu, ATReg, ATReg, BaseReg, IDLoc, STI);
296 emitRRI(Opcode, SrcReg, ATReg, LoOffset, IDLoc, STI);
302 unsigned Opcode,
unsigned SrcReg,
unsigned BaseReg,
MCOperand &HiOperand,
309 emitRX(Mips::LUi, ATReg, HiOperand, IDLoc, STI);
310 if (BaseReg != Mips::ZERO)
311 emitRRR(Mips::ADDu, ATReg, ATReg, BaseReg, IDLoc, STI);
313 emitRRX(Opcode, SrcReg, ATReg, LoOperand, IDLoc, STI);
321 unsigned BaseReg, int64_t Offset,
322 unsigned TmpReg,
SMLoc IDLoc,
325 emitRRI(Opcode, DstReg, BaseReg, Offset, IDLoc, STI);
336 unsigned LoOffset = Offset & 0x0000ffff;
337 unsigned HiOffset = (Offset & 0xffff0000) >> 16;
341 if (LoOffset & 0x8000)
345 emitRI(Mips::LUi, TmpReg, HiOffset, IDLoc, STI);
346 if (BaseReg != Mips::ZERO)
347 emitRRR(Mips::ADDu, TmpReg, TmpReg, BaseReg, IDLoc, STI);
349 emitRRI(Opcode, DstReg, TmpReg, LoOffset, IDLoc, STI);
361 unsigned TmpReg,
SMLoc IDLoc,
369 emitRX(Mips::LUi, TmpReg, HiOperand, IDLoc, STI);
370 if (BaseReg != Mips::ZERO)
371 emitRRR(Mips::ADDu, TmpReg, TmpReg, BaseReg, IDLoc, STI);
373 emitRRX(Opcode, DstReg, TmpReg, LoOperand, IDLoc, STI);
381 OS <<
"\t.set\tmicromips\n";
386 OS <<
"\t.set\tnomicromips\n";
391 OS <<
"\t.set\tmips16\n";
396 OS <<
"\t.set\tnomips16\n";
401 OS <<
"\t.set\treorder\n";
406 OS <<
"\t.set\tnoreorder\n";
411 OS <<
"\t.set\tmacro\n";
416 OS <<
"\t.set\tnomacro\n";
421 OS <<
"\t.set\tmsa\n";
426 OS <<
"\t.set\tnomsa\n";
431 OS <<
"\t.set\tmt\n";
436 OS <<
"\t.set\tnomt\n";
441 OS <<
"\t.set\tcrc\n";
446 OS <<
"\t.set\tnocrc\n";
451 OS <<
"\t.set\tvirt\n";
456 OS <<
"\t.set\tnovirt\n";
461 OS <<
"\t.set\tginv\n";
466 OS <<
"\t.set\tnoginv\n";
471 OS <<
"\t.set\tat\n";
476 OS <<
"\t.set\tat=$" <<
Twine(RegNo) <<
"\n";
481 OS <<
"\t.set\tnoat\n";
486 OS <<
"\t.end\t" << Name <<
'\n';
490 OS <<
"\t.ent\t" << Symbol.
getName() <<
'\n';
498 OS <<
"\t.nan\tlegacy\n";
502 OS <<
"\t.option\tpic0\n";
506 OS <<
"\t.option\tpic2\n";
523 OS <<
"\t.set arch=" << Arch <<
"\n";
528 OS <<
"\t.set\tmips0\n";
533 OS <<
"\t.set\tmips1\n";
538 OS <<
"\t.set\tmips2\n";
543 OS <<
"\t.set\tmips3\n";
548 OS <<
"\t.set\tmips4\n";
553 OS <<
"\t.set\tmips5\n";
558 OS <<
"\t.set\tmips32\n";
563 OS <<
"\t.set\tmips32r2\n";
568 OS <<
"\t.set\tmips32r3\n";
573 OS <<
"\t.set\tmips32r5\n";
578 OS <<
"\t.set\tmips32r6\n";
583 OS <<
"\t.set\tmips64\n";
588 OS <<
"\t.set\tmips64r2\n";
593 OS <<
"\t.set\tmips64r3\n";
598 OS <<
"\t.set\tmips64r5\n";
603 OS <<
"\t.set\tmips64r6\n";
608 OS <<
"\t.set\tdsp\n";
613 OS <<
"\t.set\tdspr2\n";
618 OS <<
"\t.set\tnodsp\n";
623 OS <<
"\t.set\tpop\n";
628 OS <<
"\t.set\tpush\n";
633 OS <<
"\t.set\tsoftfloat\n";
638 OS <<
"\t.set\thardfloat\n";
645 for (
int i = 7; i >= 0; i--)
646 OS.
write_hex((Value & (0xF << (i * 4))) >> (i * 4));
650 int CPUTopSavedRegOff) {
653 OS <<
',' << CPUTopSavedRegOff <<
'\n';
657 int FPUTopSavedRegOff) {
660 OS <<
"," << FPUTopSavedRegOff <<
'\n';
673 OS <<
"\t.cprestore\t" << Offset <<
"\n";
681 OS <<
"\t.cpsetup\t$" 697 bool SaveLocationIsRegister) {
705 OS <<
"\t.module\tsoftfloat\n";
726 OS <<
"\t.set\toddspreg\n";
731 OS <<
"\t.set\tnooddspreg\n";
735 OS <<
"\t.module\tsoftfloat\n";
739 OS <<
"\t.module\thardfloat\n";
743 OS <<
"\t.module\tmt\n";
747 OS <<
"\t.module\tcrc\n";
751 OS <<
"\t.module\tnocrc\n";
755 OS <<
"\t.module\tvirt\n";
759 OS <<
"\t.module\tnovirt\n";
763 OS <<
"\t.module\tginv\n";
767 OS <<
"\t.module\tnoginv\n";
812 if (Features[Mips::FeatureMips64r6])
814 else if (Features[Mips::FeatureMips64r2] ||
815 Features[Mips::FeatureMips64r3] ||
816 Features[Mips::FeatureMips64r5])
818 else if (Features[Mips::FeatureMips64])
820 else if (Features[Mips::FeatureMips5])
822 else if (Features[Mips::FeatureMips4])
824 else if (Features[Mips::FeatureMips3])
826 else if (Features[Mips::FeatureMips32r6])
828 else if (Features[Mips::FeatureMips32r2] ||
829 Features[Mips::FeatureMips32r3] ||
830 Features[Mips::FeatureMips32r5])
832 else if (Features[Mips::FeatureMips32])
834 else if (Features[Mips::FeatureMips2])
840 if (Features[Mips::FeatureCnMips])
844 if (Features[Mips::FeatureNaN2008])
851 auto *
Symbol = cast<MCSymbolELF>(S);
877 if (RoundSectionSizes) {
907 else if (
getABI().IsN32())
910 if (Features[Mips::FeatureGP64Bit]) {
913 }
else if (Features[Mips::FeatureMips64r2] || Features[Mips::FeatureMips64])
918 if (!Features[Mips::FeatureNoABICalls])
936 auto *
Symbol = cast<MCSymbolELF>(S);
940 const auto &RhsSym = cast<MCSymbolELF>(
954 MicroMipsEnabled =
true;
959 MicroMipsEnabled =
false;
1091 unsigned ReturnReg_) {
1102 int CPUTopSavedRegOff) {
1109 int FPUTopSavedRegOff) {
1209 emitRRR(Mips::OR64, RegOrOffset, Mips::GP, Mips::ZERO,
SMLoc(), &STI);
1212 emitRRI(Mips::SD, Mips::GP, Mips::SP, RegOrOffset,
SMLoc(), &STI);
1249 emitRRR(Mips::DADDu, Mips::GP, Mips::GP, RegNo,
SMLoc(), &STI);
1253 bool SaveLocationIsRegister) {
1260 if (SaveLocationIsRegister) {
void emitDirectiveSetDsp() override
void emitDirectiveEnd(StringRef Name) override
virtual void emitFMask(unsigned FPUBitmask, int FPUTopSavedRegOff)
void emitRR(unsigned Opcode, unsigned Reg0, unsigned Reg1, SMLoc IDLoc, const MCSubtargetInfo *STI)
void emitDirectiveSetMips3() override
void emitMask(unsigned CPUBitmask, int CPUTopSavedRegOff) override
void emitDirectiveModuleMT() override
void setELFHeaderEFlags(unsigned Flags)
Instances of this class represent a uniqued identifier for a section in the current translation unit...
virtual void emitDirectiveModuleGINV()
void emitDirectiveModuleSoftFloat() override
void emitRRIII(unsigned Opcode, unsigned Reg0, unsigned Reg1, int16_t Imm0, int16_t Imm1, int16_t Imm2, SMLoc IDLoc, const MCSubtargetInfo *STI)
void emitDirectiveSetCRC() override
void emitDirectiveCpsetup(unsigned RegNo, int RegOrOffset, const MCSymbol &Sym, bool IsReg) override
void emitDirectiveSetDspr2() override
virtual void emitDirectiveModuleCRC()
void emitMask(unsigned CPUBitmask, int CPUTopSavedRegOff) override
GCNRegPressure max(const GCNRegPressure &P1, const GCNRegPressure &P2)
bool UseCodeAlign() const override
Return true if a .align directive should use "optimized nops" to fill instead of 0s.
virtual void emitDirectiveOptionPic2()
static const MCSymbolRefExpr * create(const MCSymbol *Symbol, MCContext &Ctx)
void emitDirectiveOptionPic2() override
LLVM_ATTRIBUTE_NORETURN void report_fatal_error(Error Err, bool gen_crash_diag=true)
Report a serious error, calling any installed error handler.
This class represents lattice values for constants.
void emitDirectiveSetMips2() override
void emitDirectiveModuleNoCRC() override
void emitDirectiveModuleNoGINV() override
MCSymbol - Instances of this class represent a symbol name in the MC file, and MCSymbols are created ...
void emitDirectiveSetReorder() override
void emitDirectiveSetNoMicroMips() override
static MCOperand createExpr(const MCExpr *Val)
void emitDirectiveSetMt() override
void emitAddu(unsigned DstReg, unsigned SrcReg, unsigned TrgReg, bool Is64Bit, const MCSubtargetInfo *STI)
Target specific streamer interface.
void emitDirectiveCpreturn(unsigned SaveLocation, bool SaveLocationIsRegister) override
void setAlignment(unsigned Value)
void emitDirectiveSetOddSPReg() override
void emitDirectiveNaN2008() override
const FeatureBitset Features
An efficient, type-erasing, non-owning reference to a callable.
void emitDirectiveOptionPic0() override
virtual void emitDirectiveSetNoReorder()
void emitDirectiveModuleFP() override
virtual void emitDirectiveModuleHardFloat()
void registerSymbol(const MCSymbol &Symbol, bool *Created=nullptr)
void PushSection()
Save the current and previous section on the section stack.
virtual void emitDirectiveModuleNoGINV()
void emitDirectiveSetFp(MipsABIFlagsSection::FpABIKind Value) override
constexpr bool isInt< 16 >(int64_t x)
void emitGPRestore(int Offset, SMLoc IDLoc, const MCSubtargetInfo *STI)
Emit the $gp restore operation for .cprestore.
block Block Frequency true
void emitDirectiveSetMips32R6() override
virtual void EmitValueImpl(const MCExpr *Value, unsigned Size, SMLoc Loc=SMLoc())
Emit the expression Value into the output as a native integer of the given Size bytes.
MipsTargetAsmStreamer(MCStreamer &S, formatted_raw_ostream &OS)
bool emitDirectiveCpRestore(int Offset, function_ref< unsigned()> GetATReg, SMLoc IDLoc, const MCSubtargetInfo *STI) override
Emit a .cprestore directive.
void emitDirectiveCpLoad(unsigned RegNo) override
virtual void EmitInstruction(const MCInst &Inst, const MCSubtargetInfo &STI, bool PrintSchedInfo=false)
Emit the given Instruction into the current section.
virtual void emitDirectiveSetVirt()
const Triple & getTargetTriple() const
void emitDirectiveSetVirt() override
unsigned getAlignment() const
virtual void emitDirectiveSetMips32R3()
const MipsABIInfo & getABI() const
MCContext & getContext() const
virtual void emitDirectiveSetMicroMips()
void emitDirectiveSetNoMt() override
virtual void emitDirectiveSetMips3()
void emitDirectiveSetAt() override
amdgpu Simplify well known AMD library false Value Value const Twine & Name
void emitDirectiveSetPop() override
void emitDirectiveSetMips4() override
void emitFrame(unsigned StackReg, unsigned StackSize, unsigned ReturnReg) override
static MCOperand createReg(unsigned Reg)
Twine - A lightweight data structure for efficiently representing the concatenation of temporary valu...
virtual void emitDirectiveModuleMT()
void emitLoadWithImmOffset(unsigned Opcode, unsigned DstReg, unsigned BaseReg, int64_t Offset, unsigned TmpReg, SMLoc IDLoc, const MCSubtargetInfo *STI)
Emit a load instruction with an immediate offset.
void emitDirectiveAbiCalls() override
const FeatureBitset & getFeatureBits() const
void emitDirectiveSetMicroMips() override
virtual void emitFrame(unsigned StackReg, unsigned StackSize, unsigned ReturnReg)
virtual void emitDirectiveSetMips0()
void emitDirectiveSetNoAt() override
virtual void emitDirectiveSetSoftFloat()
virtual void emitDirectiveSetNoMacro()
void emitDirectiveSetMsa() override
Base class for the full range of assembler expressions which are needed for parsing.
virtual void emitDirectiveSetPush()
bool registerSection(MCSection &Section)
virtual void emitDirectiveEnd(StringRef Name)
Represent a reference to a symbol from inside an expression.
MCSection * getBSSSection() const
MCSection * getDataSection() const
void emitDirectiveSetNoGINV() override
virtual void emitDirectiveSetMips32R6()
void emitDirectiveSetMips1() override
void emitDirectiveSetNoCRC() override
void createPendingLabelRelocs()
Mark labels as microMIPS, if necessary for the subtarget.
void emitFMask(unsigned FPUBitmask, int FPUTopSavedRegOff) override
virtual void emitDirectiveSetMips1()
virtual void emitDirectiveModuleOddSPReg()
Context object for machine code objects.
void emitNop(SMLoc IDLoc, const MCSubtargetInfo *STI)
void emitDirectiveModuleVirt() override
virtual void emitDirectiveModuleSoftFloat()
static const MCBinaryExpr * createSub(const MCExpr *LHS, const MCExpr *RHS, MCContext &Ctx)
ArchType getArch() const
getArch - Get the parsed architecture type of this triple.
void emitDirectiveSetSoftFloat() override
MipsABIFlagsSection ABIFlagsSection
raw_ostream & write_hex(unsigned long long N)
Output N in hexadecimal, without any prefix or padding.
void emitDirectiveSetMips32R2() override
virtual void emitDirectiveModuleFP()
void emitDirectiveSetMips5() override
void emitDirectiveSetMips0() override
void emitLabel(MCSymbol *Symbol) override
virtual void emitDirectiveSetOddSPReg()
virtual void emitDirectiveSetMips64R2()
virtual void EmitIntValue(uint64_t Value, unsigned Size)
Special case of EmitValue that avoids the client having to pass in a MCExpr for constant integers...
virtual void emitDirectiveSetNoOddSPReg()
void emitDirectiveCpsetup(unsigned RegNo, int RegOrOffset, const MCSymbol &Sym, bool IsReg) override
Expected< const typename ELFT::Sym * > getSymbol(typename ELFT::SymRange Symbols, uint32_t Index)
Instances of this class represent a single low-level machine instruction.
void emitRX(unsigned Opcode, unsigned Reg0, MCOperand Op1, SMLoc IDLoc, const MCSubtargetInfo *STI)
MCRegisterInfo base class - We assume that the target defines a static array of MCRegisterDesc object...
virtual void setUsesMicroMips()
void emitDirectiveSetMips16() override
initializer< Ty > init(const Ty &Val)
void emitDirectiveNaNLegacy() override
void emitDirectiveSetHardFloat() override
void emitDirectiveSetMips32R3() override
Streaming machine code generation interface.
void emitDirectiveSetMips64() override
MCSymbol * createTempSymbol(bool CanBeUnnamed=true)
Create and return a new assembler temporary symbol with a unique but unspecified name.
virtual void emitDirectiveSetMips4()
Container class for subtarget features.
static const MipsMCExpr * createGpOff(MipsExprKind Kind, const MCExpr *Expr, MCContext &Ctx)
static bool hasShortDelaySlot(MCInst &Inst)
The instances of the Type class are immutable: once they are created, they are never changed...
virtual void emitDirectiveSetNoMicroMips()
virtual void emitDirectiveSetNoDsp()
StringRef getFpABIString(FpABIKind Value)
void emitDirectiveModuleNoVirt() override
virtual void emitDirectiveModuleVirt()
void emitDirectiveSetNoReorder() override
virtual void emitDirectiveSetMips16()
virtual void SwitchSection(MCSection *Section, const MCExpr *Subsection=nullptr)
Set the current section where code is being emitted to Section.
MCAssembler & getAssembler()
static ManagedStatic< OptionRegistry > OR
virtual void emitDirectiveSetMacro()
void emitDirectiveCpreturn(unsigned SaveLocation, bool SaveLocationIsRegister) override
virtual void emitDirectiveNaN2008()
void emitDirectiveSetGINV() override
void emitRI(unsigned Opcode, unsigned Reg0, int32_t Imm, SMLoc IDLoc, const MCSubtargetInfo *STI)
virtual void emitDirectiveCpLoad(unsigned RegNo)
virtual void EmitValueToAlignment(unsigned ByteAlignment, int64_t Value=0, unsigned ValueSize=1, unsigned MaxBytesToEmit=0)
Emit some number of copies of Value until the byte alignment ByteAlignment is reached.
void emitR(unsigned Opcode, unsigned Reg0, SMLoc IDLoc, const MCSubtargetInfo *STI)
const MCObjectFileInfo * getObjectFileInfo() const
virtual void emitDirectiveSetCRC()
virtual void emitDirectiveSetArch(StringRef Arch)
void emitDirectiveSetMips32() override
virtual void emitDirectiveSetDsp()
virtual void emitMask(unsigned CPUBitmask, int CPUTopSavedRegOff)
void emitDirectiveSetMips64R2() override
unsigned getELFHeaderEFlags() const
ELF e_header flags.
virtual void emitDirectiveSetNoCRC()
void emitDirectiveSetMacro() override
virtual void emitDirectiveSetMips32R5()
bool isMicroMipsEnabled() const
void emitDirectiveSetNoMsa() override
void emitDirectiveSetMips64R3() override
virtual void emitDirectiveSetMips32R2()
void emitLoadWithSymOffset(unsigned Opcode, unsigned DstReg, unsigned BaseReg, MCOperand &HiOperand, MCOperand &LoOperand, unsigned ATReg, SMLoc IDLoc, const MCSubtargetInfo *STI)
Emit a load instruction with an symbol offset.
void emitDirectiveSetMips16() override
virtual void emitDirectiveSetFp(MipsABIFlagsSection::FpABIKind Value)
void emitRRR(unsigned Opcode, unsigned Reg0, unsigned Reg1, unsigned Reg2, SMLoc IDLoc, const MCSubtargetInfo *STI)
virtual void emitDirectiveAbiCalls()
void emitFMask(unsigned FPUBitmask, int FPUTopSavedRegOff) override
virtual void emitDirectiveSetMips64R6()
void emitDirectiveEnt(const MCSymbol &Symbol) override
MCStreamer & getStreamer()
void emitDirectiveEnt(const MCSymbol &Symbol) override
virtual void emitDirectiveModuleNoVirt()
void setOpcode(unsigned Op)
void emitDirectiveModuleCRC() override
virtual void emitDirectiveOptionPic0()
void emitDSLL(unsigned DstReg, unsigned SrcReg, int16_t ShiftAmount, SMLoc IDLoc, const MCSubtargetInfo *STI)
void emitAssignment(MCSymbol *Symbol, const MCExpr *Value) override
virtual void emitDirectiveSetNoGINV()
virtual void EmitCodeAlignment(unsigned ByteAlignment, unsigned MaxBytesToEmit=0)
Emit nops until the byte alignment ByteAlignment is reached.
virtual void emitDirectiveSetPop()
void emitDirectiveSetMips32R5() override
void emitEmptyDelaySlot(bool hasShortDelaySlot, SMLoc IDLoc, const MCSubtargetInfo *STI)
void emitDirectiveInsn() override
virtual void emitDirectiveSetAt()
virtual void emitDirectiveSetNoMips16()
void emitDirectiveSetNoOddSPReg() override
void emitDirectiveSetAtWithArg(unsigned RegNo) override
void emitDirectiveEnd(StringRef Name) override
MipsTargetELFStreamer(MCStreamer &S, const MCSubtargetInfo &STI)
virtual void emitDirectiveInsn()
void setUsesMicroMips() override
void EmitMipsOptionRecords()
Emits all the option records stored up until the point it's called.
void emitDirectiveSetNoDsp() override
virtual void emitDirectiveCpsetup(unsigned RegNo, int RegOrOffset, const MCSymbol &Sym, bool IsReg)
static const MipsMCExpr * create(MipsExprKind Kind, const MCExpr *Expr, MCContext &Ctx)
virtual void emitDirectiveSetNoVirt()
void emitDirectiveSetMips64R5() override
void emitStoreWithImmOffset(unsigned Opcode, unsigned SrcReg, unsigned BaseReg, int64_t Offset, function_ref< unsigned()> GetATReg, SMLoc IDLoc, const MCSubtargetInfo *STI)
Emit a store instruction with an offset.
virtual void emitDirectiveSetMips64R3()
virtual void emitDirectiveSetMips64R5()
void emitDirectiveCpLoad(unsigned RegNo) override
virtual void emitDirectiveEnt(const MCSymbol &Symbol)
uint16_t getEncodingValue(unsigned RegNo) const
Returns the encoding for RegNo.
virtual void emitDirectiveSetHardFloat()
MCSymbol * getOrCreateSymbol(const Twine &Name)
Lookup the symbol inside with the specified Name.
virtual void emitDirectiveSetMips64()
MCELFStreamer & getStreamer()
virtual bool emitDirectiveCpRestore(int Offset, function_ref< unsigned()> GetATReg, SMLoc IDLoc, const MCSubtargetInfo *STI)
virtual void emitDirectiveSetDspr2()
virtual void emitDirectiveSetMips5()
void emitDirectiveSetNoMips16() override
void emitDirectiveOptionPic2() override
virtual void emitDirectiveSetMips2()
Generic base class for all target subtargets.
This represents a section on linux, lots of unix variants and some bare metal systems.
References to labels and assigned expressions.
void emitDirectiveSetNoMacro() override
MipsTargetStreamer(MCStreamer &S)
void emitDirectiveSetNoMicroMips() override
void emitFrame(unsigned StackReg, unsigned StackSize, unsigned ReturnReg) override
void emitDirectiveSetMips64R6() override
virtual void emitDirectiveSetMt()
void emitDirectiveSetArch(StringRef Arch) override
void emitDirectiveModuleOddSPReg() override
void emitDirectiveAbiCalls() override
StringRef getName() const
getName - Get the symbol name.
void emitRRI(unsigned Opcode, unsigned Reg0, unsigned Reg1, int16_t Imm, SMLoc IDLoc, const MCSubtargetInfo *STI)
LLVM_NODISCARD std::string lower() const
void emitRRX(unsigned Opcode, unsigned Reg0, unsigned Reg1, MCOperand Op2, SMLoc IDLoc, const MCSubtargetInfo *STI)
MCSection * getTextSection() const
virtual void emitDirectiveSetNoMt()
bool PopSection()
Restore the current and previous section from the section stack.
MCSectionELF * getELFSection(const Twine &Section, unsigned Type, unsigned Flags)
virtual void emitDirectiveSetReorder()
static const char * getRegisterName(unsigned RegNo)
const MCRegisterInfo * getRegisterInfo() const
LLVM Value Representation.
void forbidModuleDirective()
virtual void emitDirectiveCpreturn(unsigned SaveLocation, bool SaveLocationIsRegister)
llvm::Optional< MipsABIInfo > ABI
virtual void emitDirectiveNaNLegacy()
virtual void EmitLabel(MCSymbol *Symbol, SMLoc Loc=SMLoc())
Emit a label for Symbol into the current section.
void emitII(unsigned Opcode, int16_t Imm1, int16_t Imm2, SMLoc IDLoc, const MCSubtargetInfo *STI)
void emitDirectiveSetNoReorder() override
This class implements an extremely fast bulk output stream that can only output to a stream...
virtual void emitDirectiveSetMips32()
virtual void emitDirectiveSetNoMsa()
void addOperand(const MCOperand &Op)
StringRef - Represent a constant reference to a string, i.e.
void emitDirectiveNaN2008() override
virtual void emitDirectiveModuleNoCRC()
bool isPositionIndependent() const
virtual void emitDirectiveSetMsa()
static void printHex32(unsigned Value, raw_ostream &OS)
virtual void emitDirectiveSetNoAt()
Represents a location in source code.
Instances of this class represent operands of the MCInst class.
virtual void emitDirectiveSetGINV()
bool emitDirectiveCpRestore(int Offset, function_ref< unsigned()> GetATReg, SMLoc IDLoc, const MCSubtargetInfo *STI) override
virtual void emitDirectiveSetAtWithArg(unsigned RegNo)
static MCOperand createImm(int64_t Val)
void emitDirectiveModuleGINV() override
void emitDirectiveInsn() override
void emitDirectiveSetPush() override
void emitDirectiveSetNoVirt() override
void emitDirectiveModuleHardFloat() override
void emitDirectiveNaNLegacy() override
void emitStoreWithSymOffset(unsigned Opcode, unsigned SrcReg, unsigned BaseReg, MCOperand &HiOperand, MCOperand &LoOperand, unsigned ATReg, SMLoc IDLoc, const MCSubtargetInfo *STI)
Emit a store instruction with an symbol offset.
void emitDirectiveOptionPic0() override
void emitDirectiveSetMicroMips() override
void EmitInstruction(const MCInst &Inst, const MCSubtargetInfo &STI, bool=false) override
Emit the given Instruction into the current section.