[PATCH] D95124: [lld][ELF][test] Add testing for IE/LD TLS weak undef references

Fangrui Song via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Jan 21 11:15:37 PST 2021


MaskRay accepted this revision.
MaskRay added a comment.

LGTM.



================
Comment at: lld/test/ELF/tls-weak-undef.s:12
+
+## A weak symbol does not fetch a lazy definition.
+# RUN: ld.lld %texec.o --start-lib %tdef.o --end-lib -o %tlazy
----------------
A TLS undefined weak symbol

undefined is important.
TLS as a modifier is also useful.


================
Comment at: lld/test/ELF/tls-weak-undef.s:24
+# RUN: ld.lld -shared %tdef.o -o %tdef.so
+# RUN: not ld.lld %texec.o %tdef.so -o /dev/null 2>&1 | FileCheck --check-prefix=COPYRELOC %s
+
----------------
Copy relocations are specific to executables. I think COPYRELOC may be misguiding.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D95124



More information about the llvm-commits mailing list