; LLVM IR from Izaron/ACM-ICPC :: Timus Online Judge/Volume 10/1931. Excellent Team (main)

; 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"

%"class.std::basic_istream" = type { ptr, i64, %"class.std::basic_ios" }
%"class.std::basic_ios" = type { %"class.std::ios_base", ptr, i8, i8, ptr, ptr, ptr, ptr }
%"class.std::ios_base" = type { ptr, i64, i64, i32, i32, i32, ptr, %"struct.std::ios_base::_Words", [8 x %"struct.std::ios_base::_Words"], i32, ptr, %"class.std::locale" }
%"struct.std::ios_base::_Words" = type { ptr, i64 }
%"class.std::locale" = type { ptr }
%"class.std::basic_ostream" = type { ptr, %"class.std::basic_ios" }

@_ZSt3cin = external global %"class.std::basic_istream", align 8
@_ZSt4cout = external global %"class.std::basic_ostream", align 8

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() #0 {
  %1 = alloca i32, align 4
  %2 = alloca i32, align 4
  %3 = alloca [100005 x i64], align 16
  %4 = alloca [100005 x i32], align 16
  %5 = alloca i32, align 4
  %6 = alloca i32, align 4
  %7 = alloca i32, align 4
  %8 = alloca i32, align 4
  %9 = alloca i32, align 4
  store i32 0, ptr %1, align 4
  call void @llvm.lifetime.start.p0(i64 4, ptr %2) #5
  %10 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERi(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 4 dereferenceable(4) %2)
  call void @llvm.lifetime.start.p0(i64 800040, ptr %3) #5
  call void @llvm.lifetime.start.p0(i64 400020, ptr %4) #5
  %11 = getelementptr inbounds [100005 x i32], ptr %4, i64 0, i64 0
  call void @llvm.memset.p0.i64(ptr align 16 %11, i8 0, i64 400020, i1 false)
  call void @llvm.lifetime.start.p0(i64 4, ptr %5) #5
  store i32 0, ptr %5, align 4, !tbaa !5
  br label %12

12:                                               ; preds = %22, %0
  %13 = load i32, ptr %5, align 4, !tbaa !5
  %14 = load i32, ptr %2, align 4, !tbaa !5
  %15 = icmp slt i32 %13, %14
  br i1 %15, label %17, label %16

16:                                               ; preds = %12
  call void @llvm.lifetime.end.p0(i64 4, ptr %5) #5
  br label %25

17:                                               ; preds = %12
  %18 = load i32, ptr %5, align 4, !tbaa !5
  %19 = sext i32 %18 to i64
  %20 = getelementptr inbounds [100005 x i64], ptr %3, i64 0, i64 %19
  %21 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 8 dereferenceable(8) %20)
  br label %22

22:                                               ; preds = %17
  %23 = load i32, ptr %5, align 4, !tbaa !5
  %24 = add nsw i32 %23, 1
  store i32 %24, ptr %5, align 4, !tbaa !5
  br label %12, !llvm.loop !9

25:                                               ; preds = %16
  call void @llvm.lifetime.start.p0(i64 4, ptr %6) #5
  store i32 0, ptr %6, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #5
  store i32 1, ptr %7, align 4, !tbaa !5
  br label %26

26:                                               ; preds = %54, %25
  %27 = load i32, ptr %7, align 4, !tbaa !5
  %28 = load i32, ptr %2, align 4, !tbaa !5
  %29 = icmp slt i32 %27, %28
  br i1 %29, label %31, label %30

30:                                               ; preds = %26
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #5
  br label %57

