![]() ![]() IntelSYCL is in CMake's search path after running setvars.sh on Linux or setvars.bat on Windows. The find_package directive, tells CMake to use the IntelSYCL module distributed with the oneAPI distribution. Refer to the package for more information.Īpplications not using pre-compiled header files might work with CMake 3.21.0 on Windows. The heterogeneous compilation configuration package exposes other variables that may be required.The package directory is found in the parent directory of the icx bin directory. The heterogeneous compilation configuration package ( IntelDPCPPConfig.cmake) is shipped with the compiler. Use the following steps to enable the DPC++ compiler for your project: Run CMake and build your applications as normal.See the Linux and Windows sections above for specific settings. Select the appropriate compilers for C or C++.Not specifying any sources to add_sycl_to_target() adds SYCL compilation to all sources which may affect compilation time significantly: add_executable(target_proj A.cpp B.cpp offload1.cpp offload2.cpp)Īdd_sycl_to_target(TARGET target_proj SOURCES offload1.cpp offload2.cpp) Add the sources that require SYCL support to add_sycl_to_target().This imports the heterogeneous compilation configuration package ( IntelSYCLConfig.cmake), which is shipped with the compiler. Add IntelSYCLConfig package to the project after project() is defined: find_package( IntelSYCL REQUIRED).# CMake 3.20.5 is the minimum recommended for IntelLLVM on Linux ![]() # need CMake 3.25.0+ for IntelLLVM support of target link properties on Windows Minimum CMake version check: if (CMAKE_HOST_WIN32).Add the following snippets to your project’s CMakeLists.txt:.Use the following steps to enable the SYCL compiler for your project. We recommend using IntelSYCLConfig approach as it is compatible with de-facto Industry standard and possibility of deprecation of IntelDPCPPConfig in the future. There are two ways to enable compiler for your project. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |