; LLVM IR from tangjz/acm-icpc :: lydsy (2002)

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

%struct.Node = type { i32, [2 x i32], i32 }

@t = external dso_local global [200010 x %struct.Node], align 16
@n = external dso_local global i32, align 4
@m = external dso_local global i32, align 4
@p = external dso_local global [200010 x i32], align 16
@.str = external hidden unnamed_addr constant [3 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [5 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [4 x i8], align 1

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_Z5setchiii(i32 noundef, i32 noundef, i32 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 @_Z5splayi(i32 noundef) #0

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_Z6accessi(i32 noundef) #0

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_Z3addRi(ptr noundef nonnull align 4 dereferenceable(4)) #0

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() #2 {
  %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
  %8 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef @n)
  call void @llvm.lifetime.start.p0(i64 4, ptr %2) #4
  store i32 0, ptr %2, align 4, !tbaa !5
  br label %9

9:                                                ; preds = %18, %0
  %10 = load i32, ptr %2, align 4, !tbaa !5
  %11 = load i32, ptr @n, align 4, !tbaa !5
  %12 = icmp sle i32 %10, %11
  br i1 %12, label %14, label %13

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

14:                                               ; preds = %9
  %15 = load i32, ptr %2, align 4, !tbaa !5
  %16 = sext i32 %15 to i64
  %17 = getelementptr inbounds [200010 x i32], ptr @p, i64 0, i64 %16
  call void @_Z3addRi(ptr noundef nonnull align 4 dereferenceable(4) %17)
  br label %18

18:                                               ; preds = %14
  %19 = load i32, ptr %2, align 4, !tbaa !5
  %20 = add nsw i32 %19, 1
  store i32 %20, ptr %2, align 4, !tbaa !5
  br label %9, !llvm.loop !9

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

22:                                               ; preds = %49, %21
  %23 = load i32, ptr %3, align 4, !tbaa !5
  %24 = load i32, ptr @n, align 4, !tbaa !5
  %25 = icmp slt i32 %23, %24
  br i1 %25, label %27, label %26

26:                                               ; preds = %22
  call void @llvm.lifetime.end.p0(i64 4, ptr %4) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %3) #4
  br label %52

27:                                               ; preds = %22
  %28 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef %4)
  %29 = load i32, ptr %3, align 4, !tbaa !5
  %30 = load i32, ptr %4, align 4, !tbaa !5
  %31 = add nsw i32 %30, %29
  store i32 %31, ptr %4, align 4, !tbaa !5
  %32 = load i32, ptr %4, align 4, !tbaa !5
  %33 = load i32, ptr @n, align 4, !tbaa !5
  %34 = icmp sgt i32 %32, %33
  br i1 %34, label %35, label %37

35:                                               ; preds = %27
  %36 = load i32, ptr @n, align 4, !tbaa !5
  store i32 %36, ptr %4, align 4, !tbaa !5
  br label %37

37:                                               ; preds = %35, %27
  %38 = load i32, ptr %4, align 4, !tbaa !5
  %39 = sext i32 %38 to i64
  %40 = getelementptr inbounds [200010 x i32], ptr @p, i64 0, i64 %39
  %41 = load i32, ptr %40, align 4, !tbaa !5
  %42 = load i32, ptr %3, align 4, !tbaa !5
  %43 = sext i32 %42 to i64
  %44 = getelementptr inbounds [200010 x i32], ptr @p, i64 0, i64 %43
  %45 = load i32, ptr %44, align 4, !tbaa !5
  %46 = sext i32 %45 to i64
  %47 = getelementptr inbounds [200010 x %struct.Node], ptr @t, i64 0, i64 %46
  %48 = getelementptr inbounds %struct.Node, ptr %47, i32 0, i32 0
  store i32 %41, ptr %48, align 16, !tbaa !11
  br label %49

49:                                               ; preds = %37
  %50 = load i32, ptr %3, align 4, !tbaa !5
  %51 = add nsw i32 %50, 1
  store i32 %51, ptr %3, align 4, !tbaa !5
  br label %22, !llvm.loop !13

52:                                               ; preds = %26
  %53 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef @m)
  br label %54

54:                                               ; preds = %127, %52
  %55 = load i32, ptr @m, align 4, !tbaa !5
  %56 = add nsw i32 %55, -1
  store i32 %56, ptr @m, align 4, !tbaa !5
  %57 = icmp ne i32 %55, 0
  br i1 %57, label %58, label %128

58:                                               ; preds = %54
  call void @llvm.lifetime.start.p0(i64 4, ptr %5) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr %6) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #4
  %59 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str.1, ptr noundef %5, ptr noundef %6)
  %60 = load i32, ptr %5, align 4, !tbaa !5
  %61 = icmp eq i32 %60, 2
  br i1 %61, label %62, label %112

