Skip to content

Commit

Permalink
CI: IntelLLVM known to CMake (AMReX-Codes#2136)
Browse files Browse the repository at this point in the history
## Summary

`IntelLLVM` is now a recognized CMake compiler, so we don't need to add a Clang-ish identification anymore.

Also fix a CMake -Wdev warning (DPC++/SYCL)

-  beta08 work-around: `-mlong-double-64` (intel/llvm#2187) -> still needed!
- beta09 work-around: `-fno-sycl-early-optimizations` (link to upstream issue?) -> keep for now, RT tests pending to verify fix

## Additional background

setting the CXX compiler ID was a work-around for the 2021.1 DPC++ release / CMake 3.19.0-3.19.1
  https://gitlab.kitware.com/cmake/cmake/-/issues/21551#note_869580
  • Loading branch information
ax3l authored Jul 19, 2021
1 parent 98c9e71 commit 388ce7e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 8 deletions.
8 changes: 1 addition & 7 deletions .github/workflows/intel.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,21 +18,15 @@ jobs:
source /opt/intel/oneapi/setvars.sh
set -e
cmake -S . -B build \
-DCMAKE_CXX_COMPILER_ID="Clang" \
-DCMAKE_CXX_COMPILER_VERSION=12.0 \
-DCMAKE_CXX_STANDARD_COMPUTED_DEFAULT="17" \
-DCMAKE_VERBOSE_MAKEFILE=ON \
-DAMReX_ENABLE_TESTS=ON \
-DAMReX_FORTRAN=OFF \
-DAMReX_FORTRAN=ON \
-DAMReX_PARTICLES=ON \
-DAMReX_GPU_BACKEND=SYCL \
-DCMAKE_C_COMPILER=$(which clang) \
-DCMAKE_CXX_COMPILER=$(which dpcpp) \
-DCMAKE_Fortran_COMPILER=$(which gfortran)
cmake --build build --parallel 2
# note: setting the CXX compiler ID is a work-around for
# the 2021.1 DPC++ release / CMake 3.19.0-3.19.1
# https://gitlab.kitware.com/cmake/cmake/-/issues/21551#note_869580
# "Classic" EDG Intel Compiler
# Ref.: https://github.com/rscohn2/oneapi-ci
Expand Down
3 changes: 2 additions & 1 deletion Tools/CMake/AMReXSYCL.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,8 @@ target_compile_options( SYCL
# https://github.com/intel/llvm/issues/2187
target_compile_options( SYCL
INTERFACE
$<${_cxx_dpcpp}:-mlong-double-64 "SHELL:-Xclang -mlong-double-64">)
"$<${_cxx_dpcpp}:-mlong-double-64>"
"$<${_cxx_dpcpp}:SHELL:-Xclang -mlong-double-64>")

# Beta09 has enabled eary optimizations by default. But this causes many
# tests to crash. So we disable it.
Expand Down

0 comments on commit 388ce7e

Please sign in to comment.