Fix the LLVM build when using intel compilers (#50226)

* [llvm] Fix the LLVM build when using intel compilers

* [@spackbot] updating style on behalf of v-dobrev

* e4s oneapi ci stack: re-enable specs disabled due to llvm%oneapi issue #49625

* disable paraview

* disable failing oneapi specs

* disable additional failing oneapi spec

---------

Co-authored-by: eugeneswalker <eugenesunsetwalker@gmail.com>
This commit is contained in:
Veselin Dobrev 2025-05-01 16:46:48 -07:00 committed by GitHub
parent 6a0e03b81c
commit 95c26245c1
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 14 additions and 8 deletions

View File

@ -173,11 +173,11 @@ spack:
- vtk-m ~openmp # +openmp: https://github.com/spack/spack/issues/31830
- zfp
# --
# - paraview +qt # llvm-17.0.6: https://github.com/spack/spack/issues/49625
# - py-cinemasci # llvm-14.0.6: https://github.com/spack/spack/issues/49625
# - visit # llvm-17.0.6: https://github.com/spack/spack/issues/49625
# - paraview +qt # concretize: paraview: Qt support requires GLX on non Windows; llvm-17.0.6: https://github.com/spack/spack/issues/49625
# - py-cinemasci # py-maturin-1.8.3: rust-lld: error: undefined symbol: _intel_fast_memcpy
# - visit # vtk-9.2.6: ??
# --
# - chapel ~cuda ~rocm # llvm-19.1.7: https://github.com/spack/spack/issues/49625
# - chapel ~cuda ~rocm # chapel-2.4.0: KeyError: 'intel-oneapi-compilers': /builds/spack/spack/var/spack/repos/builtin/packages/chapel/package.py:602, in setup_chpl_compilers: env.set("CHPL_HOST_COMPILER", self.compiler_map[self.spec.compiler.name])
# - cp2k +mpi # dbcsr-2.8.0: FAILED: src/CMakeFiles/dbcsr.dir/dbcsr_api.F-pp.f src/CMakeFiles/dbcsr.dir/dbcsr_api.F.o.ddi:
# - dealii # taskflow@3.7.0: cmake: Taskflow currently supports the following compilers: g++ v7.0 or above, clang++ v6.0 or above
# - exago +mpi ~ipopt +hiop ~python +raja ^hiop+raja~sparse # raja-0.14.0: RAJA/pattern/kernel/Tile.hpp:174:30: error: no member named 'block_id' in 'IterableTiler<Iterable>'
@ -185,8 +185,8 @@ spack:
# - fftx # fftx-1.2.0: https://github.com/spack/spack/issues/49621
# - fpm # fpm-0.10.0: /tmp/ifx1305151083OkWTRB/ifxqBG60i.i90: error #6405: The same named entity from different modules and/or program units cannot be referenced. [TOML_TABLE]; fpm.F90(32048): error #7002: Error in opening the compiled module file. Check INCLUDE paths. [FPM_MANIFEST_PREPROCESS]
# - geopm-runtime # concretize: c-blosc2: conflicts with '%oneapi';
# - glvis # llvm-17.0.6: https://github.com/spack/spack/issues/49625
# - gptune ~mpispawn # llvm-14.0.6: https://github.com/spack/spack/issues/49625
- glvis # llvm-17.0.6: https://github.com/spack/spack/issues/49625
# - gptune ~mpispawn # py-maturin-1.8.3: rust-lld: error: undefined symbol: __intel_cpu_feature_indicator_x
# - lbann # lbann-0.104: https://github.com/spack/spack/issues/49619
# - libpressio +bitgrooming +bzip2 ~cuda ~cusz +fpzip +hdf5 +libdistributed +lua +openmp +python +sz +sz3 +unix +zfp # concretize: c-blosc2: conflicts with '%oneapi';
# - nek5000 +mpi ~visit # nek5000-19.0: RuntimeError: Cannot build example: short_tests/eddy.
@ -209,8 +209,8 @@ spack:
# --
# - py-jupyterlab # py-maturin: rust-lld: error: undefined symbol: _intel_fast_memcpy
# - py-notebook # py-maturin: rust-lld: error: undefined symbol: _intel_fast_memcpy
# - py-numba # llvm-14.0.6: https://github.com/spack/spack/issues/49625
# - py-pandas # llvm-14.0.6: https://github.com/spack/spack/issues/49625
- py-numba # llvm-14.0.6: https://github.com/spack/spack/issues/49625
- py-pandas # llvm-14.0.6: https://github.com/spack/spack/issues/49625
# - py-plotly # py-maturin: rust-lld: error: undefined symbol: _intel_fast_memcpy
- aml +level_zero

View File

@ -951,6 +951,12 @@ def setup_build_environment(self, env: EnvironmentModifications) -> None:
# set the SDKROOT so the bootstrap compiler finds its C++ headers
env.set("SDKROOT", macos_sdk_path())
if self.spec.satisfies("%intel-oneapi-compilers"):
intel_libs = find_libraries(
["libsvml", "libimf", "libirc"], self.spec["intel-oneapi-runtime"].prefix.lib
)
env.append_flags("LDFLAGS", intel_libs.ld_flags)
def setup_run_environment(self, env: EnvironmentModifications) -> None:
if self.spec.satisfies("+clang"):
env.set("CC", join_path(self.spec.prefix.bin, "clang"))