diff options
-rw-r--r-- | lib/Target/X86/X86JITInfo.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/Target/X86/X86JITInfo.cpp b/lib/Target/X86/X86JITInfo.cpp index fd495c7588..0cda7d3a43 100644 --- a/lib/Target/X86/X86JITInfo.cpp +++ b/lib/Target/X86/X86JITInfo.cpp @@ -463,7 +463,11 @@ void *X86JITInfo::emitFunctionStub(const Function* F, void *Fn, /// getPICJumpTableEntry - Returns the value of the jumptable entry for the /// specific basic block. intptr_t X86JITInfo::getPICJumpTableEntry(intptr_t BB, intptr_t Entry) { +#if defined(X86_64_JIT) + return BB - Entry; +#else return BB - PICBase; +#endif } /// relocate - Before the JIT can run a block of code that has been emitted, |