<div dir="ltr">I think we actually want to implement this flag in the near future. Maybe Sri can say more.</div><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Jul 7, 2017 at 4:32 AM, Jordan Glover via cfe-dev <span dir="ltr"><<a href="mailto:cfe-dev@lists.llvm.org" target="_blank">cfe-dev@lists.llvm.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div>In GCC there is a -fno-plt [1] flag not implemented in Clang which results in compilation failure:<br></div><div>clang-4.0: error: unknown argument: '-fno-plt'<br></div><div><br></div><div>I created patch that adds -fno-plt and -fplt to existing ignored flags list making it compatible with gcc for package building. I tested it and it works as expected. I sent this patch already to cfe-commits [2] list as advised [3]. I would be grateful if anyone could review it and merge when it's acceptable.<br></div><div><br></div><div>Thank you for your attention.
Jordan Glover<br></div><div><br></div><div>[1] <a href="https://gcc.gnu.org/onlinedocs/gcc-7.1.0/gcc/Code-Gen-Options.html#Code-Gen-Options" target="_blank">https://gcc.gnu.org/<wbr>onlinedocs/gcc-7.1.0/gcc/Code-<wbr>Gen-Options.html#Code-Gen-<wbr>Options</a><br></div><div>[2] <a href="https://lists.llvm.org/pipermail/cfe-commits/Week-of-Mon-20170703/197341.html" target="_blank">https://lists.llvm.org/<wbr>pipermail/cfe-commits/Week-of-<wbr>Mon-20170703/197341.html</a><br></div><div>[3] <a href="https://clang.llvm.org/hacking.html" target="_blank">https://clang.llvm.org/<wbr>hacking.html</a><br></div><div><br></div><div>Index: include/clang/Driver/Options.<wbr>td<br>==============================<wbr>==============================<wbr>=======<br>--- include/clang/Driver/Options.<wbr>td (revision 307280)<br>+++ include/clang/Driver/Options.<wbr>td (working copy)<br>@@ -2497,6 +2497,7 @@<br> defm non_call_exceptions : BooleanFFlag<"non-call-<wbr>exceptions">, Group<clang_ignored_f_Group>;<br> defm peel_loops : BooleanFFlag<"peel-loops">, Group<clang_ignored_gcc_<wbr>optimization_f_Group>;<br> defm permissive : BooleanFFlag<"permissive">, Group<clang_ignored_f_Group>;<br>+defm plt : BooleanFFlag<"plt">, Group<clang_ignored_f_Group>;<br> defm prefetch_loop_arrays : BooleanFFlag<"prefetch-loop-<wbr>arrays">, Group<clang_ignored_gcc_<wbr>optimization_f_Group>;<br> defm printf : BooleanFFlag<"printf">, Group<clang_ignored_f_Group>;<br> defm profile : BooleanFFlag<"profile">, Group<clang_ignored_f_Group>;<br>Index: test/Driver/clang_f_opts.c<br>==============================<wbr>==============================<wbr>=======<br>--- test/Driver/clang_f_opts.c (revision 307280)<br>+++ test/Driver/clang_f_opts.c (working copy)<br>@@ -275,6 +275,7 @@<br> // RUN: -fno-fat-lto-objects -ffat-lto-objects <wbr> \<br> // RUN: -fno-merge-constants -fmerge-constants <wbr> \<br> // RUN: -fno-caller-saves -fcaller-saves <wbr> \<br>+// RUN: -fno-plt <wbr> <wbr> \<br> // RUN: -fno-reorder-blocks -freorder-blocks <wbr> \<br> // RUN: -fno-schedule-insns2 -fschedule-insns2 <wbr> \<br> // RUN: -fno-stack-check <wbr> <wbr> \<br>@@ -281,6 +282,7 @@<br> // RUN: -fno-check-new -fcheck-new <wbr> \<br> // RUN: -ffriend-injection <wbr> <wbr> \<br> // RUN: -fno-implement-inlines -fimplement-inlines <wbr> \<br>+// RUN: -fplt <wbr> <wbr> \<br> // RUN: -fstack-check <wbr> <wbr> \<br> // RUN: -fforce-addr <wbr> <wbr> \<br> // RUN: -malign-functions=100 <wbr> <wbr> \<br><br></div><br>______________________________<wbr>_________________<br>
cfe-dev mailing list<br>
<a href="mailto:cfe-dev@lists.llvm.org">cfe-dev@lists.llvm.org</a><br>
<a href="http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev" rel="noreferrer" target="_blank">http://lists.llvm.org/cgi-bin/<wbr>mailman/listinfo/cfe-dev</a><br>
<br></blockquote></div><br></div>