LLVM
8.0.1
|
#include "MCTargetDesc/X86FixupKinds.h"
#include "MCTargetDesc/X86MCTargetDesc.h"
#include "llvm/BinaryFormat/ELF.h"
#include "llvm/MC/MCAsmInfo.h"
#include "llvm/MC/MCContext.h"
#include "llvm/MC/MCELFObjectWriter.h"
#include "llvm/MC/MCExpr.h"
#include "llvm/MC/MCFixup.h"
#include "llvm/MC/MCObjectWriter.h"
#include "llvm/MC/MCValue.h"
#include "llvm/Support/ErrorHandling.h"
#include <cassert>
#include <cstdint>
Go to the source code of this file.
Enumerations | |
enum | X86_64RelType { RT64_64, RT64_32, RT64_32S, RT64_16, RT64_8 } |
enum | X86_32RelType { RT32_32, RT32_16, RT32_8 } |
Functions | |
static X86_64RelType | getType64 (unsigned Kind, MCSymbolRefExpr::VariantKind &Modifier, bool &IsPCRel) |
static void | checkIs32 (MCContext &Ctx, SMLoc Loc, X86_64RelType Type) |
static unsigned | getRelocType64 (MCContext &Ctx, SMLoc Loc, MCSymbolRefExpr::VariantKind Modifier, X86_64RelType Type, bool IsPCRel, unsigned Kind) |
static X86_32RelType | getType32 (X86_64RelType T) |
static unsigned | getRelocType32 (MCContext &Ctx, MCSymbolRefExpr::VariantKind Modifier, X86_32RelType Type, bool IsPCRel, unsigned Kind) |
enum X86_32RelType |
Enumerator | |
---|---|
RT32_32 | |
RT32_16 | |
RT32_8 |
Definition at line 203 of file X86ELFObjectWriter.cpp.
enum X86_64RelType |
Enumerator | |
---|---|
RT64_64 | |
RT64_32 | |
RT64_32S | |
RT64_16 | |
RT64_8 |
Definition at line 48 of file X86ELFObjectWriter.cpp.
|
static |
Definition at line 90 of file X86ELFObjectWriter.cpp.
References llvm::MCContext::reportError(), and RT64_32.
Referenced by getRelocType64().
|
static |
Definition at line 220 of file X86ELFObjectWriter.cpp.
References assert(), llvm::MCAsmInfo::canRelaxRelocations(), llvm::ELF::EM_386, llvm::ELF::EM_IAMCU, llvm::ELF::EM_X86_64, Fixup, llvm::MCValue::getAccessVariant(), llvm::MCContext::getAsmInfo(), llvm::MCFixup::getKind(), llvm::MCFixup::getLoc(), getRelocType(), getRelocType64(), getType32(), getType64(), Kind, llvm_unreachable, llvm::X86::reloc_signed_4byte_relax, RT32_16, RT32_32, RT32_8, llvm::MCSymbolRefExpr::VK_DTPOFF, llvm::MCSymbolRefExpr::VK_GOT, llvm::MCSymbolRefExpr::VK_GOTNTPOFF, llvm::MCSymbolRefExpr::VK_GOTOFF, llvm::MCSymbolRefExpr::VK_GOTTPOFF, llvm::MCSymbolRefExpr::VK_INDNTPOFF, llvm::MCSymbolRefExpr::VK_None, llvm::MCSymbolRefExpr::VK_NTPOFF, llvm::MCSymbolRefExpr::VK_PLT, llvm::MCSymbolRefExpr::VK_TLSGD, llvm::MCSymbolRefExpr::VK_TLSLDM, llvm::MCSymbolRefExpr::VK_TPOFF, and llvm::MCSymbolRefExpr::VK_X86_ABS8.
|
static |
Definition at line 96 of file X86ELFObjectWriter.cpp.
References assert(), llvm::MCAsmInfo::canRelaxRelocations(), checkIs32(), llvm::MCContext::getAsmInfo(), llvm_unreachable, llvm::X86::reloc_riprel_4byte_movq_load, llvm::X86::reloc_riprel_4byte_relax, llvm::X86::reloc_riprel_4byte_relax_rex, RT64_16, RT64_32, RT64_32S, RT64_64, RT64_8, llvm::MCSymbolRefExpr::VK_DTPOFF, llvm::MCSymbolRefExpr::VK_GOT, llvm::MCSymbolRefExpr::VK_GOTOFF, llvm::MCSymbolRefExpr::VK_GOTPCREL, llvm::MCSymbolRefExpr::VK_GOTTPOFF, llvm::MCSymbolRefExpr::VK_None, llvm::MCSymbolRefExpr::VK_PLT, llvm::MCSymbolRefExpr::VK_SIZE, llvm::MCSymbolRefExpr::VK_TLSCALL, llvm::MCSymbolRefExpr::VK_TLSDESC, llvm::MCSymbolRefExpr::VK_TLSGD, llvm::MCSymbolRefExpr::VK_TLSLD, llvm::MCSymbolRefExpr::VK_TPOFF, and llvm::MCSymbolRefExpr::VK_X86_ABS8.
Referenced by getRelocType32().
|
static |
Definition at line 205 of file X86ELFObjectWriter.cpp.
References llvm_unreachable, RT32_16, RT32_32, RT32_8, RT64_16, RT64_32, RT64_32S, RT64_64, and RT64_8.
Referenced by getRelocType32().
|
static |
Definition at line 50 of file X86ELFObjectWriter.cpp.
References llvm::FK_Data_1, llvm::FK_Data_2, llvm::FK_Data_4, llvm::FK_Data_8, llvm::FK_PCRel_1, llvm::FK_PCRel_2, llvm::FK_PCRel_4, llvm_unreachable, llvm::X86::reloc_branch_4byte_pcrel, llvm::X86::reloc_global_offset_table, llvm::X86::reloc_global_offset_table8, llvm::X86::reloc_riprel_4byte, llvm::X86::reloc_riprel_4byte_movq_load, llvm::X86::reloc_riprel_4byte_relax, llvm::X86::reloc_riprel_4byte_relax_rex, llvm::X86::reloc_signed_4byte, llvm::X86::reloc_signed_4byte_relax, RT64_16, RT64_32, RT64_32S, RT64_64, RT64_8, llvm::MCSymbolRefExpr::VK_GOT, llvm::MCSymbolRefExpr::VK_None, and llvm::MCSymbolRefExpr::VK_PLT.
Referenced by getRelocType32().