Skip to content

Commit

Permalink
[HIPIFY][#674][rocSPARSE][feature] rocSPARSE support - Step 55 - func…
Browse files Browse the repository at this point in the history
…tions rocsparse_(s|d|c|z)bsrsm_buffer_size

+ Updated synthetic tests and the regenerated hipify-perl and SPARSE docs
  • Loading branch information
emankov committed Nov 5, 2023
1 parent 2ac1279 commit 702ee31
Show file tree
Hide file tree
Showing 7 changed files with 105 additions and 13 deletions.
4 changes: 4 additions & 0 deletions bin/hipify-perl
Original file line number Diff line number Diff line change
Expand Up @@ -1759,6 +1759,7 @@ sub rocSubstitutions {
subst("cusparseCbsrilu02_analysis", "rocsparse_cbsrilu0_analysis", "library");
subst("cusparseCbsrilu02_numericBoost", "rocsparse_dcbsrilu0_numeric_boost", "library");
subst("cusparseCbsrsm2_analysis", "rocsparse_cbsrsm_analysis", "library");
subst("cusparseCbsrsm2_bufferSize", "rocsparse_cbsrsm_buffer_size", "library");
subst("cusparseCbsrsm2_solve", "rocsparse_cbsrsm_solve", "library");
subst("cusparseCcsc2dense", "rocsparse_ccsc2dense", "library");
subst("cusparseCcsr2bsr", "rocsparse_ccsr2bsr", "library");
Expand Down Expand Up @@ -1827,6 +1828,7 @@ sub rocSubstitutions {
subst("cusparseDbsrilu02_analysis", "rocsparse_dbsrilu0_analysis", "library");
subst("cusparseDbsrilu02_numericBoost", "rocsparse_dbsrilu0_numeric_boost", "library");
subst("cusparseDbsrsm2_analysis", "rocsparse_dbsrsm_analysis", "library");
subst("cusparseDbsrsm2_bufferSize", "rocsparse_dbsrsm_buffer_size", "library");
subst("cusparseDbsrsm2_solve", "rocsparse_dbsrsm_solve", "library");
subst("cusparseDcsc2dense", "rocsparse_dcsc2dense", "library");
subst("cusparseDcsr2bsr", "rocsparse_dcsr2bsr", "library");
Expand Down Expand Up @@ -1913,6 +1915,7 @@ sub rocSubstitutions {
subst("cusparseSbsrilu02_analysis", "rocsparse_sbsrilu0_analysis", "library");
subst("cusparseSbsrilu02_numericBoost", "rocsparse_dsbsrilu0_numeric_boost", "library");
subst("cusparseSbsrsm2_analysis", "rocsparse_sbsrsm_analysis", "library");
subst("cusparseSbsrsm2_bufferSize", "rocsparse_sbsrsm_buffer_size", "library");
subst("cusparseSbsrsm2_solve", "rocsparse_sbsrsm_solve", "library");
subst("cusparseScatter", "rocsparse_scatter", "library");
subst("cusparseScsc2dense", "rocsparse_scsc2dense", "library");
Expand Down Expand Up @@ -2010,6 +2013,7 @@ sub rocSubstitutions {
subst("cusparseZbsrilu02_analysis", "rocsparse_zbsrilu0_analysis", "library");
subst("cusparseZbsrilu02_numericBoost", "rocsparse_zbsrilu0_numeric_boost", "library");
subst("cusparseZbsrsm2_analysis", "rocsparse_zbsrsm_analysis", "library");
subst("cusparseZbsrsm2_bufferSize", "rocsparse_zbsrsm_buffer_size", "library");
subst("cusparseZbsrsm2_solve", "rocsparse_zbsrsm_solve", "library");
subst("cusparseZcsc2dense", "rocsparse_zcsc2dense", "library");
subst("cusparseZcsr2bsr", "rocsparse_zcsr2bsr", "library");
Expand Down
8 changes: 4 additions & 4 deletions docs/tables/CUSPARSE_API_supported_by_HIP_and_ROC.md
Original file line number Diff line number Diff line change
Expand Up @@ -381,7 +381,7 @@
|:--|:-:|:-:|:-:|:-:|:--|:-:|:-:|:-:|:-:|:-:|:--|:-:|:-:|:-:|:-:|:-:|
|`cusparseCbsrmm`| | | | |`hipsparseCbsrmm`|3.7.0| | | | | | | | | | |
|`cusparseCbsrsm2_analysis`| |12.2| | |`hipsparseCbsrsm2_analysis`|4.5.0| | | | |`rocsparse_cbsrsm_analysis`|3.6.0| | | | |
|`cusparseCbsrsm2_bufferSize`| |12.2| | |`hipsparseCbsrsm2_bufferSize`|4.5.0| | | | | | | | | | |
|`cusparseCbsrsm2_bufferSize`| |12.2| | |`hipsparseCbsrsm2_bufferSize`|4.5.0| | | | |`rocsparse_cbsrsm_buffer_size`|4.5.0| | | | |
|`cusparseCbsrsm2_bufferSizeExt`| |12.2| | | | | | | | | | | | | | |
|`cusparseCbsrsm2_solve`| |12.2| | |`hipsparseCbsrsm2_solve`|4.5.0| | | | |`rocsparse_cbsrsm_solve`|4.5.0| | | | |
|`cusparseCcsrmm`| |10.2| |11.0|`hipsparseCcsrmm`|3.1.0| | | | | | | | | | |
Expand All @@ -394,7 +394,7 @@
|`cusparseCgemmi`|8.0|11.0| |12.0|`hipsparseCgemmi`|3.7.0| | | | | | | | | | |
|`cusparseDbsrmm`| | | | |`hipsparseDbsrmm`|3.7.0| | | | | | | | | | |
|`cusparseDbsrsm2_analysis`| |12.2| | |`hipsparseDbsrsm2_analysis`|4.5.0| | | | |`rocsparse_dbsrsm_analysis`|3.6.0| | | | |
|`cusparseDbsrsm2_bufferSize`| |12.2| | |`hipsparseDbsrsm2_bufferSize`|4.5.0| | | | | | | | | | |
|`cusparseDbsrsm2_bufferSize`| |12.2| | |`hipsparseDbsrsm2_bufferSize`|4.5.0| | | | |`rocsparse_dbsrsm_buffer_size`|4.5.0| | | | |
|`cusparseDbsrsm2_bufferSizeExt`| |12.2| | | | | | | | | | | | | | |
|`cusparseDbsrsm2_solve`| |12.2| | |`hipsparseDbsrsm2_solve`|4.5.0| | | | |`rocsparse_dbsrsm_solve`|4.5.0| | | | |
|`cusparseDcsrmm`| |10.2| |11.0|`hipsparseDcsrmm`|1.9.2| | | | | | | | | | |
Expand All @@ -407,7 +407,7 @@
|`cusparseDgemmi`|8.0|11.0| |12.0|`hipsparseDgemmi`|3.7.0| | | | | | | | | | |
|`cusparseSbsrmm`| | | | |`hipsparseSbsrmm`|3.7.0| | | | | | | | | | |
|`cusparseSbsrsm2_analysis`| |12.2| | |`hipsparseSbsrsm2_analysis`|4.5.0| | | | |`rocsparse_sbsrsm_analysis`|3.6.0| | | | |
|`cusparseSbsrsm2_bufferSize`| |12.2| | |`hipsparseSbsrsm2_bufferSize`|4.5.0| | | | | | | | | | |
|`cusparseSbsrsm2_bufferSize`| |12.2| | |`hipsparseSbsrsm2_bufferSize`|4.5.0| | | | |`rocsparse_sbsrsm_buffer_size`|4.5.0| | | | |
|`cusparseSbsrsm2_bufferSizeExt`| |12.2| | | | | | | | | | | | | | |
|`cusparseSbsrsm2_solve`| |12.2| | |`hipsparseSbsrsm2_solve`|4.5.0| | | | |`rocsparse_sbsrsm_solve`|4.5.0| | | | |
|`cusparseScsrmm`| |10.2| |11.0|`hipsparseScsrmm`|1.9.2| | | | | | | | | | |
Expand All @@ -422,7 +422,7 @@
|`cusparseXcsrsm2_zeroPivot`|10.0|11.3| |12.0|`hipsparseXcsrsm2_zeroPivot`|3.1.0| | | | | | | | | | |
|`cusparseZbsrmm`| | | | |`hipsparseZbsrmm`|3.7.0| | | | | | | | | | |
|`cusparseZbsrsm2_analysis`| |12.2| | |`hipsparseZbsrsm2_analysis`|4.5.0| | | | |`rocsparse_zbsrsm_analysis`|3.6.0| | | | |
|`cusparseZbsrsm2_bufferSize`| |12.2| | |`hipsparseZbsrsm2_bufferSize`|4.5.0| | | | | | | | | | |
|`cusparseZbsrsm2_bufferSize`| |12.2| | |`hipsparseZbsrsm2_bufferSize`|4.5.0| | | | |`rocsparse_zbsrsm_buffer_size`|4.5.0| | | | |
|`cusparseZbsrsm2_bufferSizeExt`| |12.2| | | | | | | | | | | | | | |
|`cusparseZbsrsm2_solve`| |12.2| | |`hipsparseZbsrsm2_solve`|4.5.0| | | | |`rocsparse_zbsrsm_solve`|4.5.0| | | | |
|`cusparseZcsrmm`| |10.2| |11.0|`hipsparseZcsrmm`|3.1.0| | | | | | | | | | |
Expand Down
8 changes: 4 additions & 4 deletions docs/tables/CUSPARSE_API_supported_by_ROC.md
Original file line number Diff line number Diff line change
Expand Up @@ -381,7 +381,7 @@
|:--|:-:|:-:|:-:|:-:|:--|:-:|:-:|:-:|:-:|:-:|
|`cusparseCbsrmm`| | | | | | | | | | |
|`cusparseCbsrsm2_analysis`| |12.2| | |`rocsparse_cbsrsm_analysis`|3.6.0| | | | |
|`cusparseCbsrsm2_bufferSize`| |12.2| | | | | | | | |
|`cusparseCbsrsm2_bufferSize`| |12.2| | |`rocsparse_cbsrsm_buffer_size`|4.5.0| | | | |
|`cusparseCbsrsm2_bufferSizeExt`| |12.2| | | | | | | | |
|`cusparseCbsrsm2_solve`| |12.2| | |`rocsparse_cbsrsm_solve`|4.5.0| | | | |
|`cusparseCcsrmm`| |10.2| |11.0| | | | | | |
Expand All @@ -394,7 +394,7 @@
|`cusparseCgemmi`|8.0|11.0| |12.0| | | | | | |
|`cusparseDbsrmm`| | | | | | | | | | |
|`cusparseDbsrsm2_analysis`| |12.2| | |`rocsparse_dbsrsm_analysis`|3.6.0| | | | |
|`cusparseDbsrsm2_bufferSize`| |12.2| | | | | | | | |
|`cusparseDbsrsm2_bufferSize`| |12.2| | |`rocsparse_dbsrsm_buffer_size`|4.5.0| | | | |
|`cusparseDbsrsm2_bufferSizeExt`| |12.2| | | | | | | | |
|`cusparseDbsrsm2_solve`| |12.2| | |`rocsparse_dbsrsm_solve`|4.5.0| | | | |
|`cusparseDcsrmm`| |10.2| |11.0| | | | | | |
Expand All @@ -407,7 +407,7 @@
|`cusparseDgemmi`|8.0|11.0| |12.0| | | | | | |
|`cusparseSbsrmm`| | | | | | | | | | |
|`cusparseSbsrsm2_analysis`| |12.2| | |`rocsparse_sbsrsm_analysis`|3.6.0| | | | |
|`cusparseSbsrsm2_bufferSize`| |12.2| | | | | | | | |
|`cusparseSbsrsm2_bufferSize`| |12.2| | |`rocsparse_sbsrsm_buffer_size`|4.5.0| | | | |
|`cusparseSbsrsm2_bufferSizeExt`| |12.2| | | | | | | | |
|`cusparseSbsrsm2_solve`| |12.2| | |`rocsparse_sbsrsm_solve`|4.5.0| | | | |
|`cusparseScsrmm`| |10.2| |11.0| | | | | | |
Expand All @@ -422,7 +422,7 @@
|`cusparseXcsrsm2_zeroPivot`|10.0|11.3| |12.0| | | | | | |
|`cusparseZbsrmm`| | | | | | | | | | |
|`cusparseZbsrsm2_analysis`| |12.2| | |`rocsparse_zbsrsm_analysis`|3.6.0| | | | |
|`cusparseZbsrsm2_bufferSize`| |12.2| | | | | | | | |
|`cusparseZbsrsm2_bufferSize`| |12.2| | |`rocsparse_zbsrsm_buffer_size`|4.5.0| | | | |
|`cusparseZbsrsm2_bufferSizeExt`| |12.2| | | | | | | | |
|`cusparseZbsrsm2_solve`| |12.2| | |`rocsparse_zbsrsm_solve`|4.5.0| | | | |
|`cusparseZcsrmm`| |10.2| |11.0| | | | | | |
Expand Down
12 changes: 8 additions & 4 deletions src/CUDA2HIP_SPARSE_API_functions.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -259,13 +259,13 @@ const std::map<llvm::StringRef, hipCounter> CUDA_SPARSE_FUNCTION_MAP {
{"cusparseCbsrmm", {"hipsparseCbsrmm", "", CONV_LIB_FUNC, API_SPARSE, 10, ROC_UNSUPPORTED}},
{"cusparseZbsrmm", {"hipsparseZbsrmm", "", CONV_LIB_FUNC, API_SPARSE, 10, ROC_UNSUPPORTED}},

{"cusparseSbsrsm2_bufferSize", {"hipsparseSbsrsm2_bufferSize", "", CONV_LIB_FUNC, API_SPARSE, 10, ROC_UNSUPPORTED | CUDA_DEPRECATED}},
{"cusparseSbsrsm2_bufferSize", {"hipsparseSbsrsm2_bufferSize", "rocsparse_sbsrsm_buffer_size", CONV_LIB_FUNC, API_SPARSE, 10, CUDA_DEPRECATED}},
{"cusparseSbsrsm2_bufferSizeExt", {"hipsparseSbsrsm2_bufferSizeExt", "", CONV_LIB_FUNC, API_SPARSE, 10, UNSUPPORTED | CUDA_DEPRECATED}},
{"cusparseDbsrsm2_bufferSize", {"hipsparseDbsrsm2_bufferSize", "", CONV_LIB_FUNC, API_SPARSE, 10, ROC_UNSUPPORTED | CUDA_DEPRECATED}},
{"cusparseDbsrsm2_bufferSize", {"hipsparseDbsrsm2_bufferSize", "rocsparse_dbsrsm_buffer_size", CONV_LIB_FUNC, API_SPARSE, 10, CUDA_DEPRECATED}},
{"cusparseDbsrsm2_bufferSizeExt", {"hipsparseDbsrsm2_bufferSizeExt", "", CONV_LIB_FUNC, API_SPARSE, 10, UNSUPPORTED | CUDA_DEPRECATED}},
{"cusparseCbsrsm2_bufferSize", {"hipsparseCbsrsm2_bufferSize", "", CONV_LIB_FUNC, API_SPARSE, 10, ROC_UNSUPPORTED | CUDA_DEPRECATED}},
{"cusparseCbsrsm2_bufferSize", {"hipsparseCbsrsm2_bufferSize", "rocsparse_cbsrsm_buffer_size", CONV_LIB_FUNC, API_SPARSE, 10, CUDA_DEPRECATED}},
{"cusparseCbsrsm2_bufferSizeExt", {"hipsparseCbsrsm2_bufferSizeExt", "", CONV_LIB_FUNC, API_SPARSE, 10, UNSUPPORTED | CUDA_DEPRECATED}},
{"cusparseZbsrsm2_bufferSize", {"hipsparseZbsrsm2_bufferSize", "", CONV_LIB_FUNC, API_SPARSE, 10, ROC_UNSUPPORTED | CUDA_DEPRECATED}},
{"cusparseZbsrsm2_bufferSize", {"hipsparseZbsrsm2_bufferSize", "rocsparse_zbsrsm_buffer_size", CONV_LIB_FUNC, API_SPARSE, 10, CUDA_DEPRECATED}},
{"cusparseZbsrsm2_bufferSizeExt", {"hipsparseZbsrsm2_bufferSizeExt", "", CONV_LIB_FUNC, API_SPARSE, 10, UNSUPPORTED | CUDA_DEPRECATED}},

{"cusparseSbsrsm2_analysis", {"hipsparseSbsrsm2_analysis", "rocsparse_sbsrsm_analysis", CONV_LIB_FUNC, API_SPARSE, 10, CUDA_DEPRECATED}},
Expand Down Expand Up @@ -2284,6 +2284,10 @@ const std::map<llvm::StringRef, hipAPIversions> HIP_SPARSE_FUNCTION_VER_MAP {
{"rocsparse_cbsrsm_analysis", {HIP_3060, HIP_0, HIP_0 }},
{"rocsparse_dbsrsm_analysis", {HIP_3060, HIP_0, HIP_0 }},
{"rocsparse_sbsrsm_analysis", {HIP_3060, HIP_0, HIP_0 }},
{"rocsparse_zbsrsm_buffer_size", {HIP_4050, HIP_0, HIP_0 }},
{"rocsparse_cbsrsm_buffer_size", {HIP_4050, HIP_0, HIP_0 }},
{"rocsparse_dbsrsm_buffer_size", {HIP_4050, HIP_0, HIP_0 }},
{"rocsparse_sbsrsm_buffer_size", {HIP_4050, HIP_0, HIP_0 }},
};

const std::map<llvm::StringRef, cudaAPIChangedVersions> CUDA_SPARSE_FUNCTION_CHANGED_VER_MAP {
Expand Down
46 changes: 45 additions & 1 deletion src/HipifyAction.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,10 @@ const std::string sCusparseZbsric02_bufferSize = "cusparseZbsric02_bufferSize";
const std::string sCusparseCbsric02_bufferSize = "cusparseCbsric02_bufferSize";
const std::string sCusparseDbsric02_bufferSize = "cusparseDbsric02_bufferSize";
const std::string sCusparseSbsric02_bufferSize = "cusparseSbsric02_bufferSize";
const std::string sCusparseZbsrsm2_bufferSize = "cusparseZbsrsm2_bufferSize";
const std::string sCusparseCbsrsm2_bufferSize = "cusparseCbsrsm2_bufferSize";
const std::string sCusparseDbsrsm2_bufferSize = "cusparseDbsrsm2_bufferSize";
const std::string sCusparseSbsrsm2_bufferSize = "cusparseSbsrsm2_bufferSize";
// CUDA_OVERLOADED
const std::string sCudaEventCreate = "cudaEventCreate";
const std::string sCudaGraphInstantiate = "cudaGraphInstantiate";
Expand Down Expand Up @@ -922,6 +926,42 @@ std::map<std::string, ArgCastStruct> FuncArgCasts {
false
}
},
{sCusparseZbsrsm2_bufferSize,
{
{
{13, {e_reinterpret_cast_size_t, cw_None}}
},
true,
false
}
},
{sCusparseCbsrsm2_bufferSize,
{
{
{13, {e_reinterpret_cast_size_t, cw_None}}
},
true,
false
}
},
{sCusparseDbsrsm2_bufferSize,
{
{
{13, {e_reinterpret_cast_size_t, cw_None}}
},
true,
false
}
},
{sCusparseSbsrsm2_bufferSize,
{
{
{13, {e_reinterpret_cast_size_t, cw_None}}
},
true,
false
}
},
};

void HipifyAction::RewriteString(StringRef s, clang::SourceLocation start) {
Expand Down Expand Up @@ -1685,7 +1725,11 @@ std::unique_ptr<clang::ASTConsumer> HipifyAction::CreateASTConsumer(clang::Compi
sCusparseZbsric02_bufferSize,
sCusparseCbsric02_bufferSize,
sCusparseDbsric02_bufferSize,
sCusparseSbsric02_bufferSize
sCusparseSbsric02_bufferSize,
sCusparseZbsrsm2_bufferSize,
sCusparseCbsrsm2_bufferSize,
sCusparseDbsrsm2_bufferSize,
sCusparseSbsrsm2_bufferSize
)
)
)
Expand Down
20 changes: 20 additions & 0 deletions tests/unit_tests/synthetic/libraries/cusparse2hipsparse.cu
Original file line number Diff line number Diff line change
Expand Up @@ -1060,6 +1060,26 @@ int main() {
// CHECK: status_t = hipsparseSbsrsm2_analysis(handle_t, direction_t, opA, opX, mb, n, nnzb, matDescr_A, &fbsrSortedVal, &bsrRowPtrA, &bsrColIndA, blockDim, bsrsm2_info, solvePolicy_t, pBuffer);
status_t = cusparseSbsrsm2_analysis(handle_t, direction_t, opA, opX, mb, n, nnzb, matDescr_A, &fbsrSortedVal, &bsrRowPtrA, &bsrColIndA, blockDim, bsrsm2_info, solvePolicy_t, pBuffer);

// CUDA: CUSPARSE_DEPRECATED cusparseStatus_t CUSPARSEAPI cusparseZbsrsm2_bufferSize(cusparseHandle_t handle, cusparseDirection_t dirA, cusparseOperation_t transA, cusparseOperation_t transXY, int mb, int n, int nnzb, const cusparseMatDescr_t descrA, cuDoubleComplex* bsrSortedVal, const int* bsrSortedRowPtr, const int* bsrSortedColInd, int blockSize, bsrsm2Info_t info, int* pBufferSizeInBytes);
// HIP: HIPSPARSE_EXPORT hipsparseStatus_t hipsparseZbsrsm2_bufferSize(hipsparseHandle_t handle, hipsparseDirection_t dirA, hipsparseOperation_t transA, hipsparseOperation_t transX, int mb, int nrhs, int nnzb, const hipsparseMatDescr_t descrA, hipDoubleComplex* bsrSortedValA, const int* bsrSortedRowPtrA, const int* bsrSortedColIndA, int blockDim, bsrsm2Info_t info, int* pBufferSizeInBytes);
// CHECK: status_t = hipsparseZbsrsm2_bufferSize(handle_t, direction_t, opA, opX, mb, n, nnzb, matDescr_A, &dComplexbsrSortedValA, &bsrRowPtrA, &bsrColIndA, blockDim, bsrsm2_info, &bufferSizeInBytes);
status_t = cusparseZbsrsm2_bufferSize(handle_t, direction_t, opA, opX, mb, n, nnzb, matDescr_A, &dComplexbsrSortedValA, &bsrRowPtrA, &bsrColIndA, blockDim, bsrsm2_info, &bufferSizeInBytes);

// CUDA: CUSPARSE_DEPRECATED cusparseStatus_t CUSPARSEAPI cusparseCbsrsm2_bufferSize(cusparseHandle_t handle, cusparseDirection_t dirA, cusparseOperation_t transA, cusparseOperation_t transXY, int mb, int n, int nnzb, const cusparseMatDescr_t descrA, cuComplex* bsrSortedVal, const int* bsrSortedRowPtr, const int* bsrSortedColInd, int blockSize, bsrsm2Info_t info, int* pBufferSizeInBytes);
// HIP: HIPSPARSE_EXPORT hipsparseStatus_t hipsparseCbsrsm2_bufferSize(hipsparseHandle_t handle, hipsparseDirection_t dirA, hipsparseOperation_t transA, hipsparseOperation_t transX, int mb, int nrhs, int nnzb, const hipsparseMatDescr_t descrA, hipComplex* bsrSortedValA, const int* bsrSortedRowPtrA, const int* bsrSortedColIndA, int blockDim, bsrsm2Info_t info, int* pBufferSizeInBytes);
// CHECK: status_t = hipsparseCbsrsm2_bufferSize(handle_t, direction_t, opA, opX, mb, n, nnzb, matDescr_A, &complexbsrValA, &bsrRowPtrA, &bsrColIndA, blockDim, bsrsm2_info, &bufferSizeInBytes);
status_t = cusparseCbsrsm2_bufferSize(handle_t, direction_t, opA, opX, mb, n, nnzb, matDescr_A, &complexbsrValA, &bsrRowPtrA, &bsrColIndA, blockDim, bsrsm2_info, &bufferSizeInBytes);

// CUDA: CUSPARSE_DEPRECATED cusparseStatus_t CUSPARSEAPI cusparseDbsrsm2_bufferSize(cusparseHandle_t handle, cusparseDirection_t dirA, cusparseOperation_t transA, cusparseOperation_t transXY, int mb, int n, int nnzb, const cusparseMatDescr_t descrA, double* bsrSortedVal, const int* bsrSortedRowPtr, const int* bsrSortedColInd, int blockSize, bsrsm2Info_t info, int* pBufferSizeInBytes);
// HIP: HIPSPARSE_EXPORT hipsparseStatus_t hipsparseDbsrsm2_bufferSize(hipsparseHandle_t handle, hipsparseDirection_t dirA, hipsparseOperation_t transA, hipsparseOperation_t transX, int mb, int nrhs, int nnzb, const hipsparseMatDescr_t descrA, double* bsrSortedValA, const int* bsrSortedRowPtrA, const int* bsrSortedColIndA, int blockDim, bsrsm2Info_t info, int* pBufferSizeInBytes);
// CHECK: status_t = hipsparseDbsrsm2_bufferSize(handle_t, direction_t, opA, opX, mb, n, nnzb, matDescr_A, &dbsrSortedValA, &bsrRowPtrA, &bsrColIndA, blockDim, bsrsm2_info, &bufferSizeInBytes);
status_t = cusparseDbsrsm2_bufferSize(handle_t, direction_t, opA, opX, mb, n, nnzb, matDescr_A, &dbsrSortedValA, &bsrRowPtrA, &bsrColIndA, blockDim, bsrsm2_info, &bufferSizeInBytes);

// CUDA: CUSPARSE_DEPRECATED cusparseStatus_t CUSPARSEAPI cusparseSbsrsm2_bufferSize(cusparseHandle_t handle, cusparseDirection_t dirA, cusparseOperation_t transA, cusparseOperation_t transXY, int mb, int n, int nnzb, const cusparseMatDescr_t descrA, float* bsrSortedVal, const int* bsrSortedRowPtr, const int* bsrSortedColInd, int blockSize, bsrsm2Info_t info, int* pBufferSizeInBytes);
// HIP: HIPSPARSE_EXPORT hipsparseStatus_t hipsparseSbsrsm2_bufferSize(hipsparseHandle_t handle, hipsparseDirection_t dirA, hipsparseOperation_t transA, hipsparseOperation_t transX, int mb, int nrhs, int nnzb, const hipsparseMatDescr_t descrA, float* bsrSortedValA, const int* bsrSortedRowPtrA, const int* bsrSortedColIndA, int blockDim, bsrsm2Info_t info, int* pBufferSizeInBytes);
// CHECK: status_t = hipsparseSbsrsm2_bufferSize(handle_t, direction_t, opA, opX, mb, n, nnzb, matDescr_A, &fbsrSortedVal, &bsrRowPtrA, &bsrColIndA, blockDim, bsrsm2_info, &bufferSizeInBytes);
status_t = cusparseSbsrsm2_bufferSize(handle_t, direction_t, opA, opX, mb, n, nnzb, matDescr_A, &fbsrSortedVal, &bsrRowPtrA, &bsrColIndA, blockDim, bsrsm2_info, &bufferSizeInBytes);

#if CUDA_VERSION >= 8000
// CHECK: hipDataType dataType_t;
// CHECK-NEXT: hipDataType dataType;
Expand Down
Loading

0 comments on commit 702ee31

Please sign in to comment.