annotate clang/test/Driver/darwin-embedded.c @ 150:1d019706d866

LLVM10
author anatofuz
date Thu, 13 Feb 2020 15:10:13 +0900
parents
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
150
anatofuz
parents:
diff changeset
1 // RUN: %clang -target x86_64-apple-darwin -arch armv6m -resource-dir=%S/Inputs/resource_dir %s -### 2> %t
anatofuz
parents:
diff changeset
2 // RUN: %clang -target x86_64-apple-darwin -arch armv7em -resource-dir=%S/Inputs/resource_dir %s -### 2>> %t
anatofuz
parents:
diff changeset
3 // RUN: %clang -target x86_64-apple-darwin -arch armv7em -mfloat-abi=soft -resource-dir=%S/Inputs/resource_dir %s -### 2>> %t
anatofuz
parents:
diff changeset
4
anatofuz
parents:
diff changeset
5 // RUN: %clang -target x86_64-apple-darwin -arch armv7m -fPIC -resource-dir=%S/Inputs/resource_dir %s -### 2>> %t
anatofuz
parents:
diff changeset
6 // RUN: %clang -target x86_64-apple-darwin -arch armv7em -fPIC -mfloat-abi=hard -resource-dir=%S/Inputs/resource_dir %s -### 2>> %t
anatofuz
parents:
diff changeset
7 // RUN: %clang -target x86_64-apple-darwin -arch armv7em -fPIC -mfloat-abi=softfp -resource-dir=%S/Inputs/resource_dir %s -### 2>> %t
anatofuz
parents:
diff changeset
8 // RUN: %clang -target x86_64-apple-none-macho -arch armv7 -mhard-float -resource-dir=%S/Inputs/resource_dir %s -### 2>> %t
anatofuz
parents:
diff changeset
9 // RUN: %clang -target x86_64-apple-none-macho -arch armv7 -msoft-float -fPIC -resource-dir=%S/Inputs/resource_dir %s -### 2>> %t
anatofuz
parents:
diff changeset
10
anatofuz
parents:
diff changeset
11
anatofuz
parents:
diff changeset
12 // RUN: FileCheck %s < %t
anatofuz
parents:
diff changeset
13
anatofuz
parents:
diff changeset
14 // ARMv6m has no float
anatofuz
parents:
diff changeset
15 // CHECK-LABEL: Target:
anatofuz
parents:
diff changeset
16 // CHECK-NOT: warning: unknown platform
anatofuz
parents:
diff changeset
17 // CHECK: "-mfloat-abi" "soft"
anatofuz
parents:
diff changeset
18 // CHECK: libclang_rt.soft_static.a
anatofuz
parents:
diff changeset
19
anatofuz
parents:
diff changeset
20 // ARMv7em does
anatofuz
parents:
diff changeset
21 // CHECK-LABEL: Target:
anatofuz
parents:
diff changeset
22 // CHECK-NOT: warning: unknown platform
anatofuz
parents:
diff changeset
23 // CHECK: "-mfloat-abi" "hard"
anatofuz
parents:
diff changeset
24 // CHECK: libclang_rt.hard_static.a
anatofuz
parents:
diff changeset
25
anatofuz
parents:
diff changeset
26 // but the ABI can be overridden
anatofuz
parents:
diff changeset
27 // CHECK-LABEL: Target:
anatofuz
parents:
diff changeset
28 // CHECK-NOT: warning: unknown platform
anatofuz
parents:
diff changeset
29 // CHECK: "-target-feature" "+soft-float"
anatofuz
parents:
diff changeset
30 // CHECK: "-mfloat-abi" "soft"
anatofuz
parents:
diff changeset
31 // CHECK: libclang_rt.soft_static.a
anatofuz
parents:
diff changeset
32
anatofuz
parents:
diff changeset
33 // ARMv7m has no float either
anatofuz
parents:
diff changeset
34 // CHECK-LABEL: Target:
anatofuz
parents:
diff changeset
35 // CHECK-NOT: warning: unknown platform
anatofuz
parents:
diff changeset
36 // CHECK: "-mfloat-abi" "soft"
anatofuz
parents:
diff changeset
37 // CHECK: libclang_rt.soft_pic.a
anatofuz
parents:
diff changeset
38
anatofuz
parents:
diff changeset
39 // But it can be enabled on ARMv7em
anatofuz
parents:
diff changeset
40 // CHECK-LABEL: Target:
anatofuz
parents:
diff changeset
41 // CHECK-NOT: warning: unknown platform
anatofuz
parents:
diff changeset
42 // CHECK: "-mfloat-abi" "hard"
anatofuz
parents:
diff changeset
43 // CHECK: libclang_rt.hard_pic.a
anatofuz
parents:
diff changeset
44
anatofuz
parents:
diff changeset
45 // "softfp" must link against a soft-float library since that's what the
anatofuz
parents:
diff changeset
46 // callers we're compiling will expect.
anatofuz
parents:
diff changeset
47 // CHECK-LABEL: Target:
anatofuz
parents:
diff changeset
48 // CHECK-NOT: warning: unknown platform
anatofuz
parents:
diff changeset
49 // CHECK: "-mfloat-abi" "soft"
anatofuz
parents:
diff changeset
50 // CHECK: libclang_rt.soft_pic.a
anatofuz
parents:
diff changeset
51
anatofuz
parents:
diff changeset
52 // -arch "armv7" (== embedded v7a) can be used in a couple of variants:
anatofuz
parents:
diff changeset
53 // CHECK-LABEL: Target:
anatofuz
parents:
diff changeset
54 // CHECK-NOT: warning: unknown platform
anatofuz
parents:
diff changeset
55 // CHECK: "-mfloat-abi" "hard"
anatofuz
parents:
diff changeset
56 // CHECK: libclang_rt.hard_static.a
anatofuz
parents:
diff changeset
57
anatofuz
parents:
diff changeset
58 // CHECK-LABEL: Target:
anatofuz
parents:
diff changeset
59 // CHECK-NOT: warning: unknown platform
anatofuz
parents:
diff changeset
60 // CHECK: "-mfloat-abi" "soft"
anatofuz
parents:
diff changeset
61 // CHECK: libclang_rt.soft_pic.a