Subj : Re: recursive mutexes To : comp.programming.threads From : Uenal Mutlu Date : Thu May 19 2005 12:24 am "Casper H.S. Dik" wrote > "Uenal Mutlu" writes: .... > (The recursive mutex is only slightly more expensive > than the ordinary mutex as the unlock path is more > expensive) Actually it is just an increment and a comparision of the currentthreadid vs. the lock holding threadid in Lock(), and a simple decrement in Unlock(). The overhead for recursively locking is far less than the first aquisition (== non-recursive mutex) of the lock. Cf. code snippet of my other posting to doug and David. .