Font Size: a A A

Sparse Matrix Vector Multiplication Based On CPU And GPU

Posted on:2022-01-23Degree:MasterType:Thesis
Country:ChinaCandidate:G Y YuFull Text:PDF
GTID:2518306575962249Subject:Computer system architecture
Abstract/Summary:PDF Full Text Request
Sparse matrix vector multiplication(SPMV)is of great significance for computation in many science and engineering disciplines.However,due to arbitrary sparse mode and the size of a sparse matrix,the parallelization of SPMV is still plagued by many operational problems,including bad memory merging,thread divergence and load unbalance.For my project,I implemented five different GPUbased algorithms and analyzed their performance on different types and sizes of data.I try to draw insights into the strengths and weaknesses of these algorithms and their best use.I measure performance by calculating throughput,memory bandwidth utilization,and other system-generated metrics.However,in terms of CPU,the number of cores in multi-core processor chips shows a trend of continuous increase,so it is very important to run and parallelize SPMV in multi-core processors.In this paper,two storage formats applied to sparse matrix are introduced,namely CSR format and BCSR format.Meanwhile,the multicore parallelization of SPMV is accomplished through OpenMP.In addition,this paper also studies and analyzes a variety of optimization techniques represented by the register block algorithm,and makes clear the SPMV situation when various scheduling strategies and SIMD instruction sets affect multithreaded parallelism.From the test results on the server side,it can be seen that most of the matrices are extensible and even able to achieve super linear acceleration ratio.Compared with the MULTIthreaded SPMV designed on the basis of CSR,after the register block algorithm is optimized,the speed of SPMV operation can be improved by 28.%.In this paper,it is tested and studied with the three scheduling policies supported by OpenMP standard.The results show that SIMD instruction set can perform better load balancing compared with the scheduling policies supported by OpenMP standard.Both Dynamic scheduling and Guide scheduling show better performance in multithreaded SPMV than Static scheduling policy.
Keywords/Search Tags:GPU, CPU, parallel computing, sparse matrix, SPMV
PDF Full Text Request
Related items