; LLVM IR from tangjz/acm-icpc :: uoj (117)

; 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, i32, i32, i32 }

@t = external dso_local global i32, align 4
@n = external dso_local global i32, align 4
@m = external dso_local global i32, align 4
@u = external dso_local global [200010 x i32], align 16
@v = external dso_local global [200010 x i32], align 16
@deg = external dso_local global [100010 x i32], align 16
@p = external dso_local global [100010 x i32], align 16
@ans = external dso_local global [200010 x i32], align 16
@e = external dso_local global [400020 x %struct.Node], align 16
@.str = external hidden unnamed_addr constant [7 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [5 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [5 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [3 x i8], align 1

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_Z3addi(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 uwtable
declare dso_local void @_Z3dfsii(i32 noundef, i32 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 i8, align 1
  %4 = alloca i32, align 4
  %5 = alloca i32, align 4
  %6 = alloca i32, align 4
  store i32 0, ptr %1, align 4
  %7 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef @t, ptr noundef @n, ptr noundef @m)
  call void @llvm.memset.p0.i64(ptr align 16 @p, i8 -1, i64 400040, i1 false)
  call void @llvm.lifetime.start.p0(i64 4, ptr %2) #6
  store i32 1, ptr %2, align 4, !tbaa !5
  br label %8

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

12:                                               ; preds = %8
  call void @llvm.lifetime.end.p0(i64 4, ptr %2) #6
  br label %54

13:                                               ; preds = %8
  %14 = load i32, ptr %2, align 4, !tbaa !5
  %15 = sext i32 %14 to i64
  %16 = getelementptr inbounds i32, ptr @u, i64 %15
  %17 = load i32, ptr %2, align 4, !tbaa !5
  %18 = sext i32 %17 to i64
  %19 = getelementptr inbounds i32, ptr @v, i64 %18
  %20 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str.1, ptr noundef %16, ptr noundef %19)
  %21 = load i32, ptr %2, align 4, !tbaa !5
  %22 = sext i32 %21 to i64
  %23 = getelementptr inbounds [200010 x i32], ptr @u, i64 0, i64 %22
  %24 = load i32, ptr %23, align 4, !tbaa !5
  %25 = sext i32 %24 to i64
  %26 = getelementptr inbounds [100010 x i32], ptr @deg, i64 0, i64 %25
  %27 = load i32, ptr %26, align 4, !tbaa !5
  %28 = add nsw i32 %27, 1
  store i32 %28, ptr %26, align 4, !tbaa !5
  %29 = load i32, ptr @t, align 4, !tbaa !5
  %30 = icmp eq i32 %29, 1
  br i1 %30, label %31, label %40

31:                                               ; preds = %13
  %32 = load i32, ptr %2, align 4, !tbaa !5
  %33 = sext i32 %32 to i64
  %34 = getelementptr inbounds [200010 x i32], ptr @v, i64 0, i64 %33
  %35 = load i32, ptr %34, align 4, !tbaa !5
  %36 = sext i32 %35 to i64
  %37 = getelementptr inbounds [100010 x i32], ptr @deg, i64 0, i64 %36
  %38 = load i32, ptr %37, align 4, !tbaa !5
  %39 = add nsw i32 %38, 1
  store i32 %39, ptr %37, align 4, !tbaa !5
  br label %49

40:                                               ; preds = %13
  %41 = load i32, ptr %2, align 4, !tbaa !5
  %42 = sext i32 %41 to i64
  %43 = getelementptr inbounds [200010 x i32], ptr @v, i64 0, i64 %42
  %44 = load i32, ptr %43, align 4, !tbaa !5
  %45 = sext i32 %44 to i64
  %46 = getelementptr inbounds [100010 x i32], ptr @deg, i64 0, i64 %45
  %47 = load i32, ptr %46, align 4, !tbaa !5
  %48 = add nsw i32 %47, -1
  store i32 %48, ptr %46, align 4, !tbaa !5
  br label %49

49:                                               ; preds = %40, %31
  %50 = load i32, ptr %2, align 4, !tbaa !5
  call void @_Z3addi(i32 noundef %50)
  br label %51

51:                                               ; preds = %49
  %52 = load i32, ptr %2, align 4, !tbaa !5
  %53 = add nsw i32 %52, 1
  store i32 %53, ptr %2, align 4, !tbaa !5
  br label %8, !llvm.loop !9

54:                                               ; preds = %12
  call void @llvm.lifetime.start.p0(i64 1, ptr %3) #6
  store i8 1, ptr %3, align 1, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 4, ptr %4) #6
  store i32 1, ptr %4, align 4, !tbaa !5
  br label %55

55:                                               ; preds = %81, %54
  %56 = load i32, ptr %4, align 4, !tbaa !5
  %57 = load i32, ptr @n, align 4, !tbaa !5
  %58 = icmp sle i32 %56, %57
  br i1 %58, label %60, label %59

59:                                               ; preds = %55
  store i32 5, ptr %5, align 4
  br label %84

60:                                               ; preds = %55
  %61 = load i32, ptr @t, align 4, !tbaa !5
  %62 = icmp eq i32 %61, 1
  br i1 %62, label %63, label %70

63:                                               ; preds = %60
  %64 = load i32, ptr %4, align 4, !tbaa !5
  %65 = sext i32 %64 to i64
  %66 = getelementptr inbounds [100010 x i32], ptr @deg, i64 0, i64 %65
  %67 = load i32, ptr %66, align 4, !tbaa !5
  %68 = and i32 %67, 1
  %69 = icmp ne i32 %68, 0
  br i1 %69, label %79, label %70

70:                                               ; preds = %63, %60
  %71 = load i32, ptr @t, align 4, !tbaa !5
  %72 = icmp eq i32 %71, 2
  br i1 %72, label %73, label %80

73:                                               ; preds = %70
  %74 = load i32, ptr %4, align 4, !tbaa !5
  %75 = sext i32 %74 to i64
  %76 = getelementptr inbounds [100010 x i32], ptr @deg, i64 0, i64 %75
  %77 = load i32, ptr %76, align 4, !tbaa !5
  %78 = icmp ne i32 %77, 0
  br i1 %78, label %79, label %80

79:                                               ; preds = %73, %63
  store i8 0, ptr %3, align 1, !tbaa !11
  store i32 5, ptr %5, align 4
  br label %84

80:                                               ; preds = %73, %70
  br label %81

81:                                               ; preds = %80
  %82 = load i32, ptr %4, align 4, !tbaa !5
  %83 = add nsw i32 %82, 1
  store i32 %83, ptr %4, align 4, !tbaa !5
  br label %55, !llvm.loop !13

84:                                               ; preds = %79, %59
  call void @llvm.lifetime.end.p0(i64 4, ptr %4) #6
  br label %85

85:                                               ; preds = %84
  %86 = load i8, ptr %3, align 1, !tbaa !11, !range !14, !noundef !15
  %87 = trunc i8 %86 to i1
  br i1 %87, label %90, label %88

88:                                               ; preds = %85
  %89 = call i32 @puts(ptr noundef @.str.2)
  store i32 0, ptr %1, align 4
  store i32 1, ptr %5, align 4
  br label %125

90:                                               ; preds = %85
  %91 = load i32, ptr getelementptr inbounds ([200010 x i32], ptr @u, i64 0, i64 1), align 4, !tbaa !5
  call void @_Z3dfsii(i32 noundef %91, i32 noundef -1)
  %92 = load i32, ptr @ans, align 16, !tbaa !5
  %93 = load i32, ptr @m, align 4, !tbaa !5
  %94 = add nsw i32 %93, 1
  %95 = icmp ne i32 %92, %94
  br i1 %95, label %96, label %98

96:                                               ; preds = %90
  %97 = call i32 @puts(ptr noundef @.str.2)
  store i32 0, ptr %1, align 4
  store i32 1, ptr %5, align 4
  br label %125

98:                                               ; preds = %90
  %99 = call i32 @puts(ptr noundef @.str.3)
  call void @llvm.lifetime.start.p0(i64 4, ptr %6) #6
  %100 = load i32, ptr @m, align 4, !tbaa !5
  store i32 %100, ptr %6, align 4, !tbaa !5
  br label %101

101:                                              ; preds = %121, %98
  %102 = load i32, ptr %6, align 4, !tbaa !5
  %103 = icmp sge i32 %102, 1
  br i1 %103, label %105, label %104

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

105:                                              ; preds = %101
  %106 = load i32, ptr %6, align 4, !tbaa !5
  %107 = sext i32 %106 to i64
  %108 = getelementptr inbounds [200010 x i32], ptr @ans, i64 0, i64 %107
  %109 = load i32, ptr %108, align 4, !tbaa !5
  %110 = sext i32 %109 to i64
  %111 = getelementptr inbounds [400020 x %struct.Node], ptr @e, i64 0, i64 %110
  %112 = getelementptr inbounds %struct.Node, ptr %111, i32 0, i32 3
  %113 = load i32, ptr %112, align 4, !tbaa !16
  %114 = load i32, ptr %6, align 4, !tbaa !5
  %115 = icmp eq i32 %114, 1
  %116 = zext i1 %115 to i64
  %117 = getelementptr inbounds [3 x i8], ptr @.str.5, i64 0, i64 %116
  %118 = load i8, ptr %117, align 1, !tbaa !18
  %119 = sext i8 %118 to i32
  %120 = call i32 (ptr, ...) @printf(ptr noundef @.str.4, i32 noundef %113, i32 noundef %119)
  br label %121

121:                                              ; preds = %105
  %122 = load i32, ptr %6, align 4, !tbaa !5
  %123 = add nsw i32 %122, -1
  store i32 %123, ptr %6, align 4, !tbaa !5
  br label %101, !llvm.loop !19

124:                                              ; preds = %104
  store i32 0, ptr %1, align 4
  store i32 1, ptr %5, align 4
  br label %125

125:                                              ; preds = %124, %96, %88
  call void @llvm.lifetime.end.p0(i64 1, ptr %3) #6
  %126 = load i32, ptr %1, align 4
  ret i32 %126
}

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

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

declare i32 @puts(ptr noundef) #4

declare i32 @printf(ptr noundef, ...) #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 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { 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 #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 = { "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 = { 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++ TBAA"}
!9 = distinct !{!9, !10}
!10 = !{!"llvm.loop.mustprogress"}
!11 = !{!12, !12, i64 0}
!12 = !{!"bool", !7, i64 0}
!13 = distinct !{!13, !10}
!14 = !{i8 0, i8 2}
!15 = !{}
!16 = !{!17, !6, i64 12}
!17 = !{!"_ZTS4Node", !6, i64 0, !6, i64 4, !6, i64 8, !6, i64 12}
!18 = !{!7, !7, i64 0}
!19 = distinct !{!19, !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, i32, i32, i32 }

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_Z3dfsii(i32 noundef, i32 noundef) local_unnamed_addr #1

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() local_unnamed_addr #2 {
  %1 = tail call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull @t, ptr noundef nonnull @n, ptr noundef nonnull @m)
  tail call void @llvm.memset.p0.i64(ptr noundef nonnull align 16 dereferenceable(400040) @p, i8 -1, i64 400040, i1 false)
  %2 = load i32, ptr @m, align 4, !tbaa !5
  %.not26 = icmp slt i32 %2, 1
  br i1 %.not26, label %.preheader, label %.lr.ph

