-
Notifications
You must be signed in to change notification settings - Fork 220
Open
Description
There is a note in the code that says const needed to be dropped when working with cusparseSpMV in CUDA 11
raft/cpp/include/raft/spectral/detail/matrix_wrappers.hpp
Lines 203 to 214 in 7f57ac6
| // y = alpha*A*x + beta*y | |
| //(Note: removed const-ness of x, because CUDA 11 SpMV | |
| // descriptor creation works with non-const, and const-casting | |
| // down is dangerous) | |
| // | |
| virtual void mv(value_type alpha, | |
| value_type* __restrict__ x, | |
| value_type beta, | |
| value_type* __restrict__ y, | |
| sparse_mv_alg_t alg = sparse_mv_alg_t::SPARSE_MV_ALG1, | |
| bool transpose = false, | |
| bool symmetric = false) const |
Looking at the CUDA 12 docs for cusparseSpMV, it appears everything is marked const
Given this could we now use const here and anywhere else using cusparseSpMV?
Note: This originally came up in issue ( #2741 ). However it is a bit more nuanced than the other cleanup items in that issue. So have broken it out
Metadata
Metadata
Assignees
Labels
No labels
Type
Projects
Status
Todo