If the user requested a zero-base-shadow sanitizer, infer -pie and -fPIC when appropriate.
Differential Revision: http://llvm-reviews.chandlerc.com/D502
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@179082 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/include/clang/Driver/ToolChain.h b/include/clang/Driver/ToolChain.h
index ae9e397..4f236b7 100644
--- a/include/clang/Driver/ToolChain.h
+++ b/include/clang/Driver/ToolChain.h
@@ -195,9 +195,13 @@
/// \brief Test whether this toolchain defaults to PIC.
virtual bool isPICDefault() const = 0;
- /// \brief Tests whether this toolchain forces its default for PIC or non-PIC.
- /// If this returns true, any PIC related flags should be ignored and instead
- /// the result of \c isPICDefault() is used exclusively.
+ /// \brief Test whether this toolchain defaults to PIE.
+ virtual bool isPIEDefault() const = 0;
+
+ /// \brief Tests whether this toolchain forces its default for PIC, PIE or
+ /// non-PIC. If this returns true, any PIC related flags should be ignored
+ /// and instead the results of \c isPICDefault() and \c isPIEDefault() are
+ /// used exclusively.
virtual bool isPICDefaultForced() const = 0;
/// SupportsProfiling - Does this tool chain support -pg.