[llvm] [VPlan] Model branch cond to enter scalar epilogue in VPlan. (PR #92651)

via llvm-commits llvm-commits at lists.llvm.org
Thu Jul 4 05:25:16 PDT 2024


================
@@ -651,16 +653,17 @@ static std::pair<VPBlockBase *, VPBlockBase *> cloneSESE(VPBlockBase *Entry);
 // Clone the CFG for all nodes in the single-entry-single-exit region reachable
 // from \p Entry, this includes cloning the blocks and their recipes. Operands
 // of cloned recipes will NOT be updated. Remapping of operands must be done
-// separately. Returns a pair with the the new entry and exiting blocks of the
-// cloned region.
+// separately. Returns a pair with the new entry and exiting blocks of the
+// cloned region. If \p Entry isn't part of a region, return nullptr for the exiting block.
----------------
ayalz wrote:

Could be pushed earlier, independently, but testable only now, i.e., InRegion can currently be asserted?

The name says `cloneSESE`, so a single exit is expected and should be asserted, even if Entry is not part of a region? Or should this be renamed, say, to `cloneFrom`?

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


More information about the llvm-commits mailing list