; LLVM IR from hanzohasashi33/Competetive_programming :: CodeChef/beginner (cops_and_thief_devu)

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

@.str = external hidden unnamed_addr constant [3 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [7 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [4 x i8], align 1

; Function Attrs: nounwind uwtable
define dso_local 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 [100 x i32], align 16
  %7 = alloca i32, align 4
  %8 = alloca ptr, align 8
  %9 = alloca i64, align 8
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  %13 = alloca i32, align 4
  %14 = alloca i32, align 4
  %15 = alloca i32, align 4
  %16 = alloca i32, align 4
  store i32 0, ptr %1, align 4
  call void @llvm.lifetime.start.p0(i64 4, ptr %2) #4
  %17 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef %2)
  br label %18

18:                                               ; preds = %106, %0
  %19 = load i32, ptr %2, align 4, !tbaa !5
  %20 = icmp sgt i32 %19, 0
  br i1 %20, label %21, label %112

21:                                               ; preds = %18
  call void @llvm.lifetime.start.p0(i64 4, ptr %3) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr %4) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr %5) #4
  call void @llvm.lifetime.start.p0(i64 400, ptr %6) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #4
  store i32 0, ptr %7, align 4, !tbaa !5
  br label %22

22:                                               ; preds = %30, %21
  %23 = load i32, ptr %7, align 4, !tbaa !5
  %24 = icmp slt i32 %23, 100
  br i1 %24, label %26, label %25

25:                                               ; preds = %22
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #4
  br label %33

26:                                               ; preds = %22
  %27 = load i32, ptr %7, align 4, !tbaa !5
  %28 = sext i32 %27 to i64
  %29 = getelementptr inbounds [100 x i32], ptr %6, i64 0, i64 %28
  store i32 1, ptr %29, align 4, !tbaa !5
  br label %30

30:                                               ; preds = %26
  %31 = load i32, ptr %7, align 4, !tbaa !5
  %32 = add nsw i32 %31, 1
  store i32 %32, ptr %7, align 4, !tbaa !5
  br label %22, !llvm.loop !9

33:                                               ; preds = %25
  %34 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str.1, ptr noundef %3, ptr noundef %4, ptr noundef %5)
  %35 = load i32, ptr %3, align 4, !tbaa !5
  %36 = zext i32 %35 to i64
  %37 = call ptr @llvm.stacksave.p0()
  store ptr %37, ptr %8, align 8
  %38 = alloca i32, i64 %36, align 16
  store i64 %36, ptr %9, align 8
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #4
  store i32 0, ptr %10, align 4, !tbaa !5
  br label %39

39:                                               ; preds = %88, %33
  %40 = load i32, ptr %10, align 4, !tbaa !5
  %41 = load i32, ptr %3, align 4, !tbaa !5
  %42 = icmp slt i32 %40, %41
  br i1 %42, label %44, label %43

43:                                               ; preds = %39
  store i32 7, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #4
  br label %91

44:                                               ; preds = %39
  %45 = load i32, ptr %10, align 4, !tbaa !5
  %46 = sext i32 %45 to i64
  %47 = getelementptr inbounds i32, ptr %38, i64 %46
  %48 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef %47)
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #4
  %49 = load i32, ptr %10, align 4, !tbaa !5
  %50 = sext i32 %49 to i64
  %51 = getelementptr inbounds i32, ptr %38, i64 %50
  %52 = load i32, ptr %51, align 4, !tbaa !5
  %53 = load i32, ptr %4, align 4, !tbaa !5
  %54 = load i32, ptr %5, align 4, !tbaa !5
  %55 = mul nsw i32 %53, %54
  %56 = sub nsw i32 %52, %55
  store i32 %56, ptr %12, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #4
  %57 = load i32, ptr %10, align 4, !tbaa !5
  %58 = sext i32 %57 to i64
  %59 = getelementptr inbounds i32, ptr %38, i64 %58
  %60 = load i32, ptr %59, align 4, !tbaa !5
  %61 = load i32, ptr %4, align 4, !tbaa !5
  %62 = load i32, ptr %5, align 4, !tbaa !5
  %63 = mul nsw i32 %61, %62
  %64 = add nsw i32 %60, %63
  store i32 %64, ptr %13, align 4, !tbaa !5
  %65 = load i32, ptr %12, align 4, !tbaa !5
  %66 = icmp slt i32 %65, 1
  br i1 %66, label %67, label %68

