; LLVM IR from tangjz/acm-icpc :: codechef/SNCKQL19 (CHEFPRMS)

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

@t = external dso_local global i32, align 4
@n = external dso_local global i32, align 4
@f = external dso_local global [3 x [201 x i8]], align 16
@.str = external hidden unnamed_addr constant [3 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [3 x i8], align 1

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

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

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

15:                                               ; preds = %11
  %16 = load i32, ptr %2, align 4, !tbaa !5
  %17 = sext i32 %16 to i64
  %18 = getelementptr inbounds [201 x i8], ptr @f, i64 0, i64 %17
  %19 = load i8, ptr %18, align 1, !tbaa !9, !range !11, !noundef !12
  %20 = trunc i8 %19 to i1
  br i1 %20, label %38, label %21

21:                                               ; preds = %15
  call void @llvm.lifetime.start.p0(i64 4, ptr %4) #3
  %22 = load i32, ptr %2, align 4, !tbaa !5
  %23 = load i32, ptr %2, align 4, !tbaa !5
  %24 = add nsw i32 %22, %23
  store i32 %24, ptr %4, align 4, !tbaa !5
  br label %25

25:                                               ; preds = %33, %21
  %26 = load i32, ptr %4, align 4, !tbaa !5
  %27 = icmp slt i32 %26, 201
  br i1 %27, label %29, label %28

28:                                               ; preds = %25
  store i32 5, ptr %3, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %4) #3
  br label %37

29:                                               ; preds = %25
  %30 = load i32, ptr %4, align 4, !tbaa !5
  %31 = sext i32 %30 to i64
  %32 = getelementptr inbounds [201 x i8], ptr @f, i64 0, i64 %31
  store i8 1, ptr %32, align 1, !tbaa !9
  br label %33

33:                                               ; preds = %29
  %34 = load i32, ptr %2, align 4, !tbaa !5
  %35 = load i32, ptr %4, align 4, !tbaa !5
  %36 = add nsw i32 %35, %34
  store i32 %36, ptr %4, align 4, !tbaa !5
  br label %25, !llvm.loop !13

37:                                               ; preds = %28
  br label %38

38:                                               ; preds = %37, %15
  %39 = load i32, ptr %2, align 4, !tbaa !5
  %40 = sext i32 %39 to i64
  %41 = getelementptr inbounds [201 x i8], ptr @f, i64 0, i64 %40
  %42 = load i8, ptr %41, align 1, !tbaa !9, !range !11, !noundef !12
  %43 = trunc i8 %42 to i1
  %44 = xor i1 %43, true
  %45 = load i32, ptr %2, align 4, !tbaa !5
  %46 = sext i32 %45 to i64
  %47 = getelementptr inbounds [201 x i8], ptr @f, i64 0, i64 %46
  %48 = zext i1 %44 to i8
  store i8 %48, ptr %47, align 1, !tbaa !9
  br label %49

49:                                               ; preds = %38
  %50 = load i32, ptr %2, align 4, !tbaa !5
  %51 = add nsw i32 %50, 1
  store i32 %51, ptr %2, align 4, !tbaa !5
  br label %11, !llvm.loop !15

52:                                               ; preds = %14
  call void @llvm.lifetime.start.p0(i64 4, ptr %5) #3
  store i32 1, ptr %5, align 4, !tbaa !5
  br label %53

53:                                               ; preds = %99, %52
  %54 = load i32, ptr %5, align 4, !tbaa !5
  %55 = icmp slt i32 %54, 201
  br i1 %55, label %57, label %56

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

57:                                               ; preds = %53
  %58 = load i32, ptr %5, align 4, !tbaa !5
  %59 = sext i32 %58 to i64
  %60 = getelementptr inbounds [201 x i8], ptr @f, i64 0, i64 %59
  %61 = load i8, ptr %60, align 1, !tbaa !9, !range !11, !noundef !12
  %62 = trunc i8 %61 to i1
  br i1 %62, label %63, label %98

