hipsparsexcsrgeamnnz Interface Reference#
hipfort_hipsparse::hipsparsexcsrgeamnnz Interface Reference
Public Member Functions | |
| integer(kind(hipsparse_status_success)) function | hipsparsexcsrgeamnnz_ (handle, m, n, descra, nnza, csrrowptra, csrcolinda, descrb, nnzb, csrrowptrb, csrcolindb, descrc, csrrowptrc, nnztotaldevhostptr) |
| integer(kind(hipsparse_status_success)) function | hipsparsexcsrgeamnnz_rank_0 (handle, m, n, descra, nnza, csrrowptra, csrcolinda, descrb, nnzb, csrrowptrb, csrcolindb, descrc, csrrowptrc, nnztotaldevhostptr) |
| integer(kind(hipsparse_status_success)) function | hipsparsexcsrgeamnnz_rank_1 (handle, m, n, descra, nnza, csrrowptra, csrcolinda, descrb, nnzb, csrrowptrb, csrcolindb, descrc, csrrowptrc, nnztotaldevhostptr) |
Detailed Description
hipsparseXcsrgeamNnz computes the total CSR non-zero elements and the CSR row offsets that point to the start of every row of the sparse CSR matrix of the resulting matrix \(C\). It is assumed that csrRowPtrC has been allocated with size m+1. The desired index base in the output CSR matrix is set in the hipsparseMatDescr_t. See hipsparseSetMatIndexBase().
For a full code example, see hipsparseScsrgeam().
- Note
- As indicated,
nnzTotalDevHostPtrcan point to either host or device memory. This is controlled by setting the pointer mode. SeehipsparseSetPointerMode(). - This function is non-blocking and executed asynchronously with respect to the host. It can return before the actual computation has finished.
-
Currently, only
HIPSPARSE_MATRIX_TYPE_GENERALis supported.
- Deprecated:
- This function is deprecated and will be removed in a future release.
- Parameters
-
[in] handle - handle to the hipSPARSE library context queue. [in] m - number of rows of the sparse CSR matrices \(A\), \(B\), and \(C\). Must be non-negative. [in] n - number of columns of the sparse CSR matrices \(A\), \(B\), and \(C\). Must be non-negative. [in] descrA - descriptor of the sparse CSR matrix \(A\). Currently, only HIPSPARSE_MATRIX_TYPE_GENERALis supported.[in] nnzA - number of non-zero entries of the sparse CSR matrix \(A\). Must be non-negative. [in] csrRowPtrA - array of m+1elements that point to the start of every row of the sparse CSR matrix \(A\).[in] csrColIndA - array of nnzAelements containing the column indices of the sparse CSR matrix \(A\).[in] descrB - descriptor of the sparse CSR matrix \(B\). Currently, only HIPSPARSE_MATRIX_TYPE_GENERALis supported.[in] nnzB - number of non-zero entries of the sparse CSR matrix \(B\). Must be non-negative. [in] csrRowPtrB - array of m+1elements that point to the start of every row of the sparse CSR matrix \(B\).[in] csrColIndB - array of nnzBelements containing the column indices of the sparse CSR matrix \(B\).[in] descrC - descriptor of the sparse CSR matrix \(C\). Currently, only HIPSPARSE_MATRIX_TYPE_GENERALis supported.[out] csrRowPtrC - array of m+1elements that point to the start of every row of the sparse CSR matrix \(C\).[out] nnzTotalDevHostPtr - pointer to the number of non-zero entries of the sparse CSR matrix \(C\). nnzTotalDevHostPtrcan be a host or device pointer.
- Return values
-
HIPSPARSE_STATUS_SUCCESS the operation completed successfully. HIPSPARSE_STATUS_NOT_INITIALIZED handleis not initialized.HIPSPARSE_STATUS_INVALID_VALUE handle,descrA,descrB, ordescrCis nullptr,m,n,nnzA, ornnzBis negative, orcsrRowPtrA,csrColIndA,csrRowPtrB,csrColIndB,csrRowPtrC, ornnzTotalDevHostPtris nullptr.HIPSPARSE_STATUS_NOT_SUPPORTED hipsparseMatrixType_tis notHIPSPARSE_MATRIX_TYPE_GENERAL.
Member Function/Subroutine Documentation
◆ hipsparsexcsrgeamnnz_()
| integer(kind(hipsparse_status_success)) function hipfort_hipsparse::hipsparsexcsrgeamnnz::hipsparsexcsrgeamnnz_ | ( | type(c_ptr), value | handle, |
| integer(c_int), value | m, | ||
| integer(c_int), value | n, | ||
| type(c_ptr), value | descra, | ||
| integer(c_int), value | nnza, | ||
| type(c_ptr), value | csrrowptra, | ||
| type(c_ptr), value | csrcolinda, | ||
| type(c_ptr), value | descrb, | ||
| integer(c_int), value | nnzb, | ||
| type(c_ptr), value | csrrowptrb, | ||
| type(c_ptr), value | csrcolindb, | ||
| type(c_ptr), value | descrc, | ||
| type(c_ptr), value | csrrowptrc, | ||
| integer(c_int) | nnztotaldevhostptr | ||
| ) |
◆ hipsparsexcsrgeamnnz_rank_0()
| integer(kind(hipsparse_status_success)) function hipfort_hipsparse::hipsparsexcsrgeamnnz::hipsparsexcsrgeamnnz_rank_0 | ( | type(c_ptr) | handle, |
| integer(c_int) | m, | ||
| integer(c_int) | n, | ||
| type(c_ptr) | descra, | ||
| integer(c_int) | nnza, | ||
| integer(c_int), target | csrrowptra, | ||
| integer(c_int), target | csrcolinda, | ||
| type(c_ptr) | descrb, | ||
| integer(c_int) | nnzb, | ||
| integer(c_int), target | csrrowptrb, | ||
| integer(c_int), target | csrcolindb, | ||
| type(c_ptr) | descrc, | ||
| integer(c_int), target | csrrowptrc, | ||
| integer(c_int) | nnztotaldevhostptr | ||
| ) |
◆ hipsparsexcsrgeamnnz_rank_1()
| integer(kind(hipsparse_status_success)) function hipfort_hipsparse::hipsparsexcsrgeamnnz::hipsparsexcsrgeamnnz_rank_1 | ( | type(c_ptr) | handle, |
| integer(c_int) | m, | ||
| integer(c_int) | n, | ||
| type(c_ptr) | descra, | ||
| integer(c_int) | nnza, | ||
| integer(c_int), dimension(:), target | csrrowptra, | ||
| integer(c_int), dimension(:), target | csrcolinda, | ||
| type(c_ptr) | descrb, | ||
| integer(c_int) | nnzb, | ||
| integer(c_int), dimension(:), target | csrrowptrb, | ||
| integer(c_int), dimension(:), target | csrcolindb, | ||
| type(c_ptr) | descrc, | ||
| integer(c_int), dimension(:), target | csrrowptrc, | ||
| integer(c_int) | nnztotaldevhostptr | ||
| ) |
The documentation for this interface was generated from the following file: