Building with clang 3.4


If I use clang 3.4 to build libclc, it fails with the following error:

LLVM-AS nvptx--nvidiacl/lib/atomic/atomic_impl.ll.bc
./generic/lib/atomic/atomic_impl.ll:27:82: error: expected instruction
  %0 = cmpxchg volatile i32 addrspace(1)* %ptr, i32 %compare, i32 %value
seq_cst seq_cst

Makefile:79: recipe for target
'nvptx--nvidiacl/lib/atomic/atomic_impl.ll.bc' failed
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.

Thank you!

I’m not sure if llvm 3.4 is still supported. Traditionally there was only support for the latest released version of llvm and the current development version.