67:                                               ; preds = %44
  store i32 1, ptr %12, align 4, !tbaa !5
  br label %68

68:                                               ; preds = %67, %44
  %69 = load i32, ptr %13, align 4, !tbaa !5
  %70 = icmp sgt i32 %69, 100
  br i1 %70, label %71, label %72

71:                                               ; preds = %68
  store i32 100, ptr %13, align 4, !tbaa !5
  br label %72

72:                                               ; preds = %71, %68
  call void @llvm.lifetime.start.p0(i64 4, ptr %14) #4
  %73 = load i32, ptr %12, align 4, !tbaa !5
  %74 = sub nsw i32 %73, 1
  store i32 %74, ptr %14, align 4, !tbaa !5
  br label %75

75:                                               ; preds = %84, %72
  %76 = load i32, ptr %14, align 4, !tbaa !5
  %77 = load i32, ptr %13, align 4, !tbaa !5
  %78 = icmp slt i32 %76, %77
  br i1 %78, label %80, label %79

79:                                               ; preds = %75
  store i32 10, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #4
  br label %87

80:                                               ; preds = %75
  %81 = load i32, ptr %14, align 4, !tbaa !5
  %82 = sext i32 %81 to i64
  %83 = getelementptr inbounds [100 x i32], ptr %6, i64 0, i64 %82
  store i32 0, ptr %83, align 4, !tbaa !5
  br label %84

84:                                               ; preds = %80
  %85 = load i32, ptr %14, align 4, !tbaa !5
  %86 = add nsw i32 %85, 1
  store i32 %86, ptr %14, align 4, !tbaa !5
  br label %75, !llvm.loop !11

87:                                               ; preds = %79
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #4
  br label %88

88:                                               ; preds = %87
  %89 = load i32, ptr %10, align 4, !tbaa !5
  %90 = add nsw i32 %89, 1
  store i32 %90, ptr %10, align 4, !tbaa !5
  br label %39, !llvm.loop !12

91:                                               ; preds = %43
  call void @llvm.lifetime.start.p0(i64 4, ptr %15) #4
  store i32 0, ptr %15, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %16) #4
  store i32 0, ptr %16, align 4, !tbaa !5
  br label %92

92:                                               ; preds = %103, %91
  %93 = load i32, ptr %16, align 4, !tbaa !5
  %94 = icmp slt i32 %93, 100
  br i1 %94, label %96, label %95

95:                                               ; preds = %92
  store i32 13, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #4
  br label %106

96:                                               ; preds = %92
  %97 = load i32, ptr %16, align 4, !tbaa !5
  %98 = sext i32 %97 to i64
  %99 = getelementptr inbounds [100 x i32], ptr %6, i64 0, i64 %98
  %100 = load i32, ptr %99, align 4, !tbaa !5
  %101 = load i32, ptr %15, align 4, !tbaa !5
  %102 = add nsw i32 %101, %100
  store i32 %102, ptr %15, align 4, !tbaa !5
  br label %103

103:                                              ; preds = %96
  %104 = load i32, ptr %16, align 4, !tbaa !5
  %105 = add nsw i32 %104, 1
  store i32 %105, ptr %16, align 4, !tbaa !5
  br label %92, !llvm.loop !13

106:                                              ; preds = %95
  %107 = load i32, ptr %15, align 4, !tbaa !5
  %108 = call i32 (ptr, ...) @printf(ptr noundef @.str.2, i32 noundef %107)
  %109 = load i32, ptr %2, align 4, !tbaa !5
  %110 = add nsw i32 %109, -1
  store i32 %110, ptr %2, align 4, !tbaa !5
  call void @llvm.lifetime.end.p0(i64 4, ptr %15) #4
  %111 = load ptr, ptr %8, align 8
  call void @llvm.stackrestore.p0(ptr %111)
  call void @llvm.lifetime.end.p0(i64 400, ptr %6) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %5) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %4) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %3) #4
  br label %18, !llvm.loop !14

112:                                              ; preds = %18
  store i32 0, ptr %1, align 4
  store i32 1, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %2) #4
  %113 = load i32, ptr %1, align 4
  ret i32 %113
}

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

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

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

; Function Attrs: nocallback nofree nosync nounwind willreturn
declare ptr @llvm.stacksave.p0() #3

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

