[PATCH] D15043: [ELF/AArch64] Add support for the R_AARCH64_COPY relocation.

Igor Kudrin via llvm-commits llvm-commits at lists.llvm.org
Tue Dec 1 09:47:37 PST 2015


ikudrin added a comment.

In http://reviews.llvm.org/D15043#299593, @ruiu wrote:

> What was the conclusion on PREL relocations?




- Neither ld, nor gold create a COPY relocation for a source PREL relocation.
- For me, it's hard to imagine using a PREL relocation against an external preemtible object symbol.

So, nobody probably will suffer.

We have another difference from gold, concerning ABS relocations. They don't generate a COPY relocation if an ABS relocation targets a r/w segment; in this case, they just preserve the original relocation. Everything works fine because the dynamic linker from glibc supports ABS{32,64} relocations in addition to the standard dynamic relocations. I am not sure about other dynamic linkers, in particular, on FreeBSD, and anyway ld generates COPY relocations in that situation. Thus, I decided to generate COPY relocations in that case.


http://reviews.llvm.org/D15043





More information about the llvm-commits mailing list