I am using cuDSS to solve a set of Ax=b equations as follows
cudssMatrixType_t mtype = CUDSS_MTYPE_SPD;
cudssMatrixViewType_t mview = CUDSS_MVIEW_UPPER;
cudssIndexBase_t base = CUDSS_BASE_ZERO;
cudssMatrixCreateCsr(&AA, nrows, ncols, nnz, d_row, NULL,
d_col, d_val, CUDA_R_32I, CUDA_R_64F, mtype, mview,
base);
cudssMatrixCreateDn(&b, ncols, nrhs, ldb, d_b, CUDA_R_64F,
CUDSS_LAYOUT_COL_MAJOR);
cudssMatrixCreateDn(&x, nrows, nrhs, ldx, d_x, CUDA_R_64F,
CUDSS_LAYOUT_COL_MAJOR);
/* Symbolic factorization */
cudssExecute(handle, CUDSS_PHASE_ANALYSIS, solverConfig, solverData,
AA, x, b);
/* Factorization */
cudssExecute(handle, CUDSS_PHASE_FACTORIZATION, solverConfig,
solverData, AA, x, b);
/* Solving */
cudssExecute(handle, CUDSS_PHASE_SOLVE, solverConfig, solverData,
AA, x, b);
However, matrix AA remains constant while rhs vector b is updated at every timestep. Is there a way to extract the factors and reuse it as part of CUDSS_PHASE_SOLVE step at subsequent timesteps? I see that CUDSS_PHASE_FACTORIZATION is more expensive than CUDSS_PHASE_SOLVE and hence I would prefer to avoid this step at every time step.
cudssExecute(), all objects passed as parameters must already be created and properly initialized." So a "dummy" might not be possible, but replacing a proper vector with another should be fine.