summaryrefslogtreecommitdiff
path: root/compiler-rt
diff options
context:
space:
mode:
authorAlvin Wong <alvin@alvinhc.com>2023-04-02 19:45:57 +0800
committerAlvin Wong <alvin@alvinhc.com>2023-05-16 19:53:49 +0800
commit5ad8bbee238f9655c55f048b6ae8c9b40b4c87e5 (patch)
tree80c9825a27e93a976d810bf47a5e03bf014d0243 /compiler-rt
parent3237f568403b80a6df47dd88dcfb03cb3a99b633 (diff)
downloadllvm-5ad8bbee238f9655c55f048b6ae8c9b40b4c87e5.tar.gz
[asan][test][win] Port more tests to not use clang-cl on MinGW (2)
Continuation of D147432 and D147444. Differential Revision: https://reviews.llvm.org/D150267
Diffstat (limited to 'compiler-rt')
-rw-r--r--compiler-rt/test/asan/TestCases/Windows/delay_dbghelp.cpp4
-rw-r--r--compiler-rt/test/asan/TestCases/Windows/dll_aligned_mallocs.cpp11
-rw-r--r--compiler-rt/test/asan/TestCases/Windows/dll_allocators_sanity.cpp6
-rw-r--r--compiler-rt/test/asan/TestCases/Windows/dll_intercept_memchr.cpp6
-rw-r--r--compiler-rt/test/asan/TestCases/Windows/dll_intercept_memcpy_indirect.cpp6
-rw-r--r--compiler-rt/test/asan/TestCases/Windows/dll_intercept_strlen.cpp6
-rw-r--r--compiler-rt/test/asan/TestCases/Windows/dll_malloc_left_oob.cpp6
-rw-r--r--compiler-rt/test/asan/TestCases/Windows/dll_malloc_uaf.cpp6
-rw-r--r--compiler-rt/test/asan/TestCases/Windows/dll_noreturn.cpp6
-rw-r--r--compiler-rt/test/asan/TestCases/Windows/dll_null_deref.cpp6
-rw-r--r--compiler-rt/test/asan/TestCases/Windows/dll_operator_array_new_left_oob.cpp6
-rw-r--r--compiler-rt/test/asan/TestCases/Windows/dll_operator_array_new_with_dtor_left_oob.cpp6
-rw-r--r--compiler-rt/test/asan/TestCases/Windows/dll_poison_unpoison.cpp12
-rw-r--r--compiler-rt/test/asan/TestCases/Windows/dll_stack_use_after_return.cpp8
-rw-r--r--compiler-rt/test/asan/TestCases/Windows/dll_thread_stack_array_left_oob.cpp6
-rw-r--r--compiler-rt/test/asan/TestCases/Windows/dll_unload.cpp6
-rw-r--r--compiler-rt/test/asan/TestCases/Windows/heapalloc.cpp4
-rw-r--r--compiler-rt/test/asan/TestCases/Windows/heapalloc_dll_double_free.cpp6
-rw-r--r--compiler-rt/test/asan/TestCases/Windows/heapalloc_dll_unload_realloc_uaf.cpp6
-rw-r--r--compiler-rt/test/asan/TestCases/Windows/heapalloc_doublefree.cpp4
-rw-r--r--compiler-rt/test/asan/TestCases/Windows/heapalloc_flags_fallback.cpp4
-rw-r--r--compiler-rt/test/asan/TestCases/Windows/heapalloc_huge.cpp4
-rw-r--r--compiler-rt/test/asan/TestCases/Windows/heapalloc_rtl_transfer.cpp4
-rw-r--r--compiler-rt/test/asan/TestCases/Windows/heapalloc_transfer.cpp4
-rw-r--r--compiler-rt/test/asan/TestCases/Windows/heapalloc_uaf.cpp4
-rw-r--r--compiler-rt/test/asan/TestCases/Windows/heapalloc_zero_size.cpp6
-rw-r--r--compiler-rt/test/asan/TestCases/Windows/heaprealloc.cpp4
-rw-r--r--compiler-rt/test/asan/TestCases/Windows/heaprealloc_alloc_zero.cpp6
-rw-r--r--compiler-rt/test/asan/TestCases/Windows/heaprealloc_zero_size.cpp8
-rw-r--r--compiler-rt/test/asan/TestCases/Windows/recalloc_sanity.cpp4
-rw-r--r--compiler-rt/test/asan/TestCases/Windows/report_globals_reload_dll.cpp6
-rw-r--r--compiler-rt/test/asan/TestCases/Windows/report_globals_vs_freelibrary.cpp6
-rw-r--r--compiler-rt/test/asan/TestCases/Windows/rtlallocateheap.cpp4
-rw-r--r--compiler-rt/test/asan/TestCases/Windows/rtlallocateheap_dll_unload_double_free.cpp6
-rw-r--r--compiler-rt/test/asan/TestCases/Windows/rtlallocateheap_dll_unload_realloc.cpp6
-rw-r--r--compiler-rt/test/asan/TestCases/Windows/rtlallocateheap_flags_fallback.cpp4
-rw-r--r--compiler-rt/test/asan/TestCases/Windows/rtlallocateheap_zero.cpp4
-rw-r--r--compiler-rt/test/asan/TestCases/Windows/sanitizer_purge.cpp6
-rw-r--r--compiler-rt/test/asan/TestCases/Windows/stack_use_after_return.cpp7
-rw-r--r--compiler-rt/test/asan/TestCases/Windows/symbols_path.cpp4
-rw-r--r--compiler-rt/test/asan/TestCases/Windows/user-exception.cpp4
-rw-r--r--compiler-rt/test/asan/lit.cfg.py6
42 files changed, 84 insertions, 154 deletions
diff --git a/compiler-rt/test/asan/TestCases/Windows/delay_dbghelp.cpp b/compiler-rt/test/asan/TestCases/Windows/delay_dbghelp.cpp
index 0cad545d0f31..9277fe0b2351 100644
--- a/compiler-rt/test/asan/TestCases/Windows/delay_dbghelp.cpp
+++ b/compiler-rt/test/asan/TestCases/Windows/delay_dbghelp.cpp
@@ -1,7 +1,5 @@
-// UNSUPPORTED: target={{.*-windows-gnu}}
-
// Build an executable with ASan, then extract the DLLs that it depends on.
-// RUN: %clang_cl_asan %s -Fe%t.exe
+// RUN: %clang_cl_asan %s %Fe%t.exe
// RUN: llvm-readobj --coff-imports %t.exe | grep Name: | sed -e 's/ *Name: *//' > %t
//
// Make sure the binary doesn't depend on dbghelp directly.
diff --git a/compiler-rt/test/asan/TestCases/Windows/dll_aligned_mallocs.cpp b/compiler-rt/test/asan/TestCases/Windows/dll_aligned_mallocs.cpp
index c180950a2b13..f545fe49fc50 100644
--- a/compiler-rt/test/asan/TestCases/Windows/dll_aligned_mallocs.cpp
+++ b/compiler-rt/test/asan/TestCases/Windows/dll_aligned_mallocs.cpp
@@ -1,12 +1,15 @@
-// UNSUPPORTED: target={{.*-windows-gnu}}
-
-// RUN: %clang_cl_asan -Od %p/dll_host.cpp -Fe%t
-// RUN: %clang_cl_asan -LD -Od %s -Fe%t.dll
+// RUN: %clang_cl_asan %Od %p/dll_host.cpp %Fe%t
+// RUN: %clang_cl_asan %LD %Od %s %Fe%t.dll
// RUN: %run %t %t.dll | FileCheck %s
#include <malloc.h>
#include <stdio.h>
+#ifdef __MINGW32__
+// FIXME: remove after mingw-w64 adds this declaration.
+extern "C" size_t __cdecl _aligned_msize(void *_Memory, size_t _Alignment, size_t _Offset);
+#endif
+
#define CHECK_ALIGNED(ptr,alignment) \
do { \
if (((uintptr_t)(ptr) % (alignment)) != 0) \
diff --git a/compiler-rt/test/asan/TestCases/Windows/dll_allocators_sanity.cpp b/compiler-rt/test/asan/TestCases/Windows/dll_allocators_sanity.cpp
index 8e4e71bfce12..17085587ffdd 100644
--- a/compiler-rt/test/asan/TestCases/Windows/dll_allocators_sanity.cpp
+++ b/compiler-rt/test/asan/TestCases/Windows/dll_allocators_sanity.cpp
@@ -1,7 +1,5 @@
-// UNSUPPORTED: target={{.*-windows-gnu}}
-
-// RUN: %clang_cl_asan -Od %p/dll_host.cpp -Fe%t
-// RUN: %clang_cl_asan -LD -Od %s -Fe%t.dll
+// RUN: %clang_cl_asan %Od %p/dll_host.cpp %Fe%t
+// RUN: %clang_cl_asan %LD %Od %s %Fe%t.dll
// RUN: %run %t %t.dll | FileCheck %s
#include <malloc.h>
diff --git a/compiler-rt/test/asan/TestCases/Windows/dll_intercept_memchr.cpp b/compiler-rt/test/asan/TestCases/Windows/dll_intercept_memchr.cpp
index 3db8943db830..c41d937d3240 100644
--- a/compiler-rt/test/asan/TestCases/Windows/dll_intercept_memchr.cpp
+++ b/compiler-rt/test/asan/TestCases/Windows/dll_intercept_memchr.cpp
@@ -1,7 +1,5 @@
-// UNSUPPORTED: target={{.*-windows-gnu}}
-
-// RUN: %clang_cl_asan -Od %p/dll_host.cpp -Fe%t
-// RUN: %clang_cl_asan -LD -Od %s -Fe%t.dll
+// RUN: %clang_cl_asan %Od %p/dll_host.cpp %Fe%t
+// RUN: %clang_cl_asan %LD %Od %s %Fe%t.dll
// RUN: not %run %t %t.dll 2>&1 | FileCheck %s
// On windows 64-bit, the memchr function is written in assembly and is not
diff --git a/compiler-rt/test/asan/TestCases/Windows/dll_intercept_memcpy_indirect.cpp b/compiler-rt/test/asan/TestCases/Windows/dll_intercept_memcpy_indirect.cpp
index 849c660b5113..f79e4d6dbcef 100644
--- a/compiler-rt/test/asan/TestCases/Windows/dll_intercept_memcpy_indirect.cpp
+++ b/compiler-rt/test/asan/TestCases/Windows/dll_intercept_memcpy_indirect.cpp
@@ -1,7 +1,5 @@
-// UNSUPPORTED: target={{.*-windows-gnu}}
-
-// RUN: %clang_cl_asan -Od %p/dll_host.cpp -Fe%t
-// RUN: %clang_cl_asan -LD -Od %s -Fe%t.dll
+// RUN: %clang_cl_asan %Od %p/dll_host.cpp %Fe%t
+// RUN: %clang_cl_asan %LD %Od %s %Fe%t.dll
// RUN: not %run %t %t.dll 2>&1 | FileCheck %s
#include <stdio.h>
diff --git a/compiler-rt/test/asan/TestCases/Windows/dll_intercept_strlen.cpp b/compiler-rt/test/asan/TestCases/Windows/dll_intercept_strlen.cpp
index 1bad2f818fbd..94cb6aa24a7d 100644
--- a/compiler-rt/test/asan/TestCases/Windows/dll_intercept_strlen.cpp
+++ b/compiler-rt/test/asan/TestCases/Windows/dll_intercept_strlen.cpp
@@ -1,7 +1,5 @@
-// UNSUPPORTED: target={{.*-windows-gnu}}
-
-// RUN: %clang_cl_asan -Od %p/dll_host.cpp -Fe%t
-// RUN: %clang_cl_asan -LD -Od %s -Fe%t.dll
+// RUN: %clang_cl_asan %Od %p/dll_host.cpp %Fe%t
+// RUN: %clang_cl_asan %LD %Od %s %Fe%t.dll
// RUN: not %run %t %t.dll 2>&1 | FileCheck %s
#include <stdio.h>
diff --git a/compiler-rt/test/asan/TestCases/Windows/dll_malloc_left_oob.cpp b/compiler-rt/test/asan/TestCases/Windows/dll_malloc_left_oob.cpp
index f2216cee51d2..6d550eb966cd 100644
--- a/compiler-rt/test/asan/TestCases/Windows/dll_malloc_left_oob.cpp
+++ b/compiler-rt/test/asan/TestCases/Windows/dll_malloc_left_oob.cpp
@@ -1,7 +1,5 @@
-// UNSUPPORTED: target={{.*-windows-gnu}}
-
-// RUN: %clang_cl_asan -Od %p/dll_host.cpp -Fe%t
-// RUN: %clang_cl_asan -LD -Od %s -Fe%t.dll
+// RUN: %clang_cl_asan %Od %p/dll_host.cpp %Fe%t
+// RUN: %clang_cl_asan %LD %Od %s %Fe%t.dll
// RUN: not %run %t %t.dll 2>&1 | FileCheck %s
#include <malloc.h>
diff --git a/compiler-rt/test/asan/TestCases/Windows/dll_malloc_uaf.cpp b/compiler-rt/test/asan/TestCases/Windows/dll_malloc_uaf.cpp
index bbf6f3804b0d..bc701e92961c 100644
--- a/compiler-rt/test/asan/TestCases/Windows/dll_malloc_uaf.cpp
+++ b/compiler-rt/test/asan/TestCases/Windows/dll_malloc_uaf.cpp
@@ -1,7 +1,5 @@
-// UNSUPPORTED: target={{.*-windows-gnu}}
-
-// RUN: %clang_cl_asan -Od %p/dll_host.cpp -Fe%t
-// RUN: %clang_cl_asan -LD -Od %s -Fe%t.dll
+// RUN: %clang_cl_asan %Od %p/dll_host.cpp %Fe%t
+// RUN: %clang_cl_asan %LD %Od %s %Fe%t.dll
// RUN: not %run %t %t.dll 2>&1 | FileCheck %s
#include <malloc.h>
diff --git a/compiler-rt/test/asan/TestCases/Windows/dll_noreturn.cpp b/compiler-rt/test/asan/TestCases/Windows/dll_noreturn.cpp
index d50257555851..ba67f2319d49 100644
--- a/compiler-rt/test/asan/TestCases/Windows/dll_noreturn.cpp
+++ b/compiler-rt/test/asan/TestCases/Windows/dll_noreturn.cpp
@@ -1,7 +1,5 @@
-// UNSUPPORTED: target={{.*-windows-gnu}}
-
-// RUN: %clang_cl_asan -Od %p/dll_host.cpp -Fe%t
-// RUN: %clang_cl_asan -LD -Od %s -Fe%t.dll
+// RUN: %clang_cl_asan %Od %p/dll_host.cpp %Fe%t
+// RUN: %clang_cl_asan %LD %Od %s %Fe%t.dll
// RUN: not %run %t %t.dll 2>&1 | FileCheck %s
#include <process.h>
diff --git a/compiler-rt/test/asan/TestCases/Windows/dll_null_deref.cpp b/compiler-rt/test/asan/TestCases/Windows/dll_null_deref.cpp
index a3242c970197..b65926941cd7 100644
--- a/compiler-rt/test/asan/TestCases/Windows/dll_null_deref.cpp
+++ b/compiler-rt/test/asan/TestCases/Windows/dll_null_deref.cpp
@@ -1,7 +1,5 @@
-// UNSUPPORTED: target={{.*-windows-gnu}}
-
-// RUN: %clang_cl_asan -Od %p/dll_host.cpp -Fe%t
-// RUN: %clang_cl_asan -LD -Od %s -Fe%t.dll
+// RUN: %clang_cl_asan %Od %p/dll_host.cpp %Fe%t
+// RUN: %clang_cl_asan %LD %Od %s %Fe%t.dll
// RUN: not %run %t %t.dll 2>&1 | FileCheck %s
__attribute__((noinline))
diff --git a/compiler-rt/test/asan/TestCases/Windows/dll_operator_array_new_left_oob.cpp b/compiler-rt/test/asan/TestCases/Windows/dll_operator_array_new_left_oob.cpp
index 34c29b04c159..20ce08356300 100644
--- a/compiler-rt/test/asan/TestCases/Windows/dll_operator_array_new_left_oob.cpp
+++ b/compiler-rt/test/asan/TestCases/Windows/dll_operator_array_new_left_oob.cpp
@@ -1,7 +1,5 @@
-// UNSUPPORTED: target={{.*-windows-gnu}}
-
-// RUN: %clang_cl_asan -Od %p/dll_host.cpp -Fe%t
-// RUN: %clang_cl_asan -LD -Od %s -Fe%t.dll
+// RUN: %clang_cl_asan %Od %p/dll_host.cpp %Fe%t
+// RUN: %clang_cl_asan %LD %Od %s %Fe%t.dll
// RUN: not %run %t %t.dll 2>&1 | FileCheck %s
extern "C" __declspec(dllexport)
diff --git a/compiler-rt/test/asan/TestCases/Windows/dll_operator_array_new_with_dtor_left_oob.cpp b/compiler-rt/test/asan/TestCases/Windows/dll_operator_array_new_with_dtor_left_oob.cpp
index bdf3fe330cb5..ca6b256654a2 100644
--- a/compiler-rt/test/asan/TestCases/Windows/dll_operator_array_new_with_dtor_left_oob.cpp
+++ b/compiler-rt/test/asan/TestCases/Windows/dll_operator_array_new_with_dtor_left_oob.cpp
@@ -1,7 +1,5 @@
-// UNSUPPORTED: target={{.*-windows-gnu}}
-
-// RUN: %clang_cl_asan -Od %p/dll_host.cpp -Fe%t
-// RUN: %clang_cl_asan -LD -Od %s -Fe%t.dll
+// RUN: %clang_cl_asan %Od %p/dll_host.cpp %Fe%t
+// RUN: %clang_cl_asan %LD %Od %s %Fe%t.dll
// RUN: not %run %t %t.dll 2>&1 | FileCheck %s
struct C {
diff --git a/compiler-rt/test/asan/TestCases/Windows/dll_poison_unpoison.cpp b/compiler-rt/test/asan/TestCases/Windows/dll_poison_unpoison.cpp
index f20c5b16e2f3..cc01bd0c3309 100644
--- a/compiler-rt/test/asan/TestCases/Windows/dll_poison_unpoison.cpp
+++ b/compiler-rt/test/asan/TestCases/Windows/dll_poison_unpoison.cpp
@@ -1,7 +1,5 @@
-// UNSUPPORTED: target={{.*-windows-gnu}}
-
-// RUN: %clang_cl_asan -Od %p/dll_host.cpp -Fe%t
-// RUN: %clang_cl_asan -LD -Od %s -Fe%t.dll
+// RUN: %clang_cl_asan %Od %p/dll_host.cpp %Fe%t
+// RUN: %clang_cl_asan %LD %Od %s %Fe%t.dll
// RUN: not %run %t %t.dll 2>&1 | FileCheck %s
#include <sanitizer/asan_interface.h>
@@ -26,12 +24,12 @@ int test_function() {
should_crash(&buffer[96]);
// CHECK: AddressSanitizer: use-after-poison on address [[ADDR:0x[0-9a-f]+]]
// CHECK-NEXT: WRITE of size 1 at [[ADDR]] thread T0
-// CHECK-NEXT: should_crash{{.*}}\dll_poison_unpoison.cpp
-// CHECK-NEXT: test_function{{.*}}\dll_poison_unpoison.cpp:[[@LINE-4]]
+// CHECK-NEXT: should_crash{{.*[\\/]}}dll_poison_unpoison.cpp
+// CHECK-NEXT: test_function{{.*[\\/]}}dll_poison_unpoison.cpp:[[@LINE-4]]
// CHECK-NEXT: main
//
// CHECK: [[ADDR]] is located in stack of thread T0 at offset [[OFFSET:.*]] in frame
-// CHECK-NEXT: test_function{{.*}}\dll_poison_unpoison.cpp
+// CHECK-NEXT: test_function{{.*[\\/]}}dll_poison_unpoison.cpp
// CHECK: 'buffer'{{.*}} <== Memory access at offset [[OFFSET]] is inside this variable
return 0;
}
diff --git a/compiler-rt/test/asan/TestCases/Windows/dll_stack_use_after_return.cpp b/compiler-rt/test/asan/TestCases/Windows/dll_stack_use_after_return.cpp
index 6aa9721d5688..be237044bb34 100644
--- a/compiler-rt/test/asan/TestCases/Windows/dll_stack_use_after_return.cpp
+++ b/compiler-rt/test/asan/TestCases/Windows/dll_stack_use_after_return.cpp
@@ -1,9 +1,7 @@
-// UNSUPPORTED: target={{.*-windows-gnu}}
-
-// RUN: %clang_cl_asan -Od %p/dll_host.cpp -Fe%t
-// RUN: %clang_cl_asan -LD -Od %s -Fe%t.dll
+// RUN: %clang_cl_asan %Od %p/dll_host.cpp %Fe%t
+// RUN: %clang_cl_asan %LD %Od %s %Fe%t.dll
// RUN: %env_asan_opts=detect_stack_use_after_return=1 not %run %t %t.dll 2>&1 | FileCheck %s
-// RUN: %clang_cl_asan -LD -Od %s -Fe%t.dll -fsanitize-address-use-after-return=always
+// RUN: %clang_cl_asan %LD %Od %s %Fe%t.dll -fsanitize-address-use-after-return=always
// RUN: not %run %t %t.dll 2>&1 | FileCheck %s
#include <malloc.h>
diff --git a/compiler-rt/test/asan/TestCases/Windows/dll_thread_stack_array_left_oob.cpp b/compiler-rt/test/asan/TestCases/Windows/dll_thread_stack_array_left_oob.cpp
index da2a9115df76..78f651b6b917 100644
--- a/compiler-rt/test/asan/TestCases/Windows/dll_thread_stack_array_left_oob.cpp
+++ b/compiler-rt/test/asan/TestCases/Windows/dll_thread_stack_array_left_oob.cpp
@@ -1,7 +1,5 @@
-// UNSUPPORTED: target={{.*-windows-gnu}}
-
-// RUN: %clang_cl_asan -Od %p/dll_host.cpp -Fe%t
-// RUN: %clang_cl_asan -LD -Od %s -Fe%t.dll
+// RUN: %clang_cl_asan %Od %p/dll_host.cpp %Fe%t
+// RUN: %clang_cl_asan %LD %Od %s %Fe%t.dll
// RUN: not %run %t %t.dll 2>&1 | FileCheck %s
#include <windows.h>
diff --git a/compiler-rt/test/asan/TestCases/Windows/dll_unload.cpp b/compiler-rt/test/asan/TestCases/Windows/dll_unload.cpp
index 23a65446d760..46e4190210b5 100644
--- a/compiler-rt/test/asan/TestCases/Windows/dll_unload.cpp
+++ b/compiler-rt/test/asan/TestCases/Windows/dll_unload.cpp
@@ -1,10 +1,8 @@
-// UNSUPPORTED: target={{.*-windows-gnu}}
-
#include <stdio.h>
#include <windows.h>
-// RUN: %clang_cl_asan -LD /Od -DDLL %s -Fe%t.dll
-// RUN: %clang_cl /Od -DEXE %s -Fe%te.exe
+// RUN: %clang_cl_asan %LD %Od -DDLL %s %Fe%t.dll
+// RUN: %clang_cl %Od -DEXE %s %Fe%te.exe
// RUN: %env_asan_opts=windows_hook_rtl_allocators=true not %run %te.exe %t.dll 2>&1 | FileCheck %s
// REQUIRES: asan-dynamic-runtime
// REQUIRES: asan-32-bits
diff --git a/compiler-rt/test/asan/TestCases/Windows/heapalloc.cpp b/compiler-rt/test/asan/TestCases/Windows/heapalloc.cpp
index 3deaa640a903..d707df8061af 100644
--- a/compiler-rt/test/asan/TestCases/Windows/heapalloc.cpp
+++ b/compiler-rt/test/asan/TestCases/Windows/heapalloc.cpp
@@ -1,7 +1,5 @@
-// UNSUPPORTED: target={{.*-windows-gnu}}
-
// UNSUPPORTED: asan-64-bits
-// RUN: %clang_cl_asan -Od %s -Fe%t
+// RUN: %clang_cl_asan %Od %s %Fe%t
// RUN: %env_asan_opts=windows_hook_rtl_allocators=true not %run %t 2>&1 | FileCheck %s
#include <windows.h>
diff --git a/compiler-rt/test/asan/TestCases/Windows/heapalloc_dll_double_free.cpp b/compiler-rt/test/asan/TestCases/Windows/heapalloc_dll_double_free.cpp
index 8391719c3c13..14d4601469bf 100644
--- a/compiler-rt/test/asan/TestCases/Windows/heapalloc_dll_double_free.cpp
+++ b/compiler-rt/test/asan/TestCases/Windows/heapalloc_dll_double_free.cpp
@@ -1,10 +1,8 @@
-// UNSUPPORTED: target={{.*-windows-gnu}}
-
#include <stdio.h>
#include <windows.h>
-// RUN: %clang_cl_asan -LD /Od -DDLL %s -Fe%t.dll
-// RUN: %clang_cl /Od -DEXE %s -Fe%te.exe
+// RUN: %clang_cl_asan %LD %Od -DDLL %s %Fe%t.dll
+// RUN: %clang_cl %Od -DEXE %s %Fe%te.exe
// RUN: %env_asan_opts=windows_hook_rtl_allocators=true not %run %te.exe %t.dll 2>&1 | FileCheck %s
// REQUIRES: asan-dynamic-runtime
// REQUIRES: asan-32-bits
diff --git a/compiler-rt/test/asan/TestCases/Windows/heapalloc_dll_unload_realloc_uaf.cpp b/compiler-rt/test/asan/TestCases/Windows/heapalloc_dll_unload_realloc_uaf.cpp
index a34b7025e251..dc094a0fe826 100644
--- a/compiler-rt/test/asan/TestCases/Windows/heapalloc_dll_unload_realloc_uaf.cpp
+++ b/compiler-rt/test/asan/TestCases/Windows/heapalloc_dll_unload_realloc_uaf.cpp
@@ -1,10 +1,8 @@
-// UNSUPPORTED: target={{.*-windows-gnu}}
-
#include <stdio.h>
#include <windows.h>
-// RUN: %clang_cl_asan -LD /Od -DDLL %s -Fe%t.dll
-// RUN: %clang_cl /Od -DEXE %s -Fe%te.exe
+// RUN: %clang_cl_asan %LD %Od -DDLL %s %Fe%t.dll
+// RUN: %clang_cl %Od -DEXE %s %Fe%te.exe
// RUN: %env_asan_opts=windows_hook_rtl_allocators=true not %run %te.exe %t.dll 2>&1 | FileCheck %s
// REQUIRES: asan-dynamic-runtime
// REQUIRES: asan-32-bits
diff --git a/compiler-rt/test/asan/TestCases/Windows/heapalloc_doublefree.cpp b/compiler-rt/test/asan/TestCases/Windows/heapalloc_doublefree.cpp
index 7f7b51a80953..6366fd37e9da 100644
--- a/compiler-rt/test/asan/TestCases/Windows/heapalloc_doublefree.cpp
+++ b/compiler-rt/test/asan/TestCases/Windows/heapalloc_doublefree.cpp
@@ -1,6 +1,4 @@
-// UNSUPPORTED: target={{.*-windows-gnu}}
-
-// RUN: %clang_cl_asan -Od %s -Fe%t
+// RUN: %clang_cl_asan %Od %s %Fe%t
// RUN: %env_asan_opts=windows_hook_rtl_allocators=true not %run %t 2>&1 | FileCheck %s
// UNSUPPORTED: asan-64-bits
#include <cassert>
diff --git a/compiler-rt/test/asan/TestCases/Windows/heapalloc_flags_fallback.cpp b/compiler-rt/test/asan/TestCases/Windows/heapalloc_flags_fallback.cpp
index d126c753132c..64b6ecf373ed 100644
--- a/compiler-rt/test/asan/TestCases/Windows/heapalloc_flags_fallback.cpp
+++ b/compiler-rt/test/asan/TestCases/Windows/heapalloc_flags_fallback.cpp
@@ -1,6 +1,4 @@
-// UNSUPPORTED: target={{.*-windows-gnu}}
-
-// RUN: %clang_cl_asan -Od %s -Fe%t
+// RUN: %clang_cl_asan %Od %s %Fe%t
// RUN: %run %t 2>&1 | FileCheck %s
// RUN: %env_asan_opts=windows_hook_rtl_allocators=true %run %t 2>&1 | FileCheck %s
// UNSUPPORTED: asan-64-bits
diff --git a/compiler-rt/test/asan/TestCases/Windows/heapalloc_huge.cpp b/compiler-rt/test/asan/TestCases/Windows/heapalloc_huge.cpp
index 8514be34bf29..564bebe49b25 100644
--- a/compiler-rt/test/asan/TestCases/Windows/heapalloc_huge.cpp
+++ b/compiler-rt/test/asan/TestCases/Windows/heapalloc_huge.cpp
@@ -1,6 +1,4 @@
-// UNSUPPORTED: target={{.*-windows-gnu}}
-
-// RUN: %clang_cl_asan -Od %s -Fe%t
+// RUN: %clang_cl_asan %Od %s %Fe%t
// RUN: %env_asan_opts=allocator_may_return_null=true %run %t
// RUN: %env_asan_opts=allocator_may_return_null=true:windows_hook_rtl_allocators=true %run %t
// UNSUPPORTED: asan-64-bits
diff --git a/compiler-rt/test/asan/TestCases/Windows/heapalloc_rtl_transfer.cpp b/compiler-rt/test/asan/TestCases/Windows/heapalloc_rtl_transfer.cpp
index c65ece71e23d..dc32b18ac289 100644
--- a/compiler-rt/test/asan/TestCases/Windows/heapalloc_rtl_transfer.cpp
+++ b/compiler-rt/test/asan/TestCases/Windows/heapalloc_rtl_transfer.cpp
@@ -1,5 +1,3 @@
-// UNSUPPORTED: target={{.*-windows-gnu}}
-
#include "sanitizer\allocator_interface.h"
#include <cassert>
#include <stdio.h>
@@ -97,4 +95,4 @@ int main() {
// CHECK-NOT: Assertion failed:
// CHECK-NOT: AddressSanitizer
-// CHECK: Success \ No newline at end of file
+// CHECK: Success
diff --git a/compiler-rt/test/asan/TestCases/Windows/heapalloc_transfer.cpp b/compiler-rt/test/asan/TestCases/Windows/heapalloc_transfer.cpp
index fa9f937d5c5a..0731a02ed1b6 100644
--- a/compiler-rt/test/asan/TestCases/Windows/heapalloc_transfer.cpp
+++ b/compiler-rt/test/asan/TestCases/Windows/heapalloc_transfer.cpp
@@ -1,5 +1,3 @@
-// UNSUPPORTED: target={{.*-windows-gnu}}
-
#include "sanitizer\allocator_interface.h"
#include <cassert>
#include <stdio.h>
@@ -27,4 +25,4 @@ int main() {
// CHECK-NOT: assert
// CHECK-NOT: AddressSanitizer
-// CHECK: Success \ No newline at end of file
+// CHECK: Success
diff --git a/compiler-rt/test/asan/TestCases/Windows/heapalloc_uaf.cpp b/compiler-rt/test/asan/TestCases/Windows/heapalloc_uaf.cpp
index 34f30153c083..7aff4df945b7 100644
--- a/compiler-rt/test/asan/TestCases/Windows/heapalloc_uaf.cpp
+++ b/compiler-rt/test/asan/TestCases/Windows/heapalloc_uaf.cpp
@@ -1,6 +1,4 @@
-// UNSUPPORTED: target={{.*-windows-gnu}}
-
-// RUN: %clang_cl_asan -Od %s -Fe%t
+// RUN: %clang_cl_asan %Od %s %Fe%t
// RUN: %env_asan_opts=windows_hook_rtl_allocators=true not %run %t 2>&1 | FileCheck %s
// UNSUPPORTED: asan-64-bits
#include <windows.h>
diff --git a/compiler-rt/test/asan/TestCases/Windows/heapalloc_zero_size.cpp b/compiler-rt/test/asan/TestCases/Windows/heapalloc_zero_size.cpp
index f1345f60e9fc..767201a60781 100644
--- a/compiler-rt/test/asan/TestCases/Windows/heapalloc_zero_size.cpp
+++ b/compiler-rt/test/asan/TestCases/Windows/heapalloc_zero_size.cpp
@@ -1,9 +1,7 @@
-// UNSUPPORTED: target={{.*-windows-gnu}}
-
-// RUN: %clang_cl_asan /Od -o %t %s
+// RUN: %clang_cl_asan %Od -o %t %s
// RUN: %env_asan_opts=windows_hook_rtl_allocators=true %run %t 2>&1 | FileCheck %s
// RUN: %env_asan_opts=windows_hook_rtl_allocators=false %run %t 2>&1 | FileCheck %s
-// RUN: %clang_cl /Od -o %t %s
+// RUN: %clang_cl %Od -o %t %s
// RUN: %run %t 2>&1 | FileCheck %s
// UNSUPPORTED: asan-64-bits
#include <cassert>
diff --git a/compiler-rt/test/asan/TestCases/Windows/heaprealloc.cpp b/compiler-rt/test/asan/TestCases/Windows/heaprealloc.cpp
index 0073ce0136cf..5d715e32223a 100644
--- a/compiler-rt/test/asan/TestCases/Windows/heaprealloc.cpp
+++ b/compiler-rt/test/asan/TestCases/Windows/heaprealloc.cpp
@@ -1,6 +1,4 @@
-// UNSUPPORTED: target={{.*-windows-gnu}}
-
-// RUN: %clang_cl_asan -Od %s -Fe%t
+// RUN: %clang_cl_asan %Od %s %Fe%t
// RUN: %env_asan_opts=windows_hook_rtl_allocators=true not %run %t 2>&1 | FileCheck %s
// UNSUPPORTED: asan-64-bits
#include <stdio.h>
diff --git a/compiler-rt/test/asan/TestCases/Windows/heaprealloc_alloc_zero.cpp b/compiler-rt/test/asan/TestCases/Windows/heaprealloc_alloc_zero.cpp
index 1595729fc8f7..8b0bc71b9f5d 100644
--- a/compiler-rt/test/asan/TestCases/Windows/heaprealloc_alloc_zero.cpp
+++ b/compiler-rt/test/asan/TestCases/Windows/heaprealloc_alloc_zero.cpp
@@ -1,6 +1,4 @@
-// UNSUPPORTED: target={{.*-windows-gnu}}
-
-// RUN: %clang_cl_asan /Od /MT -o %t %s
+// RUN: %clang_cl_asan %Od %MT -o %t %s
// RUN: %env_asan_opts=windows_hook_rtl_allocators=true %run %t 2>&1 | FileCheck %s
// UNSUPPORTED: asan-64-bits
#include <cassert>
@@ -57,4 +55,4 @@ int main() {
// CHECK: allocated!
// CHECK-NOT: heap-buffer-overflow
// CHECK-NOT: AddressSanitizer
-// CHECK-NOT: HeapAlloc size failure! \ No newline at end of file
+// CHECK-NOT: HeapAlloc size failure!
diff --git a/compiler-rt/test/asan/TestCases/Windows/heaprealloc_zero_size.cpp b/compiler-rt/test/asan/TestCases/Windows/heaprealloc_zero_size.cpp
index cc1f1f0bc038..eb0b3c065bcd 100644
--- a/compiler-rt/test/asan/TestCases/Windows/heaprealloc_zero_size.cpp
+++ b/compiler-rt/test/asan/TestCases/Windows/heaprealloc_zero_size.cpp
@@ -1,9 +1,7 @@
-// UNSUPPORTED: target={{.*-windows-gnu}}
-
-// RUN: %clang_cl_asan /Od -o %t %s
+// RUN: %clang_cl_asan %Od -o %t %s
// RUN: %env_asan_opts=windows_hook_rtl_allocators=true %run %t 2>&1 | FileCheck %s
// RUN: %env_asan_opts=windows_hook_rtl_allocators=false %run %t 2>&1 | FileCheck %s
-// RUN: %clang_cl /Od -o %t %s
+// RUN: %clang_cl %Od -o %t %s
// RUN: %run %t 2>&1 | FileCheck %s
// UNSUPPORTED: asan-64-bits
#include <cassert>
@@ -22,4 +20,4 @@ int main() {
// CHECK-NOT: double-free
// CHECK-NOT: AddressSanitizer
-// CHECK: passed! \ No newline at end of file
+// CHECK: passed!
diff --git a/compiler-rt/test/asan/TestCases/Windows/recalloc_sanity.cpp b/compiler-rt/test/asan/TestCases/Windows/recalloc_sanity.cpp
index 9ed3ed69fb16..664a46426067 100644
--- a/compiler-rt/test/asan/TestCases/Windows/recalloc_sanity.cpp
+++ b/compiler-rt/test/asan/TestCases/Windows/recalloc_sanity.cpp
@@ -1,5 +1,3 @@
-// UNSUPPORTED: target={{.*-windows-gnu}}
-
// Workaround for "LINK : fatal error LNK1318: Unexpected PDB error"
// RUN: rm -f %t.pdb
@@ -39,4 +37,4 @@ int main() {
}
// CHECK-NOT: Assertion
-// CHECK: passed \ No newline at end of file
+// CHECK: passed
diff --git a/compiler-rt/test/asan/TestCases/Windows/report_globals_reload_dll.cpp b/compiler-rt/test/asan/TestCases/Windows/report_globals_reload_dll.cpp
index 2965122251f4..ac1f1a3b7f39 100644
--- a/compiler-rt/test/asan/TestCases/Windows/report_globals_reload_dll.cpp
+++ b/compiler-rt/test/asan/TestCases/Windows/report_globals_reload_dll.cpp
@@ -1,8 +1,6 @@
-// UNSUPPORTED: target={{.*-windows-gnu}}
-
// Make sure we can handle reloading the same DLL multiple times.
-// RUN: %clang_cl_asan -LD -Od -DDLL %s -Fe%t.dll
-// RUN: %clang_cl_asan -Od -DEXE %s -Fe%te.exe
+// RUN: %clang_cl_asan %LD %Od -DDLL %s %Fe%t.dll
+// RUN: %clang_cl_asan %Od -DEXE %s %Fe%te.exe
// RUN: %env_asan_opts=report_globals=1 %run %te.exe %t.dll 2>&1 | FileCheck %s
#include <windows.h>
diff --git a/compiler-rt/test/asan/TestCases/Windows/report_globals_vs_freelibrary.cpp b/compiler-rt/test/asan/TestCases/Windows/report_globals_vs_freelibrary.cpp
index 2b6aedb2d78d..65586077bc45 100644
--- a/compiler-rt/test/asan/TestCases/Windows/report_globals_vs_freelibrary.cpp
+++ b/compiler-rt/test/asan/TestCases/Windows/report_globals_vs_freelibrary.cpp
@@ -1,7 +1,5 @@
-// UNSUPPORTED: target={{.*-windows-gnu}}
-
-// RUN: %clang_cl_asan -LD -Od -DDLL %s -Fe%t.dll
-// RUN: %clang_cl_asan -Od -DEXE %s -Fe%te.exe
+// RUN: %clang_cl_asan %LD %Od -DDLL %s %Fe%t.dll
+// RUN: %clang_cl_asan %Od -DEXE %s %Fe%te.exe
// RUN: %env_asan_opts=report_globals=2 %run %te.exe %t.dll 2>&1 | FileCheck %s
#include <windows.h>
diff --git a/compiler-rt/test/asan/TestCases/Windows/rtlallocateheap.cpp b/compiler-rt/test/asan/TestCases/Windows/rtlallocateheap.cpp
index 8df1b5130aa5..20d14bdb57e8 100644
--- a/compiler-rt/test/asan/TestCases/Windows/rtlallocateheap.cpp
+++ b/compiler-rt/test/asan/TestCases/Windows/rtlallocateheap.cpp
@@ -1,6 +1,4 @@
-// UNSUPPORTED: target={{.*-windows-gnu}}
-
-// RUN: %clang_cl_asan -Od %s -Fe%t /MD
+// RUN: %clang_cl_asan %Od %s %Fe%t %MD
// RUN: %env_asan_opts=windows_hook_rtl_allocators=true not %run %t 2>&1 | FileCheck %s
// UNSUPPORTED: asan-64-bits
// REQUIRES: asan-rtl-heap-interception
diff --git a/compiler-rt/test/asan/TestCases/Windows/rtlallocateheap_dll_unload_double_free.cpp b/compiler-rt/test/asan/TestCases/Windows/rtlallocateheap_dll_unload_double_free.cpp
index 7ab075c57345..b71a4a2ce688 100644
--- a/compiler-rt/test/asan/TestCases/Windows/rtlallocateheap_dll_unload_double_free.cpp
+++ b/compiler-rt/test/asan/TestCases/Windows/rtlallocateheap_dll_unload_double_free.cpp
@@ -1,7 +1,5 @@
-// UNSUPPORTED: target={{.*-windows-gnu}}
-
-// RUN: %clang_cl_asan -LD /Od -DDLL %s -Fe%t.dll
-// RUN: %clang_cl /Od -DEXE %s -Fe%te.exe
+// RUN: %clang_cl_asan %LD %Od -DDLL %s %Fe%t.dll
+// RUN: %clang_cl %Od -DEXE %s %Fe%te.exe
// RUN: %env_asan_opts=windows_hook_rtl_allocators=true not %run %te.exe %t.dll 2>&1 | FileCheck %s
// REQUIRES: asan-dynamic-runtime
// REQUIRES: asan-32-bits
diff --git a/compiler-rt/test/asan/TestCases/Windows/rtlallocateheap_dll_unload_realloc.cpp b/compiler-rt/test/asan/TestCases/Windows/rtlallocateheap_dll_unload_realloc.cpp
index 3bf1784edd15..10621082a5a8 100644
--- a/compiler-rt/test/asan/TestCases/Windows/rtlallocateheap_dll_unload_realloc.cpp
+++ b/compiler-rt/test/asan/TestCases/Windows/rtlallocateheap_dll_unload_realloc.cpp
@@ -1,7 +1,5 @@
-// UNSUPPORTED: target={{.*-windows-gnu}}
-
-// RUN: %clang_cl_asan -LD /Od -DDLL %s -Fe%t.dll
-// RUN: %clang_cl /Od -DEXE %s -Fe%te.exe
+// RUN: %clang_cl_asan %LD %Od -DDLL %s %Fe%t.dll
+// RUN: %clang_cl %Od -DEXE %s %Fe%te.exe
// RUN: %env_asan_opts=windows_hook_rtl_allocators=true not %run %te.exe %t.dll 2>&1 | FileCheck %s
// REQUIRES: asan-dynamic-runtime
// REQUIRES: asan-32-bits
diff --git a/compiler-rt/test/asan/TestCases/Windows/rtlallocateheap_flags_fallback.cpp b/compiler-rt/test/asan/TestCases/Windows/rtlallocateheap_flags_fallback.cpp
index 177de65d4456..95fbff2435ef 100644
--- a/compiler-rt/test/asan/TestCases/Windows/rtlallocateheap_flags_fallback.cpp
+++ b/compiler-rt/test/asan/TestCases/Windows/rtlallocateheap_flags_fallback.cpp
@@ -1,6 +1,4 @@
-// UNSUPPORTED: target={{.*-windows-gnu}}
-
-// RUN: %clang_cl_asan -Od %s -Fe%t /MD
+// RUN: %clang_cl_asan %Od %s %Fe%t %MD
// RUN: %env_asan_opts=windows_hook_rtl_allocators=true %run %t 2>&1 | FileCheck %s
// UNSUPPORTED: asan-64-bits
// REQUIRES: asan-rtl-heap-interception
diff --git a/compiler-rt/test/asan/TestCases/Windows/rtlallocateheap_zero.cpp b/compiler-rt/test/asan/TestCases/Windows/rtlallocateheap_zero.cpp
index b1101437d53b..99ff341be30b 100644
--- a/compiler-rt/test/asan/TestCases/Windows/rtlallocateheap_zero.cpp
+++ b/compiler-rt/test/asan/TestCases/Windows/rtlallocateheap_zero.cpp
@@ -1,6 +1,4 @@
-// UNSUPPORTED: target={{.*-windows-gnu}}
-
-// RUN: %clang_cl_asan -Od %s -Fe%t /MD
+// RUN: %clang_cl_asan %Od %s %Fe%t %MD
// RUN: %env_asan_opts=windows_hook_rtl_allocators=true not %run %t 2>&1 | FileCheck %s
// UNSUPPORTED: asan-64-bits
// REQUIRES: asan-rtl-heap-interception
diff --git a/compiler-rt/test/asan/TestCases/Windows/sanitizer_purge.cpp b/compiler-rt/test/asan/TestCases/Windows/sanitizer_purge.cpp
index 474f0292f0c2..9097756449c4 100644
--- a/compiler-rt/test/asan/TestCases/Windows/sanitizer_purge.cpp
+++ b/compiler-rt/test/asan/TestCases/Windows/sanitizer_purge.cpp
@@ -1,11 +1,9 @@
-// UNSUPPORTED: target={{.*-windows-gnu}}
-
#include <Windows.h>
#include <stdio.h>
#include <sanitizer/allocator_interface.h>
#include <psapi.h>
-// RUN: %clang_cl_asan -Od %s -Fe%t
+// RUN: %clang_cl_asan %Od %s %Fe%t
// RUN: %t
// REQUIRES: asan-64-bits
@@ -30,4 +28,4 @@ int main(){
}
return 0;
-} \ No newline at end of file
+}
diff --git a/compiler-rt/test/asan/TestCases/Windows/stack_use_after_return.cpp b/compiler-rt/test/asan/TestCases/Windows/stack_use_after_return.cpp
index ae16bbd23376..9385e36a37b6 100644
--- a/compiler-rt/test/asan/TestCases/Windows/stack_use_after_return.cpp
+++ b/compiler-rt/test/asan/TestCases/Windows/stack_use_after_return.cpp
@@ -1,8 +1,7 @@
-// UNSUPPORTED: target={{.*-windows-gnu}}
-
-// RUN: %clang_cl_asan -Od %s -Fe%t
+// RUN: %clang_cl_asan %Od %s %Fe%t
// RUN: %env_asan_opts=detect_stack_use_after_return=1 not %run %t 2>&1 | FileCheck %s
-// RUN: %clang_cl_asan -Od %s -Fe%t -fsanitize-address-use-after-return=always
+
+// RUN: %clang_cl_asan %Od %s %Fe%t -fsanitize-address-use-after-return=always
// RUN: not %run %t 2>&1 | FileCheck %s
char *x;
diff --git a/compiler-rt/test/asan/TestCases/Windows/symbols_path.cpp b/compiler-rt/test/asan/TestCases/Windows/symbols_path.cpp
index 3681ff13923c..d896da482f2e 100644
--- a/compiler-rt/test/asan/TestCases/Windows/symbols_path.cpp
+++ b/compiler-rt/test/asan/TestCases/Windows/symbols_path.cpp
@@ -1,8 +1,6 @@
-// UNSUPPORTED: target={{.*-windows-gnu}}
-
// Make sure symbolization works even if the path to the .exe file changes.
// RUN: mkdir %t || true
-// RUN: %clang_cl_asan -Od %s -Fe%t/symbols_path.exe
+// RUN: %clang_cl_asan %Od %s %Fe%t/symbols_path.exe
// RUN: not %run %t/symbols_path.exe 2>&1 | FileCheck %s
// RUN: mkdir %t2 || true
// RUN: mv %t/* %t2
diff --git a/compiler-rt/test/asan/TestCases/Windows/user-exception.cpp b/compiler-rt/test/asan/TestCases/Windows/user-exception.cpp
index 5265e05f1f23..a04661b8af40 100644
--- a/compiler-rt/test/asan/TestCases/Windows/user-exception.cpp
+++ b/compiler-rt/test/asan/TestCases/Windows/user-exception.cpp
@@ -1,6 +1,4 @@
-// UNSUPPORTED: target={{.*-windows-gnu}}
-
-// RUN: %clang_cl_asan -Od %s -Fe%t
+// RUN: %clang_cl_asan %Od %s %Fe%t
// RUN: env ASAN_OPTIONS=handle_segv=0 %run %t 2>&1 | FileCheck %s --check-prefix=USER
// RUN: env ASAN_OPTIONS=handle_segv=1 not %run %t 2>&1 | FileCheck %s --check-prefix=ASAN
// Test the default.
diff --git a/compiler-rt/test/asan/lit.cfg.py b/compiler-rt/test/asan/lit.cfg.py
index 9a8e513521a3..01eff0fbe392 100644
--- a/compiler-rt/test/asan/lit.cfg.py
+++ b/compiler-rt/test/asan/lit.cfg.py
@@ -158,6 +158,9 @@ if platform.system() == 'Windows':
config.substitutions.append( ("%clang_cl_asan ", clang_cl_asan_invocation) )
config.substitutions.append( ("%Od", "-Od") )
config.substitutions.append( ("%Fe", "-Fe") )
+ config.substitutions.append( ("%LD", "-LD") )
+ config.substitutions.append( ("%MD", "-MD") )
+ config.substitutions.append( ("%MT", "-MT") )
base_lib = os.path.join(config.compiler_rt_libdir, "clang_rt.asan%%s%s.lib" % config.target_suffix)
config.substitutions.append( ("%asan_lib", base_lib % "") )
@@ -170,6 +173,9 @@ if platform.system() == 'Windows':
config.substitutions.append( ("%clang_cl_asan ", build_invocation(clang_asan_cxxflags)) )
config.substitutions.append( ("%Od", "-O0") )
config.substitutions.append( ("%Fe", "-o") )
+ config.substitutions.append( ("%LD", "-shared") )
+ config.substitutions.append( ("%MD", "") )
+ config.substitutions.append( ("%MT", "") )
# FIXME: De-hardcode this path.
asan_source_dir = os.path.join(