A very specific topic!
[ A x = b ]
// RCI loop while (rci_request != 0) if (rci_request == 1) // Compute A * x -> tmp (provided by solver) mkl_dcsrgemv("N", &n, A_val, A_row, A_col, tmp, tmp+n); else if (rci_request == 2) // Apply preconditioner: here Jacobi diagonal for (int i = 0; i < n; i++) tmp[n+i] = tmp[n+i] / diag[i];
Here are some best practices for working with libmklccgdll:
Intel Math Kernel Library (MKL) is a highly optimized library of mathematical functions—linear algebra (BLAS, LAPACK), fast Fourier transforms (FFTs), vector math, random number generation, and statistics. For cluster-scale computing, MKL provides a specific that interfaces with Message Passing Interface (MPI) to perform distributed dense linear algebra operations (e.g., ScaLAPACK, PBLAS, BLACS).