31:                                               ; preds = %26
  %32 = load i32, ptr %6, align 4, !tbaa !5
  %33 = sext i32 %32 to i64
  %34 = getelementptr inbounds [100005 x i32], ptr %4, i64 0, i64 %33
  %35 = load i32, ptr %34, align 4, !tbaa !5
  %36 = add nsw i32 %35, 1
  store i32 %36, ptr %34, align 4, !tbaa !5
  %37 = load i32, ptr %7, align 4, !tbaa !5
  %38 = sext i32 %37 to i64
  %39 = getelementptr inbounds [100005 x i32], ptr %4, i64 0, i64 %38
  %40 = load i32, ptr %39, align 4, !tbaa !5
  %41 = add nsw i32 %40, 1
  store i32 %41, ptr %39, align 4, !tbaa !5
  %42 = load i32, ptr %6, align 4, !tbaa !5
  %43 = sext i32 %42 to i64
  %44 = getelementptr inbounds [100005 x i64], ptr %3, i64 0, i64 %43
  %45 = load i64, ptr %44, align 8, !tbaa !11
  %46 = load i32, ptr %7, align 4, !tbaa !5
  %47 = sext i32 %46 to i64
  %48 = getelementptr inbounds [100005 x i64], ptr %3, i64 0, i64 %47
  %49 = load i64, ptr %48, align 8, !tbaa !11
  %50 = icmp sgt i64 %45, %49
  br i1 %50, label %51, label %53

51:                                               ; preds = %31
  %52 = load i32, ptr %7, align 4, !tbaa !5
  store i32 %52, ptr %6, align 4, !tbaa !5
  br label %53

53:                                               ; preds = %51, %31
  br label %54

54:                                               ; preds = %53
  %55 = load i32, ptr %7, align 4, !tbaa !5
  %56 = add nsw i32 %55, 1
  store i32 %56, ptr %7, align 4, !tbaa !5
  br label %26, !llvm.loop !13

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

58:                                               ; preds = %76, %57
  %59 = load i32, ptr %9, align 4, !tbaa !5
  %60 = load i32, ptr %2, align 4, !tbaa !5
  %61 = icmp slt i32 %59, %60
  br i1 %61, label %63, label %62

62:                                               ; preds = %58
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #5
  br label %79

63:                                               ; preds = %58
  %64 = load i32, ptr %9, align 4, !tbaa !5
  %65 = sext i32 %64 to i64
  %66 = getelementptr inbounds [100005 x i32], ptr %4, i64 0, i64 %65
  %67 = load i32, ptr %66, align 4, !tbaa !5
  %68 = load i32, ptr %8, align 4, !tbaa !5
  %69 = sext i32 %68 to i64
  %70 = getelementptr inbounds [100005 x i32], ptr %4, i64 0, i64 %69
  %71 = load i32, ptr %70, align 4, !tbaa !5
  %72 = icmp sgt i32 %67, %71
  br i1 %72, label %73, label %75

73:                                               ; preds = %63
  %74 = load i32, ptr %9, align 4, !tbaa !5
  store i32 %74, ptr %8, align 4, !tbaa !5
  br label %75

75:                                               ; preds = %73, %63
  br label %76

76:                                               ; preds = %75
  %77 = load i32, ptr %9, align 4, !tbaa !5
  %78 = add nsw i32 %77, 1
  store i32 %78, ptr %9, align 4, !tbaa !5
  br label %58, !llvm.loop !14

79:                                               ; preds = %62
  %80 = load i32, ptr %8, align 4, !tbaa !5
  %81 = add nsw i32 %80, 1
  %82 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, i32 noundef %81)
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %6) #5
  call void @llvm.lifetime.end.p0(i64 400020, ptr %4) #5
  call void @llvm.lifetime.end.p0(i64 800040, ptr %3) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %2) #5
  %83 = load i32, ptr %1, align 4
  ret i32 %83
}

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

declare noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERi(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 4 dereferenceable(4)) #2

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: write)
declare void @llvm.memset.p0.i64(ptr nocapture writeonly, i8, i64, i1 immarg) #3

; Function Attrs: mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 8 dereferenceable(8)) #4 align 2

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

