[all-commits] [llvm/llvm-project] 21bb63: [MLIR][linalg] Make integer matmul ops cast before...

Geoffrey Martin-Noble via All-commits all-commits at lists.llvm.org
Fri Feb 26 08:36:53 PST 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 21bb63893e8557df7a7ab690ad98cb5979099186
      https://github.com/llvm/llvm-project/commit/21bb63893e8557df7a7ab690ad98cb5979099186
  Author: Geoffrey Martin-Noble <gcmn at google.com>
  Date:   2021-02-26 (Fri, 26 Feb 2021)

  Changed paths:
    M mlir/include/mlir/Dialect/Linalg/IR/LinalgNamedStructuredOpsSpec.tc
    M mlir/test/Dialect/Linalg/vectorization.mlir

  Log Message:
  -----------
  [MLIR][linalg] Make integer matmul ops cast before multiplying

Right now they multiply before casting which means they would frequently
overflow. There are various reasonable ways to do this, but until we
have robust op description infra, this is a simple and safe default. More
careful treatments are likely to be hardware specific, as well (e.g.
using an i8*i8->i16 mul instruction).

Reviewed By: nicolasvasilache, mravishankar

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




More information about the All-commits mailing list