Re: [PATCH] compat: Allow static initializer for pthreads on Windows

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: "Johannes Sixt" <j6t@xxxxxxxx>

One point is that the DCLP idiom must be implemented correctly. There are solutions, of course, and when the initialization is over, we have a miniscule overhead at each pthread_mutex_lock call.


I had to look up DCLP ( = Double Checked Locking Patterns), and found a good write up on the issues..

http://www.aristeia.com/Papers/DDJ_Jul_Aug_2004_revised.pdf "C++ and the Perils of Double-Checked Locking", which include 'C' issues, and multi-thread, multi-processor issues. Not an easy issue when fighting optimisers..

--

Philip



[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]