35 #ifndef _BLAZE_MATH_EXPRESSIONS_TSVECDMATMULTEXPR_H_
36 #define _BLAZE_MATH_EXPRESSIONS_TSVECDMATMULTEXPR_H_
95 class TSVecDMatMultExpr :
public DenseVector< TSVecDMatMultExpr<VT,MT>, true >
96 ,
private TVecMatMultExpr
125 template<
typename T1,
typename T2,
typename T3 >
126 struct UseSMPAssignKernel {
127 enum { value = evaluateVector || evaluateMatrix };
138 template<
typename T1,
typename T2,
typename T3 >
139 struct UseVectorizedKernel {
140 enum { value = !UseSMPAssignKernel<T1,T2,T3>::value &&
141 T1::vectorizable && T3::vectorizable &&
142 IsSame<typename T1::ElementType,typename T2::ElementType>::value &&
143 IsSame<typename T1::ElementType,typename T3::ElementType>::value &&
144 IntrinsicTrait<typename T1::ElementType>::addition &&
145 IntrinsicTrait<typename T1::ElementType>::multiplication };
156 template<
typename T1,
typename T2,
typename T3 >
157 struct UseOptimizedKernel {
158 enum { value = !UseSMPAssignKernel<T1,T2,T3>::value &&
159 !UseVectorizedKernel<T1,T2,T3>::value &&
160 !IsResizable<typename T1::ElementType>::value &&
161 !IsResizable<VET>::value };
171 template<
typename T1,
typename T2,
typename T3 >
172 struct UseDefaultKernel {
173 enum { value = !UseSMPAssignKernel<T1,T2,T3>::value &&
174 !UseVectorizedKernel<T1,T2,T3>::value &&
175 !UseOptimizedKernel<T1,T2,T3>::value };
205 enum { vectorizable = MT::vectorizable &&
211 enum { smpAssignable = !evaluateVector && !evaluateMatrix };
243 const ConstIterator end( x.end() );
244 ConstIterator element( x.begin() );
247 if( element != end ) {
248 res = element->value() *
mat_( element->index(), index );
250 for( ; element!=end; ++element )
251 res += element->value() *
mat_( element->index(), index );
267 return mat_.columns();
297 template<
typename T >
299 return vec_.isAliased( alias ) ||
mat_.isAliased( alias );
309 template<
typename T >
311 return vec_.isAliased( alias ) ||
mat_.isAliased( alias );
321 return mat_.isAligned();
354 template<
typename VT2 >
363 if( x.nonZeros() == 0UL ) {
378 TSVecDMatMultExpr::selectAssignKernel( ~lhs, x, A );
397 template<
typename VT1
401 selectAssignKernel( VT1& y,
const VT2& x,
const MT1& A )
407 const size_t N( A.columns() );
409 ConstIterator element( x.begin() );
410 const ConstIterator end( x.end() );
412 for(
size_t j=0UL; j<N; ++j ) {
413 y[j] = element->value() * A(element->index(),j);
418 for( ; element!=end; ++element ) {
419 for(
size_t j=0UL; j<N; ++j ) {
420 y[j] += element->value() * A(element->index(),j);
441 template<
typename VT1
444 static inline typename EnableIf< UseOptimizedKernel<VT1,VT2,MT1> >::Type
445 selectAssignKernel( VT1& y,
const VT2& x,
const MT1& A )
451 const size_t N( A.columns() );
453 ConstIterator element( x.begin() );
454 const ConstIterator end( x.end() );
456 const size_t iend( x.nonZeros() & size_t(-4) );
457 BLAZE_INTERNAL_ASSERT( ( x.nonZeros() - ( x.nonZeros() % 4UL ) ) == iend,
"Invalid end calculation" );
461 const size_t i1( element->index() );
462 const VET v1( element->value() );
464 const size_t i2( element->index() );
465 const VET v2( element->value() );
467 const size_t i3( element->index() );
468 const VET v3( element->value() );
470 const size_t i4( element->index() );
471 const VET v4( element->value() );
474 for(
size_t j=0UL; j<N; ++j ) {
475 y[j] = v1 * A(i1,j) + v2 * A(i2,j) + v3 * A(i3,j) + v4 * A(i4,j);
480 const size_t i1( element->index() );
481 const VET v1( element->value() );
484 for(
size_t j=0UL; j<N; ++j ) {
489 for(
size_t i=(iend>3UL)?(4UL):(1UL); (i+4UL)<=iend; i+=4UL )
491 const size_t i1( element->index() );
492 const VET v1( element->value() );
494 const size_t i2( element->index() );
495 const VET v2( element->value() );
497 const size_t i3( element->index() );
498 const VET v3( element->value() );
500 const size_t i4( element->index() );
501 const VET v4( element->value() );
504 for(
size_t j=0UL; j<N; ++j ) {
505 y[j] += v1 * A(i1,j) + v2 * A(i2,j) + v3 * A(i3,j) + v4 * A(i4,j);
508 for( ; element!=end; ++element )
510 const size_t i1( element->index() );
511 const VET v1( element->value() );
513 for(
size_t j=0UL; j<N; ++j ) {
514 y[j] += v1 * A(i1,j);
535 template<
typename VT1
538 static inline typename EnableIf< UseVectorizedKernel<VT1,VT2,MT1> >::Type
539 selectAssignKernel( VT1& y,
const VT2& x,
const MT1& A )
541 typedef IntrinsicTrait<ElementType> IT;
546 const size_t N( A.columns() );
548 ConstIterator element( x.begin() );
549 const ConstIterator end( x.end() );
551 const size_t iend( x.nonZeros() & size_t(-4) );
552 BLAZE_INTERNAL_ASSERT( ( x.nonZeros() - ( x.nonZeros() % 4UL ) ) == iend,
"Invalid end calculation" );
556 const size_t i1( element->index() );
557 const IntrinsicType v1(
set( element->value() ) );
559 const size_t i2( element->index() );
560 const IntrinsicType v2(
set( element->value() ) );
562 const size_t i3( element->index() );
563 const IntrinsicType v3(
set( element->value() ) );
565 const size_t i4( element->index() );
566 const IntrinsicType v4(
set( element->value() ) );
569 for(
size_t j=0UL; j<N; j+=IT::size ) {
570 y.store( j, v1 * A.load(i1,j) + v2 * A.load(i2,j) + v3 * A.load(i3,j) + v4 * A.load(i4,j) );
575 const size_t i1( element->index() );
576 const IntrinsicType v1(
set( element->value() ) );
579 for(
size_t j=0UL; j<N; j+=IT::size ) {
580 y.store( j, v1 * A.load(i1,j) );
584 for(
size_t i=(iend>3UL)?(4UL):(1UL); (i+4UL)<=iend; i+=4UL )
586 const size_t i1( element->index() );
587 const IntrinsicType v1(
set( element->value() ) );
589 const size_t i2( element->index() );
590 const IntrinsicType v2(
set( element->value() ) );
592 const size_t i3( element->index() );
593 const IntrinsicType v3(
set( element->value() ) );
595 const size_t i4( element->index() );
596 const IntrinsicType v4(
set( element->value() ) );
599 for(
size_t j=0UL; j<N; j+=IT::size ) {
600 y.store( j, y.load(j) + v1 * A.load(i1,j) + v2 * A.load(i2,j) + v3 * A.load(i3,j) + v4 * A.load(i4,j) );
603 for( ; element!=end; ++element )
605 const size_t i1( element->index() );
606 const IntrinsicType v1(
set( element->value() ) );
608 for(
size_t j=0UL; j<N; j+=IT::size ) {
609 y.store( j, y.load(j) + v1 * A.load(i1,j) );
630 template<
typename VT1
633 static inline typename EnableIf< UseSMPAssignKernel<VT1,VT2,MT1> >::Type
634 selectAssignKernel( VT1& y,
const VT2& x,
const MT1& A )
654 template<
typename VT2 >
665 const ResultType tmp( rhs );
683 template<
typename VT2 >
692 if( x.nonZeros() == 0UL )
return;
704 TSVecDMatMultExpr::selectAddAssignKernel( ~lhs, x, A );
722 template<
typename VT1
726 selectAddAssignKernel( VT1& y,
const VT2& x,
const MT1& A )
732 const size_t N( A.columns() );
734 ConstIterator element( x.begin() );
735 const ConstIterator end( x.end() );
737 for( ; element!=end; ++element ) {
738 for(
size_t j=0UL; j<N; ++j ) {
739 y[j] += element->value() * A(element->index(),j);
760 template<
typename VT1
763 static inline typename EnableIf< UseOptimizedKernel<VT1,VT2,MT1> >::Type
764 selectAddAssignKernel( VT1& y,
const VT2& x,
const MT1& A )
770 const size_t N( A.columns() );
772 ConstIterator element( x.begin() );
773 const ConstIterator end( x.end() );
775 const size_t iend( x.nonZeros() & size_t(-4) );
776 BLAZE_INTERNAL_ASSERT( ( x.nonZeros() - ( x.nonZeros() % 4UL ) ) == iend,
"Invalid end calculation" );
778 for(
size_t i=0UL; (i+4UL)<=iend; i+=4UL )
780 const size_t i1( element->index() );
781 const VET v1( element->value() );
783 const size_t i2( element->index() );
784 const VET v2( element->value() );
786 const size_t i3( element->index() );
787 const VET v3( element->value() );
789 const size_t i4( element->index() );
790 const VET v4( element->value() );
793 for(
size_t j=0UL; j<N; ++j ) {
794 y[j] += v1 * A(i1,j) + v2 * A(i2,j) + v3 * A(i3,j) + v4 * A(i4,j);
797 for( ; element!=end; ++element )
799 const size_t i1( element->index() );
800 const VET v1( element->value() );
802 for(
size_t j=0UL; j<N; ++j ) {
803 y[j] += v1 * A(i1,j);
824 template<
typename VT1
827 static inline typename EnableIf< UseVectorizedKernel<VT1,VT2,MT1> >::Type
828 selectAddAssignKernel( VT1& y,
const VT2& x,
const MT1& A )
830 typedef IntrinsicTrait<ElementType> IT;
835 const size_t N( A.columns() );
837 ConstIterator element( x.begin() );
838 const ConstIterator end( x.end() );
840 const size_t iend( x.nonZeros() & size_t(-4) );
841 BLAZE_INTERNAL_ASSERT( ( x.nonZeros() - ( x.nonZeros() % 4UL ) ) == iend,
"Invalid end calculation" );
843 for(
size_t i=0UL; (i+4UL)<=iend; i+=4UL )
845 const size_t i1( element->index() );
846 const IntrinsicType v1(
set( element->value() ) );
848 const size_t i2( element->index() );
849 const IntrinsicType v2(
set( element->value() ) );
851 const size_t i3( element->index() );
852 const IntrinsicType v3(
set( element->value() ) );
854 const size_t i4( element->index() );
855 const IntrinsicType v4(
set( element->value() ) );
858 for(
size_t j=0UL; j<N; j+=IT::size ) {
859 y.store( j, y.load(j) + v1 * A.load(i1,j) + v2 * A.load(i2,j) + v3 * A.load(i3,j) + v4 * A.load(i4,j) );
862 for( ; element!=end; ++element )
864 const size_t i1( element->index() );
865 const IntrinsicType v1(
set( element->value() ) );
867 for(
size_t j=0UL; j<N; j+=IT::size ) {
868 y.store( j, y.load(j) + v1 * A.load(i1,j) );
889 template<
typename VT1
892 static inline typename EnableIf< UseSMPAssignKernel<VT1,VT2,MT1> >::Type
893 selectAddAssignKernel( VT1& y,
const VT2& x,
const MT1& A )
916 template<
typename VT2 >
927 if( x.nonZeros() == 0UL )
return;
939 TSVecDMatMultExpr::selectSubAssignKernel( ~lhs, x, A );
957 template<
typename VT1
961 selectSubAssignKernel( VT1& y,
const VT2& x,
const MT1& A )
967 const size_t N( A.columns() );
969 ConstIterator element( x.begin() );
970 const ConstIterator end( x.end() );
972 for( ; element!=end; ++element ) {
973 for(
size_t j=0UL; j<N; ++j ) {
974 y[j] -= element->value() * A(element->index(),j);
995 template<
typename VT1
998 static inline typename EnableIf< UseOptimizedKernel<VT1,VT2,MT1> >::Type
999 selectSubAssignKernel( VT1& y,
const VT2& x,
const MT1& A )
1005 const size_t N( A.columns() );
1007 ConstIterator element( x.begin() );
1008 const ConstIterator end( x.end() );
1010 const size_t iend( x.nonZeros() & size_t(-4) );
1011 BLAZE_INTERNAL_ASSERT( ( x.nonZeros() - ( x.nonZeros() % 4UL ) ) == iend,
"Invalid end calculation" );
1013 for(
size_t i=0UL; (i+4UL)<=iend; i+=4UL )
1015 const size_t i1( element->index() );
1016 const VET v1( element->value() );
1018 const size_t i2( element->index() );
1019 const VET v2( element->value() );
1021 const size_t i3( element->index() );
1022 const VET v3( element->value() );
1024 const size_t i4( element->index() );
1025 const VET v4( element->value() );
1028 for(
size_t j=0UL; j<N; ++j ) {
1029 y[j] -= v1 * A(i1,j) + v2 * A(i2,j) + v3 * A(i3,j) + v4 * A(i4,j);
1032 for( ; element!=end; ++element )
1034 const size_t i1( element->index() );
1035 const VET v1( element->value() );
1037 for(
size_t j=0UL; j<N; ++j ) {
1038 y[j] -= v1 * A(i1,j);
1059 template<
typename VT1
1062 static inline typename EnableIf< UseVectorizedKernel<VT1,VT2,MT1> >::Type
1063 selectSubAssignKernel( VT1& y,
const VT2& x,
const MT1& A )
1065 typedef IntrinsicTrait<ElementType> IT;
1070 const size_t N( A.columns() );
1072 ConstIterator element( x.begin() );
1073 const ConstIterator end( x.end() );
1075 const size_t iend( x.nonZeros() & size_t(-4) );
1076 BLAZE_INTERNAL_ASSERT( ( x.nonZeros() - ( x.nonZeros() % 4UL ) ) == iend,
"Invalid end calculation" );
1078 for(
size_t i=0UL; (i+4UL)<=iend; i+=4UL )
1080 const size_t i1( element->index() );
1081 const IntrinsicType v1(
set( element->value() ) );
1083 const size_t i2( element->index() );
1084 const IntrinsicType v2(
set( element->value() ) );
1086 const size_t i3( element->index() );
1087 const IntrinsicType v3(
set( element->value() ) );
1089 const size_t i4( element->index() );
1090 const IntrinsicType v4(
set( element->value() ) );
1093 for(
size_t j=0UL; j<N; j+=IT::size ) {
1094 y.store( j, y.load(j) - v1 * A.load(i1,j) - v2 * A.load(i2,j) - v3 * A.load(i3,j) - v4 * A.load(i4,j) );
1097 for( ; element!=x.end(); ++element )
1099 const size_t i1( element->index() );
1100 const IntrinsicType v1(
set( element->value() ) );
1102 for(
size_t j=0UL; j<N; j+=IT::size ) {
1103 y.store( j, y.load(j) - v1 * A.load(i1,j) );
1124 template<
typename VT1
1127 static inline typename EnableIf< UseSMPAssignKernel<VT1,VT2,MT1> >::Type
1128 selectSubAssignKernel( VT1& y,
const VT2& x,
const MT1& A )
1151 template<
typename VT2 >
1162 const ResultType tmp( rhs );
1222 template<
typename T1,
typename T2 >
1223 inline const typename DisableIf< IsMatMatMultExpr<T2>, TSVecDMatMultExpr<T1,T2> >::Type
1228 if( (~vec).
size() != (~mat).
rows() )
1229 throw std::invalid_argument(
"Vector and matrix sizes do not match" );
1257 template<
typename T1
1260 inline const typename EnableIf< IsMatMatMultExpr<T2>, MultExprTrait<T1,T2> >::Type::Type
1280 template<
typename VT,
typename MT,
bool AF >
1285 typedef typename MultExprTrait< VT, typename SubmatrixExprTrait<const MT,AF>::Type >::Type Type;
Compile time check whether the given type is a computational expression template.This type trait clas...
Definition: IsComputation.h:89
void reset(DynamicMatrix< Type, SO > &m)
Resetting the given dense matrix.
Definition: DynamicMatrix.h:4579
friend void multAssign(DenseVector< VT2, true > &lhs, const TSVecDMatMultExpr &rhs)
Multiplication assignment of a transpose sparse vector-dense matrix multiplication to a dense vector ...
Definition: TSVecDMatMultExpr.h:1152
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:4075
TSVecDMatMultExpr< VT, MT > This
Type of this TSVecDMatMultExpr instance.
Definition: TSVecDMatMultExpr.h:182
ResultType::TransposeType TransposeType
Transpose type for expression template evaluations.
Definition: TSVecDMatMultExpr.h:184
Expression object for transpose sparse vector-dense matrix multiplications.The TSVecDMatMultExpr clas...
Definition: Forward.h:143
SelectType< evaluateMatrix, const MRT, MCT >::Type RT
Type for the assignment of the right-hand side dense matrix operand.
Definition: TSVecDMatMultExpr.h:200
SelectType< IsExpression< MT >::value, const MT, const MT & >::Type RightOperand
Composite type of the right-hand side sparse matrix expression.
Definition: TSVecDMatMultExpr.h:194
void smpSubAssign(DenseMatrix< MT1, SO1 > &lhs, const Matrix< MT2, SO2 > &rhs)
Default implementation of the SMP subtraction assignment of a matrix to dense matrix.
Definition: DenseMatrix.h:151
ReturnType operator[](size_t index) const
Subscript operator for the direct access to the vector elements.
Definition: TSVecDMatMultExpr.h:234
Efficient implementation of a compressed matrix.The CompressedMatrix class template is the represent...
Definition: CompressedMatrix.h:197
VT::ResultType VRT
Result type of the left-hand side sparse vector expression.
Definition: TSVecDMatMultExpr.h:101
#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
void smpMultAssign(DenseVector< VT1, TF1 > &lhs, const Vector< VT2, TF2 > &rhs)
Default implementation of the SMP multiplication assignment of a vector to a dense vector...
Definition: DenseVector.h:178
Header file for the IsSame and IsStrictlySame type traits.
const This & CompositeType
Data type for composite expression templates.
Definition: CompressedMatrix.h:2384
Type ElementType
Type of the sparse matrix elements.
Definition: CompressedMatrix.h:249
VT::CompositeType VCT
Composite type of the left-hand side sparse vector expression.
Definition: TSVecDMatMultExpr.h:105
Header file for the DenseVector base class.
Header file for the Computation base class.
Type relationship analysis.This class tests if the two data types A and B are equal. For this type comparison, the cv-qualifiers of both data types are ignored. If A and B are the same data type (ignoring the cv-qualifiers), then the value member enumeration is set to 1, the nested type definition Type is TrueType, and the class derives from TrueType. Otherwise value is set to 0, Type is FalseType, and the class derives from FalseType.
Definition: IsSame.h:158
Header file for the RequiresEvaluation type trait.
IntrinsicTrait< ElementType >::Type IntrinsicType
Resulting intrinsic element type.
Definition: TSVecDMatMultExpr.h:186
Base class for dense matrices.The DenseMatrix class is a base class for all dense matrix classes...
Definition: DenseMatrix.h:70
bool isAligned() const
Returns whether the operands of the expression are properly aligned in memory.
Definition: TSVecDMatMultExpr.h:320
const ElementType ReturnType
Return type for expression template evaluations.
Definition: TSVecDMatMultExpr.h:187
Constraint on the data type.
Constraint on the data type.
Header file for the MultExprTrait class template.
void smpAddAssign(DenseMatrix< 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:121
Compile time check to query the requirement to evaluate an expression.Via this type trait it is possi...
Definition: RequiresEvaluation.h:90
size_t size() const
Returns the current size/dimension of the vector.
Definition: TSVecDMatMultExpr.h:266
const This & CompositeType
Data type for composite expression templates.
Definition: CompressedMatrix.h:251
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.
friend void addAssign(DenseVector< VT2, true > &lhs, const TSVecDMatMultExpr &rhs)
Addition assignment of a transpose sparse vector-dense matrix multiplication to a dense vector ( )...
Definition: TSVecDMatMultExpr.h:684
Header file for the multiplication trait.
MT::CompositeType MCT
Composite type of the right-hand side dense matrix expression.
Definition: TSVecDMatMultExpr.h:106
Header file for the dense vector SMP implementation.
LeftOperand leftOperand() const
Returns the left-hand side sparse vector operand.
Definition: TSVecDMatMultExpr.h:276
const Element * ConstIterator
Iterator over constant elements.
Definition: CompressedMatrix.h:2388
TSVecDMatMultExpr(const VT &vec, const MT &mat)
Constructor for the TSVecDMatMultExpr class.
Definition: TSVecDMatMultExpr.h:220
Header file for the IsMatMatMultExpr type trait class.
MT::ResultType MRT
Result type of the right-hand side dense matrix expression.
Definition: TSVecDMatMultExpr.h:102
bool isAliased(const T *alias) const
Returns whether the expression is aliased with the given address alias.
Definition: TSVecDMatMultExpr.h:310
void assign(Matrix< MT1, SO1 > &lhs, const Matrix< MT2, SO2 > &rhs)
Default implementation of the assignment of a matrix to a matrix.
Definition: Matrix.h:179
Base class for N-dimensional dense vectors.The DenseVector class is a base class for all arbitrarily ...
Definition: DenseVector.h:70
#define BLAZE_CONSTRAINT_MUST_BE_SPARSE_VECTOR_TYPE(T)
Constraint on the data type.In case the given data type T is not a sparse, N-dimensional vector type...
Definition: SparseVector.h:79
Constraint on the data type.
#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
SelectType< IsExpression< VT >::value, const VT, const VT & >::Type LeftOperand
Composite type of the left-hand side sparse vector expression.
Definition: TSVecDMatMultExpr.h:191
Constraints on the storage order of matrix types.
Constraint on the data type.
MRT::ElementType MET
Element type of the right-hand side dense matrix expression.
Definition: TSVecDMatMultExpr.h:104
Type ElementType
Type of the sparse matrix elements.
Definition: CompressedMatrix.h:2382
Header file for the SelectType class template.
Header file for all forward declarations for expression class templates.
MultTrait< VRT, MRT >::Type ResultType
Result type for expression template evaluations.
Definition: TSVecDMatMultExpr.h:183
Constraint on the data type.
Header file for the EnableIf class template.
void smpAssign(DenseMatrix< MT1, SO1 > &lhs, const Matrix< MT2, SO2 > &rhs)
Default implementation of the SMP assignment of a matrix to a dense matrix.
Definition: DenseMatrix.h:91
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: StorageOrder.h:81
Removal of reference modifiers.The RemoveCV type trait removes any reference modifiers from the given...
Definition: RemoveReference.h:69
Intrinsic characteristics of data types.The IntrinsicTrait class template provides the intrinsic char...
Definition: IntrinsicTrait.h:748
Header file for run time assertion macros.
Base template for the MultTrait class.
Definition: MultTrait.h:141
const ResultType CompositeType
Data type for composite expression templates.
Definition: TSVecDMatMultExpr.h:188
Substitution Failure Is Not An Error (SFINAE) class.The EnableIf class template is an auxiliary tool ...
Definition: EnableIf.h:184
Header file for the reset shim.
bool canAlias(const T *alias) const
Returns whether the expression can alias with the given address alias.
Definition: TSVecDMatMultExpr.h:298
Compile time check for data types.This type trait tests whether or not the given template parameter i...
Definition: IsBlasCompatible.h:99
SelectType< evaluateVector, const VRT, VCT >::Type LT
Type for the assignment of the left-hand side sparse vector operand.
Definition: TSVecDMatMultExpr.h:197
Header file for the TVecMatMultExpr base class.
Header file for the RemoveReference type trait.
Header file for all intrinsic functionality.
#define BLAZE_CONSTRAINT_MUST_BE_DENSE_VECTOR_TYPE(T)
Constraint on the data type.In case the given data type T is not a dense, N-dimensional vector type...
Definition: DenseVector.h:79
bool canSMPAssign() const
Returns whether the expression can be used in SMP assignments.
Definition: TSVecDMatMultExpr.h:330
RightOperand mat_
Right-hand side dense matrix of the multiplication expression.
Definition: TSVecDMatMultExpr.h:338
LeftOperand vec_
Left-hand side sparse vector of the multiplication expression.
Definition: TSVecDMatMultExpr.h:337
Header file for the IsComputation type trait class.
Header file for the sparse vector SMP implementation.
Base class for sparse vectors.The SparseVector class is a base class for all arbitrarily sized (N-dim...
Definition: Forward.h:105
#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:2379
Header file for basic type definitions.
#define BLAZE_CONSTRAINT_MUST_BE_ROW_VECTOR_TYPE(T)
Constraint on the data type.In case the given data type T is not a row dense or sparse vector type (i...
Definition: TransposeFlag.h:81
Header file for the SubvectorExprTrait class template.
VRT::ElementType VET
Element type of the left-hand side sparse vector expression.
Definition: TSVecDMatMultExpr.h:103
const size_t SMP_TSVECDMATMULT_THRESHOLD
SMP sparse vector/row-major dense matrix multiplication threshold.This threshold represents the syste...
Definition: Thresholds.h:217
friend void subAssign(DenseVector< VT2, true > &lhs, const TSVecDMatMultExpr &rhs)
Subtraction assignment of a transpose sparse vector-dense matrix multiplication to a dense vector ( )...
Definition: TSVecDMatMultExpr.h:917
Header file for the IsResizable type trait.
Header file for the thresholds for matrix/vector and matrix/matrix multiplications.
RightOperand rightOperand() const
Returns the right-hand side dense matrix operand.
Definition: TSVecDMatMultExpr.h:286
size_t rows(const Matrix< MT, SO > &m)
Returns the current number of rows of the matrix.
Definition: Matrix.h:138
#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
EnableIf< IsIntegral< T >, Set< T, sizeof(T)> >::Type::Type set(T value)
Sets all values in the vector to the given integral value.
Definition: Set.h:209
ResultType::ElementType ElementType
Resulting element type.
Definition: TSVecDMatMultExpr.h:185
Header file for the IsExpression type trait class.
Header file for the FunctionTrace class.