[flang-commits] [flang] [flang][openacc] Lower loop directive to the new acc.loop op design (PR #65417)

Razvan Lupusoru via flang-commits flang-commits at lists.llvm.org
Wed Sep 6 12:39:21 PDT 2023


================
@@ -1514,12 +1597,15 @@ static void genACC(Fortran::lower::AbstractConverter &converter,
       converter.genLocation(beginLoopDirective.source);
   Fortran::lower::StatementContext stmtCtx;
 
-  if (loopDirective.v == llvm::acc::ACCD_loop) {
-    const auto &accClauseList =
-        std::get<Fortran::parser::AccClauseList>(beginLoopDirective.t);
-    createLoopOp(converter, currentLocation, semanticsContext, stmtCtx,
-                 accClauseList);
-  }
+  if (loopDirective.v != llvm::acc::ACCD_loop)
+    llvm::report_fatal_error("Unsupported OpenACC loop construct");
----------------
razvanlupusoru wrote:

This feels like it should be an assert.

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


More information about the flang-commits mailing list