33 #define DEBUG_TYPE "asm-printer"
38 explicit BPFAsmPrinter(
TargetMachine &
TM, std::unique_ptr<MCStreamer> Streamer)
41 const char *getPassName()
const override {
return "BPF Assembly Printer"; }
44 const char *Modifier =
nullptr);
75 void BPFAsmPrinter::EmitInstruction(
const MachineInstr *MI) {
80 MCInstLowering.Lower(MI, TmpInst);
81 EmitToStreamer(*OutStreamer, TmpInst);
const GlobalValue * getGlobal() const
MachineBasicBlock * getMBB() const
MachineBasicBlock reference.
This file declares the MachineConstantPool class which is an abstract constant pool to keep track of ...
#define llvm_unreachable(msg)
Marks that the current location is not supposed to be reachable.
static void printOperand(raw_ostream &OS, uint8_t Opcode, unsigned OperandIdx, uint64_t Operand, uint64_t CodeAlignmentFactor, int64_t DataAlignmentFactor)
Print Opcode's operand number OperandIdx which has value Operand.
Instances of this class represent a single low-level machine instruction.
Address of a global value.
const MachineOperand & getOperand(unsigned i) const
This class is intended to be used as a driving class for all asm writers.
static GCMetadataPrinterRegistry::Add< ErlangGCPrinter > X("erlang","erlang-compatible garbage collector")
MCSymbol * getSymbol() const
getSymbol - Return the MCSymbol for this basic block.
MachineOperand class - Representation of each machine instruction operand.
static const char * getRegisterName(unsigned RegNo)
Representation of each machine instruction.
MachineOperandType getType() const
getType - Returns the MachineOperandType for this operand.
unsigned getReg() const
getReg - Returns the register number.
RegisterAsmPrinter - Helper template for registering a target specific assembly printer, for use in the target machine initialization function.
This class implements an extremely fast bulk output stream that can only output to a stream...
void LLVMInitializeBPFAsmPrinter()
Primary interface to the complete machine description for the target machine.
static GCMetadataPrinterRegistry::Add< OcamlGCMetadataPrinter > Y("ocaml","ocaml 3.10-compatible collector")