[all-commits] [llvm/llvm-project] daabcf: [MLIR] Provide a way to print ops in custom form o...

Uday Bondhugula via All-commits all-commits at lists.llvm.org
Sun Apr 17 07:44:20 PDT 2022


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: daabcf5f04bbd13ac53f76ca3cc43b0d1ef64f5a
      https://github.com/llvm/llvm-project/commit/daabcf5f04bbd13ac53f76ca3cc43b0d1ef64f5a
  Author: Uday Bondhugula <uday at polymagelabs.com>
  Date:   2022-04-17 (Sun, 17 Apr 2022)

  Changed paths:
    M mlir/include/mlir/Pass/PassManager.h
    M mlir/lib/Pass/IRPrinting.cpp
    M mlir/lib/Pass/PassManagerOptions.cpp
    M mlir/test/Pass/ir-printing.mlir

  Log Message:
  -----------
  [MLIR] Provide a way to print ops in custom form on pass failure

The generic form of the op is too verbose and in some cases not
readable. On pass failure, ops have been so far printed in generic form
to provide a (stronger) guarantee that the IR print succeeds. However,
in a large number of pass failure cases, the IR is still valid and
the custom printers for the ops will succeed. In fact, readability is
highly desirable post pass failure. This revision provides an option to
print ops in their custom/pretty-printed form on IR failure -- this
option is unsafe and there is no guarantee it will succeed. It's
disabled by default and can be turned on only if needed.

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




More information about the All-commits mailing list