[compiler-rt] r343136 - [asan] [windows] Don't use CheckFailed in dynamic runtime thunk mode

Martin Storsjo via llvm-commits llvm-commits at lists.llvm.org
Wed Sep 26 12:49:35 PDT 2018


Author: mstorsjo
Date: Wed Sep 26 12:49:35 2018
New Revision: 343136

URL: http://llvm.org/viewvc/llvm-project?rev=343136&view=rev
Log:
[asan] [windows] Don't use CheckFailed in dynamic runtime thunk mode

Since SVN r342651, CheckFailed isn't exported from asan-dynamic. See
comments in https://reviews.llvm.org/D52279#1246222 for a longer
discussion on this issue.

Differential Revision: https://reviews.llvm.org/D52566

Modified:
    compiler-rt/trunk/lib/asan/asan_globals_win.cc

Modified: compiler-rt/trunk/lib/asan/asan_globals_win.cc
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/asan/asan_globals_win.cc?rev=343136&r1=343135&r2=343136&view=diff
==============================================================================
--- compiler-rt/trunk/lib/asan/asan_globals_win.cc (original)
+++ compiler-rt/trunk/lib/asan/asan_globals_win.cc Wed Sep 26 12:49:35 2018
@@ -29,7 +29,7 @@ static void call_on_globals(void (*hook)
   __asan_global *end = &__asan_globals_end;
   uptr bytediff = (uptr)end - (uptr)start;
   if (bytediff % sizeof(__asan_global) != 0) {
-#ifdef SANITIZER_DLL_THUNK
+#if defined(SANITIZER_DLL_THUNK) || defined(SANITIZER_DYNAMIC_RUNTIME_THUNK)
     __debugbreak();
 #else
     CHECK("corrupt asan global array");




More information about the llvm-commits mailing list