diff options
| author | Vedant Kumar <vsk@apple.com> | 2016-06-22 17:30:58 +0000 |
|---|---|---|
| committer | Vedant Kumar <vsk@apple.com> | 2016-06-22 17:30:58 +0000 |
| commit | f5ac6d49e40854c07b482917b6ea51dfc48db963 (patch) | |
| tree | d6faf5527e5b982ab0ae6cd81f8639b7bbcec8e9 /llvm/test/Instrumentation | |
| parent | 643dd83661d46f69d5f7a6dd0ec0e4df764ba6e3 (diff) | |
| download | bcm5719-llvm-f5ac6d49e40854c07b482917b6ea51dfc48db963.tar.gz bcm5719-llvm-f5ac6d49e40854c07b482917b6ea51dfc48db963.zip | |
[asan] Do not instrument accesses to profiling globals
It's only useful to asan-itize profiling globals while debugging llvm's
profiling instrumentation passes. Enabling asan along with instrprof or
gcov instrumentation shouldn't incur extra overhead.
This patch is in the same spirit as r264805 and r273202, which disabled
tsan instrumentation of instrprof/gcov globals.
Differential Revision: http://reviews.llvm.org/D21541
llvm-svn: 273444
Diffstat (limited to 'llvm/test/Instrumentation')
| -rw-r--r-- | llvm/test/Instrumentation/AddressSanitizer/do-not-instrument-profiling-globals.ll | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/llvm/test/Instrumentation/AddressSanitizer/do-not-instrument-profiling-globals.ll b/llvm/test/Instrumentation/AddressSanitizer/do-not-instrument-profiling-globals.ll new file mode 100644 index 00000000000..82fb2f0d2f7 --- /dev/null +++ b/llvm/test/Instrumentation/AddressSanitizer/do-not-instrument-profiling-globals.ll @@ -0,0 +1,9 @@ +; This test checks that we don't instrument globals created by profiling passes. +; RUN: opt < %s -asan -asan-module -S | FileCheck %s + +@__profc_test = private global [1 x i64] zeroinitializer, section "__DATA,__llvm_prf_cnts", align 8 +@__llvm_gcov_ctr = internal global [1 x i64] zeroinitializer + +; CHECK-DAG: @asan.module_ctor +; CHECK-NOT: @__asan_gen{{.*}}__llvm_gcov_ctr +; CHECK-NOT: @__asan_gen{{.*}}__profc_test |

