diff options
Diffstat (limited to 'winsup/cygwin/thread.h')
-rw-r--r-- | winsup/cygwin/thread.h | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/winsup/cygwin/thread.h b/winsup/cygwin/thread.h index 6065f9d9c..39f0f58a4 100644 --- a/winsup/cygwin/thread.h +++ b/winsup/cygwin/thread.h @@ -263,12 +263,15 @@ class pthread_mutex:public verifyable_object public: HANDLE win32_obj_id; LONG condwaits; + int pshared; int Lock (); int TryLock (); int UnLock (); - + + pthread_mutex (unsigned short); pthread_mutex (pthread_mutexattr *); + pthread_mutex (pthread_mutex_t *, pthread_mutexattr *); ~pthread_mutex (); }; @@ -345,6 +348,11 @@ public: callback *pthread_child; callback *pthread_parent; + /* this is an associative array for the _exclusive_ use of pshared mutex's + * normal mutex's don't go here to reduce overhead and prevent serialisation. + */ + class pthread_mutex * pshared_mutexs[256]; + void Init (int); MTinterface ():reent_index (0), indexallocated (0), threadcount (1) |