; LLVM IR from lzyrapx/Competitive-Programming :: HDUOJ (1502（dp+手写大数）)

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

@num = external dso_local global [67 x [89 x i8]], align 16
@dp = external dso_local global [62 x [62 x [62 x [89 x i8]]]], align 16
@.str = external hidden unnamed_addr constant [3 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [2 x i8], align 1

; Function Attrs: mustprogress uwtable
declare dso_local void @_Z3sumPcS_(ptr noundef, ptr noundef) #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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_Z4CopyPcS_(ptr noundef, ptr noundef) #2

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() #3 {
  %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
  store i32 0, ptr %1, align 4
  call void @llvm.memset.p0.i64(ptr align 16 @dp, i8 0, i64 21211192, i1 false)
  store i8 1, ptr getelementptr inbounds ([89 x i8], ptr @dp, i64 0, i64 1), align 1, !tbaa !5
  store i8 1, ptr @dp, align 16, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %2) #6
  store i32 1, ptr %2, align 4, !tbaa !8
  br label %8

8:                                                ; preds = %162, %0
  %9 = load i32, ptr %2, align 4, !tbaa !8
  %10 = icmp sle i32 %9, 60
  br i1 %10, label %12, label %11

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

12:                                               ; preds = %8
  call void @llvm.lifetime.start.p0(i64 4, ptr %4) #6
  store i32 0, ptr %4, align 4, !tbaa !8
  br label %13

13:                                               ; preds = %158, %12
  %14 = load i32, ptr %4, align 4, !tbaa !8
  %15 = load i32, ptr %2, align 4, !tbaa !8
  %16 = icmp sle i32 %14, %15
  br i1 %16, label %18, label %17

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

18:                                               ; preds = %13
  call void @llvm.lifetime.start.p0(i64 4, ptr %5) #6
  store i32 0, ptr %5, align 4, !tbaa !8
  br label %19

19:                                               ; preds = %154, %18
  %20 = load i32, ptr %5, align 4, !tbaa !8
  %21 = load i32, ptr %4, align 4, !tbaa !8
  %22 = icmp sle i32 %20, %21
  br i1 %22, label %24, label %23

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

24:                                               ; preds = %19
  %25 = load i32, ptr %2, align 4, !tbaa !8
  %26 = sub nsw i32 %25, 1
  %27 = icmp sge i32 %26, 0
  br i1 %27, label %28, label %59

28:                                               ; preds = %24
  %29 = load i32, ptr %2, align 4, !tbaa !8
  %30 = sub nsw i32 %29, 1
  %31 = load i32, ptr %4, align 4, !tbaa !8
  %32 = icmp sge i32 %30, %31
  br i1 %32, label %33, label %59

33:                                               ; preds = %28
  %34 = load i32, ptr %4, align 4, !tbaa !8
  %35 = load i32, ptr %5, align 4, !tbaa !8
  %36 = icmp sge i32 %34, %35
  br i1 %36, label %37, label %59

37:                                               ; preds = %33
  %38 = load i32, ptr %2, align 4, !tbaa !8
  %39 = sext i32 %38 to i64
  %40 = getelementptr inbounds [62 x [62 x [62 x [89 x i8]]]], ptr @dp, i64 0, i64 %39
  %41 = load i32, ptr %4, align 4, !tbaa !8
  %42 = sext i32 %41 to i64
  %43 = getelementptr inbounds [62 x [62 x [89 x i8]]], ptr %40, i64 0, i64 %42
  %44 = load i32, ptr %5, align 4, !tbaa !8
  %45 = sext i32 %44 to i64
  %46 = getelementptr inbounds [62 x [89 x i8]], ptr %43, i64 0, i64 %45
  %47 = getelementptr inbounds [89 x i8], ptr %46, i64 0, i64 0
  %48 = load i32, ptr %2, align 4, !tbaa !8
  %49 = sub nsw i32 %48, 1
  %50 = sext i32 %49 to i64
  %51 = getelementptr inbounds [62 x [62 x [62 x [89 x i8]]]], ptr @dp, i64 0, i64 %50
  %52 = load i32, ptr %4, align 4, !tbaa !8
  %53 = sext i32 %52 to i64
  %54 = getelementptr inbounds [62 x [62 x [89 x i8]]], ptr %51, i64 0, i64 %53
  %55 = load i32, ptr %5, align 4, !tbaa !8
  %56 = sext i32 %55 to i64
  %57 = getelementptr inbounds [62 x [89 x i8]], ptr %54, i64 0, i64 %56
  %58 = getelementptr inbounds [89 x i8], ptr %57, i64 0, i64 0
  call void @_Z3sumPcS_(ptr noundef %47, ptr noundef %58)
  br label %59

