On 6/23/20 6:44 PM, Thomas Schwinge wrote: > Per the PTX 3.1 manual that I looked into, I see for CAS it supports: > '.b32', '.b64'. We've got: > > $ build-gcc-offload-nvptx-none/gcc/xgcc > -Bbuild-gcc-offload-nvptx-none/gcc -dM -E -x c /dev/null | grep -i > compare.and.swap > #define __GCC_HAVE_SYNC_COMPARE_AND_SWAP_4 1 > #define __GCC_HAVE_SYNC_COMPARE_AND_SWAP_8 1 > > ..., so that would match the PTX 3.1 manual. GCC also seems to know > about 16-byte ("'.b128'", which doesn't exist in PTX). A quick run of > your testcase with 'GENERATE_TEST(__int128)' seems to just work, but I > haven't verified why/how.
In this case, we hit the critical section strategy and use expand_omp_atomic_mutex. Thanks, - Tom