63:                                               ; preds = %57
  call void @llvm.lifetime.start.p0(i64 4, ptr %6) #3
  %64 = load i32, ptr %5, align 4, !tbaa !5
  store i32 %64, ptr %6, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #3
  store i32 1, ptr %7, align 4, !tbaa !5
  br label %65

65:                                               ; preds = %91, %63
  %66 = load i32, ptr %6, align 4, !tbaa !5
  %67 = icmp slt i32 %66, 201
  br i1 %67, label %69, label %68

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

69:                                               ; preds = %65
  %70 = load i32, ptr %5, align 4, !tbaa !5
  %71 = load i32, ptr %7, align 4, !tbaa !5
  %72 = icmp ne i32 %70, %71
  br i1 %72, label %73, label %79

73:                                               ; preds = %69
  %74 = load i32, ptr %7, align 4, !tbaa !5
  %75 = sext i32 %74 to i64
  %76 = getelementptr inbounds [201 x i8], ptr @f, i64 0, i64 %75
  %77 = load i8, ptr %76, align 1, !tbaa !9, !range !11, !noundef !12
  %78 = trunc i8 %77 to i1
  br label %79

79:                                               ; preds = %73, %69
  %80 = phi i1 [ false, %69 ], [ %78, %73 ]
  %81 = zext i1 %80 to i32
  %82 = load i32, ptr %6, align 4, !tbaa !5
  %83 = sext i32 %82 to i64
  %84 = getelementptr inbounds [201 x i8], ptr getelementptr inbounds ([3 x [201 x i8]], ptr @f, i64 0, i64 1), i64 0, i64 %83
  %85 = load i8, ptr %84, align 1, !tbaa !9, !range !11, !noundef !12
  %86 = trunc i8 %85 to i1
  %87 = zext i1 %86 to i32
  %88 = or i32 %87, %81
  %89 = icmp ne i32 %88, 0
  %90 = zext i1 %89 to i8
  store i8 %90, ptr %84, align 1, !tbaa !9
  br label %91

91:                                               ; preds = %79
  %92 = load i32, ptr %5, align 4, !tbaa !5
  %93 = load i32, ptr %6, align 4, !tbaa !5
  %94 = add nsw i32 %93, %92
  store i32 %94, ptr %6, align 4, !tbaa !5
  %95 = load i32, ptr %7, align 4, !tbaa !5
  %96 = add nsw i32 %95, 1
  store i32 %96, ptr %7, align 4, !tbaa !5
  br label %65, !llvm.loop !16

97:                                               ; preds = %68
  br label %98

98:                                               ; preds = %97, %57
  br label %99

99:                                               ; preds = %98
  %100 = load i32, ptr %5, align 4, !tbaa !5
  %101 = add nsw i32 %100, 1
  store i32 %101, ptr %5, align 4, !tbaa !5
  br label %53, !llvm.loop !17

102:                                              ; preds = %56
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #3
  store i32 1, ptr %8, align 4, !tbaa !5
  br label %103

103:                                              ; preds = %142, %102
  %104 = load i32, ptr %8, align 4, !tbaa !5
  %105 = icmp slt i32 %104, 201
  br i1 %105, label %107, label %106

106:                                              ; preds = %103
  store i32 14, ptr %3, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #3
  br label %145

107:                                              ; preds = %103
  %108 = load i32, ptr %8, align 4, !tbaa !5
  %109 = sext i32 %108 to i64
  %110 = getelementptr inbounds [201 x i8], ptr getelementptr inbounds ([3 x [201 x i8]], ptr @f, i64 0, i64 1), i64 0, i64 %109
  %111 = load i8, ptr %110, align 1, !tbaa !9, !range !11, !noundef !12
  %112 = trunc i8 %111 to i1
  br i1 %112, label %113, label %141

