Skip to content

Commit 4d343c5

Browse files
committed
update
1 parent feb5939 commit 4d343c5

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

mlir/lib/Dialect/SCF/IR/SCF.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -681,7 +681,6 @@ void mlir::scf::promote(RewriterBase &rewriter, scf::ForallOp forallOp) {
681681
SmallVector<Value> results;
682682
results.reserve(forallOp.getResults().size());
683683
for (auto &yieldingOp : terminator.getYieldingOps()) {
684-
// Skip non-ParallelInsertSliceOp operations
685684
auto parallelInsertSliceOp =
686685
dyn_cast<tensor::ParallelInsertSliceOp>(yieldingOp);
687686
if (!parallelInsertSliceOp)
@@ -1912,9 +1911,10 @@ struct FoldTensorCastOfOutputIntoForallOp
19121911
auto terminator = newForallOp.getTerminator();
19131912
for (auto [yieldingOp, outputBlockArg] : llvm::zip(
19141913
terminator.getYieldingOps(), newForallOp.getRegionIterArgs())) {
1915-
auto inParallelOp = dyn_cast<ParallelCombiningOpInterface>(yieldingOp);
1916-
if (inParallelOp)
1914+
if (auto inParallelOp =
1915+
dyn_cast<ParallelCombiningOpInterface>(yieldingOp)) {
19171916
inParallelOp.getUpdatedDestinations().assign(outputBlockArg);
1917+
}
19181918
}
19191919

19201920
// Cast results back to the original types.

0 commit comments

Comments
 (0)