Open linehill opened 1 year ago
I can't reproduce the issue. Please let me know if you still see the issue with latest.
With the latest update the compilation seems to fail later on different thing:
[ 83%] Building CXX object src/CMakeFiles/MKLShim.dir/onemklblas.cpp.o
/mnt/md1/linehill/ws-chip-spv-2/H4I-MKLShim/src/Stream.cpp:3:10: fatal error: 'CL/sycl.hpp' file not found
#include <CL/sycl.hpp>
^~~~~~~~~~~~~
In file included from /mnt/md1/linehill/ws-chip-spv-2/H4I-MKLShim/src/Common.cpp:1:
In file included from /mnt/md1/linehill/ws-chip-spv-2/H4I-MKLShim/include/h4i/mklshim/common.h:4:
In file included from /opt/intel/oneapi/mkl/2023.1.0/include/oneapi/mkl.hpp:26:
/opt/intel/oneapi/mkl/2023.1.0/include/oneapi/mkl/blas.hpp:22:10: fatal error: 'CL/sycl.hpp' file not found
#include <CL/sycl.hpp>
^~~~~~~~~~~~~
(same error repeated...)
A configuration warning before the build is concerning:
...
-- Detecting CXX compile features
-- Detecting CXX compile features - done
CMake Warning at /opt/intel/oneapi/compiler/2023.1.0/linux/IntelDPCPP/IntelDPCPPConfig.cmake:80 (message):
IntelDPCPP Config will be deprecated soon. Use IntelSYCL config instead!
Call Stack (most recent call first):
CMakeLists.txt:30 (find_package)
-- The SYCL compiler is /usr/bin/clang++
...
@linehill, may I know the cmake command that you have used? Also can you confirm if you have oneAPI package(HPC toolkit) installed? Remember you have to run "intel/oneapi/setvars.sh" every time.
may I know the cmake command that you have used?
The command:
cd builds/mklshim/ && logsave configure.log cmake \
-DCMAKE_INSTALL_PREFIX=/mnt/md1/linehill/ws-chip-spv-2/install \
-DCMAKE_CXX_COMPILER=clang++ \
/mnt/md1/linehill/ws-chip-spv-2/H4I-MKLShim
Full configure log:
-- The CXX compiler identification is Clang 14.0.6
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/clang++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
CMake Warning at /opt/intel/oneapi/compiler/2023.1.0/linux/IntelDPCPP/IntelDPCPPConfig.cmake:80 (message):
IntelDPCPP Config will be deprecated soon. Use IntelSYCL config instead!
Call Stack (most recent call first):
CMakeLists.txt:30 (find_package)
-- The SYCL compiler is /usr/bin/clang++
-- The SYCL Flags are -fsycl
-- The SYCL Language Version is 202001
-- Found IntelDPCPP: /usr/lib/llvm-14/include (found version "202001")
-- MKL_ARCH: None, set to ` intel64` by default
-- MKL_LINK: None, set to ` dynamic` by default
-- MKL_INTERFACE_FULL: None, set to ` intel_ilp64` by default
-- MKL_THREADING: sequential
-- MKL_MPI: None, set to ` intelmpi` by default
-- Found MKL: intelmpi
-- Found MKL: /opt/intel/oneapi/mkl/2023.1.0
-- Found MKL: /opt/intel/oneapi/mkl/2023.1.0/lib/intel64/libmkl_sycl.so
-- Found MKL: /usr/lib/x86_64-linux-gnu/libmkl_intel_ilp64.so
-- Found MKL: /usr/lib/x86_64-linux-gnu/libmkl_core.so
-- Found MKL: /usr/lib/x86_64-linux-gnu/libmkl_sequential.so
-- Known MKL Targets: MKL::mkl_sycl;MKL::mkl_intel_ilp64;MKL::mkl_core;MKL::mkl_sequential;MKL::MKL_DPCPP;MKL::MKL
-- Configuring done
-- Generating done
-- Build files have been written to: /mnt/md1/linehill/ws-chip-spv-2/builds/mklshim
Also can you confirm if you have oneAPI package(HPC toolkit) installed?
It's installed:
$ sudo apt install intel-hpckit
[sudo] password for linehill:
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
intel-hpckit is already the newest version (2023.1.0-46346).
0 upgraded, 0 newly installed, 0 to remove and 1 not upgraded.
Remember you have to run "intel/oneapi/setvars.sh" every time.
Have done this.
Shim layer needs Intel compiler not clang, can you try "-DCMAKE_CXX_COMPILER=icpx" and let me know if you still see the issue?
icpx
is not working for me:
cd builds/mklshim/ && logsave configure.log cmake \
-DCMAKE_INSTALL_PREFIX=/mnt/md1/linehill/ws-chip-spv-2/install \
-DCMAKE_CXX_COMPILER=icpx \
/mnt/md1/linehill/ws-chip-spv-2/H4I-MKLShim
-- The CXX compiler identification is IntelLLVM 2023.1.0
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - failed
-- Check for working CXX compiler: /opt/intel/oneapi/compiler/2023.1.0/linux/bin/icpx
-- Check for working CXX compiler: /opt/intel/oneapi/compiler/2023.1.0/linux/bin/icpx - broken
CMake Error at /home/linehill/.local/lib/python3.10/site-packages/cmake/data/share/cmake-3.24/Modules/CMakeTestCXXCompiler.cmake:62 (message):
The C++ compiler
"/opt/intel/oneapi/compiler/2023.1.0/linux/bin/icpx"
is not able to compile a simple test program.
It fails with the following output:
Change Dir: /mnt/md1/linehill/ws-chip-spv-2/builds/mklshim/CMakeFiles/CMakeTmp
Run Build Command(s):/usr/bin/gmake -f Makefile cmTC_20305/fast && gmake[1]: Entering directory '/mnt/md1/linehill/ws-chip-spv-2/builds/mklshim/CMakeFiles/CMakeTmp'
/usr/bin/gmake -f CMakeFiles/cmTC_20305.dir/build.make CMakeFiles/cmTC_20305.dir/build
gmake[2]: Entering directory '/mnt/md1/linehill/ws-chip-spv-2/builds/mklshim/CMakeFiles/CMakeTmp'
Building CXX object CMakeFiles/cmTC_20305.dir/testCXXCompiler.cxx.o
/opt/intel/oneapi/compiler/2023.1.0/linux/bin/icpx -MD -MT CMakeFiles/cmTC_20305.dir/testCXXCompiler.cxx.o -MF CMakeFiles/cmTC_20305.dir/testCXXCompiler.cxx.o.d -o CMakeFiles/cmTC_20305.dir/testCXXCompiler.cxx.o -c /mnt/md1/linehill/ws-chip-spv-2/builds/mklshim/CMakeFiles/CMakeTmp/testCXXCompiler.cxx
Linking CXX executable cmTC_20305
/home/linehill/.local/lib/python3.10/site-packages/cmake/data/bin/cmake -E cmake_link_script CMakeFiles/cmTC_20305.dir/link.txt --verbose=1
/opt/intel/oneapi/compiler/2023.1.0/linux/bin/icpx CMakeFiles/cmTC_20305.dir/testCXXCompiler.cxx.o -o cmTC_20305
/usr/bin/ld: cannot find crtbeginS.o: No such file or directory
/usr/bin/ld: cannot find -lstdc++: No such file or directory
icpx: error: linker command failed with exit code 1 (use -v to see invocation)
gmake[2]: *** [CMakeFiles/cmTC_20305.dir/build.make:100: cmTC_20305] Error 1
gmake[2]: Leaving directory '/mnt/md1/linehill/ws-chip-spv-2/builds/mklshim/CMakeFiles/CMakeTmp'
gmake[1]: *** [Makefile:127: cmTC_20305/fast] Error 2
gmake[1]: Leaving directory '/mnt/md1/linehill/ws-chip-spv-2/builds/mklshim/CMakeFiles/CMakeTmp'
CMake will not be able to correctly generate this project.
Call Stack (most recent call first):
CMakeLists.txt:6 (project)
-- Configuring incomplete, errors occurred!
See also "/mnt/md1/linehill/ws-chip-spv-2/builds/mklshim/CMakeFiles/CMakeOutput.log".
See also "/mnt/md1/linehill/ws-chip-spv-2/builds/mklshim/CMakeFiles/CMakeError.log".
cmake exited with status code 1
Makefile:24: recipe for target 'builds/mklshim/configure.stamp' failed
make: *** [builds/mklshim/configure.stamp] Error 1
Did you try using icpx in general? I am trying to understand if this error is specific to this project or icpx compiler in general does not work for you. If icpx/dpcpp compiler does not work for you then I would suggest to fix that.
The ixpc is broken as it won't compile a simple hello world app. There is apparently a bug which is still not fixed. I can work it around by using --gcc-toolchain=/usr
.
fixed? @linehill
MKLShim build fails with following error:
The project was configured as followed: