[llvm-branch-commits] [flang] [mlir] [mlir][OpenMP] Pack task private variables into a heap-allocated context struct (PR #125307)
Sergio Afonso via llvm-branch-commits
llvm-branch-commits at lists.llvm.org
Thu Feb 6 03:37:59 PST 2025
================
@@ -146,13 +146,24 @@ def PrivateClauseOp : OpenMP_Op<"private", [IsolatedFromAbove, RecipeInterface]>
return region.empty() ? nullptr : region.getArgument(0);
}
+ /// Returns true if the init region might read from the mold argument
+ bool initReadsFromMold() {
+ BlockArgument moldArg = getInitMoldArg();
+ return moldArg ? !moldArg.use_empty() : false;
----------------
skatrak wrote:
Nit: I think it's a bit simpler this way, but feel free to ignore.
```suggestion
return moldArg && !moldArg.use_empty();
```
https://github.com/llvm/llvm-project/pull/125307
More information about the llvm-branch-commits
mailing list