[all-commits] [llvm/llvm-project] c2be2c: [mlir][Python][Linalg] Adding const, capture, and ...

Tobias Gysi via All-commits all-commits at lists.llvm.org
Thu Apr 29 00:26:14 PDT 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: c2be2cda8d268d4a0adbede149a20e3fd284f1d7
      https://github.com/llvm/llvm-project/commit/c2be2cda8d268d4a0adbede149a20e3fd284f1d7
  Author: Tobias Gysi <gysit at google.com>
  Date:   2021-04-29 (Thu, 29 Apr 2021)

  Changed paths:
    M mlir/docs/Tools/LinalgOpDsl.md
    M mlir/lib/Bindings/Python/mlir/dialects/linalg/opdsl/lang/affine.py
    M mlir/lib/Bindings/Python/mlir/dialects/linalg/opdsl/lang/comprehension.py
    M mlir/lib/Bindings/Python/mlir/dialects/linalg/opdsl/lang/config.py
    M mlir/lib/Bindings/Python/mlir/dialects/linalg/opdsl/lang/dsl.py
    M mlir/lib/Bindings/Python/mlir/dialects/linalg/opdsl/lang/emitter.py
    M mlir/lib/Bindings/Python/mlir/dialects/linalg/opdsl/lang/scalar_expr.py
    M mlir/lib/Bindings/Python/mlir/dialects/linalg/opdsl/lang/types.py
    M mlir/test/Bindings/Python/dialects/linalg/opdsl/emit_structured_generic.py

  Log Message:
  -----------
  [mlir][Python][Linalg] Adding const, capture, and index support to the OpDSL.

The patch extends the OpDSL with support for:
- Constant values
- Capture scalar parameters
- Access the iteration indices using the index operation
- Provide predefined floating point and integer types.

Up to now the patch only supports emitting the new nodes. The C++/yaml path is not fully implemented. The fill_rng_2d operation defined in emit_structured_generic.py makes use of the new DSL constructs.

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




More information about the All-commits mailing list