.preheader:                                       ; preds = %.lr.ph, %0
  %3 = load i32, ptr @n, align 4, !tbaa !5
  %.not2228 = icmp slt i32 %3, 1
  br i1 %.not2228, label %.critedge, label %.lr.ph30

.lr.ph30:                                         ; preds = %.preheader
  %4 = load i32, ptr @t, align 4, !tbaa !5
  switch i32 %4, label %.critedge [
    i32 1, label %.lr.ph30.split.us.preheader
    i32 2, label %.lr.ph30.split.us31.preheader
  ]

.lr.ph30.split.us31.preheader:                    ; preds = %.lr.ph30
  %5 = add nuw i32 %3, 1
  %wide.trip.count = zext i32 %5 to i64
  br label %.lr.ph30.split.us31

.lr.ph30.split.us.preheader:                      ; preds = %.lr.ph30
  %6 = add nuw i32 %3, 1
  %wide.trip.count47 = zext i32 %6 to i64
  br label %.lr.ph30.split.us

.lr.ph30.split.us:                                ; preds = %.lr.ph30.split.us.preheader, %.thread.us
  %indvars.iv44 = phi i64 [ 1, %.lr.ph30.split.us.preheader ], [ %indvars.iv.next45, %.thread.us ]
  %7 = getelementptr inbounds [100010 x i32], ptr @deg, i64 0, i64 %indvars.iv44
  %8 = load i32, ptr %7, align 4, !tbaa !5
  %9 = and i32 %8, 1
  %.not23.us = icmp eq i32 %9, 0
  br i1 %.not23.us, label %.thread.us, label %.loopexit.sink.split

