; LLVM IR from tangjz/acm-icpc :: projecteuler (577)

; Unoptimized IR (clang -disable-llvm-passes):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

@f = external dso_local global [30001 x i32], align 16
@g = external dso_local global [30001 x i64], align 16
@.str = external hidden unnamed_addr constant [3 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [6 x i8], align 1

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() #0 {
  %1 = alloca i32, align 4
  %2 = alloca i32, align 4
  %3 = alloca i32, align 4
  %4 = alloca i32, align 4
  %5 = alloca i32, align 4
  %6 = alloca i32, align 4
  %7 = alloca i32, align 4
  %8 = alloca i64, align 8
  %9 = alloca i32, align 4
  store i32 0, ptr %1, align 4
  store i32 1, ptr @f, align 16, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %2) #3
  store i32 1, ptr %2, align 4, !tbaa !5
  br label %10

10:                                               ; preds = %26, %0
  %11 = load i32, ptr %2, align 4, !tbaa !5
  %12 = icmp slt i32 %11, 30001
  br i1 %12, label %14, label %13

13:                                               ; preds = %10
  call void @llvm.lifetime.end.p0(i64 4, ptr %2) #3
  br label %29

14:                                               ; preds = %10
  %15 = load i32, ptr %2, align 4, !tbaa !5
  %16 = sub nsw i32 %15, 1
  %17 = sext i32 %16 to i64
  %18 = getelementptr inbounds [30001 x i32], ptr @f, i64 0, i64 %17
  %19 = load i32, ptr %18, align 4, !tbaa !5
  %20 = load i32, ptr %2, align 4, !tbaa !5
  %21 = add nsw i32 %19, %20
  %22 = add nsw i32 %21, 1
  %23 = load i32, ptr %2, align 4, !tbaa !5
  %24 = sext i32 %23 to i64
  %25 = getelementptr inbounds [30001 x i32], ptr @f, i64 0, i64 %24
  store i32 %22, ptr %25, align 4, !tbaa !5
  br label %26

26:                                               ; preds = %14
  %27 = load i32, ptr %2, align 4, !tbaa !5
  %28 = add nsw i32 %27, 1
  store i32 %28, ptr %2, align 4, !tbaa !5
  br label %10, !llvm.loop !9

29:                                               ; preds = %13
  call void @llvm.lifetime.start.p0(i64 4, ptr %3) #3
  store i32 1, ptr %3, align 4, !tbaa !5
  br label %30

30:                                               ; preds = %62, %29
  %31 = load i32, ptr %3, align 4, !tbaa !5
  %32 = icmp slt i32 %31, 30001
  br i1 %32, label %34, label %33

33:                                               ; preds = %30
  store i32 5, ptr %4, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %3) #3
  br label %65

34:                                               ; preds = %30
  call void @llvm.lifetime.start.p0(i64 4, ptr %5) #3
  store i32 3, ptr %5, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %6) #3
  store i32 1, ptr %6, align 4, !tbaa !5
  br label %35

35:                                               ; preds = %56, %34
  %36 = load i32, ptr %5, align 4, !tbaa !5
  %37 = load i32, ptr %3, align 4, !tbaa !5
  %38 = icmp sle i32 %36, %37
  br i1 %38, label %40, label %39

39:                                               ; preds = %35
  store i32 8, ptr %4, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %6) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %5) #3
  br label %61

40:                                               ; preds = %35
  %41 = load i32, ptr %3, align 4, !tbaa !5
  %42 = load i32, ptr %5, align 4, !tbaa !5
  %43 = sub nsw i32 %41, %42
  %44 = sext i32 %43 to i64
  %45 = getelementptr inbounds [30001 x i32], ptr @f, i64 0, i64 %44
  %46 = load i32, ptr %45, align 4, !tbaa !5
  %47 = sext i32 %46 to i64
  %48 = load i32, ptr %6, align 4, !tbaa !5
  %49 = sext i32 %48 to i64
  %50 = mul nsw i64 %47, %49
  %51 = load i32, ptr %3, align 4, !tbaa !5
  %52 = sext i32 %51 to i64
  %53 = getelementptr inbounds [30001 x i64], ptr @g, i64 0, i64 %52
  %54 = load i64, ptr %53, align 8, !tbaa !11
  %55 = add nsw i64 %54, %50
  store i64 %55, ptr %53, align 8, !tbaa !11
  br label %56

