You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
oneMKL uses CXX_COMPILER_NAME to detect SYCL support. This means that if a user compiles their own copy of intel/llvm, SYCL support is not detected and the MKL::MKL_SYCL library will not be available. (The CXX_COMPILER_NAME is by default Clang.)
Users can force set SYCL_COMPILER with -DSYCL_COMPILER=ON, which will make the MKL::MKL_SYCL library available. However, with CLANG_COMPILER also set, the intel_thread backend is also made available. This elicits a compiler warning:
bbrock@ortce-skl22:~/src/distributed-ranges/build/examples/shp$ make -j
Consolidate compiler generated dependencies of target fmt
Warning: Using MKL::MKL_SYCL* targets with intel_thread may have potential composability problems on CPU device with other SYCL kernels.
[ 5%] Building CXX object _deps/cpp-format-build/CMakeFiles/fmt.dir/src/os.cc.o
Which seems to indicate this is still a sub-optimal solution.
I implemented a first stab at this in a new PR #450. It is based on oneDPL's CMake and modifies MKL's MKLConfig.cmake to explicitly check for support for the -fsycl flag and SYCL headers.
BenBrock
changed the title
oneMKL's CMake Does Not Detect SYCL Support when Compiled with intel/llvm
oneMKL's CMake Does Not Detect SYCL Support when Compiled with intel/llvmFeb 22, 2024
Summary
oneMKL uses
CXX_COMPILER_NAME
to detect SYCL support. This means that if a user compiles their own copy ofintel/llvm
, SYCL support is not detected and theMKL::MKL_SYCL
library will not be available. (TheCXX_COMPILER_NAME
is by defaultClang
.)Users can force set
SYCL_COMPILER
with-DSYCL_COMPILER=ON
, which will make theMKL::MKL_SYCL
library available. However, withCLANG_COMPILER
also set, theintel_thread
backend is also made available. This elicits a compiler warning:Which seems to indicate this is still a sub-optimal solution.
Version
oneMKL
develop
branch.Environment
2024.0
and oneMKL develop.intel/llvm
CMake output
Steps to reproduce
intel/llvm
Observed behavior
Build fails due to
MKL::MKL_DPCPP
/MKL::MKL_SYCL
library not being available.Expected behavior
I expect SYCL support to be detected by oneMKL and the build to succeed.
The text was updated successfully, but these errors were encountered: