lli/RecordingMemoryManager.cpp: Make it complain if _GLOBAL_OFFSET_TABLE_ were not provided.

FIXME: Would it be responsible to provide GOT?
llvm-svn: 188855
This commit is contained in:
NAKAMURA Takumi 2013-08-21 02:37:14 +00:00
parent 7aa49d8ca6
commit b46d3c8995
1 changed files with 7 additions and 0 deletions

View File

@ -113,5 +113,12 @@ void *RecordingMemoryManager::getPointerToNamedFunction(const std::string &Name,
// is called before ExecutionEngine::runFunctionAsMain() is called. // is called before ExecutionEngine::runFunctionAsMain() is called.
if (Name == "__main") return (void*)(intptr_t)&jit_noop; if (Name == "__main") return (void*)(intptr_t)&jit_noop;
// FIXME: Would it be responsible to provide GOT?
if (AbortOnFailure) {
if (Name == "_GLOBAL_OFFSET_TABLE_")
report_fatal_error("Program used external function '" + Name +
"' which could not be resolved!");
}
return NULL; return NULL;
} }