59:                                               ; preds = %37, %33, %28, %24
  %60 = load i32, ptr %4, align 4, !tbaa !8
  %61 = sub nsw i32 %60, 1
  %62 = icmp sge i32 %61, 0
  br i1 %62, label %63, label %95

63:                                               ; preds = %59
  %64 = load i32, ptr %2, align 4, !tbaa !8
  %65 = load i32, ptr %4, align 4, !tbaa !8
  %66 = sub nsw i32 %65, 1
  %67 = icmp sge i32 %64, %66
  br i1 %67, label %68, label %95

68:                                               ; preds = %63
  %69 = load i32, ptr %4, align 4, !tbaa !8
  %70 = sub nsw i32 %69, 1
  %71 = load i32, ptr %5, align 4, !tbaa !8
  %72 = icmp sge i32 %70, %71
  br i1 %72, label %73, label %95

73:                                               ; preds = %68
  %74 = load i32, ptr %2, align 4, !tbaa !8
  %75 = sext i32 %74 to i64
  %76 = getelementptr inbounds [62 x [62 x [62 x [89 x i8]]]], ptr @dp, i64 0, i64 %75
  %77 = load i32, ptr %4, align 4, !tbaa !8
  %78 = sext i32 %77 to i64
  %79 = getelementptr inbounds [62 x [62 x [89 x i8]]], ptr %76, i64 0, i64 %78
  %80 = load i32, ptr %5, align 4, !tbaa !8
  %81 = sext i32 %80 to i64
  %82 = getelementptr inbounds [62 x [89 x i8]], ptr %79, i64 0, i64 %81
  %83 = getelementptr inbounds [89 x i8], ptr %82, i64 0, i64 0
  %84 = load i32, ptr %2, align 4, !tbaa !8
  %85 = sext i32 %84 to i64
  %86 = getelementptr inbounds [62 x [62 x [62 x [89 x i8]]]], ptr @dp, i64 0, i64 %85
  %87 = load i32, ptr %4, align 4, !tbaa !8
  %88 = sub nsw i32 %87, 1
  %89 = sext i32 %88 to i64
  %90 = getelementptr inbounds [62 x [62 x [89 x i8]]], ptr %86, i64 0, i64 %89
  %91 = load i32, ptr %5, align 4, !tbaa !8
  %92 = sext i32 %91 to i64
  %93 = getelementptr inbounds [62 x [89 x i8]], ptr %90, i64 0, i64 %92
  %94 = getelementptr inbounds [89 x i8], ptr %93, i64 0, i64 0
  call void @_Z3sumPcS_(ptr noundef %83, ptr noundef %94)
  br label %95

95:                                               ; preds = %73, %68, %63, %59
  %96 = load i32, ptr %5, align 4, !tbaa !8
  %97 = sub nsw i32 %96, 1
  %98 = icmp sge i32 %97, 0
  br i1 %98, label %99, label %130

99:                                               ; preds = %95
  %100 = load i32, ptr %2, align 4, !tbaa !8
  %101 = load i32, ptr %4, align 4, !tbaa !8
  %102 = icmp sge i32 %100, %101
  br i1 %102, label %103, label %130

103:                                              ; preds = %99
  %104 = load i32, ptr %4, align 4, !tbaa !8
  %105 = load i32, ptr %5, align 4, !tbaa !8
  %106 = sub nsw i32 %105, 1
  %107 = icmp sge i32 %104, %106
  br i1 %107, label %108, label %130

108:                                              ; preds = %103
  %109 = load i32, ptr %2, align 4, !tbaa !8
  %110 = sext i32 %109 to i64
  %111 = getelementptr inbounds [62 x [62 x [62 x [89 x i8]]]], ptr @dp, i64 0, i64 %110
  %112 = load i32, ptr %4, align 4, !tbaa !8
  %113 = sext i32 %112 to i64
  %114 = getelementptr inbounds [62 x [62 x [89 x i8]]], ptr %111, i64 0, i64 %113
  %115 = load i32, ptr %5, align 4, !tbaa !8
  %116 = sext i32 %115 to i64
  %117 = getelementptr inbounds [62 x [89 x i8]], ptr %114, i64 0, i64 %116
  %118 = getelementptr inbounds [89 x i8], ptr %117, i64 0, i64 0
  %119 = load i32, ptr %2, align 4, !tbaa !8
  %120 = sext i32 %119 to i64
  %121 = getelementptr inbounds [62 x [62 x [62 x [89 x i8]]]], ptr @dp, i64 0, i64 %120
  %122 = load i32, ptr %4, align 4, !tbaa !8
  %123 = sext i32 %122 to i64
  %124 = getelementptr inbounds [62 x [62 x [89 x i8]]], ptr %121, i64 0, i64 %123
  %125 = load i32, ptr %5, align 4, !tbaa !8
  %126 = sub nsw i32 %125, 1
  %127 = sext i32 %126 to i64
  %128 = getelementptr inbounds [62 x [89 x i8]], ptr %124, i64 0, i64 %127
  %129 = getelementptr inbounds [89 x i8], ptr %128, i64 0, i64 0
  call void @_Z3sumPcS_(ptr noundef %118, ptr noundef %129)
  br label %130

130:                                              ; preds = %108, %103, %99, %95
  %131 = load i32, ptr %2, align 4, !tbaa !8
  %132 = load i32, ptr %4, align 4, !tbaa !8
  %133 = icmp eq i32 %131, %132
  br i1 %133, label %134, label %153

134:                                              ; preds = %130
  %135 = load i32, ptr %4, align 4, !tbaa !8
  %136 = load i32, ptr %5, align 4, !tbaa !8
  %137 = icmp eq i32 %135, %136
  br i1 %137, label %138, label %153

138:                                              ; preds = %134
  %139 = load i32, ptr %2, align 4, !tbaa !8
  %140 = sext i32 %139 to i64
  %141 = getelementptr inbounds [67 x [89 x i8]], ptr @num, i64 0, i64 %140
  %142 = getelementptr inbounds [89 x i8], ptr %141, i64 0, i64 0
  %143 = load i32, ptr %2, align 4, !tbaa !8
  %144 = sext i32 %143 to i64
  %145 = getelementptr inbounds [62 x [62 x [62 x [89 x i8]]]], ptr @dp, i64 0, i64 %144
  %146 = load i32, ptr %4, align 4, !tbaa !8
  %147 = sext i32 %146 to i64
  %148 = getelementptr inbounds [62 x [62 x [89 x i8]]], ptr %145, i64 0, i64 %147
  %149 = load i32, ptr %5, align 4, !tbaa !8
  %150 = sext i32 %149 to i64
  %151 = getelementptr inbounds [62 x [89 x i8]], ptr %148, i64 0, i64 %150
  %152 = getelementptr inbounds [89 x i8], ptr %151, i64 0, i64 0
  call void @_Z4CopyPcS_(ptr noundef %142, ptr noundef %152)
  br label %153

153:                                              ; preds = %138, %134, %130
  br label %154

154:                                              ; preds = %153
  %155 = load i32, ptr %5, align 4, !tbaa !8
  %156 = add nsw i32 %155, 1
  store i32 %156, ptr %5, align 4, !tbaa !8
  br label %19, !llvm.loop !10

