diff --git a/clang/test/Driver/crash-diagnostics-dir-3.c b/clang/test/Driver/crash-diagnostics-dir-3.c --- a/clang/test/Driver/crash-diagnostics-dir-3.c +++ b/clang/test/Driver/crash-diagnostics-dir-3.c @@ -1,3 +1,4 @@ +// RUN: export LSAN_OPTIONS=detect_leaks=0 // RUN: rm -rf %t // RUN: not env CLANG_CRASH_DIAGNOSTICS_DIR=%t %clang -c %s -o - 2>&1 | FileCheck %s #pragma clang __debug parser_crash diff --git a/clang/test/Driver/crash-diagnostics-dir.c b/clang/test/Driver/crash-diagnostics-dir.c --- a/clang/test/Driver/crash-diagnostics-dir.c +++ b/clang/test/Driver/crash-diagnostics-dir.c @@ -1,3 +1,4 @@ +// RUN: export LSAN_OPTIONS=detect_leaks=0 // RUN: rm -rf %t // RUN: not %clang -fcrash-diagnostics-dir=%t -c %s -o - 2>&1 | FileCheck %s #pragma clang __debug parser_crash diff --git a/clang/test/Driver/crash-report-clang-cl.cpp b/clang/test/Driver/crash-report-clang-cl.cpp --- a/clang/test/Driver/crash-report-clang-cl.cpp +++ b/clang/test/Driver/crash-report-clang-cl.cpp @@ -1,3 +1,4 @@ +// RUN: export LSAN_OPTIONS=detect_leaks=0 // RUN: rm -rf %t // RUN: mkdir %t diff --git a/clang/test/Driver/crash-report-header.h b/clang/test/Driver/crash-report-header.h --- a/clang/test/Driver/crash-report-header.h +++ b/clang/test/Driver/crash-report-header.h @@ -1,3 +1,4 @@ +// RUN: export LSAN_OPTIONS=detect_leaks=0 // RUN: rm -rf %t // RUN: mkdir %t // RUN: env TMPDIR="%t" TEMP="%t" TMP="%t" RC_DEBUG_OPTIONS=1 not %clang -fsyntax-only %s 2>&1 | FileCheck %s diff --git a/clang/test/Driver/crash-report-spaces.c b/clang/test/Driver/crash-report-spaces.c --- a/clang/test/Driver/crash-report-spaces.c +++ b/clang/test/Driver/crash-report-spaces.c @@ -1,3 +1,4 @@ +// RUN: export LSAN_OPTIONS=detect_leaks=0 // RUN: rm -rf "%t" // RUN: mkdir "%t" // RUN: cp "%s" "%t/crash report spaces.c" diff --git a/clang/test/Driver/crash-report-with-asserts.c b/clang/test/Driver/crash-report-with-asserts.c --- a/clang/test/Driver/crash-report-with-asserts.c +++ b/clang/test/Driver/crash-report-with-asserts.c @@ -1,3 +1,4 @@ +// RUN: export LSAN_OPTIONS=detect_leaks=0 // RUN: rm -rf %t // RUN: mkdir %t diff --git a/clang/test/Driver/crash-report.cpp b/clang/test/Driver/crash-report.cpp --- a/clang/test/Driver/crash-report.cpp +++ b/clang/test/Driver/crash-report.cpp @@ -1,3 +1,4 @@ +// RUN: export LSAN_OPTIONS=detect_leaks=0 // RUN: rm -rf %t // RUN: mkdir %t diff --git a/clang/test/Driver/emit-reproducer.c b/clang/test/Driver/emit-reproducer.c --- a/clang/test/Driver/emit-reproducer.c +++ b/clang/test/Driver/emit-reproducer.c @@ -1,3 +1,4 @@ +// RUN: export LSAN_OPTIONS=detect_leaks=0 // RUN: rm -rf %t && mkdir %t // RUN: echo "%s -fcrash-diagnostics-dir=%t -fsyntax-only" | sed -e 's/\\/\\\\/g' > %t.rsp diff --git a/clang/test/Driver/output-file-cleanup.c b/clang/test/Driver/output-file-cleanup.c --- a/clang/test/Driver/output-file-cleanup.c +++ b/clang/test/Driver/output-file-cleanup.c @@ -1,3 +1,4 @@ +// RUN: export LSAN_OPTIONS=detect_leaks=0 // RUN: rm -f "%t.d" "%t1.s" "%t2.s" "%t3.s" "%t4.s" "%t5.s" // // RUN: touch %t.s diff --git a/clang/test/Driver/rewrite-map-in-diagnostics.c b/clang/test/Driver/rewrite-map-in-diagnostics.c --- a/clang/test/Driver/rewrite-map-in-diagnostics.c +++ b/clang/test/Driver/rewrite-map-in-diagnostics.c @@ -1,3 +1,4 @@ +// RUN: export LSAN_OPTIONS=detect_leaks=0 // RUN: rm -rf "%t" // RUN: mkdir -p "%t" // RUN: env TMPDIR="%t" TEMP="%t" TMP="%t" RC_DEBUG_OPTION=1 \ diff --git a/clang/test/Index/crash-recovery-code-complete.c b/clang/test/Index/crash-recovery-code-complete.c --- a/clang/test/Index/crash-recovery-code-complete.c +++ b/clang/test/Index/crash-recovery-code-complete.c @@ -1,3 +1,4 @@ +// RUN: export LSAN_OPTIONS=detect_leaks=0 // RUN: env CINDEXTEST_EDITING=1 CINDEXTEST_PREAMBLE_FILE=%t-preamble.pch \ // RUN: not c-index-test -code-completion-at=%s:20:1 \ // RUN: "-remap-file=%s,%S/Inputs/crash-recovery-code-complete-remap.c" \ diff --git a/clang/test/Index/crash-recovery-modules.m b/clang/test/Index/crash-recovery-modules.m --- a/clang/test/Index/crash-recovery-modules.m +++ b/clang/test/Index/crash-recovery-modules.m @@ -12,6 +12,7 @@ // REQUIRES: crash-recovery // UNSUPPORTED: libstdcxx-safe-mode +// UNSUPPORTED: hwasan @import Crash; diff --git a/clang/test/Index/crash-recovery-reparse.c b/clang/test/Index/crash-recovery-reparse.c --- a/clang/test/Index/crash-recovery-reparse.c +++ b/clang/test/Index/crash-recovery-reparse.c @@ -1,3 +1,4 @@ +// RUN: export LSAN_OPTIONS=detect_leaks=0 // RUN: env CINDEXTEST_EDITING=1 CINDEXTEST_PREAMBLE_FILE=%t-preamble.pch \ // RUN: not c-index-test -test-load-source-reparse 1 local \ // RUN: -remap-file="%s,%S/Inputs/crash-recovery-reparse-remap.c" \ diff --git a/clang/test/Index/crash-recovery.c b/clang/test/Index/crash-recovery.c --- a/clang/test/Index/crash-recovery.c +++ b/clang/test/Index/crash-recovery.c @@ -1,3 +1,4 @@ +// RUN: export LSAN_OPTIONS=detect_leaks=0 // RUN: not c-index-test -test-load-source all %s 2> %t.err // RUN: FileCheck < %t.err -check-prefix=CHECK-LOAD-SOURCE-CRASH %s // CHECK-LOAD-SOURCE-CRASH: Unable to load translation unit diff --git a/clang/test/Index/create-libclang-completion-reproducer.c b/clang/test/Index/create-libclang-completion-reproducer.c --- a/clang/test/Index/create-libclang-completion-reproducer.c +++ b/clang/test/Index/create-libclang-completion-reproducer.c @@ -1,3 +1,4 @@ +// RUN: export LSAN_OPTIONS=detect_leaks=0 // RUN: rm -rf %t // RUN: mkdir %t // RUN: env CINDEXTEST_INVOCATION_EMISSION_PATH=%t not c-index-test -code-completion-at=%s:10:1 "-remap-file=%s,%S/Inputs/record-parsing-invocation-remap.c" %s diff --git a/clang/test/Index/create-libclang-parsing-reproducer.c b/clang/test/Index/create-libclang-parsing-reproducer.c --- a/clang/test/Index/create-libclang-parsing-reproducer.c +++ b/clang/test/Index/create-libclang-parsing-reproducer.c @@ -1,3 +1,4 @@ +// RUN: export LSAN_OPTIONS=detect_leaks=0 // RUN: rm -rf %t // RUN: mkdir %t // RUN: env CINDEXTEST_INVOCATION_EMISSION_PATH=%t not c-index-test -test-load-source all %s diff --git a/clang/test/Index/error-on-deserialized.c b/clang/test/Index/error-on-deserialized.c --- a/clang/test/Index/error-on-deserialized.c +++ b/clang/test/Index/error-on-deserialized.c @@ -3,6 +3,7 @@ // This tests that we will correctly error out on the deserialized decl. +// RUN: export LSAN_OPTIONS=detect_leaks=0 // RUN: c-index-test -write-pch %t.h.pch %S/targeted-top.h // RUN: env CINDEXTEST_FAILONERROR=1 not c-index-test -cursor-at=%S/targeted-nested1.h:2:16 %s -include %t.h \ // RUN: -Xclang -error-on-deserialized-decl=NestedVar1 diff --git a/clang/test/Index/record-completion-invocation.c b/clang/test/Index/record-completion-invocation.c --- a/clang/test/Index/record-completion-invocation.c +++ b/clang/test/Index/record-completion-invocation.c @@ -1,3 +1,4 @@ +// RUN: export LSAN_OPTIONS=detect_leaks=0 // RUN: rm -rf %t // RUN: mkdir %t // RUN: env CINDEXTEST_INVOCATION_EMISSION_PATH=%t not c-index-test -code-completion-at=%s:10:1 "-remap-file=%s,%S/Inputs/record-parsing-invocation-remap.c" %s diff --git a/clang/test/Index/record-parsing-invocation.c b/clang/test/Index/record-parsing-invocation.c --- a/clang/test/Index/record-parsing-invocation.c +++ b/clang/test/Index/record-parsing-invocation.c @@ -1,3 +1,4 @@ +// RUN: export LSAN_OPTIONS=detect_leaks=0 // RUN: rm -rf %t // RUN: mkdir %t // RUN: env CINDEXTEST_INVOCATION_EMISSION_PATH=%t not c-index-test -test-load-source all %s diff --git a/llvm/test/Bitcode/invalid.test b/llvm/test/Bitcode/invalid.test --- a/llvm/test/Bitcode/invalid.test +++ b/llvm/test/Bitcode/invalid.test @@ -1,3 +1,4 @@ +RUN: export LSAN_OPTIONS=detect_leaks=0 RUN: not llvm-dis -disable-output %p/Inputs/invalid-empty.bc 2>&1 | \ RUN: FileCheck --check-prefix=INVALID-EMPTY %s RUN: not llvm-dis -disable-output %p/Inputs/invalid-pr20485.bc 2>&1 | \ diff --git a/llvm/test/MC/AsmParser/unmatched-if-macro.s b/llvm/test/MC/AsmParser/unmatched-if-macro.s --- a/llvm/test/MC/AsmParser/unmatched-if-macro.s +++ b/llvm/test/MC/AsmParser/unmatched-if-macro.s @@ -1,3 +1,4 @@ +# RUN: export LSAN_OPTIONS=detect_leaks=0 # RUN: not llvm-mc -triple x86_64 %s -o /dev/null 2>&1 | FileCheck %s ## This also tests that we don't assert due to an active macro instantiation. diff --git a/llvm/test/tools/llvm-mc/disassembler-options.test b/llvm/test/tools/llvm-mc/disassembler-options.test --- a/llvm/test/tools/llvm-mc/disassembler-options.test +++ b/llvm/test/tools/llvm-mc/disassembler-options.test @@ -1,3 +1,4 @@ +# RUN: export LSAN_OPTIONS=detect_leaks=0 # RUN: not llvm-mc -M invalid /dev/null 2>&1 | FileCheck %s # CHECK: error: invalid disassembler option 'invalid' diff --git a/llvm/test/tools/llvm-profdata/merge-incompatible.test b/llvm/test/tools/llvm-profdata/merge-incompatible.test --- a/llvm/test/tools/llvm-profdata/merge-incompatible.test +++ b/llvm/test/tools/llvm-profdata/merge-incompatible.test @@ -1,3 +1,4 @@ +RUN: export LSAN_OPTIONS=detect_leaks=0 RUN: not llvm-profdata merge %p/Inputs/fe-basic.proftext %p/Inputs/ir-basic.proftext -o /dev/null 2>&1 | FileCheck %s CHECK: ir-basic.proftext: Merge IR generated profile with Clang generated profile. diff --git a/llvm/test/tools/llvm-reduce/fail-execute-test.test b/llvm/test/tools/llvm-reduce/fail-execute-test.test --- a/llvm/test/tools/llvm-reduce/fail-execute-test.test +++ b/llvm/test/tools/llvm-reduce/fail-execute-test.test @@ -1,3 +1,4 @@ +# RUN: export LSAN_OPTIONS=detect_leaks=0 # RUN: not llvm-reduce --test=%s.NotAFileInTestingDir %p/Inputs/test-output-format.ll 2>&1 | FileCheck -DFILENAME=%s.NotAFileInTestingDir --strict-whitespace %s -# CHECK: Error running interesting-ness test: {{(Executable "[[FILENAME]]" doesn't exist$)?(program not executable$)?}} \ No newline at end of file +# CHECK: Error running interesting-ness test: {{(Executable "[[FILENAME]]" doesn't exist$)?(program not executable$)?}}