[clang] [flang] [llvm] [openmp] [Clang][OpenMP][LoopTransformations] Add support for "#pragma omp fuse" loop transformation directive and "looprange" clause (PR #139293)
Michael Kruse via cfe-commits
cfe-commits at lists.llvm.org
Fri Jun 20 05:06:13 PDT 2025
================
@@ -11516,6 +11516,21 @@ 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 warn_omp_different_loop_ind_var_types : Warning <
+ "loop sequence following '#pragma omp %0' contains induction variables of differing types: %1 and %2">,
+ InGroup<OpenMPLoopForm>;
+def err_omp_not_canonical_loop : Error <
+ "loop after '#pragma omp %0' is not in canonical form">;
+def err_omp_not_a_loop_sequence : Error <
+ "statement after '#pragma omp %0' must be a loop sequence containing canonical loops or loop-generating constructs">;
+def err_omp_empty_loop_sequence : Error <
+ "loop sequence after '#pragma omp %0' must contain at least 1 canonical loop or loop-generating construct">;
+def err_omp_invalid_looprange : Error <
+ "loop range in '#pragma omp %0' exceeds the number of available loops: "
+ "range end '%1' is greater than the total number of loops '%2'">;
----------------
Meinersbur wrote:
I think he means that "exceeds the number of available loops" and "range end '%1' is greater than the total number of loops '%2'" are redundant. (of the err_omp_invalid_looprange definition). Proposal:
"looprange clause selection exceeds number of loops in loop sequence" (or similar)
I don't think mentioning '#pragma omp %0' is necessary, it is already pointed to by the SourceLocation.
%1 and %2 are numbers, not necessary to put them in quotes
https://github.com/llvm/llvm-project/pull/139293
More information about the cfe-commits
mailing list