[PATCH] [OPENMP] Codegen for 'atomic capture'.

Alexey Bataev a.bataev at hotmail.com
Wed Apr 22 01:51:09 PDT 2015


John, according to the standard 'Only the read and write of
the location designated by x are performed mutually atomically. Neither the evaluation
of expr or expr_list, nor the write to the location designated by v need be atomic with
respect to the read or write of the location designated by x.'
I think this means, that store to 'v' must be atomic too, but it does not required to be synchronized with read/update of 'x'. So, I think we can use atomic load of 'x' after atomicrmw for 'x' and we can use atomic store of old/new value of 'x' to 'v' after atomic update of 'x'.


http://reviews.llvm.org/D9049

EMAIL PREFERENCES
  http://reviews.llvm.org/settings/panel/emailpreferences/






More information about the cfe-commits mailing list