blob: 564df88c4e20fdc1e12bd4cb491621ea1a4fa8d7 [file] [log] [blame]
Dean Michael Berrisc67811c2017-09-26 03:18:11 +00001// RUN: %clangxx -shared -fPIC -o /dev/null -v -fxray-instrument %s 2>&1 | \
2// RUN: FileCheck %s --check-prefix=SHARED
3// RUN: %clangxx -static -o /dev/null -v -fxray-instrument %s 2>&1 -DMAIN | \
4// RUN: FileCheck %s --check-prefix=STATIC
5// RUN: %clangxx -static -fPIE -o /dev/null -v -fxray-instrument %s 2>&1 \
6// RUN: -DMAIN | FileCheck %s --check-prefix=STATIC
7//
8// SHARED-NOT: {{clang_rt\.xray-}}
9// STATIC: {{clang_rt\.xray-}}
10//
11// REQUIRES: linux
12int foo() { return 42; }
13
14#ifdef MAIN
15int main() { return foo(); }
16#endif