[PATCH] [compiler-rt] Refactor stacktrace and symbolizing functions from TSan into sanitizer_common

Kuba Brecka kuba.brecka at gmail.com
Fri Nov 14 12:43:07 PST 2014


This is a refactor patch that moves a couple of stacktrace taking and/or symbolizer-related functions from TSan, makes them generic and moves them into sanitizer_common. This is to prepare the functions for an upcoming patch implementing issue suppression mechanism into ASan. NFC intented.

There is a couple of subtle changes, that I'd like to make sure we're fine with:

* The `#ifdef TSAN_GO` changes into `#ifdef SANITIZER_GO` in the appropriate places.
* The `internal_alloc(MBlockReportStack, sizeof(ReportStack));` becomes `InternalAlloc(sizeof(ReportStack));`, not sure if the `MBlockReportStack` is used for anything important.
* `stack->pc` to `stack->info.address`, how could this event work before???
* `bool strip_main` argument to `SymbolizeStack` whether it should try to strip the main function from the stack trace

http://reviews.llvm.org/D6276

Files:
  lib/sanitizer_common/sanitizer_symbolizer.cc
  lib/sanitizer_common/sanitizer_symbolizer.h
  lib/tsan/rtl/tsan_report.cc
  lib/tsan/rtl/tsan_report.h
  lib/tsan/rtl/tsan_rtl_report.cc
  lib/tsan/rtl/tsan_symbolize.cc
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D6276.16240.patch
Type: text/x-patch
Size: 9686 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20141114/dd8717cb/attachment.bin>


More information about the llvm-commits mailing list