113:                                              ; preds = %107
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #3
  %114 = load i32, ptr %8, align 4, !tbaa !5
  store i32 %114, ptr %9, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #3
  store i32 0, ptr %10, align 4, !tbaa !5
  br label %115

115:                                              ; preds = %135, %113
  %116 = load i32, ptr %9, align 4, !tbaa !5
  %117 = icmp slt i32 %116, 201
  br i1 %117, label %119, label %118

118:                                              ; preds = %115
  store i32 17, ptr %3, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #3
  br label %140

119:                                              ; preds = %115
  %120 = load i32, ptr %10, align 4, !tbaa !5
  %121 = sext i32 %120 to i64
  %122 = getelementptr inbounds [201 x i8], ptr getelementptr inbounds ([3 x [201 x i8]], ptr @f, i64 0, i64 1), i64 0, i64 %121
  %123 = load i8, ptr %122, align 1, !tbaa !9, !range !11, !noundef !12
  %124 = trunc i8 %123 to i1
  %125 = zext i1 %124 to i32
  %126 = load i32, ptr %9, align 4, !tbaa !5
  %127 = sext i32 %126 to i64
  %128 = getelementptr inbounds [201 x i8], ptr getelementptr inbounds ([3 x [201 x i8]], ptr @f, i64 0, i64 2), i64 0, i64 %127
  %129 = load i8, ptr %128, align 1, !tbaa !9, !range !11, !noundef !12
  %130 = trunc i8 %129 to i1
  %131 = zext i1 %130 to i32
  %132 = or i32 %131, %125
  %133 = icmp ne i32 %132, 0
  %134 = zext i1 %133 to i8
  store i8 %134, ptr %128, align 1, !tbaa !9
  br label %135

135:                                              ; preds = %119
  %136 = load i32, ptr %9, align 4, !tbaa !5
  %137 = add nsw i32 %136, 1
  store i32 %137, ptr %9, align 4, !tbaa !5
  %138 = load i32, ptr %10, align 4, !tbaa !5
  %139 = add nsw i32 %138, 1
  store i32 %139, ptr %10, align 4, !tbaa !5
  br label %115, !llvm.loop !18

140:                                              ; preds = %118
  br label %141

141:                                              ; preds = %140, %107
  br label %142

142:                                              ; preds = %141
  %143 = load i32, ptr %8, align 4, !tbaa !5
  %144 = add nsw i32 %143, 1
  store i32 %144, ptr %8, align 4, !tbaa !5
  br label %103, !llvm.loop !19

145:                                              ; preds = %106
  %146 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef @t)
  br label %147

147:                                              ; preds = %151, %145
  %148 = load i32, ptr @t, align 4, !tbaa !5
  %149 = add nsw i32 %148, -1
  store i32 %149, ptr @t, align 4, !tbaa !5
  %150 = icmp ne i32 %148, 0
  br i1 %150, label %151, label %161

151:                                              ; preds = %147
  %152 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef @n)
  %153 = load i32, ptr @n, align 4, !tbaa !5
  %154 = sext i32 %153 to i64
  %155 = getelementptr inbounds [201 x i8], ptr getelementptr inbounds ([3 x [201 x i8]], ptr @f, i64 0, i64 2), i64 0, i64 %154
  %156 = load i8, ptr %155, align 1, !tbaa !9, !range !11, !noundef !12
  %157 = trunc i8 %156 to i1
  %158 = zext i1 %157 to i64
  %159 = select i1 %157, ptr @.str.1, ptr @.str.2
  %160 = call i32 @puts(ptr noundef %159)
  br label %147, !llvm.loop !20

161:                                              ; preds = %147
  ret i32 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

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

declare i32 @puts(ptr noundef) #2

attributes #0 = { mustprogress norecurse uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { 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 = !{!10, !10, i64 0}
!10 = !{!"bool", !7, i64 0}
!11 = !{i8 0, i8 2}
!12 = !{}
!13 = distinct !{!13, !14}
!14 = !{!"llvm.loop.mustprogress"}
!15 = distinct !{!15, !14}
!16 = distinct !{!16, !14}
!17 = distinct !{!17, !14}
!18 = distinct !{!18, !14}
!19 = distinct !{!19, !14}
!20 = distinct !{!20, !14}


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

