; LLVM IR from lzyrapx/Competitive-Programming :: 百度之星/2016 Astar Contest - Round 2A (1004-D Game)

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

%"class.std::map" = type { %"class.std::_Rb_tree" }
%"class.std::_Rb_tree" = type { %"struct.std::_Rb_tree<int, std::pair<const int, int>, std::_Select1st<std::pair<const int, int>>, std::less<int>>::_Rb_tree_impl" }
%"struct.std::_Rb_tree<int, std::pair<const int, int>, std::_Select1st<std::pair<const int, int>>, std::less<int>>::_Rb_tree_impl" = type { [8 x i8], %"struct.std::_Rb_tree_header" }
%"struct.std::_Rb_tree_header" = type { %"struct.std::_Rb_tree_node_base", i64 }
%"struct.std::_Rb_tree_node_base" = type { i32, ptr, ptr, ptr }
%"class.std::basic_ostream" = type { ptr, %"class.std::basic_ios" }
%"class.std::basic_ios" = type { %"class.std::ios_base", ptr, i8, i8, ptr, ptr, ptr, ptr }
%"class.std::ios_base" = type { ptr, i64, i64, i32, i32, i32, ptr, %"struct.std::ios_base::_Words", [8 x %"struct.std::ios_base::_Words"], i32, ptr, %"class.std::locale" }
%"struct.std::ios_base::_Words" = type { ptr, i64 }
%"class.std::locale" = type { ptr }

@f = external dso_local global [305 x [305 x i32]], align 16
@n = external dso_local global i32, align 4
@m = external dso_local global i32, align 4
@i = external dso_local global i32, align 4
@T = external dso_local global i32, align 4
@j = external dso_local global i32, align 4
@dp = external dso_local global [350 x [305 x i32]], align 16
@DP = external dso_local global [305 x i32], align 16
@b = external dso_local global [305 x i32], align 16
@a = external dso_local global [305 x i32], align 16
@k = external dso_local global i32, align 4
@mp = external dso_local global %"class.std::map", align 8
@.str = external hidden unnamed_addr constant [3 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [5 x i8], align 1
@_ZSt4cout = external global %"class.std::basic_ostream", align 8

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() #0 {
  %1 = alloca i32, align 4
  %2 = alloca i32, align 4
  store i32 0, ptr %1, align 4
  %3 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef @T)
  br label %4

4:                                                ; preds = %379, %0
  %5 = load i32, ptr @T, align 4, !tbaa !5
  %6 = add nsw i32 %5, -1
  store i32 %6, ptr @T, align 4, !tbaa !5
  %7 = icmp ne i32 %5, 0
  br i1 %7, label %8, label %388

8:                                                ; preds = %4
  %9 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str.2, ptr noundef @n, ptr noundef @m)
  store i32 1, ptr @i, align 4, !tbaa !5
  br label %10

10:                                               ; preds = %19, %8
  %11 = load i32, ptr @i, align 4, !tbaa !5
  %12 = load i32, ptr @n, align 4, !tbaa !5
  %13 = icmp sle i32 %11, %12
  br i1 %13, label %14, label %22

14:                                               ; preds = %10
  %15 = load i32, ptr @i, align 4, !tbaa !5
  %16 = sext i32 %15 to i64
  %17 = getelementptr inbounds [305 x i32], ptr @a, i64 0, i64 %16
  %18 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef %17)
  br label %19

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

22:                                               ; preds = %10
  store i32 1, ptr @i, align 4, !tbaa !5
  br label %23

23:                                               ; preds = %36, %22
  %24 = load i32, ptr @i, align 4, !tbaa !5
  %25 = load i32, ptr @m, align 4, !tbaa !5
  %26 = icmp sle i32 %24, %25
  br i1 %26, label %27, label %39

27:                                               ; preds = %23
  %28 = load i32, ptr @i, align 4, !tbaa !5
  %29 = sext i32 %28 to i64
  %30 = getelementptr inbounds [305 x i32], ptr @b, i64 0, i64 %29
  %31 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef %30)
  %32 = load i32, ptr @i, align 4, !tbaa !5
  %33 = sext i32 %32 to i64
  %34 = getelementptr inbounds [305 x i32], ptr @b, i64 0, i64 %33
  %35 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt3mapIiiSt4lessIiESaISt4pairIKiiEEEixERS3_(ptr noundef nonnull align 8 dereferenceable(48) @mp, ptr noundef nonnull align 4 dereferenceable(4) %34)
  store i32 1, ptr %35, align 4, !tbaa !5
  br label %36

36:                                               ; preds = %27
  %37 = load i32, ptr @i, align 4, !tbaa !5
  %38 = add nsw i32 %37, 1
  store i32 %38, ptr @i, align 4, !tbaa !5
  br label %23, !llvm.loop !11

39:                                               ; preds = %23
  store i32 1, ptr @i, align 4, !tbaa !5
  br label %40

40:                                               ; preds = %83, %39
  %41 = load i32, ptr @i, align 4, !tbaa !5
  %42 = load i32, ptr @n, align 4, !tbaa !5
  %43 = icmp sle i32 %41, %42
  br i1 %43, label %44, label %86

44:                                               ; preds = %40
  %45 = load i32, ptr @i, align 4, !tbaa !5
  %46 = add nsw i32 %45, 1
  store i32 %46, ptr @j, align 4, !tbaa !5
  br label %47

47:                                               ; preds = %79, %44
  %48 = load i32, ptr @j, align 4, !tbaa !5
  %49 = load i32, ptr @n, align 4, !tbaa !5
  %50 = icmp sle i32 %48, %49
  br i1 %50, label %51, label %82

51:                                               ; preds = %47
  call void @llvm.lifetime.start.p0(i64 4, ptr %2) #7
  %52 = load i32, ptr @j, align 4, !tbaa !5
  %53 = sext i32 %52 to i64
  %54 = getelementptr inbounds [305 x i32], ptr @a, i64 0, i64 %53
  %55 = load i32, ptr %54, align 4, !tbaa !5
  %56 = load i32, ptr @i, align 4, !tbaa !5
  %57 = sext i32 %56 to i64
  %58 = getelementptr inbounds [305 x i32], ptr @a, i64 0, i64 %57
  %59 = load i32, ptr %58, align 4, !tbaa !5
  %60 = sub nsw i32 %55, %59
  store i32 %60, ptr %2, align 4, !tbaa !5
  %61 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt3mapIiiSt4lessIiESaISt4pairIKiiEEEixEOi(ptr noundef nonnull align 8 dereferenceable(48) @mp, ptr noundef nonnull align 4 dereferenceable(4) %2)
  %62 = load i32, ptr %61, align 4, !tbaa !5
  %63 = icmp ne i32 %62, 0
  call void @llvm.lifetime.end.p0(i64 4, ptr %2) #7
  br i1 %63, label %64, label %71

64:                                               ; preds = %51
  %65 = load i32, ptr @i, align 4, !tbaa !5
  %66 = sext i32 %65 to i64
  %67 = getelementptr inbounds [305 x [305 x i32]], ptr @f, i64 0, i64 %66
  %68 = load i32, ptr @j, align 4, !tbaa !5
  %69 = sext i32 %68 to i64
  %70 = getelementptr inbounds [305 x i32], ptr %67, i64 0, i64 %69
  store i32 1, ptr %70, align 4, !tbaa !5
  br label %78

71:                                               ; preds = %51
  %72 = load i32, ptr @i, align 4, !tbaa !5
  %73 = sext i32 %72 to i64
  %74 = getelementptr inbounds [305 x [305 x i32]], ptr @f, i64 0, i64 %73
  %75 = load i32, ptr @j, align 4, !tbaa !5
  %76 = sext i32 %75 to i64
  %77 = getelementptr inbounds [305 x i32], ptr %74, i64 0, i64 %76
  store i32 0, ptr %77, align 4, !tbaa !5
  br label %78

78:                                               ; preds = %71, %64
  br label %79

79:                                               ; preds = %78
  %80 = load i32, ptr @j, align 4, !tbaa !5
  %81 = add nsw i32 %80, 1
  store i32 %81, ptr @j, align 4, !tbaa !5
  br label %47, !llvm.loop !12

82:                                               ; preds = %47
  br label %83

83:                                               ; preds = %82
  %84 = load i32, ptr @i, align 4, !tbaa !5
  %85 = add nsw i32 %84, 1
  store i32 %85, ptr @i, align 4, !tbaa !5
  br label %40, !llvm.loop !13

86:                                               ; preds = %40
  store i32 1, ptr @i, align 4, !tbaa !5
  br label %87

