[all-commits] [llvm/llvm-project] e91a5c: [mlir][vector] Add a custom builder for LowerVecto...

qcolombet via All-commits all-commits at lists.llvm.org
Thu Jan 19 03:15:50 PST 2023


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: e91a5ce278381771ea6d4e6d602e1e486de655f9
      https://github.com/llvm/llvm-project/commit/e91a5ce278381771ea6d4e6d602e1e486de655f9
  Author: Quentin Colombet <quentin.colombet at gmail.com>
  Date:   2023-01-19 (Thu, 19 Jan 2023)

  Changed paths:
    M mlir/include/mlir/Dialect/Vector/TransformOps/VectorTransformOps.h
    M mlir/include/mlir/Dialect/Vector/TransformOps/VectorTransformOps.td

  Log Message:
  -----------
  [mlir][vector] Add a custom builder for LowerVectorsOp

The `lower_vectors` operation of the transform dialect takes a lot of
arguments to build.
In order to make C++ code easier to work with when using this
instruction, introduce a new structure, named `LowerVectorsOptions`, that
aggregates all the options that are used to build this instruction.

This allows to use patterns like:
```
LowerVectorsOptions opts;
opts.setOptZ(...)
  .setOptY(...)...;
builder.create<LowerVectorsOp>(target, opts);
```

Instead of having to pass all N options directly to the builder and set
them in the right order.

NFC

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




More information about the All-commits mailing list