Intel® Embree Ray Tracing Kernels
Discussion forum on the open source ray tracing kernels for fast photo-realistic rendering on Intel® CPU(s)
280 Discussions

no matching function for call to ‘atomic_xchg(int32*&, int32&)’

Josh_S_
Beginner
331 Views

I just configured embree and having trouble compiling it on my Linux x368 machine running Ubuntu.  I don't have icc installed so I'm assuming it's using g++.  Is there something else I need to include?  

/tmp/embree-1.1beta/build$ make
[ 1%] Building CXX object common/sys/CMakeFiles/sys.dir/platform.o
In file included from /tmp/embree-1.1beta/common/sys/platform.cpp:18:0:
/tmp/embree-1.1beta/common/sys/intrinsics.h: In function ‘T* atomic_xchg(T* volatile*, const T*)’:
/tmp/embree-1.1beta/common/sys/intrinsics.h:232:53: error: no matching function for call to ‘atomic_xchg(int32*&, int32&)’
/tmp/embree-1.1beta/common/sys/intrinsics.h:232:53: note: candidate is:
/tmp/embree-1.1beta/common/sys/intrinsics.h:231:18: note: template<class T> T* atomic_xchg(T* volatile*, const T*)
make[2]: *** [common/sys/CMakeFiles/sys.dir/platform.o] Error 1
make[1]: *** [common/sys/CMakeFiles/sys.dir/all] Error 2
make: *** [all] Error 2

0 Kudos
1 Reply
SvenW_Intel
Moderator
331 Views

The compiler does not list the atomic_xchg(int32 volatile*, int32, int32) declared some lines above as a candidate. Maybe the issue is that the template where the error occurs also has the atomic_xchg name. Rename the template to atomic_xchg_ptr including its use in the file rtcore/common/atomic_set.h.

0 Kudos
Reply