62:                                               ; preds = %58
  %63 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef %7)
  %64 = load i32, ptr %6, align 4, !tbaa !5
  %65 = load i32, ptr %7, align 4, !tbaa !5
  %66 = add nsw i32 %65, %64
  store i32 %66, ptr %7, align 4, !tbaa !5
  %67 = load i32, ptr %7, align 4, !tbaa !5
  %68 = load i32, ptr @n, align 4, !tbaa !5
  %69 = icmp sgt i32 %67, %68
  br i1 %69, label %70, label %72

70:                                               ; preds = %62
  %71 = load i32, ptr @n, align 4, !tbaa !5
  store i32 %71, ptr %7, align 4, !tbaa !5
  br label %72

72:                                               ; preds = %70, %62
  %73 = load i32, ptr %6, align 4, !tbaa !5
  %74 = sext i32 %73 to i64
  %75 = getelementptr inbounds [200010 x i32], ptr @p, i64 0, i64 %74
  %76 = load i32, ptr %75, align 4, !tbaa !5
  call void @_Z5splayi(i32 noundef %76)
  %77 = load i32, ptr %6, align 4, !tbaa !5
  %78 = sext i32 %77 to i64
  %79 = getelementptr inbounds [200010 x i32], ptr @p, i64 0, i64 %78
  %80 = load i32, ptr %79, align 4, !tbaa !5
  %81 = sext i32 %80 to i64
  %82 = getelementptr inbounds [200010 x %struct.Node], ptr @t, i64 0, i64 %81
  %83 = getelementptr inbounds %struct.Node, ptr %82, i32 0, i32 0
  %84 = load i32, ptr %83, align 16, !tbaa !11
  %85 = load i32, ptr %6, align 4, !tbaa !5
  %86 = sext i32 %85 to i64
  %87 = getelementptr inbounds [200010 x i32], ptr @p, i64 0, i64 %86
  %88 = load i32, ptr %87, align 4, !tbaa !5
  %89 = sext i32 %88 to i64
  %90 = getelementptr inbounds [200010 x %struct.Node], ptr @t, i64 0, i64 %89
  %91 = getelementptr inbounds %struct.Node, ptr %90, i32 0, i32 1
  %92 = getelementptr inbounds [2 x i32], ptr %91, i64 0, i64 0
  %93 = load i32, ptr %92, align 4, !tbaa !5
  %94 = sext i32 %93 to i64
  %95 = getelementptr inbounds [200010 x %struct.Node], ptr @t, i64 0, i64 %94
  %96 = getelementptr inbounds %struct.Node, ptr %95, i32 0, i32 0
  store i32 %84, ptr %96, align 16, !tbaa !11
  %97 = load i32, ptr %6, align 4, !tbaa !5
  %98 = sext i32 %97 to i64
  %99 = getelementptr inbounds [200010 x i32], ptr @p, i64 0, i64 %98
  %100 = load i32, ptr %99, align 4, !tbaa !5
  call void @_Z5setchiii(i32 noundef %100, i32 noundef 0, i32 noundef 0)
  %101 = load i32, ptr %7, align 4, !tbaa !5
  %102 = sext i32 %101 to i64
  %103 = getelementptr inbounds [200010 x i32], ptr @p, i64 0, i64 %102
  %104 = load i32, ptr %103, align 4, !tbaa !5
  %105 = load i32, ptr %6, align 4, !tbaa !5
  %106 = sext i32 %105 to i64
  %107 = getelementptr inbounds [200010 x i32], ptr @p, i64 0, i64 %106
  %108 = load i32, ptr %107, align 4, !tbaa !5
  %109 = sext i32 %108 to i64
  %110 = getelementptr inbounds [200010 x %struct.Node], ptr @t, i64 0, i64 %109
  %111 = getelementptr inbounds %struct.Node, ptr %110, i32 0, i32 0
  store i32 %104, ptr %111, align 16, !tbaa !11
  br label %127

112:                                              ; preds = %58
  %113 = load i32, ptr %6, align 4, !tbaa !5
  %114 = sext i32 %113 to i64
  %115 = getelementptr inbounds [200010 x i32], ptr @p, i64 0, i64 %114
  %116 = load i32, ptr %115, align 4, !tbaa !5
  call void @_Z6accessi(i32 noundef %116)
  %117 = load i32, ptr %6, align 4, !tbaa !5
  %118 = sext i32 %117 to i64
  %119 = getelementptr inbounds [200010 x i32], ptr @p, i64 0, i64 %118
  %120 = load i32, ptr %119, align 4, !tbaa !5
  %121 = sext i32 %120 to i64
  %122 = getelementptr inbounds [200010 x %struct.Node], ptr @t, i64 0, i64 %121
  %123 = getelementptr inbounds %struct.Node, ptr %122, i32 0, i32 2
  %124 = load i32, ptr %123, align 4, !tbaa !14
  %125 = sub nsw i32 %124, 1
  %126 = call i32 (ptr, ...) @printf(ptr noundef @.str.2, i32 noundef %125)
  br label %127