; Function Attrs: nocallback nofree nosync nounwind willreturn
declare void @llvm.stackrestore.p0(ptr) #3

attributes #0 = { 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 = { 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 nosync nounwind willreturn }
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/C++ TBAA"}
!9 = distinct !{!9, !10}
!10 = !{!"llvm.loop.mustprogress"}
!11 = distinct !{!11, !10}
!12 = distinct !{!12, !10}
!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"

@.str = external hidden unnamed_addr constant [3 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [7 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [4 x i8], align 1

; Function Attrs: nofree nounwind uwtable
define dso_local noundef i32 @main() local_unnamed_addr #0 {
  %1 = alloca i32, align 4
  %2 = alloca i32, align 4
  %3 = alloca i32, align 4
  %4 = alloca i32, align 4
  %5 = alloca [100 x i32], align 16
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %1) #6
  %6 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull %1)
  %7 = load i32, ptr %1, align 4, !tbaa !5
  %8 = icmp sgt i32 %7, 0
  br i1 %8, label %.lr.ph34.preheader, label %._crit_edge35

.lr.ph34.preheader:                               ; preds = %0
  %scevgep = getelementptr i8, ptr %5, i64 -4
  %9 = getelementptr inbounds i8, ptr %5, i64 384
  %10 = getelementptr inbounds i8, ptr %5, i64 368
  %11 = getelementptr inbounds i8, ptr %5, i64 16
  %12 = getelementptr inbounds i8, ptr %5, i64 32
  %13 = getelementptr inbounds i8, ptr %5, i64 48
  %14 = getelementptr inbounds i8, ptr %5, i64 64
  %15 = getelementptr inbounds i8, ptr %5, i64 80
  %16 = getelementptr inbounds i8, ptr %5, i64 96
  %17 = getelementptr inbounds i8, ptr %5, i64 112
  %18 = getelementptr inbounds i8, ptr %5, i64 128
  %19 = getelementptr inbounds i8, ptr %5, i64 144
  %20 = getelementptr inbounds i8, ptr %5, i64 160
  %21 = getelementptr inbounds i8, ptr %5, i64 176
  %22 = getelementptr inbounds i8, ptr %5, i64 192
  %23 = getelementptr inbounds i8, ptr %5, i64 208
  %24 = getelementptr inbounds i8, ptr %5, i64 224
  %25 = getelementptr inbounds i8, ptr %5, i64 240
  %26 = getelementptr inbounds i8, ptr %5, i64 256
  %27 = getelementptr inbounds i8, ptr %5, i64 272
  %28 = getelementptr inbounds i8, ptr %5, i64 288
  %29 = getelementptr inbounds i8, ptr %5, i64 304
  %30 = getelementptr inbounds i8, ptr %5, i64 320
  %31 = getelementptr inbounds i8, ptr %5, i64 336
  %32 = getelementptr inbounds i8, ptr %5, i64 352
  %33 = getelementptr inbounds i8, ptr %5, i64 368
  %34 = getelementptr inbounds i8, ptr %5, i64 384
  %35 = getelementptr inbounds i8, ptr %5, i64 388
  %36 = getelementptr inbounds i8, ptr %5, i64 392
  %37 = getelementptr inbounds i8, ptr %5, i64 396
  %38 = getelementptr inbounds i8, ptr %5, i64 336
  %39 = getelementptr inbounds i8, ptr %5, i64 304
  %40 = getelementptr inbounds i8, ptr %5, i64 272
  %41 = getelementptr inbounds i8, ptr %5, i64 240
  %42 = getelementptr inbounds i8, ptr %5, i64 208
  %43 = getelementptr inbounds i8, ptr %5, i64 176
  %44 = getelementptr inbounds i8, ptr %5, i64 144
  %45 = getelementptr inbounds i8, ptr %5, i64 112
  %46 = getelementptr inbounds i8, ptr %5, i64 80
  %47 = getelementptr inbounds i8, ptr %5, i64 48
  %48 = getelementptr inbounds i8, ptr %5, i64 16
  %49 = getelementptr inbounds i8, ptr %5, i64 352
  %50 = getelementptr inbounds i8, ptr %5, i64 320
  %51 = getelementptr inbounds i8, ptr %5, i64 288
  %52 = getelementptr inbounds i8, ptr %5, i64 256
  %53 = getelementptr inbounds i8, ptr %5, i64 224
  %54 = getelementptr inbounds i8, ptr %5, i64 192
  %55 = getelementptr inbounds i8, ptr %5, i64 160
  %56 = getelementptr inbounds i8, ptr %5, i64 128
  %57 = getelementptr inbounds i8, ptr %5, i64 96
  %58 = getelementptr inbounds i8, ptr %5, i64 64
  %59 = getelementptr inbounds i8, ptr %5, i64 32
  %60 = getelementptr inbounds i8, ptr %5, i64 388
  %61 = getelementptr inbounds i8, ptr %5, i64 392
  %62 = getelementptr inbounds i8, ptr %5, i64 396
  br label %.lr.ph34

