Intel® oneAPI Math Kernel Library
Ask questions and share information with other developers who use Intel® Math Kernel Library.
7113 Discussions

weird no const keyword for '*beta' of DSYR2K in mkl_blas.h

Lee__Heungson
Beginner
817 Views

In 'mkl_blas.h'

void DSYR2K(const char *uplo, const char *trans, const MKL_INT *n, const MKL_INT *k,
            const double *alpha, const double *a, const MKL_INT *lda, const double *b, const MKL_INT *ldb,
            double *beta, double *c, const MKL_INT *ldc);

There is no const keyword for '*beta'.

 

On the other hand, these two have const keyword for '*beta'

void SSYR2K(const char *uplo, const char *trans, const MKL_INT *n, const MKL_INT *k,
            const float *alpha, const float *a, const MKL_INT *lda, const float *b, const MKL_INT *ldb,
            const float *beta, float *c, const MKL_INT *ldc);

void ZSYR2K(const char *uplo, const char *trans, const MKL_INT *n, const MKL_INT *k,
            const MKL_Complex16 *alpha, const MKL_Complex16 *a, const MKL_INT *lda,
            const MKL_Complex16 *b, const MKL_INT *ldb, const MKL_Complex16 *beta,
            MKL_Complex16 *c, const MKL_INT *ldc);

 

Are there any reasons for this inconsistency? 

 

Because in my development environment, macros are used to deal with different types and these forms should be consistent with each other. But I see some functions don't have const consistency for different types. So it would be more convenient for some users like me if these were fixed in the future release.

 

Thank you.

0 Kudos
4 Replies
Gennady_F_Intel
Moderator
817 Views

Thanks for the issue. We will definitely fix this case in the next update.

0 Kudos
Gennady_F_Intel
Moderator
817 Views

the issue is escalated and we will keep this thread updated.

0 Kudos
Gennady_F_Intel
Moderator
804 Views

the fix of the problem available in mkl v.2020 update 2 which available for download.

0 Kudos
Gennady_F_Intel
Moderator
803 Views

void DSYR2K(const char *uplo, const char *trans, const MKL_INT *n, const MKL_INT *k,
const double *alpha, const double *a, const MKL_INT *lda, const double *b, const MKL_INT *ldb,
const double *beta, double *c, const MKL_INT *ldc) NOTHROW;

0 Kudos
Reply