aboutsummaryrefslogtreecommitdiffstats
path: root/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldELF.h
diff options
context:
space:
mode:
Diffstat (limited to 'lib/ExecutionEngine/RuntimeDyld/RuntimeDyldELF.h')
-rw-r--r--lib/ExecutionEngine/RuntimeDyld/RuntimeDyldELF.h29
1 files changed, 16 insertions, 13 deletions
diff --git a/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldELF.h b/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldELF.h
index 4aeab81..b4414b0 100644
--- a/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldELF.h
+++ b/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldELF.h
@@ -28,9 +28,11 @@ std::error_code Check(std::error_code Err) {
}
return Err;
}
+
} // end anonymous namespace
class RuntimeDyldELF : public RuntimeDyldImpl {
+
void resolveRelocation(const SectionEntry &Section, uint64_t Offset,
uint64_t Value, uint32_t Type, int64_t Addend,
uint64_t SymOffset = 0);
@@ -81,9 +83,11 @@ class RuntimeDyldELF : public RuntimeDyldImpl {
return 1;
}
- void findPPC64TOCSection(ObjectImage &Obj, ObjSectionToIDMap &LocalSections,
+ void findPPC64TOCSection(const ObjectFile &Obj,
+ ObjSectionToIDMap &LocalSections,
RelocationValueRef &Rel);
- void findOPDEntrySection(ObjectImage &Obj, ObjSectionToIDMap &LocalSections,
+ void findOPDEntrySection(const ObjectFile &Obj,
+ ObjSectionToIDMap &LocalSections,
RelocationValueRef &Rel);
uint64_t findGOTEntry(uint64_t LoadAddr, uint64_t Offset);
@@ -104,24 +108,23 @@ class RuntimeDyldELF : public RuntimeDyldImpl {
SmallVector<SID, 2> RegisteredEHFrameSections;
public:
- RuntimeDyldELF(RTDyldMemoryManager *mm) : RuntimeDyldImpl(mm) {}
+ RuntimeDyldELF(RTDyldMemoryManager *mm);
+ virtual ~RuntimeDyldELF();
+
+ std::unique_ptr<RuntimeDyld::LoadedObjectInfo>
+ loadObject(const object::ObjectFile &O) override;
void resolveRelocation(const RelocationEntry &RE, uint64_t Value) override;
relocation_iterator
processRelocationRef(unsigned SectionID, relocation_iterator RelI,
- ObjectImage &Obj, ObjSectionToIDMap &ObjSectionToID,
- const SymbolTableMap &Symbols, StubMap &Stubs) override;
- bool isCompatibleFormat(const ObjectBuffer *Buffer) const override;
- bool isCompatibleFile(const object::ObjectFile *Buffer) const override;
+ const ObjectFile &Obj,
+ ObjSectionToIDMap &ObjSectionToID,
+ StubMap &Stubs) override;
+ bool isCompatibleFile(const object::ObjectFile &Obj) const override;
void registerEHFrames() override;
void deregisterEHFrames() override;
- void finalizeLoad(ObjectImage &ObjImg,
+ void finalizeLoad(const ObjectFile &Obj,
ObjSectionToIDMap &SectionMap) override;
- virtual ~RuntimeDyldELF();
-
- static std::unique_ptr<ObjectImage>
- createObjectImage(std::unique_ptr<ObjectBuffer> InputBuffer);
- static ObjectImage *createObjectImageFromFile(std::unique_ptr<object::ObjectFile> Obj);
};
} // end namespace llvm