[all-commits] [llvm/llvm-project] 6b65d7: [mlir][linalg] Fix for invalid IR in eliminate_emp...

Spenser Bauman via All-commits all-commits at lists.llvm.org
Mon Jan 1 09:12:54 PST 2024


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 6b65d79fbb4682468333cea42b62f15c2dffd8f3
      https://github.com/llvm/llvm-project/commit/6b65d79fbb4682468333cea42b62f15c2dffd8f3
  Author: Spenser Bauman <sbauman at mathworks.com>
  Date:   2024-01-01 (Mon, 01 Jan 2024)

  Changed paths:
    M mlir/lib/Dialect/Linalg/Transforms/EliminateEmptyTensors.cpp
    M mlir/test/Dialect/Linalg/one-shot-bufferize-empty-tensor-elimination.mlir

  Log Message:
  -----------
  [mlir][linalg] Fix for invalid IR in eliminate_empty_tensors (#73513)

The transform.structured.eliminate_empty_tensors can produce mis-typed
IR when traversing use-def chains past tensor reshaping operations for
sharing candidates. This results in Linalg operations whose output types
do not match their 'outs' arguments.

This patch filters out candidate tensor.empty operations when their
types do not match the candidate input operand.




More information about the All-commits mailing list