35#ifndef _BLAZE_MATH_EXPRESSIONS_TSVECDMATMULTEXPR_H_
36#define _BLAZE_MATH_EXPRESSIONS_TSVECDMATMULTEXPR_H_
109 :
public TVecMatMultExpr< DenseVector< TSVecDMatMultExpr<VT,MT>, true > >
124 static constexpr bool evaluateVector = ( IsComputation_v<VT> || RequiresEvaluation_v<VT> );
138 template<
typename T1 >
149 template<
typename T1,
typename T2,
typename T3 >
150 static constexpr bool UseVectorizedKernel_v =
151 ( useOptimizedKernels &&
153 T1::simdEnabled && T3::simdEnabled &&
154 IsSIMDCombinable_v< ElementType_t<T1>
168 template<
typename T1,
typename T2,
typename T3 >
169 static constexpr bool UseOptimizedKernel_v =
170 ( useOptimizedKernels &&
171 !UseVectorizedKernel_v<T1,T2,T3> &&
173 !IsResizable_v< ElementType_t<T1> > &&
174 !IsResizable_v<VET> );
183 template<
typename T1,
typename T2,
typename T3 >
184 static constexpr bool UseDefaultKernel_v =
185 ( !UseVectorizedKernel_v<T1,T2,T3> && !UseOptimizedKernel_v<T1,T2,T3> );
220 ( !IsDiagonal_v<MT> &&
222 HasSIMDAdd_v<VET,MET> &&
223 HasSIMDMult_v<VET,MET> );
258 if( IsDiagonal_v<MT> )
260 return vec_[index] *
mat_(index,index);
262 else if( IsLower_v<MT> )
264 const size_t begin( IsStrictlyLower_v<MT> ? index+1UL : index );
269 else if( IsUpper_v<MT> )
271 const size_t n( IsStrictlyUpper_v<MT> ? index : index+1UL );
290 if( index >=
mat_.columns() ) {
293 return (*
this)[index];
302 inline size_t size() const noexcept {
303 return mat_.columns();
333 template<
typename T >
334 inline bool canAlias(
const T* alias )
const noexcept {
335 return vec_.isAliased( alias ) ||
mat_.isAliased( alias );
345 template<
typename T >
346 inline bool isAliased(
const T* alias )
const noexcept {
347 return vec_.isAliased( alias ) ||
mat_.isAliased( alias );
357 return mat_.isAligned();
367 return (
size() > SMP_TSVECDMATMULT_THRESHOLD );
390 template<
typename VT2 >
399 if( x.nonZeros() == 0UL ) {
414 TSVecDMatMultExpr::selectAssignKernel( *lhs, x, A );
433 template<
typename VT1
436 static inline auto selectAssignKernel( VT1& y,
const VT2& x,
const MT1& A )
441 const size_t N( A.columns() );
443 auto element( x.begin() );
444 const auto end( x.end() );
448 if( IsUpper_v<MT1> ) {
449 const size_t jend( IsStrictlyUpper_v<MT1> ? element->index()+1UL : element->index() );
450 for(
size_t j=0UL; j<jend; ++j )
454 for( ; element!=
end; ++element )
456 const size_t index( element->index() );
458 if( IsDiagonal_v<MT1> )
460 for(
size_t j=last; j<index; ++j )
463 y[index] = element->value() * A(index,index);
468 const size_t jbegin( ( IsUpper_v<MT1> )
469 ?( IsStrictlyUpper_v<MT1> ? index+1UL : index )
471 const size_t jend( ( IsLower_v<MT1> )
472 ?( IsStrictlyLower_v<MT1> ? index : index+1UL )
476 for(
size_t j=jbegin; j<last; ++j ) {
477 y[j] += element->value() * A(index,j);
479 for(
size_t j=last; j<jend; ++j ) {
480 y[j] = element->value() * A(index,j);
487 if( IsLower_v<MT1> ) {
488 for(
size_t j=last; j<N; ++j )
509 template<
typename VT1
512 static inline auto selectAssignKernel( VT1& y,
const VT2& x,
const MT1& A )
513 -> EnableIf_t< UseOptimizedKernel_v<VT1,VT2,MT1> >
517 const size_t N( A.columns() );
519 auto element( x.begin() );
520 const auto end( x.end() );
527 const size_t i1( element->index() );
528 const VET v1( element->value() );
530 const size_t i2( element->index() );
531 const VET v2( element->value() );
533 const size_t i3( element->index() );
534 const VET v3( element->value() );
536 const size_t i4( element->index() );
537 const VET v4( element->value() );
542 for(
size_t j=0UL; j<N; ++j ) {
543 y[j] = v1 * A(i1,j) + v2 * A(i2,j) + v3 * A(i3,j) + v4 * A(i4,j);
548 const size_t i1( element->index() );
549 const VET v1( element->value() );
552 for(
size_t j=0UL; j<N; ++j ) {
557 for(
size_t i=(ipos>3UL)?(4UL):(1UL); (i+4UL)<=ipos; i+=4UL )
559 const size_t i1( element->index() );
560 const VET v1( element->value() );
562 const size_t i2( element->index() );
563 const VET v2( element->value() );
565 const size_t i3( element->index() );
566 const VET v3( element->value() );
568 const size_t i4( element->index() );
569 const VET v4( element->value() );
574 const size_t jbegin( ( IsUpper_v<MT1> )
575 ?( IsStrictlyUpper_v<MT1> ? i1+1UL : i1 )
577 const size_t jend( ( IsLower_v<MT1> )
578 ?( IsStrictlyLower_v<MT1> ? i4 : i4+1UL )
582 for(
size_t j=jbegin; j<jend; ++j ) {
583 y[j] += v1 * A(i1,j) + v2 * A(i2,j) + v3 * A(i3,j) + v4 * A(i4,j);
586 for( ; element!=
end; ++element )
588 const size_t i1( element->index() );
589 const VET v1( element->value() );
591 const size_t jbegin( ( IsUpper_v<MT1> )
592 ?( IsStrictlyUpper_v<MT1> ? i1+1UL : i1 )
594 const size_t jend( ( IsLower_v<MT1> )
595 ?( IsStrictlyLower_v<MT1> ? i1 : i1+1UL )
599 for(
size_t j=jbegin; j<jend; ++j ) {
600 y[j] += v1 * A(i1,j);
621 template<
typename VT1
624 static inline auto selectAssignKernel( VT1& y,
const VT2& x,
const MT1& A )
625 -> EnableIf_t< UseVectorizedKernel_v<VT1,VT2,MT1> >
629 constexpr bool remainder( !IsPadded_v<VT1> || !IsPadded_v<MT1> );
631 const size_t N( A.columns() );
633 auto element( x.begin() );
634 const auto end( x.end() );
641 const size_t i1( element->index() );
642 const VET v1( element->value() );
644 const size_t i2( element->index() );
645 const VET v2( element->value() );
647 const size_t i3( element->index() );
648 const VET v3( element->value() );
650 const size_t i4( element->index() );
651 const VET v4( element->value() );
667 y.store( j, xmm1 * A.load(i1,j) + xmm2 * A.load(i2,j) + xmm3 * A.load(i3,j) + xmm4 * A.load(i4,j) );
669 for( ; remainder && j<N; ++j ) {
670 y[j] = v1 * A(i1,j) + v2 * A(i2,j) + v3 * A(i3,j) + v4 * A(i4,j);
675 const size_t i1( element->index() );
676 const VET v1( element->value() );
687 y.store( j, xmm1 * A.load(i1,j) );
689 for( ; remainder && j<N; ++j ) {
694 for(
size_t i=(ipos>3UL)?(4UL):(1UL); (i+4UL)<=ipos; i+=4UL )
696 const size_t i1( element->index() );
697 const VET v1( element->value() );
699 const size_t i2( element->index() );
700 const VET v2( element->value() );
702 const size_t i3( element->index() );
703 const VET v3( element->value() );
705 const size_t i4( element->index() );
706 const VET v4( element->value() );
716 const size_t jbegin( ( IsUpper_v<MT1> )
719 const size_t jend( ( IsLower_v<MT1> )
720 ?( IsStrictlyLower_v<MT1> ? i4 : i4+1UL )
730 y.store( j, y.load(j) + xmm1 * A.load(i1,j) + xmm2 * A.load(i2,j) + xmm3 * A.load(i3,j) + xmm4 * A.load(i4,j) );
732 for( ; remainder && j<jend; ++j ) {
733 y[j] += v1 * A(i1,j) + v2 * A(i2,j) + v3 * A(i3,j) + v4 * A(i4,j);
736 for( ; element!=
end; ++element )
738 const size_t i1( element->index() );
739 const VET v1( element->value() );
743 const size_t jbegin( ( IsUpper_v<MT1> )
746 const size_t jend( ( IsLower_v<MT1> )
747 ?( IsStrictlyLower_v<MT1> ? i1 : i1+1UL )
757 y.store( j, y.load(j) + xmm1 * A.load(i1,j) );
759 for( ; remainder && j<jend; ++j ) {
760 y[j] += v1 * A(i1,j);
780 template<
typename VT2 >
781 friend inline void assign( SparseVector<VT2,true>& lhs,
const TSVecDMatMultExpr& rhs )
809 template<
typename VT2 >
818 if( x.nonZeros() == 0UL )
return;
830 TSVecDMatMultExpr::selectAddAssignKernel( *lhs, x, A );
848 template<
typename VT1
851 static inline auto selectAddAssignKernel( VT1& y,
const VT2& x,
const MT1& A )
856 const size_t N( A.columns() );
858 auto element( x.begin() );
859 const auto end( x.end() );
861 for( ; element!=
end; ++element )
863 const size_t index( element->index() );
865 if( IsDiagonal_v<MT1> )
867 y[index] += A(index,index) * element->value();
871 const size_t jbegin( ( IsUpper_v<MT1> )
872 ?( IsStrictlyUpper_v<MT1> ? index+1UL : index )
874 const size_t jend( ( IsLower_v<MT1> )
875 ?( IsStrictlyLower_v<MT1> ? index : index+1UL )
879 for(
size_t j=jbegin; j<jend; ++j ) {
880 y[j] += element->value() * A(index,j);
902 template<
typename VT1
905 static inline auto selectAddAssignKernel( VT1& y,
const VT2& x,
const MT1& A )
906 -> EnableIf_t< UseOptimizedKernel_v<VT1,VT2,MT1> >
910 const size_t N( A.columns() );
912 auto element( x.begin() );
913 const auto end( x.end() );
918 for(
size_t i=0UL; (i+4UL)<=ipos; i+=4UL )
920 const size_t i1( element->index() );
921 const VET v1( element->value() );
923 const size_t i2( element->index() );
924 const VET v2( element->value() );
926 const size_t i3( element->index() );
927 const VET v3( element->value() );
929 const size_t i4( element->index() );
930 const VET v4( element->value() );
935 const size_t jbegin( ( IsUpper_v<MT1> )
936 ?( IsStrictlyUpper_v<MT1> ? i+1UL : i1 )
938 const size_t jend( ( IsLower_v<MT1> )
939 ?( IsStrictlyLower_v<MT1> ? i4 : i4+1UL )
943 for(
size_t j=jbegin; j<jend; ++j ) {
944 y[j] += v1 * A(i1,j) + v2 * A(i2,j) + v3 * A(i3,j) + v4 * A(i4,j);
947 for( ; element!=
end; ++element )
949 const size_t i1( element->index() );
950 const VET v1( element->value() );
952 const size_t jbegin( ( IsUpper_v<MT1> )
953 ?( IsStrictlyUpper_v<MT1> ? i1+1UL : i1 )
955 const size_t jend( ( IsLower_v<MT1> )
956 ?( IsStrictlyLower_v<MT1> ? i1 : i1+1UL )
960 for(
size_t j=jbegin; j<jend; ++j ) {
961 y[j] += v1 * A(i1,j);
982 template<
typename VT1
985 static inline auto selectAddAssignKernel( VT1& y,
const VT2& x,
const MT1& A )
986 -> EnableIf_t< UseVectorizedKernel_v<VT1,VT2,MT1> >
990 constexpr bool remainder( !IsPadded_v<VT1> || !IsPadded_v<MT1> );
992 const size_t N( A.columns() );
994 auto element( x.begin() );
995 const auto end( x.end() );
1000 for(
size_t i=0UL; (i+4UL)<=ipos; i+=4UL )
1002 const size_t i1( element->index() );
1003 const VET v1( element->value() );
1005 const size_t i2( element->index() );
1006 const VET v2( element->value() );
1008 const size_t i3( element->index() );
1009 const VET v3( element->value() );
1011 const size_t i4( element->index() );
1012 const VET v4( element->value() );
1022 const size_t jbegin( ( IsUpper_v<MT1> )
1025 const size_t jend( ( IsLower_v<MT1> )
1026 ?( IsStrictlyLower_v<MT1> ? i4 : i4+1UL )
1036 y.store( j, y.load(j) + xmm1 * A.load(i1,j) + xmm2 * A.load(i2,j) + xmm3 * A.load(i3,j) + xmm4 * A.load(i4,j) );
1038 for( ; remainder && j<jend; ++j ) {
1039 y[j] += v1 * A(i1,j) + v2 * A(i2,j) + v3 * A(i3,j) + v4 * A(i4,j);
1042 for( ; element!=
end; ++element )
1044 const size_t i1( element->index() );
1045 const VET v1( element->value() );
1049 const size_t jbegin( ( IsUpper_v<MT1> )
1052 const size_t jend( ( IsLower_v<MT1> )
1053 ?( IsStrictlyLower_v<MT1> ? i1 : i1+1UL )
1063 y.store( j, y.load(j) + xmm1 * A.load(i1,j) );
1065 for( ; remainder && j<jend; ++j ) {
1066 y[j] += v1 * A(i1,j);
1089 template<
typename VT2 >
1098 if( x.nonZeros() == 0UL )
return;
1110 TSVecDMatMultExpr::selectSubAssignKernel( *lhs, x, A );
1128 template<
typename VT1
1131 static inline auto selectSubAssignKernel( VT1& y,
const VT2& x,
const MT1& A )
1136 const size_t N( A.columns() );
1138 auto element( x.begin() );
1139 const auto end( x.end() );
1141 for( ; element!=
end; ++element )
1143 const size_t index( element->index() );
1145 if( IsDiagonal_v<MT1> )
1147 y[index] -= A(index,index) * element->value();
1151 const size_t jbegin( ( IsUpper_v<MT1> )
1152 ?( IsStrictlyUpper_v<MT1> ? index+1UL : index )
1154 const size_t jend( ( IsLower_v<MT1> )
1155 ?( IsStrictlyLower_v<MT1> ? index : index+1UL )
1159 for(
size_t j=jbegin; j<jend; ++j ) {
1160 y[j] -= element->value() * A(index,j);
1182 template<
typename VT1
1185 static inline auto selectSubAssignKernel( VT1& y,
const VT2& x,
const MT1& A )
1186 -> EnableIf_t< UseOptimizedKernel_v<VT1,VT2,MT1> >
1190 const size_t N( A.columns() );
1192 auto element( x.begin() );
1193 const auto end( x.end() );
1195 const size_t ipos(
prevMultiple( x.nonZeros(), 4UL ) );
1198 for(
size_t i=0UL; (i+4UL)<=ipos; i+=4UL )
1200 const size_t i1( element->index() );
1201 const VET v1( element->value() );
1203 const size_t i2( element->index() );
1204 const VET v2( element->value() );
1206 const size_t i3( element->index() );
1207 const VET v3( element->value() );
1209 const size_t i4( element->index() );
1210 const VET v4( element->value() );
1215 const size_t jbegin( ( IsUpper_v<MT1> )
1216 ?( IsStrictlyUpper_v<MT1> ? i+1UL : i1 )
1218 const size_t jend( ( IsLower_v<MT1> )
1219 ?( IsStrictlyLower_v<MT1> ? i4 : i4+1UL )
1223 for(
size_t j=jbegin; j<jend; ++j ) {
1224 y[j] -= v1 * A(i1,j) + v2 * A(i2,j) + v3 * A(i3,j) + v4 * A(i4,j);
1227 for( ; element!=
end; ++element )
1229 const size_t i1( element->index() );
1230 const VET v1( element->value() );
1232 const size_t jbegin( ( IsUpper_v<MT1> )
1233 ?( IsStrictlyUpper_v<MT1> ? i1+1UL : i1 )
1235 const size_t jend( ( IsLower_v<MT1> )
1236 ?( IsStrictlyLower_v<MT1> ? i1 : i1+1UL )
1240 for(
size_t j=jbegin; j<jend; ++j ) {
1241 y[j] -= v1 * A(i1,j);
1262 template<
typename VT1
1265 static inline auto selectSubAssignKernel( VT1& y,
const VT2& x,
const MT1& A )
1266 -> EnableIf_t< UseVectorizedKernel_v<VT1,VT2,MT1> >
1270 constexpr bool remainder( !IsPadded_v<VT1> || !IsPadded_v<MT1> );
1272 const size_t N( A.columns() );
1274 auto element( x.begin() );
1275 const auto end( x.end() );
1277 const size_t ipos(
prevMultiple( x.nonZeros(), 4UL ) );
1280 for(
size_t i=0UL; (i+4UL)<=ipos; i+=4UL )
1282 const size_t i1( element->index() );
1283 const VET v1( element->value() );
1285 const size_t i2( element->index() );
1286 const VET v2( element->value() );
1288 const size_t i3( element->index() );
1289 const VET v3( element->value() );
1291 const size_t i4( element->index() );
1292 const VET v4( element->value() );
1302 const size_t jbegin( ( IsUpper_v<MT1> )
1305 const size_t jend( ( IsLower_v<MT1> )
1306 ?( IsStrictlyLower_v<MT1> ? i4 : i4+1UL )
1316 y.store( j, y.load(j) - xmm1 * A.load(i1,j) - xmm2 * A.load(i2,j) - xmm3 * A.load(i3,j) - xmm4 * A.load(i4,j) );
1318 for( ; remainder && j<jend; ++j ) {
1319 y[j] -= v1 * A(i1,j) + v2 * A(i2,j) + v3 * A(i3,j) + v4 * A(i4,j);
1322 for( ; element!=
end; ++element )
1324 const size_t i1( element->index() );
1325 const VET v1( element->value() );
1329 const size_t jbegin( ( IsUpper_v<MT1> )
1332 const size_t jend( ( IsLower_v<MT1> )
1333 ?( IsStrictlyLower_v<MT1> ? i1 : i1+1UL )
1343 y.store( j, y.load(j) - xmm1 * A.load(i1,j) );
1345 for( ; remainder && j<jend; ++j ) {
1346 y[j] -= v1 * A(i1,j);
1369 template<
typename VT2 >
1401 template<
typename VT2 >
1436 template<
typename VT2 >
1446 if( x.nonZeros() == 0UL ) {
1481 template<
typename VT2 >
1483 -> EnableIf_t< UseSMPAssign_v<VT2> >
1513 template<
typename VT2 >
1523 if( x.nonZeros() == 0UL )
return;
1557 template<
typename VT2 >
1567 if( x.nonZeros() == 0UL )
return;
1601 template<
typename VT2 >
1636 template<
typename VT2 >
1692template<
typename VT
1694 , DisableIf_t< IsZero_v<VT> >* =
nullptr >
1695inline const TSVecDMatMultExpr<VT,MT>
1696 tsvecdmatmult(
const SparseVector<VT,true>& vec,
const DenseMatrix<MT,false>& mat )
1702 return TSVecDMatMultExpr<VT,MT>( *vec, *mat );
1721template<
typename VT
1723 , EnableIf_t< IsZero_v<VT> >* =
nullptr >
1724inline decltype(
auto)
1725 tsvecdmatmult(
const SparseVector<VT,true>& vec,
const DenseMatrix<MT,false>& mat )
1733 using ReturnType =
const MultTrait_t< ResultType_t<VT>, ResultType_t<MT> >;
1738 return ReturnType( (*mat).columns() );
1775template<
typename VT
1777inline decltype(
auto)
1784 if( (*vec).size() != (*mat).rows() ) {
1788 return tsvecdmatmult( *vec, *mat );
1803template<
typename VT,
typename MT >
1804struct IsAligned< TSVecDMatMultExpr<VT,MT> >
1805 :
public IsAligned<MT>
Header file for auxiliary alias declarations.
typename T::CompositeType CompositeType_t
Alias declaration for nested CompositeType type definitions.
Definition: Aliases.h:110
typename T::ResultType ResultType_t
Alias declaration for nested ResultType type definitions.
Definition: Aliases.h:450
typename T::ElementType ElementType_t
Alias declaration for nested ElementType type definitions.
Definition: Aliases.h:190
typename T::TransposeType TransposeType_t
Alias declaration for nested TransposeType type definitions.
Definition: Aliases.h:550
Header file for run time assertion macros.
Header file for the blaze::checked and blaze::unchecked instances.
Header file for the EnableIf class template.
Header file for the function trace functionality.
Header file for the HasSIMDAdd type trait.
Header file for the HasSIMDMult type trait.
Header file for the If class template.
Header file for the IsAligned type trait.
Header file for the IsComputation type trait class.
Header file for the IsDiagonal type trait.
Header file for the IsExpression type trait class.
Header file for the IsLower type trait.
Header file for the IsPadded type trait.
Header file for the IsResizable type trait.
Header file for the IsSIMDCombinable type trait.
Header file for the IsStrictlyLower type trait.
Header file for the IsStrictlyUpper type trait.
Header file for the IsUpper type trait.
Deactivation of problematic macros.
Header file for the MAYBE_UNUSED function template.
Header file for the multiplication trait.
Header file for the prevMultiple shim.
Constraints on the storage order of matrix types.
Constraint on the transpose flag of vector types.
Header file for all SIMD functionality.
Constraint on the data type.
Base class for dense matrices.
Definition: DenseMatrix.h:82
Base class for N-dimensional dense vectors.
Definition: DenseVector.h:77
SIMD characteristics of data types.
Definition: SIMDTrait.h:297
Base class for sparse vectors.
Definition: SparseVector.h:72
Expression object for transpose sparse vector-dense matrix multiplications.
Definition: TSVecDMatMultExpr.h:111
LeftOperand leftOperand() const noexcept
Returns the left-hand side sparse vector operand.
Definition: TSVecDMatMultExpr.h:312
TransposeType_t< ResultType > TransposeType
Transpose type for expression template evaluations.
Definition: TSVecDMatMultExpr.h:198
CompositeType_t< MT > MCT
Composite type of the right-hand side dense matrix expression.
Definition: TSVecDMatMultExpr.h:119
TSVecDMatMultExpr(const VT &vec, const MT &mat) noexcept
Constructor for the TSVecDMatMultExpr class.
Definition: TSVecDMatMultExpr.h:241
RightOperand mat_
Right-hand side dense matrix of the multiplication expression.
Definition: TSVecDMatMultExpr.h:374
bool isAligned() const noexcept
Returns whether the operands of the expression are properly aligned in memory.
Definition: TSVecDMatMultExpr.h:356
ReturnType operator[](size_t index) const
Subscript operator for the direct access to the vector elements.
Definition: TSVecDMatMultExpr.h:255
If_t< IsExpression_v< MT >, const MT, const MT & > RightOperand
Composite type of the right-hand side sparse matrix expression.
Definition: TSVecDMatMultExpr.h:208
bool canSMPAssign() const noexcept
Returns whether the expression can be used in SMP assignments.
Definition: TSVecDMatMultExpr.h:366
MultTrait_t< VRT, MRT > ResultType
Result type for expression template evaluations.
Definition: TSVecDMatMultExpr.h:197
bool canAlias(const T *alias) const noexcept
Returns whether the expression can alias with the given address alias.
Definition: TSVecDMatMultExpr.h:334
bool isAliased(const T *alias) const noexcept
Returns whether the expression is aliased with the given address alias.
Definition: TSVecDMatMultExpr.h:346
LeftOperand vec_
Left-hand side sparse vector of the multiplication expression.
Definition: TSVecDMatMultExpr.h:373
If_t< evaluateVector, const VRT, VCT > LT
Type for the assignment of the left-hand side sparse vector operand.
Definition: TSVecDMatMultExpr.h:211
ReturnType at(size_t index) const
Checked access to the vector elements.
Definition: TSVecDMatMultExpr.h:289
ElementType_t< ResultType > ElementType
Resulting element type.
Definition: TSVecDMatMultExpr.h:199
SIMDTrait_t< ElementType > SIMDType
Resulting SIMD element type.
Definition: TSVecDMatMultExpr.h:200
static constexpr size_t SIMDSIZE
The number of elements packed within a single SIMD element.
Definition: TSVecDMatMultExpr.h:232
static constexpr bool simdEnabled
Compilation switch for the expression template evaluation strategy.
Definition: TSVecDMatMultExpr.h:219
size_t size() const noexcept
Returns the current size/dimension of the vector.
Definition: TSVecDMatMultExpr.h:302
If_t< evaluateMatrix, const MRT, MCT > RT
Type for the assignment of the right-hand side dense matrix operand.
Definition: TSVecDMatMultExpr.h:214
ResultType_t< MT > MRT
Result type of the right-hand side dense matrix expression.
Definition: TSVecDMatMultExpr.h:115
const ElementType ReturnType
Return type for expression template evaluations.
Definition: TSVecDMatMultExpr.h:201
static constexpr bool evaluateMatrix
Compilation switch for the composite type of the right-hand side dense matrix expression.
Definition: TSVecDMatMultExpr.h:129
static constexpr bool evaluateVector
Compilation switch for the composite type of the left-hand side sparse vector expression.
Definition: TSVecDMatMultExpr.h:124
static constexpr bool smpAssignable
Compilation switch for the expression template assignment strategy.
Definition: TSVecDMatMultExpr.h:226
If_t< IsExpression_v< VT >, const VT, const VT & > LeftOperand
Composite type of the left-hand side sparse vector expression.
Definition: TSVecDMatMultExpr.h:205
const ResultType CompositeType
Data type for composite expression templates.
Definition: TSVecDMatMultExpr.h:202
ElementType_t< MRT > MET
Element type of the right-hand side dense matrix expression.
Definition: TSVecDMatMultExpr.h:117
CompositeType_t< VT > VCT
Composite type of the left-hand side sparse vector expression.
Definition: TSVecDMatMultExpr.h:118
RightOperand rightOperand() const noexcept
Returns the right-hand side dense matrix operand.
Definition: TSVecDMatMultExpr.h:322
ElementType_t< VRT > VET
Element type of the left-hand side sparse vector expression.
Definition: TSVecDMatMultExpr.h:116
ResultType_t< VT > VRT
Result type of the left-hand side sparse vector expression.
Definition: TSVecDMatMultExpr.h:114
Constraint on the data type.
Constraint on the data type.
Constraint on the data type.
Constraint on the data type.
Constraint on the data type.
Constraint on the data type.
Header file for the Computation base class.
Header file for the DenseVector base class.
Header file for the MatMatMultExpr base class.
Header file for the TVecMatMultExpr base class.
decltype(auto) column(Matrix< MT, SO > &matrix, RCAs... args)
Creating a view on a specific column of the given matrix.
Definition: Column.h:137
decltype(auto) serial(const DenseMatrix< MT, SO > &dm)
Forces the serial evaluation of the given dense matrix expression dm.
Definition: DMatSerialExpr.h:812
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:1370
friend auto smpMultAssign(DenseVector< VT2, true > &lhs, const TSVecDMatMultExpr &rhs) -> EnableIf_t< UseSMPAssign_v< VT2 > >
SMP multiplication assignment of a transpose sparse vector-dense matrix multiplication to a dense vec...
Definition: TSVecDMatMultExpr.h:1602
friend auto smpSubAssign(DenseVector< VT2, true > &lhs, const TSVecDMatMultExpr &rhs) -> EnableIf_t< UseSMPAssign_v< VT2 > >
SMP subtraction assignment of a transpose sparse vector-dense matrix multiplication to a dense vector...
Definition: TSVecDMatMultExpr.h:1558
friend auto smpAddAssign(DenseVector< VT2, true > &lhs, const TSVecDMatMultExpr &rhs) -> EnableIf_t< UseSMPAssign_v< VT2 > >
SMP addition assignment of a transpose sparse vector-dense matrix multiplication to a dense vector ( ...
Definition: TSVecDMatMultExpr.h:1514
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:1090
friend void divAssign(DenseVector< VT2, true > &lhs, const TSVecDMatMultExpr &rhs)
Division assignment of a transpose sparse vector-dense matrix multiplication to a dense vector ( ).
Definition: TSVecDMatMultExpr.h:1402
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:810
friend auto smpDivAssign(DenseVector< VT2, true > &lhs, const TSVecDMatMultExpr &rhs) -> EnableIf_t< UseSMPAssign_v< VT2 > >
SMP division assignment of a transpose sparse vector-dense matrix multiplication to a dense vector ( ...
Definition: TSVecDMatMultExpr.h:1637
#define BLAZE_CONSTRAINT_MUST_BE_ROW_MAJOR_MATRIX_TYPE(T)
Constraint on the data type.
Definition: RowMajorMatrix.h:61
#define BLAZE_CONSTRAINT_MUST_NOT_REQUIRE_EVALUATION(T)
Constraint on the data type.
Definition: RequiresEvaluation.h:81
#define BLAZE_CONSTRAINT_MUST_FORM_VALID_TVECMATMULTEXPR(T1, T2)
Constraint on the data type.
Definition: TVecMatMultExpr.h:104
#define BLAZE_CONSTRAINT_MUST_NOT_BE_MATMATMULTEXPR_TYPE(T)
Constraint on the data type.
Definition: MatMatMultExpr.h:83
#define BLAZE_CONSTRAINT_MUST_NOT_BE_ZERO_TYPE(T)
Constraint on the data type.
Definition: Zero.h:81
#define BLAZE_CONSTRAINT_MUST_BE_DENSE_MATRIX_TYPE(T)
Constraint on the data type.
Definition: DenseMatrix.h:61
#define BLAZE_CONSTRAINT_MUST_BE_SPARSE_VECTOR_TYPE(T)
Constraint on the data type.
Definition: SparseVector.h:61
#define BLAZE_CONSTRAINT_MUST_BE_DENSE_VECTOR_TYPE(T)
Constraint on the data type.
Definition: DenseVector.h:61
#define BLAZE_CONSTRAINT_MUST_BE_ROW_VECTOR_TYPE(T)
Constraint on the data type.
Definition: RowVector.h:61
#define BLAZE_CONSTRAINT_MUST_BE_ZERO_TYPE(T)
Constraint on the data type.
Definition: Zero.h:61
typename MultTrait< T1, T2 >::Type MultTrait_t
Auxiliary alias declaration for the MultTrait class template.
Definition: MultTrait.h:165
BLAZE_ALWAYS_INLINE constexpr auto prevMultiple(T1 value, T2 factor) noexcept
Rounds down an integral value to the previous multiple of a given factor.
Definition: PrevMultiple.h:68
constexpr void reset(Matrix< MT, SO > &matrix)
Resetting the given matrix.
Definition: Matrix.h:806
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:584
MT::Iterator begin(Matrix< MT, SO > &matrix, size_t i)
Returns an iterator to the first element of row/column i.
Definition: Matrix.h:518
#define BLAZE_INTERNAL_ASSERT(expr, msg)
Run time assertion macro for internal checks.
Definition: Assert.h:101
BLAZE_ALWAYS_INLINE const EnableIf_t< IsIntegral_v< T > &&HasSize_v< T, 1UL >, If_t< IsSigned_v< T >, SIMDint8, SIMDuint8 > > set(T value) noexcept
Sets all values in the vector to the given 1-byte integral value.
Definition: Set.h:75
typename SIMDTrait< T >::Type SIMDTrait_t
Auxiliary alias declaration for the SIMDTrait class template.
Definition: SIMDTrait.h:315
auto smpAssign(Matrix< MT1, SO1 > &lhs, const Matrix< MT2, SO2 > &rhs) -> EnableIf_t< IsDenseMatrix_v< MT1 > >
Default implementation of the SMP assignment of a matrix to a dense matrix.
Definition: DenseMatrix.h:100
decltype(auto) subvector(Vector< VT, TF > &, RSAs...)
Creating a view on a specific subvector of the given vector.
Definition: Subvector.h:158
typename EnableIf< Condition, T >::Type EnableIf_t
Auxiliary type for the EnableIf class template.
Definition: EnableIf.h:138
constexpr void MAYBE_UNUSED(const Args &...)
Suppression of unused parameter warnings.
Definition: MaybeUnused.h:81
typename If< Condition >::template Type< T1, T2 > If_t
Auxiliary alias template for the If class template.
Definition: If.h:108
#define BLAZE_THROW_OUT_OF_RANGE(MESSAGE)
Macro for the emission of a std::out_of_range exception.
Definition: Exception.h:331
#define BLAZE_THROW_INVALID_ARGUMENT(MESSAGE)
Macro for the emission of a std::invalid_argument exception.
Definition: Exception.h:235
#define BLAZE_FUNCTION_TRACE
Function trace macro.
Definition: FunctionTrace.h:94
constexpr Unchecked unchecked
Global Unchecked instance.
Definition: Check.h:146
Header file for the exception macros of the math module.
Header file for all forward declarations for expression class templates.
Header file for the reset shim.
Header file for the serial shim.
Base class for all compute expression templates.
Definition: Computation.h:68
Base class for all vector/matrix multiplication expression templates.
Definition: TVecMatMultExpr.h:69
System settings for performance optimizations.
Header file for the thresholds for matrix/vector and matrix/matrix multiplications.
Header file for the IsZero type trait.
Header file for the RequiresEvaluation type trait.
Header file for basic type definitions.