Check whether the big lock is held before invoking pre_thread_ll_create.

If the pre_thread_ll_create tracking function would be invoked without the
big lock being held, that would trigger a race condition in the tools that
implement this tracking function.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12458 a5019735-40e9-0310-863c-91ae7b9d1cf9
diff --git a/coregrind/pub_core_scheduler.h b/coregrind/pub_core_scheduler.h
index 8d3d97c..5e6042a 100644
--- a/coregrind/pub_core_scheduler.h
+++ b/coregrind/pub_core_scheduler.h
@@ -78,6 +78,9 @@
 /* Matching function to acquire_BigLock_LL. */
 extern void VG_(release_BigLock_LL) ( HChar* who );
 
+/* Whether the specified thread owns the big lock. */
+extern Bool VG_(owns_BigLock_LL) ( ThreadId tid );
+
 /* Yield the CPU for a while.  Drops/acquires the lock using the
    normal (non _LL) functions. */
 extern void VG_(vg_yield)(void);