From b731b186a7a3875088351d6e5989a151f463d2d8 Mon Sep 17 00:00:00 2001 From: Simeon Ehrig Date: Tue, 7 Jan 2025 09:52:36 +0100 Subject: [PATCH] alpaka job generator: add rule which requires that the sycl backend is enabled if icpx is the compiler --- script/before_install.sh | 9 +++++++++ script/job_generator/alpaka_filter.py | 7 +++++++ 2 files changed, 16 insertions(+) diff --git a/script/before_install.sh b/script/before_install.sh index b3c8a807674..0e61d47cbe6 100755 --- a/script/before_install.sh +++ b/script/before_install.sh @@ -90,6 +90,15 @@ then fi fi +#------------------------------------------------------------------------------- +# ONEAPI +if [[ "${ALPAKA_CI_CXX}" == "icpx" ]]; then + if [[ "${alpaka_ACC_SYCL_ENABLE}" != "ON" ]]; then + echo_red "alpaka_ACC_SYCL_ENABLE needs to be enabled, if the C++ compiler is icpx" + exit 1 + fi +fi + #------------------------------------------------------------------------------- if [ "$ALPAKA_CI_OS_NAME" = "Linux" ] then diff --git a/script/job_generator/alpaka_filter.py b/script/job_generator/alpaka_filter.py index 277baef9ddb..c041be489be 100644 --- a/script/job_generator/alpaka_filter.py +++ b/script/job_generator/alpaka_filter.py @@ -135,4 +135,11 @@ def alpaka_post_filter(row: List) -> bool: ): return False + # the SYCL backends needs to be enabled if the icpx compiler is used + if row_check_name(row, DEVICE_COMPILER, "==", ICPX): + if is_in_row(row, BACKENDS) and ( + (ALPAKA_ACC_SYCL_ENABLE, ON_VER) not in row[param_map[BACKENDS]] + ): + return False + return True