I’m using the cusparseSpSM_solve function to solve a problem in the form of the system A * b = c for some given triangular Matrix A and right-hand side c. I’ve uploaded an image of the very beginning on my matrix and vectors that I am using for testing.
Unfortunately, while this should be very simple, this returns a value of INF for the very first value in vector b. The cusparseSpSM_solve function is opaque, and I can’t diagnose the problem. I don’t have this problem with smaller datasets, only large ones. And the issue is only with the very first value in the solution vector, every other value is properly calculated. Given the simple nature of the triangular matrix problem, b[0] = c[0] / A[0][0] = 1 / 0.000338 = 2958.579882 should be the solution.
Does anyone know why the cusparseSpSM_solve is having issues with the very first value, and only with large datasets? I have confirmed that all vectors and matrices store their values correctly and are properly initialized before the function call.
Edit: After creating code to test matrix sizes, I have determined that this is only a problem for matrices of 641x641 or larger. Anything of 640x640 or smaller is not a problem. I have absolutely no clue what could be happening. Can someone please explain this behaviour to me? I know it is not a number I have defined somewhere in my code.