[PATCH] POSIX barrier implementation, take 3

Corinna Vinschen corinna-cygwin@cygwin.com
Sat Feb 13 16:05:00 GMT 2016


On Feb 12 22:25, Václav Haisman wrote:
> On 12.2.2016 15:25, Corinna Vinschen wrote:
> > Hi Václav,
> > 
> > 
> > the patch looks pretty good, I have just a few (minor) nits:
> > [...]
> The attached patch should address all of the review comments.
> 
> Modifed change log:
> 
> Newlib:
> 
> 	* libc/include/sys/features.h (_POSIX_BARRIERS): Define for Cygwin.
> 	* libc/include/sys/types.h (pthread_barrier_t)
> 	(pthread_barrierattr_t): Do not define for Cygwin.
> 
> Cygwin:
> 
> 	* common.din (pthread_barrierattr_init)
> 	(pthread_barrierattr_setpshared, pthread_barrierattr_getpshared)
> 	(pthread_barrierattr_destroy, pthread_barrier_init)
> 	(pthread_barrier_destroy, pthread_barrier_wait): Export.
> 	* include/cygwin/types.h (pthread_barrierattr_t)
> 	(pthread_barrier_t): Declare.
> 	* include/pthread.h (PTHREAD_BARRIER_SERIAL_THREAD)
> 	(pthread_barrierattr_init, pthread_barrierattr_setpshared)
> 	(pthread_barrierattr_getpshared, pthread_barrierattr_destroy)
> 	(pthread_barrier_init, pthread_barrier_destroy)
> 	(pthread_barrier_wait): Declare.
> 	* thread.h (PTHREAD_BARRIER_MAGIC)
> 	(PTHREAD_BARRIERATTR_MAGIC): Define.
> 	(class pthread_barrierattr, class pthread_barrier): Declare.
> 	* thread.cc (delete_and_clear): New local helper function.
> 	(class pthread_barrierattr, class pthread_barrier): Implement.
> 	* miscfuncs.h (likely, unlikely): New macros.

Patch applied.  I added documentation changes to reflect this welcome
addition.


Thanks,
Corinna

-- 
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Maintainer                 cygwin AT cygwin DOT com
Red Hat
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <http://cygwin.com/pipermail/cygwin-patches/attachments/20160213/90ed4daf/attachment.sig>


More information about the Cygwin-patches mailing list