.lr.ph34:                                         ; preds = %.lr.ph34.preheader, %.loopexit
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %2) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %3) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %4) #6
  call void @llvm.lifetime.start.p0(i64 400, ptr nonnull %5) #6
  store <4 x i32> <i32 1, i32 1, i32 1, i32 1>, ptr %5, align 16, !tbaa !5
  store <4 x i32> <i32 1, i32 1, i32 1, i32 1>, ptr %11, align 16, !tbaa !5
  store <4 x i32> <i32 1, i32 1, i32 1, i32 1>, ptr %12, align 16, !tbaa !5
  store <4 x i32> <i32 1, i32 1, i32 1, i32 1>, ptr %13, align 16, !tbaa !5
  store <4 x i32> <i32 1, i32 1, i32 1, i32 1>, ptr %14, align 16, !tbaa !5
  store <4 x i32> <i32 1, i32 1, i32 1, i32 1>, ptr %15, align 16, !tbaa !5
  store <4 x i32> <i32 1, i32 1, i32 1, i32 1>, ptr %16, align 16, !tbaa !5
  store <4 x i32> <i32 1, i32 1, i32 1, i32 1>, ptr %17, align 16, !tbaa !5
  store <4 x i32> <i32 1, i32 1, i32 1, i32 1>, ptr %18, align 16, !tbaa !5
  store <4 x i32> <i32 1, i32 1, i32 1, i32 1>, ptr %19, align 16, !tbaa !5
  store <4 x i32> <i32 1, i32 1, i32 1, i32 1>, ptr %20, align 16, !tbaa !5
  store <4 x i32> <i32 1, i32 1, i32 1, i32 1>, ptr %21, align 16, !tbaa !5
  store <4 x i32> <i32 1, i32 1, i32 1, i32 1>, ptr %22, align 16, !tbaa !5
  store <4 x i32> <i32 1, i32 1, i32 1, i32 1>, ptr %23, align 16, !tbaa !5
  store <4 x i32> <i32 1, i32 1, i32 1, i32 1>, ptr %24, align 16, !tbaa !5
  store <4 x i32> <i32 1, i32 1, i32 1, i32 1>, ptr %25, align 16, !tbaa !5
  store <4 x i32> <i32 1, i32 1, i32 1, i32 1>, ptr %26, align 16, !tbaa !5
  store <4 x i32> <i32 1, i32 1, i32 1, i32 1>, ptr %27, align 16, !tbaa !5
  store <4 x i32> <i32 1, i32 1, i32 1, i32 1>, ptr %28, align 16, !tbaa !5
  store <4 x i32> <i32 1, i32 1, i32 1, i32 1>, ptr %29, align 16, !tbaa !5
  store <4 x i32> <i32 1, i32 1, i32 1, i32 1>, ptr %30, align 16, !tbaa !5
  store <4 x i32> <i32 1, i32 1, i32 1, i32 1>, ptr %31, align 16, !tbaa !5
  store <4 x i32> <i32 1, i32 1, i32 1, i32 1>, ptr %32, align 16, !tbaa !5
  store <4 x i32> <i32 1, i32 1, i32 1, i32 1>, ptr %33, align 16, !tbaa !5
  store i32 1, ptr %34, align 16, !tbaa !5
  store i32 1, ptr %35, align 4, !tbaa !5
  store i32 1, ptr %36, align 8, !tbaa !5
  store i32 1, ptr %37, align 4, !tbaa !5
  %63 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str.1, ptr noundef nonnull %2, ptr noundef nonnull %3, ptr noundef nonnull %4)
  %64 = load i32, ptr %2, align 4, !tbaa !5
  %65 = zext i32 %64 to i64
  %66 = call ptr @llvm.stacksave.p0()
  %67 = alloca i32, i64 %65, align 16
  %68 = load i32, ptr %2, align 4, !tbaa !5
  %69 = icmp sgt i32 %68, 0
  br i1 %69, label %.lr.ph30, label %.loopexit