declare noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8), i32 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 = { nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #4 = { mustprogress 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 #5 = { 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}


; 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"

%"class.std::basic_istream" = type { ptr, i64, %"class.std::basic_ios" }
%"class.std::basic_ios" = type { %"class.std::ios_base", ptr, i8, i8, ptr, ptr, ptr, ptr }
%"class.std::ios_base" = type { ptr, i64, i64, i32, i32, i32, ptr, %"struct.std::ios_base::_Words", [8 x %"struct.std::ios_base::_Words"], i32, ptr, %"class.std::locale" }
%"struct.std::ios_base::_Words" = type { ptr, i64 }
%"class.std::locale" = type { ptr }
%"class.std::basic_ostream" = type { ptr, %"class.std::basic_ios" }

@_ZSt3cin = external global %"class.std::basic_istream", align 8
@_ZSt4cout = external global %"class.std::basic_ostream", align 8

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() local_unnamed_addr #0 {
  %1 = alloca i32, align 4
  %2 = alloca [100005 x i64], align 16
  %3 = alloca [100005 x i32], align 16
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %1) #5
  %4 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERi(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 4 dereferenceable(4) %1)
  call void @llvm.lifetime.start.p0(i64 800040, ptr nonnull %2) #5
  call void @llvm.lifetime.start.p0(i64 400020, ptr nonnull %3) #5
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 16 dereferenceable(400020) %3, i8 0, i64 400020, i1 false)
  %5 = load i32, ptr %1, align 4, !tbaa !5
  %6 = icmp sgt i32 %5, 0
  br i1 %6, label %.lr.ph, label %._crit_edge

.preheader23:                                     ; preds = %.lr.ph
  %7 = icmp sgt i32 %10, 1
  br i1 %7, label %.lr.ph27.preheader, label %._crit_edge

.lr.ph27.preheader:                               ; preds = %.preheader23
  %wide.trip.count = zext nneg i32 %10 to i64
  br label %.lr.ph27

.lr.ph:                                           ; preds = %0, %.lr.ph
  %indvars.iv = phi i64 [ %indvars.iv.next, %.lr.ph ], [ 0, %0 ]
  %8 = getelementptr inbounds [100005 x i64], ptr %2, i64 0, i64 %indvars.iv
  %9 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 8 dereferenceable(8) %8)
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %10 = load i32, ptr %1, align 4, !tbaa !5
  %11 = sext i32 %10 to i64
  %12 = icmp slt i64 %indvars.iv.next, %11
  br i1 %12, label %.lr.ph, label %.preheader23, !llvm.loop !9

.preheader:                                       ; preds = %.lr.ph27
  br i1 %7, label %.lr.ph30.preheader, label %._crit_edge

.lr.ph30.preheader:                               ; preds = %.preheader
  %wide.trip.count40 = zext nneg i32 %10 to i64
  %13 = add nsw i64 %wide.trip.count40, -1
  %14 = add nsw i64 %wide.trip.count40, -2
  %xtraiter = and i64 %13, 3
  %15 = icmp ult i64 %14, 3
  br i1 %15, label %._crit_edge.loopexit.unr-lcssa, label %.lr.ph30.preheader.new

.lr.ph30.preheader.new:                           ; preds = %.lr.ph30.preheader
  %unroll_iter = and i64 %13, -4
  br label %.lr.ph30

.lr.ph27:                                         ; preds = %.lr.ph27.preheader, %.lr.ph27
  %indvars.iv34 = phi i64 [ 1, %.lr.ph27.preheader ], [ %indvars.iv.next35, %.lr.ph27 ]
  %.01925 = phi i32 [ 0, %.lr.ph27.preheader ], [ %spec.select, %.lr.ph27 ]
  %16 = sext i32 %.01925 to i64
  %17 = getelementptr inbounds [100005 x i32], ptr %3, i64 0, i64 %16
  %18 = load i32, ptr %17, align 4, !tbaa !5
  %19 = add nsw i32 %18, 1
  store i32 %19, ptr %17, align 4, !tbaa !5
  %20 = getelementptr inbounds [100005 x i32], ptr %3, i64 0, i64 %indvars.iv34
  %21 = load i32, ptr %20, align 4, !tbaa !5
  %22 = add nsw i32 %21, 1
  store i32 %22, ptr %20, align 4, !tbaa !5
  %23 = getelementptr inbounds [100005 x i64], ptr %2, i64 0, i64 %16
  %24 = load i64, ptr %23, align 8, !tbaa !11
  %25 = getelementptr inbounds [100005 x i64], ptr %2, i64 0, i64 %indvars.iv34
  %26 = load i64, ptr %25, align 8, !tbaa !11
  %27 = icmp sgt i64 %24, %26
  %28 = trunc nuw nsw i64 %indvars.iv34 to i32
  %spec.select = select i1 %27, i32 %28, i32 %.01925
  %indvars.iv.next35 = add nuw nsw i64 %indvars.iv34, 1
  %exitcond.not = icmp eq i64 %indvars.iv.next35, %wide.trip.count
  br i1 %exitcond.not, label %.preheader, label %.lr.ph27, !llvm.loop !13

