LLVM 20.0.0git
Namespaces | Macros | Functions
RISCVAsmPrinter.cpp File Reference
#include "MCTargetDesc/RISCVBaseInfo.h"
#include "MCTargetDesc/RISCVInstPrinter.h"
#include "MCTargetDesc/RISCVMCExpr.h"
#include "MCTargetDesc/RISCVMatInt.h"
#include "MCTargetDesc/RISCVTargetStreamer.h"
#include "RISCV.h"
#include "RISCVConstantPoolValue.h"
#include "RISCVMachineFunctionInfo.h"
#include "RISCVRegisterInfo.h"
#include "TargetInfo/RISCVTargetInfo.h"
#include "llvm/ADT/APInt.h"
#include "llvm/ADT/Statistic.h"
#include "llvm/BinaryFormat/ELF.h"
#include "llvm/CodeGen/AsmPrinter.h"
#include "llvm/CodeGen/MachineConstantPool.h"
#include "llvm/CodeGen/MachineInstr.h"
#include "llvm/CodeGen/MachineModuleInfo.h"
#include "llvm/IR/Module.h"
#include "llvm/MC/MCAsmInfo.h"
#include "llvm/MC/MCContext.h"
#include "llvm/MC/MCInst.h"
#include "llvm/MC/MCInstBuilder.h"
#include "llvm/MC/MCObjectFileInfo.h"
#include "llvm/MC/MCSectionELF.h"
#include "llvm/MC/MCStreamer.h"
#include "llvm/MC/MCSymbol.h"
#include "llvm/MC/TargetRegistry.h"
#include "llvm/Support/raw_ostream.h"
#include "llvm/TargetParser/RISCVISAInfo.h"
#include "llvm/Transforms/Instrumentation/HWAddressSanitizer.h"
#include "RISCVGenMCPseudoLowering.inc"

Go to the source code of this file.

Namespaces

namespace  llvm
 This is an optimization pass for GlobalISel generic memory operations.
 

Macros

#define DEBUG_TYPE   "asm-printer"
 

Functions

 STATISTIC (RISCVNumInstrsCompressed, "Number of RISC-V Compressed instructions emitted")
 
LLVM_EXTERNAL_VISIBILITY void LLVMInitializeRISCVAsmPrinter ()
 
static MCOperand lowerSymbolOperand (const MachineOperand &MO, MCSymbol *Sym, const AsmPrinter &AP)
 
static bool lowerRISCVVMachineInstrToMCInst (const MachineInstr *MI, MCInst &OutMI)
 

Macro Definition Documentation

◆ DEBUG_TYPE

#define DEBUG_TYPE   "asm-printer"

Definition at line 47 of file RISCVAsmPrinter.cpp.

Function Documentation

◆ LLVMInitializeRISCVAsmPrinter()

LLVM_EXTERNAL_VISIBILITY void LLVMInitializeRISCVAsmPrinter ( )

Definition at line 606 of file RISCVAsmPrinter.cpp.

References llvm::getTheRISCV32Target(), llvm::getTheRISCV64Target(), X, and Y.

◆ lowerRISCVVMachineInstrToMCInst()

static bool lowerRISCVVMachineInstrToMCInst ( const MachineInstr MI,
MCInst OutMI 
)
static

◆ lowerSymbolOperand()

static MCOperand lowerSymbolOperand ( const MachineOperand MO,
MCSymbol Sym,
const AsmPrinter AP 
)
static

Definition at line 941 of file RISCVAsmPrinter.cpp.

References llvm::RISCVMCExpr::create(), llvm::MCSymbolRefExpr::create(), llvm::MCConstantExpr::create(), llvm::MCBinaryExpr::createAdd(), llvm::MCOperand::createExpr(), llvm::MachineOperand::getOffset(), llvm::MachineOperand::getTargetFlags(), llvm::MachineOperand::isJTI(), llvm::MachineOperand::isMBB(), llvm_unreachable, llvm::RISCVII::MO_CALL, llvm::RISCVII::MO_GOT_HI, llvm::RISCVII::MO_HI, llvm::RISCVII::MO_LO, llvm::RISCVII::MO_None, llvm::RISCVII::MO_PCREL_HI, llvm::RISCVII::MO_PCREL_LO, llvm::RISCVII::MO_TLS_GD_HI, llvm::RISCVII::MO_TLS_GOT_HI, llvm::RISCVII::MO_TLSDESC_ADD_LO, llvm::RISCVII::MO_TLSDESC_CALL, llvm::RISCVII::MO_TLSDESC_HI, llvm::RISCVII::MO_TLSDESC_LOAD_LO, llvm::RISCVII::MO_TPREL_ADD, llvm::RISCVII::MO_TPREL_HI, llvm::RISCVII::MO_TPREL_LO, llvm::AsmPrinter::OutContext, Sym, llvm::MCSymbolRefExpr::VK_None, llvm::RISCVMCExpr::VK_RISCV_CALL_PLT, llvm::RISCVMCExpr::VK_RISCV_GOT_HI, llvm::RISCVMCExpr::VK_RISCV_HI, llvm::RISCVMCExpr::VK_RISCV_LO, llvm::RISCVMCExpr::VK_RISCV_None, llvm::RISCVMCExpr::VK_RISCV_PCREL_HI, llvm::RISCVMCExpr::VK_RISCV_PCREL_LO, llvm::RISCVMCExpr::VK_RISCV_TLS_GD_HI, llvm::RISCVMCExpr::VK_RISCV_TLS_GOT_HI, llvm::RISCVMCExpr::VK_RISCV_TLSDESC_ADD_LO, llvm::RISCVMCExpr::VK_RISCV_TLSDESC_CALL, llvm::RISCVMCExpr::VK_RISCV_TLSDESC_HI, llvm::RISCVMCExpr::VK_RISCV_TLSDESC_LOAD_LO, llvm::RISCVMCExpr::VK_RISCV_TPREL_ADD, llvm::RISCVMCExpr::VK_RISCV_TPREL_HI, and llvm::RISCVMCExpr::VK_RISCV_TPREL_LO.

◆ STATISTIC()

STATISTIC ( RISCVNumInstrsCompressed  ,
"Number of RISC-V Compressed instructions emitted"   
)