.thread.us:                                       ; preds = %.lr.ph30.split.us
  %indvars.iv.next45 = add nuw nsw i64 %indvars.iv44, 1
  %exitcond48.not = icmp eq i64 %indvars.iv.next45, %wide.trip.count47
  br i1 %exitcond48.not, label %.critedge, label %.lr.ph30.split.us, !llvm.loop !9

.lr.ph30.split.us31:                              ; preds = %.lr.ph30.split.us31.preheader, %.thread.us33
  %indvars.iv41 = phi i64 [ 1, %.lr.ph30.split.us31.preheader ], [ %indvars.iv.next42, %.thread.us33 ]
  %10 = getelementptr inbounds [100010 x i32], ptr @deg, i64 0, i64 %indvars.iv41
  %11 = load i32, ptr %10, align 4, !tbaa !5
  %.not24.us = icmp eq i32 %11, 0
  br i1 %.not24.us, label %.thread.us33, label %.loopexit.sink.split

.thread.us33:                                     ; preds = %.lr.ph30.split.us31
  %indvars.iv.next42 = add nuw nsw i64 %indvars.iv41, 1
  %exitcond.not = icmp eq i64 %indvars.iv.next42, %wide.trip.count
  br i1 %exitcond.not, label %.critedge, label %.lr.ph30.split.us31, !llvm.loop !9

