Skip to content

Commit

Permalink
Add comment for gemv stride adjustment
Browse files Browse the repository at this point in the history
Written by jturner314 on the PR.
  • Loading branch information
bluss committed Sep 3, 2019
1 parent b101a27 commit b5cad2f
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/linalg/impl_linalg.rs
Original file line number Diff line number Diff line change
Expand Up @@ -586,6 +586,10 @@ pub fn general_mat_vec_mul<A, S1, S2, S3>(alpha: A,
if blas_compat_1d::<$ty, _>(&x)
&& blas_compat_1d::<$ty, _>(&y)
{
// Determine stride between rows or columns. Note that the stride is
// adjusted to at most `k` or `m` to handle the case of a matrix with a
// trivial (length 1) dimension, since the stride for the trivial dimension
// may be arbitrary.
let a_trans = CblasNoTrans;
let a_stride = match layout {
CBLAS_LAYOUT::CblasRowMajor => a.strides()[0].max(k as isize) as blas_index,
Expand Down

0 comments on commit b5cad2f

Please sign in to comment.