157:                                              ; preds = %23
  br label %158

158:                                              ; preds = %157
  %159 = load i32, ptr %4, align 4, !tbaa !8
  %160 = add nsw i32 %159, 1
  store i32 %160, ptr %4, align 4, !tbaa !8
  br label %13, !llvm.loop !12

161:                                              ; preds = %17
  br label %162

162:                                              ; preds = %161
  %163 = load i32, ptr %2, align 4, !tbaa !8
  %164 = add nsw i32 %163, 1
  store i32 %164, ptr %2, align 4, !tbaa !8
  br label %8, !llvm.loop !13

165:                                              ; preds = %11
  call void @llvm.lifetime.start.p0(i64 4, ptr %6) #6
  br label %166

166:                                              ; preds = %194, %165
  %167 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef %6)
  %168 = xor i32 %167, -1
  %169 = icmp ne i32 %168, 0
  br i1 %169, label %170, label %196

170:                                              ; preds = %166
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #6
  %171 = load i32, ptr %6, align 4, !tbaa !8
  %172 = sext i32 %171 to i64
  %173 = getelementptr inbounds [67 x [89 x i8]], ptr @num, i64 0, i64 %172
  %174 = getelementptr inbounds [89 x i8], ptr %173, i64 0, i64 0
  %175 = load i8, ptr %174, align 1, !tbaa !5
  %176 = sext i8 %175 to i32
  store i32 %176, ptr %7, align 4, !tbaa !8
  br label %177

177:                                              ; preds = %191, %170
  %178 = load i32, ptr %7, align 4, !tbaa !8
  %179 = icmp sgt i32 %178, 0
  br i1 %179, label %181, label %180

180:                                              ; preds = %177
  store i32 13, ptr %3, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #6
  br label %194

181:                                              ; preds = %177
  %182 = load i32, ptr %6, align 4, !tbaa !8
  %183 = sext i32 %182 to i64
  %184 = getelementptr inbounds [67 x [89 x i8]], ptr @num, i64 0, i64 %183
  %185 = load i32, ptr %7, align 4, !tbaa !8
  %186 = sext i32 %185 to i64
  %187 = getelementptr inbounds [89 x i8], ptr %184, i64 0, i64 %186
  %188 = load i8, ptr %187, align 1, !tbaa !5
  %189 = sext i8 %188 to i32
  %190 = call i32 (ptr, ...) @printf(ptr noundef @.str, i32 noundef %189)
  br label %191

191:                                              ; preds = %181
  %192 = load i32, ptr %7, align 4, !tbaa !8
  %193 = add nsw i32 %192, -1
  store i32 %193, ptr %7, align 4, !tbaa !8
  br label %177, !llvm.loop !14

194:                                              ; preds = %180
  %195 = call i32 @puts(ptr noundef @.str.1)
  br label %166, !llvm.loop !15

196:                                              ; preds = %166
  store i32 0, ptr %1, align 4
  store i32 1, ptr %3, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %6) #6
  %197 = load i32, ptr %1, align 4
  ret i32 %197
}

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

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

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

declare i32 @puts(ptr noundef) #5

attributes #0 = { 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 #1 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { mustprogress 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 #3 = { 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 #4 = { nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #5 = { "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 #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 = !{!"omnipotent char", !7, i64 0}
!7 = !{!"Simple C++ TBAA"}
!8 = !{!9, !9, i64 0}
!9 = !{!"int", !6, i64 0}
!10 = distinct !{!10, !11}
!11 = !{!"llvm.loop.mustprogress"}
!12 = distinct !{!12, !11}
!13 = distinct !{!13, !11}
!14 = distinct !{!14, !11}
!15 = distinct !{!15, !11}


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

