-
Notifications
You must be signed in to change notification settings - Fork 10.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Frontend][OpenMP] Privatizing clauses in construct decomposition #92176
[Frontend][OpenMP] Privatizing clauses in construct decomposition #92176
Conversation
Add remaining clauses with the "privatizing" property to construct decomposition, specifically to the part handling the `allocate` clause.
@llvm/pr-subscribers-flang-openmp Author: Krzysztof Parzyszek (kparzysz) ChangesAdd remaining clauses with the "privatizing" property to construct decomposition, specifically to the part handling the Full diff: https://github.com/llvm/llvm-project/pull/92176.diff 1 Files Affected:
diff --git a/llvm/include/llvm/Frontend/OpenMP/ConstructDecompositionT.h b/llvm/include/llvm/Frontend/OpenMP/ConstructDecompositionT.h
index 5f12c62b832fc..02c88a58e0993 100644
--- a/llvm/include/llvm/Frontend/OpenMP/ConstructDecompositionT.h
+++ b/llvm/include/llvm/Frontend/OpenMP/ConstructDecompositionT.h
@@ -793,9 +793,14 @@ bool ConstructDecompositionT<C, H>::applyClause(
// [5.2:340:33]
auto canMakePrivateCopy = [](llvm::omp::Clause id) {
switch (id) {
+ // Clauses with "privatization" property:
case llvm::omp::Clause::OMPC_firstprivate:
+ case llvm::omp::Clause::OMPC_in_reduction:
case llvm::omp::Clause::OMPC_lastprivate:
+ case llvm::omp::Clause::OMPC_linear:
case llvm::omp::Clause::OMPC_private:
+ case llvm::omp::Clause::OMPC_reduction:
+ case llvm::omp::Clause::OMPC_task_reduction:
return true;
default:
return false;
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there a way we could test this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
Co-authored-by: Tom Eccles <t@freedommail.info>
…vm#92176) Add remaining clauses with the "privatizing" property to construct decomposition, specifically to the part handling the `allocate` clause. --------- Co-authored-by: Tom Eccles <t@freedommail.info>
Add remaining clauses with the "privatizing" property to construct decomposition, specifically to the part handling the
allocate
clause.