teak-llvm/clang/test/Lexer/has_feature_efficiency_sanitizer.cpp
Derek Bruening 293772e72e [esan|wset] Add working set tool driver flags
Summary:
Adds a new -fsanitize=efficiency-working-set flag to enable esan's working
set tool.  Adds appropriate tests for the new flag.

Reviewers: aizatsky

Subscribers: vitalybuka, zhaoqin, kcc, eugenis, llvm-commits

Differential Revision: http://reviews.llvm.org/D20484

llvm-svn: 270641
2016-05-25 00:41:24 +00:00

13 lines
496 B
C++

// RUN: %clang_cc1 -E -fsanitize=efficiency-cache-frag %s -o - | FileCheck --check-prefix=CHECK-ESAN %s
// RUN: %clang_cc1 -E -fsanitize=efficiency-working-set %s -o - | FileCheck --check-prefix=CHECK-ESAN %s
// RUN: %clang_cc1 -E %s -o - | FileCheck --check-prefix=CHECK-NO-ESAN %s
#if __has_feature(efficiency_sanitizer)
int EfficiencySanitizerEnabled();
#else
int EfficiencySanitizerDisabled();
#endif
// CHECK-ESAN: EfficiencySanitizerEnabled
// CHECK-NO-ESAN: EfficiencySanitizerDisabled