@@ -2487,6 +2487,19 @@ void
ASTStmtWriter::VisitOMPInterchangeDirective(OMPInterchangeDirective *D) {
Code = serialization::STMT_OMP_INTERCHANGE_DIRECTIVE;
}
+void ASTStmtWriter::VisitOMPCanonicalLoopSequenceTransformationDirective(
+OMPCanonicalLoopSequenceTransformati
https://github.com/rofirrim edited
https://github.com/llvm/llvm-project/pull/139293
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -2487,6 +2487,19 @@ void
ASTStmtWriter::VisitOMPInterchangeDirective(OMPInterchangeDirective *D) {
Code = serialization::STMT_OMP_INTERCHANGE_DIRECTIVE;
}
+void ASTStmtWriter::VisitOMPCanonicalLoopSequenceTransformationDirective(
+OMPCanonicalLoopSequenceTransformati
@@ -1485,7 +1498,81 @@ class SemaOpenMP : public SemaBase {
bool checkTransformableLoopNest(
OpenMPDirectiveKind Kind, Stmt *AStmt, int NumLoops,
SmallVectorImpl &LoopHelpers,
- Stmt *&Body, SmallVectorImpl> &OriginalInits);
+ Stmt *&Body, SmallVectorImp
rofirrim wrote:
> There is still @alexey-bataev's
> [request](https://github.com/llvm/llvm-project/pull/139293/files#r2159465143)
> to separate OMPLoopCategory into a separate PR.
Yep, not forgetting about this one.
@alexey-bataev I've managed to remove the enum because with the recent AST
r
rofirrim wrote:
ping
https://github.com/llvm/llvm-project/pull/155849
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/rofirrim closed
https://github.com/llvm/llvm-project/pull/155849
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/rofirrim updated
https://github.com/llvm/llvm-project/pull/155849
From 365c3c5d18b0c466fee85075d6f6bc3c63267fef Mon Sep 17 00:00:00 2001
From: Roger Ferrer Ibanez
Date: Wed, 27 Aug 2025 08:18:02 +
Subject: [PATCH] [Clang][OpenMP] Add an additional class to hold data that
https://github.com/rofirrim closed
https://github.com/llvm/llvm-project/pull/155848
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -1479,7 +1492,85 @@ class SemaOpenMP : public SemaBase {
bool checkTransformableLoopNest(
OpenMPDirectiveKind Kind, Stmt *AStmt, int NumLoops,
SmallVectorImpl &LoopHelpers,
- Stmt *&Body, SmallVectorImpl> &OriginalInits);
+ Stmt *&Body, SmallVectorImp
https://github.com/rofirrim updated
https://github.com/llvm/llvm-project/pull/155849
From c0a9364dde8eb90d10a8971d2f4598b96c05ac76 Mon Sep 17 00:00:00 2001
From: Roger Ferrer Ibanez
Date: Tue, 26 Aug 2025 13:18:19 +
Subject: [PATCH 1/2] [Clang][NFC] Rename OMPLoopTransformationDirective to
@@ -11664,6 +11664,17 @@ def note_omp_implicit_dsa : Note<
"implicitly determined as %0">;
def err_omp_loop_var_dsa : Error<
"loop iteration variable in the associated loop of 'omp %1' directive may
not be %0, predetermined as %2">;
+def err_omp_not_canonical_loop : Error<
@@ -956,30 +956,42 @@ class OMPLoopBasedDirective : public
OMPExecutableDirective {
}
};
+/// Common class of data shared between
+/// OMPCanonicalLoopNestTransformationDirective and transformations over
+/// canonical loop sequences.
rofirrim wrote:
I did
@@ -956,30 +956,42 @@ class OMPLoopBasedDirective : public
OMPExecutableDirective {
}
};
+/// Common class of data shared between
+/// OMPCanonicalLoopNestTransformationDirective and transformations over
+/// canonical loop sequences.
+class OMPLoopTransformationDirective {
@@ -956,30 +956,42 @@ class OMPLoopBasedDirective : public
OMPExecutableDirective {
}
};
+/// Common class of data shared between
+/// OMPCanonicalLoopNestTransformationDirective and transformations over
+/// canonical loop sequences.
rofirrim wrote:
I'm a
rofirrim wrote:
This change now builds on top of:
- https://github.com/llvm/llvm-project/pull/155849
- https://github.com/llvm/llvm-project/pull/155848
I added a new class `OMPCanonicalLoopSequenceTransformationDirective` which
inherits from a common class `OMPLoopTransformationDirective` whic
https://github.com/rofirrim created
https://github.com/llvm/llvm-project/pull/155848
This is preparatory work for the implementation of `#pragma omp fuse` in
https://github.com/llvm/llvm-project/pull/139293
Not all OpenMP loop transformations makes sense to make them inherit from
`OMPLoopBase
https://github.com/rofirrim created
https://github.com/llvm/llvm-project/pull/155849
This is preparatory work for the implementation of `#pragma omp fuse` in
https://github.com/llvm/llvm-project/pull/139293
**Note**: this change builds on top of
https://github.com/llvm/llvm-project/pull/15584
@@ -508,6 +512,43 @@ OMPInterchangeDirective::CreateEmpty(const ASTContext &C,
unsigned NumClauses,
SourceLocation(), SourceLocation(), NumLoops);
}
+OMPFuseDirective *OMPFuseDirective::Create(
+const ASTContext &C, SourceLocation StartLoc, SourceLocation EndLoc,
+
@@ -5863,7 +5881,10 @@ class OMPInterchangeDirective final : public
OMPLoopTransformationDirective {
: OMPLoopTransformationDirective(OMPInterchangeDirectiveClass,
llvm::omp::OMPD_interchange, StartLoc,
@@ -1479,7 +1492,109 @@ class SemaOpenMP : public SemaBase {
bool checkTransformableLoopNest(
OpenMPDirectiveKind Kind, Stmt *AStmt, int NumLoops,
SmallVectorImpl &LoopHelpers,
- Stmt *&Body, SmallVectorImpl> &OriginalInits);
+ Stmt *&Body, SmallVectorIm
@@ -1479,7 +1492,109 @@ class SemaOpenMP : public SemaBase {
bool checkTransformableLoopNest(
OpenMPDirectiveKind Kind, Stmt *AStmt, int NumLoops,
SmallVectorImpl &LoopHelpers,
- Stmt *&Body, SmallVectorImpl> &OriginalInits);
+ Stmt *&Body, SmallVectorIm
@@ -11664,6 +11664,17 @@ def note_omp_implicit_dsa : Note<
"implicitly determined as %0">;
def err_omp_loop_var_dsa : Error<
"loop iteration variable in the associated loop of 'omp %1' directive may
not be %0, predetermined as %2">;
+def err_omp_not_canonical_loop : Error<
@@ -11664,6 +11664,17 @@ def note_omp_implicit_dsa : Note<
"implicitly determined as %0">;
def err_omp_loop_var_dsa : Error<
"loop iteration variable in the associated loop of 'omp %1' directive may
not be %0, predetermined as %2">;
+def err_omp_not_canonical_loop : Error<
@@ -11664,6 +11664,17 @@ def note_omp_implicit_dsa : Note<
"implicitly determined as %0">;
def err_omp_loop_var_dsa : Error<
"loop iteration variable in the associated loop of 'omp %1' directive may
not be %0, predetermined as %2">;
+def err_omp_not_canonical_loop : Error<
@@ -1479,7 +1492,109 @@ class SemaOpenMP : public SemaBase {
bool checkTransformableLoopNest(
OpenMPDirectiveKind Kind, Stmt *AStmt, int NumLoops,
SmallVectorImpl &LoopHelpers,
- Stmt *&Body, SmallVectorImpl> &OriginalInits);
+ Stmt *&Body, SmallVectorIm
rofirrim wrote:
Thanks for the clarification @Meinersbur !
https://github.com/llvm/llvm-project/pull/139293
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
rofirrim wrote:
Hi @Meinersbur, thanks for the detailed answer.
> Just recording the loop nesting of this may result in gls = [ 3 ]. Ovever,
> the tile size depends on the outer loop which the OpenMP restrictions on
> canonical loop nests do not allow.
Right, this breaks my suggested bottom-u
rofirrim wrote:
> Need a rebase
Done.
I still owe you to split that new `enum`.
@Meinersbur if you have thoughts about this comment here
https://github.com/llvm/llvm-project/pull/139293#issuecomment-3074305797 , I'd
be very thankful.
https://github.com/llvm/llvm-project/pull/139293
@@ -1143,6 +1143,83 @@ class OMPFullClause final : public
OMPNoChildClause {
static OMPFullClause *CreateEmpty(const ASTContext &C);
};
+/// This class represents the 'looprange' clause in the
+/// '#pragma omp fuse' directive
+///
+/// \code {c}
+/// #pragma omp fuse loopr
rofirrim wrote:
I'm a bit uncertain with what we want to do with `NumGeneratedLoopNests` and
`NumGeneratedLoops`.
I understand that, outside of dependent contexts, this is some sort of
synthesised attribute (in the base case from analysing the loop nests /
canonical loop sequences) that can b
rofirrim wrote:
Hi all, @eZWALT is changing jobs and kindly asked me if I could finish on his
behalf. I plan to go through all the items of feedback and then rebase against
main.
https://github.com/llvm/llvm-project/pull/139293
___
cfe-commits mailin
rofirrim wrote:
> I'm guessing that is a yes, could you @alexey-bataev please approve the
> workflows and we proceed to merge? Then we can go straight into the
> https://github.com/llvm/llvm-project/pull/139293 PR :)
I did that already.
https://github.com/llvm/llvm-project/pull/140532
___
rofirrim wrote:
LGTM. Thanks @topperc !
https://github.com/llvm/llvm-project/pull/126188
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
34 matches
Mail list logo