127:                                              ; preds = %112, %72
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %6) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %5) #4
  br label %54, !llvm.loop !15

128:                                              ; preds = %54
  ret i32 0
}

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

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

attributes #0 = { 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 #1 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { 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 #3 = { "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 = { 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, !6, i64 0}
!12 = !{!"_ZTS4Node", !6, i64 0, !7, i64 4, !6, i64 12}
!13 = distinct !{!13, !10}
!14 = !{!12, !6, i64 12}
!15 = distinct !{!15, !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"

%struct.Node = type { i32, [2 x i32], i32 }

@t = external dso_local local_unnamed_addr global [200010 x %struct.Node], align 16
@n = external dso_local global i32, align 4
@m = external dso_local global i32, align 4
@p = external dso_local global [200010 x i32], align 16
@.str = external hidden unnamed_addr constant [3 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [5 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [4 x i8], align 1

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_Z5setchiii(i32 noundef, i32 noundef, i32 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 @_Z5splayi(i32 noundef) local_unnamed_addr #0

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_Z6accessi(i32 noundef) local_unnamed_addr #0

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_Z3addRi(ptr noundef nonnull align 4 dereferenceable(4)) local_unnamed_addr #0

; Function Attrs: mustprogress norecurse nounwind uwtable
define dso_local noundef i32 @main() local_unnamed_addr #2 {
  %1 = alloca i32, align 4
  %2 = alloca i32, align 4
  %3 = alloca i32, align 4
  %4 = alloca i32, align 4
  %5 = tail call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull @n)
  %6 = load i32, ptr @n, align 4, !tbaa !5
  %.not12 = icmp slt i32 %6, 0
  br i1 %.not12, label %._crit_edge.thread, label %.lr.ph

._crit_edge.thread:                               ; preds = %0
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %1) #5
  br label %._crit_edge17

._crit_edge:                                      ; preds = %.lr.ph
  %7 = icmp sgt i32 %9, 0
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %1) #5
  br i1 %7, label %.lr.ph16, label %._crit_edge17

.lr.ph:                                           ; preds = %0, %.lr.ph
  %indvars.iv = phi i64 [ %indvars.iv.next, %.lr.ph ], [ 0, %0 ]
  %8 = getelementptr inbounds [200010 x i32], ptr @p, i64 0, i64 %indvars.iv
  tail call void @_Z3addRi(ptr noundef nonnull align 4 dereferenceable(4) %8)
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %9 = load i32, ptr @n, align 4, !tbaa !5
  %10 = sext i32 %9 to i64
  %.not.not = icmp slt i64 %indvars.iv, %10
  br i1 %.not.not, label %.lr.ph, label %._crit_edge, !llvm.loop !9

._crit_edge17:                                    ; preds = %.lr.ph16, %._crit_edge.thread, %._crit_edge
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %1) #5
  %11 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull @m)
  %12 = load i32, ptr @m, align 4, !tbaa !5
  %13 = add nsw i32 %12, -1
  store i32 %13, ptr @m, align 4, !tbaa !5
  %.not1018 = icmp eq i32 %12, 0
  br i1 %.not1018, label %._crit_edge21, label %.lr.ph20

.lr.ph16:                                         ; preds = %._crit_edge, %.lr.ph16
  %indvars.iv23 = phi i64 [ %indvars.iv.next24, %.lr.ph16 ], [ 0, %._crit_edge ]
  %14 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull %1)
  %15 = load i32, ptr %1, align 4, !tbaa !5
  %16 = trunc nuw nsw i64 %indvars.iv23 to i32
  %17 = add nsw i32 %15, %16
  %18 = load i32, ptr @n, align 4, !tbaa !5
  %spec.store.select = call i32 @llvm.smin.i32(i32 %17, i32 %18)
  store i32 %spec.store.select, ptr %1, align 4
  %19 = sext i32 %spec.store.select to i64
  %20 = getelementptr inbounds [200010 x i32], ptr @p, i64 0, i64 %19
  %21 = load i32, ptr %20, align 4, !tbaa !5
  %22 = getelementptr inbounds [200010 x i32], ptr @p, i64 0, i64 %indvars.iv23
  %23 = load i32, ptr %22, align 4, !tbaa !5
  %24 = sext i32 %23 to i64
  %25 = getelementptr inbounds [200010 x %struct.Node], ptr @t, i64 0, i64 %24
  store i32 %21, ptr %25, align 16, !tbaa !11
  %indvars.iv.next24 = add nuw nsw i64 %indvars.iv23, 1
  %26 = sext i32 %18 to i64
  %27 = icmp slt i64 %indvars.iv.next24, %26
  br i1 %27, label %.lr.ph16, label %._crit_edge17, !llvm.loop !13