@num = external dso_local global [67 x [89 x i8]], align 16
@dp = external dso_local global [62 x [62 x [62 x [89 x i8]]]], align 16
@.str = external hidden unnamed_addr constant [3 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [2 x i8], align 1

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_Z4CopyPcS_(ptr noundef, ptr noundef) local_unnamed_addr #2

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() local_unnamed_addr #3 {
  %1 = alloca i32, align 4
  tail call void @llvm.memset.p0.i64(ptr noundef nonnull align 16 dereferenceable(21211192) @dp, i8 0, i64 21211192, i1 false)
  store i8 1, ptr getelementptr inbounds (i8, ptr @dp, i64 1), align 1, !tbaa !5
  store i8 1, ptr @dp, align 16, !tbaa !5
  br label %.preheader71

.preheader71:                                     ; preds = %0, %41
  %indvars.iv117 = phi i64 [ 1, %0 ], [ %indvars.iv.next118, %41 ]
  %indvars.iv115 = phi i64 [ 2, %0 ], [ %indvars.iv.next116, %41 ]
  %2 = add nsw i64 %indvars.iv117, -1
  %3 = getelementptr inbounds [67 x [89 x i8]], ptr @num, i64 0, i64 %indvars.iv117
  %4 = getelementptr inbounds [62 x [62 x [62 x [89 x i8]]]], ptr @dp, i64 0, i64 %indvars.iv117, i64 0, i64 0
  %5 = getelementptr inbounds [62 x [62 x [62 x [89 x i8]]]], ptr @dp, i64 0, i64 %indvars.iv117, i64 0, i64 0
  br label %.preheader

6:                                                ; preds = %41
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %1) #6
  %7 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull %1)
  %.not82 = icmp eq i32 %7, -1
  br i1 %.not82, label %._crit_edge85, label %.lr.ph84

.preheader:                                       ; preds = %.preheader71, %.split.us
  %indvars.iv106 = phi i64 [ 0, %.preheader71 ], [ %indvars.iv.next107, %.split.us ]
  %indvars.iv104 = phi i64 [ 1, %.preheader71 ], [ %indvars.iv.next105, %.split.us ]
  %.not61.not = icmp ugt i64 %indvars.iv117, %indvars.iv106
  %8 = add nsw i64 %indvars.iv106, -1
  %9 = icmp eq i64 %indvars.iv117, %indvars.iv106
  %.fr = freeze i1 %9
  %10 = getelementptr inbounds [62 x [62 x [62 x [89 x i8]]]], ptr @dp, i64 0, i64 %indvars.iv117, i64 %indvars.iv106, i64 0
  br i1 %.not61.not, label %.preheader.split.us.preheader, label %.preheader.split

.preheader.split.us.preheader:                    ; preds = %.preheader
  %11 = getelementptr inbounds [62 x [62 x [62 x [89 x i8]]]], ptr @dp, i64 0, i64 %2, i64 %indvars.iv106, i64 0
  tail call void @_Z3sumPcS_(ptr noundef nonnull %10, ptr noundef nonnull %11)
  %.not64.not.us.peel.not = icmp eq i64 %indvars.iv106, 0
  br i1 %.not64.not.us.peel.not, label %13, label %.thread

.thread:                                          ; preds = %.preheader.split.us.preheader
  %12 = getelementptr inbounds [62 x [62 x [62 x [89 x i8]]]], ptr @dp, i64 0, i64 %indvars.iv117, i64 %8, i64 0
  tail call void @_Z3sumPcS_(ptr noundef nonnull %10, ptr noundef nonnull %12)
  br label %15

13:                                               ; preds = %.preheader.split.us.preheader
  br i1 %.fr, label %14, label %15

14:                                               ; preds = %13
  tail call void @_Z4CopyPcS_(ptr noundef nonnull %3, ptr noundef nonnull %5)
  br label %15

15:                                               ; preds = %.thread, %14, %13
  %exitcond102.peel.not = icmp eq i64 %indvars.iv104, 1
  br i1 %exitcond102.peel.not, label %.split.us, label %.preheader.split.us.peel.next

