21 #ifndef RAJA_IndexSetUtils_HPP
22 #define RAJA_IndexSetUtils_HPP
24 #include "RAJA/config.hpp"
49 template<
typename CONTAINER_T,
typename... SEG_TYPES>
54 forall<ExecPolicy<seq_segit, seq_exec>>(
55 iset, [&](
typename CONTAINER_T::value_type idx) {
68 template<
typename CONTAINER_T,
typename SEGMENT_T>
69 RAJA_INLINE
void getIndices(CONTAINER_T& con,
const SEGMENT_T& seg)
72 forall<seq_exec>(seg, [&](
typename CONTAINER_T::value_type idx) {
86 template<
typename CONTAINER_T,
typename... SEG_TYPES,
typename CONDITIONAL>
89 CONDITIONAL conditional)
92 forall<ExecPolicy<seq_segit, seq_exec>>(
93 iset, [&](
typename CONTAINER_T::value_type idx) {
94 if (conditional(idx)) tcon.push_back(idx);
107 template<
typename CONTAINER_T,
typename SEGMENT_T,
typename CONDITIONAL>
109 const SEGMENT_T& seg,
110 CONDITIONAL conditional)
113 forall<seq_exec>(seg, [&](
typename CONTAINER_T::value_type idx) {
114 if (conditional(idx)) tcon.push_back(idx);
Definition: IndexSet.hpp:52
Definition: AlignedRangeIndexSetBuilders.cpp:35
RAJA_INLINE void getIndicesConditional(CONTAINER_T &con, const TypedIndexSet< SEG_TYPES... > &iset, CONDITIONAL conditional)
Copy all indices in given index set that satisfy given conditional to given container.
Definition: IndexSetUtils.hpp:87
RAJA_INLINE void getIndices(CONTAINER_T &con, const TypedIndexSet< SEG_TYPES... > &iset)
Copy all indices in given index set to given container.
Definition: IndexSetUtils.hpp:50
Header file containing RAJA index set and segment iteration template methods that take an execution p...
Header file containing RAJA headers for sequential execution.