I started using the magma routines for sparse Matrices. Especially I need matrix-matrix-multiplication. So I looked in the documentation and found "magma_scuspmm", an interface to the cuSparse function "csrmm". But then I got stucked, because the definition of the struct "magma_[z,c,s,d]_sparse matrix" is without documentation. I even checked the cuSparse documentation but couldn't find out all. Can somebody help me, please?
I found the header file (see below). Some of the variables open up to me clearly. But others are not so self-explaining like:
- diagorder_type - There are 4 types, what means every type?
- nnz - It's an integer, and i don't know which meaning it has.
- max_nnz_row - same like nnz.
- diameter - same like nnz.
- diag - A float pointer, but i don't know what it means.
- row, rowidx, col - normally the crs-format has 3 arrays: value, row pointer, column index. Col is clearly the column index but what mean the other two: row, rowidx
- blockinfo - an integer pointer but I don't know the meaning
- blocksize, numblocks, alignment - all are integers but I don't know the meanings
Code: Select all
typedef struct magma_s_sparse_matrix{
magma_storage_t storage_type;
magma_location_t memory_location;
magma_symmetry_t sym;
magma_diagorder_t diagorder_type;
magma_int_t num_rows;
magma_int_t num_cols;
magma_int_t nnz;
magma_int_t max_nnz_row;
magma_int_t diameter;
float *val;
float *diag;
magma_index_t *row;
magma_index_t *rowidx;
magma_index_t *col;
magma_index_t *blockinfo;
magma_int_t blocksize;
magma_int_t numblocks;
magma_int_t alignment;
}magma_s_sparse_matrix;