@t = external dso_local global i32, align 4
@n = external dso_local global i32, align 4
@f = external dso_local local_unnamed_addr global [3 x [201 x i8]], align 16
@.str = external hidden unnamed_addr constant [3 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [3 x i8], align 1

; Function Attrs: mustprogress nofree norecurse nounwind uwtable
define dso_local noundef i32 @main() local_unnamed_addr #0 {
  br label %1

1:                                                ; preds = %0, %.loopexit44
  %indvars.iv64 = phi i64 [ 2, %0 ], [ %indvars.iv.next65, %.loopexit44 ]
  %indvars.iv = phi i64 [ 4, %0 ], [ %indvars.iv.next, %.loopexit44 ]
  %2 = getelementptr inbounds [201 x i8], ptr @f, i64 0, i64 %indvars.iv64
  %3 = load i8, ptr %2, align 1, !tbaa !5, !range !9, !noundef !10
  %4 = trunc nuw i8 %3 to i1
  %5 = icmp ugt i64 %indvars.iv64, 100
  %or.cond.not = or i1 %5, %4
  br i1 %or.cond.not, label %.loopexit44, label %.lr.ph

.lr.ph:                                           ; preds = %1, %.lr.ph
  %indvars.iv66 = phi i64 [ %indvars.iv.next67, %.lr.ph ], [ %indvars.iv, %1 ]
  %6 = getelementptr inbounds [201 x i8], ptr @f, i64 0, i64 %indvars.iv66
  store i8 1, ptr %6, align 1, !tbaa !5
  %indvars.iv.next67 = add nuw nsw i64 %indvars.iv66, %indvars.iv64
  %7 = icmp ult i64 %indvars.iv.next67, 201
  br i1 %7, label %.lr.ph, label %.loopexit44.loopexit, !llvm.loop !11

.loopexit44.loopexit:                             ; preds = %.lr.ph
  %.pre = load i8, ptr %2, align 1, !tbaa !5, !range !9
  br label %.loopexit44

.loopexit44:                                      ; preds = %.loopexit44.loopexit, %1
  %8 = phi i8 [ %.pre, %.loopexit44.loopexit ], [ %3, %1 ]
  %9 = xor i8 %8, 1
  store i8 %9, ptr %2, align 1, !tbaa !5
  %indvars.iv.next65 = add nuw nsw i64 %indvars.iv64, 1
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 2
  %exitcond.not = icmp eq i64 %indvars.iv.next65, 201
  br i1 %exitcond.not, label %.preheader43, label %1, !llvm.loop !13

.preheader43:                                     ; preds = %.loopexit44, %.loopexit42
  %indvars.iv72 = phi i64 [ %indvars.iv.next73, %.loopexit42 ], [ 1, %.loopexit44 ]
  %10 = getelementptr inbounds [201 x i8], ptr @f, i64 0, i64 %indvars.iv72
  %11 = load i8, ptr %10, align 1, !tbaa !5, !range !9, !noundef !10
  %12 = trunc nuw i8 %11 to i1
  br i1 %12, label %.lr.ph49, label %.loopexit42

.lr.ph49:                                         ; preds = %.preheader43, %16
  %indvars.iv74 = phi i64 [ %indvars.iv.next75, %16 ], [ %indvars.iv72, %.preheader43 ]
  %indvars.iv70 = phi i64 [ %indvars.iv.next71, %16 ], [ 1, %.preheader43 ]
  %.not39 = icmp eq i64 %indvars.iv72, %indvars.iv70
  br i1 %.not39, label %16, label %13

13:                                               ; preds = %.lr.ph49
  %14 = getelementptr inbounds [201 x i8], ptr @f, i64 0, i64 %indvars.iv70
  %15 = load i8, ptr %14, align 1, !tbaa !5, !range !9, !noundef !10
  br label %16

16:                                               ; preds = %13, %.lr.ph49
  %17 = phi i8 [ 0, %.lr.ph49 ], [ %15, %13 ]
  %18 = getelementptr inbounds [201 x i8], ptr getelementptr inbounds (i8, ptr @f, i64 201), i64 0, i64 %indvars.iv74
  %19 = load i8, ptr %18, align 1, !tbaa !5, !range !9, !noundef !10
  %20 = or i8 %19, %17
  store i8 %20, ptr %18, align 1, !tbaa !5
  %indvars.iv.next75 = add nuw nsw i64 %indvars.iv74, %indvars.iv72
  %indvars.iv.next71 = add nuw nsw i64 %indvars.iv70, 1
  %21 = icmp ult i64 %indvars.iv.next75, 201
  br i1 %21, label %.lr.ph49, label %.loopexit42, !llvm.loop !14

.loopexit42:                                      ; preds = %16, %.preheader43
  %indvars.iv.next73 = add nuw nsw i64 %indvars.iv72, 1
  %exitcond80.not = icmp eq i64 %indvars.iv.next73, 201
  br i1 %exitcond80.not, label %.preheader40, label %.preheader43, !llvm.loop !15

22:                                               ; preds = %.loopexit
  %23 = tail call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull @t)
  %24 = load i32, ptr @t, align 4, !tbaa !16
  %25 = add nsw i32 %24, -1
  store i32 %25, ptr @t, align 4, !tbaa !16
  %.not57 = icmp eq i32 %24, 0
  br i1 %.not57, label %._crit_edge, label %.lr.ph58

