35 #ifndef _BLAZE_MATH_SMP_THREADS_DENSEMATRIX_H_
36 #define _BLAZE_MATH_SMP_THREADS_DENSEMATRIX_H_
94 template<
typename MT1
97 void smpAssign_backend( DenseMatrix<MT1,SO>& lhs,
const DenseMatrix<MT2,rowMajor>& rhs )
105 typedef IntrinsicTrait<typename MT1::ElementType> IT;
106 typedef typename SubmatrixExprTrait<MT1,aligned>::Type AlignedTarget;
107 typedef typename SubmatrixExprTrait<MT1,unaligned>::Type UnalignedTarget;
109 const bool vectorizable( MT1::vectorizable && MT2::vectorizable && IsSame<ET1,ET2>::value );
110 const bool lhsAligned ( (~lhs).isAligned() );
111 const bool rhsAligned ( (~rhs).isAligned() );
114 const size_t addon ( ( ( (~lhs).
rows() % threads ) != 0UL )? 1UL : 0UL );
115 const size_t equalShare ( (~lhs).
rows() / threads + addon );
116 const size_t rest ( equalShare & (
IT::size - 1UL ) );
117 const size_t rowsPerThread( ( vectorizable && rest )?( equalShare - rest +
IT::size ):( equalShare ) );
119 for(
size_t i=0UL; i<threads; ++i )
121 const size_t row( i*rowsPerThread );
126 const size_t m(
min( rowsPerThread, (~lhs).
rows() -
row ) );
128 if( vectorizable && lhsAligned && rhsAligned ) {
129 AlignedTarget target( submatrix<aligned>( ~lhs,
row, 0UL, m, (~lhs).
columns() ) );
130 TheThreadBackend::scheduleAssign( target, submatrix<aligned>( ~rhs,
row, 0UL, m, (~lhs).
columns() ) );
132 else if( vectorizable && lhsAligned ) {
133 AlignedTarget target( submatrix<aligned>( ~lhs,
row, 0UL, m, (~lhs).
columns() ) );
134 TheThreadBackend::scheduleAssign( target, submatrix<unaligned>( ~rhs,
row, 0UL, m, (~lhs).
columns() ) );
136 else if( vectorizable && rhsAligned ) {
137 UnalignedTarget target( submatrix<unaligned>( ~lhs,
row, 0UL, m, (~lhs).
columns() ) );
138 TheThreadBackend::scheduleAssign( target, submatrix<aligned>( ~rhs,
row, 0UL, m, (~lhs).
columns() ) );
141 UnalignedTarget target( submatrix<unaligned>( ~lhs,
row, 0UL, m, (~lhs).
columns() ) );
142 TheThreadBackend::scheduleAssign( target, submatrix<unaligned>( ~rhs,
row, 0UL, m, (~lhs).
columns() ) );
146 TheThreadBackend::wait();
169 template<
typename MT1
172 void smpAssign_backend( DenseMatrix<MT1,SO>& lhs,
const DenseMatrix<MT2,columnMajor>& rhs )
180 typedef IntrinsicTrait<typename MT1::ElementType> IT;
181 typedef typename SubmatrixExprTrait<MT1,aligned>::Type AlignedTarget;
182 typedef typename SubmatrixExprTrait<MT1,unaligned>::Type UnalignedTarget;
184 const bool vectorizable( MT1::vectorizable && MT2::vectorizable && IsSame<ET1,ET2>::value );
185 const bool lhsAligned ( (~lhs).isAligned() );
186 const bool rhsAligned ( (~rhs).isAligned() );
189 const size_t addon ( ( ( (~lhs).
columns() % threads ) != 0UL )? 1UL : 0UL );
190 const size_t equalShare ( (~lhs).
columns() / threads + addon );
191 const size_t rest ( equalShare & (
IT::size - 1UL ) );
192 const size_t colsPerThread( ( vectorizable && rest )?( equalShare - rest +
IT::size ):( equalShare ) );
194 for(
size_t i=0UL; i<threads; ++i )
196 const size_t column( i*colsPerThread );
203 if( vectorizable && lhsAligned && rhsAligned ) {
204 AlignedTarget target( submatrix<aligned>( ~lhs, 0UL,
column, (~lhs).
rows(), n ) );
205 TheThreadBackend::scheduleAssign( target, submatrix<aligned>( ~rhs, 0UL,
column, (~lhs).
rows(), n ) );
207 else if( vectorizable && lhsAligned ) {
208 AlignedTarget target( submatrix<aligned>( ~lhs, 0UL,
column, (~lhs).
rows(), n ) );
209 TheThreadBackend::scheduleAssign( target, submatrix<unaligned>( ~rhs, 0UL,
column, (~lhs).
rows(), n ) );
211 else if( vectorizable && rhsAligned ) {
212 UnalignedTarget target( submatrix<unaligned>( ~lhs, 0UL,
column, (~lhs).
rows(), n ) );
213 TheThreadBackend::scheduleAssign( target, submatrix<aligned>( ~rhs, 0UL,
column, (~lhs).
rows(), n ) );
216 UnalignedTarget target( submatrix<unaligned>( ~lhs, 0UL,
column, (~lhs).
rows(), n ) );
217 TheThreadBackend::scheduleAssign( target, submatrix<unaligned>( ~rhs, 0UL,
column, (~lhs).
rows(), n ) );
221 TheThreadBackend::wait();
244 template<
typename MT1
247 void smpAssign_backend( DenseMatrix<MT1,SO>& lhs,
const SparseMatrix<MT2,rowMajor>& rhs )
255 typedef typename SubmatrixExprTrait<MT1,unaligned>::Type UnalignedTarget;
258 const size_t addon ( ( ( (~lhs).
rows() % threads ) != 0UL )? 1UL : 0UL );
259 const size_t rowsPerThread( (~lhs).
rows() / threads + addon );
261 for(
size_t i=0UL; i<threads; ++i )
263 const size_t row( i*rowsPerThread );
268 const size_t m(
min( rowsPerThread, (~lhs).
rows() -
row ) );
269 UnalignedTarget target( submatrix<unaligned>( ~lhs,
row, 0UL, m, (~lhs).
columns() ) );
270 TheThreadBackend::scheduleAssign( target, submatrix<unaligned>( ~rhs,
row, 0UL, m, (~lhs).
columns() ) );
273 TheThreadBackend::wait();
296 template<
typename MT1
299 void smpAssign_backend( DenseMatrix<MT1,SO>& lhs,
const SparseMatrix<MT2,columnMajor>& rhs )
307 typedef typename SubmatrixExprTrait<MT1,unaligned>::Type UnalignedTarget;
310 const size_t addon ( ( ( (~lhs).
columns() % threads ) != 0UL )? 1UL : 0UL );
311 const size_t colsPerThread( (~lhs).
columns() / threads + addon );
313 for(
size_t i=0UL; i<threads; ++i )
315 const size_t column( i*colsPerThread );
321 UnalignedTarget target( submatrix<unaligned>( ~lhs, 0UL,
column, (~lhs).
rows(), n ) );
322 TheThreadBackend::scheduleAssign( target, submatrix<unaligned>( ~rhs, 0UL,
column, (~lhs).
rows(), n ) );
325 TheThreadBackend::wait();
349 template<
typename MT1
353 inline typename EnableIf< And< IsDenseMatrix<MT1>
354 , Or< Not< IsSMPAssignable<MT1> >
355 , Not< IsSMPAssignable<MT2> > > > >::Type
356 smpAssign( Matrix<MT1,SO1>& lhs,
const Matrix<MT2,SO2>& rhs )
363 assign( ~lhs, ~rhs );
387 template<
typename MT1
391 inline typename EnableIf< And< IsDenseMatrix<MT1>
392 , IsSMPAssignable<MT1>
393 , IsSMPAssignable<MT2> > >::Type
394 smpAssign( Matrix<MT1,SO1>& lhs,
const Matrix<MT2,SO2>& rhs )
407 assign( ~lhs, ~rhs );
410 smpAssign_backend( ~lhs, ~rhs );
443 template<
typename MT1
446 void smpAddAssign_backend( DenseMatrix<MT1,SO>& lhs,
const DenseMatrix<MT2,rowMajor>& rhs )
454 typedef IntrinsicTrait<typename MT1::ElementType> IT;
455 typedef typename SubmatrixExprTrait<MT1,aligned>::Type AlignedTarget;
456 typedef typename SubmatrixExprTrait<MT1,unaligned>::Type UnalignedTarget;
458 const bool vectorizable( MT1::vectorizable && MT2::vectorizable && IsSame<ET1,ET2>::value );
459 const bool lhsAligned ( (~lhs).isAligned() );
460 const bool rhsAligned ( (~rhs).isAligned() );
463 const size_t addon ( ( ( (~lhs).
rows() % threads ) != 0UL )? 1UL : 0UL );
464 const size_t equalShare ( (~lhs).
rows() / threads + addon );
465 const size_t rest ( equalShare & (
IT::size - 1UL ) );
466 const size_t rowsPerThread( ( vectorizable && rest )?( equalShare - rest +
IT::size ):( equalShare ) );
468 for(
size_t i=0UL; i<threads; ++i )
470 const size_t row( i*rowsPerThread );
475 const size_t m(
min( rowsPerThread, (~lhs).
rows() -
row ) );
477 if( vectorizable && lhsAligned && rhsAligned ) {
478 AlignedTarget target( submatrix<aligned>( ~lhs,
row, 0UL, m, (~lhs).
columns() ) );
479 TheThreadBackend::scheduleAddAssign( target, submatrix<aligned>( ~rhs,
row, 0UL, m, (~lhs).
columns() ) );
481 else if( vectorizable && lhsAligned ) {
482 AlignedTarget target( submatrix<aligned>( ~lhs,
row, 0UL, m, (~lhs).
columns() ) );
483 TheThreadBackend::scheduleAddAssign( target, submatrix<unaligned>( ~rhs,
row, 0UL, m, (~lhs).
columns() ) );
485 else if( vectorizable && rhsAligned ) {
486 UnalignedTarget target( submatrix<unaligned>( ~lhs,
row, 0UL, m, (~lhs).
columns() ) );
487 TheThreadBackend::scheduleAddAssign( target, submatrix<aligned>( ~rhs,
row, 0UL, m, (~lhs).
columns() ) );
490 UnalignedTarget target( submatrix<unaligned>( ~lhs,
row, 0UL, m, (~lhs).
columns() ) );
491 TheThreadBackend::scheduleAddAssign( target, submatrix<unaligned>( ~rhs,
row, 0UL, m, (~lhs).
columns() ) );
495 TheThreadBackend::wait();
518 template<
typename MT1
521 void smpAddAssign_backend( DenseMatrix<MT1,SO>& lhs,
const DenseMatrix<MT2,columnMajor>& rhs )
529 typedef IntrinsicTrait<typename MT1::ElementType> IT;
530 typedef typename SubmatrixExprTrait<MT1,aligned>::Type AlignedTarget;
531 typedef typename SubmatrixExprTrait<MT1,unaligned>::Type UnalignedTarget;
533 const bool vectorizable( MT1::vectorizable && MT2::vectorizable && IsSame<ET1,ET2>::value );
534 const bool lhsAligned ( (~lhs).isAligned() );
535 const bool rhsAligned ( (~rhs).isAligned() );
538 const size_t addon ( ( ( (~lhs).
columns() % threads ) != 0UL )? 1UL : 0UL );
539 const size_t equalShare ( (~lhs).
columns() / threads + addon );
540 const size_t rest ( equalShare & (
IT::size - 1UL ) );
541 const size_t colsPerThread( ( vectorizable && rest )?( equalShare - rest +
IT::size ):( equalShare ) );
543 for(
size_t i=0UL; i<threads; ++i )
545 const size_t column( i*colsPerThread );
552 if( vectorizable && lhsAligned && rhsAligned ) {
553 AlignedTarget target( submatrix<aligned>( ~lhs, 0UL,
column, (~lhs).
rows(), n ) );
554 TheThreadBackend::scheduleAddAssign( target, submatrix<aligned>( ~rhs, 0UL,
column, (~lhs).
rows(), n ) );
556 else if( vectorizable && lhsAligned ) {
557 AlignedTarget target( submatrix<aligned>( ~lhs, 0UL,
column, (~lhs).
rows(), n ) );
558 TheThreadBackend::scheduleAddAssign( target, submatrix<unaligned>( ~rhs, 0UL,
column, (~lhs).
rows(), n ) );
560 else if( vectorizable && rhsAligned ) {
561 UnalignedTarget target( submatrix<unaligned>( ~lhs, 0UL,
column, (~lhs).
rows(), n ) );
562 TheThreadBackend::scheduleAddAssign( target, submatrix<aligned>( ~rhs, 0UL,
column, (~lhs).
rows(), n ) );
565 UnalignedTarget target( submatrix<unaligned>( ~lhs, 0UL,
column, (~lhs).
rows(), n ) );
566 TheThreadBackend::scheduleAddAssign( target, submatrix<unaligned>( ~rhs, 0UL,
column, (~lhs).
rows(), n ) );
570 TheThreadBackend::wait();
593 template<
typename MT1
596 void smpAddAssign_backend( DenseMatrix<MT1,SO>& lhs,
const SparseMatrix<MT2,rowMajor>& rhs )
604 typedef typename SubmatrixExprTrait<MT1,unaligned>::Type UnalignedTarget;
607 const size_t addon ( ( ( (~lhs).
rows() % threads ) != 0UL )? 1UL : 0UL );
608 const size_t rowsPerThread( (~lhs).
rows() / threads + addon );
610 for(
size_t i=0UL; i<threads; ++i )
612 const size_t row( i*rowsPerThread );
617 const size_t m(
min( rowsPerThread, (~lhs).
rows() -
row ) );
618 UnalignedTarget target( submatrix<unaligned>( ~lhs,
row, 0UL, m, (~lhs).
columns() ) );
619 TheThreadBackend::scheduleAddAssign( target, submatrix<unaligned>( ~rhs,
row, 0UL, m, (~lhs).
columns() ) );
622 TheThreadBackend::wait();
645 template<
typename MT1
648 void smpAddAssign_backend( DenseMatrix<MT1,SO>& lhs,
const SparseMatrix<MT2,columnMajor>& rhs )
656 typedef typename SubmatrixExprTrait<MT1,unaligned>::Type UnalignedTarget;
659 const size_t addon ( ( ( (~lhs).
columns() % threads ) != 0UL )? 1UL : 0UL );
660 const size_t colsPerThread( (~lhs).
columns() / threads + addon );
662 for(
size_t i=0UL; i<threads; ++i )
664 const size_t column( i*colsPerThread );
670 UnalignedTarget target( submatrix<unaligned>( ~lhs, 0UL,
column, (~lhs).
rows(), n ) );
671 TheThreadBackend::scheduleAddAssign( target, submatrix<unaligned>( ~rhs, 0UL,
column, (~lhs).
rows(), n ) );
674 TheThreadBackend::wait();
699 template<
typename MT1
703 inline typename EnableIf< And< IsDenseMatrix<MT1>
704 , Or< Not< IsSMPAssignable<MT1> >
705 , Not< IsSMPAssignable<MT2> > > > >::Type
706 smpAddAssign( Matrix<MT1,SO1>& lhs,
const Matrix<MT2,SO2>& rhs )
713 addAssign( ~lhs, ~rhs );
737 template<
typename MT1
741 inline typename EnableIf< And< IsDenseMatrix<MT1>
742 , IsSMPAssignable<MT1>
743 , IsSMPAssignable<MT2> > >::Type
744 smpAddAssign( Matrix<MT1,SO1>& lhs,
const Matrix<MT2,SO2>& rhs )
757 addAssign( ~lhs, ~rhs );
760 smpAddAssign_backend( ~lhs, ~rhs );
793 template<
typename MT1
796 void smpSubAssign_backend( DenseMatrix<MT1,SO>& lhs,
const DenseMatrix<MT2,rowMajor>& rhs )
804 typedef IntrinsicTrait<typename MT1::ElementType> IT;
805 typedef typename SubmatrixExprTrait<MT1,aligned>::Type AlignedTarget;
806 typedef typename SubmatrixExprTrait<MT1,unaligned>::Type UnalignedTarget;
808 const bool vectorizable( MT1::vectorizable && MT2::vectorizable && IsSame<ET1,ET2>::value );
809 const bool lhsAligned ( (~lhs).isAligned() );
810 const bool rhsAligned ( (~rhs).isAligned() );
813 const size_t addon ( ( ( (~lhs).
rows() % threads ) != 0UL )? 1UL : 0UL );
814 const size_t equalShare ( (~lhs).
rows() / threads + addon );
815 const size_t rest ( equalShare & (
IT::size - 1UL ) );
816 const size_t rowsPerThread( ( vectorizable && rest )?( equalShare - rest +
IT::size ):( equalShare ) );
818 for(
size_t i=0UL; i<threads; ++i )
820 const size_t row( i*rowsPerThread );
825 const size_t m(
min( rowsPerThread, (~lhs).
rows() -
row ) );
827 if( vectorizable && lhsAligned && rhsAligned ) {
828 AlignedTarget target( submatrix<aligned>( ~lhs,
row, 0UL, m, (~lhs).
columns() ) );
829 TheThreadBackend::scheduleSubAssign( target, submatrix<aligned>( ~rhs,
row, 0UL, m, (~lhs).
columns() ) );
831 else if( vectorizable && lhsAligned ) {
832 AlignedTarget target( submatrix<aligned>( ~lhs,
row, 0UL, m, (~lhs).
columns() ) );
833 TheThreadBackend::scheduleSubAssign( target, submatrix<unaligned>( ~rhs,
row, 0UL, m, (~lhs).
columns() ) );
835 else if( vectorizable && rhsAligned ) {
836 UnalignedTarget target( submatrix<unaligned>( ~lhs,
row, 0UL, m, (~lhs).
columns() ) );
837 TheThreadBackend::scheduleSubAssign( target, submatrix<aligned>( ~rhs,
row, 0UL, m, (~lhs).
columns() ) );
840 UnalignedTarget target( submatrix<unaligned>( ~lhs,
row, 0UL, m, (~lhs).
columns() ) );
841 TheThreadBackend::scheduleSubAssign( target, submatrix<unaligned>( ~rhs,
row, 0UL, m, (~lhs).
columns() ) );
845 TheThreadBackend::wait();
868 template<
typename MT1
871 void smpSubAssign_backend( DenseMatrix<MT1,SO>& lhs,
const DenseMatrix<MT2,columnMajor>& rhs )
879 typedef IntrinsicTrait<typename MT1::ElementType> IT;
880 typedef typename SubmatrixExprTrait<MT1,aligned>::Type AlignedTarget;
881 typedef typename SubmatrixExprTrait<MT1,unaligned>::Type UnalignedTarget;
883 const bool vectorizable( MT1::vectorizable && MT2::vectorizable && IsSame<ET1,ET2>::value );
884 const bool lhsAligned ( (~lhs).isAligned() );
885 const bool rhsAligned ( (~rhs).isAligned() );
888 const size_t addon ( ( ( (~lhs).
columns() % threads ) != 0UL )? 1UL : 0UL );
889 const size_t equalShare ( (~lhs).
columns() / threads + addon );
890 const size_t rest ( equalShare & (
IT::size - 1UL ) );
891 const size_t colsPerThread( ( vectorizable && rest )?( equalShare - rest +
IT::size ):( equalShare ) );
893 for(
size_t i=0UL; i<threads; ++i )
895 const size_t column( i*colsPerThread );
902 if( vectorizable && lhsAligned && rhsAligned ) {
903 AlignedTarget target( submatrix<aligned>( ~lhs, 0UL,
column, (~lhs).
rows(), n ) );
904 TheThreadBackend::scheduleSubAssign( target, submatrix<aligned>( ~rhs, 0UL,
column, (~lhs).
rows(), n ) );
906 else if( vectorizable && lhsAligned ) {
907 AlignedTarget target( submatrix<aligned>( ~lhs, 0UL,
column, (~lhs).
rows(), n ) );
908 TheThreadBackend::scheduleSubAssign( target, submatrix<unaligned>( ~rhs, 0UL,
column, (~lhs).
rows(), n ) );
910 else if( vectorizable && rhsAligned ) {
911 UnalignedTarget target( submatrix<unaligned>( ~lhs, 0UL,
column, (~lhs).
rows(), n ) );
912 TheThreadBackend::scheduleSubAssign( target, submatrix<aligned>( ~rhs, 0UL,
column, (~lhs).
rows(), n ) );
915 UnalignedTarget target( submatrix<unaligned>( ~lhs, 0UL,
column, (~lhs).
rows(), n ) );
916 TheThreadBackend::scheduleSubAssign( target, submatrix<unaligned>( ~rhs, 0UL,
column, (~lhs).
rows(), n ) );
920 TheThreadBackend::wait();
943 template<
typename MT1
946 void smpSubAssign_backend( DenseMatrix<MT1,SO>& lhs,
const SparseMatrix<MT2,rowMajor>& rhs )
954 typedef typename SubmatrixExprTrait<MT1,unaligned>::Type UnalignedTarget;
957 const size_t addon ( ( ( (~lhs).
rows() % threads ) != 0UL )? 1UL : 0UL );
958 const size_t rowsPerThread( (~lhs).
rows() / threads + addon );
960 for(
size_t i=0UL; i<threads; ++i )
962 const size_t row( i*rowsPerThread );
967 const size_t m(
min( rowsPerThread, (~lhs).
rows() -
row ) );
968 UnalignedTarget target( submatrix<unaligned>( ~lhs,
row, 0UL, m, (~lhs).
columns() ) );
969 TheThreadBackend::scheduleSubAssign( target, submatrix<unaligned>( ~rhs,
row, 0UL, m, (~lhs).
columns() ) );
972 TheThreadBackend::wait();
995 template<
typename MT1
998 void smpSubAssign_backend( DenseMatrix<MT1,SO>& lhs,
const SparseMatrix<MT2,columnMajor>& rhs )
1006 typedef typename SubmatrixExprTrait<MT1,unaligned>::Type UnalignedTarget;
1009 const size_t addon ( ( ( (~lhs).
columns() % threads ) != 0UL )? 1UL : 0UL );
1010 const size_t colsPerThread( (~lhs).
columns() / threads + addon );
1012 for(
size_t i=0UL; i<threads; ++i )
1014 const size_t column( i*colsPerThread );
1020 UnalignedTarget target( submatrix<unaligned>( ~lhs, 0UL,
column, (~lhs).
rows(), n ) );
1021 TheThreadBackend::scheduleSubAssign( target, submatrix<unaligned>( ~rhs, 0UL,
column, (~lhs).
rows(), n ) );
1024 TheThreadBackend::wait();
1049 template<
typename MT1
1053 inline typename EnableIf< And< IsDenseMatrix<MT1>
1054 , Or< Not< IsSMPAssignable<MT1> >
1055 , Not< IsSMPAssignable<MT2> > > > >::Type
1056 smpSubAssign( Matrix<MT1,SO1>& lhs,
const Matrix<MT2,SO2>& rhs )
1063 subAssign( ~lhs, ~rhs );
1088 template<
typename MT1
1092 inline typename EnableIf< And< IsDenseMatrix<MT1>
1093 , IsSMPAssignable<MT1>
1094 , IsSMPAssignable<MT2> > >::Type
1095 smpSubAssign( Matrix<MT1,SO1>& lhs,
const Matrix<MT2,SO2>& rhs )
1108 subAssign( ~lhs, ~rhs );
1111 smpSubAssign_backend( ~lhs, ~rhs );
1144 template<
typename MT1
1148 inline typename EnableIf< IsDenseMatrix<MT1> >::Type
1149 smpMultAssign( Matrix<MT1,SO1>& lhs,
const Matrix<MT2,SO2>& rhs )
1156 multAssign( ~lhs, ~rhs );
Header file for mathematical functions.
Header file for basic type definitions.
BLAZE_ALWAYS_INLINE size_t size(const Vector< VT, TF > &vector)
Returns the current size/dimension of the vector.
Definition: Vector.h:252
#define BLAZE_BOOST_THREADS_PARALLEL_MODE
Compilation switch for the Boost parallelization.This compilation switch enables/disables the paralle...
Definition: SMP.h:122
Header file for the IsSame and IsStrictlySame type traits.
BLAZE_ALWAYS_INLINE size_t rows(const Matrix< MT, SO > &matrix)
Returns the current number of rows of the matrix.
Definition: Matrix.h:308
DisableIf< Or< IsComputation< MT >, IsTransExpr< MT > >, typename ColumnExprTrait< MT >::Type >::Type column(Matrix< MT, SO > &matrix, size_t index)
Creating a view on a specific column of the given matrix.
Definition: Column.h:107
Header file for the And class template.
Header file for the intrinsic trait.
Header file for the SparseMatrix base class.
Header file for the matrix storage order types.
#define BLAZE_CONSTRAINT_MUST_NOT_BE_SMP_ASSIGNABLE(T)
Constraint on the data type.In case the given data type T is SMP-assignable (can be assigned by multi...
Definition: SMPAssignable.h:118
Header file for the complete DenseSubmatrix implementation.
Namespace of the Blaze C++ math library.
Definition: Blaze.h:57
System settings for the shared-memory parallelization.
Header file for the IsSMPAssignable type trait.
Header file for the Or class template.
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 Not class template.
Header file for the serial section implementation.
#define BLAZE_CPP_THREADS_PARALLEL_MODE
Compilation switch for the C++11 parallelization.This compilation switch enables/disables the paralle...
Definition: SMP.h:95
Header file for the parallel section implementation.
Type ElementType
Type of the sparse matrix elements.
Definition: CompressedMatrix.h:2586
Header file for the IsDenseMatrix type trait.
Header file for the EnableIf class template.
#define BLAZE_PARALLEL_SECTION
Section for the debugging of the shared-memory parallelization.During the shared-memory parallel (SMP...
Definition: ParallelSection.h:246
DisableIf< Or< IsComputation< MT >, IsTransExpr< MT > >, typename RowExprTrait< MT >::Type >::Type row(Matrix< MT, SO > &matrix, size_t index)
Creating a view on a specific row of the given matrix.
Definition: Row.h:107
bool isSerialSectionActive()
Returns whether a serial section is active or not.
Definition: SerialSection.h:213
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
Header file for the SubmatrixExprTrait class template.
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
Header file for the complete SparseSubmatrix implementation.
bool isParallelSectionActive()
Returns whether a parallel section is active or not.
Definition: ParallelSection.h:213
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
BLAZE_ALWAYS_INLINE size_t columns(const Matrix< MT, SO > &matrix)
Returns the current number of columns of the matrix.
Definition: Matrix.h:324
Header file for the C++11 and Boost thread backend.
#define BLAZE_STATIC_ASSERT(expr)
Compile time assertion macro.In case of an invalid compile time expression, a compilation error is cr...
Definition: StaticAssert.h:143
EnableIf< IsDenseVector< VT1 > >::Type smpMultAssign(Vector< 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:189
#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
Constraint on the data type.
Header file for the FunctionTrace class.