diff options
author | Evan Cheng <evan.cheng@apple.com> | 2008-12-10 01:33:59 +0000 |
---|---|---|
committer | Evan Cheng <evan.cheng@apple.com> | 2008-12-10 01:33:59 +0000 |
commit | 369e02da1b0f7a183c7d15a5d87a1a2c3db5f45a (patch) | |
tree | 0cc6c5fdc9c8555cd2d27377ae5852a2ecd8f4a4 /lib | |
parent | 2dae65d13b958c42561ece77e7f344ffb00c26c7 (diff) |
Fix a bug introduced by r59265. If lazy compilation is disabled, return actual function ptr instead of ptr to stub if function is already compiled.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@60822 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib')
-rw-r--r-- | lib/ExecutionEngine/JIT/JITEmitter.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/ExecutionEngine/JIT/JITEmitter.cpp b/lib/ExecutionEngine/JIT/JITEmitter.cpp index dd81f321c1..a74f53d2ab 100644 --- a/lib/ExecutionEngine/JIT/JITEmitter.cpp +++ b/lib/ExecutionEngine/JIT/JITEmitter.cpp @@ -611,7 +611,7 @@ void *JITEmitter::getPointerToGlobal(GlobalValue *V, void *Reference, // If we have already compiled the function, return a pointer to its body. Function *F = cast<Function>(V); void *ResultPtr; - if (!DoesntNeedStub) + if (!DoesntNeedStub && !TheJIT->isLazyCompilationDisabled()) // Return the function stub if it's already created. ResultPtr = Resolver.getFunctionStubIfAvailable(F); else |