armv8.1m.main.c
2.79 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
// RUN: %clang -target arm-arm-none-eabi -march=armv8.1-m.main+dsp -### %s 2> %t
// RUN: FileCheck --check-prefix=CHECK-DSP < %t %s
// CHECK-DSP: "-target-feature" "+dsp"
// RUN: %clang -target arm-arm-none-eabi -march=armv8.1-m.main+fp -### %s 2> %t
// RUN: FileCheck --check-prefix=CHECK-FP < %t %s
// CHECK-FP-DAG: "-target-feature" "+fp-armv8d16sp"
// CHECK-FP-NOT: "-target-feature" "+fp-armv8d16"
// CHECK-FP-NOT: "-target-feature" "+fp-armv8sp"
// CHECK-FP-NOT: "-target-feature" "+fp-armv8"
// CHECK-FP-NOT: "-target-feature" "+fp64"
// CHECK-FP-NOT: "-target-feature" "+d32"
// CHECK-FP-DAG: "-target-feature" "+fullfp16"
// RUN: %clang -target arm-arm-none-eabi -march=armv8.1-m.main+nofp -### %s 2> %t
// RUN: FileCheck --check-prefix=CHECK-NOFP < %t %s
// CHECK-NOFP-DAG: "-target-feature" "-vfp2"
// CHECK-NOFP-DAG: "-target-feature" "-vfp3"
// CHECK-NOFP-DAG: "-target-feature" "-fp16"
// CHECK-NOFP-DAG: "-target-feature" "-vfp4"
// CHECK-NOFP-DAG: "-target-feature" "-fp-armv8"
// CHECK-NOFP-DAG: "-target-feature" "-fp64"
// CHECK-NOFP-DAG: "-target-feature" "-d32"
// CHECK-NOFP-DAG: "-target-feature" "-neon"
// CHECK-NOFP-DAG: "-target-feature" "-crypto"
// RUN: %clang -target arm-arm-none-eabi -march=armv8.1-m.main+fp.dp -### %s 2> %t
// RUN: FileCheck --check-prefix=CHECK-FPDP < %t %s
// CHECK-FPDP-NOT: "-target-feature" "+fp-armv8sp"
// CHECK-FPDP-DAG: "-target-feature" "+fp-armv8d16"
// CHECK-FPDP-NOT: "-target-feature" "+fp-armv8"
// CHECK-FPDP-DAG: "-target-feature" "+fullfp16"
// CHECK-FPDP-DAG: "-target-feature" "+fp64"
// CHECK-FPDP-NOT: "-target-feature" "+d32"
// RUN: %clang -target arm-arm-none-eabi -march=armv8.1-m.main+nofp.dp -### %s 2> %t
// RUN: FileCheck --check-prefix=CHECK-NOFPDP < %t %s
// CHECK-NOFPDP-DAG: "-target-feature" "-fp64"
// RUN: %clang -target arm-arm-none-eabi -march=armv8.1-m.main+mve -### %s 2> %t
// RUN: FileCheck --check-prefix=CHECK-MVE < %t %s
// CHECK-MVE-DAG: "-target-feature" "+mve"
// RUN: %clang -target arm-arm-none-eabi -march=armv8.1-m.main+nomve -### %s 2> %t
// RUN: FileCheck --check-prefix=CHECK-NOMVE < %t %s
// CHECK-NOMVE-DAG: "-target-feature" "-mve"
// RUN: %clang -target arm-arm-none-eabi -march=armv8.1-m.main+mve.fp -### %s 2> %t
// RUN: FileCheck --check-prefix=CHECK-MVEFP < %t %s
// CHECK-MVEFP-DAG: "-target-feature" "+mve.fp"
// CHECK-MVEFP-NOT: "-target-feature" "+fp64"
// RUN: %clang -target arm-arm-none-eabi -march=armv8.1-m.main+nomve.fp -### %s 2> %t
// RUN: FileCheck --check-prefix=CHECK-NOMVEFP < %t %s
// CHECK-NOMVEFP: "-target-feature" "-mve.fp"
// RUN: %clang -target arm-arm-none-eabi -march=armv8.1-m.main+mve.fp+fp.dp -### %s 2> %t
// RUN: FileCheck --check-prefix=CHECK-MVEFP_DP < %t %s
// CHECK-MVEFP_DP-DAG: "-target-feature" "+mve.fp"
// CHECK-MVEFP_DP-DAG: "-target-feature" "+fp64"
double foo (double a) { return a; }