[PATCH] D53905: [ELF] Refactor TLS layout TargetInfo config. NFC.

James Clarke via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Oct 30 15:44:51 PDT 2018


jrtc27 added a comment.

Hmm, I'm not sure I like making `TlsTpOffset` negative, the name reads as meaning the offset of the thread pointer, which is *positive*, and in general linkers, loaders and libcs like to define it as a positive constant (along with others, such as `PPC64TocOffset` and `DynamicThreadPointerOffset` in PPC64.cpp). Personally I'd leave `TlsTpOffset` as being positive, rename `getTlsTpOffset` (maybe `getTlsOffsetFromTp`?) and make it negate `TlsTpOffset`. Thoughts? Otherwise looks correct to me.


Repository:
  rLLD LLVM Linker

https://reviews.llvm.org/D53905





More information about the llvm-commits mailing list