.preheader40:                                     ; preds = %.loopexit42, %.loopexit
  %indvars.iv93 = phi i64 [ %indvars.iv.next94, %.loopexit ], [ 200, %.loopexit42 ]
  %indvars.iv83 = phi i64 [ %indvars.iv.next84, %.loopexit ], [ 1, %.loopexit42 ]
  %26 = getelementptr inbounds [201 x i8], ptr getelementptr inbounds (i8, ptr @f, i64 201), i64 0, i64 %indvars.iv83
  %27 = load i8, ptr %26, align 1, !tbaa !5, !range !9, !noundef !10
  %28 = trunc nuw i8 %27 to i1
  br i1 %28, label %iter.check, label %.loopexit

iter.check:                                       ; preds = %.preheader40
  %min.iters.check = icmp ult i64 %indvars.iv93, 8
  br i1 %min.iters.check, label %.lr.ph54.preheader, label %vector.main.loop.iter.check

vector.main.loop.iter.check:                      ; preds = %iter.check
  %min.iters.check99 = icmp ult i64 %indvars.iv93, 32
  br i1 %min.iters.check99, label %vec.epilog.ph, label %vector.ph

vector.ph:                                        ; preds = %vector.main.loop.iter.check
  %n.vec = and i64 %indvars.iv93, -32
  br label %vector.body

vector.body:                                      ; preds = %vector.body, %vector.ph
  %index = phi i64 [ 0, %vector.ph ], [ %index.next, %vector.body ]
  %offset.idx = add i64 %indvars.iv83, %index
  %29 = getelementptr inbounds [201 x i8], ptr getelementptr inbounds (i8, ptr @f, i64 201), i64 0, i64 %index
  %30 = getelementptr inbounds i8, ptr %29, i64 16
  %wide.load = load <16 x i8>, ptr %29, align 1, !tbaa !5
  %wide.load100 = load <16 x i8>, ptr %30, align 1, !tbaa !5
  %31 = getelementptr inbounds [201 x i8], ptr getelementptr inbounds (i8, ptr @f, i64 402), i64 0, i64 %offset.idx
  %32 = getelementptr inbounds i8, ptr %31, i64 16
  %wide.load101 = load <16 x i8>, ptr %31, align 1, !tbaa !5
  %wide.load102 = load <16 x i8>, ptr %32, align 1, !tbaa !5
  %33 = or <16 x i8> %wide.load101, %wide.load
  %34 = or <16 x i8> %wide.load102, %wide.load100
  store <16 x i8> %33, ptr %31, align 1, !tbaa !5
  store <16 x i8> %34, ptr %32, align 1, !tbaa !5
  %index.next = add nuw i64 %index, 32
  %35 = icmp eq i64 %index.next, %n.vec
  br i1 %35, label %middle.block, label %vector.body, !llvm.loop !18

