[all-commits] [llvm/llvm-project] 229170: [mlir][Linalg] Split `populateElementwiseOpsFusion...

MaheshRavishankar via All-commits all-commits at lists.llvm.org
Mon Apr 11 16:37:39 PDT 2022

  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 2291705d2b34289a13ba7e11915fbde0a4c66418
  Author: Mahesh Ravishankar <ravishankarm at google.com>
  Date:   2022-04-11 (Mon, 11 Apr 2022)

  Changed paths:
    M mlir/include/mlir/Dialect/Linalg/Transforms/Transforms.h
    M mlir/lib/Dialect/Linalg/Transforms/CMakeLists.txt
    A mlir/lib/Dialect/Linalg/Transforms/ConstantFold.cpp
    M mlir/lib/Dialect/Linalg/Transforms/ElementwiseOpFusion.cpp
    M mlir/test/lib/Dialect/Linalg/TestLinalgElementwiseFusion.cpp

  Log Message:
  [mlir][Linalg] Split `populateElementwiseOpsFusionPatterns`.

The method to add elementwise ops fusion patterns pulls in many other
patterns by default. The patterns to pull in along with the
elementwise op fusion should be upto the caller. Split the method to
pull in just the elementwise ops fusion pattern. Other cleanup changes
- Move the pattern for constant folding of generic ops (currently only
  constant folds transpose) into a separate file, cause it is not
  related to fusion
- Drop the uber LinalgElementwiseFusionOptions. With the
  populateElementwiseOpsFusionPatterns being split, this has no
  utility now.
- Drop defaults for the control function.
- Fusion of splat constants with generic ops doesnt need a control
  function. It is always good to do.

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

More information about the All-commits mailing list