summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFrancis Ricci <francisjricci@gmail.com>2017-04-20 21:00:02 +0000
committerFrancis Ricci <francisjricci@gmail.com>2017-04-20 21:00:02 +0000
commit6b494d9edcde2054d58b932df6e2f8ccb539afed (patch)
tree78ce4f65cc449d7f4993073682641a7a058d1e0d
parentf50f97c9dd7fa784bf9d894ea3c6e843cd9b2472 (diff)
downloadbcm5719-llvm-6b494d9edcde2054d58b932df6e2f8ccb539afed.tar.gz
bcm5719-llvm-6b494d9edcde2054d58b932df6e2f8ccb539afed.zip
make detect_leaks=1 the default for the lsan test suite
Summary: This already appears to be the case in all .cc test files, it was probably left out of the .c test files accidentally. Make it a global default, instead of manually adding it to each individual test. This is needed to force leak detection for Darwin tests, where leak detection is disabled by default. Reviewers: m.ostapenko, kubamracek, alekseyshl Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D32297 llvm-svn: 300890
-rw-r--r--compiler-rt/test/lsan/TestCases/Linux/use_tls_dynamic.cc2
-rw-r--r--compiler-rt/test/lsan/TestCases/Linux/use_tls_pthread_specific_dynamic.cc2
-rw-r--r--compiler-rt/test/lsan/TestCases/Linux/use_tls_pthread_specific_static.cc2
-rw-r--r--compiler-rt/test/lsan/TestCases/Linux/use_tls_static.cc2
-rw-r--r--compiler-rt/test/lsan/TestCases/disabler.cc2
-rw-r--r--compiler-rt/test/lsan/TestCases/do_leak_check_override.cc2
-rw-r--r--compiler-rt/test/lsan/TestCases/high_allocator_contention.cc2
-rw-r--r--compiler-rt/test/lsan/TestCases/large_allocation_leak.cc2
-rw-r--r--compiler-rt/test/lsan/TestCases/leak_check_at_exit.cc2
-rw-r--r--compiler-rt/test/lsan/TestCases/link_turned_off.cc2
-rw-r--r--compiler-rt/test/lsan/TestCases/pointer_to_self.cc2
-rw-r--r--compiler-rt/test/lsan/TestCases/print_suppressions.cc2
-rw-r--r--compiler-rt/test/lsan/TestCases/recoverable_leak_check.cc2
-rw-r--r--compiler-rt/test/lsan/TestCases/register_root_region.cc2
-rw-r--r--compiler-rt/test/lsan/TestCases/stale_stack_leak.cc2
-rw-r--r--compiler-rt/test/lsan/TestCases/suppressions_default.cc2
-rw-r--r--compiler-rt/test/lsan/TestCases/suppressions_file.cc2
-rw-r--r--compiler-rt/test/lsan/TestCases/swapcontext.cc5
-rw-r--r--compiler-rt/test/lsan/TestCases/use_after_return.cc2
-rw-r--r--compiler-rt/test/lsan/TestCases/use_globals_initialized.cc2
-rw-r--r--compiler-rt/test/lsan/TestCases/use_globals_uninitialized.cc2
-rw-r--r--compiler-rt/test/lsan/TestCases/use_poisoned_asan.cc2
-rw-r--r--compiler-rt/test/lsan/TestCases/use_registers.cc2
-rw-r--r--compiler-rt/test/lsan/TestCases/use_stacks.cc2
-rw-r--r--compiler-rt/test/lsan/TestCases/use_stacks_threaded.cc2
-rw-r--r--compiler-rt/test/lsan/TestCases/use_unaligned.cc2
-rw-r--r--compiler-rt/test/lsan/lit.common.cfg4
27 files changed, 29 insertions, 30 deletions
diff --git a/compiler-rt/test/lsan/TestCases/Linux/use_tls_dynamic.cc b/compiler-rt/test/lsan/TestCases/Linux/use_tls_dynamic.cc
index c81bcaed25a..d60dec08fb2 100644
--- a/compiler-rt/test/lsan/TestCases/Linux/use_tls_dynamic.cc
+++ b/compiler-rt/test/lsan/TestCases/Linux/use_tls_dynamic.cc
@@ -1,5 +1,5 @@
// Test that dynamically allocated TLS space is included in the root set.
-// RUN: LSAN_BASE="detect_leaks=1:report_objects=1:use_stacks=0:use_registers=0:use_ld_allocations=0"
+// RUN: LSAN_BASE="report_objects=1:use_stacks=0:use_registers=0:use_ld_allocations=0"
// RUN: %clangxx %s -DBUILD_DSO -fPIC -shared -o %t-so.so
// RUN: %clangxx_lsan %s -o %t
// RUN: %env_lsan_opts=$LSAN_BASE:"use_tls=0" not %run %t 2>&1 | FileCheck %s
diff --git a/compiler-rt/test/lsan/TestCases/Linux/use_tls_pthread_specific_dynamic.cc b/compiler-rt/test/lsan/TestCases/Linux/use_tls_pthread_specific_dynamic.cc
index 947a4ce243e..650e6ad20aa 100644
--- a/compiler-rt/test/lsan/TestCases/Linux/use_tls_pthread_specific_dynamic.cc
+++ b/compiler-rt/test/lsan/TestCases/Linux/use_tls_pthread_specific_dynamic.cc
@@ -1,5 +1,5 @@
// Test that dynamically allocated thread-specific storage is included in the root set.
-// RUN: LSAN_BASE="detect_leaks=1:report_objects=1:use_stacks=0:use_registers=0"
+// RUN: LSAN_BASE="report_objects=1:use_stacks=0:use_registers=0"
// RUN: %clangxx_lsan %s -o %t
// RUN: %env_lsan_opts=$LSAN_BASE:"use_tls=0" not %run %t 2>&1 | FileCheck %s
// RUN: %env_lsan_opts=$LSAN_BASE:"use_tls=1" %run %t 2>&1
diff --git a/compiler-rt/test/lsan/TestCases/Linux/use_tls_pthread_specific_static.cc b/compiler-rt/test/lsan/TestCases/Linux/use_tls_pthread_specific_static.cc
index 8f5afc49aea..cafe40f0637 100644
--- a/compiler-rt/test/lsan/TestCases/Linux/use_tls_pthread_specific_static.cc
+++ b/compiler-rt/test/lsan/TestCases/Linux/use_tls_pthread_specific_static.cc
@@ -1,5 +1,5 @@
// Test that statically allocated thread-specific storage is included in the root set.
-// RUN: LSAN_BASE="detect_leaks=1:report_objects=1:use_stacks=0:use_registers=0"
+// RUN: LSAN_BASE="report_objects=1:use_stacks=0:use_registers=0"
// RUN: %clangxx_lsan %s -o %t
// RUN: %env_lsan_opts=$LSAN_BASE:"use_tls=0" not %run %t 2>&1 | FileCheck %s
// RUN: %env_lsan_opts=$LSAN_BASE:"use_tls=1" %run %t 2>&1
diff --git a/compiler-rt/test/lsan/TestCases/Linux/use_tls_static.cc b/compiler-rt/test/lsan/TestCases/Linux/use_tls_static.cc
index e56f5e13af2..84cc6c99fcc 100644
--- a/compiler-rt/test/lsan/TestCases/Linux/use_tls_static.cc
+++ b/compiler-rt/test/lsan/TestCases/Linux/use_tls_static.cc
@@ -1,5 +1,5 @@
// Test that statically allocated TLS space is included in the root set.
-// RUN: LSAN_BASE="detect_leaks=1:report_objects=1:use_stacks=0:use_registers=0"
+// RUN: LSAN_BASE="report_objects=1:use_stacks=0:use_registers=0"
// RUN: %clangxx_lsan %s -o %t
// RUN: %env_lsan_opts=$LSAN_BASE:"use_tls=0" not %run %t 2>&1 | FileCheck %s
// RUN: %env_lsan_opts=$LSAN_BASE:"use_tls=1" %run %t 2>&1
diff --git a/compiler-rt/test/lsan/TestCases/disabler.cc b/compiler-rt/test/lsan/TestCases/disabler.cc
index feabc36fab3..c5ffdb0bf6f 100644
--- a/compiler-rt/test/lsan/TestCases/disabler.cc
+++ b/compiler-rt/test/lsan/TestCases/disabler.cc
@@ -1,5 +1,5 @@
// Test for ScopedDisabler.
-// RUN: LSAN_BASE="detect_leaks=1:report_objects=1:use_registers=0:use_stacks=0:use_globals=0:use_tls=0"
+// RUN: LSAN_BASE="report_objects=1:use_registers=0:use_stacks=0:use_globals=0:use_tls=0"
// RUN: %clangxx_lsan %s -o %t
// RUN: %env_lsan_opts=$LSAN_BASE not %run %t 2>&1 | FileCheck %s
diff --git a/compiler-rt/test/lsan/TestCases/do_leak_check_override.cc b/compiler-rt/test/lsan/TestCases/do_leak_check_override.cc
index bffcf6ef66a..40a97635cc1 100644
--- a/compiler-rt/test/lsan/TestCases/do_leak_check_override.cc
+++ b/compiler-rt/test/lsan/TestCases/do_leak_check_override.cc
@@ -1,7 +1,7 @@
// Test for __lsan_do_leak_check(). We test it by making the leak check run
// before global destructors, which also tests compatibility with HeapChecker's
// "normal" mode (LSan runs in "strict" mode by default).
-// RUN: LSAN_BASE="detect_leaks=1:use_stacks=0:use_registers=0"
+// RUN: LSAN_BASE="use_stacks=0:use_registers=0"
// RUN: %clangxx_lsan %s -o %t
// RUN: %env_lsan_opts=$LSAN_BASE not %run %t 2>&1 | FileCheck --check-prefix=CHECK-strict %s
// RUN: %env_lsan_opts=$LSAN_BASE not %run %t foo 2>&1 | FileCheck --check-prefix=CHECK-normal %s
diff --git a/compiler-rt/test/lsan/TestCases/high_allocator_contention.cc b/compiler-rt/test/lsan/TestCases/high_allocator_contention.cc
index 8d8f9879bfa..cbe592c4f02 100644
--- a/compiler-rt/test/lsan/TestCases/high_allocator_contention.cc
+++ b/compiler-rt/test/lsan/TestCases/high_allocator_contention.cc
@@ -1,6 +1,6 @@
// A benchmark that executes malloc/free pairs in parallel.
// Usage: ./a.out number_of_threads total_number_of_allocations
-// RUN: LSAN_BASE="detect_leaks=1:use_ld_allocations=0"
+// RUN: LSAN_BASE="use_ld_allocations=0"
// RUN: %clangxx_lsan %s -o %t
// RUN: %env_lsan_opts=$LSAN_BASE %run %t 5 1000000 2>&1
#include <assert.h>
diff --git a/compiler-rt/test/lsan/TestCases/large_allocation_leak.cc b/compiler-rt/test/lsan/TestCases/large_allocation_leak.cc
index 6bf593be13a..66f364fffcd 100644
--- a/compiler-rt/test/lsan/TestCases/large_allocation_leak.cc
+++ b/compiler-rt/test/lsan/TestCases/large_allocation_leak.cc
@@ -1,5 +1,5 @@
// Test that LargeMmapAllocator's chunks aren't reachable via some internal data structure.
-// RUN: LSAN_BASE="detect_leaks=1:report_objects=1:use_stacks=0:use_registers=0"
+// RUN: LSAN_BASE="report_objects=1:use_stacks=0:use_registers=0"
// RUN: %clangxx_lsan %s -o %t
// RUN: %env_lsan_opts=$LSAN_BASE not %run %t 2>&1 | FileCheck %s
diff --git a/compiler-rt/test/lsan/TestCases/leak_check_at_exit.cc b/compiler-rt/test/lsan/TestCases/leak_check_at_exit.cc
index 2e00cfb12fb..8a8ff824566 100644
--- a/compiler-rt/test/lsan/TestCases/leak_check_at_exit.cc
+++ b/compiler-rt/test/lsan/TestCases/leak_check_at_exit.cc
@@ -1,5 +1,5 @@
// Test for the leak_check_at_exit flag.
-// RUN: LSAN_BASE="detect_leaks=1:use_stacks=0:use_registers=0"
+// RUN: LSAN_BASE="use_stacks=0:use_registers=0"
// RUN: %clangxx_lsan %s -o %t
// RUN: %env_lsan_opts=$LSAN_BASE not %run %t foo 2>&1 | FileCheck %s --check-prefix=CHECK-do
// RUN: %env_lsan_opts=$LSAN_BASE not %run %t 2>&1 | FileCheck %s --check-prefix=CHECK-do
diff --git a/compiler-rt/test/lsan/TestCases/link_turned_off.cc b/compiler-rt/test/lsan/TestCases/link_turned_off.cc
index da848bbc327..b8458de63dd 100644
--- a/compiler-rt/test/lsan/TestCases/link_turned_off.cc
+++ b/compiler-rt/test/lsan/TestCases/link_turned_off.cc
@@ -1,5 +1,5 @@
// Test for disabling LSan at link-time.
-// RUN: LSAN_BASE="detect_leaks=1:use_stacks=0:use_registers=0"
+// RUN: LSAN_BASE="use_stacks=0:use_registers=0"
// RUN: %clangxx_lsan %s -o %t
// RUN: %env_lsan_opts=$LSAN_BASE %run %t
// RUN: %env_lsan_opts=$LSAN_BASE not %run %t foo 2>&1 | FileCheck %s
diff --git a/compiler-rt/test/lsan/TestCases/pointer_to_self.cc b/compiler-rt/test/lsan/TestCases/pointer_to_self.cc
index 4f34d8a8f1e..62683a21550 100644
--- a/compiler-rt/test/lsan/TestCases/pointer_to_self.cc
+++ b/compiler-rt/test/lsan/TestCases/pointer_to_self.cc
@@ -1,6 +1,6 @@
// Regression test: pointers to self should not confuse LSan into thinking the
// object is indirectly leaked. Only external pointers count.
-// RUN: LSAN_BASE="detect_leaks=1:report_objects=1:use_registers=0"
+// RUN: LSAN_BASE="report_objects=1:use_registers=0"
// RUN: %clangxx_lsan %s -o %t
// RUN: %env_lsan_opts=$LSAN_BASE:"use_stacks=0" not %run %t 2>&1 | FileCheck %s
diff --git a/compiler-rt/test/lsan/TestCases/print_suppressions.cc b/compiler-rt/test/lsan/TestCases/print_suppressions.cc
index 0f914724456..2fa199d5d96 100644
--- a/compiler-rt/test/lsan/TestCases/print_suppressions.cc
+++ b/compiler-rt/test/lsan/TestCases/print_suppressions.cc
@@ -1,6 +1,6 @@
// Print matched suppressions only if print_suppressions=1 AND at least one is
// matched. Default is print_suppressions=true.
-// RUN: LSAN_BASE="detect_leaks=1:use_registers=0:use_stacks=0"
+// RUN: LSAN_BASE="use_registers=0:use_stacks=0"
// RUN: %clangxx_lsan %s -o %t
// RUN: %env_lsan_opts=$LSAN_BASE:print_suppressions=0 %run %t 2>&1 | FileCheck %s --check-prefix=CHECK-dont-print
// RUN: %env_lsan_opts=$LSAN_BASE %run %t 2>&1 | FileCheck %s --check-prefix=CHECK-dont-print
diff --git a/compiler-rt/test/lsan/TestCases/recoverable_leak_check.cc b/compiler-rt/test/lsan/TestCases/recoverable_leak_check.cc
index be10a49dc92..909698561e8 100644
--- a/compiler-rt/test/lsan/TestCases/recoverable_leak_check.cc
+++ b/compiler-rt/test/lsan/TestCases/recoverable_leak_check.cc
@@ -1,5 +1,5 @@
// Test for on-demand leak checking.
-// RUN: LSAN_BASE="detect_leaks=1:use_stacks=0:use_registers=0"
+// RUN: LSAN_BASE="use_stacks=0:use_registers=0"
// RUN: %clangxx_lsan %s -o %t
// RUN: %env_lsan_opts=$LSAN_BASE %run %t foo 2>&1 | FileCheck %s
// RUN: %env_lsan_opts=$LSAN_BASE %run %t 2>&1 | FileCheck %s
diff --git a/compiler-rt/test/lsan/TestCases/register_root_region.cc b/compiler-rt/test/lsan/TestCases/register_root_region.cc
index 6e3c8c1ce0c..b73b56b526f 100644
--- a/compiler-rt/test/lsan/TestCases/register_root_region.cc
+++ b/compiler-rt/test/lsan/TestCases/register_root_region.cc
@@ -1,5 +1,5 @@
// Test for __lsan_(un)register_root_region().
-// RUN: LSAN_BASE="detect_leaks=1:use_stacks=0:use_registers=0"
+// RUN: LSAN_BASE="use_stacks=0:use_registers=0"
// RUN: %clangxx_lsan %s -o %t
// RUN: %env_lsan_opts=$LSAN_BASE %run %t
// RUN: %env_lsan_opts=$LSAN_BASE not %run %t foo 2>&1 | FileCheck %s
diff --git a/compiler-rt/test/lsan/TestCases/stale_stack_leak.cc b/compiler-rt/test/lsan/TestCases/stale_stack_leak.cc
index 0b33f26a4f3..635d7381427 100644
--- a/compiler-rt/test/lsan/TestCases/stale_stack_leak.cc
+++ b/compiler-rt/test/lsan/TestCases/stale_stack_leak.cc
@@ -1,5 +1,5 @@
// Test that out-of-scope local variables are ignored by LSan.
-// RUN: LSAN_BASE="detect_leaks=1:report_objects=1:use_registers=0:use_stacks=1"
+// RUN: LSAN_BASE="report_objects=1:use_registers=0:use_stacks=1"
// RUN: %clangxx_lsan %s -o %t
// RUN: %env_lsan_opts=$LSAN_BASE not %run %t 2>&1 | FileCheck %s
// RUN: %env_lsan_opts=$LSAN_BASE":exitcode=0" %run %t 2>&1 | FileCheck --check-prefix=CHECK-sanity %s
diff --git a/compiler-rt/test/lsan/TestCases/suppressions_default.cc b/compiler-rt/test/lsan/TestCases/suppressions_default.cc
index da240f200ba..9a660e6100d 100644
--- a/compiler-rt/test/lsan/TestCases/suppressions_default.cc
+++ b/compiler-rt/test/lsan/TestCases/suppressions_default.cc
@@ -1,4 +1,4 @@
-// RUN: LSAN_BASE="detect_leaks=1:use_registers=0:use_stacks=0"
+// RUN: LSAN_BASE="use_registers=0:use_stacks=0"
// RUN: %clangxx_lsan %s -o %t
// RUN: %env_lsan_opts=$LSAN_BASE not %run %t 2>&1 | FileCheck %s
diff --git a/compiler-rt/test/lsan/TestCases/suppressions_file.cc b/compiler-rt/test/lsan/TestCases/suppressions_file.cc
index a14afc4d566..33cf0202d73 100644
--- a/compiler-rt/test/lsan/TestCases/suppressions_file.cc
+++ b/compiler-rt/test/lsan/TestCases/suppressions_file.cc
@@ -1,4 +1,4 @@
-// RUN: LSAN_BASE="detect_leaks=1:use_registers=0:use_stacks=0"
+// RUN: LSAN_BASE="use_registers=0:use_stacks=0"
// RUN: %clangxx_lsan %s -o %t
// RUN: rm -f %t.supp
diff --git a/compiler-rt/test/lsan/TestCases/swapcontext.cc b/compiler-rt/test/lsan/TestCases/swapcontext.cc
index b019067aaca..f46897a97c2 100644
--- a/compiler-rt/test/lsan/TestCases/swapcontext.cc
+++ b/compiler-rt/test/lsan/TestCases/swapcontext.cc
@@ -2,9 +2,8 @@
// memory. Make sure we don't report these leaks.
// RUN: %clangxx_lsan %s -o %t
-// RUN: LSAN_BASE="detect_leaks=1"
-// RUN: %env_lsan_opts=$LSAN_BASE %run %t 2>&1
-// RUN: %env_lsan_opts=$LSAN_BASE not %run %t foo 2>&1 | FileCheck %s
+// RUN: %env_lsan_opts= %run %t 2>&1
+// RUN: %env_lsan_opts= not %run %t foo 2>&1 | FileCheck %s
// UNSUPPORTED: arm
#include <stdio.h>
diff --git a/compiler-rt/test/lsan/TestCases/use_after_return.cc b/compiler-rt/test/lsan/TestCases/use_after_return.cc
index 6c00639c017..5c60ec60f3e 100644
--- a/compiler-rt/test/lsan/TestCases/use_after_return.cc
+++ b/compiler-rt/test/lsan/TestCases/use_after_return.cc
@@ -1,6 +1,6 @@
// Test that fake stack (introduced by ASan's use-after-return mode) is included
// in the root set.
-// RUN: LSAN_BASE="detect_leaks=1:report_objects=1:use_registers=0"
+// RUN: LSAN_BASE="report_objects=1:use_registers=0"
// RUN: %clangxx_lsan %s -O2 -o %t
// RUN: ASAN_OPTIONS=$ASAN_OPTIONS:detect_stack_use_after_return=1 %env_lsan_opts=$LSAN_BASE:"use_stacks=0" not %run %t 2>&1 | FileCheck %s
// RUN: ASAN_OPTIONS=$ASAN_OPTIONS:detect_stack_use_after_return=1 %env_lsan_opts=$LSAN_BASE:"use_stacks=1" %run %t 2>&1
diff --git a/compiler-rt/test/lsan/TestCases/use_globals_initialized.cc b/compiler-rt/test/lsan/TestCases/use_globals_initialized.cc
index 07557ee8b1e..8664618ebca 100644
--- a/compiler-rt/test/lsan/TestCases/use_globals_initialized.cc
+++ b/compiler-rt/test/lsan/TestCases/use_globals_initialized.cc
@@ -1,5 +1,5 @@
// Test that initialized globals are included in the root set.
-// RUN: LSAN_BASE="detect_leaks=1:report_objects=1:use_stacks=0:use_registers=0"
+// RUN: LSAN_BASE="report_objects=1:use_stacks=0:use_registers=0"
// RUN: %clangxx_lsan %s -o %t
// RUN: %env_lsan_opts=$LSAN_BASE:"use_globals=0" not %run %t 2>&1 | FileCheck %s
// RUN: %env_lsan_opts=$LSAN_BASE:"use_globals=1" %run %t 2>&1
diff --git a/compiler-rt/test/lsan/TestCases/use_globals_uninitialized.cc b/compiler-rt/test/lsan/TestCases/use_globals_uninitialized.cc
index f42608662d8..ef8f8e1f389 100644
--- a/compiler-rt/test/lsan/TestCases/use_globals_uninitialized.cc
+++ b/compiler-rt/test/lsan/TestCases/use_globals_uninitialized.cc
@@ -1,5 +1,5 @@
// Test that uninitialized globals are included in the root set.
-// RUN: LSAN_BASE="detect_leaks=1:report_objects=1:use_stacks=0:use_registers=0"
+// RUN: LSAN_BASE="report_objects=1:use_stacks=0:use_registers=0"
// RUN: %clangxx_lsan %s -o %t
// RUN: %env_lsan_opts=$LSAN_BASE:"use_globals=0" not %run %t 2>&1 | FileCheck %s
// RUN: %env_lsan_opts=$LSAN_BASE:"use_globals=1" %run %t 2>&1
diff --git a/compiler-rt/test/lsan/TestCases/use_poisoned_asan.cc b/compiler-rt/test/lsan/TestCases/use_poisoned_asan.cc
index 164b0cf67bc..780792e957c 100644
--- a/compiler-rt/test/lsan/TestCases/use_poisoned_asan.cc
+++ b/compiler-rt/test/lsan/TestCases/use_poisoned_asan.cc
@@ -1,6 +1,6 @@
// ASan-poisoned memory should be ignored if use_poisoned is false.
// REQUIRES: asan
-// RUN: LSAN_BASE="detect_leaks=1:report_objects=1:use_stacks=0:use_registers=0"
+// RUN: LSAN_BASE="report_objects=1:use_stacks=0:use_registers=0"
// RUN: %clangxx_lsan %s -o %t
// RUN: %env_lsan_opts=$LSAN_BASE:"use_poisoned=0" not %run %t 2>&1 | FileCheck %s
// RUN: %env_lsan_opts=$LSAN_BASE:"use_poisoned=1" %run %t 2>&1
diff --git a/compiler-rt/test/lsan/TestCases/use_registers.cc b/compiler-rt/test/lsan/TestCases/use_registers.cc
index fe552e62868..5d5ede5cec8 100644
--- a/compiler-rt/test/lsan/TestCases/use_registers.cc
+++ b/compiler-rt/test/lsan/TestCases/use_registers.cc
@@ -1,5 +1,5 @@
// Test that registers of running threads are included in the root set.
-// RUN: LSAN_BASE="detect_leaks=1:report_objects=1:use_stacks=0"
+// RUN: LSAN_BASE="report_objects=1:use_stacks=0"
// RUN: %clangxx_lsan -pthread %s -o %t
// RUN: %env_lsan_opts=$LSAN_BASE:"use_registers=0" not %run %t 2>&1 | FileCheck %s
// RUN: %env_lsan_opts=$LSAN_BASE:"use_registers=1" %run %t 2>&1
diff --git a/compiler-rt/test/lsan/TestCases/use_stacks.cc b/compiler-rt/test/lsan/TestCases/use_stacks.cc
index 656a78a7945..855a8e4ed2b 100644
--- a/compiler-rt/test/lsan/TestCases/use_stacks.cc
+++ b/compiler-rt/test/lsan/TestCases/use_stacks.cc
@@ -1,5 +1,5 @@
// Test that stack of main thread is included in the root set.
-// RUN: LSAN_BASE="detect_leaks=1:report_objects=1:use_registers=0"
+// RUN: LSAN_BASE="report_objects=1:use_registers=0"
// RUN: %clangxx_lsan %s -o %t
// RUN: %env_lsan_opts=$LSAN_BASE:"use_stacks=0" not %run %t 2>&1 | FileCheck %s
// RUN: %env_lsan_opts=$LSAN_BASE:"use_stacks=1" %run %t 2>&1
diff --git a/compiler-rt/test/lsan/TestCases/use_stacks_threaded.cc b/compiler-rt/test/lsan/TestCases/use_stacks_threaded.cc
index c0549b22eb2..579dcffb235 100644
--- a/compiler-rt/test/lsan/TestCases/use_stacks_threaded.cc
+++ b/compiler-rt/test/lsan/TestCases/use_stacks_threaded.cc
@@ -1,5 +1,5 @@
// Test that stacks of non-main threads are included in the root set.
-// RUN: LSAN_BASE="detect_leaks=1:report_objects=1:use_registers=0"
+// RUN: LSAN_BASE="report_objects=1:use_registers=0"
// RUN: %clangxx_lsan -pthread %s -o %t
// RUN: %env_lsan_opts=$LSAN_BASE:"use_stacks=0" not %run %t 2>&1 | FileCheck %s
// RUN: %env_lsan_opts=$LSAN_BASE:"use_stacks=1" %run %t 2>&1
diff --git a/compiler-rt/test/lsan/TestCases/use_unaligned.cc b/compiler-rt/test/lsan/TestCases/use_unaligned.cc
index 1d680a51bb1..26afc2d8aaf 100644
--- a/compiler-rt/test/lsan/TestCases/use_unaligned.cc
+++ b/compiler-rt/test/lsan/TestCases/use_unaligned.cc
@@ -1,5 +1,5 @@
// Test that unaligned pointers are detected correctly.
-// RUN: LSAN_BASE="detect_leaks=1:report_objects=1:use_stacks=0:use_registers=0"
+// RUN: LSAN_BASE="report_objects=1:use_stacks=0:use_registers=0"
// RUN: %clangxx_lsan %s -o %t
// RUN: %env_lsan_opts=$LSAN_BASE:"use_unaligned=0" not %run %t 2>&1 | FileCheck %s
// RUN: %env_lsan_opts=$LSAN_BASE:"use_unaligned=1" %run %t 2>&1
diff --git a/compiler-rt/test/lsan/lit.common.cfg b/compiler-rt/test/lsan/lit.common.cfg
index 43ed02a4bfc..7020bd8473e 100644
--- a/compiler-rt/test/lsan/lit.common.cfg
+++ b/compiler-rt/test/lsan/lit.common.cfg
@@ -33,12 +33,12 @@ else:
config.name += config.name_suffix
# Platform-specific default LSAN_OPTIONS for lit tests.
-default_lsan_opts = ''
+default_lsan_opts = 'detect_leaks=1'
if config.host_os == 'Darwin':
# On Darwin, we default to `abort_on_error=1`, which would make tests run
# much slower. Let's override this and run lit tests with 'abort_on_error=0'.
# Also, make sure we do not overwhelm the syslog while testing.
- default_lsan_opts = 'abort_on_error=0'
+ default_lsan_opts += ':abort_on_error=0'
default_lsan_opts += ':log_to_syslog=0'
if default_lsan_opts:
OpenPOWER on IntegriCloud