87:                                               ; preds = %108, %86
  %88 = load i32, ptr @i, align 4, !tbaa !5
  %89 = load i32, ptr @n, align 4, !tbaa !5
  %90 = icmp sle i32 %88, %89
  br i1 %90, label %91, label %111

91:                                               ; preds = %87
  %92 = load i32, ptr @i, align 4, !tbaa !5
  store i32 %92, ptr @j, align 4, !tbaa !5
  br label %93

93:                                               ; preds = %104, %91
  %94 = load i32, ptr @j, align 4, !tbaa !5
  %95 = load i32, ptr @n, align 4, !tbaa !5
  %96 = icmp sle i32 %94, %95
  br i1 %96, label %97, label %107

97:                                               ; preds = %93
  %98 = load i32, ptr @i, align 4, !tbaa !5
  %99 = sext i32 %98 to i64
  %100 = getelementptr inbounds [350 x [305 x i32]], ptr @dp, i64 0, i64 %99
  %101 = load i32, ptr @j, align 4, !tbaa !5
  %102 = sext i32 %101 to i64
  %103 = getelementptr inbounds [305 x i32], ptr %100, i64 0, i64 %102
  store i32 0, ptr %103, align 4, !tbaa !5
  br label %104

104:                                              ; preds = %97
  %105 = load i32, ptr @j, align 4, !tbaa !5
  %106 = add nsw i32 %105, 1
  store i32 %106, ptr @j, align 4, !tbaa !5
  br label %93, !llvm.loop !14

107:                                              ; preds = %93
  br label %108

108:                                              ; preds = %107
  %109 = load i32, ptr @i, align 4, !tbaa !5
  %110 = add nsw i32 %109, 1
  store i32 %110, ptr @i, align 4, !tbaa !5
  br label %87, !llvm.loop !15

111:                                              ; preds = %87
  store i32 1, ptr @i, align 4, !tbaa !5
  br label %112

112:                                              ; preds = %125, %111
  %113 = load i32, ptr @i, align 4, !tbaa !5
  %114 = load i32, ptr @n, align 4, !tbaa !5
  %115 = add nsw i32 %114, 1
  %116 = icmp sle i32 %113, %115
  br i1 %116, label %117, label %128

117:                                              ; preds = %112
  %118 = load i32, ptr @i, align 4, !tbaa !5
  %119 = sext i32 %118 to i64
  %120 = getelementptr inbounds [350 x [305 x i32]], ptr @dp, i64 0, i64 %119
  %121 = load i32, ptr @i, align 4, !tbaa !5
  %122 = sub nsw i32 %121, 1
  %123 = sext i32 %122 to i64
  %124 = getelementptr inbounds [305 x i32], ptr %120, i64 0, i64 %123
  store i32 1, ptr %124, align 4, !tbaa !5
  br label %125

125:                                              ; preds = %117
  %126 = load i32, ptr @i, align 4, !tbaa !5
  %127 = add nsw i32 %126, 1
  store i32 %127, ptr @i, align 4, !tbaa !5
  br label %112, !llvm.loop !16

128:                                              ; preds = %112
  store i32 1, ptr @i, align 4, !tbaa !5
  br label %129

129:                                              ; preds = %315, %128
  %130 = load i32, ptr @i, align 4, !tbaa !5
  %131 = load i32, ptr @n, align 4, !tbaa !5
  %132 = icmp sle i32 %130, %131
  br i1 %132, label %133, label %318

133:                                              ; preds = %129
  store i32 1, ptr @j, align 4, !tbaa !5
  br label %134

134:                                              ; preds = %311, %133
  %135 = load i32, ptr @j, align 4, !tbaa !5
  %136 = load i32, ptr @n, align 4, !tbaa !5
  %137 = load i32, ptr @i, align 4, !tbaa !5
  %138 = sub nsw i32 %136, %137
  %139 = icmp sle i32 %135, %138
  br i1 %139, label %140, label %314

140:                                              ; preds = %134
  %141 = load i32, ptr @j, align 4, !tbaa !5
  store i32 %141, ptr @k, align 4, !tbaa !5
  br label %142

142:                                              ; preds = %182, %140
  %143 = load i32, ptr @k, align 4, !tbaa !5
  %144 = load i32, ptr @j, align 4, !tbaa !5
  %145 = load i32, ptr @i, align 4, !tbaa !5
  %146 = add nsw i32 %144, %145
  %147 = icmp slt i32 %143, %146
  br i1 %147, label %148, label %185

148:                                              ; preds = %142
  %149 = load i32, ptr @j, align 4, !tbaa !5
  %150 = sext i32 %149 to i64
  %151 = getelementptr inbounds [350 x [305 x i32]], ptr @dp, i64 0, i64 %150
  %152 = load i32, ptr @k, align 4, !tbaa !5
  %153 = sext i32 %152 to i64
  %154 = getelementptr inbounds [305 x i32], ptr %151, i64 0, i64 %153
  %155 = load i32, ptr %154, align 4, !tbaa !5
  %156 = icmp ne i32 %155, 0
  br i1 %156, label %157, label %169

157:                                              ; preds = %148
  %158 = load i32, ptr @k, align 4, !tbaa !5
  %159 = add nsw i32 %158, 1
  %160 = sext i32 %159 to i64
  %161 = getelementptr inbounds [350 x [305 x i32]], ptr @dp, i64 0, i64 %160
  %162 = load i32, ptr @i, align 4, !tbaa !5
  %163 = load i32, ptr @j, align 4, !tbaa !5
  %164 = add nsw i32 %162, %163
  %165 = sext i32 %164 to i64
  %166 = getelementptr inbounds [305 x i32], ptr %161, i64 0, i64 %165
  %167 = load i32, ptr %166, align 4, !tbaa !5
  %168 = icmp ne i32 %167, 0
  br label %169

169:                                              ; preds = %157, %148
  %170 = phi i1 [ false, %148 ], [ %168, %157 ]
  %171 = zext i1 %170 to i32
  %172 = load i32, ptr @j, align 4, !tbaa !5
  %173 = sext i32 %172 to i64
  %174 = getelementptr inbounds [350 x [305 x i32]], ptr @dp, i64 0, i64 %173
  %175 = load i32, ptr @i, align 4, !tbaa !5
  %176 = load i32, ptr @j, align 4, !tbaa !5
  %177 = add nsw i32 %175, %176
  %178 = sext i32 %177 to i64
  %179 = getelementptr inbounds [305 x i32], ptr %174, i64 0, i64 %178
  %180 = load i32, ptr %179, align 4, !tbaa !5
  %181 = or i32 %180, %171
  store i32 %181, ptr %179, align 4, !tbaa !5
  br label %182

182:                                              ; preds = %169
  %183 = load i32, ptr @k, align 4, !tbaa !5
  %184 = add nsw i32 %183, 1
  store i32 %184, ptr @k, align 4, !tbaa !5
  br label %142, !llvm.loop !17

185:                                              ; preds = %142
  %186 = load i32, ptr @j, align 4, !tbaa !5
  %187 = sext i32 %186 to i64
  %188 = getelementptr inbounds [305 x [305 x i32]], ptr @f, i64 0, i64 %187
  %189 = load i32, ptr @i, align 4, !tbaa !5
  %190 = load i32, ptr @j, align 4, !tbaa !5
  %191 = add nsw i32 %189, %190
  %192 = sext i32 %191 to i64
  %193 = getelementptr inbounds [305 x i32], ptr %188, i64 0, i64 %192
  %194 = load i32, ptr %193, align 4, !tbaa !5
  %195 = icmp ne i32 %194, 0
  br i1 %195, label %196, label %218

196:                                              ; preds = %185
  %197 = load i32, ptr @j, align 4, !tbaa !5
  %198 = add nsw i32 %197, 1
  %199 = sext i32 %198 to i64
  %200 = getelementptr inbounds [350 x [305 x i32]], ptr @dp, i64 0, i64 %199
  %201 = load i32, ptr @i, align 4, !tbaa !5
  %202 = load i32, ptr @j, align 4, !tbaa !5
  %203 = add nsw i32 %201, %202
  %204 = sub nsw i32 %203, 1
  %205 = sext i32 %204 to i64
  %206 = getelementptr inbounds [305 x i32], ptr %200, i64 0, i64 %205
  %207 = load i32, ptr %206, align 4, !tbaa !5
  %208 = load i32, ptr @j, align 4, !tbaa !5
  %209 = sext i32 %208 to i64
  %210 = getelementptr inbounds [350 x [305 x i32]], ptr @dp, i64 0, i64 %209
  %211 = load i32, ptr @i, align 4, !tbaa !5
  %212 = load i32, ptr @j, align 4, !tbaa !5
  %213 = add nsw i32 %211, %212
  %214 = sext i32 %213 to i64
  %215 = getelementptr inbounds [305 x i32], ptr %210, i64 0, i64 %214
  %216 = load i32, ptr %215, align 4, !tbaa !5
  %217 = or i32 %216, %207
  store i32 %217, ptr %215, align 4, !tbaa !5
  br label %218

