Re: [cxx-mem-model] alternate fetch operations

2011-08-12 Thread Richard Henderson
On 08/11/2011 02:42 PM, Andrew MacLeod wrote: The names for the previous set implies the fetch is done before the operation, so the new ones simply drop the fetch and simply use the operation name. I found sync_mem_op_fetch slightly less clear. Really? I guess I'm pretty used to that, and it

Re: [cxx-mem-model] alternate fetch operations

2011-08-12 Thread Andrew MacLeod
On 08/12/2011 07:05 PM, Richard Henderson wrote: On 08/11/2011 02:42 PM, Andrew MacLeod wrote: The names for the previous set implies the fetch is done before the operation, so the new ones simply drop the fetch and simply use the operation name. I found sync_mem_op_fetch slightly less clear.

Re: [cxx-mem-model] alternate fetch operations

2011-08-11 Thread Lawrence Crowl
On 8/11/11, Andrew MacLeod amacl...@redhat.com wrote: The __sync_mem_fetch_{add,sub,and,xor,or} routines perform the operation atomically, and return the value that was in memory before the operation was performed. As I was working on switching the c++ wrappers to use these new routines, I

Re: [cxx-mem-model] alternate fetch operations

2011-08-11 Thread Andrew MacLeod
On 08/11/2011 07:18 PM, Lawrence Crowl wrote: On 8/11/11, Andrew MacLeodamacl...@redhat.com wrote: The __sync_mem_fetch_{add,sub,and,xor,or} routines perform the operation atomically, and return the value that was in memory before the operation was performed. As I was working on switching the