On 07/15/2011 11:37 AM, Jakub Jelinek wrote:
While __sync_lock_test_and_set isn't a full barrier on all targets, I hope it doesn't matter, because the inline caller has already done one __sync_val_compare_and_swap which is a full barrier.
Why not take the occasion to add the __sync_swap extension that clang added already?
Paolo