218:                                              ; preds = %196, %185
  %219 = load i32, ptr @j, align 4, !tbaa !5
  %220 = add nsw i32 %219, 1
  store i32 %220, ptr @k, align 4, !tbaa !5
  br label %221

221:                                              ; preds = %307, %218
  %222 = load i32, ptr @k, align 4, !tbaa !5
  %223 = load i32, ptr @i, align 4, !tbaa !5
  %224 = load i32, ptr @j, align 4, !tbaa !5
  %225 = add nsw i32 %223, %224
  %226 = icmp slt i32 %222, %225
  br i1 %226, label %227, label %310

227:                                              ; preds = %221
  %228 = load i32, ptr @j, align 4, !tbaa !5
  %229 = sext i32 %228 to i64
  %230 = getelementptr inbounds [305 x [305 x i32]], ptr @f, i64 0, i64 %229
  %231 = load i32, ptr @k, align 4, !tbaa !5
  %232 = sext i32 %231 to i64
  %233 = getelementptr inbounds [305 x i32], ptr %230, i64 0, i64 %232
  %234 = load i32, ptr %233, align 4, !tbaa !5
  %235 = icmp ne i32 %234, 0
  br i1 %235, label %236, label %306

236:                                              ; preds = %227
  %237 = load i32, ptr @k, align 4, !tbaa !5
  %238 = sext i32 %237 to i64
  %239 = getelementptr inbounds [305 x [305 x i32]], ptr @f, i64 0, i64 %238
  %240 = load i32, ptr @i, align 4, !tbaa !5
  %241 = load i32, ptr @j, align 4, !tbaa !5
  %242 = add nsw i32 %240, %241
  %243 = sext i32 %242 to i64
  %244 = getelementptr inbounds [305 x i32], ptr %239, i64 0, i64 %243
  %245 = load i32, ptr %244, align 4, !tbaa !5
  %246 = icmp ne i32 %245, 0
  br i1 %246, label %247, label %306

247:                                              ; preds = %236
  %248 = load i32, ptr @k, align 4, !tbaa !5
  %249 = sext i32 %248 to i64
  %250 = getelementptr inbounds [305 x i32], ptr @a, i64 0, i64 %249
  %251 = load i32, ptr %250, align 4, !tbaa !5
  %252 = load i32, ptr @k, align 4, !tbaa !5
  %253 = sext i32 %252 to i64
  %254 = getelementptr inbounds [305 x i32], ptr @a, i64 0, i64 %253
  %255 = load i32, ptr %254, align 4, !tbaa !5
  %256 = add nsw i32 %251, %255
  %257 = load i32, ptr @j, align 4, !tbaa !5
  %258 = sext i32 %257 to i64
  %259 = getelementptr inbounds [305 x i32], ptr @a, i64 0, i64 %258
  %260 = load i32, ptr %259, align 4, !tbaa !5
  %261 = load i32, ptr @i, align 4, !tbaa !5
  %262 = load i32, ptr @j, align 4, !tbaa !5
  %263 = add nsw i32 %261, %262
  %264 = sext i32 %263 to i64
  %265 = getelementptr inbounds [305 x i32], ptr @a, i64 0, i64 %264
  %266 = load i32, ptr %265, align 4, !tbaa !5
  %267 = add nsw i32 %260, %266
  %268 = icmp eq i32 %256, %267
  br i1 %268, label %269, label %306

269:                                              ; preds = %247
  %270 = load i32, ptr @j, align 4, !tbaa !5
  %271 = add nsw i32 %270, 1
  %272 = sext i32 %271 to i64
  %273 = getelementptr inbounds [350 x [305 x i32]], ptr @dp, i64 0, i64 %272
  %274 = load i32, ptr @k, align 4, !tbaa !5
  %275 = sub nsw i32 %274, 1
  %276 = sext i32 %275 to i64
  %277 = getelementptr inbounds [305 x i32], ptr %273, i64 0, i64 %276
  %278 = load i32, ptr %277, align 4, !tbaa !5
  %279 = icmp ne i32 %278, 0
  br i1 %279, label %280, label %293

280:                                              ; preds = %269
  %281 = load i32, ptr @k, align 4, !tbaa !5
  %282 = add nsw i32 %281, 1
  %283 = sext i32 %282 to i64
  %284 = getelementptr inbounds [350 x [305 x i32]], ptr @dp, i64 0, i64 %283
  %285 = load i32, ptr @i, align 4, !tbaa !5
  %286 = load i32, ptr @j, align 4, !tbaa !5
  %287 = add nsw i32 %285, %286
  %288 = sub nsw i32 %287, 1
  %289 = sext i32 %288 to i64
  %290 = getelementptr inbounds [305 x i32], ptr %284, i64 0, i64 %289
  %291 = load i32, ptr %290, align 4, !tbaa !5
  %292 = icmp ne i32 %291, 0
  br label %293

293:                                              ; preds = %280, %269
  %294 = phi i1 [ false, %269 ], [ %292, %280 ]
  %295 = zext i1 %294 to i32
  %296 = load i32, ptr @j, align 4, !tbaa !5
  %297 = sext i32 %296 to i64
  %298 = getelementptr inbounds [350 x [305 x i32]], ptr @dp, i64 0, i64 %297
  %299 = load i32, ptr @i, align 4, !tbaa !5
  %300 = load i32, ptr @j, align 4, !tbaa !5
  %301 = add nsw i32 %299, %300
  %302 = sext i32 %301 to i64
  %303 = getelementptr inbounds [305 x i32], ptr %298, i64 0, i64 %302
  %304 = load i32, ptr %303, align 4, !tbaa !5
  %305 = or i32 %304, %295
  store i32 %305, ptr %303, align 4, !tbaa !5
  br label %306

306:                                              ; preds = %293, %247, %236, %227
  br label %307

307:                                              ; preds = %306
  %308 = load i32, ptr @k, align 4, !tbaa !5
  %309 = add nsw i32 %308, 1
  store i32 %309, ptr @k, align 4, !tbaa !5
  br label %221, !llvm.loop !18

310:                                              ; preds = %221
  br label %311

311:                                              ; preds = %310
  %312 = load i32, ptr @j, align 4, !tbaa !5
  %313 = add nsw i32 %312, 1
  store i32 %313, ptr @j, align 4, !tbaa !5
  br label %134, !llvm.loop !19

314:                                              ; preds = %134
  br label %315

315:                                              ; preds = %314
  %316 = load i32, ptr @i, align 4, !tbaa !5
  %317 = add nsw i32 %316, 1
  store i32 %317, ptr @i, align 4, !tbaa !5
  br label %129, !llvm.loop !20

318:                                              ; preds = %129
  store i32 1, ptr @i, align 4, !tbaa !5
  br label %319

319:                                              ; preds = %327, %318
  %320 = load i32, ptr @i, align 4, !tbaa !5
  %321 = load i32, ptr @n, align 4, !tbaa !5
  %322 = icmp sle i32 %320, %321
  br i1 %322, label %323, label %330

323:                                              ; preds = %319
  %324 = load i32, ptr @i, align 4, !tbaa !5
  %325 = sext i32 %324 to i64
  %326 = getelementptr inbounds [305 x i32], ptr @DP, i64 0, i64 %325
  store i32 0, ptr %326, align 4, !tbaa !5
  br label %327

327:                                              ; preds = %323
  %328 = load i32, ptr @i, align 4, !tbaa !5
  %329 = add nsw i32 %328, 1
  store i32 %329, ptr @i, align 4, !tbaa !5
  br label %319, !llvm.loop !21

330:                                              ; preds = %319
  store i32 1, ptr @i, align 4, !tbaa !5
  br label %331

331:                                              ; preds = %376, %330
  %332 = load i32, ptr @i, align 4, !tbaa !5
  %333 = load i32, ptr @n, align 4, !tbaa !5
  %334 = icmp sle i32 %332, %333
  br i1 %334, label %335, label %379

