; LLVM IR from bqi343/cp-notebook :: Contests/USACO Solutions/2013-14/Jan 2014/14 Jan G2.ll (Z4testi)

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

@M = external dso_local global i32, align 4
@N = external dso_local global i32, align 4
@a = external dso_local global [100 x [100 x i32]], align 16
@A = external dso_local global [100 x [100 x i32]], align 16
@done = external dso_local global [100 x [100 x i32]], align 16
@.str = external hidden unnamed_addr constant [13 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [108 x i8], align 1
@__PRETTY_FUNCTION__._Z4testi = external hidden unnamed_addr constant [15 x i8], align 1

; Function Attrs: mustprogress nounwind uwtable
define dso_local noundef zeroext i1 @_Z4testi(i32 noundef %0) #0 {
  %2 = alloca i1, align 1
  %3 = alloca i32, align 4
  %4 = alloca i32, align 4
  %5 = alloca i32, align 4
  %6 = alloca i32, align 4
  %7 = alloca i8, align 1
  %8 = alloca i32, align 4
  %9 = alloca i32, align 4
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  %13 = alloca i32, align 4
  %14 = alloca i32, align 4
  %15 = alloca i8, align 1
  %16 = alloca i32, align 4
  %17 = alloca i32, align 4
  store i32 %0, ptr %3, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %4) #3
  store i32 0, ptr %4, align 4, !tbaa !5
  br label %18

18:                                               ; preds = %65, %1
  %19 = load i32, ptr %4, align 4, !tbaa !5
  %20 = load i32, ptr @M, align 4, !tbaa !5
  %21 = icmp slt i32 %19, %20
  br i1 %21, label %23, label %22

22:                                               ; preds = %18
  store i32 2, ptr %5, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %4) #3
  br label %68

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

24:                                               ; preds = %61, %23
  %25 = load i32, ptr %6, align 4, !tbaa !5
  %26 = load i32, ptr @N, align 4, !tbaa !5
  %27 = icmp slt i32 %25, %26
  br i1 %27, label %29, label %28

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

29:                                               ; preds = %24
  %30 = load i32, ptr %4, align 4, !tbaa !5
  %31 = sext i32 %30 to i64
  %32 = getelementptr inbounds [100 x [100 x i32]], ptr @a, i64 0, i64 %31
  %33 = load i32, ptr %6, align 4, !tbaa !5
  %34 = sext i32 %33 to i64
  %35 = getelementptr inbounds [100 x i32], ptr %32, i64 0, i64 %34
  %36 = load i32, ptr %35, align 4, !tbaa !5
  %37 = load i32, ptr %4, align 4, !tbaa !5
  %38 = sext i32 %37 to i64
  %39 = getelementptr inbounds [100 x [100 x i32]], ptr @A, i64 0, i64 %38
  %40 = load i32, ptr %6, align 4, !tbaa !5
  %41 = sext i32 %40 to i64
  %42 = getelementptr inbounds [100 x i32], ptr %39, i64 0, i64 %41
  store i32 %36, ptr %42, align 4, !tbaa !5
  %43 = load i32, ptr %4, align 4, !tbaa !5
  %44 = sext i32 %43 to i64
  %45 = getelementptr inbounds [100 x [100 x i32]], ptr @A, i64 0, i64 %44
  %46 = load i32, ptr %6, align 4, !tbaa !5
  %47 = sext i32 %46 to i64
  %48 = getelementptr inbounds [100 x i32], ptr %45, i64 0, i64 %47
  %49 = load i32, ptr %48, align 4, !tbaa !5
  %50 = icmp ne i32 %49, 0
  br i1 %50, label %51, label %52

51:                                               ; preds = %29
  br label %54

52:                                               ; preds = %29
  call void @__assert_fail(ptr noundef @.str, ptr noundef @.str.1, i32 noundef 33, ptr noundef @__PRETTY_FUNCTION__._Z4testi) #4
  unreachable

53:                                               ; No predecessors!
  br label %54

54:                                               ; preds = %53, %51
  %55 = load i32, ptr %4, align 4, !tbaa !5
  %56 = sext i32 %55 to i64
  %57 = getelementptr inbounds [100 x [100 x i32]], ptr @done, i64 0, i64 %56
  %58 = load i32, ptr %6, align 4, !tbaa !5
  %59 = sext i32 %58 to i64
  %60 = getelementptr inbounds [100 x i32], ptr %57, i64 0, i64 %59
  store i32 0, ptr %60, align 4, !tbaa !5
  br label %61

61:                                               ; preds = %54
  %62 = load i32, ptr %6, align 4, !tbaa !5
  %63 = add nsw i32 %62, 1
  store i32 %63, ptr %6, align 4, !tbaa !5
  br label %24, !llvm.loop !9

64:                                               ; preds = %28
  br label %65

65:                                               ; preds = %64
  %66 = load i32, ptr %4, align 4, !tbaa !5
  %67 = add nsw i32 %66, 1
  store i32 %67, ptr %4, align 4, !tbaa !5
  br label %18, !llvm.loop !11

68:                                               ; preds = %22
  call void @llvm.lifetime.start.p0(i64 1, ptr %7) #3
  store i8 1, ptr %7, align 1, !tbaa !12
  br label %69

69:                                               ; preds = %243, %68
  %70 = load i8, ptr %7, align 1, !tbaa !12, !range !14, !noundef !15
  %71 = trunc i8 %70 to i1
  br i1 %71, label %72, label %244

72:                                               ; preds = %69
  store i8 0, ptr %7, align 1, !tbaa !12
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #3
  store i32 0, ptr %8, align 4, !tbaa !5
  br label %73

73:                                               ; preds = %203, %72
  %74 = load i32, ptr %8, align 4, !tbaa !5
  %75 = load i32, ptr @M, align 4, !tbaa !5
  %76 = load i32, ptr %3, align 4, !tbaa !5
  %77 = sub nsw i32 %75, %76
  %78 = add nsw i32 %77, 1
  %79 = icmp slt i32 %74, %78
  br i1 %79, label %81, label %80

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

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

82:                                               ; preds = %199, %81
  %83 = load i32, ptr %9, align 4, !tbaa !5
  %84 = load i32, ptr @N, align 4, !tbaa !5
  %85 = load i32, ptr %3, align 4, !tbaa !5
  %86 = sub nsw i32 %84, %85
  %87 = add nsw i32 %86, 1
  %88 = icmp slt i32 %83, %87
  br i1 %88, label %90, label %89

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

90:                                               ; preds = %82
  %91 = load i32, ptr %8, align 4, !tbaa !5
  %92 = sext i32 %91 to i64
  %93 = getelementptr inbounds [100 x [100 x i32]], ptr @done, i64 0, i64 %92
  %94 = load i32, ptr %9, align 4, !tbaa !5
  %95 = sext i32 %94 to i64
  %96 = getelementptr inbounds [100 x i32], ptr %93, i64 0, i64 %95
  %97 = load i32, ptr %96, align 4, !tbaa !5
  %98 = icmp ne i32 %97, 0
  br i1 %98, label %198, label %99

