llvm-project/compiler-rt
Adhemerval Zanella 039126c97d [sanitizer] Disable fast_unwind_on_malloc as default for arm-linux-gnu
ARM thumb/thumb2 frame pointer is inconsistent on GCC and Clang [1]
and fast-unwider is also unreliable when mixing arm and thumb code [2].

The fast unwinder on ARM tries to probe and compare the frame-pointer
at different stack layout positions and it works reliable only on
systems where all the libraries were built in arm mode (either with
gcc or clang) or with clang in thmb mode (which uses the same stack
frame pointer layout in arm and thumb).

However when mixing objects built with different abi modes the
fast unwinder is still problematic as shown by the failures on the
AddressSanitizer.ThreadStackReuseTest. For these failures, the
malloc is called by the loader itself and since it has been built
with a thum enabled gcc, the stack frame is not correctly obtained
and the suppression rule is not applied (resulting in a leak warning).

The check for fast-unwinder-works is also changed: instead of checking
f it is explicit enabled in the compiler flags, it now checks if
compiler defined thumb pre-processor.

This should fix BZ#44158.

[1] https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92172
[2] https://bugs.llvm.org/show_bug.cgi?id=44158

Reviewed By: eugenis

Differential Revision: https://reviews.llvm.org/D88958
2020-10-12 14:36:08 -03:00
..
cmake Enable LSAN for Android 2020-10-09 15:23:47 -04:00
docs
include [compiler-rt] [netbsd] Regenerate syscall hooks 2020-09-10 20:16:39 +02:00
lib [sanitizer] Disable fast_unwind_on_malloc as default for arm-linux-gnu 2020-10-12 14:36:08 -03:00
test [sanitizer] Disable fast_unwind_on_malloc as default for arm-linux-gnu 2020-10-12 14:36:08 -03:00
tools Add GWP-ASan fuzz target to compiler-rt/tools. 2019-08-27 18:28:07 +00:00
unittests [Scudo] [GWP-ASan] Add GWP-ASan to Scudo Standalone. 2019-12-13 09:09:41 -08:00
utils [compiler-rt] [netbsd] Update generate_netbsd_syscalls.awk 2020-09-10 20:16:17 +02:00
www [www] Change URLs to HTTPS. 2019-10-24 13:25:15 -07:00
.clang-tidy [NFC][compiler-rt] Refine .clang-tidy checks 2020-09-05 15:42:15 -07:00
.gitignore
CMakeLists.txt [sanitizer] Disable fast_unwind_on_malloc as default for arm-linux-gnu 2020-10-12 14:36:08 -03:00
CODE_OWNERS.TXT
CREDITS.TXT
LICENSE.TXT Fix typos throughout the license files that somehow I and my reviewers 2019-01-21 09:52:34 +00:00
README.txt

README.txt

Compiler-RT
================================

This directory and its subdirectories contain source code for the compiler
support routines.

Compiler-RT is open source software. You may freely distribute it under the
terms of the license agreement found in LICENSE.txt.

================================