I missed the second part.
Am 05.07.2017 um 23:38 schrieb svk:
Hello,
the attached patch introduces a -mtls-gs command line option for clang
for the x86_64 target.
This option will force the usage of the GS instead of the FS register
for TLS references and
stack canary references.
This is particularly useful for low-level kernel-side development.
Best regards,
Sven Konietzny
diff --git a/include/clang/Driver/Options.td b/include/clang/Driver/Options.td
index cdd4c94..dbf27b5 100644
--- a/include/clang/Driver/Options.td
+++ b/include/clang/Driver/Options.td
@@ -1801,6 +1801,9 @@ def mno_mpx : Flag<["-"], "mno-mpx">, Group<m_x86_Features_Group>;
def mno_sgx : Flag<["-"], "mno-sgx">, Group<m_x86_Features_Group>;
def mno_prefetchwt1 : Flag<["-"], "mno-prefetchwt1">, Group<m_x86_Features_Group>;
+def mtls_gs : Flag<["-"], "mtls-gs">, Group<m_x86_Features_Group>,
+ HelpText<"Use GS register instead of FS register for TLS (x86_64 only)">;
+
def munaligned_access : Flag<["-"], "munaligned-access">, Group<m_arm_Features_Group>,
HelpText<"Allow memory accesses to be unaligned (AArch32/AArch64 only)">;
def mno_unaligned_access : Flag<["-"], "mno-unaligned-access">, Group<m_arm_Features_Group>,
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits