Anthon Porath Gretter - 259030
Before building, make sure you have CUDA/11.8.0 installed and loaded. To build the desired implementation you can simply type
make spmv_<implementation name>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:
make cpu
make gpuYou can always add additional jobs to make, like -j8, to enhance compilation time.
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:
./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/