335:                                              ; preds = %331
  %336 = load i32, ptr @i, align 4, !tbaa !5
  %337 = sub nsw i32 %336, 1
  %338 = sext i32 %337 to i64
  %339 = getelementptr inbounds [305 x i32], ptr @DP, i64 0, i64 %338
  %340 = load i32, ptr %339, align 4, !tbaa !5
  %341 = add nsw i32 %340, 1
  %342 = load i32, ptr @i, align 4, !tbaa !5
  %343 = sext i32 %342 to i64
  %344 = getelementptr inbounds [305 x i32], ptr @DP, i64 0, i64 %343
  store i32 %341, ptr %344, align 4, !tbaa !5
  store i32 1, ptr @j, align 4, !tbaa !5
  br label %345

345:                                              ; preds = %372, %335
  %346 = load i32, ptr @j, align 4, !tbaa !5
  %347 = load i32, ptr @i, align 4, !tbaa !5
  %348 = icmp slt i32 %346, %347
  br i1 %348, label %349, label %375

349:                                              ; preds = %345
  %350 = load i32, ptr @j, align 4, !tbaa !5
  %351 = sext i32 %350 to i64
  %352 = getelementptr inbounds [350 x [305 x i32]], ptr @dp, i64 0, i64 %351
  %353 = load i32, ptr @i, align 4, !tbaa !5
  %354 = sext i32 %353 to i64
  %355 = getelementptr inbounds [305 x i32], ptr %352, i64 0, i64 %354
  %356 = load i32, ptr %355, align 4, !tbaa !5
  %357 = icmp ne i32 %356, 0
  br i1 %357, label %358, label %371

358:                                              ; preds = %349
  %359 = load i32, ptr @i, align 4, !tbaa !5
  %360 = sext i32 %359 to i64
  %361 = getelementptr inbounds [305 x i32], ptr @DP, i64 0, i64 %360
  %362 = load i32, ptr @j, align 4, !tbaa !5
  %363 = sub nsw i32 %362, 1
  %364 = sext i32 %363 to i64
  %365 = getelementptr inbounds [305 x i32], ptr @DP, i64 0, i64 %364
  %366 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3minIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %361, ptr noundef nonnull align 4 dereferenceable(4) %365)
  %367 = load i32, ptr %366, align 4, !tbaa !5
  %368 = load i32, ptr @i, align 4, !tbaa !5
  %369 = sext i32 %368 to i64
  %370 = getelementptr inbounds [305 x i32], ptr @DP, i64 0, i64 %369
  store i32 %367, ptr %370, align 4, !tbaa !5
  br label %371

371:                                              ; preds = %358, %349
  br label %372

372:                                              ; preds = %371
  %373 = load i32, ptr @j, align 4, !tbaa !5
  %374 = add nsw i32 %373, 1
  store i32 %374, ptr @j, align 4, !tbaa !5
  br label %345, !llvm.loop !22

375:                                              ; preds = %345
  br label %376

376:                                              ; preds = %375
  %377 = load i32, ptr @i, align 4, !tbaa !5
  %378 = add nsw i32 %377, 1
  store i32 %378, ptr @i, align 4, !tbaa !5
  br label %331, !llvm.loop !23

379:                                              ; preds = %331
  %380 = load i32, ptr @n, align 4, !tbaa !5
  %381 = load i32, ptr @n, align 4, !tbaa !5
  %382 = sext i32 %381 to i64
  %383 = getelementptr inbounds [305 x i32], ptr @DP, i64 0, i64 %382
  %384 = load i32, ptr %383, align 4, !tbaa !5
  %385 = sub nsw i32 %380, %384
  %386 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, i32 noundef %385)
  %387 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSoS_E(ptr noundef nonnull align 8 dereferenceable(8) %386, ptr noundef @_ZSt4endlIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_)
  call void @_ZNSt3mapIiiSt4lessIiESaISt4pairIKiiEEE5clearEv(ptr noundef nonnull align 8 dereferenceable(48) @mp) #7
  br label %4, !llvm.loop !24

388:                                              ; preds = %4
  ret i32 0
}

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt3mapIiiSt4lessIiESaISt4pairIKiiEEEixERS3_(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 4 dereferenceable(4)) #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt3mapIiiSt4lessIiESaISt4pairIKiiEEEixEOi(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 4 dereferenceable(4)) #2 align 2

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3minIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4), ptr noundef nonnull align 4 dereferenceable(4)) #4

declare noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8), i32 noundef) #1

; Function Attrs: mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSoS_E(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef) #2 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZSt4endlIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_(ptr noundef nonnull align 8 dereferenceable(8)) #5

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt3mapIiiSt4lessIiESaISt4pairIKiiEEE5clearEv(ptr noundef nonnull align 8 dereferenceable(48)) #6 align 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 = { "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 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 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #4 = { inlinehint 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 #5 = { inlinehint 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 #6 = { 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 #7 = { 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 = distinct !{!13, !10}
!14 = distinct !{!14, !10}
!15 = distinct !{!15, !10}
!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"

%"class.std::map" = type { %"class.std::_Rb_tree" }
%"class.std::_Rb_tree" = type { %"struct.std::_Rb_tree<int, std::pair<const int, int>, std::_Select1st<std::pair<const int, int>>, std::less<int>>::_Rb_tree_impl" }
%"struct.std::_Rb_tree<int, std::pair<const int, int>, std::_Select1st<std::pair<const int, int>>, std::less<int>>::_Rb_tree_impl" = type { [8 x i8], %"struct.std::_Rb_tree_header" }
%"struct.std::_Rb_tree_header" = type { %"struct.std::_Rb_tree_node_base", i64 }
%"struct.std::_Rb_tree_node_base" = type { i32, ptr, ptr, ptr }
%"class.std::basic_ostream" = type { ptr, %"class.std::basic_ios" }
%"class.std::basic_ios" = type { %"class.std::ios_base", ptr, i8, i8, ptr, ptr, ptr, ptr }
%"class.std::ios_base" = type { ptr, i64, i64, i32, i32, i32, ptr, %"struct.std::ios_base::_Words", [8 x %"struct.std::ios_base::_Words"], i32, ptr, %"class.std::locale" }
%"struct.std::ios_base::_Words" = type { ptr, i64 }
%"class.std::locale" = type { ptr }

@f = external dso_local local_unnamed_addr global [305 x [305 x i32]], align 16
@n = external dso_local global i32, align 4
@m = external dso_local global i32, align 4
@i = external dso_local local_unnamed_addr global i32, align 4
@T = external dso_local global i32, align 4
@j = external dso_local local_unnamed_addr global i32, align 4
@dp = external dso_local local_unnamed_addr global [350 x [305 x i32]], align 16
@DP = external dso_local global [305 x i32], align 16
@b = external dso_local global [305 x i32], align 16
@a = external dso_local global [305 x i32], align 16
@k = external dso_local local_unnamed_addr global i32, align 4
@mp = external dso_local global %"class.std::map", align 8
@.str = external hidden unnamed_addr constant [3 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [5 x i8], align 1
@_ZSt4cout = external global %"class.std::basic_ostream", align 8

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() local_unnamed_addr #0 {
  %1 = alloca i32, align 4
  %2 = tail call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull @T)
  %3 = load i32, ptr @T, align 4, !tbaa !5
  %4 = add nsw i32 %3, -1
  store i32 %4, ptr @T, align 4, !tbaa !5
  %.not112 = icmp eq i32 %3, 0
  br i1 %.not112, label %._crit_edge115, label %.lr.ph114

.lr.ph114:                                        ; preds = %0, %._crit_edge110
  %5 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str.2, ptr noundef nonnull @n, ptr noundef nonnull @m)
  store i32 1, ptr @i, align 4, !tbaa !5
  %6 = load i32, ptr @n, align 4, !tbaa !5
  %.not1761 = icmp slt i32 %6, 1
  br i1 %.not1761, label %.preheader57, label %.lr.ph

.preheader57:                                     ; preds = %.lr.ph, %.lr.ph114
  %7 = phi i32 [ %6, %.lr.ph114 ], [ %14, %.lr.ph ]
  store i32 1, ptr @i, align 4, !tbaa !5
  %8 = load i32, ptr @m, align 4, !tbaa !5
  %.not1963 = icmp slt i32 %8, 1
  br i1 %.not1963, label %.preheader56, label %.lr.ph65

.lr.ph:                                           ; preds = %.lr.ph114, %.lr.ph
  %storemerge62 = phi i32 [ %13, %.lr.ph ], [ 1, %.lr.ph114 ]
  %9 = sext i32 %storemerge62 to i64
  %10 = getelementptr inbounds [305 x i32], ptr @a, i64 0, i64 %9
  %11 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull %10)
  %12 = load i32, ptr @i, align 4, !tbaa !5
  %13 = add nsw i32 %12, 1
  store i32 %13, ptr @i, align 4, !tbaa !5
  %14 = load i32, ptr @n, align 4, !tbaa !5
  %.not17.not = icmp slt i32 %12, %14
  br i1 %.not17.not, label %.lr.ph, label %.preheader57, !llvm.loop !9

