[all-commits] [llvm/llvm-project] 8c8856: [mlir][Interfaces] Add ValueBoundsOpInterface

Matthias Springer via All-commits all-commits at lists.llvm.org
Wed Apr 5 17:57:38 PDT 2023


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 8c885658edf599da277d6d8f2f66bf4cf6f2b934
      https://github.com/llvm/llvm-project/commit/8c885658edf599da277d6d8f2f66bf4cf6f2b934
  Author: Matthias Springer <me at m-sp.org>
  Date:   2023-04-06 (Thu, 06 Apr 2023)

  Changed paths:
    M mlir/include/mlir/Dialect/Affine/Transforms/Transforms.h
    A mlir/include/mlir/Dialect/Tensor/IR/ValueBoundsOpInterfaceImpl.h
    M mlir/include/mlir/InitAllDialects.h
    M mlir/include/mlir/Interfaces/CMakeLists.txt
    A mlir/include/mlir/Interfaces/ValueBoundsOpInterface.h
    A mlir/include/mlir/Interfaces/ValueBoundsOpInterface.td
    M mlir/lib/Dialect/Affine/Transforms/CMakeLists.txt
    A mlir/lib/Dialect/Affine/Transforms/ReifyValueBounds.cpp
    M mlir/lib/Dialect/Tensor/IR/CMakeLists.txt
    A mlir/lib/Dialect/Tensor/IR/ValueBoundsOpInterfaceImpl.cpp
    M mlir/lib/Interfaces/CMakeLists.txt
    A mlir/lib/Interfaces/ValueBoundsOpInterface.cpp
    A mlir/test/Dialect/Affine/value-bounds-reification.mlir
    A mlir/test/Dialect/Tensor/value-bounds-op-interface-impl.mlir
    M mlir/test/lib/Dialect/Affine/CMakeLists.txt
    A mlir/test/lib/Dialect/Affine/TestReifyValueBounds.cpp
    M mlir/tools/mlir-opt/mlir-opt.cpp
    M utils/bazel/llvm-project-overlay/mlir/BUILD.bazel
    M utils/bazel/llvm-project-overlay/mlir/test/BUILD.bazel

  Log Message:
  -----------
  [mlir][Interfaces] Add ValueBoundsOpInterface

Ops can implement this interface to specify lower/upper bounds for their result values and block arguments. Bounds can be specified for:
* Index-type values
* Dimension sizes of shapes values

The bounds are added to a constraint set. Users can query this constraint set to compute bounds wrt. to a user-specified set of values. Only EQ bounds are supported at the moment.

This revision also contains interface implementations for various tensor dialect ops, which illustrates how to implement this interface.

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




More information about the All-commits mailing list