OSDN Git Service

[GWP-ASan] Split the unwinder into segv/non-segv.
authorMitch Phillips <31459023+hctim@users.noreply.github.com>
Fri, 17 Jul 2020 19:59:09 +0000 (12:59 -0700)
committerMitch Phillips <31459023+hctim@users.noreply.github.com>
Fri, 17 Jul 2020 19:59:47 +0000 (12:59 -0700)
commit502f0cc0e3889229e923e187f38dda91324ae139
tree46309debd8637baaf71c0e33767607687918026f
parentd8e0baf29daa58233c349d94ca4617065efc4c95
[GWP-ASan] Split the unwinder into segv/non-segv.

Summary:
Splits the unwinder into a non-segv (for allocation/deallocation traces) and a
segv unwinder. This ensures that implementations can select an accurate, slower
unwinder in the segv handler (if they choose to use the GWP-ASan provided one).
This is important as fast frame-pointer unwinders (like the sanitizer unwinder)
don't like unwinding through signal handlers.

Reviewers: morehouse, cryptoad

Reviewed By: morehouse, cryptoad

Subscribers: cryptoad, mgorny, eugenis, pcc, #sanitizers

Tags: #sanitizers

Differential Revision: https://reviews.llvm.org/D83994
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/segv_handler.h
compiler-rt/lib/gwp_asan/optional/segv_handler_posix.cpp
compiler-rt/lib/gwp_asan/tests/CMakeLists.txt
compiler-rt/lib/gwp_asan/tests/harness.h
compiler-rt/lib/scudo/scudo_allocator.cpp
compiler-rt/lib/scudo/standalone/combined.h
compiler-rt/test/gwp_asan/backtrace.c [new file with mode: 0644]