[all-commits] [llvm/llvm-project] 6e44f1: [mlir] provide a base class for transform interpre...

ftynse via All-commits all-commits at lists.llvm.org
Fri Feb 3 06:12:49 PST 2023


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 6e44f11ed30cc2e9d5453f162403c7e58ee6e5e1
      https://github.com/llvm/llvm-project/commit/6e44f11ed30cc2e9d5453f162403c7e58ee6e5e1
  Author: Alex Zinenko <zinenko at google.com>
  Date:   2023-02-03 (Fri, 03 Feb 2023)

  Changed paths:
    M mlir/include/mlir/Dialect/Transform/IR/TransformInterfaces.h
    A mlir/include/mlir/Dialect/Transform/Transforms/TransformInterpreterPassBase.h
    M mlir/lib/Dialect/Transform/IR/TransformInterfaces.cpp
    M mlir/lib/Dialect/Transform/Transforms/CMakeLists.txt
    A mlir/lib/Dialect/Transform/Transforms/TransformInterpreterPassBase.cpp
    A mlir/test/Dialect/Linalg/generalize-tensor-unpack-tile.mlir
    M mlir/test/Dialect/Linalg/generalize-tensor-unpack.mlir
    A mlir/test/Dialect/Linalg/generalize-tesnor-pack-tile.mlir
    M mlir/test/Dialect/Linalg/transform-patterns.mlir
    A mlir/test/Dialect/Transform/test-interpreter-debug.mlir
    A mlir/test/Dialect/Transform/test-interpreter-external-source.mlir
    A mlir/test/Dialect/Transform/test-interpreter-external.mlir
    M mlir/test/Dialect/Transform/test-interpreter.mlir
    M mlir/test/lib/Dialect/Transform/CMakeLists.txt
    M mlir/test/lib/Dialect/Transform/TestTransformDialectInterpreter.cpp
    M utils/bazel/llvm-project-overlay/mlir/BUILD.bazel
    M utils/bazel/llvm-project-overlay/mlir/test/BUILD.bazel
    M utils/bazel/llvm-project-overlay/mlir/test/Dialect/BUILD.bazel

  Log Message:
  -----------
  [mlir] provide a base class for transform interpreter passes

The transform dialect infrastructure does not provide a default
interpreter pass and instead expects users to create their own to ensure
all relevant extensions and dependent dialects are loaded. Provide a
base class for implementing such passes that includes the additional
facilities for debugging and is aware of the multithreaded nature of
pass execution.

Reviewed By: pifon2a, nicolasvasilache

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


  Commit: b7895f9ded5d4d328525b13386c124b16f6a93c5
      https://github.com/llvm/llvm-project/commit/b7895f9ded5d4d328525b13386c124b16f6a93c5
  Author: Alex Zinenko <zinenko at google.com>
  Date:   2023-02-03 (Fri, 03 Feb 2023)

  Changed paths:
    M mlir/lib/Dialect/Transform/IR/TransformInterfaces.cpp
    M mlir/lib/Dialect/Transform/IR/TransformOps.cpp
    A mlir/test/Dialect/Transform/test-interpreter-external-concurrent-source.mlir
    A mlir/test/Dialect/Transform/test-interpreter-external-concurrent.mlir
    M mlir/test/lib/Dialect/Transform/TestTransformDialectInterpreter.cpp

  Log Message:
  -----------
  [mlir] properly fix concurrent transform interpreter pass base

The original implementation of the transform interpreter pass base was
cloning the entire transform IR in presence of PDL-related operations to
avoid concurrency issues when running the pass with the same transform
IR on multiple operations of the payload IR. The root cause of those
issues is the `transform.pdl_match` operation that was moving the PDL
pattern definition operation into a new module, consumed by the PDL
interpreter and leading to a race. Clone the pattern operation instead.
This avoids the race as well as the cost for transform IR that doesn't
use PDL.

Depends on D142729.

Reviewed By: nicolasvasilache

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


Compare: https://github.com/llvm/llvm-project/compare/7bb615ea0ec0...b7895f9ded5d


More information about the All-commits mailing list