Lines Matching defs:XCOFFObjectFile

1 //===--- XCOFFObjectFile.cpp - XCOFF object file implementation -----------===//
9 // This file defines the XCOFFObjectFile class.
13 #include "llvm/Object/XCOFFObjectFile.h"
127 XCOFFObjectFile::getAdvancedSymbolEntryAddress(uintptr_t CurrentAddress,
133 XCOFFObjectFile::getSymbolAuxType(uintptr_t AuxEntryAddress) const {
139 void XCOFFObjectFile::checkSectionAddress(uintptr_t Addr,
154 XCOFFObjectFile::toSection32(DataRefImpl Ref) const {
163 XCOFFObjectFile::toSection64(DataRefImpl Ref) const {
171 XCOFFSymbolRef XCOFFObjectFile::toSymbolRef(DataRefImpl Ref) const {
179 const XCOFFFileHeader32 *XCOFFObjectFile::fileHeader32() const {
184 const XCOFFFileHeader64 *XCOFFObjectFile::fileHeader64() const {
189 const XCOFFAuxiliaryHeader32 *XCOFFObjectFile::auxiliaryHeader32() const {
194 const XCOFFAuxiliaryHeader64 *XCOFFObjectFile::auxiliaryHeader64() const {
199 template <typename T> const T *XCOFFObjectFile::sectionHeaderTable() const {
204 XCOFFObjectFile::sectionHeaderTable32() const {
210 XCOFFObjectFile::sectionHeaderTable64() const {
215 void XCOFFObjectFile::moveSymbolNext(DataRefImpl &Symb) const {
228 XCOFFObjectFile::getStringTableEntry(uint32_t Offset) const {
245 StringRef XCOFFObjectFile::getStringTable() const {
253 XCOFFObjectFile::getCFileName(const XCOFFFileAuxEnt *CFileEntPtr) const {
259 Expected<StringRef> XCOFFObjectFile::getSymbolName(DataRefImpl Symb) const {
263 Expected<uint64_t> XCOFFObjectFile::getSymbolAddress(DataRefImpl Symb) const {
267 uint64_t XCOFFObjectFile::getSymbolValueImpl(DataRefImpl Symb) const {
271 uint32_t XCOFFObjectFile::getSymbolAlignment(DataRefImpl Symb) const {
286 uint64_t XCOFFObjectFile::getCommonSymbolSizeImpl(DataRefImpl Symb) const {
305 XCOFFObjectFile::getSymbolType(DataRefImpl Symb) const {
339 SecName = XCOFFObjectFile::toSection64(SecDRIOrErr.get())->getName();
341 SecName = XCOFFObjectFile::toSection32(SecDRIOrErr.get())->getName();
358 XCOFFObjectFile::getSymbolSection(DataRefImpl Symb) const {
371 void XCOFFObjectFile::moveSectionNext(DataRefImpl &Sec) const {
376 Expected<StringRef> XCOFFObjectFile::getSectionName(DataRefImpl Sec) const {
380 uint64_t XCOFFObjectFile::getSectionAddress(DataRefImpl Sec) const {
389 uint64_t XCOFFObjectFile::getSectionIndex(DataRefImpl Sec) const {
398 uint64_t XCOFFObjectFile::getSectionSize(DataRefImpl Sec) const {
408 XCOFFObjectFile::getSectionContents(DataRefImpl Sec) const {
430 uint64_t XCOFFObjectFile::getSectionAlignment(DataRefImpl Sec) const {
436 uint64_t XCOFFObjectFile::getSectionFileOffsetToRawData(DataRefImpl Sec) const {
443 Expected<uintptr_t> XCOFFObjectFile::getSectionFileOffsetToRawData(
490 bool XCOFFObjectFile::isSectionCompressed(DataRefImpl Sec) const {
494 bool XCOFFObjectFile::isSectionText(DataRefImpl Sec) const {
498 bool XCOFFObjectFile::isSectionData(DataRefImpl Sec) const {
503 bool XCOFFObjectFile::isSectionBSS(DataRefImpl Sec) const {
508 bool XCOFFObjectFile::isDebugSection(DataRefImpl Sec) const {
513 bool XCOFFObjectFile::isSectionVirtual(DataRefImpl Sec) const {
518 relocation_iterator XCOFFObjectFile::section_rel_begin(DataRefImpl Sec) const {
544 relocation_iterator XCOFFObjectFile::section_rel_end(DataRefImpl Sec) const {
570 void XCOFFObjectFile::moveRelocationNext(DataRefImpl &Rel) const {
577 uint64_t XCOFFObjectFile::getRelocationOffset(DataRefImpl Rel) const {
610 symbol_iterator XCOFFObjectFile::getRelocationSymbol(DataRefImpl Rel) const {
630 uint64_t XCOFFObjectFile::getRelocationType(DataRefImpl Rel) const {
636 void XCOFFObjectFile::getRelocationTypeName(
649 Expected<uint32_t> XCOFFObjectFile::getSymbolFlags(DataRefImpl Symb) const {
689 basic_symbol_iterator XCOFFObjectFile::symbol_begin() const {
695 basic_symbol_iterator XCOFFObjectFile::symbol_end() const {
702 XCOFFObjectFile::xcoff_symbol_iterator_range XCOFFObjectFile::symbols() const {
706 section_iterator XCOFFObjectFile::section_begin() const {
712 section_iterator XCOFFObjectFile::section_end() const {
719 uint8_t XCOFFObjectFile::getBytesInAddress() const { return is64Bit() ? 8 : 4; }
721 StringRef XCOFFObjectFile::getFileFormatName() const {
725 Triple::ArchType XCOFFObjectFile::getArch() const {
729 Expected<SubtargetFeatures> XCOFFObjectFile::getFeatures() const {
733 bool XCOFFObjectFile::isRelocatableObject() const {
739 Expected<uint64_t> XCOFFObjectFile::getStartAddress() const {
747 StringRef XCOFFObjectFile::mapDebugSectionName(StringRef Name) const {
763 size_t XCOFFObjectFile::getFileHeaderSize() const {
767 size_t XCOFFObjectFile::getSectionHeaderSize() const {
772 bool XCOFFObjectFile::is64Bit() const {
776 Expected<StringRef> XCOFFObjectFile::getRawData(const char *Start,
789 uint16_t XCOFFObjectFile::getMagic() const {
793 Expected<DataRefImpl> XCOFFObjectFile::getSectionByNum(int16_t Num) const {
806 XCOFFObjectFile::getSectionByType(XCOFF::SectionTypeFlags SectType) const {
822 XCOFFObjectFile::getSymbolSectionName(XCOFFSymbolRef SymEntPtr) const {
841 unsigned XCOFFObjectFile::getSymbolSectionID(SymbolRef Sym) const {
846 bool XCOFFObjectFile::isReservedSectionNumber(int16_t SectionNumber) {
850 uint16_t XCOFFObjectFile::getNumberOfSections() const {
855 int32_t XCOFFObjectFile::getTimeStamp() const {
859 uint16_t XCOFFObjectFile::getOptionalHeaderSize() const {
864 uint32_t XCOFFObjectFile::getSymbolTableOffset32() const {
868 int32_t XCOFFObjectFile::getRawNumberOfSymbolTableEntries32() const {
875 uint32_t XCOFFObjectFile::getLogicalNumberOfSymbolTableEntries32() const {
881 uint64_t XCOFFObjectFile::getSymbolTableOffset64() const {
885 uint32_t XCOFFObjectFile::getNumberOfSymbolTableEntries64() const {
889 uint32_t XCOFFObjectFile::getNumberOfSymbolTableEntries() const {
894 uintptr_t XCOFFObjectFile::getEndOfSymbolTableAddress() const {
900 void XCOFFObjectFile::checkSymbolEntryPointer(uintptr_t SymbolEntPtr) const {
915 uint32_t XCOFFObjectFile::getSymbolIndex(uintptr_t SymbolEntPtr) const {
921 uint64_t XCOFFObjectFile::getSymbolSize(DataRefImpl Symb) const {
940 uintptr_t XCOFFObjectFile::getSymbolEntryAddressByIndex(uint32_t Index) const {
946 XCOFFObjectFile::getSymbolNameByIndex(uint32_t Index) const {
959 uint16_t XCOFFObjectFile::getFlags() const {
963 const char *XCOFFObjectFile::getSectionNameInternal(DataRefImpl Sec) const {
967 uintptr_t XCOFFObjectFile::getSectionHeaderTableAddress() const {
971 int32_t XCOFFObjectFile::getSectionFlags(DataRefImpl Sec) const {
975 XCOFFObjectFile::XCOFFObjectFile(unsigned int Type, MemoryBufferRef Object)
980 ArrayRef<XCOFFSectionHeader64> XCOFFObjectFile::sections64() const {
987 ArrayRef<XCOFFSectionHeader32> XCOFFObjectFile::sections32() const {
999 Expected<uint32_t> XCOFFObjectFile::getNumberOfRelocationEntries(
1017 Expected<ArrayRef<Reloc>> XCOFFObjectFile::relocations(const Shdr &Sec) const {
1044 Expected<ArrayRef<ExceptEnt>> XCOFFObjectFile::getExceptionEntries() const {
1064 XCOFFObjectFile::getExceptionEntries() const;
1066 XCOFFObjectFile::getExceptionEntries() const;
1069 XCOFFObjectFile::parseStringTable(const XCOFFObjectFile *Obj, uint64_t Offset) {
1104 Expected<StringRef> XCOFFObjectFile::getImportFileTable() const {
1151 Expected<std::unique_ptr<XCOFFObjectFile>>
1152 XCOFFObjectFile::create(unsigned Type, MemoryBufferRef MBR) {
1154 std::unique_ptr<XCOFFObjectFile> Obj;
1155 Obj.reset(new XCOFFObjectFile(Type, MBR));
1233 return XCOFFObjectFile::create(FileType, MemBufRef);
1236 std::optional<StringRef> XCOFFObjectFile::tryGetCPUName() const {
1331 uintptr_t AuxAddr = XCOFFObjectFile::getAdvancedSymbolEntryAddress(
1339 uintptr_t AuxAddr = XCOFFObjectFile::getAdvancedSymbolEntryAddress(
1380 llvm::object::XCOFFObjectFile::relocations<llvm::object::XCOFFSectionHeader64,
1384 llvm::object::XCOFFObjectFile::relocations<llvm::object::XCOFFSectionHeader32,