[llvm] [LV] codegen for tail-folded epilogue loop (PR #208764)

David Sherwood via llvm-commits llvm-commits at lists.llvm.org
Mon Aug 3 03:32:57 PDT 2026


================
@@ -750,6 +751,12 @@ VPRegionBlock *VPRegionBlock::clone() {
   if (getHeaderMask())
     NewRegion->createHeaderMask();
 
+  // The cloned canonical IV increment instruction already carries over its
+  // original NUW flag via the deep clone above, but the new region's
+  // CanIVInfo defaults to NUW set. Keep the two in sync.
+  if (CanIV && !hasCanonicalIVNUW())
+    NewRegion->CanIVInfo->clearNUW();
----------------
david-arm wrote:

Once https://github.com/llvm/llvm-project/pull/212266 lands this can be rebased.

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


More information about the llvm-commits mailing list