[compiler-rt] Add aligned_alloc to macOS tsan interceptors (PR #79198)
Chris Apple via llvm-commits
llvm-commits at lists.llvm.org
Tue Jan 23 19:02:21 PST 2024
cjappl wrote:
It turns out the test I wrote works both before and after the change to the code. This means that `aligned_alloc` was already being properly intercepted in this block:
https://github.com/cjappl/llvm-project/blob/3d718d0ebac232f304a0a074610de2d9652ab21f/compiler-rt/lib/sanitizer_common/sanitizer_malloc_mac.inc#L262-L266
It appears that when `aligned_alloc` is called, it calls the intercepted `__sanitizer_mz_memalign` for the sanitizer zone, and is able to do it's magic.
At the minimum, this means the test case I proposed is useless. At a higher level it could mean this PR should be closed. Is there any value in this call being intercepted directly for MacOS if we catch it another way? Is there a test I can write to prove that it's valuable?
https://github.com/llvm/llvm-project/pull/79198
More information about the llvm-commits
mailing list