[llvm] r222859 - [MCJIT] Move get-any-symbol-load-address logic out of RuntimeDyld and into
Lang Hames
lhames at gmail.com
Wed Nov 26 16:12:40 PST 2014
Author: lhames
Date: Wed Nov 26 18:12:28 2014
New Revision: 222859
URL: http://llvm.org/viewvc/llvm-project?rev=222859&view=rev
Log:
[MCJIT] Move get-any-symbol-load-address logic out of RuntimeDyld and into
RuntimeDyldChecker.
RuntimeDyld instances should only provide lookup for locally defined
symbols.
Modified:
llvm/trunk/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldChecker.cpp
llvm/trunk/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldImpl.h
Modified: llvm/trunk/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldChecker.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldChecker.cpp?rev=222859&r1=222858&r2=222859&view=diff
==============================================================================
--- llvm/trunk/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldChecker.cpp (original)
+++ llvm/trunk/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldChecker.cpp Wed Nov 26 18:12:28 2014
@@ -740,7 +740,9 @@ uint64_t RuntimeDyldCheckerImpl::getSymb
}
uint64_t RuntimeDyldCheckerImpl::getSymbolRemoteAddr(StringRef Symbol) const {
- return getRTDyld().getAnySymbolRemoteAddress(Symbol);
+ if (uint64_t InternalSymbolAddr = getRTDyld().getSymbolLoadAddress(Symbol))
+ return InternalSymbolAddr;
+ return getRTDyld().MemMgr->getSymbolAddress(Symbol);
}
uint64_t RuntimeDyldCheckerImpl::readMemoryAtAddr(uint64_t SrcAddr,
Modified: llvm/trunk/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldImpl.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldImpl.h?rev=222859&r1=222858&r2=222859&view=diff
==============================================================================
--- llvm/trunk/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldImpl.h (original)
+++ llvm/trunk/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldImpl.h Wed Nov 26 18:12:28 2014
@@ -159,14 +159,6 @@ public:
class RuntimeDyldImpl {
friend class RuntimeDyld::LoadedObjectInfo;
friend class RuntimeDyldCheckerImpl;
-private:
-
- uint64_t getAnySymbolRemoteAddress(StringRef Symbol) {
- if (uint64_t InternalSymbolAddr = getSymbolLoadAddress(Symbol))
- return InternalSymbolAddr;
- return MemMgr->getSymbolAddress(Symbol);
- }
-
protected:
// The MemoryManager to load objects into.
RTDyldMemoryManager *MemMgr;
More information about the llvm-commits
mailing list