.lr.ph:                                           ; preds = %0, %.lr.ph
  %indvars.iv = phi i64 [ %indvars.iv.next, %.lr.ph ], [ 1, %0 ]
  %12 = getelementptr inbounds i32, ptr @u, i64 %indvars.iv
  %13 = getelementptr inbounds i32, ptr @v, i64 %indvars.iv
  %14 = tail call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str.1, ptr noundef nonnull %12, ptr noundef nonnull %13)
  %15 = load i32, ptr %12, align 4, !tbaa !5
  %16 = sext i32 %15 to i64
  %17 = getelementptr inbounds [100010 x i32], ptr @deg, 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 = load i32, ptr @t, align 4, !tbaa !5
  %21 = icmp eq i32 %20, 1
  %22 = load i32, ptr %13, align 4, !tbaa !5
  %23 = sext i32 %22 to i64
  %24 = getelementptr inbounds [100010 x i32], ptr @deg, i64 0, i64 %23
  %25 = load i32, ptr %24, align 4, !tbaa !5
  %. = select i1 %21, i32 1, i32 -1
  %26 = add nsw i32 %25, %.
  store i32 %26, ptr %24, align 4, !tbaa !5
  %27 = trunc nuw nsw i64 %indvars.iv to i32
  tail call void @_Z3addi(i32 noundef %27)
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %28 = load i32, ptr @m, align 4, !tbaa !5
  %29 = sext i32 %28 to i64
  %.not.not = icmp slt i64 %indvars.iv, %29
  br i1 %.not.not, label %.lr.ph, label %.preheader, !llvm.loop !11

