diff options
author | Kostya Serebryany <kcc@google.com> | 2015-03-10 01:58:27 +0000 |
---|---|---|
committer | Kostya Serebryany <kcc@google.com> | 2015-03-10 01:58:27 +0000 |
commit | 935a3aa5bc1441ec05e8b2656080b73f3a5fef1a (patch) | |
tree | ee6db3f28dded253a340943d54861b31ae36dbf4 /test | |
parent | a7b107bc826153fdaf6f3db179e3a1d4c91b948f (diff) |
[sanitizer] fix instrumentation with -mllvm -sanitizer-coverage-block-threshold=0 to actually do something useful.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@231736 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test')
-rw-r--r-- | test/Instrumentation/SanitizerCoverage/coverage.ll | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/test/Instrumentation/SanitizerCoverage/coverage.ll b/test/Instrumentation/SanitizerCoverage/coverage.ll index 024a9dceff3..b2f0ab0680b 100644 --- a/test/Instrumentation/SanitizerCoverage/coverage.ll +++ b/test/Instrumentation/SanitizerCoverage/coverage.ll @@ -2,6 +2,7 @@ ; RUN: opt < %s -sancov -sanitizer-coverage-level=1 -S | FileCheck %s --check-prefix=CHECK1 ; RUN: opt < %s -sancov -sanitizer-coverage-level=2 -S | FileCheck %s --check-prefix=CHECK2 ; RUN: opt < %s -sancov -sanitizer-coverage-level=2 -sanitizer-coverage-block-threshold=10 -S | FileCheck %s --check-prefix=CHECK2 +; RUN: opt < %s -sancov -sanitizer-coverage-level=2 -sanitizer-coverage-block-threshold=0 -S | FileCheck %s --check-prefix=CHECK_WITH_CHECK ; RUN: opt < %s -sancov -sanitizer-coverage-level=2 -sanitizer-coverage-block-threshold=1 -S | FileCheck %s --check-prefix=CHECK_WITH_CHECK ; RUN: opt < %s -sancov -sanitizer-coverage-level=3 -sanitizer-coverage-block-threshold=10 -S | FileCheck %s --check-prefix=CHECK3 ; RUN: opt < %s -sancov -sanitizer-coverage-level=4 -S | FileCheck %s --check-prefix=CHECK4 @@ -51,6 +52,10 @@ entry: ; CHECK_WITH_CHECK-LABEL: define void @foo ; CHECK_WITH_CHECK: __sanitizer_cov_with_check ; CHECK_WITH_CHECK: ret void +; CHECK_WITH_CHECK-LABEL: define internal void @sancov.module_ctor +; CHECK_WITH_CHECK-NOT: ret +; CHECK_WITH_CHECK: call void @__sanitizer_cov_module_init({{.*}}, i64 4, +; CHECK_WITH_CHECK: ret ; CHECK2-LABEL: define void @foo ; CHECK2: call void @__sanitizer_cov |