[Parallel Computing] SpMV

Intro

  • Sparse matrix vector multiplication.
  • Many scientific algorithms require multiplying a matrix by a vector.
    • Optimization (e.g. conjugate gradient low degree mesh.), iterative methods (solving linear systems), eigenvalue methods (e.g. graph partitioning vx), simulations (e.g. finite elements), data analysis (e.g. Pagerank the web connectivity matrix).
  • The matrices are often sparse.
    • In an nxn matrix, there are \(O(n^2)\) nonzero elements.

image-20200420095011605

image-20200420095335093

image-20200420095418927

DIA Format

image-20200420095439285

ELL format

image-20200420095732832

COO format

image-20200420095827947

CSR format

image-20200420095843518

image-20200420095942099

Hybird format

image-20200420100525622

what to use

image-20200420100455097

ELL kernel

image-20200420104856356

CSR scalar vector kernel

image-20200420104830242

CSR vector kernel

image-20200420104812194

COO vector kernel

image-20200420105358361

image-20200420104747538