[PATCH] D61613: [LLD][ELF] Add the -z ifunc-noplt option

Mark Johnston via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue May 7 13:46:20 PDT 2019


markj added inline comments.


================
Comment at: lld/test/ELF/gnu-ifunc-noplt-i386.s:9
+
+// Check that the IRELATIVE relocations are after the JUMP_SLOT in the plt
+// CHECK: Relocations [
----------------
MaskRay wrote:
> Where is the `IRELATIVE` relocation? And I don't think the ordering matters.
My mistake, sorry. I left a few TODO comments and forgot to fix them before creating the review. There should not be any IRELATIVE relocations.


================
Comment at: lld/test/ELF/gnu-ifunc-noplt-i386.s:43
+// DISASM-EMPTY:
+// DISASM-NEXT:   bar2 at plt:
+// DISASM-NEXT:    401030:       ff 25 0c 30 40 00       jmpl    *4206604
----------------
MaskRay wrote:
> Not sure if you need `bar2 at plt` `zed2 at plt`. The normal PLT entries are checked by numerous tests.
I just reused them from gnu-ifunc-plt.s. If you prefer I can remove them, though I need to add -pie or so to ensure that lld doesn't try to resolve the relocations statically.


================
Comment at: lld/test/ELF/gnu-ifunc-noplt.s:38
+// DISASM-NEXT:   201026:       ff 25 e4 1f 00 00       jmpq    *8164(%rip)
+// DISASM-NEXT:   20102c:       0f 1f 40 00     nopl    (%rax)
+// DISASM-EMPTY:
----------------
MaskRay wrote:
> You FreeBSD llvm-objdump is old XD
> 
> The misindentation made me unhappy so I fixed it in rL358405.
Not too old :)

```
> llvm-objdump --version
LLVM (http://llvm.org/):
  LLVM version 8.0.0
```


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D61613





More information about the llvm-commits mailing list