middle.block:                                     ; preds = %vector.body
  %cmp.n = icmp eq i64 %indvars.iv93, %n.vec
  br i1 %cmp.n, label %.loopexit, label %vec.epilog.iter.check

vec.epilog.iter.check:                            ; preds = %middle.block
  %ind.end105 = add i64 %indvars.iv83, %n.vec
  %n.vec.remaining = and i64 %indvars.iv93, 24
  %min.epilog.iters.check = icmp eq i64 %n.vec.remaining, 0
  br i1 %min.epilog.iters.check, label %.lr.ph54.preheader, label %vec.epilog.ph

vec.epilog.ph:                                    ; preds = %vector.main.loop.iter.check, %vec.epilog.iter.check
  %vec.epilog.resume.val = phi i64 [ %n.vec, %vec.epilog.iter.check ], [ 0, %vector.main.loop.iter.check ]
  %n.vec104 = and i64 %indvars.iv93, -8
  %ind.end = add i64 %indvars.iv83, %n.vec104
  br label %vec.epilog.vector.body

vec.epilog.vector.body:                           ; preds = %vec.epilog.vector.body, %vec.epilog.ph
  %index107 = phi i64 [ %vec.epilog.resume.val, %vec.epilog.ph ], [ %index.next111, %vec.epilog.vector.body ]
  %offset.idx108 = add i64 %indvars.iv83, %index107
  %36 = getelementptr inbounds [201 x i8], ptr getelementptr inbounds (i8, ptr @f, i64 201), i64 0, i64 %index107
  %wide.load109 = load <8 x i8>, ptr %36, align 1, !tbaa !5
  %37 = getelementptr inbounds [201 x i8], ptr getelementptr inbounds (i8, ptr @f, i64 402), i64 0, i64 %offset.idx108
  %wide.load110 = load <8 x i8>, ptr %37, align 1, !tbaa !5
  %38 = or <8 x i8> %wide.load110, %wide.load109
  store <8 x i8> %38, ptr %37, align 1, !tbaa !5
  %index.next111 = add nuw i64 %index107, 8
  %39 = icmp eq i64 %index.next111, %n.vec104
  br i1 %39, label %vec.epilog.middle.block, label %vec.epilog.vector.body, !llvm.loop !21

vec.epilog.middle.block:                          ; preds = %vec.epilog.vector.body
  %cmp.n112 = icmp eq i64 %indvars.iv93, %n.vec104
  br i1 %cmp.n112, label %.loopexit, label %.lr.ph54.preheader

.lr.ph54.preheader:                               ; preds = %vec.epilog.middle.block, %iter.check, %vec.epilog.iter.check
  %indvars.iv85.ph = phi i64 [ %indvars.iv83, %iter.check ], [ %ind.end105, %vec.epilog.iter.check ], [ %ind.end, %vec.epilog.middle.block ]
  %indvars.iv81.ph = phi i64 [ 0, %iter.check ], [ %n.vec, %vec.epilog.iter.check ], [ %n.vec104, %vec.epilog.middle.block ]
  br label %.lr.ph54

