Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
40 Views

clFFT on Intel Processor Graphics and Windows?

Has anyone successfully used the open-source clFFT libraries (https://github.com/clMathLibraries/clFFT)

with a recent Intel Processor Graphics device (gen8/9), on Windows 10, with Visual Studio 2015/17 and Intel OpenCL SDK 2015/17?

I am trying to do it and wondering about any advice on setup/configuration of the dev environment/system from your experiences,

such as: will using the pre-compiled Windows/x64 binaries etc (clFFT.dll, clFFT.lib, clFFT.h) work,

or do we have to do the whole CMake build process ourselves?

Thanks, Colin

0 Kudos
3 Replies
Highlighted
Employee
40 Views

It's been a while, but I did get this to work about a year or so ago.  It looks like I built from source and didn't use pre-compiled binaries.  My project was CMake-based already and I don't see that I had to do anything fancy to add clFFT to the build, but like I said, it's been a while. :-)

Copying a few relevant parts of my CMakeLists.txt below, in case it's helpful:

add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/third_party/clFFT/src)
include_directories( ${CMAKE_CURRENT_SOURCE_DIR}/third_party/clFFT/src/include )
include_directories( ${CMAKE_CURRENT_BINARY_DIR}/third_party/clFFT/src/include )

target_link_libraries( ${TARGET_NAME} clFFT {other_libs_go_here} )

 

 

0 Kudos
Highlighted
Beginner
40 Views

Hello,

I tried an example of clfft on Intel Core M3 based laptop (I know it is extremely outdated) and received the error below. Any clue?

 

clFFT/src/examples/build$ make
[ 16%] Linking C executable examples/fft2d
/usr/bin/ld: CMakeFiles/example_examples_fft2d.dir/fft2d.c.o: undefined reference to symbol 'clGetPlatformIDs@@OPENCL_1.0'
//usr/lib/x86_64-linux-gnu/libOpenCL.so.1: error adding symbols: DSO missing from command line
collect2: error: ld returned 1 exit status
CMakeFiles/example_examples_fft2d.dir/build.make:94: recipe for target 'examples/fft2d' failed
make[2]: *** [examples/fft2d] Error 1
CMakeFiles/Makefile2:67: recipe for target 'CMakeFiles/example_examples_fft2d.dir/all' failed
make[1]: *** [CMakeFiles/example_examples_fft2d.dir/all] Error 2
Makefile:129: recipe for target 'all' failed
make: *** [all] Error 2

 

0 Kudos
Highlighted
Employee
40 Views

wang, shu wrote:

I tried an example of clfft on Intel Core M3 based laptop (I know it is extremely outdated) and received the error below. Any clue?

Hello, were you able to resolve this problem?  If not, it looks like there was an issue detecting your OpenCL library to link with when your Makefile was generated.  It might be helpful to see what CMake commands you are issuing to generate your Makefiles.  I just tried this and it seemed to work:

cd <clFFT directory>
mkdir build && cd build
cmake ../src
make -j4

This should build clFFT and the examples.  If all goes well you should see lines like the following when your Makefiles are generated:

-- Looking for CL_VERSION_2_0
-- Looking for CL_VERSION_2_0 - found
-- Found OpenCL: /opt/intel/intel-opencl-1.2-6.2.0.1760/opencl-sdk/lib64/libOpenCL.so (found version "2.0") 

Hope this helps!

0 Kudos