[PATCH] D17473: [LoopUnroll] Avoid unnecessary DT recomputation.

Mehdi AMINI via llvm-commits llvm-commits at lists.llvm.org
Mon Feb 22 16:43:06 PST 2016


joker.eph added inline comments.

================
Comment at: lib/Transforms/Utils/LoopUnroll.cpp:121
@@ -110,1 +120,3 @@
+      DT->eraseNode(BB);
+    }
 
----------------
Random thought: couldn't the pattern above being implemented more efficiently inside the DT (by breaking the invariant during the process): no need for a temporary vector and the ability to reserve the space in the new dominator (could just directly append the source children vector to the new one).
This pattern seems to appear at multiple places in the codebase (looked very quickly).


Repository:
  rL LLVM

http://reviews.llvm.org/D17473





More information about the llvm-commits mailing list