[PATCH] D22320: Codegen: Tail Duplication: Only duplicate into layout pred if it is a CFG Pred.

Kyle Butt via llvm-commits llvm-commits at lists.llvm.org
Wed Jul 13 16:00:42 PDT 2016


iteratee added inline comments.

================
Comment at: lib/CodeGen/TailDuplicator.cpp:817
@@ -816,2 +816,3 @@
   if (PrevBB->succ_size() == 1 &&
+      *PrevBB->succ_begin() == TailBB &&
       !TII->AnalyzeBranch(*PrevBB, PriorTBB, PriorFBB, PriorCond, true) &&
----------------
echristo wrote:
> Can you update and elaborate on the comment for this?
The comment now matches the code. "except for the prior block, which falls through unconditionally, move the contents of this block into the prior block."

But I'll add a comment to this line to the effect of "Layout preds are not always CFG preds", above this line.


http://reviews.llvm.org/D22320





More information about the llvm-commits mailing list