diff --git a/compiler-rt/test/asan/TestCases/Windows/coverage-dll-stdio.cpp b/compiler-rt/test/asan/TestCases/Windows/msvc/coverage-dll-stdio.cpp rename from compiler-rt/test/asan/TestCases/Windows/coverage-dll-stdio.cpp rename to compiler-rt/test/asan/TestCases/Windows/msvc/coverage-dll-stdio.cpp --- a/compiler-rt/test/asan/TestCases/Windows/coverage-dll-stdio.cpp +++ b/compiler-rt/test/asan/TestCases/Windows/msvc/coverage-dll-stdio.cpp @@ -1,10 +1,8 @@ -// UNSUPPORTED: target={{.*-windows-gnu}} - // Test that coverage and MSVC CRT stdio work from a DLL. This ensures that the // __local_stdio_printf_options function isn't instrumented for coverage. // RUN: rm -rf %t && mkdir %t && cd %t -// RUN: %clang_cl_asan -fsanitize-coverage=func,trace-pc-guard -Od %p/dll_host.cpp -Fet.exe +// RUN: %clang_cl_asan -fsanitize-coverage=func,trace-pc-guard -Od %p/../dll_host.cpp -Fet.exe // RUN: %clang_cl_asan -fsanitize-coverage=func,trace-pc-guard -LD -Od %s -Fet.dll // RUN: %run ./t.exe t.dll 2>&1 | FileCheck %s diff --git a/compiler-rt/test/asan/TestCases/Windows/dll_and_lib.cpp b/compiler-rt/test/asan/TestCases/Windows/msvc/dll_and_lib.cpp rename from compiler-rt/test/asan/TestCases/Windows/dll_and_lib.cpp rename to compiler-rt/test/asan/TestCases/Windows/msvc/dll_and_lib.cpp --- a/compiler-rt/test/asan/TestCases/Windows/dll_and_lib.cpp +++ b/compiler-rt/test/asan/TestCases/Windows/msvc/dll_and_lib.cpp @@ -1,5 +1,3 @@ -// UNSUPPORTED: target={{.*-windows-gnu}} - // Just make sure we can link an implib into another DLL // This used to fail between r212699 and r212814. // RUN: %clang_cl_asan -DCONFIG=1 %s -c -Fo%t.1.obj diff --git a/compiler-rt/test/asan/TestCases/Windows/dll_cerr.cpp b/compiler-rt/test/asan/TestCases/Windows/msvc/dll_cerr.cpp rename from compiler-rt/test/asan/TestCases/Windows/dll_cerr.cpp rename to compiler-rt/test/asan/TestCases/Windows/msvc/dll_cerr.cpp --- a/compiler-rt/test/asan/TestCases/Windows/dll_cerr.cpp +++ b/compiler-rt/test/asan/TestCases/Windows/msvc/dll_cerr.cpp @@ -1,6 +1,4 @@ -// UNSUPPORTED: target={{.*-windows-gnu}} - -// RUN: %clang_cl_asan -Od %p/dll_host.cpp -Fe%t +// 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 2>&1 | FileCheck %s diff --git a/compiler-rt/test/asan/TestCases/Windows/dll_control_c.cpp b/compiler-rt/test/asan/TestCases/Windows/msvc/dll_control_c.cpp rename from compiler-rt/test/asan/TestCases/Windows/dll_control_c.cpp rename to compiler-rt/test/asan/TestCases/Windows/msvc/dll_control_c.cpp --- a/compiler-rt/test/asan/TestCases/Windows/dll_control_c.cpp +++ b/compiler-rt/test/asan/TestCases/Windows/msvc/dll_control_c.cpp @@ -1,6 +1,4 @@ -// UNSUPPORTED: target={{.*-windows-gnu}} - -// RUN: %clang_cl_asan -Od %p/dll_host.cpp -Fe%t +// RUN: %clang_cl_asan -Od %p/../dll_host.cpp -Fe%t // RUN: %clang_cl_asan -LD -O2 %s -Fe%t.dll // RUNX: %run %t %t.dll 2>&1 | FileCheck %s diff --git a/compiler-rt/test/asan/TestCases/Windows/dll_large_function.cpp b/compiler-rt/test/asan/TestCases/Windows/msvc/dll_large_function.cpp rename from compiler-rt/test/asan/TestCases/Windows/dll_large_function.cpp rename to compiler-rt/test/asan/TestCases/Windows/msvc/dll_large_function.cpp --- a/compiler-rt/test/asan/TestCases/Windows/dll_large_function.cpp +++ b/compiler-rt/test/asan/TestCases/Windows/msvc/dll_large_function.cpp @@ -1,5 +1,3 @@ -// UNSUPPORTED: target={{.*-windows-gnu}} - // Make sure we can link a DLL with large functions which would mean // functions such as __asan_loadN and __asan_storeN will be called // from the DLL. We simulate the large function with diff --git a/compiler-rt/test/asan/TestCases/Windows/dll_seh.cpp b/compiler-rt/test/asan/TestCases/Windows/msvc/dll_seh.cpp rename from compiler-rt/test/asan/TestCases/Windows/dll_seh.cpp rename to compiler-rt/test/asan/TestCases/Windows/msvc/dll_seh.cpp --- a/compiler-rt/test/asan/TestCases/Windows/dll_seh.cpp +++ b/compiler-rt/test/asan/TestCases/Windows/msvc/dll_seh.cpp @@ -1,6 +1,4 @@ -// UNSUPPORTED: target={{.*-windows-gnu}} - -// RUN: %clang_cl_asan -Od %p/dll_host.cpp -Fe%t +// RUN: %clang_cl_asan -Od %p/../dll_host.cpp -Fe%t // // Check both -GS and -GS- builds: // RUN: %clang_cl_asan -GS -LD -Od %s -Fe%t.dll diff --git a/compiler-rt/test/asan/TestCases/Windows/iostream_sbo.cpp b/compiler-rt/test/asan/TestCases/Windows/msvc/iostream_sbo.cpp rename from compiler-rt/test/asan/TestCases/Windows/iostream_sbo.cpp rename to compiler-rt/test/asan/TestCases/Windows/msvc/iostream_sbo.cpp --- a/compiler-rt/test/asan/TestCases/Windows/iostream_sbo.cpp +++ b/compiler-rt/test/asan/TestCases/Windows/msvc/iostream_sbo.cpp @@ -1,11 +1,9 @@ -// UNSUPPORTED: target={{.*-windows-gnu}} - // First, check this works with the default ignorelist: // RUN: %clang_cl_asan -Od %s -Fe%t // RUN: echo "42" | %run %t 2>&1 | FileCheck %s // // Then, make sure it still works when a user uses their own ignorelist file: -// RUN: %clang_cl_asan -Od %s -fsanitize-ignorelist=%p/../Helpers/initialization-ignorelist.txt -Fe%t2 +// RUN: %clang_cl_asan -Od %s -fsanitize-ignorelist=%p/../../Helpers/initialization-ignorelist.txt -Fe%t2 // RUN: echo "42" | %run %t2 2>&1 | FileCheck %s #include diff --git a/compiler-rt/test/asan/TestCases/Windows/msvc/lit.local.cfg.py b/compiler-rt/test/asan/TestCases/Windows/msvc/lit.local.cfg.py new file mode 100644 --- /dev/null +++ b/compiler-rt/test/asan/TestCases/Windows/msvc/lit.local.cfg.py @@ -0,0 +1,4 @@ +import re + +if not re.match(r'.*-windows-msvc$', config.target_triple): + config.unsupported = True diff --git a/compiler-rt/test/asan/TestCases/Windows/seh.cpp b/compiler-rt/test/asan/TestCases/Windows/msvc/seh.cpp rename from compiler-rt/test/asan/TestCases/Windows/seh.cpp rename to compiler-rt/test/asan/TestCases/Windows/msvc/seh.cpp --- a/compiler-rt/test/asan/TestCases/Windows/seh.cpp +++ b/compiler-rt/test/asan/TestCases/Windows/msvc/seh.cpp @@ -1,5 +1,3 @@ -// UNSUPPORTED: target={{.*-windows-gnu}} - // Make sure that ASan works with SEH in both Clang and MSVC. MSVC uses a // different EH personality depending on the -GS setting, so test both -GS+ and // -GS-. diff --git a/compiler-rt/test/asan/TestCases/Windows/tls_init.cpp b/compiler-rt/test/asan/TestCases/Windows/msvc/tls_init.cpp rename from compiler-rt/test/asan/TestCases/Windows/tls_init.cpp rename to compiler-rt/test/asan/TestCases/Windows/msvc/tls_init.cpp --- a/compiler-rt/test/asan/TestCases/Windows/tls_init.cpp +++ b/compiler-rt/test/asan/TestCases/Windows/msvc/tls_init.cpp @@ -1,5 +1,3 @@ -// UNSUPPORTED: target={{.*-windows-gnu}} - // RUN: %clang_cl_asan %s -Fe%t.exe /MD // RUN: %run %t.exe | FileCheck %s diff --git a/compiler-rt/test/asan/TestCases/Windows/use_after_return_linkage.cpp b/compiler-rt/test/asan/TestCases/Windows/msvc/use_after_return_linkage.cpp rename from compiler-rt/test/asan/TestCases/Windows/use_after_return_linkage.cpp rename to compiler-rt/test/asan/TestCases/Windows/msvc/use_after_return_linkage.cpp --- a/compiler-rt/test/asan/TestCases/Windows/use_after_return_linkage.cpp +++ b/compiler-rt/test/asan/TestCases/Windows/msvc/use_after_return_linkage.cpp @@ -1,5 +1,3 @@ -// UNSUPPORTED: target={{.*-windows-gnu}} - // Make sure LIBCMT doesn't accidentally get added to the list of DEFAULTLIB // directives.