.lr.ph30:                                         ; preds = %.lr.ph34, %._crit_edge
  %indvars.iv42 = phi i64 [ %indvars.iv.next43, %._crit_edge ], [ 0, %.lr.ph34 ]
  %70 = getelementptr inbounds i32, ptr %67, i64 %indvars.iv42
  %71 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull %70)
  %72 = load i32, ptr %70, align 4, !tbaa !5
  %73 = load i32, ptr %3, align 4, !tbaa !5
  %74 = load i32, ptr %4, align 4, !tbaa !5
  %75 = mul nsw i32 %74, %73
  %76 = sub nsw i32 %72, %75
  %77 = add nsw i32 %75, %72
  %spec.store.select = call i32 @llvm.smax.i32(i32 %76, i32 1)
  %spec.store.select1 = call i32 @llvm.smin.i32(i32 %77, i32 100)
  %.not = icmp sgt i32 %spec.store.select, %spec.store.select1
  br i1 %.not, label %._crit_edge, label %.lr.ph.preheader

.lr.ph.preheader:                                 ; preds = %.lr.ph30
  %78 = zext nneg i32 %spec.store.select to i64
  %79 = shl nuw nsw i64 %78, 2
  %scevgep37 = getelementptr i8, ptr %scevgep, i64 %79
  %80 = sub nsw i32 %spec.store.select1, %spec.store.select
  %81 = zext i32 %80 to i64
  %82 = shl nuw nsw i64 %81, 2
  %83 = add nuw nsw i64 %82, 4
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 4 dereferenceable(1) %scevgep37, i8 0, i64 %83, i1 false), !tbaa !5
  br label %._crit_edge

._crit_edge:                                      ; preds = %.lr.ph.preheader, %.lr.ph30
  %indvars.iv.next43 = add nuw nsw i64 %indvars.iv42, 1
  %84 = load i32, ptr %2, align 4, !tbaa !5
  %85 = sext i32 %84 to i64
  %86 = icmp slt i64 %indvars.iv.next43, %85
  br i1 %86, label %.lr.ph30, label %.loopexit, !llvm.loop !9