56:                                               ; preds = %40
  %57 = load i32, ptr %5, align 4, !tbaa !5
  %58 = add nsw i32 %57, 3
  store i32 %58, ptr %5, align 4, !tbaa !5
  %59 = load i32, ptr %6, align 4, !tbaa !5
  %60 = add nsw i32 %59, 1
  store i32 %60, ptr %6, align 4, !tbaa !5
  br label %35, !llvm.loop !13

61:                                               ; preds = %39
  br label %62

62:                                               ; preds = %61
  %63 = load i32, ptr %3, align 4, !tbaa !5
  %64 = add nsw i32 %63, 1
  store i32 %64, ptr %3, align 4, !tbaa !5
  br label %30, !llvm.loop !14

65:                                               ; preds = %33
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #3
  br label %66

66:                                               ; preds = %86, %65
  %67 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef %7)
  %68 = icmp eq i32 %67, 1
  br i1 %68, label %70, label %69

69:                                               ; preds = %66
  store i32 11, ptr %4, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #3
  br label %89

70:                                               ; preds = %66
  call void @llvm.lifetime.start.p0(i64 8, ptr %8) #3
  store i64 0, ptr %8, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #3
  store i32 1, ptr %9, align 4, !tbaa !5
  br label %71

71:                                               ; preds = %83, %70
  %72 = load i32, ptr %9, align 4, !tbaa !5
  %73 = load i32, ptr %7, align 4, !tbaa !5
  %74 = icmp sle i32 %72, %73
  br i1 %74, label %76, label %75

75:                                               ; preds = %71
  store i32 13, ptr %4, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #3
  br label %86

76:                                               ; preds = %71
  %77 = load i32, ptr %9, align 4, !tbaa !5
  %78 = sext i32 %77 to i64
  %79 = getelementptr inbounds [30001 x i64], ptr @g, i64 0, i64 %78
  %80 = load i64, ptr %79, align 8, !tbaa !11
  %81 = load i64, ptr %8, align 8, !tbaa !11
  %82 = add nsw i64 %81, %80
  store i64 %82, ptr %8, align 8, !tbaa !11
  br label %83

83:                                               ; preds = %76
  %84 = load i32, ptr %9, align 4, !tbaa !5
  %85 = add nsw i32 %84, 1
  store i32 %85, ptr %9, align 4, !tbaa !5
  br label %71, !llvm.loop !15

86:                                               ; preds = %75
  %87 = load i64, ptr %8, align 8, !tbaa !11
  %88 = call i32 (ptr, ...) @printf(ptr noundef @.str.1, i64 noundef %87)
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #3
  br label %66, !llvm.loop !16

89:                                               ; preds = %69
  ret i32 0
}

; Function Attrs: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.start.p0(i64 immarg, ptr nocapture) #1

; Function Attrs: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.end.p0(i64 immarg, ptr nocapture) #1

declare i32 @__isoc99_scanf(ptr noundef, ...) #2

declare i32 @printf(ptr noundef, ...) #2

attributes #0 = { mustprogress norecurse uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { nounwind }

!llvm.module.flags = !{!0, !1, !2, !3}
!llvm.ident = !{!4}

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"int", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = distinct !{!9, !10}
!10 = !{!"llvm.loop.mustprogress"}
!11 = !{!12, !12, i64 0}
!12 = !{!"long long", !7, i64 0}
!13 = distinct !{!13, !10}
!14 = distinct !{!14, !10}
!15 = distinct !{!15, !10}
!16 = distinct !{!16, !10}


; Optimized IR (opt -passes='default<O3>'):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

