[all-commits] [llvm/llvm-project] 411093: [mlir] add readonly/consume annotations to transfo...

ftynse via All-commits all-commits at lists.llvm.org
Tue Apr 4 02:38:16 PDT 2023


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 4110934120ed4e4309099be3389faef128f72c03
      https://github.com/llvm/llvm-project/commit/4110934120ed4e4309099be3389faef128f72c03
  Author: Alex Zinenko <zinenko at google.com>
  Date:   2023-04-04 (Tue, 04 Apr 2023)

  Changed paths:
    M mlir/include/mlir/Dialect/Transform/IR/TransformDialect.td
    M mlir/include/mlir/Dialect/Transform/IR/TransformInterfaces.h
    M mlir/include/mlir/Dialect/Transform/Transforms/Passes.h
    M mlir/include/mlir/Dialect/Transform/Transforms/Passes.td
    M mlir/lib/Dialect/Transform/IR/TransformDialect.cpp
    M mlir/lib/Dialect/Transform/IR/TransformInterfaces.cpp
    M mlir/lib/Dialect/Transform/IR/TransformOps.cpp
    M mlir/lib/Dialect/Transform/Transforms/CMakeLists.txt
    A mlir/lib/Dialect/Transform/Transforms/InferEffects.cpp
    M mlir/lib/Dialect/Transform/Transforms/TransformInterpreterPassBase.cpp
    A mlir/test/Dialect/Transform/infer-effects.mlir
    M mlir/test/Dialect/Transform/ops-invalid.mlir
    M mlir/test/Dialect/Transform/test-interpreter-external-symbol-decl-and-schedule.mlir
    M mlir/test/Dialect/Transform/test-interpreter-external-symbol-decl-invalid.mlir
    M mlir/test/Dialect/Transform/test-interpreter-external-symbol-decl.mlir
    M mlir/test/Dialect/Transform/test-interpreter-external-symbol-def.mlir
    M mlir/test/Dialect/Transform/test-interpreter.mlir

  Log Message:
  -----------
  [mlir] add readonly/consume annotations to transform named sequences

Use the argument attribute mechanism for function-like operations to
annotate the arguments of named transform sequences as consuming or only
reading the handles passed as arguments. This makes it possible to
correctly specify handle invalidation for external named sequences by
requiring their declarations to always provide such annotations.
Additionally, these annotations remove the need to analyze the body of
a named sequence to understand its effects on the arguments. Make them
required for named sequences that are called from the same file, in
addition to external sequences.

Provide a convenience pass that infers annotations by analyzing bodies
of named sequences provided they are not called from the same file.

Reviewed By: springerm

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




More information about the All-commits mailing list