[PATCH] D27141: [asan] Support handle_sigill on Darwin

Phabricator via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Nov 25 17:40:37 PST 2016


This revision was automatically updated to reflect the committed changes.
Closed by commit rL287959: [asan] Support handle_sigill on Darwin (authored by kuba.brecka).

Changed prior to commit:
  https://reviews.llvm.org/D27141?vs=79324&id=79326#toc

Repository:
  rL LLVM

https://reviews.llvm.org/D27141

Files:
  compiler-rt/trunk/lib/sanitizer_common/sanitizer_mac.cc
  compiler-rt/trunk/test/asan/TestCases/ill.cc


Index: compiler-rt/trunk/test/asan/TestCases/ill.cc
===================================================================
--- compiler-rt/trunk/test/asan/TestCases/ill.cc
+++ compiler-rt/trunk/test/asan/TestCases/ill.cc
@@ -3,7 +3,6 @@
 // RUN: %clangxx_asan %s -o %t && %env_asan_opts=handle_sigill=0 not --crash %run %t 2>&1 | FileCheck %s --check-prefix=CHECK0
 // RUN: %clangxx_asan %s -o %t && %env_asan_opts=handle_sigill=1 not %run %t 2>&1 | FileCheck %s --check-prefix=CHECK1
 // REQUIRES: x86-target-arch
-// UNSUPPORTED: darwin
 
 #ifdef _WIN32
 #include <windows.h>
Index: compiler-rt/trunk/lib/sanitizer_common/sanitizer_mac.cc
===================================================================
--- compiler-rt/trunk/lib/sanitizer_common/sanitizer_mac.cc
+++ compiler-rt/trunk/lib/sanitizer_common/sanitizer_mac.cc
@@ -400,6 +400,8 @@
     return false;
   if (common_flags()->handle_abort && signum == SIGABRT)
     return true;
+  if (common_flags()->handle_sigill && signum == SIGILL)
+    return true;
   return (signum == SIGSEGV || signum == SIGBUS) && common_flags()->handle_segv;
 }
 


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D27141.79326.patch
Type: text/x-patch
Size: 1104 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20161126/d7a0f9e4/attachment.bin>


More information about the llvm-commits mailing list