Intel® oneAPI Math Kernel Library
Ask questions and share information with other developers who use Intel® Math Kernel Library.
Announcements
The Intel sign-in experience has changed to support enhanced security controls. If you sign in, click here for more information.
6698 Discussions

Call to LAPACKE_zunmlq cause access violation

Dmitriy_Prokhorov
213 Views

Hello,

I am trying to apply Q obtained from LAPACKE_zgelqf to the rectangular matrix from the right using LAPACKE_zunmlq.

 

#include "mkl.h"

int main() {


int m = 637;
int rows1 = m;
int columns1 = 3 * m;
int lda1 = rows1;

MKL_Complex16* matrix1 = new MKL_Complex16[rows1 * columns1];
for (int i = 0; i < rows1 * columns1; ++i) {

matrix1[i] = { (double)i, (double)i };

}

int rows2 = 3 * m + 1;
int columns2 = 3 * m;
int lda2 = rows2;
MKL_Complex16* matrix2 = new MKL_Complex16[rows2 * columns2];
for (int i = 0; i < rows2 * columns2; ++i) {


matrix2[i] = { (double)i, (double)i };

}
int refl = rows1;
MKL_Complex16* tau = new MKL_Complex16[refl];

int info = 0;
info = LAPACKE_zgelqf(LAPACK_COL_MAJOR, rows1, columns1, matrix1, lda1, tau);
info = LAPACKE_zunmlq(LAPACK_COL_MAJOR, 'R', 'C', rows2, columns2, refl, matrix1, lda1, tau, matrix2, lda2);
delete[] tau;
delete[] matrix1;
delete[] matrix2;

}

 

I am sure that all parameters have appropriate values but call to the LAPACKE_zunmlq cause access violation. 

I run this code using VS 2019 with oneAPI 2022.0 on the machine with Windows 10.

 

Am I missing something obvious or is there a bug in LAPACKE_zunmlq

Thanks for helping me

 

0 Kudos
3 Replies
ShanmukhS_Intel
Moderator
178 Views

Hi,


Thank you for posting on Intel Communities.


Could please let us know if you are getting the same issue when trying it from Intel oneAPI command prompt? and also do let us know if this happens in both sequential and parallel mode of execution.


Best Regards,

Shanmukh.SS


Dmitriy_Prokhorov
140 Views
Thank you for your response.

I can't currently check described functionality. But using fortran interface zunmlq with equivalent parameters instead of LAPACKE_zumlq solves the problem.

Best regards,
Dmitriy Prokhorov
ShanmukhS_Intel
Moderator
146 Views

Hi,


We are working on your issue. We will get back to you soon with an update.


Best Regards,

Shanmukh.SS


Reply