[PATCH] D90483: [GWP-ASan] Fuchsia specific mapping & utilities functions
Kostya Kortchinsky via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Oct 30 10:44:58 PDT 2020
cryptoad created this revision.
cryptoad added reviewers: hctim, eugenis, mcgrathr.
Herald added subscribers: Sanitizers, phosek, mgorny.
Herald added a project: Sanitizers.
cryptoad requested review of this revision.
This CL introduces the Fuchsia versions of the existing platform
specific functions.
For Fuchsia, we need to track the VMAR (https://fuchsia.dev/fuchsia-src/reference/kernel_objects/vm_address_region)
of the Guarded Pool mapping, and for this purpose I added some platform
specific data structure that remains empty on POSIX platforms.
`getThreadID` is not super useful for Fuchsia so it's just left as a
stub for now.
While testing the changes in my Fuchsia tree, I realized that
`guarded_pool_allocator_tls.h` should have closed the namespace before
including `GWP_ASAN_PLATFORM_TLS_HEADER`, otherwise drama ensues.
This was tested in g3, upstream LLVM, and Fuchsia (with local changes).
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D90483
Files:
compiler-rt/lib/gwp_asan/CMakeLists.txt
compiler-rt/lib/gwp_asan/guarded_pool_allocator.h
compiler-rt/lib/gwp_asan/platform_specific/common_fuchsia.cpp
compiler-rt/lib/gwp_asan/platform_specific/guarded_pool_allocator_fuchsia.cpp
compiler-rt/lib/gwp_asan/platform_specific/guarded_pool_allocator_fuchsia.h
compiler-rt/lib/gwp_asan/platform_specific/guarded_pool_allocator_posix.h
compiler-rt/lib/gwp_asan/platform_specific/guarded_pool_allocator_tls.h
compiler-rt/lib/gwp_asan/platform_specific/utilities_fuchsia.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D90483.301956.patch
Type: text/x-patch
Size: 10645 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20201030/6875b943/attachment.bin>
More information about the llvm-commits
mailing list