20 #ifndef RAJA_pattern_tensor_ET_TensorLoadStore_HPP
21 #define RAJA_pattern_tensor_ET_TensorLoadStore_HPP
23 #include "RAJA/config.hpp"
42 template<
typename STORAGE,
typename LHS_TYPE,
typename RHS_TYPE>
48 template<
typename TILE_TYPE>
64 template<
typename STORAGE,
typename LHS_TYPE,
typename RHS_TYPE>
72 template<
typename TENSOR_TYPE,
typename REF_TYPE>
85 static constexpr camp::idx_t
s_num_dims = result_type::s_num_dims;
108 printf(
"TensorLoadStore: ");
109 m_ref.m_tile.print();
123 template<
typename RHS>
133 template<
typename RHS>
141 template<
typename RHS>
149 template<
typename RHS>
157 template<
typename RHS>
165 template<
typename TILE_TYPE>
173 template<
typename TILE_TYPE>
175 -> decltype(TENSOR_TYPE::create_et_store_ref(
merge_ref_tile(this->m_ref,
186 return m_ref.m_tile.m_size[dim];
198 tile_type const& getTile()
const {
return m_ref.m_tile; }
200 template<
typename RHS>
203 #ifdef RAJA_DEBUG_PRINT_ET_AST
209 tensorTileExec<tensor_type>(
210 m_ref.m_tile, makeTensorStoreFunctor<tensor_type>(*
this, rhs));
RAJA header file defining SIMD/SIMT register operations.
RAJA header file defining SIMD/SIMT register operations.
Definition: BinaryOperator.hpp:46
Definition: TensorDivide.hpp:320
Definition: ExpressionTemplateBase.hpp:72
Definition: TensorLoadStore.hpp:75
RAJA_INLINE RAJA_HOST_DEVICE TensorLoadStore(ref_type const &ref)
Definition: TensorLoadStore.hpp:96
RAJA_SUPPRESS_HD_WARN RAJA_HOST_DEVICE RAJA_INLINE self_type operator*=(RHS const &rhs)
Definition: TensorLoadStore.hpp:150
TENSOR_TYPE tensor_type
Definition: TensorLoadStore.hpp:78
RAJA_SUPPRESS_HD_WARN RAJA_HOST_DEVICE RAJA_INLINE self_type & operator-=(RHS const &rhs)
Definition: TensorLoadStore.hpp:142
typename REF_TYPE::tile_type tile_type
Definition: TensorLoadStore.hpp:82
RAJA_SUPPRESS_HD_WARN RAJA_HOST_DEVICE RAJA_INLINE self_type operator/=(RHS const &rhs)
Definition: TensorLoadStore.hpp:158
TENSOR_TYPE result_type
Definition: TensorLoadStore.hpp:83
static constexpr camp::idx_t s_num_dims
Definition: TensorLoadStore.hpp:85
typename TENSOR_TYPE::element_type element_type
Definition: TensorLoadStore.hpp:79
RAJA_HOST_DEVICE RAJA_INLINE self_type & operator=(RHS const &rhs)
Definition: TensorLoadStore.hpp:124
RAJA_INLINE RAJA_HOST_DEVICE void print() const
Definition: TensorLoadStore.hpp:106
typename REF_TYPE::index_type index_type
Definition: TensorLoadStore.hpp:80
RAJA_SUPPRESS_HD_WARN RAJA_INLINE RAJA_HOST_DEVICE auto eval(TILE_TYPE const &tile) const -> decltype(tensor_type::s_load_ref(merge_ref_tile(m_ref, tile)))
Definition: TensorLoadStore.hpp:166
RAJA_INLINE RAJA_HOST_DEVICE void print_ast() const
Definition: TensorLoadStore.hpp:192
RAJA_INLINE constexpr RAJA_HOST_DEVICE index_type getDimSize(index_type dim) const
Definition: TensorLoadStore.hpp:184
RAJA_SUPPRESS_HD_WARN RAJA_HOST_DEVICE RAJA_INLINE self_type & operator+=(RHS const &rhs)
Definition: TensorLoadStore.hpp:134
RAJA_SUPPRESS_HD_WARN RAJA_INLINE RAJA_HOST_DEVICE auto eval_lhs(TILE_TYPE const &tile) const -> decltype(TENSOR_TYPE::create_et_store_ref(merge_ref_tile(this->m_ref, tile)))
Definition: TensorLoadStore.hpp:174
REF_TYPE ref_type
Definition: TensorLoadStore.hpp:81
RAJA_HOST_DEVICE RAJA_INLINE self_type & operator=(self_type const &rhs)
Definition: TensorLoadStore.hpp:116
RAJA_INLINE RAJA_HOST_DEVICE TensorLoadStore(self_type const &rhs)
Definition: TensorLoadStore.hpp:101
Definition: TensorMultiply.hpp:50
Header file for common RAJA internal macro definitions.
#define RAJA_HOST_DEVICE
Definition: macros.hpp:65
#define RAJA_SUPPRESS_HD_WARN
Definition: macros.hpp:68
RAJA_INLINE RAJA_HOST_DEVICE auto normalizeOperand(RHS const &rhs) -> typename NormalizeOperandHelper< RHS >::return_type
Definition: normalizeOperand.hpp:73
RAJA_HOST_DEVICE constexpr RAJA_INLINE auto makeTensorStoreFunctor(LHS_TYPE const &lhs, RHS_TYPE const &rhs) -> TensorStoreFunctor< STORAGE, LHS_TYPE, RHS_TYPE >
Definition: TensorLoadStore.hpp:65
RAJA_INLINE constexpr RAJA_HOST_DEVICE auto merge_ref_tile(REF_TYPE const &ref, TILE_TYPE const &tile) -> typename MergeRefTile< REF_TYPE, TILE_TYPE, camp::make_idx_seq_t< TILE_TYPE::s_num_dims >>::merge_type
Definition: TensorRef.hpp:682
Definition: AlignedRangeIndexSetBuilders.cpp:35
RAJA_HOST_DEVICE RAJA_INLINE void tile(CONTEXT const &ctx, TILE_T tile_size, SEGMENT const &segment, BODY const &body)
Definition: launch_core.hpp:589
Definition: TensorLoadStore.hpp:44
RHS_TYPE const & m_rhs
Definition: TensorLoadStore.hpp:46
RAJA_HOST_DEVICE RAJA_INLINE void operator()(TILE_TYPE const &tile) const
Definition: TensorLoadStore.hpp:49
LHS_TYPE const & m_lhs
Definition: TensorLoadStore.hpp:45