[PATCH] Make some pthread_mutex_* and pthread_cond_* interceptors common.
Alexey Samsonov
samsonov at google.com
Tue Oct 15 07:22:59 PDT 2013
================
Comment at: lib/sanitizer_common/sanitizer_common_interceptors.inc:45
@@ +44,3 @@
+#ifndef COMMON_INTERCEPTOR_MUTEX_LOCK
+# define COMMON_INTERCEPTOR_MUTEX_LOCK(ctx, m)
+#endif
----------------
Evgeniy Stepanov wrote:
> Please either use or do not use space in "# define" consistently.
Done
================
Comment at: lib/sanitizer_common/sanitizer_common_interceptors.inc:2233
@@ +2232,3 @@
+ COMMON_INTERCEPTOR_MUTEX_UNLOCK(ctx, m);
+ COMMON_INTERCEPTOR_READ_RANGE(ctx, c, 1);
+ int res = REAL(pthread_cond_wait)(c, m);
----------------
Evgeniy Stepanov wrote:
> I think you'll need to intercept pthread_cond_init to tell MSan that (*c) is initialized.
Good catch. Done.
http://llvm-reviews.chandlerc.com/D1937
More information about the llvm-commits
mailing list