Revert "[llvm] Improve llvm.objectsize computation by computing GEP, alloca and mallo...
[llvm-project.git] / clang / test / CodeGen / xray-instruction-threshold.cpp
blob8a27a8c746fcf8c780eecbcd783223947c22c0e7
1 // RUN: %clang_cc1 -fxray-instrument -fxray-instruction-threshold=1 -x c++ -std=c++11 -emit-llvm -o - %s -triple x86_64-unknown-linux-gnu | FileCheck %s
3 int foo() {
4 return 1;
7 [[clang::xray_never_instrument]] int bar() {
8 return 2;
11 // CHECK: define{{.*}} i32 @_Z3foov() #[[THRESHOLD:[0-9]+]] {
12 // CHECK: define{{.*}} i32 @_Z3barv() #[[NEVERATTR:[0-9]+]] {
13 // CHECK-DAG: attributes #[[THRESHOLD]] = {{.*}} "xray-instruction-threshold"="1" {{.*}}
14 // CHECK-DAG: attributes #[[NEVERATTR]] = {{.*}} "function-instrument"="xray-never" {{.*}}