42 #ifndef KOKKOS_VIEW_UTILS_DEF_HPP
43 #define KOKKOS_VIEW_UTILS_DEF_HPP
46 #include "Kokkos_ExecPolicy.hpp"
47 #include "Kokkos_Parallel.hpp"
55 template <
class OutputView,
typename Enabled>
56 struct StokhosViewFill
64 KOKKOS_INLINE_FUNCTION
67 const size_t n1 =
output.extent(1);
68 const size_t n2 =
output.extent(2);
69 const size_t n3 =
output.extent(3);
70 const size_t n4 =
output.extent(4);
71 const size_t n5 =
output.extent(5);
72 const size_t n6 =
output.extent(6);
73 const size_t n7 =
output.extent(7);
75 for (
size_t i1 = 0 ; i1 < n1 ; ++i1 ) {
76 for (
size_t i2 = 0 ; i2 < n2 ; ++i2 ) {
77 for (
size_t i3 = 0 ; i3 < n3 ; ++i3 ) {
78 for (
size_t i4 = 0 ; i4 < n4 ; ++i4 ) {
79 for (
size_t i5 = 0 ; i5 < n5 ; ++i5 ) {
80 for (
size_t i6 = 0 ; i6 < n6 ; ++i6 ) {
81 for (
size_t i7 = 0 ; i7 < n7 ; ++i7 ) {
89 const size_t n0 =
output.extent(0);
90 Kokkos::RangePolicy<execution_space> policy( 0, n0 );
91 Kokkos::parallel_for( policy, *
this );
92 execution_space::fence();
99 #endif // KOKKOS_VIEW_UTILS_DEF_HPP
Kokkos::DefaultExecutionSpace execution_space
KOKKOS_INLINE_FUNCTION void operator()(const size_t i0) const
OutputView::const_value_type const_value_type
OutputView::execution_space execution_space
StokhosViewFill(const OutputView &arg_out, const_value_type &arg_in)