Change --trace-pthread= flag to accept none|some|all, for finer level
of pthread event tracing.  And allow this info to be passed across to
the client, where vg_libpthread.c uses it to also control verbosity.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@91 a5019735-40e9-0310-863c-91ae7b9d1cf9
diff --git a/coregrind/vg_include.h b/coregrind/vg_include.h
index 1fef7da..cd831c8 100644
--- a/coregrind/vg_include.h
+++ b/coregrind/vg_include.h
@@ -241,8 +241,9 @@
 extern Bool  VG_(clo_trace_malloc);
 /* DEBUG: print thread scheduling events?  default: NO */
 extern Bool  VG_(clo_trace_sched);
-/* DEBUG: print pthread (mutex etc) events?  default: NO */
-extern Bool  VG_(clo_trace_pthread);
+/* DEBUG: print pthread (mutex etc) events?  default: 0 (none), 1
+   (some), 2 (all) */
+extern Int   VG_(clo_trace_pthread_level);
 /* Stop after this many basic blocks.  default: Infinity. */
 extern ULong VG_(clo_stop_after);
 /* Display gory details for the k'th most popular error.  default:
@@ -405,6 +406,9 @@
 #define VG_USERREQ__PTHREAD_MUTEX_DESTROY   0x3007
 #define VG_USERREQ__PTHREAD_CANCEL          0x3008
 
+/* Cosmetic ... */
+#define VG_USERREQ__GET_PTHREAD_TRACE_LEVEL 0x3101
+
 /* 
 In vg_constants.h:
 #define VG_USERREQ__SIGNAL_RETURNS          0x4001