[PATCH] D62106: [X86] Support -fno-plt __tls_get_addr calls

Reid Kleckner via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed May 22 14:36:38 PDT 2019


rnk accepted this revision.
rnk added a comment.
This revision is now accepted and ready to land.

Looks good to me.

I'm not 100% following the discussion of using EBX as the PIC register, but I think it's a pre-existing issue for 32-bit code. I think it's unlikely that anyone will ever care enough to improve our 32-bit codegen, so it seems reasonable to leave it alone for now (or forever).



================
Comment at: lib/Target/X86/X86MCInstLower.cpp:690
-
-  bool needsPadding = MI.getOpcode() == X86::TLS_addr64;
-
----------------
I think it would be more readable to retain this NeedsPadding variable, but make it evaluate to `SRVK == MCSymbolRefExpr::VK_TLSGD`.


Repository:
  rL LLVM

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

https://reviews.llvm.org/D62106





More information about the llvm-commits mailing list