99:                                               ; preds = %90
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #3
  store i32 0, ptr %10, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #3
  %100 = load i32, ptr %8, align 4, !tbaa !5
  store i32 %100, ptr %11, align 4, !tbaa !5
  br label %101

101:                                              ; preds = %151, %99
  %102 = load i32, ptr %11, align 4, !tbaa !5
  %103 = load i32, ptr %8, align 4, !tbaa !5
  %104 = load i32, ptr %3, align 4, !tbaa !5
  %105 = add nsw i32 %103, %104
  %106 = icmp slt i32 %102, %105
  br i1 %106, label %108, label %107

107:                                              ; preds = %101
  store i32 16, ptr %5, align 4
  br label %154

108:                                              ; preds = %101
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #3
  %109 = load i32, ptr %9, align 4, !tbaa !5
  store i32 %109, ptr %12, align 4, !tbaa !5
  br label %110

110:                                              ; preds = %142, %108
  %111 = load i32, ptr %12, align 4, !tbaa !5
  %112 = load i32, ptr %9, align 4, !tbaa !5
  %113 = load i32, ptr %3, align 4, !tbaa !5
  %114 = add nsw i32 %112, %113
  %115 = icmp slt i32 %111, %114
  br i1 %115, label %117, label %116

116:                                              ; preds = %110
  store i32 19, ptr %5, align 4
  br label %145

117:                                              ; preds = %110
  %118 = load i32, ptr %11, align 4, !tbaa !5
  %119 = sext i32 %118 to i64
  %120 = getelementptr inbounds [100 x [100 x i32]], ptr @A, i64 0, i64 %119
  %121 = load i32, ptr %12, align 4, !tbaa !5
  %122 = sext i32 %121 to i64
  %123 = getelementptr inbounds [100 x i32], ptr %120, i64 0, i64 %122
  %124 = load i32, ptr %123, align 4, !tbaa !5
  %125 = icmp ne i32 %124, 0
  br i1 %125, label %126, label %141

126:                                              ; preds = %117
  %127 = load i32, ptr %11, align 4, !tbaa !5
  %128 = sext i32 %127 to i64
  %129 = getelementptr inbounds [100 x [100 x i32]], ptr @A, i64 0, i64 %128
  %130 = load i32, ptr %12, align 4, !tbaa !5
  %131 = sext i32 %130 to i64
  %132 = getelementptr inbounds [100 x i32], ptr %129, i64 0, i64 %131
  %133 = load i32, ptr %132, align 4, !tbaa !5
  %134 = shl i32 1, %133
  %135 = load i32, ptr %10, align 4, !tbaa !5
  %136 = or i32 %135, %134
  store i32 %136, ptr %10, align 4, !tbaa !5
  %137 = load i32, ptr %10, align 4, !tbaa !5
  %138 = icmp eq i32 %137, 6
  br i1 %138, label %139, label %140

139:                                              ; preds = %126
  store i32 19, ptr %5, align 4
  br label %145

140:                                              ; preds = %126
  br label %141

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

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

145:                                              ; preds = %139, %116
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #3
  br label %146

146:                                              ; preds = %145
  %147 = load i32, ptr %10, align 4, !tbaa !5
  %148 = icmp eq i32 %147, 6
  br i1 %148, label %149, label %150

149:                                              ; preds = %146
  store i32 16, ptr %5, align 4
  br label %154

150:                                              ; preds = %146
  br label %151

151:                                              ; preds = %150
  %152 = load i32, ptr %11, align 4, !tbaa !5
  %153 = add nsw i32 %152, 1
  store i32 %153, ptr %11, align 4, !tbaa !5
  br label %101, !llvm.loop !17

154:                                              ; preds = %149, %107
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #3
  br label %155

155:                                              ; preds = %154
  %156 = load i32, ptr %10, align 4, !tbaa !5
  %157 = icmp ne i32 %156, 6
  br i1 %157, label %158, label %197

158:                                              ; preds = %155
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #3
  %159 = load i32, ptr %8, align 4, !tbaa !5
  store i32 %159, ptr %13, align 4, !tbaa !5
  br label %160

160:                                              ; preds = %187, %158
  %161 = load i32, ptr %13, align 4, !tbaa !5
  %162 = load i32, ptr %8, align 4, !tbaa !5
  %163 = load i32, ptr %3, align 4, !tbaa !5
  %164 = add nsw i32 %162, %163
  %165 = icmp slt i32 %161, %164
  br i1 %165, label %167, label %166

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

167:                                              ; preds = %160
  call void @llvm.lifetime.start.p0(i64 4, ptr %14) #3
  %168 = load i32, ptr %9, align 4, !tbaa !5
  store i32 %168, ptr %14, align 4, !tbaa !5
  br label %169

169:                                              ; preds = %183, %167
  %170 = load i32, ptr %14, align 4, !tbaa !5
  %171 = load i32, ptr %9, align 4, !tbaa !5
  %172 = load i32, ptr %3, align 4, !tbaa !5
  %173 = add nsw i32 %171, %172
  %174 = icmp slt i32 %170, %173
  br i1 %174, label %176, label %175

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

176:                                              ; preds = %169
  %177 = load i32, ptr %13, align 4, !tbaa !5
  %178 = sext i32 %177 to i64
  %179 = getelementptr inbounds [100 x [100 x i32]], ptr @A, i64 0, i64 %178
  %180 = load i32, ptr %14, align 4, !tbaa !5
  %181 = sext i32 %180 to i64
  %182 = getelementptr inbounds [100 x i32], ptr %179, i64 0, i64 %181
  store i32 0, ptr %182, align 4, !tbaa !5
  br label %183

183:                                              ; preds = %176
  %184 = load i32, ptr %14, align 4, !tbaa !5
  %185 = add nsw i32 %184, 1
  store i32 %185, ptr %14, align 4, !tbaa !5
  br label %169, !llvm.loop !18

186:                                              ; preds = %175
  br label %187

187:                                              ; preds = %186
  %188 = load i32, ptr %13, align 4, !tbaa !5
  %189 = add nsw i32 %188, 1
  store i32 %189, ptr %13, align 4, !tbaa !5
  br label %160, !llvm.loop !19

190:                                              ; preds = %166
  %191 = load i32, ptr %8, align 4, !tbaa !5
  %192 = sext i32 %191 to i64
  %193 = getelementptr inbounds [100 x [100 x i32]], ptr @done, i64 0, i64 %192
  %194 = load i32, ptr %9, align 4, !tbaa !5
  %195 = sext i32 %194 to i64
  %196 = getelementptr inbounds [100 x i32], ptr %193, i64 0, i64 %195
  store i32 1, ptr %196, align 4, !tbaa !5
  store i8 1, ptr %7, align 1, !tbaa !12
  br label %197

