I am trying to see if I can use a pointer from cudaMalloc and use it in the OpenCL api. It seems kinda of a goofy thing to want to do, but I want to see if it works. I could only get a CUDA project running in Ubuntu by using Nvidia’s Cuda C SDK template project. I then added -lOpenCL to the libs of the common.mk which was fine. Then when I tried to add #include to template.cu, I get over a hundred errors. They all look similar to this, but with different function names at the end:
/usr/lib/gcc/x86_64-linux-gnu/4.4.1/include/xmmintrin.h(334): error: identifier “__builtin_ia32_cmpeqps” is undefined
I am having a hard time figuring out why. Please help if you can. Also, if there is an easier way to set up a project that’ll be able to call the CUDA and OpenCL APIs let me know.