@f = external dso_local local_unnamed_addr global [30001 x i32], align 16
@g = external dso_local local_unnamed_addr global [30001 x i64], align 16
@.str = external hidden unnamed_addr constant [3 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [6 x i8], align 1

; Function Attrs: mustprogress nofree norecurse nounwind uwtable
define dso_local noundef i32 @main() local_unnamed_addr #0 {
  %1 = alloca i32, align 4
  store i32 1, ptr @f, align 16, !tbaa !5
  br label %2

2:                                                ; preds = %2, %0
  %3 = phi i32 [ 1, %0 ], [ %20, %2 ]
  %indvars.iv = phi i64 [ 1, %0 ], [ %indvars.iv.next.5, %2 ]
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %4 = trunc nuw nsw i64 %indvars.iv.next to i32
  %5 = add i32 %3, %4
  %6 = getelementptr inbounds [30001 x i32], ptr @f, i64 0, i64 %indvars.iv
  store i32 %5, ptr %6, align 4, !tbaa !5
  %indvars.iv.next.1 = add nuw nsw i64 %indvars.iv, 2
  %7 = trunc nuw nsw i64 %indvars.iv.next.1 to i32
  %8 = add i32 %5, %7
  %9 = getelementptr inbounds [30001 x i32], ptr @f, i64 0, i64 %indvars.iv.next
  store i32 %8, ptr %9, align 4, !tbaa !5
  %indvars.iv.next.2 = add nuw nsw i64 %indvars.iv, 3
  %10 = trunc nuw nsw i64 %indvars.iv.next.2 to i32
  %11 = add i32 %8, %10
  %12 = getelementptr inbounds [30001 x i32], ptr @f, i64 0, i64 %indvars.iv.next.1
  store i32 %11, ptr %12, align 4, !tbaa !5
  %indvars.iv.next.3 = add nuw nsw i64 %indvars.iv, 4
  %13 = trunc nuw nsw i64 %indvars.iv.next.3 to i32
  %14 = add i32 %11, %13
  %15 = getelementptr inbounds [30001 x i32], ptr @f, i64 0, i64 %indvars.iv.next.2
  store i32 %14, ptr %15, align 4, !tbaa !5
  %indvars.iv.next.4 = add nuw nsw i64 %indvars.iv, 5
  %16 = trunc nuw nsw i64 %indvars.iv.next.4 to i32
  %17 = add i32 %14, %16
  %18 = getelementptr inbounds [30001 x i32], ptr @f, i64 0, i64 %indvars.iv.next.3
  store i32 %17, ptr %18, align 4, !tbaa !5
  %indvars.iv.next.5 = add nuw nsw i64 %indvars.iv, 6
  %19 = trunc nuw nsw i64 %indvars.iv.next.5 to i32
  %20 = add i32 %17, %19
  %21 = getelementptr inbounds [30001 x i32], ptr @f, i64 0, i64 %indvars.iv.next.4
  store i32 %20, ptr %21, align 4, !tbaa !5
  %exitcond.not.5 = icmp eq i64 %indvars.iv.next.5, 30001
  br i1 %exitcond.not.5, label %.preheader26, label %2, !llvm.loop !9

.preheader26:                                     ; preds = %2, %36
  %indvars.iv51 = phi i64 [ %indvars.iv.next52, %36 ], [ 1, %2 ]
  %indvars.iv48 = phi i32 [ %indvars.iv.next49, %36 ], [ -2, %2 ]
  %22 = udiv i32 %indvars.iv48, 3
  %narrow = add nuw nsw i32 %22, 1
  %23 = zext nneg i32 %narrow to i64
  %.not2529 = icmp ult i64 %indvars.iv51, 3
  br i1 %.not2529, label %36, label %.lr.ph

.lr.ph:                                           ; preds = %.preheader26
  %24 = getelementptr inbounds [30001 x i64], ptr @g, i64 0, i64 %indvars.iv51
  %.promoted = load i64, ptr %24, align 8, !tbaa !11
  %xtraiter = and i64 %23, 3
  %25 = icmp ult i32 %indvars.iv48, 9
  br i1 %25, label %._crit_edge.unr-lcssa, label %.lr.ph.new

.lr.ph.new:                                       ; preds = %.lr.ph
  %unroll_iter = and i64 %23, 2147483644
  br label %37

26:                                               ; preds = %36
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %1) #4
  %27 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull %1)
  %28 = icmp eq i32 %27, 1
  br i1 %28, label %.preheader, label %._crit_edge38

