[llvm] r196912 - Darwin: update default iOS version to 5.0
Tim Northover
tnorthover at apple.com
Tue Dec 10 03:53:17 PST 2013
Author: tnorthover
Date: Tue Dec 10 05:53:16 2013
New Revision: 196912
URL: http://llvm.org/viewvc/llvm-project?rev=196912&view=rev
Log:
Darwin: update default iOS version to 5.0
Defaulting to iOS 3.0 when LLVM has to guess the version is no longer a useful
option and can give surprising results (like tail calls being disabled).
5.0 seems like a reasonable compromise as a platform that's still interesting
to some people.
rdar://problem/15567348
Modified:
llvm/trunk/lib/Support/Triple.cpp
llvm/trunk/unittests/ADT/TripleTest.cpp
Modified: llvm/trunk/lib/Support/Triple.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Support/Triple.cpp?rev=196912&r1=196911&r2=196912&view=diff
==============================================================================
--- llvm/trunk/lib/Support/Triple.cpp (original)
+++ llvm/trunk/lib/Support/Triple.cpp Tue Dec 10 05:53:16 2013
@@ -600,15 +600,15 @@ void Triple::getiOSVersion(unsigned &Maj
// the clang driver combines OS X and IOS support into a common Darwin
// toolchain that wants to know the iOS version number even when targeting
// OS X.
- Major = 3;
+ Major = 5;
Minor = 0;
Micro = 0;
break;
case IOS:
getOSVersion(Major, Minor, Micro);
- // Default to 3.0.
+ // Default to 5.0.
if (Major == 0)
- Major = 3;
+ Major = 5;
break;
}
}
Modified: llvm/trunk/unittests/ADT/TripleTest.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/unittests/ADT/TripleTest.cpp?rev=196912&r1=196911&r2=196912&view=diff
==============================================================================
--- llvm/trunk/unittests/ADT/TripleTest.cpp (original)
+++ llvm/trunk/unittests/ADT/TripleTest.cpp Tue Dec 10 05:53:16 2013
@@ -417,7 +417,7 @@ TEST(TripleTest, getOSVersion) {
EXPECT_EQ((unsigned)5, Minor);
EXPECT_EQ((unsigned)0, Micro);
T.getiOSVersion(Major, Minor, Micro);
- EXPECT_EQ((unsigned)3, Major);
+ EXPECT_EQ((unsigned)5, Major);
EXPECT_EQ((unsigned)0, Minor);
EXPECT_EQ((unsigned)0, Micro);
@@ -432,7 +432,7 @@ TEST(TripleTest, getOSVersion) {
EXPECT_EQ((unsigned)5, Minor);
EXPECT_EQ((unsigned)0, Micro);
T.getiOSVersion(Major, Minor, Micro);
- EXPECT_EQ((unsigned)3, Major);
+ EXPECT_EQ((unsigned)5, Major);
EXPECT_EQ((unsigned)0, Minor);
EXPECT_EQ((unsigned)0, Micro);
@@ -447,7 +447,7 @@ TEST(TripleTest, getOSVersion) {
EXPECT_EQ((unsigned)4, Minor);
EXPECT_EQ((unsigned)0, Micro);
T.getiOSVersion(Major, Minor, Micro);
- EXPECT_EQ((unsigned)3, Major);
+ EXPECT_EQ((unsigned)5, Major);
EXPECT_EQ((unsigned)0, Minor);
EXPECT_EQ((unsigned)0, Micro);
@@ -462,7 +462,7 @@ TEST(TripleTest, getOSVersion) {
EXPECT_EQ((unsigned)7, Minor);
EXPECT_EQ((unsigned)0, Micro);
T.getiOSVersion(Major, Minor, Micro);
- EXPECT_EQ((unsigned)3, Major);
+ EXPECT_EQ((unsigned)5, Major);
EXPECT_EQ((unsigned)0, Minor);
EXPECT_EQ((unsigned)0, Micro);
@@ -477,11 +477,11 @@ TEST(TripleTest, getOSVersion) {
EXPECT_EQ((unsigned)4, Minor);
EXPECT_EQ((unsigned)0, Micro);
T.getiOSVersion(Major, Minor, Micro);
- EXPECT_EQ((unsigned)3, Major);
+ EXPECT_EQ((unsigned)5, Major);
EXPECT_EQ((unsigned)0, Minor);
EXPECT_EQ((unsigned)0, Micro);
- T = Triple("armv7-apple-ios5.0");
+ T = Triple("armv7-apple-ios7.0");
EXPECT_FALSE(T.isMacOSX());
EXPECT_TRUE(T.isiOS());
EXPECT_FALSE(T.isArch16Bit());
@@ -492,7 +492,7 @@ TEST(TripleTest, getOSVersion) {
EXPECT_EQ((unsigned)4, Minor);
EXPECT_EQ((unsigned)0, Micro);
T.getiOSVersion(Major, Minor, Micro);
- EXPECT_EQ((unsigned)5, Major);
+ EXPECT_EQ((unsigned)7, Major);
EXPECT_EQ((unsigned)0, Minor);
EXPECT_EQ((unsigned)0, Micro);
}
More information about the llvm-commits
mailing list