diff options
| author | Dimitry Andric <dim@FreeBSD.org> | 2017-12-18 20:11:37 +0000 |
|---|---|---|
| committer | Dimitry Andric <dim@FreeBSD.org> | 2017-12-18 20:11:37 +0000 |
| commit | 461a67fa15370a9ec88f8f8a240bf7c123bb2029 (patch) | |
| tree | 6942083d7d56bba40ec790a453ca58ad3baf6832 /test/Driver/XRay/xray-shared-noxray.cpp | |
| parent | 75c3240472ba6ac2669ee72ca67eb72d4e2851fc (diff) | |
Notes
Diffstat (limited to 'test/Driver/XRay/xray-shared-noxray.cpp')
| -rw-r--r-- | test/Driver/XRay/xray-shared-noxray.cpp | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/test/Driver/XRay/xray-shared-noxray.cpp b/test/Driver/XRay/xray-shared-noxray.cpp new file mode 100644 index 000000000000..c279f93f3f3d --- /dev/null +++ b/test/Driver/XRay/xray-shared-noxray.cpp @@ -0,0 +1,16 @@ +// RUN: %clangxx -shared -o /dev/null -v -fxray-instrument %s -### +// RUN: %clangxx -shared -o /dev/null -v -fxray-instrument %s -### 2>&1 | \ +// RUN: FileCheck %s --check-prefix=SHARED +// RUN: %clangxx -static -o /dev/null -v -fxray-instrument %s -### -DMAIN +// RUN: %clangxx -static -o /dev/null -v -fxray-instrument %s -### 2>&1 -DMAIN \ +// RUN: | FileCheck %s --check-prefix=STATIC +// +// SHARED-NOT: {{clang_rt\.xray-}} +// STATIC: {{clang_rt\.xray-}} +// +// REQUIRES: linux, enable_shared +int foo() { return 42; } + +#ifdef MAIN +int main() { return foo(); } +#endif |
