aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/ExecutionEngine/RuntimeDyld/RuntimeDyldELF.cpp8
-rw-r--r--lib/Object/COFFObjectFile.cpp5
-rw-r--r--lib/Object/MachOObjectFile.cpp6
3 files changed, 4 insertions, 15 deletions
diff --git a/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldELF.cpp b/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldELF.cpp
index d4d84d31d0..57676ffaf4 100644
--- a/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldELF.cpp
+++ b/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldELF.cpp
@@ -519,10 +519,10 @@ void RuntimeDyldELF::findOPDEntrySection(ObjectImage &Obj,
SymbolRef TargetSymbol;
uint64_t TargetSymbolOffset;
- int64_t TargetAdditionalInfo;
check(i->getSymbol(TargetSymbol));
check(i->getOffset(TargetSymbolOffset));
- check(i->getAdditionalInfo(TargetAdditionalInfo));
+ int64_t Addend;
+ check(getELFRelocationAddend(*i, Addend));
i = i.increment(err);
if (i == e)
@@ -544,7 +544,7 @@ void RuntimeDyldELF::findOPDEntrySection(ObjectImage &Obj,
section_iterator tsi(Obj.end_sections());
check(TargetSymbol.getSection(tsi));
Rel.SectionID = findOrEmitSection(Obj, (*tsi), true, LocalSections);
- Rel.Addend = (intptr_t)TargetAdditionalInfo;
+ Rel.Addend = (intptr_t)Addend;
return;
}
}
@@ -742,7 +742,7 @@ void RuntimeDyldELF::processRelocationRef(unsigned SectionID,
uint64_t RelType;
Check(RelI.getType(RelType));
int64_t Addend;
- Check(RelI.getAdditionalInfo(Addend));
+ Check(getELFRelocationAddend(RelI, Addend));
SymbolRef Symbol;
Check(RelI.getSymbol(Symbol));
diff --git a/lib/Object/COFFObjectFile.cpp b/lib/Object/COFFObjectFile.cpp
index 70fec321ba..f5b49ab061 100644
--- a/lib/Object/COFFObjectFile.cpp
+++ b/lib/Object/COFFObjectFile.cpp
@@ -798,11 +798,6 @@ error_code COFFObjectFile::getRelocationTypeName(DataRefImpl Rel,
#undef LLVM_COFF_SWITCH_RELOC_TYPE_NAME
-error_code COFFObjectFile::getRelocationAdditionalInfo(DataRefImpl Rel,
- int64_t &Res) const {
- Res = 0;
- return object_error::success;
-}
error_code COFFObjectFile::getRelocationValueString(DataRefImpl Rel,
SmallVectorImpl<char> &Result) const {
const coff_relocation *reloc = toRel(Rel);
diff --git a/lib/Object/MachOObjectFile.cpp b/lib/Object/MachOObjectFile.cpp
index dfd8d3d3dd..af14c72145 100644
--- a/lib/Object/MachOObjectFile.cpp
+++ b/lib/Object/MachOObjectFile.cpp
@@ -989,12 +989,6 @@ MachOObjectFile::getRelocationTypeName(DataRefImpl Rel,
return object_error::success;
}
-error_code MachOObjectFile::getRelocationAdditionalInfo(DataRefImpl Rel,
- int64_t &Res) const {
- Res = 0;
- return object_error::success;
-}
-
error_code
MachOObjectFile::getRelocationValueString(DataRefImpl Rel,
SmallVectorImpl<char> &Result) const {