.lr.ph54:                                         ; preds = %.lr.ph54.preheader, %.lr.ph54
  %indvars.iv85 = phi i64 [ %indvars.iv.next86, %.lr.ph54 ], [ %indvars.iv85.ph, %.lr.ph54.preheader ]
  %indvars.iv81 = phi i64 [ %indvars.iv.next82, %.lr.ph54 ], [ %indvars.iv81.ph, %.lr.ph54.preheader ]
  %40 = getelementptr inbounds [201 x i8], ptr getelementptr inbounds (i8, ptr @f, i64 201), i64 0, i64 %indvars.iv81
  %41 = load i8, ptr %40, align 1, !tbaa !5, !range !9, !noundef !10
  %42 = getelementptr inbounds [201 x i8], ptr getelementptr inbounds (i8, ptr @f, i64 402), i64 0, i64 %indvars.iv85
  %43 = load i8, ptr %42, align 1, !tbaa !5, !range !9, !noundef !10
  %44 = or i8 %43, %41
  store i8 %44, ptr %42, align 1, !tbaa !5
  %indvars.iv.next86 = add nuw nsw i64 %indvars.iv85, 1
  %indvars.iv.next82 = add nuw nsw i64 %indvars.iv81, 1
  %exitcond92.not = icmp eq i64 %indvars.iv.next82, %indvars.iv93
  br i1 %exitcond92.not, label %.loopexit, label %.lr.ph54, !llvm.loop !22

.loopexit:                                        ; preds = %.lr.ph54, %middle.block, %vec.epilog.middle.block, %.preheader40
  %indvars.iv.next84 = add nuw nsw i64 %indvars.iv83, 1
  %indvars.iv.next94 = add nsw i64 %indvars.iv93, -1
  %exitcond98.not = icmp eq i64 %indvars.iv.next84, 201
  br i1 %exitcond98.not, label %22, label %.preheader40, !llvm.loop !23

.lr.ph58:                                         ; preds = %22, %.lr.ph58
  %45 = tail call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull @n)
  %46 = load i32, ptr @n, align 4, !tbaa !16
  %47 = sext i32 %46 to i64
  %48 = getelementptr inbounds [201 x i8], ptr getelementptr inbounds (i8, ptr @f, i64 402), i64 0, i64 %47
  %49 = load i8, ptr %48, align 1, !tbaa !5, !range !9, !noundef !10
  %50 = trunc nuw i8 %49 to i1
  %51 = select i1 %50, ptr @.str.1, ptr @.str.2
  %52 = tail call i32 @puts(ptr noundef nonnull dereferenceable(1) %51)
  %53 = load i32, ptr @t, align 4, !tbaa !16
  %54 = add nsw i32 %53, -1
  store i32 %54, ptr @t, align 4, !tbaa !16
  %.not = icmp eq i32 %53, 0
  br i1 %.not, label %._crit_edge, label %.lr.ph58, !llvm.loop !24

._crit_edge:                                      ; preds = %.lr.ph58, %22
  ret i32 0
}

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

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

attributes #0 = { mustprogress nofree 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 #1 = { 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" }

!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 = !{!"bool", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{i8 0, i8 2}
!10 = !{}
!11 = distinct !{!11, !12}
!12 = !{!"llvm.loop.mustprogress"}
!13 = distinct !{!13, !12}
!14 = distinct !{!14, !12}
!15 = distinct !{!15, !12}
!16 = !{!17, !17, i64 0}
!17 = !{!"int", !7, i64 0}
!18 = distinct !{!18, !12, !19, !20}
!19 = !{!"llvm.loop.isvectorized", i32 1}
!20 = !{!"llvm.loop.unroll.runtime.disable"}
!21 = distinct !{!21, !12, !19, !20}
!22 = distinct !{!22, !12, !20, !19}
!23 = distinct !{!23, !12}
!24 = distinct !{!24, !12}


; Effective O3 passes: EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferFunctionAttrsPass,InstCombinePass,JumpThreadingPass,LoopLoadEliminationPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,LoopVectorizePass,PostOrderFunctionAttrsPass,ReassociatePass,SROAPass,SimplifyCFGPass,TailCallElimPass