.preheader.split.us.peel.next:                    ; preds = %15
  %16 = getelementptr inbounds [62 x [62 x [62 x [89 x i8]]]], ptr @dp, i64 0, i64 %indvars.iv117, i64 %indvars.iv106, i64 %indvars.iv106
  br label %.preheader.split.us

.preheader.split.us:                              ; preds = %.preheader.split.us.peel.next, %26
  %indvars.iv98 = phi i64 [ 1, %.preheader.split.us.peel.next ], [ %indvars.iv.next99, %26 ]
  %17 = getelementptr inbounds [62 x [62 x [62 x [89 x i8]]]], ptr @dp, i64 0, i64 %indvars.iv117, i64 %indvars.iv106, i64 %indvars.iv98
  %18 = getelementptr inbounds [62 x [62 x [62 x [89 x i8]]]], ptr @dp, i64 0, i64 %2, i64 %indvars.iv106, i64 %indvars.iv98
  tail call void @_Z3sumPcS_(ptr noundef nonnull %17, ptr noundef nonnull %18)
  %.not64.not.us = icmp ugt i64 %indvars.iv106, %indvars.iv98
  br i1 %.not64.not.us, label %19, label %21

19:                                               ; preds = %.preheader.split.us
  %20 = getelementptr inbounds [62 x [62 x [62 x [89 x i8]]]], ptr @dp, i64 0, i64 %indvars.iv117, i64 %8, i64 %indvars.iv98
  tail call void @_Z3sumPcS_(ptr noundef nonnull %17, ptr noundef nonnull %20)
  br label %21

21:                                               ; preds = %19, %.preheader.split.us
  %22 = add nsw i64 %indvars.iv98, -1
  %23 = getelementptr inbounds [62 x [62 x [62 x [89 x i8]]]], ptr @dp, i64 0, i64 %indvars.iv117, i64 %indvars.iv106, i64 %22
  tail call void @_Z3sumPcS_(ptr noundef nonnull %17, ptr noundef nonnull %23)
  %24 = icmp eq i64 %indvars.iv106, %indvars.iv98
  %or.cond69.us = and i1 %.fr, %24
  br i1 %or.cond69.us, label %25, label %26

25:                                               ; preds = %21
  tail call void @_Z4CopyPcS_(ptr noundef nonnull %3, ptr noundef nonnull %16)
  br label %26

26:                                               ; preds = %25, %21
  %indvars.iv.next99 = add nuw nsw i64 %indvars.iv98, 1
  %exitcond102.not = icmp eq i64 %indvars.iv.next99, %indvars.iv104
  br i1 %exitcond102.not, label %.split.us, label %.preheader.split.us, !llvm.loop !8

.preheader.split:                                 ; preds = %.preheader
  %27 = getelementptr inbounds [62 x [62 x [62 x [89 x i8]]]], ptr @dp, i64 0, i64 %indvars.iv117, i64 %8, i64 0
  tail call void @_Z3sumPcS_(ptr noundef nonnull %10, ptr noundef nonnull %27)
  br i1 %.fr, label %29, label %28

28:                                               ; preds = %.preheader.split
  %exitcond.peel.not = icmp eq i64 %indvars.iv104, 1
  br i1 %exitcond.peel.not, label %.split.us, label %.preheader.split.split.us

29:                                               ; preds = %.preheader.split
  %30 = icmp eq i64 %indvars.iv106, 0
  br i1 %30, label %31, label %32

31:                                               ; preds = %29
  tail call void @_Z4CopyPcS_(ptr noundef nonnull %3, ptr noundef nonnull %4)
  br label %32

32:                                               ; preds = %31, %29
  %exitcond96.peel.not = icmp eq i64 %indvars.iv104, 1
  br i1 %exitcond96.peel.not, label %.split.us, label %.preheader.split.split.peel.next

.preheader.split.split.peel.next:                 ; preds = %32
  %33 = getelementptr inbounds [62 x [62 x [62 x [89 x i8]]]], ptr @dp, i64 0, i64 %indvars.iv117, i64 %indvars.iv106, i64 %indvars.iv106
  br label %.preheader.split.split

