[PATCH] D63841: [GWP-ASan] Add generic unwinders and structure backtrace output.

Mitch Phillips via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Jun 26 13:43:48 PDT 2019


hctim created this revision.
hctim added reviewers: eugenis, vlad.tsyrklevich.
Herald added subscribers: llvm-commits, Sanitizers, cryptoad, mgorny, kubamracek.
Herald added projects: Sanitizers, LLVM.

Adds two flavours of generic unwinder and all the supporting cruft. If the
supporting allocator is okay with bringing in sanitizer_common, they can use
the fast frame-pointer based unwinder from sanitizer_common. Otherwise, we also
provide the backtrace() libc-based unwinder as well. Of course, the allocator
can always specify its own unwinder and unwinder-symbolizer.

The slightly changed output format is exemplified in the first comment on this
patch. It now better incorporates backtrace information, and displays
allocation details on the second line.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D63841

Files:
  compiler-rt/lib/gwp_asan/CMakeLists.txt
  compiler-rt/lib/gwp_asan/guarded_pool_allocator.cpp
  compiler-rt/lib/gwp_asan/guarded_pool_allocator.h
  compiler-rt/lib/gwp_asan/optional/backtrace.h
  compiler-rt/lib/gwp_asan/optional/backtrace_linux_libc.cpp
  compiler-rt/lib/gwp_asan/optional/backtrace_sanitizer_common.cpp
  compiler-rt/lib/gwp_asan/optional/options_parser.cpp
  compiler-rt/lib/gwp_asan/optional/options_parser.h
  compiler-rt/lib/gwp_asan/options.h
  compiler-rt/test/gwp_asan/double_delete.cpp
  compiler-rt/test/gwp_asan/double_deletea.cpp
  compiler-rt/test/gwp_asan/double_free.cpp
  compiler-rt/test/gwp_asan/heap_buffer_overflow.cpp
  compiler-rt/test/gwp_asan/heap_buffer_underflow.cpp
  compiler-rt/test/gwp_asan/invalid_free_left.cpp
  compiler-rt/test/gwp_asan/invalid_free_right.cpp
  compiler-rt/test/gwp_asan/lit.cfg
  compiler-rt/test/gwp_asan/realloc.cpp
  compiler-rt/test/gwp_asan/use_after_delete.cpp
  compiler-rt/test/gwp_asan/use_after_deletea.cpp
  compiler-rt/test/gwp_asan/use_after_free.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D63841.206740.patch
Type: text/x-patch
Size: 32121 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20190626/dc8a6bfd/attachment.bin>


More information about the llvm-commits mailing list