aboutsummaryrefslogtreecommitdiff
path: root/lib/Basic/Targets.cpp
diff options
context:
space:
mode:
authorDaniel Dunbar <daniel@zuster.org>2009-11-17 09:15:44 +0000
committerDaniel Dunbar <daniel@zuster.org>2009-11-17 09:15:44 +0000
commit2fc430d5483545b47a5a22f45338ff54f5362e34 (patch)
treec71568897bdabd54f971cae8ea922cbbc4a0cacc /lib/Basic/Targets.cpp
parentca74ae733619b91413f86f06965089f6abc8d100 (diff)
Eliminate TargetInfo::getDefaultLangOptions, this kind of logic is better done
in the driver. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@89073 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Basic/Targets.cpp')
-rw-r--r--lib/Basic/Targets.cpp24
1 files changed, 0 insertions, 24 deletions
diff --git a/lib/Basic/Targets.cpp b/lib/Basic/Targets.cpp
index 3a4d115db2..07c2bb960b 100644
--- a/lib/Basic/Targets.cpp
+++ b/lib/Basic/Targets.cpp
@@ -155,24 +155,6 @@ static void getDarwinIPhoneOSDefines(std::vector<char> &Defs,
iPhoneOSStr);
}
-/// GetDarwinLanguageOptions - Set the default language options for darwin.
-static void GetDarwinLanguageOptions(LangOptions &Opts,
- const llvm::Triple &Triple) {
- unsigned MajorVersion = Triple.getDarwinMajorNumber();
-
- // Blocks and stack protectors default to on for 10.6 (darwin10) and beyond.
- if (MajorVersion > 9) {
- Opts.Blocks = 1;
- Opts.setStackProtectorMode(LangOptions::SSPOn);
- }
-
- // Non-fragile ABI (in 64-bit mode) default to on for 10.5 (darwin9) and
- // beyond.
- if (MajorVersion >= 9 && Opts.ObjC1 &&
- Triple.getArch() == llvm::Triple::x86_64)
- Opts.ObjCNonFragileABI = 1;
-}
-
namespace {
template<typename Target>
class DarwinTargetInfo : public OSTargetInfo<Target> {
@@ -183,12 +165,6 @@ protected:
getDarwinOSXDefines(Defines, Triple);
}
- /// getDefaultLangOptions - Allow the target to specify default settings for
- /// various language options. These may be overridden by command line
- /// options.
- virtual void getDefaultLangOptions(LangOptions &Opts) {
- GetDarwinLanguageOptions(Opts, TargetInfo::getTriple());
- }
public:
DarwinTargetInfo(const std::string& triple) :
OSTargetInfo<Target>(triple) {