10 #ifndef KOKKOS_LAYOUT_CONTIGUOUS_HPP
11 #define KOKKOS_LAYOUT_CONTIGUOUS_HPP
15 #ifndef KOKKOS_IMPL_PUBLIC_INCLUDE
16 #define KOKKOS_IMPL_PUBLIC_INCLUDE
17 #define KOKKOS_IMPL_PUBLIC_INCLUDE_NOTDEFINED_CORE
19 #include "Kokkos_Core_fwd.hpp"
20 #include "Kokkos_Layout.hpp"
21 #ifdef KOKKOS_IMPL_PUBLIC_INCLUDE_NOTDEFINED_CORE
22 #undef KOKKOS_IMPL_PUBLIC_INCLUDE
23 #undef KOKKOS_IMPL_PUBLIC_INCLUDE_NOTDEFINED_CORE
30 template <
typename Layout,
unsigned Str
ide = 1>
41 KOKKOS_INLINE_FUNCTION
43 KOKKOS_INLINE_FUNCTION
46 KOKKOS_INLINE_FUNCTION
50 #ifdef SACADO_HAS_NEW_KOKKOS_VIEW_IMPL
52 template <
class Layout,
unsigned Str
ide>
53 struct LayoutFromArrayLayout<LayoutContiguous<Layout, Stride>> {
54 using type =
typename LayoutFromArrayLayout<Layout>::type;
60 template <
class Layout>
62 static const bool value =
false;
65 template <
class Layout,
unsigned Str
ide>
71 template <
class Layout>
76 template <
class Layout>
81 template <
class Layout,
unsigned Str
ide>
92 template <
class Layout,
unsigned Str
ide>
93 struct is_same< Kokkos::LayoutContiguous<Layout,Stride>, Layout> {
97 template <
class Layout,
unsigned Str
ide>
98 #if defined(KOKKOS_COMPILER_INTEL)
99 inline constexpr
bool is_same_v< Kokkos::LayoutContiguous<Layout,Stride>, Layout> = is_same<Kokkos::LayoutContiguous<Layout,Stride>, Layout>
::value;
101 static constexpr
bool is_same_v< Kokkos::LayoutContiguous<Layout,Stride>, Layout> = is_same<Kokkos::LayoutContiguous<Layout,Stride>, Layout>
::value;
104 template <
class Layout,
unsigned Str
ide>
105 struct is_same< Layout, Kokkos::LayoutContiguous<Layout,Stride> > {
109 template <
class Layout,
unsigned Str
ide>
110 #if defined(KOKKOS_COMPILER_INTEL)
111 inline constexpr
bool is_same_v< Layout, Kokkos::LayoutContiguous<Layout,Stride>> = is_same<Kokkos::LayoutContiguous<Layout,Stride>, Layout>
::value;
113 static constexpr
bool is_same_v< Layout, Kokkos::LayoutContiguous<Layout,Stride>> = is_same<Kokkos::LayoutContiguous<Layout,Stride>, Layout>
::value;
117 #if KOKKOS_VERSION >= 40499
118 #include "View/Kokkos_ViewMapping.hpp"
120 #include "impl/Kokkos_ViewMapping.hpp"
127 template <
class Dimension ,
class Layout ,
unsigned Str
ide >
129 :
public ViewOffset<Dimension,Layout> {
135 typedef ViewOffset<Dimension,Layout>
Base;
137 ViewOffset() = default ;
138 ViewOffset(
const ViewOffset & ) = default ;
139 ViewOffset & operator = (
const ViewOffset & ) = default ;
143 template <
typename Arg1>
144 KOKKOS_INLINE_FUNCTION
147 template <
typename Arg1,
typename Arg2>
148 KOKKOS_INLINE_FUNCTION
152 template <
typename Layout>
158 template <
typename Layout,
unsigned Str
ide>
167 #endif // #ifndef KOKKOS_LAYOUT_CONTIGUOUS_HPP
static const bool is_unit_stride
KOKKOS_INLINE_FUNCTION Layout base_layout() const
KOKKOS_INLINE_FUNCTION constexpr ViewOffset(const Arg1 &arg1)
static const unsigned stride
KOKKOS_INLINE_FUNCTION constexpr LayoutContiguous(Layout const &layout)
KOKKOS_INLINE_FUNCTION constexpr ViewOffset(const Arg1 &arg1, const Arg2 &arg2)
LayoutContiguous array_layout
Tag this class as a kokkos array layout.
KOKKOS_INLINE_FUNCTION constexpr LayoutContiguous(Layout &&layout)
ViewOffset< Dimension, Layout > Base