/freebsd/contrib/llvm-project/llvm/lib/Target/Mips/MCTargetDesc/ |
H A D | MipsELFObjectWriter.cpp | 143 if (Type == ELF::R_MIPS_HI16) in getMatchingLoType() 144 return ELF::R_MIPS_LO16; in getMatchingLoType() 145 if (Type == ELF::R_MICROMIPS_HI16) in getMatchingLoType() 146 return ELF::R_MICROMIPS_LO16; in getMatchingLoType() 147 if (Type == ELF::R_MIPS16_HI16) in getMatchingLoType() 148 return ELF::R_MIPS16_LO16; in getMatchingLoType() 151 Reloc.OriginalSymbol->getBinding() != ELF::STB_LOCAL) in getMatchingLoType() 152 return ELF::R_MIPS_NONE; in getMatchingLoType() 154 if (Type == ELF::R_MIPS_GOT16) in getMatchingLoType() 155 return ELF::R_MIPS_LO16; in getMatchingLoType() [all …]
|
/freebsd/contrib/llvm-project/llvm/lib/Target/Hexagon/MCTargetDesc/ |
H A D | HexagonELFObjectWriter.cpp | 38 : MCELFObjectTargetWriter(/*Is64bit*/ false, OSABI, ELF::EM_HEXAGON, in HexagonELFObjectWriter() 54 return ELF::R_HEX_DTPREL_32; in getRelocType() 56 return ELF::R_HEX_GOT_32; in getRelocType() 58 return ELF::R_HEX_GOTREL_32; in getRelocType() 60 return ELF::R_HEX_GD_GOT_32; in getRelocType() 62 return ELF::R_HEX_IE_32; in getRelocType() 64 return ELF::R_HEX_IE_GOT_32; in getRelocType() 66 return ELF::R_HEX_LD_GOT_32; in getRelocType() 68 return ELF::R_HEX_32_PCREL; in getRelocType() 70 return ELF::R_HEX_TPREL_32; in getRelocType() [all …]
|
/freebsd/contrib/llvm-project/llvm/lib/Target/PowerPC/MCTargetDesc/ |
H A D | PPCELFObjectWriter.cpp | 1 //===-- PPCELFObjectWriter.cpp - PPC ELF Writer ---------------------------===// 38 Is64Bit ? ELF::EM_PPC64 : ELF::EM_PPC, in PPCELFObjectWriter() 93 Type = ELF::R_PPC_REL24; in getRelocType() 96 Type = ELF::R_PPC_PLTREL24; in getRelocType() 99 Type = ELF::R_PPC_LOCAL24PC; in getRelocType() 102 Type = ELF::R_PPC64_REL24_NOTOC; in getRelocType() 108 Type = ELF::R_PPC_REL14; in getRelocType() 114 Type = ELF::R_PPC_REL16; in getRelocType() 117 Type = ELF in getRelocType() [all...] |
/freebsd/contrib/llvm-project/llvm/lib/Target/Sparc/MCTargetDesc/ |
H A D | SparcELFObjectWriter.cpp | 27 Is64Bit ? ELF::EM_SPARCV9 in SparcELFObjectWriter() 28 : (HasV9 ? ELF::EM_SPARC32PLUS : ELF::EM_SPARC), in SparcELFObjectWriter() 52 return ELF::R_SPARC_DISP32; in getRelocType() 59 case FK_Data_1: return ELF::R_SPARC_DISP8; in getRelocType() 60 case FK_Data_2: return ELF::R_SPARC_DISP16; in getRelocType() 61 case FK_Data_4: return ELF::R_SPARC_DISP32; in getRelocType() 62 case FK_Data_8: return ELF::R_SPARC_DISP64; in getRelocType() 63 case Sparc::fixup_sparc_call30: return ELF::R_SPARC_WDISP30; in getRelocType() 64 case Sparc::fixup_sparc_br22: return ELF::R_SPARC_WDISP22; in getRelocType() 65 case Sparc::fixup_sparc_br19: return ELF::R_SPARC_WDISP19; in getRelocType() [all …]
|
/freebsd/contrib/llvm-project/llvm/lib/Target/ARM/MCTargetDesc/ |
H A D | ARMELFObjectWriter.cpp | 52 ELF::EM_ARM, in ARMELFObjectWriter() 65 case ELF::R_ARM_PREL31: in needsRelocateWithSymbol() 66 case ELF::R_ARM_ABS32: in needsRelocateWithSymbol() 89 if (getOSABI() != ELF::ELFOSABI_ARM_FDPIC) in GetRelocTypeInner() 92 object::getELFRelocationTypeName(ELF::EM_ARM, Type) + in GetRelocTypeInner() 101 return ELF::R_ARM_NONE; in GetRelocTypeInner() 107 return ELF::R_ARM_NONE; in GetRelocTypeInner() 113 return ELF::R_ARM_BASE_PREL; in GetRelocTypeInner() 115 return ELF::R_ARM_REL32; in GetRelocTypeInner() 118 return ELF::R_ARM_TLS_IE32; in GetRelocTypeInner() [all …]
|
/freebsd/contrib/llvm-project/llvm/lib/Object/ |
H A D | RelocationResolver.cpp | 16 #include "llvm/BinaryFormat/ELF.h" 42 case ELF::R_X86_64_NONE: in supportsX86_64() 43 case ELF::R_X86_64_64: in supportsX86_64() 44 case ELF::R_X86_64_DTPOFF32: in supportsX86_64() 45 case ELF::R_X86_64_DTPOFF64: in supportsX86_64() 46 case ELF::R_X86_64_PC32: in supportsX86_64() 47 case ELF::R_X86_64_PC64: in supportsX86_64() 48 case ELF::R_X86_64_32: in supportsX86_64() 49 case ELF::R_X86_64_32S: in supportsX86_64() 59 case ELF in resolveX86_64() [all...] |
H A D | ELFObjectFile.cpp | 42 {"None", "NOTYPE", ELF::STT_NOTYPE}, 43 {"Object", "OBJECT", ELF::STT_OBJECT}, 44 {"Function", "FUNC", ELF::STT_FUNC}, 45 {"Section", "SECTION", ELF::STT_SECTION}, 46 {"File", "FILE", ELF::STT_FILE}, 47 {"Common", "COMMON", ELF::STT_COMMON}, 48 {"TLS", "TLS", ELF::STT_TLS}, 52 {"GNU_IFunc", "IFUNC", ELF::STT_GNU_IFUNC}, 83 if (Ident.first == ELF::ELFCLASS32) { in createELFObjectFile() 84 if (Ident.second == ELF::ELFDATA2LSB) in createELFObjectFile() [all …]
|
H A D | ELF.cpp | 21 #define ELF_RELOC(name, value) STRINGIFY_ENUM_CASE(ELF, name) 26 case ELF::EM_68K: in getELFRelocationTypeName() 33 case ELF::EM_X86_64: in getELFRelocationTypeName() 40 case ELF::EM_386: in getELFRelocationTypeName() 41 case ELF::EM_IAMCU: in getELFRelocationTypeName() 48 case ELF::EM_MIPS: in getELFRelocationTypeName() 55 case ELF::EM_AARCH64: in getELFRelocationTypeName() 62 case ELF::EM_ARM: in getELFRelocationTypeName() 69 case ELF::EM_ARC_COMPACT: in getELFRelocationTypeName() 70 case ELF::EM_ARC_COMPACT2: in getELFRelocationTypeName() [all …]
|
/freebsd/contrib/llvm-project/llvm/lib/Target/XCore/ |
H A D | XCoreTargetObjectFile.cpp | 23 BSSSection = Ctx.getELFSection(".dp.bss", ELF::SHT_NOBITS, in Initialize() 24 ELF::SHF_ALLOC | ELF::SHF_WRITE | in Initialize() 25 ELF::XCORE_SHF_DP_SECTION); in Initialize() 26 BSSSectionLarge = Ctx.getELFSection(".dp.bss.large", ELF::SHT_NOBITS, in Initialize() 27 ELF::SHF_ALLOC | ELF::SHF_WRITE | in Initialize() 28 ELF::XCORE_SHF_DP_SECTION); in Initialize() 29 DataSection = Ctx.getELFSection(".dp.data", ELF::SHT_PROGBITS, in Initialize() 30 ELF::SHF_ALLOC | ELF::SHF_WRITE | in Initialize() 31 ELF::XCORE_SHF_DP_SECTION); in Initialize() 32 DataSectionLarge = Ctx.getELFSection(".dp.data.large", ELF::SHT_PROGBITS, in Initialize() [all …]
|
/freebsd/contrib/llvm-project/llvm/lib/Target/RISCV/MCTargetDesc/ |
H A D | RISCVELFObjectWriter.cpp | 1 //===-- RISCVELFObjectWriter.cpp - RISC-V ELF Writer ----------------------===// 44 : MCELFObjectTargetWriter(Is64Bit, OSABI, ELF::EM_RISCV, in RISCVELFObjectWriter() 62 return ELF::R_RISCV_NONE; in getRelocType() 66 ? ELF::R_RISCV_PLT32 in getRelocType() 67 : ELF::R_RISCV_32_PCREL; in getRelocType() 69 return ELF::R_RISCV_PCREL_HI20; in getRelocType() 71 return ELF::R_RISCV_PCREL_LO12_I; in getRelocType() 73 return ELF::R_RISCV_PCREL_LO12_S; in getRelocType() 75 return ELF::R_RISCV_GOT_HI20; in getRelocType() 77 return ELF in getRelocType() [all...] |
/freebsd/contrib/llvm-project/llvm/lib/Target/AVR/MCTargetDesc/ |
H A D | AVRELFObjectWriter.cpp | 35 : MCELFObjectTargetWriter(false, OSABI, ELF::EM_AVR, true) {} in AVRELFObjectWriter() 50 return ELF::R_AVR_8; in getRelocType() 52 return ELF::R_AVR_DIFF8; in getRelocType() 54 return ELF::R_AVR_8_LO8; in getRelocType() 56 return ELF::R_AVR_8_HI8; in getRelocType() 58 return ELF::R_AVR_8_HLO8; in getRelocType() 65 return ELF::R_AVR_32; in getRelocType() 67 return ELF::R_AVR_DIFF32; in getRelocType() 74 return ELF::R_AVR_16; in getRelocType() 77 return ELF::R_AVR_16_PM; in getRelocType() [all …]
|
/freebsd/contrib/llvm-project/llvm/lib/Target/CSKY/MCTargetDesc/ |
H A D | CSKYELFObjectWriter.cpp | 25 : MCELFObjectTargetWriter(false, OSABI, ELF::EM_CSKY, true){}; in CSKYELFObjectWriter() 48 return ELF::R_CKCORE_NONE; in getRelocType() 51 return ELF::R_CKCORE_PCREL32; in getRelocType() 53 return ELF::R_CKCORE_PCREL_IMM16_4; in getRelocType() 55 return ELF::R_CKCORE_PCREL_IMM8_4; in getRelocType() 57 return ELF::R_CKCORE_PCREL_IMM26_2; in getRelocType() 59 return ELF::R_CKCORE_PCREL_IMM18_2; in getRelocType() 61 return ELF::R_CKCORE_PCREL_IMM16_2; in getRelocType() 63 return ELF::R_CKCORE_PCREL_IMM10_2; in getRelocType() 65 return ELF::R_CKCORE_PCREL_IMM7_4; in getRelocType() [all …]
|
/freebsd/contrib/llvm-project/llvm/lib/MC/ |
H A D | MCSectionELF.cpp | 69 !(Flags & ELF::SHF_MERGE)) { in printSwitchToSection() 70 if (Flags & ELF::SHF_ALLOC) in printSwitchToSection() 72 if (Flags & ELF::SHF_EXECINSTR) in printSwitchToSection() 74 if (Flags & ELF::SHF_WRITE) in printSwitchToSection() 76 if (Flags & ELF::SHF_EXCLUDE) in printSwitchToSection() 78 if (Flags & ELF::SHF_TLS) in printSwitchToSection() 85 if (Flags & ELF::SHF_ALLOC) in printSwitchToSection() 87 if (Flags & ELF::SHF_EXCLUDE) in printSwitchToSection() 89 if (Flags & ELF::SHF_EXECINSTR) in printSwitchToSection() 91 if (Flags & ELF::SHF_WRITE) in printSwitchToSection() [all …]
|
H A D | MCSymbolELF.cpp | 49 case ELF::STB_LOCAL: in setBinding() 52 case ELF::STB_GLOBAL: in setBinding() 55 case ELF::STB_WEAK: in setBinding() 58 case ELF::STB_GNU_UNIQUE: in setBinding() 73 return ELF::STB_LOCAL; in getBinding() 75 return ELF::STB_GLOBAL; in getBinding() 77 return ELF::STB_WEAK; in getBinding() 79 return ELF::STB_GNU_UNIQUE; in getBinding() 84 return ELF::STB_LOCAL; in getBinding() 86 return ELF::STB_GLOBAL; in getBinding() [all …]
|
/freebsd/contrib/llvm-project/llvm/lib/Target/VE/MCTargetDesc/ |
H A D | VEELFObjectWriter.cpp | 1 //===-- VEELFObjectWriter.cpp - VE ELF Writer -----------------------------===// 25 : MCELFObjectTargetWriter(/* Is64Bit */ true, OSABI, ELF::EM_VE, in VEELFObjectWriter() 44 return ELF::R_VE_PC_LO32; in getRelocType() 51 return ELF::R_VE_NONE; in getRelocType() 56 return ELF::R_VE_NONE; in getRelocType() 61 return ELF::R_VE_NONE; in getRelocType() 64 return ELF::R_VE_SREL32; in getRelocType() 69 return ELF::R_VE_NONE; in getRelocType() 72 return ELF::R_VE_SREL32; in getRelocType() 74 return ELF in getRelocType() [all...] |
/freebsd/contrib/llvm-project/llvm/lib/Target/AMDGPU/MCTargetDesc/ |
H A D | AMDGPUTargetStreamer.cpp | 58 case ELF::EF_AMDGPU_MACH_R600_R600: AK = GK_R600; break; in getArchNameFromElfMach() 59 case ELF::EF_AMDGPU_MACH_R600_R630: AK = GK_R630; break; in getArchNameFromElfMach() 60 case ELF::EF_AMDGPU_MACH_R600_RS880: AK = GK_RS880; break; in getArchNameFromElfMach() 61 case ELF::EF_AMDGPU_MACH_R600_RV670: AK = GK_RV670; break; in getArchNameFromElfMach() 62 case ELF::EF_AMDGPU_MACH_R600_RV710: AK = GK_RV710; break; in getArchNameFromElfMach() 63 case ELF::EF_AMDGPU_MACH_R600_RV730: AK = GK_RV730; break; in getArchNameFromElfMach() 64 case ELF::EF_AMDGPU_MACH_R600_RV770: AK = GK_RV770; break; in getArchNameFromElfMach() 65 case ELF::EF_AMDGPU_MACH_R600_CEDAR: AK = GK_CEDAR; break; in getArchNameFromElfMach() 66 case ELF::EF_AMDGPU_MACH_R600_CYPRESS: AK = GK_CYPRESS; break; in getArchNameFromElfMach() 67 case ELF::EF_AMDGPU_MACH_R600_JUNIPER: AK = GK_JUNIPER; break; in getArchNameFromElfMach() [all …]
|
/freebsd/contrib/llvm-project/llvm/lib/Target/X86/MCTargetDesc/ |
H A D | X86ELFObjectWriter.cpp | 44 (EMachine != ELF::EM_386) && in X86ELFObjectWriter() 45 (EMachine != ELF::EM_IAMCU)) {} in X86ELFObjectWriter() 115 return ELF::R_X86_64_NONE; in getRelocType64() 118 return IsPCRel ? ELF::R_X86_64_PC64 : ELF::R_X86_64_64; in getRelocType64() 120 return IsPCRel ? ELF::R_X86_64_PC32 : ELF::R_X86_64_32; in getRelocType64() 122 return ELF::R_X86_64_32S; in getRelocType64() 124 return IsPCRel ? ELF::R_X86_64_PC16 : ELF::R_X86_64_16; in getRelocType64() 126 return IsPCRel ? ELF::R_X86_64_PC8 : ELF::R_X86_64_8; in getRelocType64() 132 return IsPCRel ? ELF::R_X86_64_GOTPC64 : ELF::R_X86_64_GOT64; in getRelocType64() 134 return IsPCRel ? ELF::R_X86_64_GOTPC32 : ELF::R_X86_64_GOT32; in getRelocType64() [all …]
|
/freebsd/usr.bin/clang/lld/ |
H A D | Makefile | 19 CFLAGS+= -I${LLD_SRCS}/ELF 37 SRCS+= ELF/AArch64ErrataFix.cpp 38 SRCS+= ELF/ARMErrataFix.cpp 39 SRCS+= ELF/Arch/AArch64.cpp 40 SRCS+= ELF/Arch/AMDGPU.cpp 41 SRCS+= ELF/Arch/ARM.cpp 42 SRCS+= ELF/Arch/AVR.cpp 43 SRCS+= ELF/Arch/Hexagon.cpp 44 SRCS+= ELF/Arch/LoongArch.cpp 45 SRCS+= ELF/Arch/MSP430.cpp [all …]
|
/freebsd/contrib/llvm-project/llvm/lib/Target/M68k/MCTargetDesc/ |
H A D | M68kELFObjectWriter.cpp | 41 : MCELFObjectTargetWriter(false, OSABI, ELF::EM_68K, /* RELA */ true) {} in M68kELFObjectWriter() 77 return ELF::R_68K_TLS_GD32; in getRelocType() 79 return ELF::R_68K_TLS_GD16; in getRelocType() 81 return ELF::R_68K_TLS_GD8; in getRelocType() 87 return ELF::R_68K_TLS_LDM32; in getRelocType() 89 return ELF::R_68K_TLS_LDM16; in getRelocType() 91 return ELF::R_68K_TLS_LDM8; in getRelocType() 97 return ELF::R_68K_TLS_LDO32; in getRelocType() 99 return ELF::R_68K_TLS_LDO16; in getRelocType() 101 return ELF::R_68K_TLS_LDO8; in getRelocType() [all …]
|
/freebsd/contrib/llvm-project/llvm/lib/ExecutionEngine/RuntimeDyld/Targets/ |
H A D | RuntimeDyldELFMips.cpp | 68 case ELF::R_MIPS_32: in evaluateMIPS32Relocation() 70 case ELF::R_MIPS_26: in evaluateMIPS32Relocation() 72 case ELF::R_MIPS_HI16: in evaluateMIPS32Relocation() 75 case ELF::R_MIPS_LO16: in evaluateMIPS32Relocation() 77 case ELF::R_MIPS_PC32: { in evaluateMIPS32Relocation() 81 case ELF::R_MIPS_PC16: { in evaluateMIPS32Relocation() 85 case ELF::R_MIPS_PC19_S2: { in evaluateMIPS32Relocation() 89 case ELF::R_MIPS_PC21_S2: { in evaluateMIPS32Relocation() 93 case ELF::R_MIPS_PC26_S2: { in evaluateMIPS32Relocation() 97 case ELF::R_MIPS_PCHI16: { in evaluateMIPS32Relocation() [all …]
|
/freebsd/contrib/llvm-project/llvm/lib/Target/SystemZ/MCTargetDesc/ |
H A D | SystemZMCObjectWriter.cpp |
|
/freebsd/contrib/llvm-project/llvm/lib/MC/MCParser/ |
H A D | ELFAsmParser.cpp | 92 return ParseSectionSwitch(".data", ELF::SHT_PROGBITS, in ParseSectionDirectiveData() 93 ELF::SHF_WRITE | ELF::SHF_ALLOC, in ParseSectionDirectiveData() 97 return ParseSectionSwitch(".text", ELF::SHT_PROGBITS, in ParseSectionDirectiveText() 98 ELF::SHF_EXECINSTR | in ParseSectionDirectiveText() 99 ELF::SHF_ALLOC, SectionKind::getText()); in ParseSectionDirectiveText() 102 return ParseSectionSwitch(".bss", ELF::SHT_NOBITS, in ParseSectionDirectiveBSS() 103 ELF::SHF_WRITE | in ParseSectionDirectiveBSS() 104 ELF::SHF_ALLOC, SectionKind::getBSS()); in ParseSectionDirectiveBSS() 107 return ParseSectionSwitch(".rodata", ELF::SHT_PROGBITS, in ParseSectionDirectiveRoData() 108 ELF::SHF_ALLOC, in ParseSectionDirectiveRoData() [all …]
|
/freebsd/contrib/llvm-project/llvm/lib/ExecutionEngine/RuntimeDyld/ |
H A D | RuntimeDyldELF.cpp | 267 case ELF::R_X86_64_NONE: in resolveX86_64Relocation() 269 case ELF::R_X86_64_8: { in resolveX86_64Relocation() 278 case ELF::R_X86_64_16: { in resolveX86_64Relocation() 288 case ELF::R_X86_64_64: { in resolveX86_64Relocation() 295 case ELF::R_X86_64_32: in resolveX86_64Relocation() 296 case ELF::R_X86_64_32S: { in resolveX86_64Relocation() 298 assert((Type == ELF::R_X86_64_32 && (Value <= UINT32_MAX)) || in resolveX86_64Relocation() 299 (Type == ELF::R_X86_64_32S && in resolveX86_64Relocation() 308 case ELF::R_X86_64_PC8: { in resolveX86_64Relocation() 316 case ELF::R_X86_64_PC32: { in resolveX86_64Relocation() [all …]
|
/freebsd/contrib/llvm-project/llvm/include/llvm/Object/ |
H A D | ELFObjectFile.h | 360 assert(SymTable->sh_type == ELF::SHT_SYMTAB || in toDRI() 361 SymTable->sh_type == ELF::SHT_DYNSYM); in toDRI() 402 (Binding == ELF::STB_GLOBAL || Binding == ELF::STB_WEAK || in isExportedToOtherDSO() 403 Binding == ELF::STB_GNU_UNIQUE) && in isExportedToOtherDSO() 404 (Visibility == ELF::STV_DEFAULT || Visibility == ELF::STV_PROTECTED)); in isExportedToOtherDSO() 410 case ELF::EM_ARM: in getBuildAttributes() 411 Type = ELF::SHT_ARM_ATTRIBUTES; in getBuildAttributes() 413 case ELF::EM_RISCV: in getBuildAttributes() 414 Type = ELF::SHT_RISCV_ATTRIBUTES; in getBuildAttributes() 416 case ELF::EM_HEXAGON: in getBuildAttributes() [all …]
|
/freebsd/contrib/llvm-project/llvm/lib/Target/LoongArch/MCTargetDesc/ |
H A D | LoongArchELFObjectWriter.cpp | 1 //===-- LoongArchELFObjectWriter.cpp - LoongArch ELF Writer ---*- C++ -*---===// 11 #include "llvm/BinaryFormat/ELF.h" 41 : MCELFObjectTargetWriter(Is64Bit, OSABI, ELF::EM_LOONGARCH, in getRelocType() 60 return ELF::R_LARCH_NONE; in getRelocType() 63 return ELF::R_LARCH_NONE; in getRelocType() 66 return ELF::R_LARCH_NONE; in getRelocType() 68 return IsPCRel ? ELF::R_LARCH_32_PCREL : ELF::R_LARCH_32; in getRelocType() 70 return IsPCRel ? ELF::R_LARCH_64_PCREL : ELF in getRelocType() [all...] |