.lr.ph20:                                         ; preds = %._crit_edge17, %75
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %2) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %3) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %4) #5
  %28 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str.1, ptr noundef nonnull %2, ptr noundef nonnull %3)
  %29 = load i32, ptr %2, align 4, !tbaa !5
  %30 = icmp eq i32 %29, 2
  br i1 %30, label %31, label %61

31:                                               ; preds = %.lr.ph20
  %32 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull %4)
  %33 = load i32, ptr %3, align 4, !tbaa !5
  %34 = load i32, ptr %4, align 4, !tbaa !5
  %35 = add nsw i32 %34, %33
  %36 = load i32, ptr @n, align 4, !tbaa !5
  %spec.store.select11 = call i32 @llvm.smin.i32(i32 %35, i32 %36)
  store i32 %spec.store.select11, ptr %4, align 4
  %37 = sext i32 %33 to i64
  %38 = getelementptr inbounds [200010 x i32], ptr @p, i64 0, i64 %37
  %39 = load i32, ptr %38, align 4, !tbaa !5
  call void @_Z5splayi(i32 noundef %39)
  %40 = load i32, ptr %3, align 4, !tbaa !5
  %41 = sext i32 %40 to i64
  %42 = getelementptr inbounds [200010 x i32], ptr @p, i64 0, i64 %41
  %43 = load i32, ptr %42, align 4, !tbaa !5
  %44 = sext i32 %43 to i64
  %45 = getelementptr inbounds [200010 x %struct.Node], ptr @t, i64 0, i64 %44
  %46 = load i32, ptr %45, align 16, !tbaa !11
  %47 = getelementptr inbounds i8, ptr %45, i64 4
  %48 = load i32, ptr %47, align 4, !tbaa !5
  %49 = sext i32 %48 to i64
  %50 = getelementptr inbounds [200010 x %struct.Node], ptr @t, i64 0, i64 %49
  store i32 %46, ptr %50, align 16, !tbaa !11
  call void @_Z5setchiii(i32 noundef %43, i32 noundef 0, i32 noundef 0)
  %51 = load i32, ptr %4, align 4, !tbaa !5
  %52 = sext i32 %51 to i64
  %53 = getelementptr inbounds [200010 x i32], ptr @p, i64 0, i64 %52
  %54 = load i32, ptr %53, align 4, !tbaa !5
  %55 = load i32, ptr %3, align 4, !tbaa !5
  %56 = sext i32 %55 to i64
  %57 = getelementptr inbounds [200010 x i32], ptr @p, i64 0, i64 %56
  %58 = load i32, ptr %57, align 4, !tbaa !5
  %59 = sext i32 %58 to i64
  %60 = getelementptr inbounds [200010 x %struct.Node], ptr @t, i64 0, i64 %59
  store i32 %54, ptr %60, align 16, !tbaa !11
  br label %75

61:                                               ; preds = %.lr.ph20
  %62 = load i32, ptr %3, align 4, !tbaa !5
  %63 = sext i32 %62 to i64
  %64 = getelementptr inbounds [200010 x i32], ptr @p, i64 0, i64 %63
  %65 = load i32, ptr %64, align 4, !tbaa !5
  call void @_Z6accessi(i32 noundef %65)
  %66 = load i32, ptr %3, align 4, !tbaa !5
  %67 = sext i32 %66 to i64
  %68 = getelementptr inbounds [200010 x i32], ptr @p, i64 0, i64 %67
  %69 = load i32, ptr %68, align 4, !tbaa !5
  %70 = sext i32 %69 to i64
  %71 = getelementptr inbounds [200010 x %struct.Node], ptr @t, i64 0, i64 %70, i32 2
  %72 = load i32, ptr %71, align 4, !tbaa !14
  %73 = add nsw i32 %72, -1
  %74 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.2, i32 noundef %73)
  br label %75

75:                                               ; preds = %61, %31
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %4) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %3) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %2) #5
  %76 = load i32, ptr @m, align 4, !tbaa !5
  %77 = add nsw i32 %76, -1
  store i32 %77, ptr @m, align 4, !tbaa !5
  %.not10 = icmp eq i32 %76, 0
  br i1 %.not10, label %._crit_edge21, label %.lr.ph20, !llvm.loop !15

._crit_edge21:                                    ; preds = %75, %._crit_edge17
  ret i32 0
}

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

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

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

attributes #0 = { 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 #1 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { mustprogress 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 #3 = { 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 #4 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
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, !6, i64 0}
!12 = !{!"_ZTS4Node", !6, i64 0, !7, i64 4, !6, i64 12}
!13 = distinct !{!13, !10}
!14 = !{!12, !6, i64 12}
!15 = distinct !{!15, !10}


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