9 #ifndef LLVM_LIB_TARGET_X86_X86ASMPRINTER_H 10 #define LLVM_LIB_TARGET_X86_X86ASMPRINTER_H 32 std::unique_ptr<MCCodeEmitter> CodeEmitter;
33 bool EmitFPOData =
false;
34 bool NeedsRetpoline =
false;
44 class StackMapShadowTracker {
53 void reset(
unsigned RequiredSize) {
54 RequiredShadowSize = RequiredSize;
55 CurrentShadowSize = 0;
64 bool InShadow =
false;
71 unsigned RequiredShadowSize = 0, CurrentShadowSize = 0;
74 StackMapShadowTracker SMShadowTracker;
82 void EmitAndCountInstruction(
MCInst &Inst);
84 void LowerPATCHPOINT(
const MachineInstr &MI, X86MCInstLower &MCIL);
85 void LowerSTATEPOINT(
const MachineInstr &MI, X86MCInstLower &MCIL);
86 void LowerFAULTING_OP(
const MachineInstr &MI, X86MCInstLower &MCIL);
87 void LowerPATCHABLE_OP(
const MachineInstr &MI, X86MCInstLower &MCIL);
89 void LowerTlsAddr(X86MCInstLower &MCInstLowering,
const MachineInstr &MI);
92 void LowerPATCHABLE_FUNCTION_ENTER(
const MachineInstr &MI,
93 X86MCInstLower &MCIL);
94 void LowerPATCHABLE_RET(
const MachineInstr &MI, X86MCInstLower &MCIL);
95 void LowerPATCHABLE_TAIL_CALL(
const MachineInstr &MI, X86MCInstLower &MCIL);
96 void LowerPATCHABLE_EVENT_CALL(
const MachineInstr &MI, X86MCInstLower &MCIL);
97 void LowerPATCHABLE_TYPED_EVENT_CALL(
const MachineInstr &MI,
98 X86MCInstLower &MCIL);
100 void LowerFENTRY_CALL(
const MachineInstr &MI, X86MCInstLower &MCIL);
107 void PrintModifiedOperand(
const MachineInstr *MI,
unsigned OpNo,
110 void PrintLeaMemReference(
const MachineInstr *MI,
unsigned OpNo,
113 const char *Modifier);
114 void PrintIntelMemReference(
const MachineInstr *MI,
unsigned OpNo,
121 return "X86 Assembly Printer";
126 void EmitStartOfAsmFile(
Module &M)
override;
128 void EmitEndOfAsmFile(
Module &M)
override;
133 AsmPrinter::EmitBasicBlockEnd(MBB);
134 SMShadowTracker.emitShadowPadding(*OutStreamer, getSubtargetInfo());
137 bool PrintAsmOperand(
const MachineInstr *MI,
unsigned OpNo,
139 bool PrintAsmMemoryOperand(
const MachineInstr *MI,
unsigned OpNo,
143 SMShadowTracker.reset(0);
146 return AsmPrinter::doInitialization(M);
150 void EmitFunctionBodyStart()
override;
151 void EmitFunctionBodyEnd()
override;
This class represents lattice values for constants.
A Module instance is used to store all the information related to an LLVM module. ...
bool doInitialization(Module &M) override
Set up the AsmPrinter when we are working on a new module.
Instances of this class represent a single low-level machine instruction.
auto count(R &&Range, const E &Element) -> typename std::iterator_traits< decltype(adl_begin(Range))>::difference_type
Wrapper function around std::count to count the number of times an element Element occurs in the give...
Streaming machine code generation interface.
MCCodeEmitter - Generic instruction encoding interface.
This class is intended to be used as a driving class for all asm writers.
#define LLVM_LIBRARY_VISIBILITY
LLVM_LIBRARY_VISIBILITY - If a class marked with this attribute is linked into a shared library...
MachineOperand class - Representation of each machine instruction operand.
StringRef getPassName() const override
getPassName - Return a nice clean name for a pass.
Representation of each machine instruction.
void EmitBasicBlockEnd(const MachineBasicBlock &MBB) override
Targets can override this to emit stuff at the end of a basic block.
Generic base class for all target subtargets.
This class implements an extremely fast bulk output stream that can only output to a stream...
Primary interface to the complete machine description for the target machine.
StringRef - Represent a constant reference to a string, i.e.
const X86Subtarget & getSubtarget() const