35#ifndef _BLAZE_MATH_BLAS_GEMM_H_
36#define _BLAZE_MATH_BLAS_GEMM_H_
68template<
typename MT1,
bool SO1,
typename MT2,
bool SO2,
typename MT3,
bool SO3,
typename ST >
69void gemm( DenseMatrix<MT1,SO1>& C,
const DenseMatrix<MT2,SO2>& A,
70 const DenseMatrix<MT3,SO3>& B, ST alpha, ST beta );
105inline void gemm( DenseMatrix<MT1,SO1>& C,
const DenseMatrix<MT2,SO2>& A,
106 const DenseMatrix<MT3,SO3>& B, ST alpha, ST beta )
120 const blas_int_t m ( numeric_cast<blas_int_t>( (*A).rows() ) );
121 const blas_int_t n ( numeric_cast<blas_int_t>( (*B).columns() ) );
122 const blas_int_t k ( numeric_cast<blas_int_t>( (*A).columns() ) );
123 const blas_int_t lda( numeric_cast<blas_int_t>( (*A).spacing() ) );
124 const blas_int_t ldb( numeric_cast<blas_int_t>( (*B).spacing() ) );
125 const blas_int_t ldc( numeric_cast<blas_int_t>( (*C).spacing() ) );
127 gemm( ( IsRowMajorMatrix_v<MT1> )?( CblasRowMajor ):( CblasColMajor ),
128 ( SO1 == SO2 )?( CblasNoTrans ):( CblasTrans ),
129 ( SO1 == SO3 )?( CblasNoTrans ):( CblasTrans ),
130 m, n, k, alpha, (*A).data(), lda, (*B).data(), ldb, beta, (*C).data(), ldc );
Header file for auxiliary alias declarations.
Constraint on the data type.
Constraint on the data type.
Header file for the IsRowMajorMatrix type trait.
Constraint on the data type.
Cast operators for numeric types.
Header file for the CBLAS gemm wrapper functions.
Constraint on the data type.
Header file for the DenseMatrix base class.
#define BLAZE_CONSTRAINT_MUST_BE_BLAS_COMPATIBLE_TYPE(T)
Constraint on the data type.
Definition: BLASCompatible.h:61
#define BLAZE_CONSTRAINT_MUST_NOT_BE_COMPUTATION_TYPE(T)
Constraint on the data type.
Definition: Computation.h:81
#define BLAZE_CONSTRAINT_MUST_HAVE_MUTABLE_DATA_ACCESS(T)
Constraint on the data type.
Definition: MutableDataAccess.h:61
#define BLAZE_CONSTRAINT_MUST_HAVE_CONST_DATA_ACCESS(T)
Constraint on the data type.
Definition: ConstDataAccess.h:61
int32_t blas_int_t
Signed integer type used in the BLAS/LAPACK wrapper functions.
Definition: Types.h:64
System settings for the BLAS mode.