[Mlir-commits] [mlir] [mlir][SCF] `scf.parallel`: Make reductions part of the terminator (PR #75314)

Jakub Kuderski llvmlistbot at llvm.org
Sat Dec 16 16:21:18 PST 2023


================
@@ -382,14 +398,13 @@ struct ParallelOpLowering : public OpRewritePattern<scf::ParallelOp> {
     // Replace the reduction operations contained in this loop. Must be done
     // here rather than in a separate pattern to have access to the list of
     // reduction variables.
-    for (auto pair :
-         llvm::zip(parallelOp.getOps<scf::ReduceOp>(), reductionVariables)) {
+    for (auto pair : llvm::zip(reductionVariables, reduce.getOperands())) {
----------------
kuhar wrote:

You don't need the `&&`, just `auto [x, y] : llvm::zip`

https://github.com/llvm/llvm-project/pull/75314


More information about the Mlir-commits mailing list