197:                                              ; preds = %190, %155
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #3
  br label %198

198:                                              ; preds = %197, %90
  br label %199

199:                                              ; preds = %198
  %200 = load i32, ptr %9, align 4, !tbaa !5
  %201 = add nsw i32 %200, 1
  store i32 %201, ptr %9, align 4, !tbaa !5
  br label %82, !llvm.loop !20

202:                                              ; preds = %89
  br label %203

203:                                              ; preds = %202
  %204 = load i32, ptr %8, align 4, !tbaa !5
  %205 = add nsw i32 %204, 1
  store i32 %205, ptr %8, align 4, !tbaa !5
  br label %73, !llvm.loop !21

206:                                              ; preds = %80
  call void @llvm.lifetime.start.p0(i64 1, ptr %15) #3
  store i8 1, ptr %15, align 1, !tbaa !12
  call void @llvm.lifetime.start.p0(i64 4, ptr %16) #3
  store i32 0, ptr %16, align 4, !tbaa !5
  br label %207

207:                                              ; preds = %233, %206
  %208 = load i32, ptr %16, align 4, !tbaa !5
  %209 = load i32, ptr @M, align 4, !tbaa !5
  %210 = icmp slt i32 %208, %209
  br i1 %210, label %212, label %211

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

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

213:                                              ; preds = %229, %212
  %214 = load i32, ptr %17, align 4, !tbaa !5
  %215 = load i32, ptr @N, align 4, !tbaa !5
  %216 = icmp slt i32 %214, %215
  br i1 %216, label %218, label %217

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

218:                                              ; preds = %213
  %219 = load i32, ptr %16, align 4, !tbaa !5
  %220 = sext i32 %219 to i64
  %221 = getelementptr inbounds [100 x [100 x i32]], ptr @A, i64 0, i64 %220
  %222 = load i32, ptr %17, align 4, !tbaa !5
  %223 = sext i32 %222 to i64
  %224 = getelementptr inbounds [100 x i32], ptr %221, i64 0, i64 %223
  %225 = load i32, ptr %224, align 4, !tbaa !5
  %226 = icmp ne i32 %225, 0
  br i1 %226, label %227, label %228

227:                                              ; preds = %218
  store i8 0, ptr %15, align 1, !tbaa !12
  br label %228

228:                                              ; preds = %227, %218
  br label %229

229:                                              ; preds = %228
  %230 = load i32, ptr %17, align 4, !tbaa !5
  %231 = add nsw i32 %230, 1
  store i32 %231, ptr %17, align 4, !tbaa !5
  br label %213, !llvm.loop !22

232:                                              ; preds = %217
  br label %233

233:                                              ; preds = %232
  %234 = load i32, ptr %16, align 4, !tbaa !5
  %235 = add nsw i32 %234, 1
  store i32 %235, ptr %16, align 4, !tbaa !5
  br label %207, !llvm.loop !23

236:                                              ; preds = %211
  %237 = load i8, ptr %15, align 1, !tbaa !12, !range !14, !noundef !15
  %238 = trunc i8 %237 to i1
  br i1 %238, label %239, label %240

239:                                              ; preds = %236
  store i1 true, ptr %2, align 1
  store i32 1, ptr %5, align 4
  br label %241

240:                                              ; preds = %236
  store i32 0, ptr %5, align 4
  br label %241

241:                                              ; preds = %240, %239
  call void @llvm.lifetime.end.p0(i64 1, ptr %15) #3
  %242 = load i32, ptr %5, align 4
  switch i32 %242, label %245 [
    i32 0, label %243
  ]

243:                                              ; preds = %241
  br label %69, !llvm.loop !24

244:                                              ; preds = %69
  store i1 false, ptr %2, align 1
  store i32 1, ptr %5, align 4
  br label %245

245:                                              ; preds = %244, %241
  call void @llvm.lifetime.end.p0(i64 1, ptr %7) #3
  %246 = load i1, ptr %2, align 1
  ret i1 %246
}

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

