[LLVMdev] cross-section differences in MC generation
Rafael Avila de Espindola
rafael.espindola at gmail.com
Thu Jun 26 13:26:17 PDT 2014
Sent from my iPhone
> On Jun 26, 2014, at 12:33, Justin Hibbits <jrh29 at alumni.cwru.edu> wrote:
>
> I'm working on Position-independent code for 32-bit PowerPC, but
> running into a problem. At the beginning of each function, there's a
> pre-word that's the difference between the PICBase (.L1$pb) and the
> GOT. This works fine when generating assembly output, but it fails
> when generating ELF output, with the error "Cannot represent a
> difference across sections" (line 847, lib/MC/ELFObjectWriter.cpp).
>
> Roman Divacky suggested I try something with 'let EncoderMethod = ...'
> similar to how the TOC entries are done for ppc64. However, I'm not
> sure if that would work, given that the TOC on ppc64 is handled
> differently from the GOT on ppc32, and I'm not sure how to represent
> that if it could work.
>
> Any ideas on how a cross-section diff and relocation could be
> represented for this?
>
Can you post the generated assembly that works with gas but fails with llvm-mc?
> Thanks,
> Justin
> _______________________________________________
> 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