LLVM 19.0.0git
|
#include "llvm/Object/ELFObjectFile.h"
Public Types | |
using | elf_symbol_iterator_range = iterator_range< elf_symbol_iterator > |
Public Types inherited from llvm::object::ObjectFile | |
using | symbol_iterator_range = iterator_range< symbol_iterator > |
using | section_iterator_range = iterator_range< section_iterator > |
Public Types inherited from llvm::object::SymbolicFile | |
using | basic_symbol_iterator_range = iterator_range< basic_symbol_iterator > |
Friends | |
class | ELFRelocationRef |
class | ELFSectionRef |
class | ELFSymbolRef |
Additional Inherited Members | |
Protected Types inherited from llvm::object::Binary | |
enum | { ID_Archive , ID_MachOUniversalBinary , ID_COFFImportFile , ID_IR , ID_TapiUniversal , ID_TapiFile , ID_Minidump , ID_WinRes , ID_Offload , ID_StartObjects , ID_COFF , ID_XCOFF32 , ID_XCOFF64 , ID_ELF32L , ID_ELF32B , ID_ELF64L , ID_ELF64B , ID_MachO32L , ID_MachO32B , ID_MachO64L , ID_MachO64B , ID_GOFF , ID_Wasm , ID_EndObjects } |
Static Protected Member Functions inherited from llvm::object::Binary | |
static unsigned int | getELFType (bool isLE, bool is64Bits) |
static unsigned int | getMachOType (bool isLE, bool is64Bits) |
Protected Attributes inherited from llvm::object::Binary | |
MemoryBufferRef | Data |
Definition at line 56 of file ELFObjectFile.h.
using llvm::object::ELFObjectFileBase::elf_symbol_iterator_range = iterator_range<elf_symbol_iterator> |
Definition at line 85 of file ELFObjectFile.h.
|
protected |
Definition at line 59 of file ELFObjectFile.cpp.
Definition at line 94 of file ELFObjectFile.h.
|
protectedpure virtual |
Implemented in llvm::object::ELFObjectFile< ELFT >.
Referenced by setARMSubArch().
|
pure virtual |
Implemented in llvm::object::ELFObjectFile< ELFT >.
Referenced by readDynsymVersions().
|
pure virtual |
|
pure virtual |
Referenced by getFeatures(), getPltEntries(), and tryGetCPUName().
|
pure virtual |
|
overridevirtual |
Implements llvm::object::ObjectFile.
Definition at line 342 of file ELFObjectFile.cpp.
References llvm::ELF::EM_ARM, llvm::ELF::EM_LOONGARCH, llvm::ELF::EM_MIPS, llvm::ELF::EM_RISCV, and getEMachine().
|
pure virtual |
Returns platform-specific object flags, if any.
Implemented in llvm::object::ELFObjectFile< ELFT >.
Referenced by llvm::RuntimeDyldELF::processRelocationRef().
std::vector< ELFPltEntry > ELFObjectFileBase::getPltEntries | ( | ) | const |
Definition at line 694 of file ELFObjectFile.cpp.
References llvm::Triple::aarch64, llvm::Triple::aarch64_be, llvm::append_range(), llvm::consumeError(), llvm::ELF::EM_386, llvm::DenseMapBase< DerivedT, KeyT, ValueT, KeyInfoT, BucketT >::end(), llvm::DenseMapBase< DerivedT, KeyT, ValueT, KeyInfoT, BucketT >::find(), llvm::Triple::getArch(), getEMachine(), llvm::DenseMapBase< DerivedT, KeyT, ValueT, KeyInfoT, BucketT >::insert(), llvm::TargetRegistry::lookupTarget(), llvm::object::ObjectFile::makeTriple(), Name, llvm::object::ObjectFile::sections(), llvm::Triple::str(), Sym, llvm::object::SymbolicFile::symbol_end(), llvm::Expected< T >::takeError(), llvm::Triple::x86, and llvm::Triple::x86_64.
|
protectedpure virtual |
Implemented in llvm::object::ELFObjectFile< ELFT >.
Referenced by llvm::object::ELFRelocationRef::getAddend().
|
protectedpure virtual |
Implemented in llvm::object::ELFObjectFile< ELFT >.
Referenced by llvm::object::ELFSectionRef::getFlags().
|
protectedpure virtual |
Implemented in llvm::object::ELFObjectFile< ELFT >.
Referenced by llvm::object::ELFSectionRef::getOffset().
|
protectedpure virtual |
Implemented in llvm::object::ELFObjectFile< ELFT >.
Referenced by llvm::object::ELFSectionRef::getType().
|
protectedpure virtual |
Implemented in llvm::object::ELFObjectFile< ELFT >.
Referenced by llvm::object::ELFSymbolRef::getBinding().
|
protectedpure virtual |
Implemented in llvm::object::ELFObjectFile< ELFT >.
Referenced by llvm::object::ELFSymbolRef::getELFType().
|
protectedpure virtual |
Implemented in llvm::object::ELFObjectFile< ELFT >.
Referenced by llvm::object::ELFSymbolRef::getOther().
|
protectedpure virtual |
Referenced by llvm::object::ELFSymbolRef::getSize().
Expected< std::vector< BBAddrMap > > ELFObjectFileBase::readBBAddrMap | ( | std::optional< unsigned > | TextSectionIndex = std::nullopt , |
std::vector< PGOAnalysisMap > * | PGOAnalyses = nullptr |
||
) | const |
Returns a vector of all BB address maps in the object file.
When TextSectionIndex
is specified, only returns the BB address maps corresponding to the section with that index. When PGOAnalyses
is specified (PGOAnalyses is not nullptr), the vector is cleared then filled with extra PGO data. PGOAnalyses
will always be the same length as the return value when it is requested assuming no error occurs. Upon failure, PGOAnalyses
will be emptied.
Definition at line 922 of file ELFObjectFile.cpp.
References readBBAddrMapImpl().
Expected< std::vector< VersionEntry > > ELFObjectFileBase::readDynsymVersions | ( | ) | const |
Returns a vector containing a symbol version for each dynamic symbol.
Returns an empty vector if version sections do not exist.
Definition at line 910 of file ELFObjectFile.cpp.
References getDynamicSymbolIterators(), and readDynsymVersionsImpl().
|
overridevirtual |
Reimplemented from llvm::object::ObjectFile.
Definition at line 600 of file ELFObjectFile.cpp.
References Attributes, llvm::consumeError(), llvm::ARMBuildAttrs::CPU_arch, llvm::ARMBuildAttrs::CPU_arch_profile, E, getBuildAttributes(), llvm::Triple::getSubArch(), llvm::object::Binary::isLittleEndian(), llvm::Triple::isThumb(), llvm::ARMBuildAttrs::MicroControllerProfile, llvm::Triple::NoSubArch, llvm::Triple::setArchName(), llvm::ARMBuildAttrs::v4, llvm::ARMBuildAttrs::v4T, llvm::ARMBuildAttrs::v5T, llvm::ARMBuildAttrs::v5TE, llvm::ARMBuildAttrs::v5TEJ, llvm::ARMBuildAttrs::v6, llvm::ARMBuildAttrs::v6_M, llvm::ARMBuildAttrs::v6K, llvm::ARMBuildAttrs::v6KZ, llvm::ARMBuildAttrs::v6S_M, llvm::ARMBuildAttrs::v6T2, llvm::ARMBuildAttrs::v7, llvm::ARMBuildAttrs::v7E_M, llvm::ARMBuildAttrs::v8_1_M_Main, llvm::ARMBuildAttrs::v8_A, llvm::ARMBuildAttrs::v8_M_Base, llvm::ARMBuildAttrs::v8_M_Main, llvm::ARMBuildAttrs::v8_R, and llvm::ARMBuildAttrs::v9_A.
|
inline |
Definition at line 249 of file ELFObjectFile.h.
References llvm::object::SymbolicFile::symbol_begin(), and llvm::object::SymbolicFile::symbol_end().
Referenced by llvm::orc::getELFObjectFileSymbolInfo().
|
overridevirtual |
Reimplemented from llvm::object::ObjectFile.
Definition at line 357 of file ELFObjectFile.cpp.
References llvm::ELF::EM_AMDGPU, llvm::ELF::EM_CUDA, llvm::ELF::EM_PPC, llvm::ELF::EM_PPC64, and getEMachine().
|
friend |
Definition at line 57 of file ELFObjectFile.h.
|
friend |
Definition at line 58 of file ELFObjectFile.h.
|
friend |
Definition at line 59 of file ELFObjectFile.h.
Referenced by llvm::object::ELFObjectFile< ELFT >::toSymbolRef().