; Function Attrs: noreturn nounwind
declare void @__assert_fail(ptr noundef, ptr noundef, i32 noundef, ptr noundef) #2

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

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 = { noreturn nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { nounwind }
attributes #4 = { noreturn 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 = distinct !{!11, !10}
!12 = !{!13, !13, i64 0}
!13 = !{!"bool", !7, i64 0}
!14 = !{i8 0, i8 2}
!15 = !{}
!16 = distinct !{!16, !10}
!17 = distinct !{!17, !10}
!18 = distinct !{!18, !10}
!19 = distinct !{!19, !10}
!20 = distinct !{!20, !10}
!21 = distinct !{!21, !10}
!22 = distinct !{!22, !10}
!23 = distinct !{!23, !10}
!24 = distinct !{!24, !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"

@M = external dso_local local_unnamed_addr global i32, align 4
@N = external dso_local local_unnamed_addr global i32, align 4
@a = external dso_local local_unnamed_addr global [100 x [100 x i32]], align 16
@A = external dso_local local_unnamed_addr global [100 x [100 x i32]], align 16
@done = external dso_local local_unnamed_addr global [100 x [100 x i32]], align 16
@.str = external hidden unnamed_addr constant [13 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [108 x i8], align 1
@__PRETTY_FUNCTION__._Z4testi = external hidden unnamed_addr constant [15 x i8], align 1

; Function Attrs: mustprogress nounwind uwtable
define dso_local noundef zeroext i1 @_Z4testi(i32 noundef %0) local_unnamed_addr #0 {
  %2 = load i32, ptr @M, align 4, !tbaa !5
  %.fr214 = freeze i32 %2
  %3 = icmp sgt i32 %.fr214, 0
  %.pre = load i32, ptr @N, align 4
  %.fr216 = freeze i32 %.pre
  br i1 %3, label %.preheader101.lr.ph, label %.preheader100.thread

.preheader101.lr.ph:                              ; preds = %1
  %4 = icmp sgt i32 %.fr216, 0
  br i1 %4, label %.preheader101.us.preheader, label %.preheader100.thread294

.preheader101.us.preheader:                       ; preds = %.preheader101.lr.ph
  %wide.trip.count235 = zext nneg i32 %.fr214 to i64
  %wide.trip.count = zext nneg i32 %.fr216 to i64
  br label %.preheader101.us

.preheader101.us:                                 ; preds = %.preheader101.us.preheader, %._crit_edge.us
  %indvars.iv232 = phi i64 [ 0, %.preheader101.us.preheader ], [ %indvars.iv.next233, %._crit_edge.us ]
  br label %5

5:                                                ; preds = %.preheader101.us, %9
  %indvars.iv = phi i64 [ 0, %.preheader101.us ], [ %indvars.iv.next, %9 ]
  %6 = getelementptr inbounds [100 x [100 x i32]], ptr @a, i64 0, i64 %indvars.iv232, i64 %indvars.iv
  %7 = load i32, ptr %6, align 4, !tbaa !5
  %8 = getelementptr inbounds [100 x [100 x i32]], ptr @A, i64 0, i64 %indvars.iv232, i64 %indvars.iv
  store i32 %7, ptr %8, align 4, !tbaa !5
  %.not91.us = icmp eq i32 %7, 0
  br i1 %.not91.us, label %.split.us, label %9

9:                                                ; preds = %5
  %10 = getelementptr inbounds [100 x [100 x i32]], ptr @done, i64 0, i64 %indvars.iv232, i64 %indvars.iv
  store i32 0, ptr %10, align 4, !tbaa !5
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %exitcond.not = icmp eq i64 %indvars.iv.next, %wide.trip.count
  br i1 %exitcond.not, label %._crit_edge.us, label %5, !llvm.loop !9

._crit_edge.us:                                   ; preds = %9
  %indvars.iv.next233 = add nuw nsw i64 %indvars.iv232, 1
  %exitcond236.not = icmp eq i64 %indvars.iv.next233, %wide.trip.count235
  br i1 %exitcond236.not, label %.preheader100, label %.preheader101.us, !llvm.loop !11

.preheader100:                                    ; preds = %._crit_edge.us
  %11 = sub i32 %.fr214, %0
  %.not159 = icmp slt i32 %11, 0
  br i1 %.not159, label %.preheader100.split.us, label %.preheader100.split

.preheader100.thread294:                          ; preds = %.preheader101.lr.ph
  %12 = sub i32 %.fr214, %0
  %13 = sub i32 %.fr216, %0
  %14 = or i32 %12, %13
  %or.cond.not = icmp sgt i32 %14, -1
  br i1 %or.cond.not, label %.preheader100.split.split.preheader, label %.split.us179

.preheader100.thread:                             ; preds = %1
  %15 = sub i32 %.fr214, %0
  %16 = icmp sgt i32 %.fr216, 0
  %17 = sub i32 %.fr216, %0
  %18 = or i32 %15, %17
  %or.cond304.not = icmp sgt i32 %18, -1
  br i1 %or.cond304.not, label %.preheader100.split.split.preheader, label %.split.us179

.preheader100.split.us:                           ; preds = %.preheader100
  br i1 %3, label %.preheader100.split.us.split.us.split.us.preheader, label %.split.us179

.preheader100.split.us.split.us.split.us.preheader: ; preds = %.preheader100.split.us
  %wide.trip.count291 = zext nneg i32 %.fr214 to i64
  %wide.trip.count287 = zext nneg i32 %.fr216 to i64
  %min.iters.check319 = icmp ult i32 %.fr216, 8
  %n.vec322 = and i64 %wide.trip.count, 2147483640
  %cmp.n333 = icmp eq i64 %n.vec322, %wide.trip.count
  br label %.preheader96.us.us.us.us

.preheader96.us.us.us.us:                         ; preds = %.preheader100.split.us.split.us.split.us.preheader, %._crit_edge168.us.us.us.us
  %indvars.iv289 = phi i64 [ 0, %.preheader100.split.us.split.us.split.us.preheader ], [ %indvars.iv.next290, %._crit_edge168.us.us.us.us ]
  %.062170.us.us.us.us = phi i1 [ true, %.preheader100.split.us.split.us.split.us.preheader ], [ %spec.select.us.us.us.us.lcssa, %._crit_edge168.us.us.us.us ]
  br i1 %min.iters.check319, label %scalar.ph318.preheader, label %vector.body324

vector.body324:                                   ; preds = %.preheader96.us.us.us.us, %vector.body324
  %index325 = phi i64 [ %index.next330, %vector.body324 ], [ 0, %.preheader96.us.us.us.us ]
  %vec.phi326 = phi <4 x i1> [ %23, %vector.body324 ], [ zeroinitializer, %.preheader96.us.us.us.us ]
  %vec.phi327 = phi <4 x i1> [ %24, %vector.body324 ], [ zeroinitializer, %.preheader96.us.us.us.us ]
  %19 = getelementptr inbounds [100 x [100 x i32]], ptr @A, i64 0, i64 %indvars.iv289, i64 %index325
  %20 = getelementptr inbounds i8, ptr %19, i64 16
  %wide.load328 = load <4 x i32>, ptr %19, align 16, !tbaa !5
  %wide.load329 = load <4 x i32>, ptr %20, align 16, !tbaa !5
  %21 = icmp ne <4 x i32> %wide.load328, zeroinitializer
  %22 = icmp ne <4 x i32> %wide.load329, zeroinitializer
  %23 = or <4 x i1> %vec.phi326, %21
  %24 = or <4 x i1> %vec.phi327, %22
  %index.next330 = add nuw i64 %index325, 8
  %25 = icmp eq i64 %index.next330, %n.vec322
  br i1 %25, label %middle.block317, label %vector.body324, !llvm.loop !12

middle.block317:                                  ; preds = %vector.body324
  %bin.rdx331 = or <4 x i1> %24, %23
  %bin.rdx331.fr = freeze <4 x i1> %bin.rdx331
  %26 = bitcast <4 x i1> %bin.rdx331.fr to i4
  %.not353 = icmp eq i4 %26, 0
  %rdx.select332 = select i1 %.not353, i1 %.062170.us.us.us.us, i1 false
  br i1 %cmp.n333, label %._crit_edge168.us.us.us.us, label %scalar.ph318.preheader

scalar.ph318.preheader:                           ; preds = %middle.block317, %.preheader96.us.us.us.us
  %indvars.iv285.ph = phi i64 [ 0, %.preheader96.us.us.us.us ], [ %n.vec322, %middle.block317 ]
  %.1166.us.us.us.us.ph = phi i1 [ %.062170.us.us.us.us, %.preheader96.us.us.us.us ], [ %rdx.select332, %middle.block317 ]
  br label %scalar.ph318

scalar.ph318:                                     ; preds = %scalar.ph318.preheader, %scalar.ph318
  %indvars.iv285 = phi i64 [ %indvars.iv.next286, %scalar.ph318 ], [ %indvars.iv285.ph, %scalar.ph318.preheader ]
  %.1166.us.us.us.us = phi i1 [ %spec.select.us.us.us.us, %scalar.ph318 ], [ %.1166.us.us.us.us.ph, %scalar.ph318.preheader ]
  %27 = getelementptr inbounds [100 x [100 x i32]], ptr @A, i64 0, i64 %indvars.iv289, i64 %indvars.iv285
  %28 = load i32, ptr %27, align 4, !tbaa !5
  %.not86.us.us.us.us = icmp eq i32 %28, 0
  %spec.select.us.us.us.us = select i1 %.not86.us.us.us.us, i1 %.1166.us.us.us.us, i1 false
  %indvars.iv.next286 = add nuw nsw i64 %indvars.iv285, 1
  %exitcond288.not = icmp eq i64 %indvars.iv.next286, %wide.trip.count287
  br i1 %exitcond288.not, label %._crit_edge168.us.us.us.us, label %scalar.ph318, !llvm.loop !15

._crit_edge168.us.us.us.us:                       ; preds = %scalar.ph318, %middle.block317
  %spec.select.us.us.us.us.lcssa = phi i1 [ %rdx.select332, %middle.block317 ], [ %spec.select.us.us.us.us, %scalar.ph318 ]
  %indvars.iv.next290 = add nuw nsw i64 %indvars.iv289, 1
  %exitcond292.not = icmp eq i64 %indvars.iv.next290, %wide.trip.count291
  br i1 %exitcond292.not, label %.split.us179, label %.preheader96.us.us.us.us, !llvm.loop !16

.preheader100.split:                              ; preds = %.preheader100
  %29 = sub i32 %.fr216, %0
  %.not87123 = icmp slt i32 %29, 0
  br i1 %.not87123, label %.preheader100.split.split.us, label %.preheader100.split.split.preheader

.preheader100.split.split.preheader:              ; preds = %.preheader100.thread, %.preheader100.thread294, %.preheader100.split
  %30 = phi i1 [ true, %.preheader100.split ], [ false, %.preheader100.thread294 ], [ %16, %.preheader100.thread ]
  %31 = add i32 %.fr216, 1
  %32 = sub i32 %31, %0
  %33 = sext i32 %0 to i64
  %34 = add i32 %.fr214, 1
  %35 = sub i32 %34, %0
  %wide.trip.count267 = zext i32 %35 to i64
  %36 = icmp sgt i32 %0, 0
  %wide.trip.count239 = zext i32 %32 to i64
  %wide.trip.count265 = zext i32 %32 to i64
  %wide.trip.count275 = zext nneg i32 %.fr214 to i64
  %wide.trip.count271 = zext i32 %.fr216 to i64
  %xtraiter = and i64 %wide.trip.count239, 1
  %37 = icmp eq i32 %32, 1
  %unroll_iter = and i64 %wide.trip.count239, 4294967294
  %lcmp.mod.not = icmp eq i64 %xtraiter, 0
  %brmerge310.not = and i1 %3, %30
  %min.iters.check337 = icmp ult i32 %.fr216, 8
  %n.vec340 = and i64 %wide.trip.count271, 4294967288
  %cmp.n351 = icmp eq i64 %n.vec340, %wide.trip.count271
  br label %.preheader100.split.split

.preheader100.split.split.us:                     ; preds = %.preheader100.split
  br i1 %3, label %.preheader100.split.split.us.split.us.split.us.preheader, label %.split.us179

.preheader100.split.split.us.split.us.split.us.preheader: ; preds = %.preheader100.split.split.us
  %wide.trip.count283 = zext nneg i32 %.fr214 to i64
  %wide.trip.count279 = zext nneg i32 %.fr216 to i64
  %min.iters.check = icmp ult i32 %.fr216, 8
  %n.vec = and i64 %wide.trip.count, 2147483640
  %cmp.n = icmp eq i64 %n.vec, %wide.trip.count
  br label %.preheader96.us.us192.us.us

.preheader96.us.us192.us.us:                      ; preds = %.preheader100.split.split.us.split.us.split.us.preheader, %._crit_edge168.us.us199.us.us
  %indvars.iv281 = phi i64 [ 0, %.preheader100.split.split.us.split.us.split.us.preheader ], [ %indvars.iv.next282, %._crit_edge168.us.us199.us.us ]
  %.062170.us.us194.us.us = phi i1 [ true, %.preheader100.split.split.us.split.us.split.us.preheader ], [ %spec.select.us.us198.us.us.lcssa, %._crit_edge168.us.us199.us.us ]
  br i1 %min.iters.check, label %scalar.ph.preheader, label %vector.body

vector.body:                                      ; preds = %.preheader96.us.us192.us.us, %vector.body
  %index = phi i64 [ %index.next, %vector.body ], [ 0, %.preheader96.us.us192.us.us ]
  %vec.phi = phi <4 x i1> [ %42, %vector.body ], [ zeroinitializer, %.preheader96.us.us192.us.us ]
  %vec.phi315 = phi <4 x i1> [ %43, %vector.body ], [ zeroinitializer, %.preheader96.us.us192.us.us ]
  %38 = getelementptr inbounds [100 x [100 x i32]], ptr @A, i64 0, i64 %indvars.iv281, i64 %index
  %39 = getelementptr inbounds i8, ptr %38, i64 16
  %wide.load = load <4 x i32>, ptr %38, align 16, !tbaa !5
  %wide.load316 = load <4 x i32>, ptr %39, align 16, !tbaa !5
  %40 = icmp ne <4 x i32> %wide.load, zeroinitializer
  %41 = icmp ne <4 x i32> %wide.load316, zeroinitializer
  %42 = or <4 x i1> %vec.phi, %40
  %43 = or <4 x i1> %vec.phi315, %41
  %index.next = add nuw i64 %index, 8
  %44 = icmp eq i64 %index.next, %n.vec
  br i1 %44, label %middle.block, label %vector.body, !llvm.loop !17

middle.block:                                     ; preds = %vector.body
  %bin.rdx = or <4 x i1> %43, %42
  %bin.rdx.fr = freeze <4 x i1> %bin.rdx
  %45 = bitcast <4 x i1> %bin.rdx.fr to i4
  %.not = icmp eq i4 %45, 0
  %rdx.select = select i1 %.not, i1 %.062170.us.us194.us.us, i1 false
  br i1 %cmp.n, label %._crit_edge168.us.us199.us.us, label %scalar.ph.preheader

scalar.ph.preheader:                              ; preds = %middle.block, %.preheader96.us.us192.us.us
  %indvars.iv277.ph = phi i64 [ 0, %.preheader96.us.us192.us.us ], [ %n.vec, %middle.block ]
  %.1166.us.us196.us.us.ph = phi i1 [ %.062170.us.us194.us.us, %.preheader96.us.us192.us.us ], [ %rdx.select, %middle.block ]
  br label %scalar.ph

scalar.ph:                                        ; preds = %scalar.ph.preheader, %scalar.ph
  %indvars.iv277 = phi i64 [ %indvars.iv.next278, %scalar.ph ], [ %indvars.iv277.ph, %scalar.ph.preheader ]
  %.1166.us.us196.us.us = phi i1 [ %spec.select.us.us198.us.us, %scalar.ph ], [ %.1166.us.us196.us.us.ph, %scalar.ph.preheader ]
  %46 = getelementptr inbounds [100 x [100 x i32]], ptr @A, i64 0, i64 %indvars.iv281, i64 %indvars.iv277
  %47 = load i32, ptr %46, align 4, !tbaa !5
  %.not86.us.us197.us.us = icmp eq i32 %47, 0
  %spec.select.us.us198.us.us = select i1 %.not86.us.us197.us.us, i1 %.1166.us.us196.us.us, i1 false
  %indvars.iv.next278 = add nuw nsw i64 %indvars.iv277, 1
  %exitcond280.not = icmp eq i64 %indvars.iv.next278, %wide.trip.count279
  br i1 %exitcond280.not, label %._crit_edge168.us.us199.us.us, label %scalar.ph, !llvm.loop !18

._crit_edge168.us.us199.us.us:                    ; preds = %scalar.ph, %middle.block
  %spec.select.us.us198.us.us.lcssa = phi i1 [ %rdx.select, %middle.block ], [ %spec.select.us.us198.us.us, %scalar.ph ]
  %indvars.iv.next282 = add nuw nsw i64 %indvars.iv281, 1
  %exitcond284.not = icmp eq i64 %indvars.iv.next282, %wide.trip.count283
  br i1 %exitcond284.not, label %.split.us179, label %.preheader96.us.us192.us.us, !llvm.loop !16

.split.us:                                        ; preds = %5
  tail call void @__assert_fail(ptr noundef nonnull @.str, ptr noundef nonnull @.str.1, i32 noundef 33, ptr noundef nonnull @__PRETTY_FUNCTION__._Z4testi) #4
  unreachable

.preheader100.split.split:                        ; preds = %.preheader100.split.split.preheader, %._crit_edge172
  %.072 = phi i1 [ %.us-phi137, %._crit_edge172 ], [ true, %.preheader100.split.split.preheader ]
  br i1 %.072, label %.preheader97, label %.split.us179

..preheader98_crit_edge.split:                    ; preds = %._crit_edge
  br i1 %brmerge310.not, label %.preheader96.us, label %.split.us179.loopexit364.split.loop.exit

.preheader96.us:                                  ; preds = %..preheader98_crit_edge.split, %._crit_edge168.us
  %indvars.iv273 = phi i64 [ %indvars.iv.next274, %._crit_edge168.us ], [ 0, %..preheader98_crit_edge.split ]
  %.062170.us = phi i1 [ %spec.select.us.lcssa, %._crit_edge168.us ], [ true, %..preheader98_crit_edge.split ]
  br i1 %min.iters.check337, label %scalar.ph336.preheader, label %vector.body342

vector.body342:                                   ; preds = %.preheader96.us, %vector.body342
  %index343 = phi i64 [ %index.next348, %vector.body342 ], [ 0, %.preheader96.us ]
  %vec.phi344 = phi <4 x i1> [ %52, %vector.body342 ], [ zeroinitializer, %.preheader96.us ]
  %vec.phi345 = phi <4 x i1> [ %53, %vector.body342 ], [ zeroinitializer, %.preheader96.us ]
  %48 = getelementptr inbounds [100 x [100 x i32]], ptr @A, i64 0, i64 %indvars.iv273, i64 %index343
  %49 = getelementptr inbounds i8, ptr %48, i64 16
  %wide.load346 = load <4 x i32>, ptr %48, align 16, !tbaa !5
  %wide.load347 = load <4 x i32>, ptr %49, align 16, !tbaa !5
  %50 = icmp ne <4 x i32> %wide.load346, zeroinitializer
  %51 = icmp ne <4 x i32> %wide.load347, zeroinitializer
  %52 = or <4 x i1> %vec.phi344, %50
  %53 = or <4 x i1> %vec.phi345, %51
  %index.next348 = add nuw i64 %index343, 8
  %54 = icmp eq i64 %index.next348, %n.vec340
  br i1 %54, label %middle.block335, label %vector.body342, !llvm.loop !19

middle.block335:                                  ; preds = %vector.body342
  %bin.rdx349 = or <4 x i1> %53, %52
  %bin.rdx349.fr = freeze <4 x i1> %bin.rdx349
  %55 = bitcast <4 x i1> %bin.rdx349.fr to i4
  %.not355 = icmp eq i4 %55, 0
  %rdx.select350 = select i1 %.not355, i1 %.062170.us, i1 false
  br i1 %cmp.n351, label %._crit_edge168.us, label %scalar.ph336.preheader

scalar.ph336.preheader:                           ; preds = %middle.block335, %.preheader96.us
  %indvars.iv269.ph = phi i64 [ 0, %.preheader96.us ], [ %n.vec340, %middle.block335 ]
  %.1166.us.ph = phi i1 [ %.062170.us, %.preheader96.us ], [ %rdx.select350, %middle.block335 ]
  br label %scalar.ph336

scalar.ph336:                                     ; preds = %scalar.ph336.preheader, %scalar.ph336
  %indvars.iv269 = phi i64 [ %indvars.iv.next270, %scalar.ph336 ], [ %indvars.iv269.ph, %scalar.ph336.preheader ]
  %.1166.us = phi i1 [ %spec.select.us, %scalar.ph336 ], [ %.1166.us.ph, %scalar.ph336.preheader ]
  %56 = getelementptr inbounds [100 x [100 x i32]], ptr @A, i64 0, i64 %indvars.iv273, i64 %indvars.iv269
  %57 = load i32, ptr %56, align 4, !tbaa !5
  %.not86.us = icmp eq i32 %57, 0
  %spec.select.us = select i1 %.not86.us, i1 %.1166.us, i1 false
  %indvars.iv.next270 = add nuw nsw i64 %indvars.iv269, 1
  %exitcond272.not = icmp eq i64 %indvars.iv.next270, %wide.trip.count271
  br i1 %exitcond272.not, label %._crit_edge168.us, label %scalar.ph336, !llvm.loop !20

._crit_edge168.us:                                ; preds = %scalar.ph336, %middle.block335
  %spec.select.us.lcssa = phi i1 [ %rdx.select350, %middle.block335 ], [ %spec.select.us, %scalar.ph336 ]
  %indvars.iv.next274 = add nuw nsw i64 %indvars.iv273, 1
  %exitcond276.not = icmp eq i64 %indvars.iv.next274, %wide.trip.count275
  br i1 %exitcond276.not, label %._crit_edge172, label %.preheader96.us, !llvm.loop !16

.preheader97:                                     ; preds = %.preheader100.split.split, %._crit_edge
  %indvar = phi i64 [ %indvar.next, %._crit_edge ], [ 0, %.preheader100.split.split ]
  %.173160 = phi i1 [ %.us-phi137, %._crit_edge ], [ false, %.preheader100.split.split ]
  %58 = add nsw i64 %indvar, %33
  br i1 %36, label %.lr.ph.split.us.preheader, label %.lr.ph.split.split.preheader

.lr.ph.split.split.preheader:                     ; preds = %.preheader97
  br i1 %37, label %._crit_edge.loopexit363.unr-lcssa, label %.lr.ph.split.split

.lr.ph.split.us.preheader:                        ; preds = %.preheader97
  %59 = mul nuw nsw i64 %indvar, 400
  %60 = trunc nuw nsw i64 %indvar to i32
  %61 = getelementptr i8, ptr @A, i64 %59
  br label %.lr.ph.split.us

.lr.ph.split.us:                                  ; preds = %.lr.ph.split.us.preheader, %.thread.us
  %indvars.iv250 = phi i64 [ 0, %.lr.ph.split.us.preheader ], [ %65, %.thread.us ]
  %.274124.us = phi i1 [ %.173160, %.lr.ph.split.us.preheader ], [ %.476.us, %.thread.us ]
  %62 = shl nuw nsw i64 %indvars.iv250, 2
  %63 = trunc i64 %indvars.iv250 to i32
  %64 = add i32 %63, %0
  %65 = add nuw nsw i64 %indvars.iv250, 1
  %66 = trunc i64 %65 to i32
  %smax261 = tail call i32 @llvm.smax.i32(i32 %64, i32 %66)
  %67 = trunc i64 %indvars.iv250 to i32
  %68 = xor i32 %67, -1
  %69 = add i32 %smax261, %68
  %70 = zext i32 %69 to i64
  %71 = shl nuw nsw i64 %70, 2
  %72 = add nuw nsw i64 %71, 4
  %73 = getelementptr inbounds [100 x [100 x i32]], ptr @done, i64 0, i64 %indvar, i64 %indvars.iv250
  %74 = load i32, ptr %73, align 4, !tbaa !5
  %.not88.us = icmp eq i32 %74, 0
  br i1 %.not88.us, label %.preheader93.us.us, label %.thread.us

._crit_edge121.us:                                ; preds = %.preheader.us.us
  store i32 1, ptr %73, align 4, !tbaa !5
  br label %.thread.us

.thread.us:                                       ; preds = %._crit_edge.us115.us, %78, %._crit_edge121.us, %.lr.ph.split.us
  %.476.us = phi i1 [ %.274124.us, %.lr.ph.split.us ], [ true, %._crit_edge121.us ], [ %.274124.us, %78 ], [ %.274124.us, %._crit_edge.us115.us ]
  %exitcond266.not = icmp eq i64 %65, %wide.trip.count265
  br i1 %exitcond266.not, label %._crit_edge, label %.lr.ph.split.us, !llvm.loop !21

.preheader93.us.us:                               ; preds = %.lr.ph.split.us, %85
  %indvars.iv255 = phi i64 [ %indvars.iv.next256, %85 ], [ %indvar, %.lr.ph.split.us ]
  %.067112.us.us = phi i32 [ %.269.us.us, %85 ], [ 0, %.lr.ph.split.us ]
  br label %75

75:                                               ; preds = %82, %.preheader93.us.us
  %indvars.iv252 = phi i64 [ %indvars.iv.next253, %82 ], [ %indvars.iv250, %.preheader93.us.us ]
  %.168109.us.us = phi i32 [ %.269.us.us, %82 ], [ %.067112.us.us, %.preheader93.us.us ]
  %76 = getelementptr inbounds [100 x [100 x i32]], ptr @A, i64 0, i64 %indvars.iv255, i64 %indvars.iv252
  %77 = load i32, ptr %76, align 4, !tbaa !5
  %.not89.us.us = icmp eq i32 %77, 0
  br i1 %.not89.us.us, label %82, label %78

78:                                               ; preds = %75
  %79 = shl nuw i32 1, %77
  %80 = or i32 %79, %.168109.us.us
  %81 = icmp eq i32 %80, 6
  br i1 %81, label %.thread.us, label %82

82:                                               ; preds = %78, %75
  %.269.us.us = phi i32 [ %80, %78 ], [ %.168109.us.us, %75 ]
  %indvars.iv.next253 = add nuw nsw i64 %indvars.iv252, 1
  %83 = trunc nuw i64 %indvars.iv.next253 to i32
  %84 = icmp sgt i32 %64, %83
  br i1 %84, label %75, label %._crit_edge.us115.us, !llvm.loop !22

85:                                               ; preds = %._crit_edge.us115.us
  %indvars.iv.next256 = add nuw nsw i64 %indvars.iv255, 1
  %sext = shl i64 %indvars.iv.next256, 32
  %86 = ashr exact i64 %sext, 32
  %87 = icmp slt i64 %86, %58
  br i1 %87, label %.preheader93.us.us, label %.preheader.us.us.preheader, !llvm.loop !23

._crit_edge.us115.us:                             ; preds = %82
  %88 = icmp eq i32 %.269.us.us, 6
  br i1 %88, label %.thread.us, label %85

.preheader.us.us.preheader:                       ; preds = %85
  %89 = getelementptr i8, ptr %61, i64 %62
  br label %.preheader.us.us

.preheader.us.us:                                 ; preds = %.preheader.us.us.preheader, %.preheader.us.us
  %indvar258 = phi i64 [ 0, %.preheader.us.us.preheader ], [ %indvar.next259, %.preheader.us.us ]
  %.064120.us.us = phi i32 [ %60, %.preheader.us.us.preheader ], [ %91, %.preheader.us.us ]
  %90 = mul nuw nsw i64 %indvar258, 400
  %scevgep260 = getelementptr i8, ptr %89, i64 %90
  tail call void @llvm.memset.p0.i64(ptr noundef nonnull align 4 dereferenceable(1) %scevgep260, i8 0, i64 %72, i1 false), !tbaa !5
  %91 = add nuw nsw i32 %.064120.us.us, 1
  %92 = sext i32 %91 to i64
  %93 = icmp sgt i64 %58, %92
  %indvar.next259 = add nuw nsw i64 %indvar258, 1
  br i1 %93, label %.preheader.us.us, label %._crit_edge121.us, !llvm.loop !24

._crit_edge.loopexit363.unr-lcssa:                ; preds = %100, %.lr.ph.split.split.preheader
  %.476.lcssa.ph = phi i1 [ poison, %.lr.ph.split.split.preheader ], [ %.476.1, %100 ]
  %indvars.iv237.unr = phi i64 [ 0, %.lr.ph.split.split.preheader ], [ %indvars.iv.next238.1, %100 ]
  %.274124.unr = phi i1 [ %.173160, %.lr.ph.split.split.preheader ], [ %.476.1, %100 ]
  br i1 %lcmp.mod.not, label %._crit_edge, label %.lr.ph.split.split.epil

.lr.ph.split.split.epil:                          ; preds = %._crit_edge.loopexit363.unr-lcssa
  %94 = getelementptr inbounds [100 x [100 x i32]], ptr @done, i64 0, i64 %indvar, i64 %indvars.iv237.unr
  %95 = load i32, ptr %94, align 4, !tbaa !5
  %.not88.epil = icmp eq i32 %95, 0
  br i1 %.not88.epil, label %.preheader94.epil, label %._crit_edge

.preheader94.epil:                                ; preds = %.lr.ph.split.split.epil
  store i32 1, ptr %94, align 4, !tbaa !5
  br label %._crit_edge

._crit_edge:                                      ; preds = %._crit_edge.loopexit363.unr-lcssa, %.preheader94.epil, %.lr.ph.split.split.epil, %.thread.us
  %.us-phi137 = phi i1 [ %.476.us, %.thread.us ], [ %.476.lcssa.ph, %._crit_edge.loopexit363.unr-lcssa ], [ %.274124.unr, %.lr.ph.split.split.epil ], [ true, %.preheader94.epil ]
  %indvar.next = add nuw nsw i64 %indvar, 1
  %exitcond268.not = icmp eq i64 %indvar.next, %wide.trip.count267
  br i1 %exitcond268.not, label %..preheader98_crit_edge.split, label %.preheader97, !llvm.loop !25

.lr.ph.split.split:                               ; preds = %.lr.ph.split.split.preheader, %100
  %indvars.iv237 = phi i64 [ %indvars.iv.next238.1, %100 ], [ 0, %.lr.ph.split.split.preheader ]
  %.274124 = phi i1 [ %.476.1, %100 ], [ %.173160, %.lr.ph.split.split.preheader ]
  %niter = phi i64 [ %niter.next.1, %100 ], [ 0, %.lr.ph.split.split.preheader ]
  %96 = getelementptr inbounds [100 x [100 x i32]], ptr @done, i64 0, i64 %indvar, i64 %indvars.iv237
  %97 = load i32, ptr %96, align 8, !tbaa !5
  %.not88 = icmp eq i32 %97, 0
  br i1 %.not88, label %.preheader94, label %.lr.ph.split.split.1

.preheader94:                                     ; preds = %.lr.ph.split.split
  store i32 1, ptr %96, align 8, !tbaa !5
  br label %.lr.ph.split.split.1

.lr.ph.split.split.1:                             ; preds = %.preheader94, %.lr.ph.split.split
  %.476 = phi i1 [ %.274124, %.lr.ph.split.split ], [ true, %.preheader94 ]
  %indvars.iv.next238 = or disjoint i64 %indvars.iv237, 1
  %98 = getelementptr inbounds [100 x [100 x i32]], ptr @done, i64 0, i64 %indvar, i64 %indvars.iv.next238
  %99 = load i32, ptr %98, align 4, !tbaa !5
  %.not88.1 = icmp eq i32 %99, 0
  br i1 %.not88.1, label %.preheader94.1, label %100

.preheader94.1:                                   ; preds = %.lr.ph.split.split.1
  store i32 1, ptr %98, align 4, !tbaa !5
  br label %100

100:                                              ; preds = %.preheader94.1, %.lr.ph.split.split.1
  %.476.1 = phi i1 [ %.476, %.lr.ph.split.split.1 ], [ true, %.preheader94.1 ]
  %indvars.iv.next238.1 = add nuw nsw i64 %indvars.iv237, 2
  %niter.next.1 = add i64 %niter, 2
  %niter.ncmp.1 = icmp eq i64 %niter.next.1, %unroll_iter
  br i1 %niter.ncmp.1, label %._crit_edge.loopexit363.unr-lcssa, label %.lr.ph.split.split, !llvm.loop !21

._crit_edge172:                                   ; preds = %._crit_edge168.us
  br i1 %spec.select.us.lcssa, label %.split.us179, label %.preheader100.split.split, !llvm.loop !26

.split.us179.loopexit364.split.loop.exit:         ; preds = %..preheader98_crit_edge.split
  %.072.mux.le = or i1 %.072, %3
  br label %.split.us179

.split.us179:                                     ; preds = %.split.us179.loopexit364.split.loop.exit, %._crit_edge172, %.preheader100.split.split, %._crit_edge168.us.us199.us.us, %._crit_edge168.us.us.us.us, %.preheader100.split.split.us, %.preheader100.split.us, %.preheader100.thread, %.preheader100.thread294
  %.us-phi180 = phi i1 [ true, %.preheader100.split.us ], [ true, %.preheader100.split.split.us ], [ true, %.preheader100.thread294 ], [ true, %.preheader100.thread ], [ %spec.select.us.us.us.us.lcssa, %._crit_edge168.us.us.us.us ], [ %spec.select.us.us198.us.us.lcssa, %._crit_edge168.us.us199.us.us ], [ %.072.mux.le, %.split.us179.loopexit364.split.loop.exit ], [ %.072, %._crit_edge172 ], [ false, %.preheader100.split.split ]
  ret i1 %.us-phi180
}

; Function Attrs: noreturn nounwind
declare void @__assert_fail(ptr noundef, ptr noundef, i32 noundef, ptr noundef) local_unnamed_addr #1

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

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: write)
declare void @llvm.memset.p0.i64(ptr nocapture writeonly, i8, i64, i1 immarg) #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 = { noreturn 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 #2 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #3 = { nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #4 = { noreturn 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 = distinct !{!11, !10}
!12 = distinct !{!12, !10, !13, !14}
!13 = !{!"llvm.loop.isvectorized", i32 1}
!14 = !{!"llvm.loop.unroll.runtime.disable"}
!15 = distinct !{!15, !10, !14, !13}
!16 = distinct !{!16, !10}
!17 = distinct !{!17, !10, !13, !14}
!18 = distinct !{!18, !10, !14, !13}
!19 = distinct !{!19, !10, !13, !14}
!20 = distinct !{!20, !10, !14, !13}
!21 = distinct !{!21, !10}
!22 = distinct !{!22, !10}
!23 = distinct !{!23, !10}
!24 = distinct !{!24, !10}
!25 = distinct !{!25, !10}
!26 = distinct !{!26, !10}


; Effective O3 passes: ADCEPass,AggressiveInstCombinePass,ConstraintEliminationPass,CorrelatedValuePropagationPass,EarlyCSEPass,GVNPass,GlobalDCEPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferAlignmentPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,JumpThreadingPass,LCSSAPass,LICMPass,LoopIdiomRecognizePass,LoopInstSimplifyPass,LoopLoadEliminationPass,LoopRotatePass,LoopSimplifyCFGPass,LoopSimplifyPass,LoopUnrollPass,LoopVectorizePass,ReassociatePass,SCCPPass,SROAPass,SimplifyCFGPass,TailCallElimPass