[PATCH] D26133: [ELF] Relative relocations to absolute symbols in PIC

Rafael EspĂ­ndola via llvm-commits llvm-commits at lists.llvm.org
Mon Oct 31 10:26:53 PDT 2016


On 31 October 2016 at 13:01, Eugene Leviant <evgeny.leviant at gmail.com> wrote:
>> generate a dynamic relocation when the expression is relative relocation to an absolute symbol
>
> Looks like that's what I was trying to fix in https://reviews.llvm.org/D25560
>
>> "foo = ." is not actually absolute
>
> It's not the only problem. For instance `foo = variable` is also
> absolute as well as `foo = ADDR(.section)`.
> Also when I define `foo = 0` in script and use ld/gold, foo is a load
> address of an image. When I use lld it's just zero.
>

Yes, absoluteness is a property of the expression. I am writing a
patch for that.

Cheers,
Rafael


More information about the llvm-commits mailing list