1 //===-- ObjDumper.h -------------------------------------------------------===//
3 // The LLVM Compiler Infrastructure
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
8 //===----------------------------------------------------------------------===//
10 #ifndef LLVM_READOBJ_OBJDUMPER_H
11 #define LLVM_READOBJ_OBJDUMPER_H
28 ObjDumper(StreamWriter& Writer);
31 virtual void printFileHeaders() = 0;
32 virtual void printSections() = 0;
33 virtual void printRelocations() = 0;
34 virtual void printSymbols() = 0;
35 virtual void printDynamicSymbols() = 0;
36 virtual void printUnwindInfo() = 0;
38 // Only implemented for ELF at this time.
39 virtual void printDynamicTable() { }
40 virtual void printNeededLibraries() { }
41 virtual void printProgramHeaders() { }
47 error_code createCOFFDumper(const object::ObjectFile *Obj,
49 OwningPtr<ObjDumper> &Result);
51 error_code createELFDumper(const object::ObjectFile *Obj,
53 OwningPtr<ObjDumper> &Result);
55 error_code createMachODumper(const object::ObjectFile *Obj,
57 OwningPtr<ObjDumper> &Result);