[PATCH] D36377: Add NetBSD support in asan_stack.h

Kamil Rytarowski via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sun Aug 6 06:54:01 PDT 2017


krytarowski created this revision.
krytarowski added a project: Sanitizers.
Herald added a subscriber: kubamracek.

Part of the code inspired by the original work on libsanitizer in GCC 5.4 by Christos Zoulas.

Sponsored by <The NetBSD Foundation>


Repository:
  rL LLVM

https://reviews.llvm.org/D36377

Files:
  lib/asan/asan_stack.h


Index: lib/asan/asan_stack.h
===================================================================
--- lib/asan/asan_stack.h
+++ lib/asan/asan_stack.h
@@ -44,7 +44,8 @@
       // On FreeBSD the slow unwinding that leverages _Unwind_Backtrace()
       // yields the call stack of the signal's handler and not of the code
       // that raised the signal (as it does on Linux).
-      if (SANITIZER_FREEBSD && t->isInDeadlySignal()) fast = true;
+      if ((SANITIZER_FREEBSD || SANITIZER_NETBSD) && t->isInDeadlySignal())
+        fast = true;
       uptr stack_top = t->stack_top();
       uptr stack_bottom = t->stack_bottom();
       ScopedUnwinding unwind_scope(t);


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D36377.109921.patch
Type: text/x-patch
Size: 667 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20170806/797593ab/attachment.bin>


More information about the llvm-commits mailing list