._crit_edge.loopexit.unr-lcssa:                   ; preds = %.lr.ph30, %.lr.ph30.preheader
  %spec.select22.lcssa.ph = phi i32 [ poison, %.lr.ph30.preheader ], [ %spec.select22.3, %.lr.ph30 ]
  %indvars.iv37.unr = phi i64 [ 1, %.lr.ph30.preheader ], [ %indvars.iv.next38.3, %.lr.ph30 ]
  %.01728.unr = phi i32 [ 0, %.lr.ph30.preheader ], [ %spec.select22.3, %.lr.ph30 ]
  %lcmp.mod.not = icmp eq i64 %xtraiter, 0
  br i1 %lcmp.mod.not, label %._crit_edge.loopexit, label %.lr.ph30.epil

.lr.ph30.epil:                                    ; preds = %._crit_edge.loopexit.unr-lcssa, %.lr.ph30.epil
  %indvars.iv37.epil = phi i64 [ %indvars.iv.next38.epil, %.lr.ph30.epil ], [ %indvars.iv37.unr, %._crit_edge.loopexit.unr-lcssa ]
  %.01728.epil = phi i32 [ %spec.select22.epil, %.lr.ph30.epil ], [ %.01728.unr, %._crit_edge.loopexit.unr-lcssa ]
  %epil.iter = phi i64 [ %epil.iter.next, %.lr.ph30.epil ], [ 0, %._crit_edge.loopexit.unr-lcssa ]
  %29 = getelementptr inbounds [100005 x i32], ptr %3, i64 0, i64 %indvars.iv37.epil
  %30 = load i32, ptr %29, align 4, !tbaa !5
  %31 = sext i32 %.01728.epil to i64
  %32 = getelementptr inbounds [100005 x i32], ptr %3, i64 0, i64 %31
  %33 = load i32, ptr %32, align 4, !tbaa !5
  %34 = icmp sgt i32 %30, %33
  %35 = trunc nuw nsw i64 %indvars.iv37.epil to i32
  %spec.select22.epil = select i1 %34, i32 %35, i32 %.01728.epil
  %indvars.iv.next38.epil = add nuw nsw i64 %indvars.iv37.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.loopexit, label %.lr.ph30.epil, !llvm.loop !14

._crit_edge.loopexit:                             ; preds = %.lr.ph30.epil, %._crit_edge.loopexit.unr-lcssa
  %spec.select22.lcssa = phi i32 [ %spec.select22.lcssa.ph, %._crit_edge.loopexit.unr-lcssa ], [ %spec.select22.epil, %.lr.ph30.epil ]
  %36 = add nsw i32 %spec.select22.lcssa, 1
  br label %._crit_edge

._crit_edge:                                      ; preds = %0, %.preheader23, %._crit_edge.loopexit, %.preheader
  %.017.lcssa = phi i32 [ 1, %.preheader ], [ %36, %._crit_edge.loopexit ], [ 1, %.preheader23 ], [ 1, %0 ]
  %37 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, i32 noundef %.017.lcssa)
  call void @llvm.lifetime.end.p0(i64 400020, ptr nonnull %3) #5
  call void @llvm.lifetime.end.p0(i64 800040, ptr nonnull %2) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %1) #5
  ret i32 0