.preheader.split.split.us:                        ; preds = %28, %37
  %indvars.iv = phi i64 [ %indvars.iv.next, %37 ], [ 1, %28 ]
  %.not64.not.us74 = icmp ugt i64 %indvars.iv106, %indvars.iv
  br i1 %.not64.not.us74, label %34, label %37

34:                                               ; preds = %.preheader.split.split.us
  %35 = getelementptr inbounds [62 x [62 x [62 x [89 x i8]]]], ptr @dp, i64 0, i64 %indvars.iv117, i64 %indvars.iv106, i64 %indvars.iv
  %36 = getelementptr inbounds [62 x [62 x [62 x [89 x i8]]]], ptr @dp, i64 0, i64 %indvars.iv117, i64 %8, i64 %indvars.iv
  tail call void @_Z3sumPcS_(ptr noundef nonnull %35, ptr noundef nonnull %36)
  br label %37

37:                                               ; preds = %34, %.preheader.split.split.us
  %38 = add nsw i64 %indvars.iv, -1
  %39 = getelementptr inbounds [62 x [62 x [62 x [89 x i8]]]], ptr @dp, i64 0, i64 %indvars.iv117, i64 %indvars.iv106, i64 %indvars.iv
  %40 = getelementptr inbounds [62 x [62 x [62 x [89 x i8]]]], ptr @dp, i64 0, i64 %indvars.iv117, i64 %indvars.iv106, i64 %38
  tail call void @_Z3sumPcS_(ptr noundef nonnull %39, ptr noundef nonnull %40)
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %exitcond.not = icmp eq i64 %indvars.iv.next, %indvars.iv104
  br i1 %exitcond.not, label %.split.us, label %.preheader.split.split.us, !llvm.loop !11

41:                                               ; preds = %.split.us
  %indvars.iv.next118 = add nuw nsw i64 %indvars.iv117, 1
  %indvars.iv.next116 = add nuw nsw i64 %indvars.iv115, 1
  %exitcond122.not = icmp eq i64 %indvars.iv.next118, 61
  br i1 %exitcond122.not, label %6, label %.preheader71, !llvm.loop !12

.split.us:                                        ; preds = %37, %51, %26, %28, %32, %15
  %indvars.iv.next107 = add nuw nsw i64 %indvars.iv106, 1
  %indvars.iv.next105 = add nuw nsw i64 %indvars.iv104, 1
  %exitcond114.not = icmp eq i64 %indvars.iv.next107, %indvars.iv115
  br i1 %exitcond114.not, label %41, label %.preheader, !llvm.loop !13

.preheader.split.split:                           ; preds = %.preheader.split.split.peel.next, %51
  %indvars.iv92 = phi i64 [ 1, %.preheader.split.split.peel.next ], [ %indvars.iv.next93, %51 ]
  %.not64.not = icmp ugt i64 %indvars.iv106, %indvars.iv92
  br i1 %.not64.not, label %42, label %45

42:                                               ; preds = %.preheader.split.split
  %43 = getelementptr inbounds [62 x [62 x [62 x [89 x i8]]]], ptr @dp, i64 0, i64 %indvars.iv117, i64 %indvars.iv106, i64 %indvars.iv92
  %44 = getelementptr inbounds [62 x [62 x [62 x [89 x i8]]]], ptr @dp, i64 0, i64 %indvars.iv117, i64 %8, i64 %indvars.iv92
  tail call void @_Z3sumPcS_(ptr noundef nonnull %43, ptr noundef nonnull %44)
  br label %45

45:                                               ; preds = %42, %.preheader.split.split
  %46 = add nsw i64 %indvars.iv92, -1
  %47 = getelementptr inbounds [62 x [62 x [62 x [89 x i8]]]], ptr @dp, i64 0, i64 %indvars.iv117, i64 %indvars.iv106, i64 %indvars.iv92
  %48 = getelementptr inbounds [62 x [62 x [62 x [89 x i8]]]], ptr @dp, i64 0, i64 %indvars.iv117, i64 %indvars.iv106, i64 %46
  tail call void @_Z3sumPcS_(ptr noundef nonnull %47, ptr noundef nonnull %48)
  %49 = icmp eq i64 %indvars.iv106, %indvars.iv92
  br i1 %49, label %50, label %51

