[LLVMbugs] [Bug 22457] New: Interpreter ignores LazyFunctionCreator and always perform symbol search
bugzilla-daemon at llvm.org
bugzilla-daemon at llvm.org
Wed Feb 4 06:28:01 PST 2015
http://llvm.org/bugs/show_bug.cgi?id=22457
Bug ID: 22457
Summary: Interpreter ignores LazyFunctionCreator and always
perform symbol search
Product: libraries
Version: trunk
Hardware: All
OS: All
Status: NEW
Severity: normal
Priority: P
Component: Interpreter
Assignee: unassignedbugs at nondot.org
Reporter: pguyot at kallisys.net
CC: llvmbugs at cs.uiuc.edu
Classification: Unclassified
The interpreter ignores the following:
theInterpreterEngine->DisableSymbolSearching();
theInterpreterEngine->InstallLazyFunctionCreator(LazyFunctionCreator);
It will always perform symbol-based search for external functions.
The issue probably is in ExternalFunctions.cpp
#ifdef USE_LIBFFI
std::map<const Function *, RawFunc>::iterator RF = RawFunctions->find(F);
RawFunc RawFn;
if (RF == RawFunctions->end()) {
RawFn = (RawFunc)(intptr_t)
sys::DynamicLibrary::SearchForAddressOfSymbol(F->getName());
if (!RawFn)
RawFn = (RawFunc)(intptr_t)getPointerToGlobalIfAvailable(F);
if (RawFn != 0)
RawFunctions->insert(std::make_pair(F, RawFn)); // Cache for later
} else {
RawFn = RF->second;
}
As a result, interpreter cannot call functions with names not supported by the
dynamic linker.
--
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20150204/75e92917/attachment.html>
More information about the llvm-bugs
mailing list