.preheader56.loopexit:                            ; preds = %.lr.ph65
  %.pre = load i32, ptr @n, align 4, !tbaa !5
  br label %.preheader56

.preheader56:                                     ; preds = %.preheader56.loopexit, %.preheader57
  %15 = phi i32 [ %.pre, %.preheader56.loopexit ], [ %7, %.preheader57 ]
  store i32 1, ptr @i, align 4, !tbaa !5
  %.not2170 = icmp slt i32 %15, 1
  br i1 %.not2170, label %.preheader54, label %.preheader50

.lr.ph65:                                         ; preds = %.preheader57, %.lr.ph65
  %storemerge1864 = phi i32 [ %24, %.lr.ph65 ], [ 1, %.preheader57 ]
  %16 = sext i32 %storemerge1864 to i64
  %17 = getelementptr inbounds [305 x i32], ptr @b, i64 0, i64 %16
  %18 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull %17)
  %19 = load i32, ptr @i, align 4, !tbaa !5
  %20 = sext i32 %19 to i64
  %21 = getelementptr inbounds [305 x i32], ptr @b, i64 0, i64 %20
  %22 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt3mapIiiSt4lessIiESaISt4pairIKiiEEEixERS3_(ptr noundef nonnull align 8 dereferenceable(48) @mp, ptr noundef nonnull align 4 dereferenceable(4) %21)
  store i32 1, ptr %22, align 4, !tbaa !5
  %23 = load i32, ptr @i, align 4, !tbaa !5
  %24 = add nsw i32 %23, 1
  store i32 %24, ptr @i, align 4, !tbaa !5
  %25 = load i32, ptr @m, align 4, !tbaa !5
  %.not19.not = icmp slt i32 %23, %25
  br i1 %.not19.not, label %.lr.ph65, label %.preheader56.loopexit, !llvm.loop !11

.preheader55:                                     ; preds = %._crit_edge
  %.not2373 = icmp slt i32 %45, 1
  br i1 %.not2373, label %.preheader54, label %.preheader49.preheader

.preheader49.preheader:                           ; preds = %.preheader55
  %26 = add nuw i32 %45, 1
  %wide.trip.count128 = zext nneg i32 %45 to i64
  %xtraiter = and i64 %wide.trip.count128, 1
  %27 = icmp eq i32 %45, 1
  br i1 %27, label %..preheader54_crit_edge.unr-lcssa, label %.preheader49.preheader.new

.preheader49.preheader.new:                       ; preds = %.preheader49.preheader
  %unroll_iter = and i64 %wide.trip.count128, 2147483646
  br label %.preheader49

.preheader50:                                     ; preds = %.preheader56, %._crit_edge
  %28 = phi i32 [ %45, %._crit_edge ], [ %15, %.preheader56 ]
  %storemerge2071 = phi i32 [ %.pre-phi, %._crit_edge ], [ 1, %.preheader56 ]
  %storemerge4566 = add nsw i32 %storemerge2071, 1
  store i32 %storemerge4566, ptr @j, align 4, !tbaa !5
  %.not46.not67 = icmp slt i32 %storemerge2071, %28
  br i1 %.not46.not67, label %.lr.ph69, label %._crit_edge

.lr.ph69:                                         ; preds = %.preheader50, %.lr.ph69
  %29 = phi i32 [ %39, %.lr.ph69 ], [ %storemerge2071, %.preheader50 ]
  %storemerge4568 = phi i32 [ %storemerge45, %.lr.ph69 ], [ %storemerge4566, %.preheader50 ]
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %1) #9
  %30 = sext i32 %storemerge4568 to i64
  %31 = getelementptr inbounds [305 x i32], ptr @a, i64 0, i64 %30
  %32 = load i32, ptr %31, align 4, !tbaa !5
  %33 = sext i32 %29 to i64
  %34 = getelementptr inbounds [305 x i32], ptr @a, i64 0, i64 %33
  %35 = load i32, ptr %34, align 4, !tbaa !5
  %36 = sub nsw i32 %32, %35
  store i32 %36, ptr %1, align 4, !tbaa !5
  %37 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt3mapIiiSt4lessIiESaISt4pairIKiiEEEixEOi(ptr noundef nonnull align 8 dereferenceable(48) @mp, ptr noundef nonnull align 4 dereferenceable(4) %1)
  %38 = load i32, ptr %37, align 4, !tbaa !5
  %.not47 = icmp ne i32 %38, 0
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %1) #9
  %39 = load i32, ptr @i, align 4, !tbaa !5
  %40 = sext i32 %39 to i64
  %41 = load i32, ptr @j, align 4, !tbaa !5
  %42 = sext i32 %41 to i64
  %43 = getelementptr inbounds [305 x [305 x i32]], ptr @f, i64 0, i64 %40, i64 %42
  %. = zext i1 %.not47 to i32
  store i32 %., ptr %43, align 4, !tbaa !5
  %storemerge45 = add nsw i32 %41, 1
  store i32 %storemerge45, ptr @j, align 4, !tbaa !5
  %44 = load i32, ptr @n, align 4, !tbaa !5
  %.not46.not = icmp slt i32 %41, %44
  br i1 %.not46.not, label %.lr.ph69, label %._crit_edge.loopexit, !llvm.loop !12

._crit_edge.loopexit:                             ; preds = %.lr.ph69
  %.pre172 = add nsw i32 %39, 1
  br label %._crit_edge

._crit_edge:                                      ; preds = %._crit_edge.loopexit, %.preheader50
  %.pre-phi = phi i32 [ %.pre172, %._crit_edge.loopexit ], [ %storemerge4566, %.preheader50 ]
  %45 = phi i32 [ %44, %._crit_edge.loopexit ], [ %28, %.preheader50 ]
  %46 = phi i32 [ %39, %._crit_edge.loopexit ], [ %storemerge2071, %.preheader50 ]
  store i32 %.pre-phi, ptr @i, align 4, !tbaa !5
  %.not21.not = icmp slt i32 %46, %45
  br i1 %.not21.not, label %.preheader50, label %.preheader55, !llvm.loop !13

..preheader54_crit_edge.unr-lcssa:                ; preds = %.preheader49, %.preheader49.preheader
  %indvar.unr = phi i64 [ 0, %.preheader49.preheader ], [ %indvar.next.1, %.preheader49 ]
  %lcmp.mod.not = icmp eq i64 %xtraiter, 0
  br i1 %lcmp.mod.not, label %..preheader54_crit_edge, label %.preheader49.epil

.preheader49.epil:                                ; preds = %..preheader54_crit_edge.unr-lcssa
  %47 = mul nuw nsw i64 %indvar.unr, 1224
  %gep.epil = getelementptr i8, ptr getelementptr inbounds (i8, ptr @dp, i64 1224), i64 %47
  %48 = trunc i64 %indvar.unr to i32
  %49 = xor i32 %48, -1
  %50 = add i32 %45, %49
  %51 = zext i32 %50 to i64
  %52 = shl nuw nsw i64 %51, 2
  %53 = add nuw nsw i64 %52, 4
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(1) %gep.epil, i8 0, i64 %53, i1 false), !tbaa !5
  br label %..preheader54_crit_edge

..preheader54_crit_edge:                          ; preds = %..preheader54_crit_edge.unr-lcssa, %.preheader49.epil
  store i32 %26, ptr @j, align 4, !tbaa !5
  br label %.preheader54

.preheader54:                                     ; preds = %.preheader56, %..preheader54_crit_edge, %.preheader55
  %.not2373179 = phi i1 [ %.not2373, %..preheader54_crit_edge ], [ true, %.preheader55 ], [ true, %.preheader56 ]
  %54 = phi i32 [ %45, %..preheader54_crit_edge ], [ %45, %.preheader55 ], [ %15, %.preheader56 ]
  %.not2576 = icmp slt i32 %54, 0
  br i1 %.not2576, label %.preheader53, label %.lr.ph78.preheader

.lr.ph78.preheader:                               ; preds = %.preheader54
  %55 = add nuw i32 %54, 1
  %56 = zext i32 %55 to i64
  %xtraiter202 = and i64 %56, 3
  %57 = icmp ult i32 %54, 3
  br i1 %57, label %.preheader53.loopexit.unr-lcssa, label %.lr.ph78.preheader.new

.lr.ph78.preheader.new:                           ; preds = %.lr.ph78.preheader
  %unroll_iter204 = and i64 %56, 4294967292
  br label %.lr.ph78

