Go to the documentation of this file.
9 #ifndef LLVM_LIB_TARGET_X86_X86ASMPRINTER_H
10 #define LLVM_LIB_TARGET_X86_X86ASMPRINTER_H
30 std::unique_ptr<MCCodeEmitter> CodeEmitter;
31 bool EmitFPOData =
false;
32 bool ShouldEmitWeakSwiftAsyncExtendedFramePointerFlags =
false;
33 bool IndCSPrefix =
false;
43 class StackMapShadowTracker {
52 void reset(
unsigned RequiredSize) {
53 RequiredShadowSize = RequiredSize;
54 CurrentShadowSize = 0;
63 bool InShadow =
false;
70 unsigned RequiredShadowSize = 0, CurrentShadowSize = 0;
73 StackMapShadowTracker SMShadowTracker;
81 void EmitAndCountInstruction(
MCInst &Inst);
83 void LowerPATCHPOINT(
const MachineInstr &
MI, X86MCInstLower &MCIL);
84 void LowerSTATEPOINT(
const MachineInstr &
MI, X86MCInstLower &MCIL);
85 void LowerFAULTING_OP(
const MachineInstr &
MI, X86MCInstLower &MCIL);
86 void LowerPATCHABLE_OP(
const MachineInstr &
MI, X86MCInstLower &MCIL);
88 void LowerTlsAddr(X86MCInstLower &MCInstLowering,
const MachineInstr &
MI);
92 X86MCInstLower &MCIL);
93 void LowerPATCHABLE_RET(
const MachineInstr &
MI, X86MCInstLower &MCIL);
94 void LowerPATCHABLE_TAIL_CALL(
const MachineInstr &
MI, X86MCInstLower &MCIL);
95 void LowerPATCHABLE_EVENT_CALL(
const MachineInstr &
MI, X86MCInstLower &MCIL);
97 X86MCInstLower &MCIL);
99 void LowerFENTRY_CALL(
const MachineInstr &
MI, X86MCInstLower &MCIL);
103 void EmitKCFITypePadding(
const MachineFunction &MF,
bool HasType =
true);
120 const char *Modifier);
121 void PrintIntelMemReference(
const MachineInstr *
MI,
unsigned OpNo,
128 return "X86 Assembly Printer";
133 void emitStartOfAsmFile(
Module &M)
override;
135 void emitEndOfAsmFile(
Module &M)
override;
147 SMShadowTracker.reset(0);
154 void emitFunctionBodyStart()
override;
155 void emitFunctionBodyEnd()
override;
159 return ShouldEmitWeakSwiftAsyncExtendedFramePointerFlags;
This is an optimization pass for GlobalISel generic memory operations.
We currently emits eax Perhaps this is what we really should generate is Is imull three or four cycles eax eax The current instruction priority is based on pattern complexity The former is more complex because it folds a load so the latter will not be emitted Perhaps we should use AddedComplexity to give LEA32r a higher priority We should always try to match LEA first since the LEA matching code does some estimate to determine whether the match is profitable if we care more about code then imull is better It s two bytes shorter than movl leal On a Pentium M
Instances of this class represent a single low-level machine instruction.
StringRef getPassName() const override
getPassName - Return a nice clean name for a pass.
Streaming machine code generation interface.
bool shouldEmitWeakSwiftAsyncExtendedFramePointerFlags() const override
MachineOperand class - Representation of each machine instruction operand.
This class implements an extremely fast bulk output stream that can only output to a stream.
auto count(R &&Range, const E &Element)
Wrapper function around std::count to count the number of times an element Element occurs in the give...
Representation of each machine instruction.
Primary interface to the complete machine description for the target machine.
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.
#define LLVM_LIBRARY_VISIBILITY
LLVM_LIBRARY_VISIBILITY - If a class marked with this attribute is linked into a shared library,...
bool doInitialization(Module &M) override
Set up the AsmPrinter when we are working on a new module.
MCCodeEmitter - Generic instruction encoding interface.
This class is intended to be used as a driving class for all asm writers.
const X86Subtarget & getSubtarget() const
const char LLVMTargetMachineRef TM
Generic base class for all target subtargets.
LLVM Value Representation.
bool doInitialization(Module &M) override
Set up the AsmPrinter when we are working on a new module.