[PATCH] D95262: [LLD][PowerPC] Fix bug in PC-Relative initial exec
Fangrui Song via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Mar 17 09:52:11 PDT 2021
MaskRay accepted this revision.
MaskRay added a comment.
This revision is now accepted and ready to land.
Sorry for my slow response. Mostly looks good.
================
Comment at: lld/ELF/Arch/PPC64.cpp:924
+ // Check if the add uses the same result register as the input register.
+ uint32_t RT = (tlsInstr & 0x03E00000) >> 21; // bits 6-10
+ uint32_t RA = (tlsInstr & 0x001F0000) >> 16; // bits 11-15
----------------
`RT` -> `rt`
================
Comment at: lld/ELF/Arch/PPC64.cpp:926
+ uint32_t RA = (tlsInstr & 0x001F0000) >> 16; // bits 11-15
+ if (RA == RT)
+ write32(loc - 1, NOP);
----------------
https://llvm.org/docs/CodingStandards.html#don-t-use-braces-on-simple-single-statement-bodies-of-if-else-loop-statements
// Use braces for the `if` block to keep it uniform with the else block.
================
Comment at: lld/test/ELF/ppc64-tls-le-relax.s:82
+ .size TGlobal, 4
+
+
----------------
Delete trailing empty lines
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D95262/new/
https://reviews.llvm.org/D95262
More information about the llvm-commits
mailing list