Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Max_G_2
Beginner
58 Views

MKL inspector-executor mkl_sparse_optimize returns SPARSE_STATUS_NOT_SUPPORTED

I'm trying to get a test program working with the MKL inspector-executor framework, but I'm getting the rather opaque error code SPARSE_STATUS_NOT_SUPPORTED from mkl_sparse_optimize and it isn't clear what I'm doing wrong. I was hoping I could get some help. Below is a snippet of my code:

71             sparse_matrix_t mkl_ie_csr;
72             CHECK_IE(mkl_sparse_d_create_csr(&mkl_ie_csr,
73                     SPARSE_INDEX_BASE_ZERO, mkl_csr.m, mkl_csr.n,
74                     mkl_csr.row_pointers, rows_end, mkl_csr.columns,
75                     mkl_csr.values));
76
77             struct matrix_descr descr;
78             descr.type = SPARSE_MATRIX_TYPE_GENERAL;
79             descr.mode = SPARSE_FILL_MODE_LOWER;
80             descr.diag = SPARSE_DIAG_NON_UNIT;
81             // May return 6 (SPARSE_STATUS_NOT_SUPPORTED) if repeats == 1
82             CHECK_IE(mkl_sparse_set_mv_hint(mkl_ie_csr,
83                     SPARSE_OPERATION_NON_TRANSPOSE, descr,
84                     repeats));
85             CHECK_IE(mkl_sparse_set_memory_hint(mkl_ie_csr,
86                         SPARSE_MEMORY_AGGRESSIVE));
87             CHECK_IE(mkl_sparse_optimize(mkl_ie_csr));
88             for (r = 0; r < repeats; r++) {
89                status = mkl_sparse_d_mv(SPARSE_OPERATION_NON_TRANSPOSE, 1.0,
90                        &mkl_ie_csr, SPARSE_MATRIX_TYPE_DIAGONAL, x, 1.0, y); 
91                assert(status == SPARSE_STATUS_SUCCESS);
92             }

CHECK_IE is just a macro that verifies SPARSE_STATUS_SUCCESS, and exits otherwise.

When I run this example, I get the error on line 87 after calling mkl_sparse_optimize. Now, if I remove the call to mkl_sparse_optimize everything runs and validates against my reference data so it seems like this is mostly correct. I just don't have any understanding of what specific misconfigurations could be causing an unsupported error to be returned from mkl_sparse_optimize. Can I get any clarification on that?

Thanks!

Max

0 Kudos
1 Reply
Gennady_F_Intel
Moderator
58 Views

Max, all is ok with your code. the problem is not all optimizations are implemented into the current version. We will improve that into one of the future updates. thanks, Gennady

Reply