[llvm-branch-commits] [flang] [flang][OpenMP] Map simple `do concurrent` loops to OpenMP host constructs (PR #127633)

Kareem Ergawy via llvm-branch-commits llvm-branch-commits at lists.llvm.org
Thu Feb 20 07:47:26 PST 2025


================
@@ -93,11 +169,14 @@ bool isPerfectlyNested(fir::DoLoopOp outerLoop, fir::DoLoopOp innerLoop) {
 /// recognize a certain nested loop as part of the nest it just returns the
 /// parent loops it discovered before.
 mlir::LogicalResult collectLoopNest(fir::DoLoopOp currentLoop,
-                                    LoopNest &loopNest) {
+                                    LoopNestToIndVarMap &loopNest) {
   assert(currentLoop.getUnordered());
 
   while (true) {
-    loopNest.insert(currentLoop);
+    loopNest.try_emplace(
----------------
ergawy wrote:

Strangely enough, there is no `emplace`. There is `insert` thought, this might look less weird. Used it.

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


More information about the llvm-branch-commits mailing list