aboutsummaryrefslogtreecommitdiffstats
path: root/tools/llvm-objdump
diff options
context:
space:
mode:
authorChandler Carruth <chandlerc@gmail.com>2011-11-27 10:37:47 +0000
committerChandler Carruth <chandlerc@gmail.com>2011-11-27 10:37:47 +0000
commit790552c20fbd8daa77d343419f0f6ec4e7fa1457 (patch)
tree548fd44cb22491e6367bc1c611bfab583b7730d1 /tools/llvm-objdump
parent7096692fd9ab5753f17500a27d400d1544b6d3d8 (diff)
downloadexternal_llvm-790552c20fbd8daa77d343419f0f6ec4e7fa1457.zip
external_llvm-790552c20fbd8daa77d343419f0f6ec4e7fa1457.tar.gz
external_llvm-790552c20fbd8daa77d343419f0f6ec4e7fa1457.tar.bz2
Revert r145180 as it is causing test failures on all the bots.
Original commit message: Fixed ObjectFile functions: - getSymbolOffset() renamed as getSymbolFileOffset() - getSymbolFileOffset(), getSymbolAddress(), getRelocationAddress() returns same result for ELFObjectFile, MachOObjectFile and COFFObjectFile. - added getRelocationOffset() - fixed MachOObjectFile::getSymbolSize() - fixed MachOObjectFile::getSymbolSection() - fixed MachOObjectFile::getSymbolOffset() for symbols without section data. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@145182 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'tools/llvm-objdump')
-rw-r--r--tools/llvm-objdump/MachODump.cpp4
-rw-r--r--tools/llvm-objdump/llvm-objdump.cpp4
2 files changed, 4 insertions, 4 deletions
diff --git a/tools/llvm-objdump/MachODump.cpp b/tools/llvm-objdump/MachODump.cpp
index ef5258d..4ccae51 100644
--- a/tools/llvm-objdump/MachODump.cpp
+++ b/tools/llvm-objdump/MachODump.cpp
@@ -419,7 +419,7 @@ void llvm::DisassembleInputMachO(StringRef Filename) {
// Start at the address of the symbol relative to the section's address.
uint64_t Start = 0;
- Symbols[SymIdx].getFileOffset(Start);
+ Symbols[SymIdx].getOffset(Start);
// Stop disassembling either at the beginning of the next symbol or at
// the end of the section.
@@ -432,7 +432,7 @@ void llvm::DisassembleInputMachO(StringRef Filename) {
if (NextSymType == SymbolRef::ST_Function) {
Sections[SectIdx].containsSymbol(Symbols[NextSymIdx],
containsNextSym);
- Symbols[NextSymIdx].getFileOffset(NextSym);
+ Symbols[NextSymIdx].getOffset(NextSym);
break;
}
++NextSymIdx;
diff --git a/tools/llvm-objdump/llvm-objdump.cpp b/tools/llvm-objdump/llvm-objdump.cpp
index 0f0ae1c..9071d58 100644
--- a/tools/llvm-objdump/llvm-objdump.cpp
+++ b/tools/llvm-objdump/llvm-objdump.cpp
@@ -186,7 +186,7 @@ static void DisassembleObject(const ObjectFile *Obj, bool InlineRelocs) {
bool contains;
if (!error(i->containsSymbol(*si, contains)) && contains) {
uint64_t Address;
- if (error(si->getFileOffset(Address))) break;
+ if (error(si->getOffset(Address))) break;
StringRef Name;
if (error(si->getName(Name))) break;
Symbols.push_back(std::make_pair(Address, Name));
@@ -485,7 +485,7 @@ static void PrintSymbolTable(const ObjectFile *o) {
uint64_t Size;
section_iterator Section = o->end_sections();
if (error(si->getName(Name))) continue;
- if (error(si->getFileOffset(Offset))) continue;
+ if (error(si->getOffset(Offset))) continue;
if (error(si->isGlobal(Global))) continue;
if (error(si->getType(Type))) continue;
if (error(si->isWeak(Weak))) continue;