.preheader49:                                     ; preds = %.preheader49, %.preheader49.preheader.new
  %indvar = phi i64 [ 0, %.preheader49.preheader.new ], [ %indvar.next.1, %.preheader49 ]
  %niter = phi i64 [ 0, %.preheader49.preheader.new ], [ %niter.next.1, %.preheader49 ]
  %58 = mul nuw nsw i64 %indvar, 1224
  %gep = getelementptr i8, ptr getelementptr inbounds (i8, ptr @dp, i64 1224), i64 %58
  %59 = trunc i64 %indvar to i32
  %60 = xor i32 %59, -1
  %61 = add i32 %45, %60
  %62 = zext i32 %61 to i64
  %63 = shl nuw nsw i64 %62, 2
  %64 = add nuw nsw i64 %63, 4
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(1) %gep, i8 0, i64 %64, i1 false), !tbaa !5
  %indvar.next = or disjoint i64 %indvar, 1
  %65 = mul nuw nsw i64 %indvar.next, 1224
  %gep.1 = getelementptr i8, ptr getelementptr inbounds (i8, ptr @dp, i64 1224), i64 %65
  %66 = trunc i64 %indvar.next to i32
  %67 = xor i32 %66, -1
  %68 = add i32 %45, %67
  %69 = zext i32 %68 to i64
  %70 = shl nuw nsw i64 %69, 2
  %71 = add nuw nsw i64 %70, 4
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 16 dereferenceable(1) %gep.1, i8 0, i64 %71, i1 false), !tbaa !5
  %indvar.next.1 = add nuw nsw i64 %indvar, 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 %..preheader54_crit_edge.unr-lcssa, label %.preheader49, !llvm.loop !14

.preheader53.loopexit.unr-lcssa:                  ; preds = %.lr.ph78, %.lr.ph78.preheader
  %indvars.iv130.unr = phi i64 [ 1, %.lr.ph78.preheader ], [ %indvars.iv.next131.3, %.lr.ph78 ]
  %lcmp.mod203.not = icmp eq i64 %xtraiter202, 0
  br i1 %lcmp.mod203.not, label %.preheader53, label %.lr.ph78.epil

.lr.ph78.epil:                                    ; preds = %.preheader53.loopexit.unr-lcssa, %.lr.ph78.epil
  %indvars.iv130.epil = phi i64 [ %indvars.iv.next131.epil, %.lr.ph78.epil ], [ %indvars.iv130.unr, %.preheader53.loopexit.unr-lcssa ]
  %epil.iter = phi i64 [ %epil.iter.next, %.lr.ph78.epil ], [ 0, %.preheader53.loopexit.unr-lcssa ]
  %72 = add nsw i64 %indvars.iv130.epil, -1
  %73 = getelementptr inbounds [350 x [305 x i32]], ptr @dp, i64 0, i64 %indvars.iv130.epil, i64 %72
  store i32 1, ptr %73, align 4, !tbaa !5
  %indvars.iv.next131.epil = add nuw nsw i64 %indvars.iv130.epil, 1
  %epil.iter.next = add i64 %epil.iter, 1
  %epil.iter.cmp.not = icmp eq i64 %epil.iter.next, %xtraiter202
  br i1 %epil.iter.cmp.not, label %.preheader53, label %.lr.ph78.epil, !llvm.loop !15

.preheader53:                                     ; preds = %.preheader53.loopexit.unr-lcssa, %.lr.ph78.epil, %.preheader54
  br i1 %.not2373179, label %.preheader51.thread, label %.preheader48.preheader

.preheader48.preheader:                           ; preds = %.preheader53
  %74 = add nuw i32 %54, 1
  %75 = zext nneg i32 %54 to i64
  %wide.trip.count165 = zext i32 %74 to i64
  br label %.preheader48

.lr.ph78:                                         ; preds = %.lr.ph78, %.lr.ph78.preheader.new
  %indvars.iv130 = phi i64 [ 1, %.lr.ph78.preheader.new ], [ %indvars.iv.next131.3, %.lr.ph78 ]
  %niter205 = phi i64 [ 0, %.lr.ph78.preheader.new ], [ %niter205.next.3, %.lr.ph78 ]
  %76 = add nsw i64 %indvars.iv130, -1
  %77 = getelementptr inbounds [350 x [305 x i32]], ptr @dp, i64 0, i64 %indvars.iv130, i64 %76
  store i32 1, ptr %77, align 4, !tbaa !5
  %indvars.iv.next131 = add nuw nsw i64 %indvars.iv130, 1
  %78 = getelementptr inbounds [350 x [305 x i32]], ptr @dp, i64 0, i64 %indvars.iv.next131, i64 %indvars.iv130
  store i32 1, ptr %78, align 4, !tbaa !5
  %indvars.iv.next131.1 = add nuw nsw i64 %indvars.iv130, 2
  %79 = add nuw nsw i64 %indvars.iv130, 1
  %80 = getelementptr inbounds [350 x [305 x i32]], ptr @dp, i64 0, i64 %indvars.iv.next131.1, i64 %79
  store i32 1, ptr %80, align 4, !tbaa !5
  %indvars.iv.next131.2 = add nuw nsw i64 %indvars.iv130, 3
  %81 = add nuw nsw i64 %indvars.iv130, 2
  %82 = getelementptr inbounds [350 x [305 x i32]], ptr @dp, i64 0, i64 %indvars.iv.next131.2, i64 %81
  store i32 1, ptr %82, align 4, !tbaa !5
  %indvars.iv.next131.3 = add nuw nsw i64 %indvars.iv130, 4
  %niter205.next.3 = add nuw i64 %niter205, 4
  %niter205.ncmp.3 = icmp eq i64 %niter205.next.3, %unroll_iter204
  br i1 %niter205.ncmp.3, label %.preheader53.loopexit.unr-lcssa, label %.lr.ph78, !llvm.loop !17

.preheader52:                                     ; preds = %161
  store i32 %storemerge34.lcssa, ptr @j, align 4, !tbaa !5
  br i1 %.not2373179, label %.preheader51.thread, label %.lr.ph109.preheader

.preheader48:                                     ; preds = %.preheader48.preheader, %161
  %indvar206 = phi i64 [ 0, %.preheader48.preheader ], [ %indvar.next207, %161 ]
  %indvars.iv160 = phi i64 [ 1, %.preheader48.preheader ], [ %indvars.iv.next161, %161 ]
  %indvars.iv151 = phi i64 [ 2, %.preheader48.preheader ], [ %indvars.iv.next152, %161 ]
  %.not3590.not = icmp ult i64 %indvars.iv160, %75
  br i1 %.not3590.not, label %.preheader.preheader, label %161

.preheader.preheader:                             ; preds = %.preheader48
  %83 = icmp ugt i64 %indvars.iv160, 1
  %xtraiter208 = and i64 %indvars.iv160, 1
  %lcmp.mod209.not = icmp eq i64 %xtraiter208, 0
  %84 = icmp eq i64 %indvar206, 0
  br label %.preheader

.preheader:                                       ; preds = %.preheader.preheader, %._crit_edge87
  %indvars.iv153 = phi i64 [ %indvars.iv151, %.preheader.preheader ], [ %indvars.iv.next154, %._crit_edge87 ]
  %indvars.iv146 = phi i32 [ 2, %.preheader.preheader ], [ %indvars.iv.next147, %._crit_edge87 ]
  %indvars.iv135 = phi i64 [ 1, %.preheader.preheader ], [ %.pre176, %._crit_edge87 ]
  %85 = sext i32 %indvars.iv146 to i64
  %86 = add nuw nsw i64 %indvars.iv135, %indvars.iv160
  %87 = getelementptr inbounds [350 x [305 x i32]], ptr @dp, i64 0, i64 %indvars.iv135, i64 %86
  %.promoted = load i32, ptr %87, align 4, !tbaa !5
  br i1 %lcmp.mod209.not, label %.prol.loopexit, label %.prol.preheader

.prol.preheader:                                  ; preds = %.preheader
  %88 = getelementptr inbounds [350 x [305 x i32]], ptr @dp, i64 0, i64 %indvars.iv135, i64 %indvars.iv135
  %89 = load i32, ptr %88, align 4, !tbaa !5
  %.not42.prol = icmp eq i32 %89, 0
  %.pre175.prol = add nuw nsw i64 %indvars.iv135, 1
  br i1 %.not42.prol, label %._crit_edge174.prol, label %90

90:                                               ; preds = %.prol.preheader
  %91 = getelementptr inbounds [350 x [305 x i32]], ptr @dp, i64 0, i64 %.pre175.prol, i64 %86
  %92 = load i32, ptr %91, align 4, !tbaa !5
  %93 = icmp ne i32 %92, 0
  br label %._crit_edge174.prol

