Run DCE after a LoopFlatten test to reduce spurious output [nfc]
[llvm-project.git] / clang / test / Driver / ps4-ps5-runtime-flags.c
blobe75ba97948d2340710cedf198cb810640e62b8e5
1 /// Test the profile runtime library to be linked for PS4/PS5 compiler.
2 /// Check runtime flag --dependent-lib which does not append the default library search path.
3 //
4 /// PS4 case.
5 // RUN: %clang -target x86_64-scei-ps4 --coverage %s -### 2>&1 | FileCheck --check-prefix=CHECK-PS4-PROFILE %s
6 // RUN: %clang -target x86_64-scei-ps4 -fprofile-arcs %s -### 2>&1 | FileCheck --check-prefix=CHECK-PS4-PROFILE %s
7 // RUN: %clang -target x86_64-scei-ps4 -fno-profile-arcs -fprofile-arcs %s -### 2>&1 | FileCheck --check-prefix=CHECK-PS4-PROFILE %s
8 // RUN: %clang -target x86_64-scei-ps4 -fno-profile-arcs %s -### 2>&1 | FileCheck -check-prefix=CHECK-PS4-NO-PROFILE %s
9 // RUN: %clang -target x86_64-scei-ps4 -fprofile-arcs -fno-profile-arcs %s -### 2>&1 | FileCheck --check-prefix=CHECK-PS4-NO-PROFILE %s
10 // RUN: %clang -target x86_64-scei-ps4 -fprofile-generate %s -### 2>&1 | FileCheck --check-prefix=CHECK-PS4-PROFILE %s
11 // RUN: %clang -target x86_64-scei-ps4 -fno-profile-generate %s -### 2>&1 | FileCheck --check-prefix=CHECK-PS4-NO-PROFILE %s
12 // RUN: %clang -target x86_64-scei-ps4 -fprofile-generate -fno-profile-generate %s -### 2>&1 | FileCheck --check-prefix=CHECK-PS4-NO-PROFILE %s
13 // RUN: %clang -target x86_64-scei-ps4 -fprofile-generate=dir %s -### 2>&1 | FileCheck --check-prefix=CHECK-PS4-PROFILE %s
14 // RUN: %clang -target x86_64-scei-ps4 -fprofile-instr-generate %s -### 2>&1 | FileCheck --check-prefix=CHECK-PS4-PROFILE %s
15 // RUN: %clang -target x86_64-scei-ps4 -fno-profile-instr-generate %s -### 2>&1 | FileCheck --check-prefix=CHECK-PS4-NO-PROFILE %s
16 // RUN: %clang -target x86_64-scei-ps4 -fprofile-instr-generate -fno-profile-instr-generate %s -### 2>&1 | FileCheck --check-prefix=CHECK-PS4-NO-PROFILE %s
17 // RUN: %clang -target x86_64-scei-ps4 -fprofile-generate -fno-profile-instr-generate %s -### 2>&1 | FileCheck --check-prefix=CHECK-PS4-PROFILE %s
18 // RUN: %clang -target x86_64-scei-ps4 -fprofile-instr-generate=somefile.profraw %s -### 2>&1 | FileCheck --check-prefix=CHECK-PS4-PROFILE %s
19 // RUN: %clang -target x86_64-scei-ps4 -fcs-profile-generate %s -### 2>&1 | FileCheck --check-prefix=CHECK-PS4-PROFILE %s
20 // RUN: %clang -target x86_64-scei-ps4 -fcs-profile-generate -fno-profile-generate %s -### 2>&1 | FileCheck --check-prefix=CHECK-PS4-NO-PROFILE %s
22 // CHECK-PS4-PROFILE: "--dependent-lib=libclang_rt.profile-x86_64.a"
23 // CHECK-PS4-NO-PROFILE-NOT: "--dependent-lib=libclang_rt.profile-x86_64.a"
25 /// PS5 case.
26 // RUN: %clang -target x86_64-sie-ps5 --coverage %s -### 2>&1 | FileCheck --check-prefix=CHECK-PS5-PROFILE %s
27 // RUN: %clang -target x86_64-sie-ps5 -fprofile-arcs %s -### 2>&1 | FileCheck --check-prefix=CHECK-PS5-PROFILE %s
28 // RUN: %clang -target x86_64-sie-ps5 -fno-profile-arcs -fprofile-arcs %s -### 2>&1 | FileCheck --check-prefix=CHECK-PS5-PROFILE %s
29 // RUN: %clang -target x86_64-sie-ps5 -fno-profile-arcs %s -### 2>&1 | FileCheck -check-prefix=CHECK-PS5-NO-PROFILE %s
30 // RUN: %clang -target x86_64-sie-ps5 -fprofile-arcs -fno-profile-arcs %s -### 2>&1 | FileCheck --check-prefix=CHECK-PS5-NO-PROFILE %s
31 // RUN: %clang -target x86_64-sie-ps5 -fprofile-generate %s -### 2>&1 | FileCheck --check-prefix=CHECK-PS5-PROFILE %s
32 // RUN: %clang -target x86_64-sie-ps5 -fno-profile-generate %s -### 2>&1 | FileCheck --check-prefix=CHECK-PS5-NO-PROFILE %s
33 // RUN: %clang -target x86_64-sie-ps5 -fprofile-generate -fno-profile-generate %s -### 2>&1 | FileCheck --check-prefix=CHECK-PS5-NO-PROFILE %s
34 // RUN: %clang -target x86_64-sie-ps5 -fprofile-generate=dir %s -### 2>&1 | FileCheck --check-prefix=CHECK-PS5-PROFILE %s
35 // RUN: %clang -target x86_64-sie-ps5 -fprofile-instr-generate %s -### 2>&1 | FileCheck --check-prefix=CHECK-PS5-PROFILE %s
36 // RUN: %clang -target x86_64-sie-ps5 -fno-profile-instr-generate %s -### 2>&1 | FileCheck --check-prefix=CHECK-PS5-NO-PROFILE %s
37 // RUN: %clang -target x86_64-sie-ps5 -fprofile-instr-generate -fno-profile-instr-generate %s -### 2>&1 | FileCheck --check-prefix=CHECK-PS5-NO-PROFILE %s
38 // RUN: %clang -target x86_64-sie-ps5 -fprofile-generate -fno-profile-instr-generate %s -### 2>&1 | FileCheck --check-prefix=CHECK-PS5-PROFILE %s
39 // RUN: %clang -target x86_64-sie-ps5 -fprofile-instr-generate=somefile.profraw %s -### 2>&1 | FileCheck --check-prefix=CHECK-PS5-PROFILE %s
40 // RUN: %clang -target x86_64-sie-ps5 -fcs-profile-generate %s -### 2>&1 | FileCheck --check-prefix=CHECK-PS5-PROFILE %s
41 // RUN: %clang -target x86_64-sie-ps5 -fcs-profile-generate -fno-profile-generate %s -### 2>&1 | FileCheck --check-prefix=CHECK-PS5-NO-PROFILE %s
43 // CHECK-PS5-PROFILE: "--dependent-lib=libclang_rt.profile-x86_64_nosubmission.a"
44 // CHECK-PS5-NO-PROFILE-NOT: "--dependent-lib=libclang_rt.profile-x86_64_nosubmission.a"