Closed yiakwy-mapping-team closed 2 years ago
@romanovvlad
Hi @yiakwy-mapping-team, thanks for you bug report
A few questions:
After compilation, I try to run one of test cases from "oneAPI-Samples" for reduce operation. It apparently failed.
Could you please attach corresponding logs and reproducer? There is an example of the failed test, but it has nothing to do with DPC++ - it is just a test for llvm-ranlib
utility which is not used by the toolchain as far as I know.
build it in a linux env like Ubuntu 18.04 and run it with a example. Make it as simple as few lines of automation codes in a script
From my point of view this is exactly what we have right now: according tp Build DPC++ toolchain section you need to launch configure.py
script and then compile.py
script and that would be all.
Most libraries in Linux is using gcc not clang.
What is the exact suggestion here? You should be able to compile DPC++ toolchain by both gcc
and clang
Few people now are developing libraries in Make, please switch to CMake or Bazel system.
We do not use make
directly, we use CMake
and you can choose the particular build system by selecting corresponding CMake generator through --cmake-gen
option of configure.py
Tell instructions with complete examples.
This is also present in Get Started Guide, see Run simple DPC++ application
@alexey-bataev
Use DPC++ toolchain
Yes I can compile but it is not very clear what which version of gcc used by the project.
According to https://intel.github.io/llvm-docs/GetStartedGuide.html#prerequisites
Linux: GCC version 7.1.0 or later (including libstdc++)
Or are we talking about device/host compilation of the actual DPCPP code and not compilation of the compilator? I'm confused.
I mean there is no FindDPC shipped. How I can use them in a third-party cmake system?
Just like you'd use any other compiler: either by setting CC=clang
and CXX=clang++
(on Linux), or by passing -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++
(also linux) or -DCMAKE_C_COMPILER=clang-cl -DCMAKE_CXX_COMPILER=clang-cl
(windows) flags to cmake configuration line. Just make sure that clang
is actually clang executable, that was result of building this repository code.
I mean there is no FindDPC shipped. How I can use them in a third-party cmake system?
Yes, this is a missing thing for sure. Related feature request is #1000 - if you have particular suggestions feel free to post them there.
I see that there was an attempt to add FindSYCL
into CMake
distribution here, but it doesn't seem to be finished due to some design concerns.
Meanwhile, you can configure C
/CXX
compiler as @alexbatashev suggested. Here is an example of how it is done in official oneAPI samples.
@yiakwy-mapping-team, is there something else you would like to ask/clarify? Can we close this issue?
I assume that we have answered all questions and therefor I'm closing the issue. @yiakwy-mapping-team, if that is not the case, feel free to re-open or open a new one for further questions
What is going on
Here is an instruction from intel how to configure latest DPC++ in a new machine:
From "Build DPC++ toolchain" and "Use DPC++ toolchain" , they just don't tell it clear how to build and test the DPC++ libraries.
After compilation, I try to run one of test cases from "oneAPI-Samples" for reduce operation. It apparently failed.
Expected
Build test failed:
OS : Ubuntu 18.04 docker OS, with necessary build essential toolkit gcc : 7.5 cmake : 3.19
Suggestion
Also see https://github.com/oneapi-src/oneDPL/issues/256#issuecomment-848595269