[flang-commits] [flang] [flang][OpenMP] Lower DO, SIMD, and DO SIMD metadirective variants (PR #218555)
via flang-commits
flang-commits at lists.llvm.org
Wed Aug 26 18:47:53 PDT 2026
================
@@ -0,0 +1,562 @@
+! Test lowering of metadirectives with ordinary loop-associated variants.
+
+! RUN: %flang_fc1 -fopenmp -emit-hlfir -fopenmp-version=52 %s -o - | FileCheck %s
+
+! CHECK: #loop_unroll = #llvm.loop_unroll<disable = false, count = 4 : i64>
+! CHECK: #loop_annotation = #llvm.loop_annotation<unroll = #loop_unroll>
+
+! CHECK-LABEL: func.func @_QPtest_do(
+! CHECK-NOT: omp.parallel
+! CHECK: omp.wsloop
----------------
MattPD wrote:
The private declaration and induction assignment are now bound correctly. The complete FileCheck test still passes after `a(i) = i` becomes `a(1) = 1` in either source case, so the body loads need not use the captured private declaration.
Could the checks require both loads from that declaration and thread the captured index and value into the body assignment?
https://github.com/llvm/llvm-project/pull/218555
More information about the flang-commits
mailing list