HomePhabricator

[compiler-rt][hwasan] Setup hwasan thread handling on Fuchsia

Authored by leonardchan on Jun 11 2021, 10:32 AM.

Description

[compiler-rt][hwasan] Setup hwasan thread handling on Fuchsia

This patch splits up hwasan thread creation between __sanitizer_before_thread_create_hook,
__sanitizer_thread_create_hook, and __sanitizer_thread_start_hook.
The linux implementation creates the hwasan thread object inside the
new thread. On Fuchsia, we know the stack bounds before thread creation,
so we can initialize part of the thread object in __sanitizer_before_thread_create_hook,
then initialize the stack ring buffer in __sanitizer_thread_start_hook
once we enter the thread.

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

Details

Committed
leonardchanJul 7 2021, 3:05 PM
Differential Revision
D104085: [compiler-rt][hwasan] Setup hwasan thread handling on Fuchsia
Parents
rGb81aa458afd0: [llvm-nm][test] Fix just-symbols.test
Branches
Unknown
Tags
Unknown