diff options
author | Keith Walker <kwalker@arm.com> | 2017-11-30 12:05:18 +0000 |
---|---|---|
committer | Keith Walker <kwalker@arm.com> | 2017-11-30 12:05:18 +0000 |
commit | 96c9689f478d292390b76efcea35d87cbad3f44d (patch) | |
tree | a722b217a2f604e7259274d6cb19cb10b4d62246 /test/Preprocessor | |
parent | aac00512b56fcddcb73c6cd1767bf280d111f897 (diff) |
Revert [ARM] disable FPU features when using soft floating point.
This reverts r319420
It is failing the test Driver/arm-mfpu.c so reverting while I investigate the failure.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@319425 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/Preprocessor')
-rw-r--r-- | test/Preprocessor/arm-target-features.c | 309 |
1 files changed, 45 insertions, 264 deletions
diff --git a/test/Preprocessor/arm-target-features.c b/test/Preprocessor/arm-target-features.c index eaa90f05b5..0067e108d3 100644 --- a/test/Preprocessor/arm-target-features.c +++ b/test/Preprocessor/arm-target-features.c @@ -5,22 +5,10 @@ // CHECK-V8A: #define __ARM_FEATURE_CRC32 1 // CHECK-V8A: #define __ARM_FEATURE_DIRECTED_ROUNDING 1 // CHECK-V8A: #define __ARM_FEATURE_NUMERIC_MAXMIN 1 -// CHECK-V8A-NOT: #define __ARM_FP 0x +// CHECK-V8A: #define __ARM_FP 0xE // CHECK-V8A: #define __ARM_FP16_ARGS 1 // CHECK-V8A: #define __ARM_FP16_FORMAT_IEEE 1 -// RUN: %clang -target armv8a-none-linux-gnueabi -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=CHECK-V8A-ALLOW-FP-INSTR %s -// RUN: %clang -target armv8a-none-linux-gnueabihf -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=CHECK-V8A-ALLOW-FP-INSTR %s -// CHECK-V8A-ALLOW-FP-INSTR: #define __ARMEL__ 1 -// CHECK-V8A-ALLOW-FP-INSTR: #define __ARM_ARCH 8 -// CHECK-V8A-ALLOW-FP-INSTR: #define __ARM_ARCH_8A__ 1 -// CHECK-V8A-ALLOW-FP-INSTR: #define __ARM_FEATURE_CRC32 1 -// CHECK-V8A-ALLOW-FP-INSTR: #define __ARM_FEATURE_DIRECTED_ROUNDING 1 -// CHECK-V8A-ALLOW-FP-INSTR: #define __ARM_FEATURE_NUMERIC_MAXMIN 1 -// CHECK-V8A-ALLOW-FP-INSTR: #define __ARM_FP 0xE -// CHECK-V8A-ALLOW-FP-INSTR: #define __ARM_FP16_ARGS 1 -// CHECK-V8A-ALLOW-FP-INSTR: #define __ARM_FP16_FORMAT_IEEE 1 - // RUN: %clang -target armv8r-none-linux-gnu -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=CHECK-V8R %s // CHECK-V8R: #define __ARMEL__ 1 // CHECK-V8R: #define __ARM_ARCH 8 @@ -28,17 +16,7 @@ // CHECK-V8R: #define __ARM_FEATURE_CRC32 1 // CHECK-V8R: #define __ARM_FEATURE_DIRECTED_ROUNDING 1 // CHECK-V8R: #define __ARM_FEATURE_NUMERIC_MAXMIN 1 -// CHECK-V8R-NOT: #define __ARM_FP 0x - -// RUN: %clang -target armv8r-none-linux-gnueabi -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=CHECK-V8R-ALLOW-FP-INSTR %s -// RUN: %clang -target armv8r-none-linux-gnueabihf -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=CHECK-V8R-ALLOW-FP-INSTR %s -// CHECK-V8R-ALLOW-FP-INSTR: #define __ARMEL__ 1 -// CHECK-V8R-ALLOW-FP-INSTR: #define __ARM_ARCH 8 -// CHECK-V8R-ALLOW-FP-INSTR: #define __ARM_ARCH_8R__ 1 -// CHECK-V8R-ALLOW-FP-INSTR: #define __ARM_FEATURE_CRC32 1 -// CHECK-V8R-ALLOW-FP-INSTR: #define __ARM_FEATURE_DIRECTED_ROUNDING 1 -// CHECK-V8R-ALLOW-FP-INSTR: #define __ARM_FEATURE_NUMERIC_MAXMIN 1 -// CHECK-V8R-ALLOW-FP-INSTR: #define __ARM_FP 0xE +// CHECK-V8R: #define __ARM_FP 0xE // RUN: %clang -target armv7a-none-linux-gnu -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=CHECK-V7 %s // CHECK-V7: #define __ARMEL__ 1 @@ -47,32 +25,14 @@ // CHECK-V7-NOT: __ARM_FEATURE_CRC32 // CHECK-V7-NOT: __ARM_FEATURE_NUMERIC_MAXMIN // CHECK-V7-NOT: __ARM_FEATURE_DIRECTED_ROUNDING -// CHECK-V7-NOT: #define __ARM_FP 0x - -// RUN: %clang -target armv7a-none-linux-gnueabi -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=CHECK-V7-ALLOW-FP-INSTR %s -// RUN: %clang -target armv7a-none-linux-gnueabihf -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=CHECK-V7-ALLOW-FP-INSTR %s -// CHECK-V7-ALLOW-FP-INSTR: #define __ARMEL__ 1 -// CHECK-V7-ALLOW-FP-INSTR: #define __ARM_ARCH 7 -// CHECK-V7-ALLOW-FP-INSTR: #define __ARM_ARCH_7A__ 1 -// CHECK-V7-ALLOW-FP-INSTR-NOT: __ARM_FEATURE_CRC32 -// CHECK-V7-ALLOW-FP-INSTR-NOT: __ARM_FEATURE_NUMERIC_MAXMIN -// CHECK-V7-ALLOW-FP-INSTR-NOT: __ARM_FEATURE_DIRECTED_ROUNDING -// CHECK-V7-ALLOW-FP-INSTR: #define __ARM_FP 0xC +// CHECK-V7: #define __ARM_FP 0xC // RUN: %clang -target armv7ve-none-linux-gnu -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=CHECK-V7VE %s // CHECK-V7VE: #define __ARMEL__ 1 // CHECK-V7VE: #define __ARM_ARCH 7 // CHECK-V7VE: #define __ARM_ARCH_7VE__ 1 // CHECK-V7VE: #define __ARM_ARCH_EXT_IDIV__ 1 -// CHECK-V7VE-NOT: #define __ARM_FP 0x - -// RUN: %clang -target armv7ve-none-linux-gnueabi -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=CHECK-V7VE-DEFAULT-ABI-SOFT %s -// RUN: %clang -target armv7ve-none-linux-gnueabihf -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=CHECK-V7VE-DEFAULT-ABI-SOFT %s -// CHECK-V7VE-DEFAULT-ABI-SOFT: #define __ARMEL__ 1 -// CHECK-V7VE-DEFAULT-ABI-SOFT: #define __ARM_ARCH 7 -// CHECK-V7VE-DEFAULT-ABI-SOFT: #define __ARM_ARCH_7VE__ 1 -// CHECK-V7VE-DEFAULT-ABI-SOFT: #define __ARM_ARCH_EXT_IDIV__ 1 -// CHECK-V7VE-DEFAULT-ABI-SOFT: #define __ARM_FP 0xC +// CHECK-V7VE: #define __ARM_FP 0xC // RUN: %clang -target x86_64-apple-macosx10.10 -arch armv7s -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=CHECK-V7S %s // CHECK-V7S: #define __ARMEL__ 1 @@ -125,15 +85,10 @@ // RUN: %clang -target armv8a -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=V8A %s // RUN: %clang -target armv8a -mthumb -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=V8A %s +// RUN: %clang -target armv8a-eabi -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=V8A %s +// RUN: %clang -target armv8a-eabi -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=V8A %s // V8A:#define __ARM_ARCH_EXT_IDIV__ 1 -// V8A-NOT:#define __ARM_FP 0x - -// RUN: %clang -target armv8a-eabi -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=V8A-ALLOW-FP-INSTR %s -// RUN: %clang -target armv8a-eabi -mthumb -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=V8A-ALLOW-FP-INSTR %s -// RUN: %clang -target armv8a-eabihf -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=V8A-ALLOW-FP-INSTR %s -// RUN: %clang -target armv8a-eabihf -mthumb -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=V8A-ALLOW-FP-INSTR %s -// V8A-ALLOW-FP-INSTR:#define __ARM_ARCH_EXT_IDIV__ 1 -// V8A-ALLOW-FP-INSTR:#define __ARM_FP 0xE +// V8A:#define __ARM_FP 0xE // RUN: %clang -target armv8m.base-none-linux-gnu -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=V8M_BASELINE %s // V8M_BASELINE: #define __ARM_ARCH 8 @@ -156,22 +111,9 @@ // V8M_MAINLINE: #define __ARM_ARCH_PROFILE 'M' // V8M_MAINLINE-NOT: __ARM_FEATURE_CRC32 // V8M_MAINLINE-NOT: __ARM_FEATURE_DSP -// V8M_MAINLINE-NOT: #define __ARM_FP 0x +// V8M_MAINLINE: #define __ARM_FP 0xE // V8M_MAINLINE: #define __GCC_HAVE_SYNC_COMPARE_AND_SWAP_1 1 -// RUN: %clang -target armv8m.main-none-linux-gnueabi -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=V8M-MAINLINE-ALLOW-FP-INSTR %s -// RUN: %clang -target armv8m.main-none-linux-gnueabihf -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=V8M-MAINLINE-ALLOW-FP-INSTR %s -// V8M-MAINLINE-ALLOW-FP-INSTR: #define __ARM_ARCH 8 -// V8M-MAINLINE-ALLOW-FP-INSTR: #define __ARM_ARCH_8M_MAIN__ 1 -// V8M-MAINLINE-ALLOW-FP-INSTR: #define __ARM_ARCH_EXT_IDIV__ 1 -// V8M-MAINLINE-ALLOW-FP-INSTR-NOT: __ARM_ARCH_ISA_ARM -// V8M-MAINLINE-ALLOW-FP-INSTR: #define __ARM_ARCH_ISA_THUMB 2 -// V8M-MAINLINE-ALLOW-FP-INSTR: #define __ARM_ARCH_PROFILE 'M' -// V8M-MAINLINE-ALLOW-FP-INSTR-NOT: __ARM_FEATURE_CRC32 -// V8M-MAINLINE-ALLOW-FP-INSTR-NOT: __ARM_FEATURE_DSP -// V8M-MAINLINE-ALLOW-FP-INSTR: #define __ARM_FP 0xE -// V8M-MAINLINE-ALLOW-FP-INSTR: #define __GCC_HAVE_SYNC_COMPARE_AND_SWAP_1 1 - // RUN: %clang -target arm-none-linux-gnu -march=armv8-m.main+dsp -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=V8M_MAINLINE_DSP %s // V8M_MAINLINE_DSP: #define __ARM_ARCH 8 // V8M_MAINLINE_DSP: #define __ARM_ARCH_8M_MAIN__ 1 @@ -181,21 +123,9 @@ // V8M_MAINLINE_DSP: #define __ARM_ARCH_PROFILE 'M' // V8M_MAINLINE_DSP-NOT: __ARM_FEATURE_CRC32 // V8M_MAINLINE_DSP: #define __ARM_FEATURE_DSP 1 -// V8M_MAINLINE_DSP-NOT: #define __ARM_FP 0x +// V8M_MAINLINE_DSP: #define __ARM_FP 0xE // V8M_MAINLINE_DSP: #define __GCC_HAVE_SYNC_COMPARE_AND_SWAP_1 1 -// RUN: %clang -target arm-none-linux-gnueabi -march=armv8-m.main+dsp -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=V8M-MAINLINE-DSP-ALLOW-FP-INSTR %s -// V8M-MAINLINE-DSP-ALLOW-FP-INSTR: #define __ARM_ARCH 8 -// V8M-MAINLINE-DSP-ALLOW-FP-INSTR: #define __ARM_ARCH_8M_MAIN__ 1 -// V8M-MAINLINE-DSP-ALLOW-FP-INSTR: #define __ARM_ARCH_EXT_IDIV__ 1 -// V8M-MAINLINE-DSP-ALLOW-FP-INSTR-NOT: __ARM_ARCH_ISA_ARM -// V8M-MAINLINE-DSP-ALLOW-FP-INSTR: #define __ARM_ARCH_ISA_THUMB 2 -// V8M-MAINLINE-DSP-ALLOW-FP-INSTR: #define __ARM_ARCH_PROFILE 'M' -// V8M-MAINLINE-DSP-ALLOW-FP-INSTR-NOT: __ARM_FEATURE_CRC32 -// V8M-MAINLINE-DSP-ALLOW-FP-INSTR: #define __ARM_FEATURE_DSP 1 -// V8M-MAINLINE-DSP-ALLOW-FP-INSTR: #define __ARM_FP 0xE -// V8M-MAINLINE-DSP-ALLOW-FP-INSTR: #define __GCC_HAVE_SYNC_COMPARE_AND_SWAP_1 1 - // RUN: %clang -target arm-none-linux-gnu -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=CHECK-DEFS %s // CHECK-DEFS:#define __ARM_PCS 1 // CHECK-DEFS:#define __ARM_SIZEOF_MINIMAL_ENUM 4 @@ -231,8 +161,6 @@ // Check that -mfpu works properly for Cortex-A7 (enabled by default). // RUN: %clang -target armv7-none-linux-gnueabi -mcpu=cortex-a7 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=DEFAULTFPU-A7 %s // RUN: %clang -target armv7-none-linux-gnueabi -mthumb -mcpu=cortex-a7 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=DEFAULTFPU-A7 %s -// RUN: %clang -target armv7-none-linux-gnueabihf -mcpu=cortex-a7 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=DEFAULTFPU-A7 %s -// RUN: %clang -target armv7-none-linux-gnueabihf -mthumb -mcpu=cortex-a7 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=DEFAULTFPU-A7 %s // DEFAULTFPU-A7:#define __ARM_FP 0xE // DEFAULTFPU-A7:#define __ARM_NEON__ 1 // DEFAULTFPU-A7:#define __ARM_VFPV4__ 1 @@ -279,7 +207,7 @@ // A5T-NOT:#define __ARM_FEATURE_DSP // A5T-NOT:#define __ARM_FP 0x{{.*}} -// Test whether predefines are as expected when targeting cortex-a5i (soft FP ABI as default). +// Test whether predefines are as expected when targeting cortex-a5. // RUN: %clang -target armv7 -mcpu=cortex-a5 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=A5 %s // RUN: %clang -target armv7 -mthumb -mcpu=cortex-a5 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=A5 %s // A5:#define __ARM_ARCH 7 @@ -290,21 +218,9 @@ // A5-NOT: #define __ARM_FEATURE_DIRECTED_ROUNDING // A5:#define __ARM_FEATURE_DSP 1 // A5-NOT: #define __ARM_FEATURE_NUMERIC_MAXMIN -// A5-NOT:#define __ARM_FP 0x - -// Test whether predefines are as expected when targeting cortex-a5 (softfp FP ABI as default). -// RUN: %clang -target armv7-eabi -mcpu=cortex-a5 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=A5-ALLOW-FP-INSTR %s -// RUN: %clang -target armv7-eabi -mthumb -mcpu=cortex-a5 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=A5-ALLOW-FP-INSTR %s -// A5-ALLOW-FP-INSTR:#define __ARM_ARCH 7 -// A5-ALLOW-FP-INSTR:#define __ARM_ARCH_7A__ 1 -// A5-ALLOW-FP-INSTR-NOT:#define __ARM_ARCH_EXT_IDIV__ -// A5-ALLOW-FP-INSTR:#define __ARM_ARCH_PROFILE 'A' -// A5-ALLOW-FP-INSTR-NOT: #define __ARM_FEATURE_DIRECTED_ROUNDING -// A5-ALLOW-FP-INSTR:#define __ARM_FEATURE_DSP 1 -// A5-ALLOW-FP-INSTR-NOT: #define __ARM_FEATURE_NUMERIC_MAXMIN -// A5-ALLOW-FP-INSTR:#define __ARM_FP 0xE - -// Test whether predefines are as expected when targeting cortex-a7 (soft FP ABI as default). +// A5:#define __ARM_FP 0xE + +// Test whether predefines are as expected when targeting cortex-a7. // RUN: %clang -target armv7k -mcpu=cortex-a7 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=A7 %s // RUN: %clang -target armv7k -mthumb -mcpu=cortex-a7 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=A7 %s // A7:#define __ARM_ARCH 7 @@ -312,16 +228,7 @@ // A7:#define __ARM_ARCH_PROFILE 'A' // A7-NOT:#define __ARM_DWARF_EH__ 1 // A7:#define __ARM_FEATURE_DSP 1 -// A7-NOT:#define __ARM_FP 0x - -// Test whether predefines are as expected when targeting cortex-a7 (softfp FP ABI as default). -// RUN: %clang -target armv7k-eabi -mcpu=cortex-a7 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=A7-ALLOW-FP-INSTR %s -// RUN: %clang -target armv7k-eabi -mthumb -mcpu=cortex-a7 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=A7-ALLOW-FP-INSTR %s -// A7-ALLOW-FP-INSTR:#define __ARM_ARCH 7 -// A7-ALLOW-FP-INSTR:#define __ARM_ARCH_EXT_IDIV__ 1 -// A7-ALLOW-FP-INSTR:#define __ARM_ARCH_PROFILE 'A' -// A7-ALLOW-FP-INSTR:#define __ARM_FEATURE_DSP 1 -// A7-ALLOW-FP-INSTR:#define __ARM_FP 0xE +// A7:#define __ARM_FP 0xE // Test whether predefines are as expected when targeting cortex-a7. // RUN: %clang -target x86_64-apple-darwin -arch armv7k -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=ARMV7K %s @@ -334,33 +241,19 @@ // ARMV7K:#define __ARM_PCS_VFP 1 -// Test whether predefines are as expected when targeting cortex-a8 (soft FP ABI as default). +// Test whether predefines are as expected when targeting cortex-a8. // RUN: %clang -target armv7 -mcpu=cortex-a8 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=A8 %s // RUN: %clang -target armv7 -mthumb -mcpu=cortex-a8 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=A8 %s // A8-NOT:#define __ARM_ARCH_EXT_IDIV__ // A8:#define __ARM_FEATURE_DSP 1 -// A8-NOT:#define __ARM_FP 0x +// A8:#define __ARM_FP 0xC -// Test whether predefines are as expected when targeting cortex-a8 (softfp FP ABI as default). -// RUN: %clang -target armv7-eabi -mcpu=cortex-a8 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=A8-ALLOW-FP-INSTR %s -// RUN: %clang -target armv7-eabi -mthumb -mcpu=cortex-a8 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=A8-ALLOW-FP-INSTR %s -// A8-ALLOW-FP-INSTR-NOT:#define __ARM_ARCH_EXT_IDIV__ -// A8-ALLOW-FP-INSTR:#define __ARM_FEATURE_DSP 1 -// A8-ALLOW-FP-INSTR:#define __ARM_FP 0xC - -// Test whether predefines are as expected when targeting cortex-a9 (soft FP as default). +// Test whether predefines are as expected when targeting cortex-a9. // RUN: %clang -target armv7 -mcpu=cortex-a9 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=A9 %s // RUN: %clang -target armv7 -mthumb -mcpu=cortex-a9 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=A9 %s // A9-NOT:#define __ARM_ARCH_EXT_IDIV__ // A9:#define __ARM_FEATURE_DSP 1 -// A9-NOT:#define __ARM_FP 0x - -// Test whether predefines are as expected when targeting cortex-a9 (softfp FP as default). -// RUN: %clang -target armv7-eabi -mcpu=cortex-a9 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=A9-ALLOW-FP-INSTR %s -// RUN: %clang -target armv7-eabi -mthumb -mcpu=cortex-a9 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=A9-ALLOW-FP-INSTR %s -// A9-ALLOW-FP-INSTR-NOT:#define __ARM_ARCH_EXT_IDIV__ -// A9-ALLOW-FP-INSTR:#define __ARM_FEATURE_DSP 1 -// A9-ALLOW-FP-INSTR:#define __ARM_FP 0xE +// A9:#define __ARM_FP 0xE // Check that -mfpu works properly for Cortex-A12 (enabled by default). @@ -376,7 +269,7 @@ // FPUNONE-A12-NOT:#define __ARM_NEON__ 1 // FPUNONE-A12-NOT:#define __ARM_VFPV4__ 1 -// Test whether predefines are as expected when targeting cortex-a12 (soft FP ABI as default). +// Test whether predefines are as expected when targeting cortex-a12. // RUN: %clang -target armv7 -mcpu=cortex-a12 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=A12 %s // RUN: %clang -target armv7 -mthumb -mcpu=cortex-a12 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=A12 %s // A12:#define __ARM_ARCH 7 @@ -384,31 +277,14 @@ // A12:#define __ARM_ARCH_EXT_IDIV__ 1 // A12:#define __ARM_ARCH_PROFILE 'A' // A12:#define __ARM_FEATURE_DSP 1 -// A12-NOT:#define __ARM_FP 0x - -// Test whether predefines are as expected when targeting cortex-a12 (soft FP ABI as default). -// RUN: %clang -target armv7-eabi -mcpu=cortex-a12 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=A12-ALLOW-FP-INSTR %s -// RUN: %clang -target armv7-eabi -mthumb -mcpu=cortex-a12 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=A12-ALLOW-FP-INSTR %s -// A12-ALLOW-FP-INSTR:#define __ARM_ARCH 7 -// A12-ALLOW-FP-INSTR:#define __ARM_ARCH_7A__ 1 -// A12-ALLOW-FP-INSTR:#define __ARM_ARCH_EXT_IDIV__ 1 -// A12-ALLOW-FP-INSTR:#define __ARM_ARCH_PROFILE 'A' -// A12-ALLOW-FP-INSTR:#define __ARM_FEATURE_DSP 1 -// A12-ALLOW-FP-INSTR:#define __ARM_FP 0xE - -// Test whether predefines are as expected when targeting cortex-a15 (soft FP ABI as default). +// A12:#define __ARM_FP 0xE + +// Test whether predefines are as expected when targeting cortex-a15. // RUN: %clang -target armv7 -mcpu=cortex-a15 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=A15 %s // RUN: %clang -target armv7 -mthumb -mcpu=cortex-a15 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=A15 %s // A15:#define __ARM_ARCH_EXT_IDIV__ 1 // A15:#define __ARM_FEATURE_DSP 1 -// A15-NOT:#define __ARM_FP 0x - -// Test whether predefines are as expected when targeting cortex-a15 (softfp ABI as default). -// RUN: %clang -target armv7-eabi -mcpu=cortex-a15 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=A15-ALLOW-FP-INSTR %s -// RUN: %clang -target armv7-eabi -mthumb -mcpu=cortex-a15 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=A15-ALLOW-FP-INSTR %s -// A15-ALLOW-FP-INSTR:#define __ARM_ARCH_EXT_IDIV__ 1 -// A15-ALLOW-FP-INSTR:#define __ARM_FEATURE_DSP 1 -// A15-ALLOW-FP-INSTR:#define __ARM_FP 0xE +// A15:#define __ARM_FP 0xE // Check that -mfpu works properly for Cortex-A17 (enabled by default). // RUN: %clang -target armv7-none-linux-gnueabi -mcpu=cortex-a17 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=DEFAULTFPU-A17 %s @@ -423,7 +299,7 @@ // FPUNONE-A17-NOT:#define __ARM_NEON__ 1 // FPUNONE-A17-NOT:#define __ARM_VFPV4__ 1 -// Test whether predefines are as expected when targeting cortex-a17 (soft FP ABI as default). +// Test whether predefines are as expected when targeting cortex-a17. // RUN: %clang -target armv7 -mcpu=cortex-a17 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=A17 %s // RUN: %clang -target armv7 -mthumb -mcpu=cortex-a17 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=A17 %s // A17:#define __ARM_ARCH 7 @@ -431,33 +307,16 @@ // A17:#define __ARM_ARCH_EXT_IDIV__ 1 // A17:#define __ARM_ARCH_PROFILE 'A' // A17:#define __ARM_FEATURE_DSP 1 -// A17-NOT:#define __ARM_FP 0x - -// Test whether predefines are as expected when targeting cortex-a17 (softfp FP ABI as default). -// RUN: %clang -target armv7-eabi -mcpu=cortex-a17 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=A17-ALLOW-FP-INSTR %s -// RUN: %clang -target armv7-eabi -mthumb -mcpu=cortex-a17 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=A17-ALLOW-FP-INSTR %s -// A17-ALLOW-FP-INSTR:#define __ARM_ARCH 7 -// A17-ALLOW-FP-INSTR:#define __ARM_ARCH_7A__ 1 -// A17-ALLOW-FP-INSTR:#define __ARM_ARCH_EXT_IDIV__ 1 -// A17-ALLOW-FP-INSTR:#define __ARM_ARCH_PROFILE 'A' -// A17-ALLOW-FP-INSTR:#define __ARM_FEATURE_DSP 1 -// A17-ALLOW-FP-INSTR:#define __ARM_FP 0xE - -// Test whether predefines are as expected when targeting swift (soft FP ABI as default). +// A17:#define __ARM_FP 0xE + +// Test whether predefines are as expected when targeting swift. // RUN: %clang -target armv7s -mcpu=swift -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=SWIFT %s // RUN: %clang -target armv7s -mthumb -mcpu=swift -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=SWIFT %s // SWIFT:#define __ARM_ARCH_EXT_IDIV__ 1 // SWIFT:#define __ARM_FEATURE_DSP 1 -// SWIFTi-NOT:#define __ARM_FP 0xxE +// SWIFT:#define __ARM_FP 0xE -// Test whether predefines are as expected when targeting swift (softfp FP ABI as default). -// RUN: %clang -target armv7s-eabi -mcpu=swift -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=SWIFT-ALLOW-FP-INSTR %s -// RUN: %clang -target armv7s-eabi -mthumb -mcpu=swift -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=SWIFT-ALLOW-FP-INSTR %s -// SWIFT-ALLOW-FP-INSTR:#define __ARM_ARCH_EXT_IDIV__ 1 -// SWIFT-ALLOW-FP-INSTR:#define __ARM_FEATURE_DSP 1 -// SWIFT-ALLOW-FP-INSTR:#define __ARM_FP 0xE - -// Test whether predefines are as expected when targeting ARMv8-A Cortex implementations (soft FP ABI as default) +// Test whether predefines are as expected when targeting ARMv8-A Cortex implementations // RUN: %clang -target armv8 -mcpu=cortex-a32 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=ARMV8 %s // RUN: %clang -target armv8 -mthumb -mcpu=cortex-a32 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=ARMV8 %s // RUN: %clang -target armv8 -mcpu=cortex-a35 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=ARMV8 %s @@ -472,24 +331,7 @@ // RUN: %clang -target armv8 -mthumb -mcpu=cortex-a73 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=ARMV8 %s // ARMV8:#define __ARM_ARCH_EXT_IDIV__ 1 // ARMV8:#define __ARM_FEATURE_DSP 1 -// ARMV8-NOT:#define __ARM_FP 0x - -// Test whether predefines are as expected when targeting ARMv8-A Cortex implementations (softfp FP ABI as default) -// RUN: %clang -target armv8-eabi -mcpu=cortex-a32 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=ARMV8-ALLOW-FP-INSTR %s -// RUN: %clang -target armv8-eabi -mthumb -mcpu=cortex-a32 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=ARMV8-ALLOW-FP-INSTR %s -// RUN: %clang -target armv8-eabi -mcpu=cortex-a35 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=ARMV8-ALLOW-FP-INSTR %s -// RUN: %clang -target armv8-eabi -mthumb -mcpu=cortex-a35 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=ARMV8-ALLOW-FP-INSTR %s -// RUN: %clang -target armv8-eabi -mcpu=cortex-a53 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=ARMV8-ALLOW-FP-INSTR %s -// RUN: %clang -target armv8-eabi -mthumb -mcpu=cortex-a53 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=ARMV8-ALLOW-FP-INSTR %s -// RUN: %clang -target armv8-eabi -mcpu=cortex-a57 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=ARMV8-ALLOW-FP-INSTR %s -// RUN: %clang -target armv8-eabi -mthumb -mcpu=cortex-a57 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=ARMV8-ALLOW-FP-INSTR %s -// RUN: %clang -target armv8-eabi -mcpu=cortex-a72 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=ARMV8-ALLOW-FP-INSTR %s -// RUN: %clang -target armv8-eabi -mthumb -mcpu=cortex-a72 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=ARMV8-ALLOW-FP-INSTR %s -// RUN: %clang -target armv8-eabi -mcpu=cortex-a73 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=ARMV8-ALLOW-FP-INSTR %s -// RUN: %clang -target armv8-eabi -mthumb -mcpu=cortex-a73 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=ARMV8-ALLOW-FP-INSTR %s -// ARMV8-ALLOW-FP-INSTR:#define __ARM_ARCH_EXT_IDIV__ 1 -// ARMV8-ALLOW-FP-INSTR:#define __ARM_FEATURE_DSP 1 -// ARMV8-ALLOW-FP-INSTR:#define __ARM_FP 0xE +// ARMV8:#define __ARM_FP 0xE // Test whether predefines are as expected when targeting cortex-r4. // RUN: %clang -target armv7 -mcpu=cortex-r4 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=R4-ARM %s @@ -502,59 +344,32 @@ // R4-THUMB:#define __ARM_FEATURE_DSP 1 // R4-THUMB-NOT:#define __ARM_FP 0x{{.*}} -// Test whether predefines are as expected when targeting cortex-r4f (soft FP ABI as default). +// Test whether predefines are as expected when targeting cortex-r4f. // RUN: %clang -target armv7 -mcpu=cortex-r4f -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=R4F-ARM %s // R4F-ARM-NOT:#define __ARM_ARCH_EXT_IDIV__ // R4F-ARM:#define __ARM_FEATURE_DSP 1 -// R4F-ARM-NOT:#define __ARM_FP 0x - -// Test whether predefines are as expected when targeting cortex-r4f (softfp FP ABI as default). -// RUN: %clang -target armv7-eabi -mcpu=cortex-r4f -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=R4F-ARM-ALLOW-FP-INSTR %s -// R4F-ARM-ALLOW-FP-INSTR-NOT:#define __ARM_ARCH_EXT_IDIV__ -// R4F-ARM-ALLOW-FP-INSTR:#define __ARM_FEATURE_DSP 1 -// R4F-ARM-ALLOW-FP-INSTR:#define __ARM_FP 0xC +// R4F-ARM:#define __ARM_FP 0xC // RUN: %clang -target armv7 -mthumb -mcpu=cortex-r4f -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=R4F-THUMB %s // R4F-THUMB:#define __ARM_ARCH_EXT_IDIV__ 1 // R4F-THUMB:#define __ARM_FEATURE_DSP 1 -// R4F-THUMB-NOT:#define __ARM_FP 0x +// R4F-THUMB:#define __ARM_FP 0xC -// RUN: %clang -target armv7-eabi -mthumb -mcpu=cortex-r4f -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=R4F-THUMB-ALLOW-FP-INSTR %s -// R4F-THUMB-ALLOW-FP-INSTR:#define __ARM_ARCH_EXT_IDIV__ 1 -// R4F-THUMB-ALLOW-FP-INSTR:#define __ARM_FEATURE_DSP 1 -// R4F-THUMB-ALLOW-FP-INSTR:#define __ARM_FP 0xC - -// Test whether predefines are as expected when targeting cortex-r5 (soft FP ABI as default). +// Test whether predefines are as expected when targeting cortex-r5. // RUN: %clang -target armv7 -mcpu=cortex-r5 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=R5 %s // RUN: %clang -target armv7 -mthumb -mcpu=cortex-r5 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=R5 %s // R5:#define __ARM_ARCH_EXT_IDIV__ 1 // R5:#define __ARM_FEATURE_DSP 1 -// R5-NOT:#define __ARM_FP 0x - -// Test whether predefines are as expected when targeting cortex-r5 (softfp FP ABI as default). -// RUN: %clang -target armv7-eabi -mcpu=cortex-r5 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=R5-ALLOW-FP-INSTR %s -// RUN: %clang -target armv7-eabi -mthumb -mcpu=cortex-r5 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=R5-ALLOW-FP-INSTR %s -// R5-ALLOW-FP-INSTR:#define __ARM_ARCH_EXT_IDIV__ 1 -// R5-ALLOW-FP-INSTR:#define __ARM_FEATURE_DSP 1 -// R5-ALLOW-FP-INSTR:#define __ARM_FP 0xC +// R5:#define __ARM_FP 0xC -// Test whether predefines are as expected when targeting cortex-r7 and cortex-r8 (soft FP ABI as default). +// Test whether predefines are as expected when targeting cortex-r7 and cortex-r8. // RUN: %clang -target armv7 -mcpu=cortex-r7 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=R7-R8 %s // RUN: %clang -target armv7 -mthumb -mcpu=cortex-r7 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=R7-R8 %s // RUN: %clang -target armv7 -mcpu=cortex-r8 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=R7-R8 %s // RUN: %clang -target armv7 -mthumb -mcpu=cortex-r8 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=R7-R8 %s // R7-R8:#define __ARM_ARCH_EXT_IDIV__ 1 // R7-R8:#define __ARM_FEATURE_DSP 1 -// R7-R8-NOT:#define __ARM_FP 0x - -// Test whether predefines are as expected when targeting cortex-r7 and cortex-r8 (softfp FP ABI as default). -// RUN: %clang -target armv7-eabi -mcpu=cortex-r7 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=R7-R8-ALLOW-FP-INSTR %s -// RUN: %clang -target armv7-eabi -mthumb -mcpu=cortex-r7 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=R7-R8-ALLOW-FP-INSTR %s -// RUN: %clang -target armv7-eabi -mcpu=cortex-r8 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=R7-R8-ALLOW-FP-INSTR %s -// RUN: %clang -target armv7-eabi -mthumb -mcpu=cortex-r8 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=R7-R8-ALLOW-FP-INSTR %s -// R7-R8-ALLOW-FP-INSTR:#define __ARM_ARCH_EXT_IDIV__ 1 -// R7-R8-ALLOW-FP-INSTR:#define __ARM_FEATURE_DSP 1 -// R7-R8-ALLOW-FP-INSTR:#define __ARM_FP 0xE +// R7-R8:#define __ARM_FP 0xE // Test whether predefines are as expected when targeting cortex-m0. // RUN: %clang -target armv7 -mthumb -mcpu=cortex-m0 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=M0-THUMB %s @@ -572,31 +387,18 @@ // M3-THUMB-NOT:#define __ARM_FEATURE_DSP // M3-THUMB-NOT:#define __ARM_FP 0x{{.*}} -// Test whether predefines are as expected when targeting cortex-m4 (soft FP ABI as default). +// Test whether predefines are as expected when targeting cortex-m4. // RUN: %clang -target armv7 -mthumb -mcpu=cortex-m4 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=M4-THUMB %s // M4-THUMB:#define __ARM_ARCH_EXT_IDIV__ 1 // M4-THUMB:#define __ARM_FEATURE_DSP 1 -// M4-THUMB-NOT:#define __ARM_FP 0x +// M4-THUMB:#define __ARM_FP 0x6 -// Test whether predefines are as expected when targeting cortex-m4 (softfp ABI as default). -// RUN: %clang -target armv7-eabi -mthumb -mcpu=cortex-m4 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=M4-THUMB-ALLOW-FP-INSTR %s -// M4-THUMB-ALLOW-FP-INSTR:#define __ARM_ARCH_EXT_IDIV__ 1 -// M4-THUMB-ALLOW-FP-INSTR:#define __ARM_FEATURE_DSP 1 -// M4-THUMB-ALLOW-FP-INSTR:#define __ARM_FP 0x6 - -// Test whether predefines are as expected when targeting cortex-m7 (soft FP ABI as default). +// Test whether predefines are as expected when targeting cortex-m7. // RUN: %clang -target armv7 -mthumb -mcpu=cortex-m7 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=M7-THUMB %s // M7-THUMB:#define __ARM_ARCH_EXT_IDIV__ 1 // M7-THUMB:#define __ARM_FEATURE_DSP 1 -// M7-THUMB-NOT:#define __ARM_FP 0x -// M7-THUMB-NOT:#define __ARM_FPV5__ - -// Test whether predefines are as expected when targeting cortex-m7 (softfp FP ABI as default). -// RUN: %clang -target armv7-eabi -mthumb -mcpu=cortex-m7 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=M7-THUMB-ALLOW-FP-INSTR %s -// M7-THUMB-ALLOW-FP-INSTR:#define __ARM_ARCH_EXT_IDIV__ 1 -// M7-THUMB-ALLOW-FP-INSTR:#define __ARM_FEATURE_DSP 1 -// M7-THUMB-ALLOW-FP-INSTR:#define __ARM_FP 0xE -// M7-THUMB-ALLOW-FP-INSTR:#define __ARM_FPV5__ 1 +// M7-THUMB:#define __ARM_FP 0xE +// M7-THUMB:#define __ARM_FPV5__ 1 // Test whether predefines are as expected when targeting v8m cores // RUN: %clang -target arm -mcpu=cortex-m23 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=M23 %s @@ -611,7 +413,6 @@ // M23-NOT: __ARM_FP 0x{{.*}} // M23-NOT: __GCC_HAVE_SYNC_COMPARE_AND_SWAP_1 -// Test whether predefines are as expected when targeting m33 (soft FP ABI as default). // RUN: %clang -target arm -mcpu=cortex-m33 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=M33 %s // M33: #define __ARM_ARCH 8 // M33: #define __ARM_ARCH_8M_MAIN__ 1 @@ -621,35 +422,15 @@ // M33: #define __ARM_ARCH_PROFILE 'M' // M33-NOT: __ARM_FEATURE_CRC32 // M33: #define __ARM_FEATURE_DSP 1 -// M33-NOT: #define __ARM_FP 0x +// M33: #define __ARM_FP 0x6 // M33: #define __GCC_HAVE_SYNC_COMPARE_AND_SWAP_1 1 -// Test whether predefines are as expected when targeting m33 (softfp FP ABI as default). -// RUN: %clang -target arm-eabi -mcpu=cortex-m33 -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=M33-ALLOW-FP-INSTR %s -// M33-ALLOW-FP-INSTR: #define __ARM_ARCH 8 -// M33-ALLOW-FP-INSTR: #define __ARM_ARCH_8M_MAIN__ 1 -// M33-ALLOW-FP-INSTR: #define __ARM_ARCH_EXT_IDIV__ 1 -// M33-ALLOW-FP-INSTR-NOT: __ARM_ARCH_ISA_ARM -// M33-ALLOW-FP-INSTR: #define __ARM_ARCH_ISA_THUMB 2 -// M33-ALLOW-FP-INSTR: #define __ARM_ARCH_PROFILE 'M' -// M33-ALLOW-FP-INSTR-NOT: __ARM_FEATURE_CRC32 -// M33-ALLOW-FP-INSTR: #define __ARM_FEATURE_DSP 1 -// M33-ALLOW-FP-INSTR: #define __ARM_FP 0x6 -// M33-ALLOW-FP-INSTR: #define __GCC_HAVE_SYNC_COMPARE_AND_SWAP_1 1 - -// Test whether predefines are as expected when targeting krait (soft FP as default). +// Test whether predefines are as expected when targeting krait. // RUN: %clang -target armv7 -mcpu=krait -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=KRAIT %s // RUN: %clang -target armv7 -mthumb -mcpu=krait -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=KRAIT %s // KRAIT:#define __ARM_ARCH_EXT_IDIV__ 1 // KRAIT:#define __ARM_FEATURE_DSP 1 -// KRAIT-NOT:#define __ARM_VFPV4__ - -// Test whether predefines are as expected when targeting krait (softfp FP as default). -// RUN: %clang -target armv7-eabi -mcpu=krait -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=KRAIT-ALLOW-FP-INSTR %s -// RUN: %clang -target armv7-eabi -mthumb -mcpu=krait -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=KRAIT-ALLOW-FP-INSTR %s -// KRAIT-ALLOW-FP-INSTR:#define __ARM_ARCH_EXT_IDIV__ 1 -// KRAIT-ALLOW-FP-INSTR:#define __ARM_FEATURE_DSP 1 -// KRAIT-ALLOW-FP-INSTR:#define __ARM_VFPV4__ 1 +// KRAIT:#define __ARM_VFPV4__ 1 // RUN: %clang -target armv8.1a-none-none-eabi -x c -E -dM %s -o - | FileCheck -match-full-lines --check-prefix=CHECK-V81A %s // CHECK-V81A: #define __ARM_ARCH 8 |