If I use clang 3.4 to build libclc, it fails with the following error:
./generic/lib/atomic/atomic_impl.ll:27:82: error: expected instruction
%0 = cmpxchg volatile i32 addrspace(1)* %ptr, i32 %compare, i32 %value
Makefile:79: recipe for target
gmake: *** [nvptx--nvidiacl/lib/atomic/atomic_impl.ll.bc] Error 1
It's building fine with clang 3.5.
I don't know how to fix the problem, but wanted to let people know in
case this happens to someone else.