[PATCH] D81948: [LLD][PowerPC] Add support for R_PPC64_GOT_PCREL34

Stefan Pintilie via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Jun 18 04:19:10 PDT 2020


stefanp marked an inline comment as done.
stefanp added inline comments.


================
Comment at: lld/test/ELF/ppc64-got-pcrel34-reloc.s:33
+# RELA:        0009a578  0000000200000014 R_PPC64_GLOB_DAT       0000000000000000 glob_int8 + 0
+.section .GLOB_INT_PCREL_OFFSET,"ax", at progbits
+	pld 3, glob_int8 at got@PCREL(0), 1
----------------
MaskRay wrote:
> sfertile wrote:
> > It this test just to show the linker doesn't modify the load instruction that follows the PC-relative load from the got?
> If you want to check not TOC (a variant of GOT) optimization is performed, use -no-pie (default) or -pie, instead of -shared.
Yes, this test is just to make sure that we don't make changes to the `lwa`. It may not be necessary from that perspective because that instruction does not have a relocation on it so there really is no risk of this problem. However, in my head they are the part of the same set so I want to check them both.


I'm not trying to check for not TOC. We have removed all of the TOC references on the compiler side. Or, maybe I didn't understand your comment...


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D81948/new/

https://reviews.llvm.org/D81948





More information about the llvm-commits mailing list