[PATCH] Introduce new gold plugin option "relocation-pic"

Alexey Samsonov samsonov at google.com
Tue Apr 15 09:51:49 PDT 2014


  In general, sanitizers don't work with -static flag at all, so there shouldn't be any problems with "interaction".


================
Comment at: lib/Driver/Tools.cpp:6845
@@ -6845,1 +6844,3 @@
+    !Args.hasArg(options::OPT_static) &&
+    (Args.hasArg(options::OPT_pie) || ToolChain.isPIEDefault() || isAndroid);
 
----------------
I don't understand this part - effectively you're making -pie the default on Android. Is it really the intended behavior?

If yes, shouldn't you implement it in ToolChain.isPIEDefault() instead?


http://reviews.llvm.org/D2668






More information about the llvm-commits mailing list