| 
    LLVM 22.0.0git
    
   | 
 
#include "RISCVAsmBackend.h"#include "RISCVFixupKinds.h"#include "llvm/ADT/APInt.h"#include "llvm/MC/MCAsmInfo.h"#include "llvm/MC/MCAssembler.h"#include "llvm/MC/MCContext.h"#include "llvm/MC/MCELFObjectWriter.h"#include "llvm/MC/MCExpr.h"#include "llvm/MC/MCObjectWriter.h"#include "llvm/MC/MCSymbol.h"#include "llvm/MC/MCValue.h"#include "llvm/Support/CommandLine.h"#include "llvm/Support/EndianStream.h"#include "llvm/Support/ErrorHandling.h"#include "llvm/Support/LEB128.h"#include "llvm/Support/raw_ostream.h"#include "llvm/BinaryFormat/ELFRelocs/RISCV.def"#include "llvm/BinaryFormat/ELFRelocs/RISCV_nonstandard.def"Go to the source code of this file.
Macros | |
| #define | ELF_RELOC(NAME, ID) | 
| #define | ELF_RISCV_NONSTANDARD_RELOC(_VENDOR, NAME, ID) | 
Functions | |
| static unsigned | getRelaxedOpcode (unsigned Opcode, ArrayRef< MCOperand > Operands, const MCSubtargetInfo &STI) | 
| static uint64_t | adjustFixupValue (const MCFixup &Fixup, uint64_t Value, MCContext &Ctx) | 
| static const MCFixup * | getPCRelHiFixup (const MCSpecifierExpr &Expr, const MCFragment **DFOut) | 
| static bool | relaxableFixupNeedsRelocation (const MCFixupKind Kind) | 
| static bool | isDataFixup (unsigned Kind) | 
Variables | |
| static cl::opt< bool > | ULEB128Reloc ("riscv-uleb128-reloc", cl::init(true), cl::Hidden, cl::desc("Emit R_RISCV_SET_ULEB128/E_RISCV_SUB_ULEB128 if appropriate")) | 
| static cl::opt< bool > | AlignRvc ("riscv-align-rvc", cl::init(true), cl::Hidden, cl::desc("When generating R_RISCV_ALIGN, insert $alignment-2 " "bytes of NOPs even in norvc code")) | 
| #define ELF_RELOC | ( | NAME, | |
| ID ) | 
| #define ELF_RISCV_NONSTANDARD_RELOC | ( | _VENDOR, | |
| NAME, | |||
| ID ) | 
Definition at line 496 of file RISCVAsmBackend.cpp.
References Fixup, llvm::RISCV::fixup_riscv_12_i, llvm::RISCV::fixup_riscv_branch, llvm::RISCV::fixup_riscv_call, llvm::RISCV::fixup_riscv_call_plt, llvm::RISCV::fixup_riscv_hi20, llvm::RISCV::fixup_riscv_jal, llvm::RISCV::fixup_riscv_lo12_i, llvm::RISCV::fixup_riscv_lo12_s, llvm::RISCV::fixup_riscv_nds_branch_10, llvm::RISCV::fixup_riscv_pcrel_hi20, llvm::RISCV::fixup_riscv_pcrel_lo12_i, llvm::RISCV::fixup_riscv_pcrel_lo12_s, llvm::RISCV::fixup_riscv_qc_abs20_u, llvm::RISCV::fixup_riscv_qc_e_32, llvm::RISCV::fixup_riscv_qc_e_branch, llvm::RISCV::fixup_riscv_qc_e_call_plt, llvm::RISCV::fixup_riscv_rvc_branch, llvm::RISCV::fixup_riscv_rvc_imm, llvm::RISCV::fixup_riscv_rvc_jump, llvm::FK_Data_1, llvm::FK_Data_2, llvm::FK_Data_4, llvm::FK_Data_8, llvm::FK_Data_leb128, llvm::isInt(), and llvm_unreachable.
      
  | 
  static | 
Definition at line 677 of file RISCVAsmBackend.cpp.
References DF, llvm::MCExpr::evaluateAsRelocatable(), F, llvm::RISCV::fixup_riscv_pcrel_hi20, llvm::MCValue::getAddSym(), llvm::MCSymbol::getFragment(), llvm::MCSymbol::getOffset(), llvm::MCSpecifierExpr::getSubExpr(), llvm::mc::isRelocation(), and llvm::Offset.
Referenced by llvm::RISCVAsmBackend::evaluateFixup().
      
  | 
  static | 
Definition at line 156 of file RISCVAsmBackend.cpp.
References llvm::MCSubtargetInfo::hasFeature(), and Reg.
Definition at line 909 of file RISCVAsmBackend.cpp.
References llvm::FK_Data_1, llvm::FK_Data_2, llvm::FK_Data_4, and llvm::FK_Data_8.
Referenced by llvm::RISCVAsmBackend::applyFixup().
      
  | 
  static | 
Definition at line 815 of file RISCVAsmBackend.cpp.
References llvm::RISCV::fixup_riscv_jal, llvm::RISCV::fixup_riscv_rvc_branch, llvm::RISCV::fixup_riscv_rvc_imm, and llvm::RISCV::fixup_riscv_rvc_jump.
Referenced by llvm::RISCVAsmBackend::addReloc().
      
  | 
  static | 
Referenced by llvm::RISCVAsmBackend::relaxAlign().
      
  | 
  static | 
Referenced by llvm::RISCVAsmBackend::relaxLEB128().