llvm-project/compiler-rt/test
Mitch Phillips 5f0f4e3ae0 [GWP-ASan] Mutex implementation [2].
Summary:
See D60593 for further information.
This patch pulls out the mutex implementation and the required definitions file.

We implement our own mutex for GWP-ASan currently, because:

1. We must be compatible with the sum of the most restrictive elements of the supporting allocator's build system. Current targets for GWP-ASan include Scudo (on Linux and Fuchsia), and bionic (on Android).
2. Scudo specifies `-nostdlib++ -nonodefaultlibs`, meaning we can't use `std::mutex` or `mtx_t`.
3. We can't use `sanitizer_common`'s mutex, as the supporting allocators cannot afford the extra maintenance (Android, Fuchsia) and code size (Fuchsia) overheads that this would incur.

In future, we would like to implement a shared base mutex for GWP-ASan, Scudo and sanitizer_common. This will likely happen when both GWP-ASan and Scudo standalone are not in the development phase, at which point they will have stable requirements.

Reviewers: vlad.tsyrklevich, morehouse, jfb

Reviewed By: morehouse

Subscribers: dexonsmith, srhines, cfe-commits, kubamracek, mgorny, cryptoad, jfb, #sanitizers, llvm-commits, vitalybuka, eugenis

Tags: #sanitizers, #llvm, #clang

Differential Revision: https://reviews.llvm.org/D61923

llvm-svn: 362138
2019-05-30 19:45:32 +00:00
..
BlocksRuntime Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
asan [AddressSanitizer] [Windows] Fix HeapReAlloc and _recalloc bugs in asan_malloc_win.cc 2019-04-29 20:26:19 +00:00
builtins [compiler-rt] Make builtins test pass when using i386 gcc as host compiler 2019-05-08 15:50:21 +00:00
cfi compiler-rt tests: Unbreak cmake with LLVM_ENABLE_PIC=OFF on mac 2019-01-16 20:36:27 +00:00
crt [crt] Mark dso_handle test as xfailing on ARM. 2019-05-16 11:13:49 +00:00
dfsan Add weak definitions of trace-cmp hooks to dfsan 2018-06-01 21:59:25 +00:00
fuzzer [libFuzzer] when using data-flow-trace (DFT) only load the DFT for the files present in the corpus 2019-05-24 00:43:52 +00:00
gwp_asan [GWP-ASan] Mutex implementation [2]. 2019-05-30 19:45:32 +00:00
hwasan [hwasan] Limit try-catch tests to aarch64. 2019-05-17 18:40:06 +00:00
interception Revert "[interception] Check for export table's size before referring to its elements." 2017-01-22 03:30:14 +00:00
lsan [TSan] Support fiber API on macOS 2019-04-20 00:18:44 +00:00
msan [MSan] Introduce __msan_unpoison_param(). 2019-05-09 21:50:57 +00:00
profile Prospective test fix in response to r358104. 2019-04-11 03:04:04 +00:00
safestack compiler-rt tests: Unbreak cmake with LLVM_ENABLE_PIC=OFF on mac 2019-01-16 20:36:27 +00:00
sanitizer_common [Sanitizer] Add interceptor for wcsdup 2019-05-22 08:34:56 +00:00
scudo [sanitizer] Remove "-android" from test_arch. 2019-02-25 22:32:30 +00:00
shadowcallstack Delete x86_64 ShadowCallStack support 2019-03-07 18:56:36 +00:00
tsan [TSan][libdispatch] Use FileCheck's --implicit-check-not=... 2019-05-16 18:57:36 +00:00
ubsan mac: Make ubsan test config look more like asan test config 2019-05-29 18:54:28 +00:00
ubsan_minimal [compiler-rt][UBSan] Sanitization for alignment assumptions. 2019-01-15 09:44:27 +00:00
xray Add libc++ to link XRay test cases if libc++ is used to build CLANG 2019-05-06 17:45:21 +00:00
.clang-format [compiler-rt] Use "ColumnLimit: 0" instead of "clang-format off" in tests 2018-12-01 01:24:29 +00:00
CMakeLists.txt Reland "[compiler-rt] Simple crtbegin.o and crtend.o implementation" 2019-04-30 18:13:22 +00:00
lit.common.cfg [TSan][libdispatch] Specify libdispatch header dir for lit tests 2019-04-04 17:25:43 +00:00
lit.common.configured.in Add libc++ to link XRay test cases if libc++ is used to build CLANG 2019-05-06 17:45:21 +00:00