.critedge:                                        ; preds = %.thread.us33, %.thread.us, %.lr.ph30, %.preheader
  %30 = load i32, ptr getelementptr inbounds (i8, ptr @u, i64 4), align 4, !tbaa !5
  tail call void @_Z3dfsii(i32 noundef %30, i32 noundef -1)
  %31 = load i32, ptr @ans, align 16, !tbaa !5
  %32 = load i32, ptr @m, align 4, !tbaa !5
  %33 = add nsw i32 %32, 1
  %.not25 = icmp eq i32 %31, %33
  br i1 %.not25, label %34, label %.loopexit.sink.split

34:                                               ; preds = %.critedge
  %35 = tail call i32 @puts(ptr noundef nonnull dereferenceable(1) @.str.3)
  %36 = load i32, ptr @m, align 4, !tbaa !5
  %37 = icmp sgt i32 %36, 0
  br i1 %37, label %.lr.ph36.preheader, label %.loopexit

.lr.ph36.preheader:                               ; preds = %34
  %38 = zext nneg i32 %36 to i64
  br label %.lr.ph36

.lr.ph36:                                         ; preds = %.lr.ph36.preheader, %.lr.ph36
  %indvars.iv49 = phi i64 [ %38, %.lr.ph36.preheader ], [ %indvars.iv.next50, %.lr.ph36 ]
  %39 = getelementptr inbounds [200010 x i32], ptr @ans, i64 0, i64 %indvars.iv49
  %40 = load i32, ptr %39, align 4, !tbaa !5
  %41 = sext i32 %40 to i64
  %42 = getelementptr inbounds [400020 x %struct.Node], ptr @e, i64 0, i64 %41, i32 3
  %43 = load i32, ptr %42, align 4, !tbaa !12
  %44 = icmp eq i64 %indvars.iv49, 1
  %45 = zext i1 %44 to i64
  %46 = getelementptr inbounds [3 x i8], ptr @.str.5, i64 0, i64 %45
  %47 = load i8, ptr %46, align 1, !tbaa !14
  %48 = sext i8 %47 to i32
  %49 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.4, i32 noundef %43, i32 noundef %48)
  %indvars.iv.next50 = add nsw i64 %indvars.iv49, -1
  %50 = icmp ugt i64 %indvars.iv49, 1
  br i1 %50, label %.lr.ph36, label %.loopexit, !llvm.loop !15

.loopexit.sink.split:                             ; preds = %.lr.ph30.split.us31, %.lr.ph30.split.us, %.critedge
  %51 = tail call i32 @puts(ptr noundef nonnull dereferenceable(1) @.str.2)
  br label %.loopexit

.loopexit:                                        ; preds = %.lr.ph36, %.loopexit.sink.split, %34
  ret i32 0
}

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

; 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 @puts(ptr nocapture noundef readonly) local_unnamed_addr #3

; Function Attrs: nofree nounwind
declare noundef i32 @printf(ptr nocapture noundef readonly, ...) local_unnamed_addr #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 = { 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 #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 = { 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 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: write) }

!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 = distinct !{!11, !10}
!12 = !{!13, !6, i64 12}
!13 = !{!"_ZTS4Node", !6, i64 0, !6, i64 4, !6, i64 8, !6, i64 12}
!14 = !{!7, !7, i64 0}
!15 = distinct !{!15, !10}


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