diff options
author | Michael J. Spencer <bigcheesegs@gmail.com> | 2011-10-07 19:25:32 +0000 |
---|---|---|
committer | Michael J. Spencer <bigcheesegs@gmail.com> | 2011-10-07 19:25:32 +0000 |
commit | 4344b1ef9b3721a5ebc2e024f753772a1e4ddd92 (patch) | |
tree | 4e940dd99f2b1745799c9f1544fc1a88b3e5594f /include/llvm/Object/COFF.h | |
parent | 186ffac4d35c9ea669b03ac75f5e21bff1f01a7f (diff) | |
download | llvm-4344b1ef9b3721a5ebc2e024f753772a1e4ddd92.tar.gz llvm-4344b1ef9b3721a5ebc2e024f753772a1e4ddd92.tar.bz2 llvm-4344b1ef9b3721a5ebc2e024f753772a1e4ddd92.tar.xz |
Change relocation API to be per section. This time without breaking GCC.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@141385 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/Object/COFF.h')
-rw-r--r-- | include/llvm/Object/COFF.h | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/include/llvm/Object/COFF.h b/include/llvm/Object/COFF.h index 6a91008a40..9d83e287e4 100644 --- a/include/llvm/Object/COFF.h +++ b/include/llvm/Object/COFF.h @@ -84,6 +84,8 @@ private: error_code getSection(int32_t index, const coff_section *&Res) const; error_code getString(uint32_t offset, StringRef &Res) const; + error_code getSymbol(uint32_t index, + const coff_symbol *&Res) const; const coff_symbol *toSymb(DataRefImpl Symb) const; const coff_section *toSec(DataRefImpl Sec) const; @@ -110,6 +112,8 @@ protected: virtual error_code isSectionBSS(DataRefImpl Sec, bool &Res) const; virtual error_code sectionContainsSymbol(DataRefImpl Sec, DataRefImpl Symb, bool &Result) const; + virtual relocation_iterator getSectionRelBegin(DataRefImpl Sec) const; + virtual relocation_iterator getSectionRelEnd(DataRefImpl Sec) const; virtual error_code getRelocationNext(DataRefImpl Rel, RelocationRef &Res) const; @@ -119,16 +123,19 @@ protected: SymbolRef &Res) const; virtual error_code getRelocationType(DataRefImpl Rel, uint32_t &Res) const; + virtual error_code getRelocationTypeName(DataRefImpl Rel, + SmallVectorImpl<char> &Result) const; virtual error_code getRelocationAdditionalInfo(DataRefImpl Rel, int64_t &Res) const; + virtual error_code getRelocationValueString(DataRefImpl Rel, + SmallVectorImpl<char> &Result) const; + public: COFFObjectFile(MemoryBuffer *Object, error_code &ec); virtual symbol_iterator begin_symbols() const; virtual symbol_iterator end_symbols() const; virtual section_iterator begin_sections() const; virtual section_iterator end_sections() const; - virtual relocation_iterator begin_relocations() const; - virtual relocation_iterator end_relocations() const; virtual uint8_t getBytesInAddress() const; virtual StringRef getFileFormatName() const; |