20 #ifndef RAJA_scan_sequential_HPP
21 #define RAJA_scan_sequential_HPP
23 #include "RAJA/config.hpp"
45 template<
typename ExecPolicy,
typename Iter,
typename BinFn>
46 RAJA_INLINE concepts::enable_if_t<resources::EventProxy<resources::Host>,
47 type_traits::is_sequential_policy<ExecPolicy>>
54 using ValueT =
typename std::remove_reference<decltype(*begin)>::type;
57 for (Iter i = ++begin; i != end; ++i)
63 return resources::EventProxy<resources::Host>(host_res);
70 template<
typename ExecPolicy,
typename Iter,
typename BinFn,
typename T>
71 RAJA_INLINE concepts::enable_if_t<resources::EventProxy<resources::Host>,
81 const auto n = distance(begin, end);
82 using DistanceT =
typename std::remove_const<decltype(n)>::type;
84 using ValueT =
typename std::remove_reference<decltype(*begin)>::type;
87 for (DistanceT i = 0; i < n; ++i)
94 return resources::EventProxy<resources::Host>(host_res);
101 template<
typename ExecPolicy,
typename Iter,
typename OutIter,
typename BinFn>
102 RAJA_INLINE concepts::enable_if_t<resources::EventProxy<resources::Host>,
111 using ValueT =
typename std::remove_reference<decltype(*out)>::type;
115 for (Iter i = begin + 1; i != end; ++i)
121 return resources::EventProxy<resources::Host>(host_res);
133 RAJA_INLINE concepts::enable_if_t<resources::EventProxy<resources::Host>,
143 using ValueT =
typename std::remove_reference<decltype(*out)>::type;
148 for (Iter i = begin; i != end - 1; ++i, ++o)
154 return resources::EventProxy<resources::Host>(host_res);
Header file for RAJA concept definitions.
Header file for common RAJA internal macro definitions.
RAJA_INLINE concepts::enable_if_t< resources::EventProxy< resources::Host >, type_traits::is_openmp_policy< Policy > > inclusive(resources::Host host_res, const Policy &exec, Iter begin, Iter end, OutIter out, BinFn f)
Definition: scan.hpp:144
RAJA_INLINE concepts::enable_if_t< resources::EventProxy< resources::Host >, type_traits::is_openmp_policy< Policy > > exclusive(resources::Host host_res, const Policy &exec, Iter begin, Iter end, OutIter out, BinFn f, ValueT v)
Definition: scan.hpp:167
RAJA_INLINE concepts::enable_if_t< resources::EventProxy< resources::Host >, type_traits::is_openmp_policy< Policy > > inclusive_inplace(resources::Host host_res, const Policy &, Iter begin, Iter end, BinFn f)
Definition: scan.hpp:51
RAJA_INLINE concepts::enable_if_t< resources::EventProxy< resources::Host >, type_traits::is_openmp_policy< Policy > > exclusive_inplace(resources::Host host_res, const Policy &, Iter begin, Iter end, BinFn f, ValueT v)
Definition: scan.hpp:96
Definition: AlignedRangeIndexSetBuilders.cpp:35
Header file containing RAJA sequential policy definitions.
Definition: IndexSet.hpp:70
Definition: PolicyBase.hpp:207