Visible to Intel only — GUID: GUID-68E3377A-B04A-4DBA-BD0A-BACDBEDD1A23
Visible to Intel only — GUID: GUID-68E3377A-B04A-4DBA-BD0A-BACDBEDD1A23
oneapi::mkl::sparse::set_matmat_data
Sets the appropriate oneapi::mkl::sparse::matrix_view_descr and oneapi::mkl::transpose values in the oneapi::mkl::sparse::matmat_descr_t object reflecting the sparse::matmat operation to be performed: .
Description
The oneapi::mkl::sparse::set_matmat_data routine enables the user to set the desired sparse matrix - sparse matrix operation in the oneapi::mkl::sparse::matmat_descr_t object which will be used in the sparse::matmat routine.
The oneapi::mkl::sparse::matrix_view_descr enum class is defined in the oneapi/mkl/spblas.hpp header file
namespace oneapi::mkl::sparse {
enum class matrix_view_descr : std::int32_t {
general
};
}
where general view assumes all data is populated in the sparse::matrix_handle_t object for both lower, diagonal and upper portions of the matrix. A common usage model for the matmat descriptor is the following:
using namespace oneapi::mkl;
sparse::matmat_descr_t descr = nullptr;
sparse::init_matmat_descr(&descr);
// example descriptor for general
// C = A * B
sparse::matrix_view_descr viewA = sparse::matrix_view_descr::general;
sparse::matrix_view_descr viewB = sparse::matrix_view_descr::general;
sparse::matrix_view_descr viewC = sparse::matrix_view_descr::general;
transpose opA = transpose::nontrans;
transpose opB = transpose::nontrans;
sparse::set_matmat_data(descr, viewA, opA, viewB, opB, viewC);
// use descr in sparse::matmat() api
sparse::release_matmat_descr(&descr);
API
Syntax
namespace oneapi::mkl::sparse {
void set_matmat_descr (
sparse::matmat_descr_t descr,
sparse::matrix_view_descr viewA,
transpose opA,
sparse::matrix_view_descr viewB,
transpose opB,
sparse::matrix_view_descr viewC);
}
Include Files
oneapi/mkl/spblas.hpp
Input Parameters
- viewA, viewB, viewC
-
sparse::matrix_view_descr enum values describing how the , and matrix representations are to be viewed. Currently, only the general type is supported.
- opA, opB
-
Specifies operation op() on input matrix.
oneapi::mkl::transpose::nontrans
Non-transpose, .
oneapi::mkl::transpose::trans
Transpose, .
oneapi::mkl::transpose::conjtrans
Conjugate transpose, .
NOTE:Currently, the only supported case for operation is oneapi::mkl::transpose::nontrans.
Output Parameters
- descr
-
sparse::matmat_descr_t object used to define the sparse matrix - sparse matrix operation to be performed by the sparse::matmat routine.