2 ; RUN: opt < %s -passes=loop-vectorize -mattr=+sve -force-vector-width=4 -debug-only=loop-vectorize \
3 ; RUN: -prefer-predicate-over-epilogue=scalar-epilogue -S -disable-output 2>&1 | FileCheck %s
4 target triple = "aarch64-linux-gnu"
6 define dso_local void @loop_sve_i1(ptr nocapture %ptr, i64 %N) {
7 ; CHECK-LABEL: LV: Checking a loop in 'loop_sve_i1'
8 ; CHECK: LV: Found an estimated cost of Invalid for VF vscale x 4 For instruction: %0 = load i1, ptr %arrayidx, align 16
9 ; CHECK: LV: Found an estimated cost of Invalid for VF vscale x 4 For instruction: store i1 %add, ptr %arrayidx, align 16
14 %iv = phi i64 [ 0, %entry ], [ %iv.next, %for.body ]
15 %arrayidx = getelementptr inbounds i1, ptr %ptr, i64 %iv
16 %0 = load i1, ptr %arrayidx, align 16
17 %add = add nsw i1 %0, 1
18 store i1 %add, ptr %arrayidx, align 16
19 %iv.next = add i64 %iv, 1
20 %exitcond.not = icmp eq i64 %iv.next, %N
21 br i1 %exitcond.not, label %for.end, label %for.body, !llvm.loop !0
27 !0 = distinct !{!0, !1}
28 !1 = !{!"llvm.loop.vectorize.scalable.enable", i1 true}