15 #ifndef LLVM_LIB_TARGET_AMDGPU_AMDGPUASMPRINTER_H
16 #define LLVM_LIB_TARGET_AMDGPU_AMDGPUASMPRINTER_H
28 struct SIProgramInfo {
46 NumSGPRsForWavesPerEU(0),
47 NumVGPRsForWavesPerEU(0),
50 DebuggerWavefrontPrivateSegmentOffsetSGPR((uint16_t)-1),
51 DebuggerPrivateSegmentBufferSGPR((uint16_t)-1),
66 uint64_t ComputePGMRSrc1;
72 uint64_t ComputePGMRSrc2;
87 uint16_t ReservedVGPRFirst;
90 uint16_t ReservedVGPRCount;
94 uint16_t DebuggerWavefrontPrivateSegmentOffsetSGPR;
99 uint16_t DebuggerPrivateSegmentBufferSGPR;
109 unsigned &NumVGPR)
const;
114 void EmitProgramInfoSI(
const MachineFunction &MF,
const SIProgramInfo &KernelInfo);
116 const SIProgramInfo &KernelInfo)
const;
120 std::unique_ptr<MCStreamer> Streamer);
150 unsigned AsmVariant,
const char *ExtraCode,
void EmitGlobalVariable(const GlobalVariable *GV) override
Emit the specified global variable to the .s file.
bool lowerOperand(const MachineOperand &MO, MCOperand &MCOp) const
Wrapper for MCInstLowering.lowerOperand() for the tblgen'erated pseudo lowering.
std::unique_ptr< MCStreamer > OutStreamer
This is the MCStreamer object for the file we are generating.
A Module instance is used to store all the information related to an LLVM module. ...
bool emitPseudoExpansionLowering(MCStreamer &OutStreamer, const MachineInstr *MI)
tblgen'erated driver function for lowering simple MI->MC pseudo instructions.
const MachineFunction * MF
The current machine function.
AMDGPUAsmPrinter(TargetMachine &TM, std::unique_ptr< MCStreamer > Streamer)
void EmitInstruction(const MachineInstr *MI) override
Implemented in AMDGPUMCInstLower.cpp.
bool isBlockOnlyReachableByFallthrough(const MachineBasicBlock *MBB) const override
Return true if the basic block has exactly one predecessor and the control transfer mechanism between...
Streaming machine code generation interface.
bool PrintAsmOperand(const MachineInstr *MI, unsigned OpNo, unsigned AsmVariant, const char *ExtraCode, raw_ostream &O) override
Print the specified operand of MI, an INLINEASM instruction, using the specified assembler variant...
TargetMachine & TM
Target machine description.
This class is intended to be used as a driving class for all asm writers.
std::vector< std::string > HexLines
MachineOperand class - Representation of each machine instruction operand.
bool runOnMachineFunction(MachineFunction &MF) override
Emit the specified function out to the OutStreamer.
std::vector< std::string > DisasmLines
void EmitFunctionEntryLabel() override
EmitFunctionEntryLabel - Emit the label that is the entrypoint for the function.
Representation of each machine instruction.
void EmitFunctionBodyStart() override
Targets can override this to emit stuff before the first basic block in the function.
StringRef getPassName() const override
getPassName - Return a nice clean name for a pass.
void EmitStartOfAsmFile(Module &M) override
This virtual method can be overridden by targets that want to emit something at the start of their fi...
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.
Instances of this class represent operands of the MCInst class.