._crit_edge174.prol:                              ; preds = %90, %.prol.preheader
  %94 = phi i1 [ %93, %90 ], [ false, %.prol.preheader ]
  %95 = zext i1 %94 to i32
  %96 = or i32 %.promoted, %95
  store i32 %96, ptr %87, align 4, !tbaa !5
  br label %.prol.loopexit

.prol.loopexit:                                   ; preds = %._crit_edge174.prol, %.preheader
  %.lcssa198.unr = phi i32 [ poison, %.preheader ], [ %96, %._crit_edge174.prol ]
  %indvars.iv137.unr = phi i64 [ %indvars.iv135, %.preheader ], [ %.pre175.prol, %._crit_edge174.prol ]
  %.unr = phi i32 [ %.promoted, %.preheader ], [ %96, %._crit_edge174.prol ]
  br i1 %84, label %.unr-lcssa, label %.preheader.new

.preheader.new:                                   ; preds = %.prol.loopexit, %._crit_edge174.1
  %indvars.iv137 = phi i64 [ %.pre175.1, %._crit_edge174.1 ], [ %indvars.iv137.unr, %.prol.loopexit ]
  %97 = phi i32 [ %115, %._crit_edge174.1 ], [ %.unr, %.prol.loopexit ]
  %98 = getelementptr inbounds [350 x [305 x i32]], ptr @dp, i64 0, i64 %indvars.iv135, i64 %indvars.iv137
  %99 = load i32, ptr %98, align 4, !tbaa !5
  %.not42 = icmp eq i32 %99, 0
  %.pre175 = add nuw nsw i64 %indvars.iv137, 1
  br i1 %.not42, label %._crit_edge174, label %100

100:                                              ; preds = %.preheader.new
  %101 = getelementptr inbounds [350 x [305 x i32]], ptr @dp, i64 0, i64 %.pre175, i64 %86
  %102 = load i32, ptr %101, align 4, !tbaa !5
  %103 = icmp ne i32 %102, 0
  br label %._crit_edge174

._crit_edge174:                                   ; preds = %.preheader.new, %100
  %104 = phi i1 [ %103, %100 ], [ false, %.preheader.new ]
  %105 = zext i1 %104 to i32
  %106 = or i32 %97, %105
  store i32 %106, ptr %87, align 4, !tbaa !5
  %107 = getelementptr inbounds [350 x [305 x i32]], ptr @dp, i64 0, i64 %indvars.iv135, i64 %.pre175
  %108 = load i32, ptr %107, align 4, !tbaa !5
  %.not42.1 = icmp eq i32 %108, 0
  %.pre175.1 = add nuw nsw i64 %indvars.iv137, 2
  br i1 %.not42.1, label %._crit_edge174.1, label %109

109:                                              ; preds = %._crit_edge174
  %110 = getelementptr inbounds [350 x [305 x i32]], ptr @dp, i64 0, i64 %.pre175.1, i64 %86
  %111 = load i32, ptr %110, align 4, !tbaa !5
  %112 = icmp ne i32 %111, 0
  br label %._crit_edge174.1

._crit_edge174.1:                                 ; preds = %109, %._crit_edge174
  %113 = phi i1 [ %112, %109 ], [ false, %._crit_edge174 ]
  %114 = zext i1 %113 to i32
  %115 = or i32 %106, %114
  store i32 %115, ptr %87, align 4, !tbaa !5
  %exitcond145.not.1 = icmp eq i64 %.pre175.1, %indvars.iv153
  br i1 %exitcond145.not.1, label %.unr-lcssa, label %.preheader.new, !llvm.loop !18

.unr-lcssa:                                       ; preds = %._crit_edge174.1, %.prol.loopexit
  %.lcssa198 = phi i32 [ %.lcssa198.unr, %.prol.loopexit ], [ %115, %._crit_edge174.1 ]
  %116 = getelementptr inbounds [305 x [305 x i32]], ptr @f, i64 0, i64 %indvars.iv135, i64 %86
  %117 = load i32, ptr %116, align 4, !tbaa !5
  %.not37 = icmp eq i32 %117, 0
  %.pre176 = add nuw nsw i64 %indvars.iv135, 1
  br i1 %.not37, label %._crit_edge173, label %118

118:                                              ; preds = %.unr-lcssa
  %119 = add nsw i64 %86, -1
  %120 = getelementptr inbounds [350 x [305 x i32]], ptr @dp, i64 0, i64 %.pre176, i64 %119
  %121 = load i32, ptr %120, align 4, !tbaa !5
  %122 = or i32 %.lcssa198, %121
  store i32 %122, ptr %87, align 4, !tbaa !5
  br label %._crit_edge173

._crit_edge173:                                   ; preds = %.unr-lcssa, %118
  %123 = phi i32 [ %122, %118 ], [ %.lcssa198, %.unr-lcssa ]
  %124 = trunc nsw i64 %.pre176 to i32
  br i1 %83, label %.lr.ph86, label %._crit_edge87

.lr.ph86:                                         ; preds = %._crit_edge173
  %125 = getelementptr inbounds [305 x i32], ptr @a, i64 0, i64 %indvars.iv135
  %126 = getelementptr inbounds [305 x i32], ptr @a, i64 0, i64 %86
  %127 = add nsw i64 %86, -1
  br label %128

128:                                              ; preds = %.lr.ph86, %157
  %129 = phi i32 [ %123, %.lr.ph86 ], [ %158, %157 ]
  %indvars.iv148 = phi i64 [ %85, %.lr.ph86 ], [ %indvars.iv.next149, %157 ]
  %storemerge38.in83.in = phi i64 [ %indvars.iv135, %.lr.ph86 ], [ %indvars.iv148, %157 ]
  %130 = getelementptr inbounds [305 x [305 x i32]], ptr @f, i64 0, i64 %indvars.iv135, i64 %indvars.iv148
  %131 = load i32, ptr %130, align 4, !tbaa !5
  %.not39 = icmp eq i32 %131, 0
  br i1 %.not39, label %157, label %132

132:                                              ; preds = %128
  %133 = getelementptr inbounds [305 x [305 x i32]], ptr @f, i64 0, i64 %indvars.iv148, i64 %86
  %134 = load i32, ptr %133, align 4, !tbaa !5
  %.not40 = icmp eq i32 %134, 0
  br i1 %.not40, label %157, label %135

135:                                              ; preds = %132
  %136 = getelementptr inbounds [305 x i32], ptr @a, i64 0, i64 %indvars.iv148
  %137 = load i32, ptr %136, align 4, !tbaa !5
  %138 = shl nsw i32 %137, 1
  %139 = load i32, ptr %125, align 4, !tbaa !5
  %140 = load i32, ptr %126, align 4, !tbaa !5
  %141 = add nsw i32 %140, %139
  %142 = icmp eq i32 %138, %141
  br i1 %142, label %143, label %157

143:                                              ; preds = %135
  %sext = shl i64 %storemerge38.in83.in, 32
  %144 = ashr exact i64 %sext, 32
  %145 = getelementptr inbounds [350 x [305 x i32]], ptr @dp, i64 0, i64 %.pre176, i64 %144
  %146 = load i32, ptr %145, align 4, !tbaa !5
  %.not41 = icmp eq i32 %146, 0
  br i1 %.not41, label %153, label %147

147:                                              ; preds = %143
  %148 = shl i64 %storemerge38.in83.in, 32
  %sext177 = add i64 %148, 8589934592
  %149 = ashr exact i64 %sext177, 32
  %150 = getelementptr inbounds [350 x [305 x i32]], ptr @dp, i64 0, i64 %149, i64 %127
  %151 = load i32, ptr %150, align 4, !tbaa !5
  %152 = icmp ne i32 %151, 0
  br label %153

153:                                              ; preds = %147, %143
  %154 = phi i1 [ false, %143 ], [ %152, %147 ]
  %155 = zext i1 %154 to i32
  %156 = or i32 %129, %155
  store i32 %156, ptr %87, align 4, !tbaa !5
  br label %157

157:                                              ; preds = %128, %132, %135, %153
  %158 = phi i32 [ %129, %128 ], [ %129, %132 ], [ %129, %135 ], [ %156, %153 ]
  %indvars.iv.next149 = add nuw nsw i64 %indvars.iv148, 1
  %159 = icmp ult i64 %indvars.iv.next149, %86
  br i1 %159, label %128, label %._crit_edge87.loopexit, !llvm.loop !19

._crit_edge87.loopexit:                           ; preds = %157
  %160 = trunc nsw i64 %indvars.iv.next149 to i32
  br label %._crit_edge87

