Skip to content

Commit

Permalink
Merge branch 'develop' into task/rhornung67/switch2github-actions
Browse files Browse the repository at this point in the history
  • Loading branch information
rhornung67 committed Jul 22, 2024
2 parents e26cd5a + 819260b commit 75ded62
Show file tree
Hide file tree
Showing 5 changed files with 34 additions and 4 deletions.
2 changes: 1 addition & 1 deletion include/RAJA/policy/sycl.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@

#if defined(RAJA_SYCL_ACTIVE)

#include <CL/sycl.hpp>
#include "RAJA/util/sycl_compat.hpp"

#include "RAJA/policy/sycl/forall.hpp"
#include "RAJA/policy/sycl/policy.hpp"
Expand Down
2 changes: 1 addition & 1 deletion include/RAJA/policy/sycl/MemUtils_SYCL.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@

#if defined(RAJA_ENABLE_SYCL)

#include <CL/sycl.hpp>
#include "RAJA/util/sycl_compat.hpp"

#include <cassert>
#include <cstddef>
Expand Down
3 changes: 2 additions & 1 deletion include/RAJA/policy/sycl/forall.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,11 @@

#if defined(RAJA_ENABLE_SYCL)

#include <CL/sycl.hpp>
#include <algorithm>
#include <chrono>

#include "RAJA/util/sycl_compat.hpp"

#include "RAJA/pattern/forall.hpp"

#include "RAJA/pattern/params/forall.hpp"
Expand Down
2 changes: 1 addition & 1 deletion include/RAJA/policy/sycl/policy.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@

#if defined(RAJA_SYCL_ACTIVE)

#include <CL/sycl.hpp>
#include "RAJA/util/sycl_compat.hpp"

#include "RAJA/policy/PolicyBase.hpp"
#include "RAJA/policy/sequential/policy.hpp"
Expand Down
29 changes: 29 additions & 0 deletions include/RAJA/util/sycl_compat.hpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
/*!
******************************************************************************
*
* \file
*
* \brief RAJA header file for handling different SYCL header include paths
*
******************************************************************************
*/

//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~//
// Copyright (c) 2016-24, Lawrence Livermore National Security, LLC
// and RAJA project contributors. See the RAJA/LICENSE file for details.
//
// SPDX-License-Identifier: (BSD-3-Clause)
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~//

#ifndef RAJA_util_sycl_compat_HPP
#define RAJA_util_sycl_compat_HPP

#if (__INTEL_CLANG_COMPILER && __INTEL_CLANG_COMPILER < 20230000)
// older version, use legacy header locations
#include <CL/sycl.hpp>
#else
// SYCL 2020 standard header
#include <sycl/sycl.hpp>
#endif

#endif // RAJA_util_sycl_compat_HPP

0 comments on commit 75ded62

Please sign in to comment.