._crit_edge.unr-lcssa:                            ; preds = %37, %.lr.ph
  %.lcssa67.ph = phi i64 [ poison, %.lr.ph ], [ %62, %37 ]
  %indvars.iv43.unr = phi i64 [ 3, %.lr.ph ], [ %indvars.iv.next44.3, %37 ]
  %indvars.iv41.unr = phi i64 [ 1, %.lr.ph ], [ %indvars.iv.next42.3, %37 ]
  %.unr = phi i64 [ %.promoted, %.lr.ph ], [ %62, %37 ]
  %lcmp.mod.not = icmp eq i64 %xtraiter, 0
  br i1 %lcmp.mod.not, label %._crit_edge, label %.epil.preheader

.epil.preheader:                                  ; preds = %._crit_edge.unr-lcssa, %.epil.preheader
  %indvars.iv43.epil = phi i64 [ %indvars.iv.next44.epil, %.epil.preheader ], [ %indvars.iv43.unr, %._crit_edge.unr-lcssa ]
  %indvars.iv41.epil = phi i64 [ %indvars.iv.next42.epil, %.epil.preheader ], [ %indvars.iv41.unr, %._crit_edge.unr-lcssa ]
  %29 = phi i64 [ %35, %.epil.preheader ], [ %.unr, %._crit_edge.unr-lcssa ]
  %epil.iter = phi i64 [ %epil.iter.next, %.epil.preheader ], [ 0, %._crit_edge.unr-lcssa ]
  %30 = sub nsw i64 %indvars.iv51, %indvars.iv43.epil
  %31 = getelementptr inbounds [30001 x i32], ptr @f, i64 0, i64 %30
  %32 = load i32, ptr %31, align 4, !tbaa !5
  %33 = sext i32 %32 to i64
  %34 = mul nsw i64 %indvars.iv41.epil, %33
  %35 = add nsw i64 %34, %29
  %indvars.iv.next44.epil = add nuw nsw i64 %indvars.iv43.epil, 3
  %indvars.iv.next42.epil = add nuw nsw i64 %indvars.iv41.epil, 1
  %epil.iter.next = add i64 %epil.iter, 1
  %epil.iter.cmp.not = icmp eq i64 %epil.iter.next, %xtraiter
  br i1 %epil.iter.cmp.not, label %._crit_edge, label %.epil.preheader, !llvm.loop !13

._crit_edge:                                      ; preds = %.epil.preheader, %._crit_edge.unr-lcssa
  %.lcssa67 = phi i64 [ %.lcssa67.ph, %._crit_edge.unr-lcssa ], [ %35, %.epil.preheader ]
  store i64 %.lcssa67, ptr %24, align 8, !tbaa !11
  br label %36

36:                                               ; preds = %._crit_edge, %.preheader26
  %indvars.iv.next52 = add nuw nsw i64 %indvars.iv51, 1
  %indvars.iv.next49 = add nsw i32 %indvars.iv48, 1
  %exitcond54.not = icmp eq i64 %indvars.iv.next52, 30001
  br i1 %exitcond54.not, label %26, label %.preheader26, !llvm.loop !15