._crit_edge87:                                    ; preds = %._crit_edge87.loopexit, %._crit_edge173
  %storemerge38.lcssa94 = phi i32 [ %124, %._crit_edge173 ], [ %160, %._crit_edge87.loopexit ]
  %indvars.iv.next154 = add nuw nsw i64 %indvars.iv153, 1
  %indvars.iv.next147 = add nuw i32 %indvars.iv146, 1
  %exitcond159.not = icmp eq i64 %indvars.iv.next154, %wide.trip.count165
  br i1 %exitcond159.not, label %._crit_edge92, label %.preheader, !llvm.loop !20

._crit_edge92:                                    ; preds = %._crit_edge87
  store i32 %storemerge38.lcssa94, ptr @k, align 4, !tbaa !5
  br label %161

161:                                              ; preds = %._crit_edge92, %.preheader48
  %storemerge34.lcssa = phi i32 [ %124, %._crit_edge92 ], [ 1, %.preheader48 ]
  %indvars.iv.next161 = add nuw nsw i64 %indvars.iv160, 1
  %indvars.iv.next152 = add nuw nsw i64 %indvars.iv151, 1
  %exitcond166.not = icmp eq i64 %indvars.iv.next161, %wide.trip.count165
  %indvar.next207 = add i64 %indvar206, 1
  br i1 %exitcond166.not, label %.preheader52, label %.preheader48, !llvm.loop !21

.preheader51.thread:                              ; preds = %.preheader53, %.preheader52
  store i32 1, ptr @i, align 4, !tbaa !5
  br label %._crit_edge110

.lr.ph109.preheader:                              ; preds = %.preheader52
  %162 = zext nneg i32 %54 to i64
  %163 = shl nuw nsw i64 %162, 2
  call void @llvm.memset.p0.i64(ptr nonnull align 4 getelementptr inbounds (i8, ptr @DP, i64 4), i8 0, i64 %163, i1 false), !tbaa !5
  store i32 1, ptr @i, align 4, !tbaa !5
  br label %.lr.ph109

.lr.ph109:                                        ; preds = %.lr.ph109.preheader, %._crit_edge105
  %164 = phi i32 [ %194, %._crit_edge105 ], [ %54, %.lr.ph109.preheader ]
  %165 = phi i32 [ %195, %._crit_edge105 ], [ 1, %.lr.ph109.preheader ]
  %166 = add nsw i32 %165, -1
  %167 = sext i32 %166 to i64
  %168 = getelementptr inbounds [305 x i32], ptr @DP, i64 0, i64 %167
  %169 = load i32, ptr %168, align 4, !tbaa !5
  %170 = add nsw i32 %169, 1
  %171 = sext i32 %165 to i64
  %172 = getelementptr inbounds [305 x i32], ptr @DP, i64 0, i64 %171
  store i32 %170, ptr %172, align 4, !tbaa !5
  store i32 1, ptr @j, align 4, !tbaa !5
  %173 = icmp sgt i32 %165, 1
  br i1 %173, label %.lr.ph104, label %._crit_edge105

.lr.ph104:                                        ; preds = %.lr.ph109, %189
  %174 = phi i32 [ %190, %189 ], [ %165, %.lr.ph109 ]
  %storemerge32102 = phi i32 [ %192, %189 ], [ 1, %.lr.ph109 ]
  %175 = sext i32 %storemerge32102 to i64
  %176 = sext i32 %174 to i64
  %177 = getelementptr inbounds [350 x [305 x i32]], ptr @dp, i64 0, i64 %175, i64 %176
  %178 = load i32, ptr %177, align 4, !tbaa !5
  %.not33 = icmp eq i32 %178, 0
  br i1 %.not33, label %189, label %179

179:                                              ; preds = %.lr.ph104
  %180 = getelementptr inbounds [305 x i32], ptr @DP, i64 0, i64 %176
  %181 = add nsw i32 %storemerge32102, -1
  %182 = sext i32 %181 to i64
  %183 = getelementptr inbounds [305 x i32], ptr @DP, i64 0, i64 %182
  %184 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3minIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %180, ptr noundef nonnull align 4 dereferenceable(4) %183)
  %185 = load i32, ptr %184, align 4, !tbaa !5
  %186 = load i32, ptr @i, align 4, !tbaa !5
  %187 = sext i32 %186 to i64
  %188 = getelementptr inbounds [305 x i32], ptr @DP, i64 0, i64 %187
  store i32 %185, ptr %188, align 4, !tbaa !5
  %.pre170 = load i32, ptr @j, align 4, !tbaa !5
  br label %189

189:                                              ; preds = %.lr.ph104, %179
  %190 = phi i32 [ %174, %.lr.ph104 ], [ %186, %179 ]
  %191 = phi i32 [ %storemerge32102, %.lr.ph104 ], [ %.pre170, %179 ]
  %192 = add nsw i32 %191, 1
  store i32 %192, ptr @j, align 4, !tbaa !5
  %193 = icmp slt i32 %192, %190
  br i1 %193, label %.lr.ph104, label %._crit_edge105.loopexit, !llvm.loop !22

._crit_edge105.loopexit:                          ; preds = %189
  %.pre171 = load i32, ptr @n, align 4, !tbaa !5
  br label %._crit_edge105

._crit_edge105:                                   ; preds = %._crit_edge105.loopexit, %.lr.ph109
  %194 = phi i32 [ %164, %.lr.ph109 ], [ %.pre171, %._crit_edge105.loopexit ]
  %.lcssa59 = phi i32 [ %165, %.lr.ph109 ], [ %190, %._crit_edge105.loopexit ]
  %195 = add nsw i32 %.lcssa59, 1
  store i32 %195, ptr @i, align 4, !tbaa !5
  %.not31.not = icmp slt i32 %.lcssa59, %194
  br i1 %.not31.not, label %.lr.ph109, label %._crit_edge110, !llvm.loop !23

._crit_edge110:                                   ; preds = %._crit_edge105, %.preheader51.thread
  %.lcssa60 = phi i32 [ %54, %.preheader51.thread ], [ %194, %._crit_edge105 ]
  %196 = sext i32 %.lcssa60 to i64
  %197 = getelementptr inbounds [305 x i32], ptr @DP, i64 0, i64 %196
  %198 = load i32, ptr %197, align 4, !tbaa !5
  %199 = sub nsw i32 %.lcssa60, %198
  %200 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, i32 noundef %199)
  %201 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSoS_E(ptr noundef nonnull align 8 dereferenceable(8) %200, ptr noundef nonnull @_ZSt4endlIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_)
  call void @_ZNSt3mapIiiSt4lessIiESaISt4pairIKiiEEE5clearEv(ptr noundef nonnull align 8 dereferenceable(48) @mp) #9
  %202 = load i32, ptr @T, align 4, !tbaa !5
  %203 = add nsw i32 %202, -1
  store i32 %203, ptr @T, align 4, !tbaa !5
  %.not = icmp eq i32 %202, 0
  br i1 %.not, label %._crit_edge115, label %.lr.ph114, !llvm.loop !24

._crit_edge115:                                   ; preds = %._crit_edge110, %0
  ret i32 0
}

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt3mapIiiSt4lessIiESaISt4pairIKiiEEEixERS3_(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 4 dereferenceable(4)) local_unnamed_addr #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt3mapIiiSt4lessIiESaISt4pairIKiiEEEixEOi(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 4 dereferenceable(4)) local_unnamed_addr #2 align 2

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3minIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4), ptr noundef nonnull align 4 dereferenceable(4)) local_unnamed_addr #4

declare noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8), i32 noundef) local_unnamed_addr #5

; Function Attrs: mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSoS_E(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef) local_unnamed_addr #2 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZSt4endlIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_(ptr noundef nonnull align 8 dereferenceable(8)) #6

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt3mapIiiSt4lessIiESaISt4pairIKiiEEE5clearEv(ptr noundef nonnull align 8 dereferenceable(48)) local_unnamed_addr #7 align 2

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

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 = { 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 #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 nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #4 = { inlinehint 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 #5 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #6 = { inlinehint 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 #7 = { 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 #8 = { nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #9 = { 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 = distinct !{!13, !10}
!14 = distinct !{!14, !10}
!15 = distinct !{!15, !16}
!16 = !{!"llvm.loop.unroll.disable"}
!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}


; Effective O3 passes: CorrelatedValuePropagationPass,DSEPass,EarlyCSEPass,GVNPass,GlobalOptPass,IndVarSimplifyPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,JumpThreadingPass,LCSSAPass,LICMPass,LoopIdiomRecognizePass,LoopInstSimplifyPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,ReassociatePass,SROAPass,SimplifyCFGPass,TailCallElimPass