Re: Use atomics in libgomp mutex

2011-11-29 Thread Alan Modra
On Tue, Nov 29, 2011 at 08:37:07AM -0800, Richard Henderson wrote: > How about MEMMODEL_ACQ_REL Right. Committed with that change revision 181832. -- Alan Modra Australia Development Lab, IBM

Re: Use atomics in libgomp mutex

2011-11-29 Thread Richard Henderson
On 11/29/2011 04:27 AM, Alan Modra wrote: > Did you see my comment about the OpenMP spec requirement that critical, > ordered and parallel regions have a flush on entry and on exit? So > should I commit a version with No, I missed that. Too many branches to this thread. ;-) > /* FIXME: This

Re: Use atomics in libgomp mutex

2011-11-29 Thread Alan Modra
On Mon, Nov 28, 2011 at 05:33:17PM -0800, Richard Henderson wrote: > On 11/27/2011 02:57 PM, Alan Modra wrote: > > This is the mutex part. Depends on > > http://gcc.gnu.org/ml/gcc-patches/2011-11/msg02454.html for MEMMODEL_* > > values. > > > > * config/linux/mutex.h: Use atomic rather than s

Re: Use atomics in libgomp mutex

2011-11-28 Thread Richard Henderson
On 11/27/2011 02:57 PM, Alan Modra wrote: > This is the mutex part. Depends on > http://gcc.gnu.org/ml/gcc-patches/2011-11/msg02454.html for MEMMODEL_* > values. > > * config/linux/mutex.h: Use atomic rather than sync builtins. > * config/linux/mutex.c: Likewise. Comment. Use -1 for

Re: Use atomics in libgomp mutex

2011-11-28 Thread Alan Modra
On Mon, Nov 28, 2011 at 09:15:02AM +0100, Jakub Jelinek wrote: > On Mon, Nov 28, 2011 at 10:37:09AM +1030, Alan Modra wrote: > > 14 A flush region without a list is implied at the following locations: > > 15 • During a barrier region. > > 16 • At entry to and exit from parallel, critical, and order

Re: Use atomics in libgomp mutex

2011-11-28 Thread Jakub Jelinek
On Mon, Nov 28, 2011 at 10:37:09AM +1030, Alan Modra wrote: > On Mon, Nov 28, 2011 at 09:27:20AM +1030, Alan Modra wrote: > > This is the mutex part. Depends on > > http://gcc.gnu.org/ml/gcc-patches/2011-11/msg02454.html for MEMMODEL_* > > values. > > Arrgh, I posted the wrong patch. I know it n

Re: Use atomics in libgomp mutex

2011-11-27 Thread Alan Modra
On Mon, Nov 28, 2011 at 09:27:20AM +1030, Alan Modra wrote: > This is the mutex part. Depends on > http://gcc.gnu.org/ml/gcc-patches/2011-11/msg02454.html for MEMMODEL_* > values. Arrgh, I posted the wrong patch. I know it needs work elsewhere in libgomp to comply with the OMP spec, which says o

Use atomics in libgomp mutex

2011-11-27 Thread Alan Modra
This is the mutex part. Depends on http://gcc.gnu.org/ml/gcc-patches/2011-11/msg02454.html for MEMMODEL_* values. * config/linux/mutex.h: Use atomic rather than sync builtins. * config/linux/mutex.c: Likewise. Comment. Use -1 for waiting state. * config/linux/omp-lock.h: