[llvm-branch-commits] [flang] [Flang][OpenMP] Push genEval closer to leaf lowering functions (PR #77760)

Krzysztof Parzyszek via llvm-branch-commits llvm-branch-commits at lists.llvm.org
Fri Jan 12 07:05:12 PST 2024


================
@@ -2248,11 +2248,15 @@ static void createBodyOfOp(
     if (clauses)
       ClauseProcessor(converter, *clauses).processCopyin();
   }
+
+  if (genNested)
+    genNestedEvaluations(converter, eval);
 }
 
 static void genBodyOfTargetDataOp(
     Fortran::lower::AbstractConverter &converter,
-    Fortran::lower::pft::Evaluation &eval, mlir::omp::DataOp &dataOp,
+    Fortran::lower::pft::Evaluation &eval, bool genNested,
----------------
kparzysz wrote:

I made it so that the `genNested` argument is set in the genOMP functions and then passed on to all nested calls.  This is to make the calls have a more consistent treatment.

If we even do the breakup where each function creates only one op, then this argument will always be `true`, and can be eliminated.

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


More information about the llvm-branch-commits mailing list