================
@@ -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'">;
----------------
eZWALT wrote:

The two errors serve different purposes:

1. The first is triggered when the loop sequence inside a fusion construct 
(full or ranged) contains no loops.
2. The second is specific to loopranged fusion and reports when the specified 
range exceeds the number of available loops.

While the first case is technically a subset of the second, they occur in 
different contexts. Keeping both improves clarity and helps users better 
understand the issue. That said, I’m open to refactoring if you'd prefer a 
single, more general diagnostic, though it may reduce the precision of the 
error messages.

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

Reply via email to