37:                                               ; preds = %37, %.lr.ph.new
  %indvars.iv43 = phi i64 [ 3, %.lr.ph.new ], [ %indvars.iv.next44.3, %37 ]
  %indvars.iv41 = phi i64 [ 1, %.lr.ph.new ], [ %indvars.iv.next42.3, %37 ]
  %38 = phi i64 [ %.promoted, %.lr.ph.new ], [ %62, %37 ]
  %niter = phi i64 [ 0, %.lr.ph.new ], [ %niter.next.3, %37 ]
  %39 = sub nsw i64 %indvars.iv51, %indvars.iv43
  %40 = getelementptr inbounds [30001 x i32], ptr @f, i64 0, i64 %39
  %41 = load i32, ptr %40, align 4, !tbaa !5
  %42 = sext i32 %41 to i64
  %43 = mul nsw i64 %indvars.iv41, %42
  %44 = add nsw i64 %43, %38
  %indvars.iv.next44 = add nuw nsw i64 %indvars.iv43, 3
  %indvars.iv.next42 = add nuw nsw i64 %indvars.iv41, 1
  %45 = sub nsw i64 %indvars.iv51, %indvars.iv.next44
  %46 = getelementptr inbounds [30001 x i32], ptr @f, i64 0, i64 %45
  %47 = load i32, ptr %46, align 4, !tbaa !5
  %48 = sext i32 %47 to i64
  %49 = mul nsw i64 %indvars.iv.next42, %48
  %50 = add nsw i64 %49, %44
  %indvars.iv.next44.1 = add nuw nsw i64 %indvars.iv43, 6
  %indvars.iv.next42.1 = add nuw nsw i64 %indvars.iv41, 2
  %51 = sub nsw i64 %indvars.iv51, %indvars.iv.next44.1
  %52 = getelementptr inbounds [30001 x i32], ptr @f, i64 0, i64 %51
  %53 = load i32, ptr %52, align 4, !tbaa !5
  %54 = sext i32 %53 to i64
  %55 = mul nsw i64 %indvars.iv.next42.1, %54
  %56 = add nsw i64 %55, %50
  %indvars.iv.next44.2 = add nuw nsw i64 %indvars.iv43, 9
  %indvars.iv.next42.2 = add nuw nsw i64 %indvars.iv41, 3
  %57 = sub nsw i64 %indvars.iv51, %indvars.iv.next44.2
  %58 = getelementptr inbounds [30001 x i32], ptr @f, i64 0, i64 %57
  %59 = load i32, ptr %58, align 4, !tbaa !5
  %60 = sext i32 %59 to i64
  %61 = mul nsw i64 %indvars.iv.next42.2, %60
  %62 = add nsw i64 %61, %56
  %indvars.iv.next44.3 = add nuw nsw i64 %indvars.iv43, 12
  %indvars.iv.next42.3 = add nuw nsw i64 %indvars.iv41, 4
  %niter.next.3 = add i64 %niter, 4
  %niter.ncmp.3 = icmp eq i64 %niter.next.3, %unroll_iter
  br i1 %niter.ncmp.3, label %._crit_edge.unr-lcssa, label %37, !llvm.loop !16

.preheader:                                       ; preds = %26, %._crit_edge37
  %63 = load i32, ptr %1, align 4, !tbaa !5
  %.not33 = icmp slt i32 %63, 1
  br i1 %.not33, label %._crit_edge37, label %.lr.ph36.preheader

.lr.ph36.preheader:                               ; preds = %.preheader
  %64 = add nuw i32 %63, 1
  %wide.trip.count58 = zext i32 %64 to i64
  %65 = zext nneg i32 %63 to i64
  %min.iters.check = icmp ult i32 %63, 4
  br i1 %min.iters.check, label %.lr.ph36.preheader64, label %vector.ph

.lr.ph36.preheader64:                             ; preds = %middle.block, %.lr.ph36.preheader
  %indvars.iv55.ph = phi i64 [ 1, %.lr.ph36.preheader ], [ %ind.end, %middle.block ]
  %.02034.ph = phi i64 [ 0, %.lr.ph36.preheader ], [ %71, %middle.block ]
  br label %.lr.ph36

vector.ph:                                        ; preds = %.lr.ph36.preheader
  %n.vec = and i64 %65, 2147483644
  %ind.end = or disjoint i64 %n.vec, 1
  br label %vector.body

vector.body:                                      ; preds = %vector.body, %vector.ph
  %index = phi i64 [ 0, %vector.ph ], [ %index.next, %vector.body ]
  %vec.phi = phi <2 x i64> [ zeroinitializer, %vector.ph ], [ %68, %vector.body ]
  %vec.phi62 = phi <2 x i64> [ zeroinitializer, %vector.ph ], [ %69, %vector.body ]
  %offset.idx = or disjoint i64 %index, 1
  %66 = getelementptr inbounds [30001 x i64], ptr @g, i64 0, i64 %offset.idx
  %67 = getelementptr inbounds i8, ptr %66, i64 16
  %wide.load = load <2 x i64>, ptr %66, align 8, !tbaa !11
  %wide.load63 = load <2 x i64>, ptr %67, align 8, !tbaa !11
  %68 = add <2 x i64> %wide.load, %vec.phi
  %69 = add <2 x i64> %wide.load63, %vec.phi62
  %index.next = add nuw i64 %index, 4
  %70 = icmp eq i64 %index.next, %n.vec
  br i1 %70, label %middle.block, label %vector.body, !llvm.loop !17

