Skip to main content

Module cusolver

Module cusolver 

Source
Expand description

cuSOLVER-backed GPU linear algebra: SVD, Cholesky, QR, Solve.

Each operation follows the cuSOLVER pattern:

  1. Query workspace size via *_bufferSize.
  2. Allocate workspace + output buffers on the device.
  3. Call the cuSOLVER routine.
  4. Check devInfo — non-zero means the operation failed (singular matrix, etc.).

All functions operate on column-major data because cuSOLVER (LAPACK-style) uses column-major layout. The caller is responsible for transposing row-major tensors before calling and transposing outputs back.

Functions§

gpu_cholesky_f32
Compute the Cholesky decomposition of an n-by-n SPD matrix (row-major f32).
gpu_cholesky_f64
Compute the Cholesky decomposition of an n-by-n SPD matrix (row-major f64).
gpu_qr_f32
Compute the reduced QR decomposition of an m-by-n matrix (row-major f32).
gpu_qr_f64
Compute the reduced QR decomposition of an m-by-n matrix (row-major f64).
gpu_solve_f32
Solve A * X = B for X where A is n-by-n and B is n-by-nrhs (row-major f32).
gpu_solve_f64
Solve A * X = B for X where A is n-by-n and B is n-by-nrhs (row-major f64).
gpu_svd_f32
Compute the thin SVD of an m-by-n matrix (row-major f32).
gpu_svd_f64
Compute the thin SVD of an m-by-n matrix (row-major f64).