50:                                               ; preds = %45
  tail call void @_Z4CopyPcS_(ptr noundef nonnull %3, ptr noundef nonnull %33)
  br label %51

51:                                               ; preds = %45, %50
  %indvars.iv.next93 = add nuw nsw i64 %indvars.iv92, 1
  %exitcond96.not = icmp eq i64 %indvars.iv.next93, %indvars.iv104
  br i1 %exitcond96.not, label %.split.us, label %.preheader.split.split, !llvm.loop !14

.lr.ph84:                                         ; preds = %6, %._crit_edge
  %52 = load i32, ptr %1, align 4, !tbaa !15
  %53 = sext i32 %52 to i64
  %54 = getelementptr inbounds [67 x [89 x i8]], ptr @num, i64 0, i64 %53
  %55 = load i8, ptr %54, align 1, !tbaa !5
  %56 = icmp sgt i8 %55, 0
  br i1 %56, label %.lr.ph.preheader, label %._crit_edge

.lr.ph.preheader:                                 ; preds = %.lr.ph84
  %57 = zext nneg i8 %55 to i64
  br label %.lr.ph

._crit_edge:                                      ; preds = %.lr.ph, %.lr.ph84
  %58 = call i32 @puts(ptr noundef nonnull dereferenceable(1) @.str.1)
  %59 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull %1)
  %.not = icmp eq i32 %59, -1
  br i1 %.not, label %._crit_edge85, label %.lr.ph84, !llvm.loop !17

.lr.ph:                                           ; preds = %.lr.ph.preheader, %.lr.ph
  %indvars.iv123 = phi i64 [ %57, %.lr.ph.preheader ], [ %indvars.iv.next124, %.lr.ph ]
  %60 = load i32, ptr %1, align 4, !tbaa !15
  %61 = sext i32 %60 to i64
  %62 = getelementptr inbounds [67 x [89 x i8]], ptr @num, i64 0, i64 %61, i64 %indvars.iv123
  %63 = load i8, ptr %62, align 1, !tbaa !5
  %64 = sext i8 %63 to i32
  %65 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str, i32 noundef %64)
  %indvars.iv.next124 = add nsw i64 %indvars.iv123, -1
  %66 = icmp ugt i64 %indvars.iv123, 1
  br i1 %66, label %.lr.ph, label %._crit_edge, !llvm.loop !18

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

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

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

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

; Function Attrs: nofree nounwind
declare noundef i32 @puts(ptr nocapture noundef readonly) local_unnamed_addr #5

attributes #0 = { 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 #1 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { mustprogress 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 #3 = { 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 #4 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #5 = { 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 #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 = !{!"omnipotent char", !7, i64 0}
!7 = !{!"Simple C++ TBAA"}
!8 = distinct !{!8, !9, !10}
!9 = !{!"llvm.loop.mustprogress"}
!10 = !{!"llvm.loop.peeled.count", i32 1}
!11 = distinct !{!11, !9, !10}
!12 = distinct !{!12, !9}
!13 = distinct !{!13, !9}
!14 = distinct !{!14, !9, !10}
!15 = !{!16, !16, i64 0}
!16 = !{!"int", !6, i64 0}
!17 = distinct !{!17, !9}
!18 = distinct !{!18, !9}


; Effective O3 passes: ConstraintEliminationPass,CorrelatedValuePropagationPass,EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferFunctionAttrsPass,InstCombinePass,JumpThreadingPass,LICMPass,LoopFullUnrollPass,LoopInstSimplifyPass,LoopRotatePass,LoopSimplifyCFGPass,LoopSimplifyPass,LoopUnrollPass,SCCPPass,SROAPass,SimplifyCFGPass,TailCallElimPass