[all-commits] [llvm/llvm-project] 90e291: [LangRef] Fix description of shape args for matrix...

Braedy via All-commits all-commits at lists.llvm.org
Wed Jun 3 03:26:25 PDT 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: 90e291912ac7e3caf9251969a5c47310c6aa01ff
      https://github.com/llvm/llvm-project/commit/90e291912ac7e3caf9251969a5c47310c6aa01ff
  Author: Braedy Kuzma <braedy at ualberta.ca>
  Date:   2020-06-03 (Wed, 03 Jun 2020)

  Changed paths:
    M llvm/docs/LangRef.rst

  Log Message:
  -----------
  [LangRef] Fix description of shape args for matrix.multiply.

Currently all code instances within the matrix lowering pass consider
matrix A to be MxN and B to be NxK, producing C which is MxK. Anyone
interacting with this API after reading the docs but without reading the pass
would expect A: MxK, B: KxN, and C: MxN. These changes bring the documentation
in line with the implementation.

One point of concern with this, the original signature as described in the docs
may be better or at least more expected. The interface as it was written
reflected other common matrix multiplication interfaces such as BLAS'[1], where
the matrices are MxK, KxN, MxN respectively. Choosing to honor this requires
changing code and tests instead, but should be mostly just renaming of variables.

Patch by Braedy Kuzma <braedy at ualberta.ca>

[1] http://www.netlib.org/lapack/explore-html/db/dc9/group__single__blas__level3_gafe51bacb54592ff5de056acabd83c260.html#gafe51bacb54592ff5de056acabd83c260

Reviewers: anemet, LuoYuanke, nicolasvasilache, fhahn

Reviewed By: fhahn

Differential Revision: https://reviews.llvm.org/D80663




More information about the All-commits mailing list