[PATCH] D86893: [PowerPC] Add support for TLS Initial Exec
Victor Huang via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Sep 1 12:47:15 PDT 2020
NeHuang added inline comments.
================
Comment at: lld/ELF/Arch/PPC64.cpp:868
+ // instruction it references.
+ uint32_t primaryOp = getPrimaryOpCode(read32(loc - 1));
+ if (primaryOp != 31)
----------------
I am not sure if the relocation we have here will be either 4 byte aligned or offset by one byte. Seems all the code here is based on the relocation is offset by one byte. Do we need to add an `error` if the offset is not offset by 1 byte?
================
Comment at: lld/ELF/Arch/PPC64.cpp:1270
case R_PPC64_GOT_PCREL34:
+ case R_PPC64_GOT_TPREL_PCREL34:
case R_PPC64_TPREL34: {
----------------
Can we combine these 3 relocation cases with `R_PPC64_PCREL34`?
================
Comment at: lld/test/ELF/Inputs/ppc64-tls-vardef.s:1
+## Thread Local Storage variable definitions.
+.section .tbss,"awT", at nobits
----------------
We can either use ` llvm-mc --defsym AUX=1` or `extract` to merge the variable definitions in `ppc64-tls-pcrel-ie.s`
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D86893/new/
https://reviews.llvm.org/D86893
More information about the llvm-commits
mailing list