33 #ifndef EIGEN_TRIANGULAR_SOLVER_MATRIX_BLAS_H 34 #define EIGEN_TRIANGULAR_SOLVER_MATRIX_BLAS_H 41 #define EIGEN_BLAS_TRSM_L(EIGTYPE, BLASTYPE, BLASFUNC) \ 42 template <typename Index, int Mode, bool Conjugate, int TriStorageOrder> \ 43 struct triangular_solve_matrix<EIGTYPE,Index,OnTheLeft,Mode,Conjugate,TriStorageOrder,ColMajor> \ 46 IsLower = (Mode&Lower) == Lower, \ 47 IsUnitDiag = (Mode&UnitDiag) ? 1 : 0, \ 48 IsZeroDiag = (Mode&ZeroDiag) ? 1 : 0, \ 49 conjA = ((TriStorageOrder==ColMajor) && Conjugate) ? 1 : 0 \ 52 Index size, Index otherSize, \ 53 const EIGTYPE* _tri, Index triStride, \ 54 EIGTYPE* _other, Index otherStride, level3_blocking<EIGTYPE,EIGTYPE>& ) \ 56 BlasIndex m = convert_index<BlasIndex>(size), n = convert_index<BlasIndex>(otherSize), lda, ldb; \ 57 char side = 'L', uplo, diag='N', transa; \ 60 ldb = convert_index<BlasIndex>(otherStride);\ 64 transa = (TriStorageOrder==RowMajor) ? ((Conjugate) ? 'C' : 'T') : 'N'; \ 66 uplo = IsLower ? 'L' : 'U'; \ 67 if (TriStorageOrder==RowMajor) uplo = (uplo == 'L') ? 'U' : 'L'; \ 69 typedef Matrix<EIGTYPE, Dynamic, Dynamic, TriStorageOrder> MatrixTri; \ 70 Map<const MatrixTri, 0, OuterStride<> > tri(_tri,size,size,OuterStride<>(triStride)); \ 74 a_tmp = tri.conjugate(); \ 76 lda = convert_index<BlasIndex>(a_tmp.outerStride()); \ 79 lda = convert_index<BlasIndex>(triStride); \ 81 if (IsUnitDiag) diag='U'; \ 83 BLASFUNC(&side, &uplo, &transa, &diag, &m, &n, (const BLASTYPE*)&numext::real_ref(alpha), (const BLASTYPE*)a, &lda, (BLASTYPE*)_other, &ldb); \ 100 #define EIGEN_BLAS_TRSM_R(EIGTYPE, BLASTYPE, BLASFUNC) \ 101 template <typename Index, int Mode, bool Conjugate, int TriStorageOrder> \ 102 struct triangular_solve_matrix<EIGTYPE,Index,OnTheRight,Mode,Conjugate,TriStorageOrder,ColMajor> \ 105 IsLower = (Mode&Lower) == Lower, \ 106 IsUnitDiag = (Mode&UnitDiag) ? 1 : 0, \ 107 IsZeroDiag = (Mode&ZeroDiag) ? 1 : 0, \ 108 conjA = ((TriStorageOrder==ColMajor) && Conjugate) ? 1 : 0 \ 111 Index size, Index otherSize, \ 112 const EIGTYPE* _tri, Index triStride, \ 113 EIGTYPE* _other, Index otherStride, level3_blocking<EIGTYPE,EIGTYPE>& ) \ 115 BlasIndex m = convert_index<BlasIndex>(otherSize), n = convert_index<BlasIndex>(size), lda, ldb; \ 116 char side = 'R', uplo, diag='N', transa; \ 119 ldb = convert_index<BlasIndex>(otherStride);\ 123 transa = (TriStorageOrder==RowMajor) ? ((Conjugate) ? 'C' : 'T') : 'N'; \ 125 uplo = IsLower ? 'L' : 'U'; \ 126 if (TriStorageOrder==RowMajor) uplo = (uplo == 'L') ? 'U' : 'L'; \ 128 typedef Matrix<EIGTYPE, Dynamic, Dynamic, TriStorageOrder> MatrixTri; \ 129 Map<const MatrixTri, 0, OuterStride<> > tri(_tri,size,size,OuterStride<>(triStride)); \ 133 a_tmp = tri.conjugate(); \ 135 lda = convert_index<BlasIndex>(a_tmp.outerStride()); \ 138 lda = convert_index<BlasIndex>(triStride); \ 140 if (IsUnitDiag) diag='U'; \ 142 BLASFUNC(&side, &uplo, &transa, &diag, &m, &n, (const BLASTYPE*)&numext::real_ref(alpha), (const BLASTYPE*)a, &lda, (BLASTYPE*)_other, &ldb); \ 163 #endif // EIGEN_TRIANGULAR_SOLVER_MATRIX_BLAS_H int BLASFUNC() ztrsm(char *, char *, char *, char *, int *, int *, double *, double *, int *, double *, int *)
Namespace containing all symbols from the Eigen library.
int BLASFUNC() ctrsm(char *, char *, char *, char *, int *, int *, float *, float *, int *, float *, int *)
#define EIGEN_BLAS_TRSM_R(EIGTYPE, BLASTYPE, BLASFUNC)
std::complex< float > scomplex
std::complex< double > dcomplex
int BLASFUNC() dtrsm(char *, char *, char *, char *, int *, int *, double *, double *, int *, double *, int *)
#define EIGEN_BLAS_TRSM_L(EIGTYPE, BLASTYPE, BLASFUNC)
int BLASFUNC() strsm(char *, char *, char *, char *, int *, int *, float *, float *, int *, float *, int *)