[Mlir-commits] [mlir] [mlir] Translating task_reduction clause for pass-by-value vars to LLVMIR (PR #125218)
llvmlistbot at llvm.org
llvmlistbot at llvm.org
Fri Jan 9 06:51:13 PST 2026
================
@@ -1388,6 +1388,14 @@ class OpenMP_TaskReductionClauseSkip<
OptionalAttr<SymbolRefArrayAttr>:$task_reduction_syms
);
+ let extraClassDeclaration = [{
+ /// Returns the number of reduction variables.
+ unsigned getNumReductionVars() { return getTaskReductionVars().size(); }
+
+ /// Returns the reduction symbols
+ auto getReductionSyms() { return getTaskReductionSyms(); }
----------------
NimishMishra wrote:
I mainly did this to share code between reductions and task reductions. But I totally understand your concern.
I will modify these. Thanks!
https://github.com/llvm/llvm-project/pull/125218
More information about the Mlir-commits
mailing list