================
@@ -4161,6 +4247,37 @@ convertOmpDistribute(Operation &opInst,
llvm::IRBuilderBase &builder,
if (failed(checkImplementationStatus(opInst)))
return failure();
+ /// Process teams op reduction in distribute if the reduction is contained in
+ /// the distribute op.
+ omp::TeamsOp teamsOp = opInst.getParentOfType<omp::TeamsOp>();
+ bool doDistributeReduction =
+ teamsOp ? teamsReductionContainedInDistribute(teamsOp) : false;
+
+ DenseMap<Value, llvm::Value *> reductionVariableMap;
----------------
skatrak wrote:
Nit: This looks like it could be moved into the `if`.
It actually looks like it would make sense to make it local to
`allocAndInitializeReductionVars`, since I can't see anywhere it being used
outside of it, but that can be looked into later on.
https://github.com/llvm/llvm-project/pull/133310
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits