[Mlir-commits] [flang] [mlir] [Flang][MLIR] Add `!$omp unroll` and `omp.unroll_heuristic` (PR #144785)
Kareem Ergawy
llvmlistbot at llvm.org
Mon Jun 30 05:08:47 PDT 2025
================
@@ -0,0 +1,39 @@
+! RUN: %flang_fc1 -emit-hlfir -fopenmp -fopenmp-version=51 -o - %s 2>&1 | FileCheck %s
+
+
+subroutine omp_unroll_heuristic01(lb, ub, inc)
+ integer res, i, lb, ub, inc
+
+ !$omp unroll
+ do i = lb, ub, inc
+ res = i
+ end do
+ !$omp end unroll
+
+end subroutine omp_unroll_heuristic01
+
+
+!CHECK-LABEL: func.func @_QPomp_unroll_heuristic01(
+!CHECK: %c0_i32 = arith.constant 0 : i32
----------------
ergawy wrote:
Can you capture SSA value names using descriptive names (e.g. `trip_count`, `ub`, `lb`, etc.?
https://github.com/llvm/llvm-project/pull/144785
More information about the Mlir-commits
mailing list