.lr.ph30:                                         ; preds = %.lr.ph30, %.lr.ph30.preheader.new
  %indvars.iv37 = phi i64 [ 1, %.lr.ph30.preheader.new ], [ %indvars.iv.next38.3, %.lr.ph30 ]
  %.01728 = phi i32 [ 0, %.lr.ph30.preheader.new ], [ %spec.select22.3, %.lr.ph30 ]
  %niter = phi i64 [ 0, %.lr.ph30.preheader.new ], [ %niter.next.3, %.lr.ph30 ]
  %38 = getelementptr inbounds [100005 x i32], ptr %3, i64 0, i64 %indvars.iv37
  %39 = load i32, ptr %38, align 4, !tbaa !5
  %40 = sext i32 %.01728 to i64
  %41 = getelementptr inbounds [100005 x i32], ptr %3, i64 0, i64 %40
  %42 = load i32, ptr %41, align 4, !tbaa !5
  %43 = icmp sgt i32 %39, %42
  %44 = trunc nuw nsw i64 %indvars.iv37 to i32
  %spec.select22 = select i1 %43, i32 %44, i32 %.01728
  %indvars.iv.next38 = add nuw nsw i64 %indvars.iv37, 1
  %45 = getelementptr inbounds [100005 x i32], ptr %3, i64 0, i64 %indvars.iv.next38
  %46 = load i32, ptr %45, align 4, !tbaa !5
  %47 = sext i32 %spec.select22 to i64
  %48 = getelementptr inbounds [100005 x i32], ptr %3, i64 0, i64 %47
  %49 = load i32, ptr %48, align 4, !tbaa !5
  %50 = icmp sgt i32 %46, %49
  %51 = trunc nuw nsw i64 %indvars.iv.next38 to i32
  %spec.select22.1 = select i1 %50, i32 %51, i32 %spec.select22
  %indvars.iv.next38.1 = add nuw nsw i64 %indvars.iv37, 2
  %52 = getelementptr inbounds [100005 x i32], ptr %3, i64 0, i64 %indvars.iv.next38.1
  %53 = load i32, ptr %52, align 4, !tbaa !5
  %54 = sext i32 %spec.select22.1 to i64
  %55 = getelementptr inbounds [100005 x i32], ptr %3, i64 0, i64 %54
  %56 = load i32, ptr %55, align 4, !tbaa !5
  %57 = icmp sgt i32 %53, %56
  %58 = trunc nuw nsw i64 %indvars.iv.next38.1 to i32
  %spec.select22.2 = select i1 %57, i32 %58, i32 %spec.select22.1
  %indvars.iv.next38.2 = add nuw nsw i64 %indvars.iv37, 3
  %59 = getelementptr inbounds [100005 x i32], ptr %3, i64 0, i64 %indvars.iv.next38.2
  %60 = load i32, ptr %59, align 4, !tbaa !5
  %61 = sext i32 %spec.select22.2 to i64
  %62 = getelementptr inbounds [100005 x i32], ptr %3, i64 0, i64 %61
  %63 = load i32, ptr %62, align 4, !tbaa !5
  %64 = icmp sgt i32 %60, %63
  %65 = trunc nuw nsw i64 %indvars.iv.next38.2 to i32
  %spec.select22.3 = select i1 %64, i32 %65, i32 %spec.select22.2
  %indvars.iv.next38.3 = add nuw nsw i64 %indvars.iv37, 4
  %niter.next.3 = add nuw i64 %niter, 4
  %niter.ncmp.3 = icmp eq i64 %niter.next.3, %unroll_iter
  br i1 %niter.ncmp.3, label %._crit_edge.loopexit.unr-lcssa, label %.lr.ph30, !llvm.loop !16
}

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

declare noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERi(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 4 dereferenceable(4)) local_unnamed_addr #2

; Function Attrs: mustprogress nocallback nofree nounwind willreturn memory(argmem: write)
declare void @llvm.memset.p0.i64(ptr nocapture writeonly, i8, i64, i1 immarg) #3

; Function Attrs: mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #4 align 2

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

declare noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8), i32 noundef) local_unnamed_addr #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 = { mustprogress 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 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #4 = { mustprogress 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 #5 = { 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, !15}
!15 = !{!"llvm.loop.unroll.disable"}
!16 = distinct !{!16, !10}


; Effective O3 passes: CorrelatedValuePropagationPass,EarlyCSEPass,GVNPass,GlobalOptPass,IndVarSimplifyPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,JumpThreadingPass,LCSSAPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,SROAPass,SimplifyCFGPass