[PATCH] D35865: [asan] Fuchsia port

Roland McGrath via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Aug 1 13:55:31 PDT 2017


mcgrathr marked an inline comment as done.
mcgrathr added a comment.

I'll split this into smaller pieces.



================
Comment at: lib/asan/asan_interceptors.h:118
+#endif  // !SANITIZER_FUCHSIA
+
 namespace __asan {
----------------
filcab wrote:
> It seems you can disable most of the file anyway. Do you really need `InitializeAsanInterceptors` if you don't have interceptors?
> Can you just hoist the macro (and maybe the functions) to either the top of the header or another header?
InitializeAsanInterceptors is called unconditionally from asan_rtl.cc and the norm in this code seems to be to write stub functions instead of conditionalizing the calls.  The main thing I need is the ENSURE_ASAN_INITED macro, which is used by asan_interceptors_memintrinsics.h and by asan_malloc_linux.cc (both of which are used on Fuchsia).

I'll move the preserved code to the top of the file if that's what you prefer.  If it's to go in a different header, I'm not sure which one you'd want it in.  I'll do it however I'm told.


https://reviews.llvm.org/D35865





More information about the llvm-commits mailing list