middle.block:                                     ; preds = %vector.body
  %bin.rdx = add <2 x i64> %69, %68
  %71 = call i64 @llvm.vector.reduce.add.v2i64(<2 x i64> %bin.rdx)
  %cmp.n = icmp eq i64 %n.vec, %65
  br i1 %cmp.n, label %._crit_edge37, label %.lr.ph36.preheader64

._crit_edge38:                                    ; preds = %._crit_edge37, %26
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %1) #4
  ret i32 0

._crit_edge37:                                    ; preds = %.lr.ph36, %middle.block, %.preheader
  %.020.lcssa = phi i64 [ 0, %.preheader ], [ %71, %middle.block ], [ %77, %.lr.ph36 ]
  %72 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.1, i64 noundef %.020.lcssa)
  %73 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull %1)
  %74 = icmp eq i32 %73, 1
  br i1 %74, label %.preheader, label %._crit_edge38, !llvm.loop !20

.lr.ph36:                                         ; preds = %.lr.ph36.preheader64, %.lr.ph36
  %indvars.iv55 = phi i64 [ %indvars.iv.next56, %.lr.ph36 ], [ %indvars.iv55.ph, %.lr.ph36.preheader64 ]
  %.02034 = phi i64 [ %77, %.lr.ph36 ], [ %.02034.ph, %.lr.ph36.preheader64 ]
  %75 = getelementptr inbounds [30001 x i64], ptr @g, i64 0, i64 %indvars.iv55
  %76 = load i64, ptr %75, align 8, !tbaa !11
  %77 = add nsw i64 %76, %.02034
  %indvars.iv.next56 = add nuw nsw i64 %indvars.iv55, 1
  %exitcond59.not = icmp eq i64 %indvars.iv.next56, %wide.trip.count58
  br i1 %exitcond59.not, label %._crit_edge37, label %.lr.ph36, !llvm.loop !21
}

; Function Attrs: mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.start.p0(i64 immarg, ptr nocapture) #1

; Function Attrs: mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.end.p0(i64 immarg, ptr nocapture) #1

; Function Attrs: nofree nounwind
declare noundef i32 @__isoc99_scanf(ptr nocapture noundef readonly, ...) local_unnamed_addr #2

; Function Attrs: nofree nounwind
declare noundef i32 @printf(ptr nocapture noundef readonly, ...) local_unnamed_addr #2

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i64 @llvm.vector.reduce.add.v2i64(<2 x i64>) #3

attributes #0 = { mustprogress nofree norecurse nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { nofree nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #4 = { nounwind }

!llvm.module.flags = !{!0, !1, !2, !3}
!llvm.ident = !{!4}

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"int", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = distinct !{!9, !10}
!10 = !{!"llvm.loop.mustprogress"}
!11 = !{!12, !12, i64 0}
!12 = !{!"long long", !7, i64 0}
!13 = distinct !{!13, !14}
!14 = !{!"llvm.loop.unroll.disable"}
!15 = distinct !{!15, !10}
!16 = distinct !{!16, !10}
!17 = distinct !{!17, !10, !18, !19}
!18 = !{!"llvm.loop.isvectorized", i32 1}
!19 = !{!"llvm.loop.unroll.runtime.disable"}
!20 = distinct !{!20, !10}
!21 = distinct !{!21, !10, !19, !18}


; Effective O3 passes: BDCEPass,GVNPass,GlobalOptPass,IndVarSimplifyPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,JumpThreadingPass,LCSSAPass,LICMPass,LoopLoadEliminationPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,LoopVectorizePass,PostOrderFunctionAttrsPass,ReassociatePass,SCCPPass,SROAPass,SimplifyCFGPass