Lines Matching defs:Obj

43       : Dumper(O), Obj(O) {
44 Is64 = !Obj.getPE32Header();
59 const llvm::object::COFFObjectFile &Obj;
65 objdump::createCOFFDumper(const object::COFFObjectFile &Obj) {
66 return std::make_unique<COFFDumper>(Obj);
185 if (const data_directory *Data = Obj.getDataDirectory(I)) {
343 static Error resolveSectionAndAddress(const COFFObjectFile *Obj,
354 ResolvedSection = Obj->getCOFFSection(**Iter);
377 getSectionContents(const COFFObjectFile *Obj,
384 if (Error E = resolveSectionAndAddress(Obj, Sym, Section, Addr))
386 return Obj->getSectionContents(Section, Contents);
418 printSEHTable(const COFFObjectFile *Obj, uint32_t TableVA, int Count) {
423 if (Error E = Obj->getVaPtr(TableVA, IntPtr))
424 reportError(std::move(E), Obj->getFileName());
429 outs() << format(" 0x%x", P[I] + Obj->getPE32Header()->ImageBase);
454 static void printTLSDirectory(const COFFObjectFile *Obj) {
455 const pe32_header *PE32Header = Obj->getPE32Header();
456 const pe32plus_header *PE32PlusHeader = Obj->getPE32PlusHeader();
463 if (auto *TLSDir = Obj->getTLSDirectory32())
466 if (auto *TLSDir = Obj->getTLSDirectory64())
473 static void printLoadConfiguration(const COFFObjectFile *Obj) {
475 if (!Obj->getPE32Header())
479 if (Obj->getMachine() != COFF::IMAGE_FILE_MACHINE_I386)
482 auto *LoadConf = Obj->getLoadConfig32();
505 printSEHTable(Obj, LoadConf->SEHandlerTable, LoadConf->SEHandlerCount);
511 static void printImportTables(const COFFObjectFile *Obj) {
512 import_directory_iterator I = Obj->import_directory_begin();
513 import_directory_iterator E = Obj->import_directory_end();
517 for (const ImportDirectoryEntryRef &DirRef : Obj->import_directories()) {
547 if (Obj->getHintName(HintNameRVA, Hint, Name))
557 static void printExportTable(const COFFObjectFile *Obj) {
558 export_directory_iterator I = Obj->export_directory_begin();
559 export_directory_iterator E = Obj->export_directory_end();
612 static bool getPDataSection(const COFFObjectFile *Obj,
615 for (const SectionRef &Section : Obj->sections()) {
616 StringRef Name = unwrapOrError(Section.getName(), Obj->getFileName());
620 const coff_section *Pdata = Obj->getCOFFSection(Section);
627 if (Error E = Obj->getSectionContents(Pdata, Contents))
628 reportError(std::move(E), Obj->getFileName());
640 Error objdump::getCOFFRelocationValueString(const COFFObjectFile *Obj,
692 /// Prints out the given RuntimeFunction struct for x64, assuming that Obj is
694 static void printRuntimeFunction(const COFFObjectFile *Obj,
706 if (Obj->getRvaPtr(RF.UnwindInfoOffset, addr))
711 /// Prints out the given RuntimeFunction struct for x64, assuming that Obj is
717 static void printRuntimeFunctionRels(const COFFObjectFile *Obj,
746 Obj, Rels,
750 reportError(std::move(E), Obj->getFileName());
763 void objdump::printCOFFUnwindInfo(const COFFObjectFile *Obj) {
764 if (Obj->getMachine() != COFF::IMAGE_FILE_MACHINE_AMD64) {
774 if (!getPDataSection(Obj, Rels, RFStart, NumRFs))
781 printRuntimeFunction(Obj, RF);
788 printRuntimeFunctionRels(Obj, RF, SectionOffset, Rels);
793 COFFDumper CD(Obj);
794 const uint16_t Cha = Obj.getCharacteristics();
821 const time_t Timestamp = Obj.getTimeDateStamp();
824 if (const pe32_header *Hdr = Obj.getPE32Header())
826 else if (const pe32plus_header *Hdr = Obj.getPE32PlusHeader())
829 printTLSDirectory(&Obj);
830 printLoadConfiguration(&Obj);
831 printImportTables(&Obj);
832 printExportTable(&Obj);