[llvm] [VPlan] Don't use the legacy cost model for loop conditions (PR #156864)
David Sherwood via llvm-commits
llvm-commits at lists.llvm.org
Tue Sep 9 05:54:14 PDT 2025
================
@@ -9,11 +9,12 @@ define i64 @test(ptr %a, ptr %b) #0 {
; CHECK-LABEL: LV: Checking a loop in 'test'
; CHECK: Cost of 1 for VF 8: induction instruction %i.iv.next = add nuw nsw i64 %i.iv, 1
; CHECK-NEXT: Cost of 0 for VF 8: induction instruction %i.iv = phi i64 [ 0, %entry ], [ %i.iv.next, %for.body ]
-; CHECK-NEXT: Cost of 1 for VF 8: exit condition instruction %exitcond.not = icmp eq i64 %i.iv.next, 16
; CHECK-NEXT: Cost of 0 for VF 8: EMIT vp<{{.+}}> = CANONICAL-INDUCTION ir<0>, vp<%index.next>
+; CHECK: Cost of 1 for VF 8: EMIT branch-on-count vp<%index.next>, vp<{{.+}}>
----------------
david-arm wrote:
I think @igogo-x86 added this file in #106699. You might also want to remove `addFullyUnrolledInstructionsToIgnore`, since you're now dealing with the cost properly in vplan?
https://github.com/llvm/llvm-project/pull/156864
More information about the llvm-commits
mailing list