summaryrefslogtreecommitdiffstats
path: root/compiler-rt/test/profile
diff options
context:
space:
mode:
authorVedant Kumar <vsk@apple.com>2018-06-28 17:53:43 +0000
committerVedant Kumar <vsk@apple.com>2018-06-28 17:53:43 +0000
commitc8735fbb4c9e0d3b678d2ee804685ebdd9bef211 (patch)
tree5361aad9d48fd5b89af28d9bc9d9508de405b677 /compiler-rt/test/profile
parent29b46c469b517e488f821b7c94fa70379c9a8acd (diff)
downloadbcm5719-llvm-c8735fbb4c9e0d3b678d2ee804685ebdd9bef211.tar.gz
bcm5719-llvm-c8735fbb4c9e0d3b678d2ee804685ebdd9bef211.zip
[Darwin] Add an integration test for PGO + symbol exports
rdar://41470205 llvm-svn: 335891
Diffstat (limited to 'compiler-rt/test/profile')
-rw-r--r--compiler-rt/test/profile/instrprof-darwin-exports.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/compiler-rt/test/profile/instrprof-darwin-exports.c b/compiler-rt/test/profile/instrprof-darwin-exports.c
new file mode 100644
index 00000000000..6667cabdb2d
--- /dev/null
+++ b/compiler-rt/test/profile/instrprof-darwin-exports.c
@@ -0,0 +1,11 @@
+// REQUIRES: osx-ld64-live_support
+
+// Compiling with PGO/code coverage on Darwin should raise no warnings or errors
+// when using an exports list.
+
+// RUN: echo "_main" > %t.exports
+// RUN: %clang_pgogen -Werror -Wl,-exported_symbols_list,%t.exports -o %t %s 2>&1 | tee %t.log
+// RUN: %clang_profgen -Werror -fcoverage-mapping -Wl,-exported_symbols_list,%t.exports -o %t %s 2>&1 | tee -a %t.log
+// RUN: cat %t.log | count 0
+
+int main() {}
OpenPOWER on IntegriCloud