[LLVMdev] x86_64 and large call offsets

Jeffrey Yasskin jyasskin at google.com
Thu Mar 18 13:10:49 PDT 2010


Yeah, I fixed this on x86 for llvm-2.7. It's broken in 2.6. (And it's
still broken on 2.7 for arm and ppc.)

On Thu, Mar 18, 2010 at 11:38 AM, Michael Beck <mm.beck at gmx.net> wrote:
> Hi all,
>
> I use a plain LLVM 2.6 to jit code for x86_64. My setup falls into the
> following problem:
>
> The generated code calls some external function whose address is set via
> addGlobalMapping(), but is more than 2GB away from the generated call.
> However, a call imm instruction using a 32bit offset is generated, which due
> to wrap around calls the wrong address.
> After digging for some time in the LLVM source I could not find code that
> handle this case.
>
> Is there something wrong in my setup? Should I use pre2.7 for this use case?
>
> Thanks in advance,
> --
> Michael Beck
>
> _______________________________________________
> LLVM Developers mailing list
> LLVMdev at cs.uiuc.edu         http://llvm.cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev
>




More information about the llvm-dev mailing list