Open GoogleCodeExporter opened 9 years ago
Hi Carlos,
You can use array and matrix "views" [1] to avoid the copy. Just create a
plain function that accepts the device pointers and wrap them up in a
csr_matrix_view to perform the multiply. Something like
void my_multiply(int num_rows, int num_cols, int num_nonzeros,
int * row_offsets, int * column_indices, double * values,
double * x, double * y)
{
// construct csr_matrix_view and call cusp::multiply
}
BTW, we generally prefer people to ask questions on the cusp-users mailing list
[2] since more people read that than this issue tracker.
[1] http://code.google.com/p/cusp-library/source/browse/#hg%2Fexamples%2FViews
[2] http://groups.google.com/group/cusp-users
Original comment by wnbell
on 18 Feb 2012 at 6:01
Original issue reported on code.google.com by
fade...@gmail.com
on 17 Feb 2012 at 5:38