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

Deal with huge matrix

chao_n_
Beginner
268 Views

I have written some codes with MKL library, but recently these codes do not work. They can be complied well and do not report any error when I run it. However, they did not work for some huge matrix operations. They keep running, but no results return. Here is an example code. When the variable nID exceed 31, the program will keep running forever.

#include <stdio.h>
#include <mkl.h>
int main(){
int nID=31;
int nSNP=33;
double *mMatrix = (double*) calloc(nID*nSNP,sizeof(double));
double *AGmatrix = (double*) calloc(nID*nID,sizeof(double));
    const CBLAS_LAYOUT Layout=CblasRowMajor;
    double alpha=1;
    double beta=0;
    cblas_dgemm (Layout, CblasTrans, CblasNoTrans, nID, nID, nSNP, alpha, mMatrix, 
nID, mMatrix, nID, beta, AGmatrix, nID);
0 Kudos
0 Replies
Reply