[flang-commits] [flang] [llvm] Enabling support for Allocate clause in DO construct (PR #180172)

Jack Styles via flang-commits flang-commits at lists.llvm.org
Fri Feb 6 04:49:32 PST 2026


================
@@ -890,6 +890,7 @@ def OMP_Distribute : Directive<[Spelling<"distribute">]> {
 }
 def OMP_Do : Directive<[Spelling<"do">]> {
   let allowedClauses = [
+    VersionedClause<OMPC_Allocate>,
----------------
Stylie777 wrote:

```suggestion
    VersionedClause<OMPC_Allocate, 50>,
```
Allocate was allowed on `!$omp do` after OpenMP 5.0. We need to make sure this is applied in TableGen and tested that when, for example` `-fopenmp-version=45` is used, then Flang rejects this.

https://github.com/llvm/llvm-project/pull/180172


More information about the flang-commits mailing list