summaryrefslogtreecommitdiffstats
path: root/clang/test/Driver/instrprof-ld.c
diff options
context:
space:
mode:
authorVedant Kumar <vsk@apple.com>2015-11-10 00:20:34 +0000
committerVedant Kumar <vsk@apple.com>2015-11-10 00:20:34 +0000
commit0affb938946183c6aa7332cb17d57a930e2ecb9c (patch)
treea5d7f0d2689e5d578c6b9210778b4ef90d4fbfea /clang/test/Driver/instrprof-ld.c
parent3bfc3e2d2a8a57faf0946a2babc5320452546a14 (diff)
downloadbcm5719-llvm-0affb938946183c6aa7332cb17d57a930e2ecb9c.tar.gz
bcm5719-llvm-0affb938946183c6aa7332cb17d57a930e2ecb9c.zip
[Driver] Use platform-appropriate profiling libraries for WatchOS, TVOS
When adding profiling instrumentation, use libclang_rt.profile_tvos.a for TVOS targets and libclang_rt.profile_watchos.a for WatchOS targets. I've also fixed up a comment and added an assert() that prevents us from defaulting to an incorrect platform. Differential Revision: http://reviews.llvm.org/D14521 Reviewed-by: t.p.northover llvm-svn: 252558
Diffstat (limited to 'clang/test/Driver/instrprof-ld.c')
-rw-r--r--clang/test/Driver/instrprof-ld.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/clang/test/Driver/instrprof-ld.c b/clang/test/Driver/instrprof-ld.c
index cd926cd186b..b3ba12ee434 100644
--- a/clang/test/Driver/instrprof-ld.c
+++ b/clang/test/Driver/instrprof-ld.c
@@ -89,3 +89,19 @@
//
// CHECK-DARWIN-ARM64: "{{(.*[^-.0-9A-Z_a-z])?}}ld{{(.exe)?}}"
// CHECK-DARWIN-ARM64: "{{.*}}/Inputs/resource_dir{{/|\\\\}}lib{{/|\\\\}}darwin{{/|\\\\}}libclang_rt.profile_ios.a"
+//
+// RUN: %clang -no-canonical-prefixes %s -### -o %t.o 2>&1 \
+// RUN: -target armv7-apple-darwin -mtvos-version-min=8.3 -fprofile-instr-generate \
+// RUN: -resource-dir=%S/Inputs/resource_dir \
+// RUN: | FileCheck --check-prefix=CHECK-TVOS-ARMV7 %s
+//
+// CHECK-TVOS-ARMV7: "{{(.*[^-.0-9A-Z_a-z])?}}ld{{(.exe)?}}"
+// CHECK-TVOS-ARMV7: "{{.*}}/Inputs/resource_dir{{/|\\\\}}lib{{/|\\\\}}darwin{{/|\\\\}}libclang_rt.profile_tvos.a"
+//
+// RUN: %clang -no-canonical-prefixes %s -### -o %t.o 2>&1 \
+// RUN: -target armv7s-apple-darwin10 -mwatchos-version-min=2.0 -arch armv7k -fprofile-instr-generate \
+// RUN: -resource-dir=%S/Inputs/resource_dir \
+// RUN: | FileCheck --check-prefix=CHECK-WATCHOS-ARMV7 %s
+//
+// CHECK-WATCHOS-ARMV7: "{{(.*[^-.0-9A-Z_a-z])?}}ld{{(.exe)?}}"
+// CHECK-WATCHOS-ARMV7: "{{.*}}/Inputs/resource_dir{{/|\\\\}}lib{{/|\\\\}}darwin{{/|\\\\}}libclang_rt.profile_watchos.a"
OpenPOWER on IntegriCloud