From: Tim Northover Date: Fri, 29 May 2015 21:28:25 +0000 (+0000) Subject: ARM: fix ACLE predefine for iOS's "-arch armv7s". X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=f102f777ae55a658713e8c0cc0d013c07cd942e3;p=clang ARM: fix ACLE predefine for iOS's "-arch armv7s". We were getting "#define __ARM_ARCH_7 -S__ 1" which is really not a good idea. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@238614 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/Basic/Targets.cpp b/lib/Basic/Targets.cpp index 03cc91481b..0eb5cee351 100644 --- a/lib/Basic/Targets.cpp +++ b/lib/Basic/Targets.cpp @@ -4322,6 +4322,7 @@ public: return "6M"; case llvm::ARM::AK_ARMV7: case llvm::ARM::AK_ARMV7A: + case llvm::ARM::AK_ARMV7S: return "7A"; case llvm::ARM::AK_ARMV7R: return "7R"; diff --git a/test/Preprocessor/arm-target-features.c b/test/Preprocessor/arm-target-features.c index 0dace434ab..2b0ebb9b1e 100644 --- a/test/Preprocessor/arm-target-features.c +++ b/test/Preprocessor/arm-target-features.c @@ -7,6 +7,7 @@ // CHECK: __ARM_FEATURE_NUMERIC_MAXMIN 1 // RUN: %clang -target armv7a-none-linux-gnu -x c -E -dM %s -o - | FileCheck --check-prefix=CHECK-V7 %s +// RUN: %clang -target x86_64-apple-macosx10.10 -arch armv7s -x c -E -dM %s -o - | FileCheck --check-prefix=CHECK-V7 %s // CHECK-V7: __ARMEL__ 1 // CHECK-V7: __ARM_ARCH 7 // CHECK-V7: __ARM_ARCH_7A__ 1