35 #ifndef _BLAZE_MATH_EXPRESSIONS_DMATSMATMULTEXPR_H_
36 #define _BLAZE_MATH_EXPRESSIONS_DMATSMATMULTEXPR_H_
124 template<
typename MT1
157 template<
typename T1,
typename T2,
typename T3 >
158 struct CanExploitSymmetry {
159 enum { value = ( IsSymmetric<T2>::value || IsSymmetric<T3>::value ) };
170 template<
typename T1,
typename T2,
typename T3 >
171 struct IsEvaluationRequired {
172 enum { value = ( evaluateLeft || evaluateRight ) &&
173 !CanExploitSymmetry<T1,T2,T3>::value };
183 template<
typename T1,
typename T2,
typename T3 >
184 struct UseOptimizedKernel {
186 !IsDiagonal<T2>::value &&
187 !IsResizable<typename T1::ElementType>::value };
197 template<
typename T1,
typename T2,
typename T3 >
198 struct UseDefaultKernel {
199 enum { value = !UseOptimizedKernel<T1,T2,T3>::value };
229 enum { vectorizable = 0 };
232 enum { smpAssignable = !evaluateLeft && MT1::smpAssignable &&
233 !evaluateRight && MT2::smpAssignable };
276 :(
lhs_.columns() ) ) );
278 if(
lhs_.columns() == 0UL ||
282 ElementType tmp(
lhs_(i,kbegin) *
rhs_(kbegin,j) );
283 for(
size_t k=kbegin+1UL; k<kend; ++k ) {
299 inline ReturnType
at(
size_t i,
size_t j )
const {
300 if( i >=
lhs_.rows() ) {
303 if( j >=
rhs_.columns() ) {
326 return rhs_.columns();
356 template<
typename T >
358 return (
lhs_.isAliased( alias ) ||
rhs_.isAliased( alias ) );
368 template<
typename T >
370 return (
lhs_.isAliased( alias ) ||
rhs_.isAliased( alias ) );
380 return lhs_.isAligned();
390 return (
rows() > SMP_DMATSMATMULT_THRESHOLD );
413 template<
typename MT
433 DMatSMatMultExpr::selectAssignKernel( ~lhs, A, B );
449 template<
typename MT3
452 static inline void selectAssignKernel( MT3& C,
const MT4& A,
const MT5& B )
454 if( C.rows() * C.columns() < DMATSMATMULT_THRESHOLD )
455 selectSmallAssignKernel( C, A, B );
457 selectLargeAssignKernel( C, A, B );
476 template<
typename MT3
479 static inline void selectDefaultAssignKernel( MT3& C,
const MT4& A,
const MT5& B )
485 for(
size_t j=0UL; j<B.rows(); ++j )
487 if( IsDiagonal<MT4>::value )
489 ConstIterator element( B.begin(j) );
490 const ConstIterator
end( B.end(j) );
492 for( ; element!=
end; ++element ) {
493 C(j,element->index()) = A(j,j) * element->value();
498 const size_t iibegin( ( IsLower<MT4>::value )
499 ?( IsStrictlyLower<MT4>::value ? j+1UL : j )
501 const size_t iiend( ( IsUpper<MT4>::value )
502 ?( IsStrictlyUpper<MT4>::value ? j : j+1UL )
506 for(
size_t ii=iibegin; ii<iiend; ii+=8UL )
508 ConstIterator element( B.begin(j) );
509 const ConstIterator
end( B.end(j) );
510 const size_t iend( ( ii+8UL > iiend )?( iiend ):( ii+8UL ) );
512 for( ; element!=
end; ++element ) {
513 for(
size_t i=ii; i<iend; ++i ) {
515 C(i,element->index()) = A(i,j) * element->value();
517 C(i,element->index()) += A(i,j) * element->value();
540 template<
typename MT3
543 static inline typename EnableIf< UseDefaultKernel<MT3,MT4,MT5> >::Type
544 selectSmallAssignKernel( MT3& C,
const MT4& A,
const MT5& B )
546 selectDefaultAssignKernel( C, A, B );
566 template<
typename MT3
569 static inline typename EnableIf< UseOptimizedKernel<MT3,MT4,MT5> >::Type
570 selectSmallAssignKernel( MT3& C,
const MT4& A,
const MT5& B )
576 for(
size_t j=0UL; j<B.rows(); ++j )
578 const size_t iibegin( ( IsLower<MT4>::value )
579 ?( IsStrictlyLower<MT4>::value ? j+1UL : j )
581 const size_t iiend( ( IsUpper<MT4>::value )
582 ?( IsStrictlyUpper<MT4>::value ? j : j+1UL )
586 for(
size_t ii=iibegin; ii<iiend; ii+=8UL )
588 ConstIterator element( B.begin(j) );
589 const ConstIterator
end( B.end(j) );
590 const size_t iend( ( ii+8UL > iiend )?( iiend ):( ii+8UL ) );
592 for( ; element!=
end; ++element ) {
593 for(
size_t i=ii; i<iend; ++i ) {
594 C(i,element->index()) += A(i,j) * element->value();
616 template<
typename MT3
619 static inline typename EnableIf< UseDefaultKernel<MT3,MT4,MT5> >::Type
620 selectLargeAssignKernel( MT3& C,
const MT4& A,
const MT5& B )
622 selectDefaultAssignKernel( C, A, B );
642 template<
typename MT3
645 static inline typename EnableIf< UseOptimizedKernel<MT3,MT4,MT5> >::Type
646 selectLargeAssignKernel( MT3& C,
const MT4& A,
const MT5& B )
651 assign( C, A * tmp );
669 template<
typename MT
671 friend inline typename DisableIf< CanExploitSymmetry<MT,MT1,MT2> >::Type
676 typedef typename SelectType< SO, OppositeType, ResultType >::Type TmpType;
688 const TmpType tmp(
serial( rhs ) );
709 template<
typename MT
711 friend inline typename EnableIf< CanExploitSymmetry<MT,MT1,MT2> >::Type
721 if( IsSymmetric<MT1>::value && IsSymmetric<MT2>::value )
722 assign( ~lhs,
trans( rhs.lhs_ ) *
trans( rhs.rhs_ ) );
723 else if( IsSymmetric<MT1>::value )
724 assign( ~lhs,
trans( rhs.lhs_ ) * rhs.rhs_ );
726 assign( ~lhs, rhs.lhs_ *
trans( rhs.rhs_ ) );
744 template<
typename MT
746 friend inline typename DisableIf< CanExploitSymmetry<MT,MT1,MT2> >::Type
754 LT A(
serial( rhs.lhs_ ) );
755 RT B(
serial( rhs.rhs_ ) );
764 DMatSMatMultExpr::selectAddAssignKernel( ~lhs, A, B );
780 template<
typename MT3
783 static inline void selectAddAssignKernel( MT3& C,
const MT4& A,
const MT5& B )
785 if( C.rows() * C.columns() < DMATSMATMULT_THRESHOLD )
786 selectSmallAddAssignKernel( C, A, B );
788 selectLargeAddAssignKernel( C, A, B );
807 template<
typename MT3
810 static inline void selectSmallAddAssignKernel( MT3& C,
const MT4& A,
const MT5& B )
814 for(
size_t j=0UL; j<B.rows(); ++j )
816 if( IsDiagonal<MT4>::value )
818 ConstIterator element( B.begin(j) );
819 const ConstIterator
end( B.end(j) );
821 for( ; element!=
end; ++element ) {
822 C(j,element->index()) += A(j,j) * element->value();
827 const size_t iibegin( ( IsLower<MT4>::value )
828 ?( IsStrictlyLower<MT4>::value ? j+1UL : j )
830 const size_t iiend( ( IsUpper<MT4>::value )
831 ?( IsStrictlyUpper<MT4>::value ? j : j+1UL )
835 for(
size_t ii=iibegin; ii<iiend; ii+=8UL )
837 ConstIterator element( B.begin(j) );
838 const ConstIterator
end( B.end(j) );
839 const size_t iend( ( ii+8UL > iiend )?( iiend ):( ii+8UL ) );
841 for( ; element!=
end; ++element ) {
842 for(
size_t i=ii; i<iend; ++i ) {
843 C(i,element->index()) += A(i,j) * element->value();
867 template<
typename MT3
870 static inline void selectLargeAddAssignKernel( MT3& C,
const MT4& A,
const MT5& B )
875 addAssign( C, A * tmp );
895 template<
typename MT
897 friend inline typename EnableIf< CanExploitSymmetry<MT,MT1,MT2> >::Type
907 if( IsSymmetric<MT1>::value && IsSymmetric<MT2>::value )
908 addAssign( ~lhs,
trans( rhs.lhs_ ) *
trans( rhs.rhs_ ) );
909 else if( IsSymmetric<MT1>::value )
910 addAssign( ~lhs,
trans( rhs.lhs_ ) * rhs.rhs_ );
912 addAssign( ~lhs, rhs.lhs_ *
trans( rhs.rhs_ ) );
934 template<
typename MT
936 friend inline typename DisableIf< CanExploitSymmetry<MT,MT1,MT2> >::Type
944 LT A(
serial( rhs.lhs_ ) );
945 RT B(
serial( rhs.rhs_ ) );
954 DMatSMatMultExpr::selectSubAssignKernel( ~lhs, A, B );
970 template<
typename MT3
973 static inline void selectSubAssignKernel( MT3& C,
const MT4& A,
const MT5& B )
975 if( C.rows() * C.columns() < DMATSMATMULT_THRESHOLD )
976 selectSmallSubAssignKernel( C, A, B );
978 selectLargeSubAssignKernel( C, A, B );
997 template<
typename MT3
1000 static inline void selectSmallSubAssignKernel( MT3& C,
const MT4& A,
const MT5& B )
1004 for(
size_t j=0UL; j<B.rows(); ++j )
1006 if( IsDiagonal<MT4>::value )
1008 ConstIterator element( B.begin(j) );
1009 const ConstIterator
end( B.end(j) );
1011 for( ; element!=
end; ++element ) {
1012 C(j,element->index()) -= A(j,j) * element->value();
1017 const size_t iibegin( ( IsLower<MT4>::value )
1018 ?( IsStrictlyLower<MT4>::value ? j+1UL : j )
1020 const size_t iiend( ( IsUpper<MT4>::value )
1021 ?( IsStrictlyUpper<MT4>::value ? j : j+1UL )
1025 for(
size_t ii=iibegin; ii<iiend; ii+=8UL )
1027 ConstIterator element( B.begin(j) );
1028 const ConstIterator
end( B.end(j) );
1029 const size_t iend( ( ii+8UL > iiend )?( iiend ):( ii+8UL ) );
1031 for( ; element!=
end; ++element ) {
1032 for(
size_t i=ii; i<iend; ++i ) {
1033 C(i,element->index()) -= A(i,j) * element->value();
1057 template<
typename MT3
1060 static inline void selectLargeSubAssignKernel( MT3& C,
const MT4& A,
const MT5& B )
1065 subAssign( C, A * tmp );
1085 template<
typename MT
1087 friend inline typename EnableIf< CanExploitSymmetry<MT,MT1,MT2> >::Type
1097 if( IsSymmetric<MT1>::value && IsSymmetric<MT2>::value )
1098 subAssign( ~lhs,
trans( rhs.lhs_ ) *
trans( rhs.rhs_ ) );
1099 else if( IsSymmetric<MT1>::value )
1100 subAssign( ~lhs,
trans( rhs.lhs_ ) * rhs.rhs_ );
1102 subAssign( ~lhs, rhs.lhs_ *
trans( rhs.rhs_ ) );
1134 template<
typename MT
1136 friend inline typename EnableIf< IsEvaluationRequired<MT,MT1,MT2> >::Type
1174 template<
typename MT
1176 friend inline typename EnableIf< IsEvaluationRequired<MT,MT1,MT2> >::Type
1181 typedef typename SelectType< SO, OppositeType, ResultType >::Type TmpType;
1193 const TmpType tmp( rhs );
1214 template<
typename MT
1216 friend inline typename EnableIf< CanExploitSymmetry<MT,MT1,MT2> >::Type
1226 if( IsSymmetric<MT1>::value && IsSymmetric<MT2>::value )
1228 else if( IsSymmetric<MT1>::value )
1251 template<
typename MT
1253 friend inline typename EnableIf< IsEvaluationRequired<MT,MT1,MT2> >::Type
1291 template<
typename MT
1293 friend inline typename EnableIf< CanExploitSymmetry<MT,MT1,MT2> >::Type
1303 if( IsSymmetric<MT1>::value && IsSymmetric<MT2>::value )
1305 else if( IsSymmetric<MT1>::value )
1333 template<
typename MT
1335 friend inline typename EnableIf< IsEvaluationRequired<MT,MT1,MT2> >::Type
1373 template<
typename MT
1375 friend inline typename EnableIf< CanExploitSymmetry<MT,MT1,MT2> >::Type
1385 if( IsSymmetric<MT1>::value && IsSymmetric<MT2>::value )
1387 else if( IsSymmetric<MT1>::value )
1457 template<
typename T1
1459 inline const DMatSMatMultExpr<T1,T2>
1483 template<
typename MT1,
typename MT2 >
1500 template<
typename MT1,
typename MT2 >
1517 template<
typename MT1,
typename MT2 >
1518 struct IsAligned<
DMatSMatMultExpr<MT1,MT2> > :
public IsTrue< IsAligned<MT1>::value >
1534 template<
typename MT1,
typename MT2 >
1536 :
public IsTrue< And< IsLower<MT1>, IsLower<MT2> >::value >
1552 template<
typename MT1,
typename MT2 >
1554 :
public IsTrue< And< IsUniLower<MT1>, IsUniLower<MT2> >::value >
1570 template<
typename MT1,
typename MT2 >
1572 :
public IsTrue< Or< And< IsStrictlyLower<MT1>, IsLower<MT2> >
1573 , And< IsStrictlyLower<MT2>, IsLower<MT1> > >::value >
1589 template<
typename MT1,
typename MT2 >
1591 :
public IsTrue< And< IsUpper<MT1>, IsUpper<MT2> >::value >
1607 template<
typename MT1,
typename MT2 >
1609 :
public IsTrue< And< IsUniUpper<MT1>, IsUniUpper<MT2> >::value >
1625 template<
typename MT1,
typename MT2 >
1627 :
public IsTrue< Or< And< IsStrictlyUpper<MT1>, IsUpper<MT2> >
1628 , And< IsStrictlyUpper<MT2>, IsUpper<MT1> > >::value >
1644 template<
typename MT1,
typename MT2,
typename VT >
1649 typedef typename SelectType< IsDenseMatrix<MT1>::value && IsRowMajorMatrix<MT1>::value &&
1650 IsSparseMatrix<MT2>::value && IsRowMajorMatrix<MT2>::value &&
1651 IsDenseVector<VT>::value && IsColumnVector<VT>::value
1652 ,
typename DMatDVecMultExprTrait< MT1, typename SMatDVecMultExprTrait<MT2,VT>::Type >::Type
1653 , INVALID_TYPE >::Type Type;
1662 template<
typename MT1,
typename MT2,
typename VT >
1667 typedef typename SelectType< IsDenseMatrix<MT1>::value && IsRowMajorMatrix<MT1>::value &&
1668 IsSparseMatrix<MT2>::value && IsRowMajorMatrix<MT2>::value &&
1669 IsSparseVector<VT>::value && IsColumnVector<VT>::value
1670 ,
typename DMatSVecMultExprTrait< MT1, typename SMatSVecMultExprTrait<MT2,VT>::Type >::Type
1671 , INVALID_TYPE >::Type Type;
1680 template<
typename VT,
typename MT1,
typename MT2 >
1685 typedef typename SelectType< IsDenseVector<VT>::value && IsRowVector<VT>::value &&
1686 IsDenseMatrix<MT1>::value && IsRowMajorMatrix<MT1>::value &&
1687 IsSparseMatrix<MT2>::value && IsRowMajorMatrix<MT2>::value
1688 ,
typename TDVecSMatMultExprTrait< typename TDVecDMatMultExprTrait<VT,MT1>::Type, MT2 >::Type
1689 , INVALID_TYPE >::Type Type;
1698 template<
typename VT,
typename MT1,
typename MT2 >
1703 typedef typename SelectType< IsSparseVector<VT>::value && IsRowVector<VT>::value &&
1704 IsDenseMatrix<MT1>::value && IsRowMajorMatrix<MT1>::value &&
1705 IsSparseMatrix<MT2>::value && IsRowMajorMatrix<MT2>::value
1706 ,
typename TDVecSMatMultExprTrait< typename TDVecDMatMultExprTrait<VT,MT1>::Type, MT2 >::Type
1707 , INVALID_TYPE >::Type Type;
1716 template<
typename MT1,
typename MT2,
bool AF >
1721 typedef typename MultExprTrait< typename SubmatrixExprTrait<const MT1,AF>::Type
1722 ,
typename SubmatrixExprTrait<const MT2,AF>::Type >::Type Type;
1731 template<
typename MT1,
typename MT2 >
1736 typedef typename MultExprTrait< typename RowExprTrait<const MT1>::Type, MT2 >::Type Type;
1745 template<
typename MT1,
typename MT2 >
1750 typedef typename MultExprTrait< MT1, typename ColumnExprTrait<const MT2>::Type >::Type Type;
#define BLAZE_THROW_INVALID_ARGUMENT(MESSAGE)
Macro for the emission of a std::invalid_argument exceptionThis macro encapsulates the default way of...
Definition: Exception.h:187
ResultType::TransposeType TransposeType
Transpose type for expression template evaluations.
Definition: DMatSMatMultExpr.h:209
const MT::ElementType max(const DenseMatrix< MT, SO > &dm)
Returns the largest element of the dense matrix.
Definition: DenseMatrix.h:1729
Compile time check whether the given type is a computational expression template.This type trait clas...
Definition: IsComputation.h:89
Header file for mathematical functions.
RightOperand rhs_
Right-hand side sparse matrix of the multiplication expression.
Definition: DMatSMatMultExpr.h:397
Header file for the SMatDVecMultExprTrait class template.
Header file for the Rows type trait.
Header file for the IsUniUpper type trait.
const DMatDMatMultExpr< T1, T2 > operator*(const DenseMatrix< T1, false > &lhs, const DenseMatrix< T2, false > &rhs)
Multiplication operator for the multiplication of two row-major dense matrices ( ).
Definition: DMatDMatMultExpr.h:7820
Compile time check for triangular matrix types.This type trait tests whether or not the given templat...
Definition: IsTriangular.h:105
Header file for basic type definitions.
const ResultType CompositeType
Data type for composite expression templates.
Definition: DMatSMatMultExpr.h:212
ReturnType operator()(size_t i, size_t j) const
2D-access to the matrix elements.
Definition: DMatSMatMultExpr.h:257
const ElementType ReturnType
Return type for expression template evaluations.
Definition: DMatSMatMultExpr.h:211
BLAZE_ALWAYS_INLINE MT::Iterator end(Matrix< MT, SO > &matrix, size_t i)
Returns an iterator just past the last element of row/column i.
Definition: Matrix.h:250
SelectType< evaluateRight, const RT2, CT2 >::Type RT
Type for the assignment of the right-hand side sparse matrix operand.
Definition: DMatSMatMultExpr.h:224
Header file for the IsSparseMatrix type trait.
Efficient implementation of a compressed matrix.The CompressedMatrix class template is the represent...
Definition: CompressedMatrix.h:207
Header file for the IsDiagonal type trait.
#define BLAZE_CONSTRAINT_MUST_BE_DENSE_MATRIX_TYPE(T)
Constraint on the data type.In case the given data type T is not a dense, N-dimensional matrix type...
Definition: DenseMatrix.h:79
Header file for the ColumnExprTrait class template.
void reset(const DiagonalProxy< MT > &proxy)
Resetting the represented element to the default initial values.
Definition: DiagonalProxy.h:507
const This & CompositeType
Data type for composite expression templates.
Definition: CompressedMatrix.h:2588
Header file for the IsRowVector type trait.
Type ElementType
Type of the sparse matrix elements.
Definition: CompressedMatrix.h:259
Header file for the And class template.
size_t columns() const
Returns the current number of columns of the matrix.
Definition: DMatSMatMultExpr.h:325
Compile time check for lower triangular matrices.This type trait tests whether or not the given templ...
Definition: IsLower.h:90
bool isAligned() const
Returns whether the operands of the expression are properly aligned in memory.
Definition: DMatSMatMultExpr.h:379
MT2::ResultType RT2
Result type of the right-hand side sparse matrix expression.
Definition: DMatSMatMultExpr.h:133
Header file for the TDVecSMatMultExprTrait class template.
MultTrait< RT1, RT2 >::Type ResultType
Result type for expression template evaluations.
Definition: DMatSMatMultExpr.h:207
const DMatSerialExpr< MT, SO > serial(const DenseMatrix< MT, SO > &dm)
Forces the serial evaluation of the given dense matrix expression dm.
Definition: DMatSerialExpr.h:721
Header file for the Computation base class.
Header file for the MatMatMultExpr base class.
Compile time check for upper triangular matrices.This type trait tests whether or not the given templ...
Definition: IsUpper.h:90
Constraints on the storage order of matrix types.
Header file for the RequiresEvaluation type trait.
System settings for performance optimizations.
Header file for the IsUniLower type trait.
CompressedMatrix< Type, false > OppositeType
Result type with opposite storage order for expression template evaluations.
Definition: CompressedMatrix.h:2584
Base class for dense matrices.The DenseMatrix class is a base class for all dense matrix classes...
Definition: DenseMatrix.h:70
Base class for sparse matrices.The SparseMatrix class is a base class for all sparse matrix classes...
Definition: Forward.h:117
bool isDefault(const DiagonalProxy< MT > &proxy)
Returns whether the represented element is in default state.
Definition: DiagonalProxy.h:547
Constraint on the data type.
Constraint on the data type.
Constraint on the data type.
Header file for the MultExprTrait class template.
Compile time check to query the requirement to evaluate an expression.Via this type trait it is possi...
Definition: RequiresEvaluation.h:90
SelectType< IsExpression< MT2 >::value, const MT2, const MT2 & >::Type RightOperand
Composite type of the right-hand side sparse matrix expression.
Definition: DMatSMatMultExpr.h:218
LeftOperand lhs_
Left-hand side dense matrix of the multiplication expression.
Definition: DMatSMatMultExpr.h:396
size_t rows() const
Returns the current number of rows of the matrix.
Definition: DMatSMatMultExpr.h:315
Compile time type selection.The SelectType class template selects one of the two given types T1 and T...
Definition: SelectType.h:59
Header file for the DisableIf class template.
Header file for the multiplication trait.
Header file for the IsStrictlyUpper type trait.
MT1::ResultType RT1
Result type of the left-hand side dense matrix expression.
Definition: DMatSMatMultExpr.h:132
Header file for the IsSymmetric type trait.
Namespace of the Blaze C++ math library.
Definition: Blaze.h:57
#define BLAZE_CONSTRAINT_MUST_BE_COLUMN_MAJOR_MATRIX_TYPE(T)
Constraint on the data type.In case the given data type T is not a column-major dense or sparse matri...
Definition: ColumnMajorMatrix.h:79
const Element * ConstIterator
Iterator over constant elements.
Definition: CompressedMatrix.h:2592
LeftOperand leftOperand() const
Returns the left-hand side dense matrix operand.
Definition: DMatSMatMultExpr.h:335
Header file for the Or class template.
#define BLAZE_THROW_OUT_OF_RANGE(MESSAGE)
Macro for the emission of a std::out_of_range exceptionThis macro encapsulates the default way of Bla...
Definition: Exception.h:331
const MT::ElementType min(const DenseMatrix< MT, SO > &dm)
Returns the smallest element of the dense matrix.
Definition: DenseMatrix.h:1682
Header file for the DenseMatrix base class.
Header file for the Columns type trait.
ResultType::OppositeType OppositeType
Result type with opposite storage order for expression template evaluations.
Definition: DMatSMatMultExpr.h:208
Header file for the DMatDVecMultExprTrait class template.
Header file for the IsLower type trait.
RT2::ElementType ET2
Element type of the right-hand side sparse matrix expression.
Definition: DMatSMatMultExpr.h:135
Header file for the IsAligned type trait.
Header file for the SMatSVecMultExprTrait class template.
#define BLAZE_CONSTRAINT_MUST_BE_REFERENCE_TYPE(T)
Constraint on the data type.In case the given data type T is not a reference type, a compilation error is created.
Definition: Reference.h:78
bool canSMPAssign() const
Returns whether the expression can be used in SMP assignments.
Definition: DMatSMatMultExpr.h:389
Header file for the IsTriangular type trait.
Constraints on the storage order of matrix types.
SelectType< evaluateLeft, const RT1, CT1 >::Type LT
Type for the assignment of the left-hand side dense matrix operand.
Definition: DMatSMatMultExpr.h:221
Compile time check for strictly upper triangular matrices.This type trait tests whether or not the gi...
Definition: IsStrictlyUpper.h:86
Type ElementType
Type of the sparse matrix elements.
Definition: CompressedMatrix.h:2586
Header file for the SelectType class template.
Header file for the RowExprTrait class template.
Header file for all forward declarations for expression class templates.
Header file for the IsDenseMatrix type trait.
Header file for the EnableIf class template.
Header file for the IsStrictlyLower type trait.
Header file for the serial shim.
#define BLAZE_CONSTRAINT_MUST_FORM_VALID_MATMATMULTEXPR(T1, T2)
Constraint on the data type.In case the given data types T1 and T2 do not form a valid matrix/matrix ...
Definition: MatMatMultExpr.h:165
ResultType::ElementType ElementType
Resulting element type.
Definition: DMatSMatMultExpr.h:210
MT1::CompositeType CT1
Composite type of the left-hand side dense matrix expression.
Definition: DMatSMatMultExpr.h:136
RT1::ElementType ET1
Element type of the left-hand side dense matrix expression.
Definition: DMatSMatMultExpr.h:134
Base class for all matrix/matrix multiplication expression templates.The MatMatMultExpr class serves ...
Definition: MatMatMultExpr.h:65
EnableIf< IsDenseMatrix< MT1 > >::Type smpSubAssign(Matrix< MT1, SO1 > &lhs, const Matrix< MT2, SO2 > &rhs)
Default implementation of the SMP subtraction assignment of a matrix to dense matrix.
Definition: DenseMatrix.h:160
ReturnType at(size_t i, size_t j) const
Checked access to the matrix elements.
Definition: DMatSMatMultExpr.h:299
Header file for the IsSparseVector type trait.
#define BLAZE_CONSTRAINT_MUST_NOT_BE_SYMMETRIC_MATRIX_TYPE(T)
Constraint on the data type.In case the given data type T is a symmetric matrix type, a compilation error is created.
Definition: Symmetric.h:116
Header file for the SubmatrixExprTrait class template.
#define BLAZE_CONSTRAINT_MUST_BE_ROW_MAJOR_MATRIX_TYPE(T)
Constraint on the data type.In case the given data type T is not a row-major dense or sparse matrix t...
Definition: RowMajorMatrix.h:79
bool canAlias(const T *alias) const
Returns whether the expression can alias with the given address alias.
Definition: DMatSMatMultExpr.h:357
Header file for run time assertion macros.
EnableIf< IsDenseMatrix< MT1 > >::Type smpAssign(Matrix< MT1, SO1 > &lhs, const Matrix< MT2, SO2 > &rhs)
Default implementation of the SMP assignment of a matrix to a dense matrix.
Definition: DenseMatrix.h:98
bool isAliased(const T *alias) const
Returns whether the expression is aliased with the given address alias.
Definition: DMatSMatMultExpr.h:369
Utility type for generic codes.
Base template for the MultTrait class.
Definition: MultTrait.h:138
Expression object for dense matrix-sparse matrix multiplications.The DMatSMatMultExpr class represent...
Definition: DMatSMatMultExpr.h:126
const bool useOptimizedKernels
Configuration switch for optimized kernels.This configuration switch enables/disables all optimized c...
Definition: Optimizations.h:84
Header file for the reset shim.
Header file for the isDefault shim.
Constraint on the data type.
Constraints on the storage order of matrix types.
Substitution Failure Is Not An Error (SFINAE) class.The DisableIf class template is an auxiliary tool...
Definition: DisableIf.h:184
#define BLAZE_CONSTRAINT_MATRICES_MUST_HAVE_SAME_STORAGE_ORDER(T1, T2)
Constraint on the data type.In case either of the two given data types T1 or T2 is not a matrix type ...
Definition: StorageOrder.h:122
MT2::CompositeType CT2
Composite type of the right-hand side sparse matrix expression.
Definition: DMatSMatMultExpr.h:137
Header file for the IsDenseVector type trait.
Compile time check for strictly lower triangular matrices.This type trait tests whether or not the gi...
Definition: IsStrictlyLower.h:86
SelectType< IsExpression< MT1 >::value, const MT1, const MT1 & >::Type LeftOperand
Composite type of the left-hand side dense matrix expression.
Definition: DMatSMatMultExpr.h:215
Header file for the IsRowMajorMatrix type trait.
const DMatTransExpr< MT,!SO > trans(const DenseMatrix< MT, SO > &dm)
Calculation of the transpose of the given dense matrix.
Definition: DMatTransExpr.h:944
Header file for the IsComputation type trait class.
Base class for all compute expression templates.The Computation class serves as a tag for all computa...
Definition: Computation.h:59
Header file for the TDVecDMatMultExprTrait class template.
EnableIf< IsDenseMatrix< MT1 > >::Type smpAddAssign(Matrix< MT1, SO1 > &lhs, const Matrix< MT2, SO2 > &rhs)
Default implementation of the SMP addition assignment of a matrix to a dense matrix.
Definition: DenseMatrix.h:129
#define BLAZE_FUNCTION_TRACE
Function trace macro.This macro can be used to reliably trace function calls. In case function tracin...
Definition: FunctionTrace.h:157
This ResultType
Result type for expression template evaluations.
Definition: CompressedMatrix.h:2583
Header file for the IsTrue value trait.
DMatSMatMultExpr(const MT1 &lhs, const MT2 &rhs)
Constructor for the DMatSMatMultExpr class.
Definition: DMatSMatMultExpr.h:242
Header file for the TSVecDMatMultExprTrait class template.
DMatSMatMultExpr< MT1, MT2 > This
Type of this DMatSMatMultExpr instance.
Definition: DMatSMatMultExpr.h:206
Header file for the IsUpper type trait.
Header file for exception macros.
Header file for the DMatSVecMultExprTrait class template.
Header file for the IsColumnVector type trait.
Constraint on the data type.
Header file for the IsResizable type trait.
Header file for the thresholds for matrix/vector and matrix/matrix multiplications.
#define BLAZE_INTERNAL_ASSERT(expr, msg)
Run time assertion macro for internal checks.In case of an invalid run time expression, the program execution is terminated. The BLAZE_INTERNAL_ASSERT macro can be disabled by setting the BLAZE_USER_ASSERTION flag to zero or by defining NDEBUG during the compilation.
Definition: Assert.h:101
#define BLAZE_CONSTRAINT_MUST_BE_SPARSE_MATRIX_TYPE(T)
Constraint on the data type.In case the given data type T is not a sparse, N-dimensional matrix type...
Definition: SparseMatrix.h:79
Header file for the IsExpression type trait class.
Header file for the FunctionTrace class.
RightOperand rightOperand() const
Returns the right-hand side sparse matrix operand.
Definition: DMatSMatMultExpr.h:345