[PATCH] D14855: [tsan] Support thread sanitizer on Android.

Dmitry Vyukov via llvm-commits llvm-commits at lists.llvm.org
Thu Dec 3 06:17:39 PST 2015


dvyukov added inline comments.

================
Comment at: lib/tsan/rtl/tsan_interceptors.cc:252
@@ +251,3 @@
+#if SANITIZER_ANDROID
+  internal_sigfillset(sigset);
+  return 0;
----------------
kubabrecka wrote:
> dvyukov wrote:
> > This file calls REAL(sigfillset) just because it was written before internal_sigfillset appeared. The right thing to do is to replace all calls of REAL(sigfillset) to internal_sigfillset in this file, and then make internal_sigfillset work on all platforms. Windows is not an issue, because tsan does not work on windows yet. Mac calls just sigfillset inside of internal_sigfillset, not sure whether it can lead to infinite recursion or not... +Kuba for this. Anyway we need to fix internal_sigfillset.
> Calling just `sigfillset` on OS X will call `REAL(sigfillset)`, so it won't infinitely recurse.  (Actually, sigfillset is a macro that sets the value to `~0`, so nothing is called at all.)
Great, thanks.
Then we just need to call internal_sigfillset in this file.


http://reviews.llvm.org/D14855





More information about the llvm-commits mailing list