[all-commits] [llvm/llvm-project] 93cb71: [mlir-docs] Add a blurb on recursion during patter...
River Riddle via All-commits
all-commits at lists.llvm.org
Tue May 18 14:41:08 PDT 2021
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 93cb71a4649ac71b9aca48ba5496f11ffbc4b26d
https://github.com/llvm/llvm-project/commit/93cb71a4649ac71b9aca48ba5496f11ffbc4b26d
Author: River Riddle <riddleriver at gmail.com>
Date: 2021-05-18 (Tue, 18 May 2021)
Changed paths:
M mlir/docs/PatternRewriter.md
Log Message:
-----------
[mlir-docs] Add a blurb on recursion during pattern application
We currently do not document how the pattern rewriter infra treats recursion when it gets detected. This revision adds a blurb on recursion in patterns, and how patterns can signal that they are equipped to handle it.
Differential Revision: https://reviews.llvm.org/D102439
Commit: 2257e4a70e4aabe7255161f3a54922d7dcf1c059
https://github.com/llvm/llvm-project/commit/2257e4a70e4aabe7255161f3a54922d7dcf1c059
Author: River Riddle <riddleriver at gmail.com>
Date: 2021-05-18 (Tue, 18 May 2021)
Changed paths:
M mlir/docs/PatternRewriter.md
M mlir/include/mlir/IR/PatternMatch.h
M mlir/lib/Conversion/VectorToLLVM/ConvertVectorToLLVM.cpp
M mlir/test/lib/Dialect/Test/TestPatterns.cpp
Log Message:
-----------
[mlir] Allow derived rewrite patterns to define a non-virtual `initialize` hook
This is a hook that allows for providing custom initialization of the pattern, e.g. if it has bounded recursion, setting the debug name, etc., without needing to define a custom constructor. A non-virtual hook was chosen to avoid polluting the vtable with code that we really just want to be inlined when constructing the pattern. The alternative to this would be to just define a constructor for each pattern, this unfortunately creates a lot of otherwise unnecessary boiler plate for a lot of patterns and a hook provides a much simpler/cleaner interface for the very common case.
Differential Revision: https://reviews.llvm.org/D102440
Compare: https://github.com/llvm/llvm-project/compare/b9d25cc92138...2257e4a70e4a
More information about the All-commits
mailing list