An open API service indexing awesome lists of open source software.

https://github.com/anthongretter/spmv-cuda-analysis

A analysis on different approaches on Sparse Matrix-Vector Multiplication (SpMV) on GPU using CUDA
https://github.com/anthongretter/spmv-cuda-analysis

cuda gpu matrix-computations spmv unitn

Last synced: 8 months ago
JSON representation

A analysis on different approaches on Sparse Matrix-Vector Multiplication (SpMV) on GPU using CUDA

Awesome Lists containing this project

README

          

# SpMV evaluation
Anthon Porath Gretter - 259030

## Building
Before building, make sure you have **CUDA/11.8.0** installed and loaded.
To build the desired implementation you can simply type
```shell
make spmv_
```
Where <_implementation name_> can be `cpu_csr`, `gpu_mem`, `gpu_unrl` or `gpu_dyn`.
Or even, to build all CPU or/and all GPU implementations¹ just run:
```shell
make cpu
make gpu
```
You can always add additional jobs to make, like `-j8`, to enhance compilation time.

## Usage
To run, provide a valid `.mtx` file alongside the desired implementation call.
There are some `.mtx` included in the **resources** directory². Below sits an example:
```shell
./spmv_gpu_mem ./resources/rim.mtx
```

> [1] _the implementations are compiled separately
> due to the usage of Compile-time Conditional Inclusion.
> So if make does not do that automatically,
> please make sure there are no object files from previous compilations._\
> [2] _All available matrix market files were gathered from https://sparse.tamu.edu/_