[PATCH] D77483: [MLIR] fix greedy pattern rewrite driver iteration on change

Uday Bondhugula via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sun Apr 5 06:56:05 PDT 2020


This revision was automatically updated to reflect the committed changes.
Closed by commit rGf875e55ba927: [MLIR] fix greedy pattern rewrite driver iteration on change (authored by bondhugula).

Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D77483/new/

https://reviews.llvm.org/D77483

Files:
  mlir/lib/Transforms/Utils/GreedyPatternRewriteDriver.cpp


Index: mlir/lib/Transforms/Utils/GreedyPatternRewriteDriver.cpp
===================================================================
--- mlir/lib/Transforms/Utils/GreedyPatternRewriteDriver.cpp
+++ mlir/lib/Transforms/Utils/GreedyPatternRewriteDriver.cpp
@@ -165,6 +165,7 @@
       if (isOpTriviallyDead(op)) {
         notifyOperationRemoved(op);
         op->erase();
+        changed = true;
         continue;
       }
 
@@ -186,7 +187,7 @@
 
       // Try to fold this op.
       if (succeeded(folder.tryToFold(op, collectOps, preReplaceAction))) {
-        changed |= true;
+        changed = true;
         continue;
       }
 


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D77483.255156.patch
Type: text/x-patch
Size: 634 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200405/fbefc628/attachment.bin>


More information about the llvm-commits mailing list