.loopexit:                                        ; preds = %.lr.ph34, %._crit_edge
  %wide.load50.11 = load <4 x i32>, ptr %10, align 16, !tbaa !5
  %wide.load50.10 = load <4 x i32>, ptr %38, align 16, !tbaa !5
  %wide.load50.9 = load <4 x i32>, ptr %39, align 16, !tbaa !5
  %wide.load50.8 = load <4 x i32>, ptr %40, align 16, !tbaa !5
  %wide.load50.7 = load <4 x i32>, ptr %41, align 16, !tbaa !5
  %wide.load50.6 = load <4 x i32>, ptr %42, align 16, !tbaa !5
  %wide.load50.5 = load <4 x i32>, ptr %43, align 16, !tbaa !5
  %wide.load50.4 = load <4 x i32>, ptr %44, align 16, !tbaa !5
  %wide.load50.3 = load <4 x i32>, ptr %45, align 16, !tbaa !5
  %wide.load50.2 = load <4 x i32>, ptr %46, align 16, !tbaa !5
  %wide.load50.1 = load <4 x i32>, ptr %47, align 16, !tbaa !5
  %wide.load50 = load <4 x i32>, ptr %48, align 16, !tbaa !5
  %87 = add <4 x i32> %wide.load50.1, %wide.load50
  %88 = add <4 x i32> %wide.load50.2, %87
  %89 = add <4 x i32> %wide.load50.3, %88
  %90 = add <4 x i32> %wide.load50.4, %89
  %91 = add <4 x i32> %wide.load50.5, %90
  %92 = add <4 x i32> %wide.load50.6, %91
  %93 = add <4 x i32> %wide.load50.7, %92
  %94 = add <4 x i32> %wide.load50.8, %93
  %95 = add <4 x i32> %wide.load50.9, %94
  %96 = add <4 x i32> %wide.load50.10, %95
  %97 = add <4 x i32> %wide.load50.11, %96
  %wide.load.11 = load <4 x i32>, ptr %49, align 16, !tbaa !5
  %wide.load.10 = load <4 x i32>, ptr %50, align 16, !tbaa !5
  %wide.load.9 = load <4 x i32>, ptr %51, align 16, !tbaa !5
  %wide.load.8 = load <4 x i32>, ptr %52, align 16, !tbaa !5
  %wide.load.7 = load <4 x i32>, ptr %53, align 16, !tbaa !5
  %wide.load.6 = load <4 x i32>, ptr %54, align 16, !tbaa !5
  %wide.load.5 = load <4 x i32>, ptr %55, align 16, !tbaa !5
  %wide.load.4 = load <4 x i32>, ptr %56, align 16, !tbaa !5
  %wide.load.3 = load <4 x i32>, ptr %57, align 16, !tbaa !5
  %wide.load.2 = load <4 x i32>, ptr %58, align 16, !tbaa !5
  %wide.load.1 = load <4 x i32>, ptr %59, align 16, !tbaa !5
  %wide.load = load <4 x i32>, ptr %5, align 16, !tbaa !5
  %98 = add <4 x i32> %wide.load.1, %wide.load
  %99 = add <4 x i32> %wide.load.2, %98
  %100 = add <4 x i32> %wide.load.3, %99
  %101 = add <4 x i32> %wide.load.4, %100
  %102 = add <4 x i32> %wide.load.5, %101
  %103 = add <4 x i32> %wide.load.6, %102
  %104 = add <4 x i32> %wide.load.7, %103
  %105 = add <4 x i32> %wide.load.8, %104
  %106 = add <4 x i32> %wide.load.9, %105
  %107 = add <4 x i32> %wide.load.10, %106
  %108 = add <4 x i32> %wide.load.11, %107
  %bin.rdx = add <4 x i32> %97, %108
  %109 = call i32 @llvm.vector.reduce.add.v4i32(<4 x i32> %bin.rdx)
  %110 = load i32, ptr %9, align 16, !tbaa !5
  %111 = add nsw i32 %110, %109
  %112 = load i32, ptr %60, align 4, !tbaa !5
  %113 = add nsw i32 %112, %111
  %114 = load i32, ptr %61, align 8, !tbaa !5
  %115 = add nsw i32 %114, %113
  %116 = load i32, ptr %62, align 4, !tbaa !5
  %117 = add nsw i32 %116, %115
  %118 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.2, i32 noundef %117)
  %119 = load i32, ptr %1, align 4, !tbaa !5
  %120 = add nsw i32 %119, -1
  store i32 %120, ptr %1, align 4, !tbaa !5
  call void @llvm.stackrestore.p0(ptr %66)
  call void @llvm.lifetime.end.p0(i64 400, ptr nonnull %5) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %4) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %3) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %2) #6
  %121 = load i32, ptr %1, align 4, !tbaa !5
  %122 = icmp sgt i32 %121, 0
  br i1 %122, label %.lr.ph34, label %._crit_edge35, !llvm.loop !11

._crit_edge35:                                    ; preds = %.loopexit, %0
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %1) #6
  ret i32 0
}

; Function Attrs: mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.start.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: mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.end.p0(i64 immarg, ptr nocapture) #1

; Function Attrs: mustprogress nocallback nofree nosync nounwind willreturn
declare ptr @llvm.stacksave.p0() #3

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

; Function Attrs: mustprogress nocallback nofree nosync nounwind willreturn
declare void @llvm.stackrestore.p0(ptr) #3

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i32 @llvm.smax.i32(i32, i32) #4

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i32 @llvm.smin.i32(i32, i32) #4

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

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i32 @llvm.vector.reduce.add.v4i32(<4 x i32>) #4

attributes #0 = { nofree 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 = { mustprogress nocallback nofree nosync nounwind willreturn }
attributes #4 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #5 = { nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #6 = { 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/C++ TBAA"}
!9 = distinct !{!9, !10}
!10 = !{!"llvm.loop.mustprogress"}
!11 = distinct !{!11, !10}


; Effective O3 passes: CorrelatedValuePropagationPass,EarlyCSEPass,GVNPass,GlobalOptPass,IndVarSimplifyPass,InferAlignmentPass,InferFunctionAttrsPass,InstCombinePass,JumpThreadingPass,LCSSAPass,LICMPass,LoopIdiomRecognizePass,LoopLoadEliminationPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,LoopVectorizePass,PostOrderFunctionAttrsPass,ReassociatePass,SROAPass,SimplifyCFGPass