Skip to content
Merged
Show file tree
Hide file tree
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions include/RAJA/internal/ThreadUtils_CPU.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,9 @@
#include "RAJA/config.hpp"

#include "RAJA/pattern/thread.hpp"
#if defined(RAJA_ENABLE_OPENMP)
#include "RAJA/policy/openmp/thread.hpp"
#endif
#include "RAJA/policy/sequential/thread.hpp"

namespace RAJA
Expand Down
7 changes: 7 additions & 0 deletions include/RAJA/policy/openmp/forall.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,12 @@ forall_impl(resources::Host host_res,
}
else
{
// This branch handles the case of an OpenMP reduction through the RAJA::kernel
// abstraction. MSVC is not supported in this case.
#if defined(RAJA_COMPILER_MSVC)
static_assert(false, "MSVC does not support an OpenMP reduction through "
"the RAJA::kernel abstraction");
#else
auto reducers_tuple = loop_body.data.param_tuple;

using EXEC_POL = camp::decay<InnerPolicy>;
Expand Down Expand Up @@ -110,6 +116,7 @@ forall_impl(resources::Host host_res,
}
}
RAJA::expt::detail::resolve_params<EXEC_POL>(reducers_tuple);
#endif
}
return resources::EventProxy<resources::Host>(host_res);
}
Expand Down
1 change: 1 addition & 0 deletions include/RAJA/policy/thread_auto.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
#include "RAJA/util/macros.hpp"

#ifdef RAJA_OPENMP_ACTIVE
#include <omp.h>
#include "RAJA/policy/openmp/policy.hpp"
#endif

Expand Down