Skip to content

Commit

Permalink
revert test fixups that don't work without the onedll changes themsel…
Browse files Browse the repository at this point in the history
…ves.
  • Loading branch information
barcharcraz committed Mar 14, 2024
1 parent ed4d8a7 commit f54e0b4
Show file tree
Hide file tree
Showing 9 changed files with 25 additions and 4 deletions.
3 changes: 3 additions & 0 deletions compiler-rt/test/asan/TestCases/Windows/free_hook_realloc.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
// FIXME: merge this with the common free_hook_realloc test when we can run
// common tests on Windows.

// FIXME: Doesn't work with DLLs
// XFAIL: win32-dynamic-asan

#include <stdlib.h>
#include <io.h>
#include <sanitizer/allocator_interface.h>
Expand Down
5 changes: 3 additions & 2 deletions compiler-rt/test/asan/TestCases/Windows/msvc/dll_and_lib.cpp
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
// 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
// RUN: lld-link /nologo /DLL /OUT:%t.1.dll %t.1.obj %asan_lib %asan_thunk
// RUN: lld-link /nologo /DLL /OUT:%t.1.dll %t.1.obj %asan_dll_thunk
// RUN: %clang_cl_asan -DCONFIG=2 %s -c -Fo%t.2.obj
// RUN: lld-link /nologo /DLL /OUT:%t.2.dll %t.2.obj %t.1.lib %asan_lib %asan_thunk
// RUN: lld-link /nologo /DLL /OUT:%t.2.dll %t.2.obj %t.1.lib %asan_dll_thunk
// REQUIRES: asan-static-runtime
// REQUIRES: lld-available

#if CONFIG==1
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@
// from the DLL. We simulate the large function with
// -mllvm -asan-instrumentation-with-call-threshold=0.
// RUN: %clang_cl_asan %s -c -Fo%t.obj -mllvm -asan-instrumentation-with-call-threshold=0
// RUN: lld-link /nologo /DLL /OUT:%t.dll %t.obj %asan_lib %asan_thunk
// RUN: lld-link /nologo /DLL /OUT:%t.dll %t.obj %asan_dll_thunk
// REQUIRES: asan-static-runtime
// REQUIRES: lld-available

void f(long* foo, long* bar) {
Expand Down
2 changes: 1 addition & 1 deletion compiler-rt/test/asan/TestCases/Windows/unsymbolized.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

// RUN: rm -f %t.pdb
// RUN: %clangxx_asan -c -O2 %s -o %t.obj
// RUN: lld-link /nologo /OUT:%t.exe %t.obj -defaultlib:libcmt -nodefaultlib:msvcrt -defaultlib:oldnames %asan_static_runtime_thunk %asan_lib
// RUN: lld-link /nologo /OUT:%t.exe %t.obj %asan_lib %asan_cxx_lib
// RUN: not %run %t.exe 2>&1 | FileCheck %s
// REQUIRES: lld-available

Expand Down
3 changes: 3 additions & 0 deletions compiler-rt/test/asan/TestCases/debug_double_free.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@
#include <stdio.h>
#include <stdlib.h>

// FIXME: Doesn't work with DLLs
// XFAIL: win32-dynamic-asan

// If we use %p with MSVC, it comes out all upper case. Use %08x to get
// lowercase hex.
#ifdef _MSC_VER
Expand Down
3 changes: 3 additions & 0 deletions compiler-rt/test/asan/TestCases/debug_report.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@
#include <stdio.h>
#include <stdlib.h>

// FIXME: Doesn't work with DLLs
// XFAIL: win32-dynamic-asan

int main() {
// Disable stderr buffering. Needed on Windows.
setvbuf(stderr, NULL, _IONBF, 0);
Expand Down
4 changes: 4 additions & 0 deletions compiler-rt/test/asan/TestCases/default_options.cpp
Original file line number Diff line number Diff line change
@@ -1,7 +1,11 @@
// RUN: %clangxx_asan -O2 %s -o %t
// RUN: %run %t 2>&1 | FileCheck %s

// FIXME: Doesn't work with DLLs
// XFAIL: win32-dynamic-asan

const char *kAsanDefaultOptions = "verbosity=1 help=1";

// Required for dyld macOS 12.0+
#if (__APPLE__)
__attribute__((weak))
Expand Down
3 changes: 3 additions & 0 deletions compiler-rt/test/asan/TestCases/on_error_callback.cpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
// RUN: %clangxx_asan -O2 %s -o %t && not %run %t 2>&1 | FileCheck %s

// FIXME: Doesn't work with DLLs
// XFAIL: win32-dynamic-asan

#include <stdio.h>
#include <stdlib.h>

Expand Down
3 changes: 3 additions & 0 deletions compiler-rt/test/asan/TestCases/report_error_summary.cpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
// RUN: %clangxx_asan -O0 %s -o %t && not %run %t 2>&1 | FileCheck %s

// FIXME: Doesn't work with DLLs
// XFAIL: win32-dynamic-asan

#include <stdio.h>

// Required for ld64 macOS 12.0+
Expand Down

0 comments on commit f54e0b4

Please sign in to comment.