aboutsummaryrefslogtreecommitdiff
path: root/clang/test/Driver/fcs-profile-generate.c
diff options
context:
space:
mode:
Diffstat (limited to 'clang/test/Driver/fcs-profile-generate.c')
-rw-r--r--clang/test/Driver/fcs-profile-generate.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/clang/test/Driver/fcs-profile-generate.c b/clang/test/Driver/fcs-profile-generate.c
index f69fa44..ecb5aad 100644
--- a/clang/test/Driver/fcs-profile-generate.c
+++ b/clang/test/Driver/fcs-profile-generate.c
@@ -1,10 +1,14 @@
-// RUN: %clang -### -c -fprofile-use=a.profdata -fcs-profile-generate %s 2>&1 | FileCheck %s
+// RUN: rm -rf %t && mkdir %t
+// RUN: llvm-profdata merge -o %t/a.profdata %S/Inputs/a.proftext
+
+// RUN: %clang -### -c -fprofile-use=%t/a.profdata -fcs-profile-generate %s 2>&1 | FileCheck %s
// CHECK: "-fprofile-instrument=csllvm"
// CHECK-NOT: "-fprofile-instrument-path=
-// CHECK-SAME: "-fprofile-instrument-use-path=a.profdata"
+// CHECK-SAME: "-fprofile-instrument-use=llvm"
+// CHECK-SAME: "-fprofile-instrument-use-path={{.*}}a.profdata"
-// RUN: %clang -### -c -fprofile-use=a.profdata -fcs-profile-generate=dir %s 2>&1 | FileCheck %s --check-prefix=CHECK1
-// CHECK1: "-fprofile-instrument=csllvm"{{.*}} "-fprofile-instrument-path=dir{{/|\\\\}}default_%m.profraw" "-fprofile-instrument-use-path=a.profdata"
+// RUN: %clang -### -c -fprofile-use=%t/a.profdata -fcs-profile-generate=dir %s 2>&1 | FileCheck %s --check-prefix=CHECK1
+// CHECK1: "-fprofile-instrument=csllvm"{{.*}} "-fprofile-instrument-path=dir{{/|\\\\}}default_%m.profraw" "-fprofile-instrument-use=llvm" "-fprofile-instrument-use-path={{.*}}a.profdata"
/// Degradation case. This usage does not make much sense.
// RUN: %clang -### -c -fcs-profile-generate %s 2>&1 | FileCheck %s --check-prefix=NOUSE