[PATCH] D79497: [mlir] OperationFolder: fix crash in creation of single-result-ops with in-place folds
Uday Bondhugula via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed May 6 11:52:48 PDT 2020
bondhugula accepted this revision.
bondhugula added a comment.
Great catch and fix! Appreciate the thorough test case.
================
Comment at: mlir/test/lib/Dialect/Test/TestDialect.cpp:327
+OpFoldResult TestOpInPlaceFold::fold(ArrayRef<Attribute> operands) {
+ assert(operands.size() == 1);
+ if (operands.front()) {
----------------
Nit: && "single operand op").
================
Comment at: mlir/test/lib/Dialect/Test/TestPatterns.cpp:52
+ PatternRewriter &rewriter) const override {
+ // Exercice OperationFolder API for a single-result operation that is folded
+ // upon construction. The operation being created through the folder has an
----------------
Nit: Exercise, pas exercice comme on dirait en francais ;-)
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D79497/new/
https://reviews.llvm.org/D79497
More information about the llvm-commits
mailing list