aboutsummaryrefslogtreecommitdiffstats
path: root/include/llvm/ExecutionEngine/RuntimeDyld.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/llvm/ExecutionEngine/RuntimeDyld.h')
-rw-r--r--include/llvm/ExecutionEngine/RuntimeDyld.h16
1 files changed, 10 insertions, 6 deletions
diff --git a/include/llvm/ExecutionEngine/RuntimeDyld.h b/include/llvm/ExecutionEngine/RuntimeDyld.h
index f123ffb..3605b9e 100644
--- a/include/llvm/ExecutionEngine/RuntimeDyld.h
+++ b/include/llvm/ExecutionEngine/RuntimeDyld.h
@@ -26,19 +26,21 @@ namespace object {
}
class RuntimeDyldImpl;
+class RuntimeDyldCheckerImpl;
class ObjectImage;
class RuntimeDyld {
- friend class RuntimeDyldChecker;
+ friend class RuntimeDyldCheckerImpl;
RuntimeDyld(const RuntimeDyld &) LLVM_DELETED_FUNCTION;
void operator=(const RuntimeDyld &) LLVM_DELETED_FUNCTION;
// RuntimeDyldImpl is the actual class. RuntimeDyld is just the public
// interface.
- RuntimeDyldImpl *Dyld;
+ std::unique_ptr<RuntimeDyldImpl> Dyld;
RTDyldMemoryManager *MM;
bool ProcessAllSections;
+ RuntimeDyldCheckerImpl *Checker;
protected:
// Change the address associated with a section when resolving relocations.
// Any relocations already associated with the symbol will be re-resolved.
@@ -51,22 +53,24 @@ public:
/// Ownership of the input buffer is transferred to the ObjectImage
/// instance returned from this function if successful. In the case of load
/// failure, the input buffer will be deleted.
- ObjectImage *loadObject(ObjectBuffer *InputBuffer);
+ std::unique_ptr<ObjectImage>
+ loadObject(std::unique_ptr<ObjectBuffer> InputBuffer);
/// Prepare the referenced object file for execution.
/// Ownership of the input object is transferred to the ObjectImage
/// instance returned from this function if successful. In the case of load
/// failure, the input object will be deleted.
- ObjectImage *loadObject(std::unique_ptr<object::ObjectFile> InputObject);
+ std::unique_ptr<ObjectImage>
+ loadObject(std::unique_ptr<object::ObjectFile> InputObject);
/// Get the address of our local copy of the symbol. This may or may not
/// be the address used for relocation (clients can copy the data around
/// and resolve relocatons based on where they put it).
- void *getSymbolAddress(StringRef Name);
+ void *getSymbolAddress(StringRef Name) const;
/// Get the address of the target copy of the symbol. This is the address
/// used for relocation.
- uint64_t getSymbolLoadAddress(StringRef Name);
+ uint64_t getSymbolLoadAddress(StringRef Name) const;
/// Resolve the relocations for all symbols we currently know about.
void resolveRelocations();