20 #ifndef RAJA_pattern_tensor_ET_TensorMultiply_HPP
21 #define RAJA_pattern_tensor_ET_TensorMultiply_HPP
23 #include "RAJA/config.hpp"
41 template<
typename LEFT_OPERAND_TYPE,
42 typename RIGHT_OPERAND_TYPE,
44 class TensorMultiplyAdd;
46 template<
typename LEFT_OPERAND_TYPE,
typename RIGHT_OPERAND_TYPE>
49 TensorMultiply<LEFT_OPERAND_TYPE, RIGHT_OPERAND_TYPE>>
58 using index_type =
typename LEFT_OPERAND_TYPE::index_type;
73 : m_left_operand {left_operand},
74 m_right_operand {right_operand}
85 template<
typename TILE_TYPE>
100 return m_left_operand;
111 return m_right_operand;
118 template<
typename ADD>
137 m_left_operand.print_ast();
139 m_right_operand.print_ast();
151 typename std::enable_if<std::is_arithmetic<LHS>::value,
bool>::type =
true,
152 typename std::enable_if<
153 std::is_base_of<TensorExpressionConcreteBase, RHS>::value,
156 RHS
const& right_operand)
RAJA header file defining SIMD/SIMT register operations.
RAJA header defining expression template behavior for operator*.
Definition: ExpressionTemplateBase.hpp:72
Definition: TensorMultiplyAdd.hpp:56
Definition: TensorMultiply.hpp:50
typename LEFT_OPERAND_TYPE::index_type index_type
Definition: TensorMultiply.hpp:58
RAJA_INLINE RAJA_HOST_DEVICE auto eval(TILE_TYPE const &tile) const -> decltype(multiply_op::multiply(tile, m_left_operand, m_right_operand))
Definition: TensorMultiply.hpp:86
typename LEFT_OPERAND_TYPE::element_type element_type
Definition: TensorMultiply.hpp:57
typename multiply_op::result_type result_type
Definition: TensorMultiply.hpp:60
RAJA_INLINE constexpr RAJA_HOST_DEVICE left_operand_type const & getLeftOperand() const
Definition: TensorMultiply.hpp:98
RAJA_INLINE constexpr RAJA_HOST_DEVICE int getDimSize(int dim) const
Definition: TensorMultiply.hpp:80
RIGHT_OPERAND_TYPE right_operand_type
Definition: TensorMultiply.hpp:54
RAJA_INLINE constexpr RAJA_HOST_DEVICE right_operand_type const & getRightOperand() const
Definition: TensorMultiply.hpp:109
LEFT_OPERAND_TYPE left_operand_type
Definition: TensorMultiply.hpp:53
static constexpr camp::idx_t s_num_dims
Definition: TensorMultiply.hpp:61
RAJA_SUPPRESS_HD_WARN RAJA_INLINE RAJA_HOST_DEVICE TensorMultiplyAdd< left_operand_type, right_operand_type, normalize_operand_t< ADD > > operator+(ADD const &add) const
Definition: TensorMultiply.hpp:122
RAJA_INLINE RAJA_HOST_DEVICE void print_ast() const
Definition: TensorMultiply.hpp:132
RAJA_INLINE RAJA_HOST_DEVICE TensorMultiply(left_operand_type const &left_operand, right_operand_type const &right_operand)
Definition: TensorMultiply.hpp:71
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_INLINE RAJA_HOST_DEVICE auto operator*(LHS const &left_operand, RHS const &right_operand) -> TensorMultiply< typename NormalizeOperandHelper< LHS >::return_type, RHS >
Definition: TensorMultiply.hpp:155
typename NormalizeOperandHelper< RHS >::return_type normalize_operand_t
Definition: normalizeOperand.hpp:80
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: MultiplyOperator.hpp:48
RAJA_INLINE static RAJA_HOST_DEVICE auto multiply(TILE_TYPE const &tile, LEFT_OPERAND_TYPE const &left, RIGHT_OPERAND_TYPE const &right) -> decltype(left.eval(tile) *right.eval(tile))
Definition: MultiplyOperator.hpp:76
static constexpr camp::idx_t s_num_dims
Definition: MultiplyOperator.hpp:51
typename LEFT_OPERAND_TYPE::result_type result_type
Definition: MultiplyOperator.hpp:50
RAJA_INLINE static RAJA_HOST_DEVICE void print_ast()
Definition: MultiplyOperator.hpp:56
RAJA_INLINE static RAJA_HOST_DEVICE int getDimSize(int dim, LEFT_OPERAND_TYPE const &left, RIGHT_OPERAND_TYPE const &right)
Definition: MultiplyOperator.hpp:65
Definition: normalizeOperand.hpp:44