[flang-commits] [flang] [Flang][OpenMP] Support unstructured code in target data (PR #71051)

via flang-commits flang-commits at lists.llvm.org
Thu Nov 2 06:20:25 PDT 2023


================
@@ -2213,6 +2212,27 @@ static void createBodyOfTargetDataOp(
     }
     argIndex++;
   }
+
+  // Insert dummy instruction to remember the insertion position. The
+  // marker will be deleted since there are not uses.
+  // In the HLFIR flow there are hlfir.declares inserted above while
+  // setting block arguments.
+  mlir::Value undefMarker = firOpBuilder.create<fir::UndefOp>(
+      dataOp.getOperation()->getLoc(), firOpBuilder.getIndexType());
+
+  // Create blocks for unstructured regions. This has to be done since
+  // the original block allocation are created with the function as
----------------
agozillon wrote:

Nit: either "allocation -> allocations" or "are -> is", not sure which is correct in this context

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


More information about the flang-commits mailing list