Reputation: 372
I know dgemv
is for matrix-vector, but which is more efficient? Using dgemm
directly for matrix multiplication or using dgemv
to do the matrix multiplication by multiplying the Matrix A with each individual column of matrix B using dgemv
?
Upvotes: 2
Views: 1216
Reputation: 106267
If you make repeated calls to DGEMV, you will not benefit from cache tiling and re-use, which are the biggest advantages good DGEMM implementations have. DGEMM is vastly more efficient than multiple calls to DGEMV.
Upvotes: 7