; LLVM IR from AnneLivia/Competitive-Programming :: Algorithms/Longest Common Subsequence (main)

; 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::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 }
%"class.std::__cxx11::basic_string" = type { %"struct.std::__cxx11::basic_string<char>::_Alloc_hider", i64, %union.anon }
%"struct.std::__cxx11::basic_string<char>::_Alloc_hider" = type { ptr }
%union.anon = type { i64, [8 x i8] }
%"class.std::allocator" = type { i8 }

@_ZSt4cout = external global %"class.std::basic_ostream", align 8
@.str = external hidden unnamed_addr constant [2 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [1 x i8], align 1

; Function Attrs: mustprogress nounwind uwtable
declare noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32), i64 noundef) #0 align 2

declare i32 @__gxx_personality_v0(...)

; Function Attrs: mustprogress nounwind uwtable
declare void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32)) unnamed_addr #0 align 2

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

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

; Function Attrs: mustprogress uwtable
define dso_local void @_Z3lcsNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES4_(ptr dead_on_unwind noalias writable sret(%"class.std::__cxx11::basic_string") align 8 %0, ptr noundef %1, ptr noundef %2) #2 personality ptr @__gxx_personality_v0 {
  %4 = alloca ptr, align 8
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca i32, align 4
  %8 = alloca i32, align 4
  %9 = alloca ptr, align 8
  %10 = alloca i64, align 8
  %11 = alloca i64, align 8
  %12 = alloca i32, align 4
  %13 = alloca i32, align 4
  %14 = alloca i32, align 4
  %15 = alloca i32, align 4
  %16 = alloca i32, align 4
  %17 = alloca i32, align 4
  %18 = alloca i32, align 4
  %19 = alloca i1, align 1
  %20 = alloca %"class.std::allocator", align 1
  %21 = alloca ptr, align 8
  %22 = alloca i32, align 4
  %23 = alloca i32, align 4
  %24 = alloca i32, align 4
  store ptr %0, ptr %4, align 8
  store ptr %1, ptr %5, align 8, !tbaa !5
  store ptr %2, ptr %6, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #6
  %25 = call noundef i64 @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(32) %1) #6
  %26 = trunc i64 %25 to i32
  store i32 %26, ptr %7, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #6
  %27 = call noundef i64 @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(32) %2) #6
  %28 = trunc i64 %27 to i32
  store i32 %28, ptr %8, align 4, !tbaa !9
  %29 = load i32, ptr %7, align 4, !tbaa !9
  %30 = add nsw i32 %29, 1
  %31 = zext i32 %30 to i64
  %32 = load i32, ptr %8, align 4, !tbaa !9
  %33 = add nsw i32 %32, 1
  %34 = zext i32 %33 to i64
  %35 = call ptr @llvm.stacksave.p0()
  store ptr %35, ptr %9, align 8
  %36 = mul nuw i64 %31, %34
  %37 = alloca i32, i64 %36, align 16
  store i64 %31, ptr %10, align 8
  store i64 %34, ptr %11, align 8
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #6
  store i32 0, ptr %12, align 4, !tbaa !9
  br label %38

38:                                               ; preds = %50, %3
  %39 = load i32, ptr %12, align 4, !tbaa !9
  %40 = load i32, ptr %8, align 4, !tbaa !9
  %41 = add nsw i32 %40, 1
  %42 = icmp slt i32 %39, %41
  br i1 %42, label %44, label %43

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

44:                                               ; preds = %38
  %45 = mul nsw i64 0, %34
  %46 = getelementptr inbounds i32, ptr %37, i64 %45
  %47 = load i32, ptr %12, align 4, !tbaa !9
  %48 = sext i32 %47 to i64
  %49 = getelementptr inbounds i32, ptr %46, i64 %48
  store i32 0, ptr %49, align 4, !tbaa !9
  br label %50

50:                                               ; preds = %44
  %51 = load i32, ptr %12, align 4, !tbaa !9
  %52 = add nsw i32 %51, 1
  store i32 %52, ptr %12, align 4, !tbaa !9
  br label %38, !llvm.loop !11

53:                                               ; preds = %43
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #6
  store i32 0, ptr %13, align 4, !tbaa !9
  br label %54

54:                                               ; preds = %66, %53
  %55 = load i32, ptr %13, align 4, !tbaa !9
  %56 = load i32, ptr %7, align 4, !tbaa !9
  %57 = add nsw i32 %56, 1
  %58 = icmp slt i32 %55, %57
  br i1 %58, label %60, label %59

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

60:                                               ; preds = %54
  %61 = load i32, ptr %13, align 4, !tbaa !9
  %62 = sext i32 %61 to i64
  %63 = mul nsw i64 %62, %34
  %64 = getelementptr inbounds i32, ptr %37, i64 %63
  %65 = getelementptr inbounds i32, ptr %64, i64 0
  store i32 0, ptr %65, align 4, !tbaa !9
  br label %66

66:                                               ; preds = %60
  %67 = load i32, ptr %13, align 4, !tbaa !9
  %68 = add nsw i32 %67, 1
  store i32 %68, ptr %13, align 4, !tbaa !9
  br label %54, !llvm.loop !13

69:                                               ; preds = %59
  call void @llvm.lifetime.start.p0(i64 4, ptr %14) #6
  store i32 1, ptr %14, align 4, !tbaa !9
  br label %70

70:                                               ; preds = %168, %69
  %71 = load i32, ptr %14, align 4, !tbaa !9
  %72 = load i32, ptr %7, align 4, !tbaa !9
  %73 = icmp sle i32 %71, %72
  br i1 %73, label %75, label %74

74:                                               ; preds = %70
  store i32 8, ptr %15, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #6
  br label %171

75:                                               ; preds = %70
  call void @llvm.lifetime.start.p0(i64 4, ptr %16) #6
  store i32 1, ptr %16, align 4, !tbaa !9
  br label %76

76:                                               ; preds = %164, %75
  %77 = load i32, ptr %16, align 4, !tbaa !9
  %78 = load i32, ptr %8, align 4, !tbaa !9
  %79 = icmp sle i32 %77, %78
  br i1 %79, label %81, label %80

80:                                               ; preds = %76
  store i32 11, ptr %15, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #6
  br label %167

81:                                               ; preds = %76
  %82 = load i32, ptr %14, align 4, !tbaa !9
  %83 = sub nsw i32 %82, 1
  %84 = sext i32 %83 to i64
  %85 = call noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %1, i64 noundef %84)
  %86 = load i8, ptr %85, align 1, !tbaa !14
  %87 = sext i8 %86 to i32
  %88 = load i32, ptr %16, align 4, !tbaa !9
  %89 = sub nsw i32 %88, 1
  %90 = sext i32 %89 to i64
  %91 = call noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %2, i64 noundef %90)
  %92 = load i8, ptr %91, align 1, !tbaa !14
  %93 = sext i8 %92 to i32
  %94 = icmp eq i32 %87, %93
  br i1 %94, label %95, label %114

95:                                               ; preds = %81
  %96 = load i32, ptr %14, align 4, !tbaa !9
  %97 = sub nsw i32 %96, 1
  %98 = sext i32 %97 to i64
  %99 = mul nsw i64 %98, %34
  %100 = getelementptr inbounds i32, ptr %37, i64 %99
  %101 = load i32, ptr %16, align 4, !tbaa !9
  %102 = sub nsw i32 %101, 1
  %103 = sext i32 %102 to i64
  %104 = getelementptr inbounds i32, ptr %100, i64 %103
  %105 = load i32, ptr %104, align 4, !tbaa !9
  %106 = add nsw i32 %105, 1
  %107 = load i32, ptr %14, align 4, !tbaa !9
  %108 = sext i32 %107 to i64
  %109 = mul nsw i64 %108, %34
  %110 = getelementptr inbounds i32, ptr %37, i64 %109
  %111 = load i32, ptr %16, align 4, !tbaa !9
  %112 = sext i32 %111 to i64
  %113 = getelementptr inbounds i32, ptr %110, i64 %112
  store i32 %106, ptr %113, align 4, !tbaa !9
  br label %163

114:                                              ; preds = %81
  %115 = load i32, ptr %14, align 4, !tbaa !9
  %116 = sub nsw i32 %115, 1
  %117 = sext i32 %116 to i64
  %118 = mul nsw i64 %117, %34
  %119 = getelementptr inbounds i32, ptr %37, i64 %118
  %120 = load i32, ptr %16, align 4, !tbaa !9
  %121 = sext i32 %120 to i64
  %122 = getelementptr inbounds i32, ptr %119, i64 %121
  %123 = load i32, ptr %122, align 4, !tbaa !9
  %124 = load i32, ptr %14, align 4, !tbaa !9
  %125 = sext i32 %124 to i64
  %126 = mul nsw i64 %125, %34
  %127 = getelementptr inbounds i32, ptr %37, i64 %126
  %128 = load i32, ptr %16, align 4, !tbaa !9
  %129 = sub nsw i32 %128, 1
  %130 = sext i32 %129 to i64
  %131 = getelementptr inbounds i32, ptr %127, i64 %130
  %132 = load i32, ptr %131, align 4, !tbaa !9
  %133 = icmp sgt i32 %123, %132
  br i1 %133, label %134, label %144

134:                                              ; preds = %114
  %135 = load i32, ptr %14, align 4, !tbaa !9
  %136 = sub nsw i32 %135, 1
  %137 = sext i32 %136 to i64
  %138 = mul nsw i64 %137, %34
  %139 = getelementptr inbounds i32, ptr %37, i64 %138
  %140 = load i32, ptr %16, align 4, !tbaa !9
  %141 = sext i32 %140 to i64
  %142 = getelementptr inbounds i32, ptr %139, i64 %141
  %143 = load i32, ptr %142, align 4, !tbaa !9
  br label %154

144:                                              ; preds = %114
  %145 = load i32, ptr %14, align 4, !tbaa !9
  %146 = sext i32 %145 to i64
  %147 = mul nsw i64 %146, %34
  %148 = getelementptr inbounds i32, ptr %37, i64 %147
  %149 = load i32, ptr %16, align 4, !tbaa !9
  %150 = sub nsw i32 %149, 1
  %151 = sext i32 %150 to i64
  %152 = getelementptr inbounds i32, ptr %148, i64 %151
  %153 = load i32, ptr %152, align 4, !tbaa !9
  br label %154

154:                                              ; preds = %144, %134
  %155 = phi i32 [ %143, %134 ], [ %153, %144 ]
  %156 = load i32, ptr %14, align 4, !tbaa !9
  %157 = sext i32 %156 to i64
  %158 = mul nsw i64 %157, %34
  %159 = getelementptr inbounds i32, ptr %37, i64 %158
  %160 = load i32, ptr %16, align 4, !tbaa !9
  %161 = sext i32 %160 to i64
  %162 = getelementptr inbounds i32, ptr %159, i64 %161
  store i32 %155, ptr %162, align 4, !tbaa !9
  br label %163

163:                                              ; preds = %154, %95
  br label %164

164:                                              ; preds = %163
  %165 = load i32, ptr %16, align 4, !tbaa !9
  %166 = add nsw i32 %165, 1
  store i32 %166, ptr %16, align 4, !tbaa !9
  br label %76, !llvm.loop !15

167:                                              ; preds = %80
  br label %168

168:                                              ; preds = %167
  %169 = load i32, ptr %14, align 4, !tbaa !9
  %170 = add nsw i32 %169, 1
  store i32 %170, ptr %14, align 4, !tbaa !9
  br label %70, !llvm.loop !16

171:                                              ; preds = %74
  call void @llvm.lifetime.start.p0(i64 4, ptr %17) #6
  store i32 0, ptr %17, align 4, !tbaa !9
  br label %172

172:                                              ; preds = %201, %171
  %173 = load i32, ptr %17, align 4, !tbaa !9
  %174 = load i32, ptr %7, align 4, !tbaa !9
  %175 = add nsw i32 %174, 1
  %176 = icmp slt i32 %173, %175
  br i1 %176, label %178, label %177

177:                                              ; preds = %172
  store i32 14, ptr %15, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #6
  br label %204

178:                                              ; preds = %172
  call void @llvm.lifetime.start.p0(i64 4, ptr %18) #6
  store i32 0, ptr %18, align 4, !tbaa !9
  br label %179

179:                                              ; preds = %196, %178
  %180 = load i32, ptr %18, align 4, !tbaa !9
  %181 = load i32, ptr %8, align 4, !tbaa !9
  %182 = add nsw i32 %181, 1
  %183 = icmp slt i32 %180, %182
  br i1 %183, label %185, label %184

184:                                              ; preds = %179
  store i32 17, ptr %15, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %18) #6
  br label %199

185:                                              ; preds = %179
  %186 = load i32, ptr %17, align 4, !tbaa !9
  %187 = sext i32 %186 to i64
  %188 = mul nsw i64 %187, %34
  %189 = getelementptr inbounds i32, ptr %37, i64 %188
  %190 = load i32, ptr %18, align 4, !tbaa !9
  %191 = sext i32 %190 to i64
  %192 = getelementptr inbounds i32, ptr %189, i64 %191
  %193 = load i32, ptr %192, align 4, !tbaa !9
  %194 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, i32 noundef %193)
  %195 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %194, ptr noundef @.str)
  br label %196

196:                                              ; preds = %185
  %197 = load i32, ptr %18, align 4, !tbaa !9
  %198 = add nsw i32 %197, 1
  store i32 %198, ptr %18, align 4, !tbaa !9
  br label %179, !llvm.loop !17

199:                                              ; preds = %184
  %200 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSoS_E(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, ptr noundef @_ZSt4endlIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_)
  br label %201

201:                                              ; preds = %199
  %202 = load i32, ptr %17, align 4, !tbaa !9
  %203 = add nsw i32 %202, 1
  store i32 %203, ptr %17, align 4, !tbaa !9
  br label %172, !llvm.loop !18

204:                                              ; preds = %177
  store i1 false, ptr %19, align 1
  call void @llvm.lifetime.start.p0(i64 1, ptr %20) #6
  call void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %20) #6
  invoke void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32) %0, ptr noundef @.str.2, ptr noundef nonnull align 1 dereferenceable(1) %20)
          to label %205 unwind label %245

205:                                              ; preds = %204
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %20) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr %20) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr %23) #6
  %206 = load i32, ptr %7, align 4, !tbaa !9
  store i32 %206, ptr %23, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %24) #6
  %207 = load i32, ptr %8, align 4, !tbaa !9
  store i32 %207, ptr %24, align 4, !tbaa !9
  br label %208

208:                                              ; preds = %280, %205
  %209 = load i32, ptr %24, align 4, !tbaa !9
  %210 = icmp sgt i32 %209, 0
  br i1 %210, label %211, label %214

211:                                              ; preds = %208
  %212 = load i32, ptr %23, align 4, !tbaa !9
  %213 = icmp sgt i32 %212, 0
  br label %214

214:                                              ; preds = %211, %208
  %215 = phi i1 [ false, %208 ], [ %213, %211 ]
  br i1 %215, label %216, label %281

216:                                              ; preds = %214
  %217 = load i32, ptr %23, align 4, !tbaa !9
  %218 = sub nsw i32 %217, 1
  %219 = sext i32 %218 to i64
  %220 = invoke noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %1, i64 noundef %219)
          to label %221 unwind label %249

221:                                              ; preds = %216
  %222 = load i8, ptr %220, align 1, !tbaa !14
  %223 = sext i8 %222 to i32
  %224 = load i32, ptr %24, align 4, !tbaa !9
  %225 = sub nsw i32 %224, 1
  %226 = sext i32 %225 to i64
  %227 = invoke noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %2, i64 noundef %226)
          to label %228 unwind label %249

228:                                              ; preds = %221
  %229 = load i8, ptr %227, align 1, !tbaa !14
  %230 = sext i8 %229 to i32
  %231 = icmp eq i32 %223, %230
  br i1 %231, label %232, label %253

232:                                              ; preds = %228
  %233 = load i32, ptr %23, align 4, !tbaa !9
  %234 = sub nsw i32 %233, 1
  %235 = sext i32 %234 to i64
  %236 = invoke noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %1, i64 noundef %235)
          to label %237 unwind label %249

237:                                              ; preds = %232
  %238 = load i8, ptr %236, align 1, !tbaa !14
  %239 = invoke noundef nonnull align 8 dereferenceable(32) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEpLEc(ptr noundef nonnull align 8 dereferenceable(32) %0, i8 noundef signext %238)
          to label %240 unwind label %249

240:                                              ; preds = %237
  %241 = load i32, ptr %23, align 4, !tbaa !9
  %242 = add nsw i32 %241, -1
  store i32 %242, ptr %23, align 4, !tbaa !9
  %243 = load i32, ptr %24, align 4, !tbaa !9
  %244 = add nsw i32 %243, -1
  store i32 %244, ptr %24, align 4, !tbaa !9
  br label %280

245:                                              ; preds = %204
  %246 = landingpad { ptr, i32 }
          cleanup
  %247 = extractvalue { ptr, i32 } %246, 0
  store ptr %247, ptr %21, align 8
  %248 = extractvalue { ptr, i32 } %246, 1
  store i32 %248, ptr %22, align 4
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %20) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr %20) #6
  br label %286

249:                                              ; preds = %237, %232, %221, %216
  %250 = landingpad { ptr, i32 }
          cleanup
  %251 = extractvalue { ptr, i32 } %250, 0
  store ptr %251, ptr %21, align 8
  %252 = extractvalue { ptr, i32 } %250, 1
  store i32 %252, ptr %22, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %24) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %23) #6
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %0) #6
  br label %286

253:                                              ; preds = %228
  %254 = load i32, ptr %23, align 4, !tbaa !9
  %255 = sub nsw i32 %254, 1
  %256 = sext i32 %255 to i64
  %257 = mul nsw i64 %256, %34
  %258 = getelementptr inbounds i32, ptr %37, i64 %257
  %259 = load i32, ptr %24, align 4, !tbaa !9
  %260 = sext i32 %259 to i64
  %261 = getelementptr inbounds i32, ptr %258, i64 %260
  %262 = load i32, ptr %261, align 4, !tbaa !9
  %263 = load i32, ptr %23, align 4, !tbaa !9
  %264 = sext i32 %263 to i64
  %265 = mul nsw i64 %264, %34
  %266 = getelementptr inbounds i32, ptr %37, i64 %265
  %267 = load i32, ptr %24, align 4, !tbaa !9
  %268 = sub nsw i32 %267, 1
  %269 = sext i32 %268 to i64
  %270 = getelementptr inbounds i32, ptr %266, i64 %269
  %271 = load i32, ptr %270, align 4, !tbaa !9
  %272 = icmp sgt i32 %262, %271
  br i1 %272, label %273, label %276

273:                                              ; preds = %253
  %274 = load i32, ptr %23, align 4, !tbaa !9
  %275 = add nsw i32 %274, -1
  store i32 %275, ptr %23, align 4, !tbaa !9
  br label %279

276:                                              ; preds = %253
  %277 = load i32, ptr %24, align 4, !tbaa !9
  %278 = add nsw i32 %277, -1
  store i32 %278, ptr %24, align 4, !tbaa !9
  br label %279

279:                                              ; preds = %276, %273
  br label %280

280:                                              ; preds = %279, %240
  br label %208, !llvm.loop !19

281:                                              ; preds = %214
  store i1 true, ptr %19, align 1
  store i32 1, ptr %15, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %24) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %23) #6
  %282 = load i1, ptr %19, align 1
  br i1 %282, label %284, label %283

283:                                              ; preds = %281
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %0) #6
  br label %284

284:                                              ; preds = %283, %281
  %285 = load ptr, ptr %9, align 8
  call void @llvm.stackrestore.p0(ptr %285)
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #6
  ret void

286:                                              ; preds = %249, %245
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #6
  br label %287

287:                                              ; preds = %286
  %288 = load ptr, ptr %21, align 8
  %289 = load i32, ptr %22, align 4
  %290 = insertvalue { ptr, i32 } poison, ptr %288, 0
  %291 = insertvalue { ptr, i32 } %290, i32 %289, 1
  resume { ptr, i32 } %291
}

; Function Attrs: mustprogress nounwind uwtable
declare noundef i64 @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(32)) #0 align 2

; Function Attrs: nocallback nofree nosync nounwind willreturn
declare ptr @llvm.stacksave.p0() #3

; Function Attrs: inlinehint mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef) #4

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

; 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)) #4

; Function Attrs: mustprogress nounwind uwtable
declare void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #0 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32), ptr noundef, ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #2 align 2

; Function Attrs: mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(32) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEpLEc(ptr noundef nonnull align 8 dereferenceable(32), i8 noundef signext) #2 align 2

; Function Attrs: nocallback nofree nosync nounwind willreturn
declare void @llvm.stackrestore.p0(ptr) #3

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #0 align 2

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


; 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::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 }
%"class.std::__cxx11::basic_string" = type { %"struct.std::__cxx11::basic_string<char>::_Alloc_hider", i64, %union.anon }
%"struct.std::__cxx11::basic_string<char>::_Alloc_hider" = type { ptr }
%union.anon = type { i64, [8 x i8] }
%"class.std::allocator" = type { i8 }

@_ZSt4cout = external global %"class.std::basic_ostream", align 8
@.str = external hidden unnamed_addr constant [2 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [1 x i8], align 1

; Function Attrs: mustprogress nounwind uwtable
declare noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32), i64 noundef) local_unnamed_addr #0 align 2

declare i32 @__gxx_personality_v0(...)

; Function Attrs: mustprogress nounwind uwtable
declare void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32)) unnamed_addr #0 align 2

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

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

; Function Attrs: mustprogress uwtable
define dso_local void @_Z3lcsNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES4_(ptr dead_on_unwind noalias writable sret(%"class.std::__cxx11::basic_string") align 8 %0, ptr noundef nonnull %1, ptr noundef %2) local_unnamed_addr #2 personality ptr @__gxx_personality_v0 {
  %4 = alloca %"class.std::allocator", align 1
  %5 = tail call noundef i64 @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(32) %1) #7
  %6 = trunc i64 %5 to i32
  %7 = tail call noundef i64 @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(32) %2) #7
  %8 = trunc i64 %7 to i32
  %9 = add i64 %5, 1
  %10 = and i64 %9, 4294967295
  %11 = add i64 %7, 1
  %12 = and i64 %11, 4294967295
  %13 = mul nuw i64 %12, %10
  %14 = alloca i32, i64 %13, align 16
  %.not84 = icmp slt i32 %8, 0
  br i1 %.not84, label %.preheader83, label %.lr.ph.preheader

.lr.ph.preheader:                                 ; preds = %3
  %15 = shl i64 %7, 2
  %16 = add nuw nsw i64 %15, 4
  %17 = and i64 %16, 17179869180
  call void @llvm.memset.p0.i64(ptr nonnull align 16 %14, i8 0, i64 %17, i1 false), !tbaa !5
  br label %.preheader83

.preheader83:                                     ; preds = %.lr.ph.preheader, %3
  %.not7386 = icmp slt i32 %6, 0
  br i1 %.not7386, label %._crit_edge100, label %.lr.ph88.preheader

.lr.ph88.preheader:                               ; preds = %.preheader83
  %18 = add nuw nsw i64 %5, 1
  %wide.trip.count = and i64 %18, 4294967295
  %19 = add nsw i64 %wide.trip.count, -1
  %xtraiter = and i64 %18, 3
  %20 = icmp ult i64 %19, 3
  br i1 %20, label %.preheader82.unr-lcssa, label %.lr.ph88.preheader.new

.lr.ph88.preheader.new:                           ; preds = %.lr.ph88.preheader
  %unroll_iter = sub nsw i64 %wide.trip.count, %xtraiter
  br label %.lr.ph88

.preheader82.unr-lcssa:                           ; preds = %.lr.ph88, %.lr.ph88.preheader
  %indvars.iv.unr = phi i64 [ 0, %.lr.ph88.preheader ], [ %indvars.iv.next.3, %.lr.ph88 ]
  %lcmp.mod.not = icmp eq i64 %xtraiter, 0
  br i1 %lcmp.mod.not, label %.preheader82, label %.lr.ph88.epil

.lr.ph88.epil:                                    ; preds = %.preheader82.unr-lcssa, %.lr.ph88.epil
  %indvars.iv.epil = phi i64 [ %indvars.iv.next.epil, %.lr.ph88.epil ], [ %indvars.iv.unr, %.preheader82.unr-lcssa ]
  %epil.iter = phi i64 [ %epil.iter.next, %.lr.ph88.epil ], [ 0, %.preheader82.unr-lcssa ]
  %21 = mul nuw nsw i64 %12, %indvars.iv.epil
  %22 = getelementptr inbounds i32, ptr %14, i64 %21
  store i32 0, ptr %22, align 4, !tbaa !5
  %indvars.iv.next.epil = add nuw nsw i64 %indvars.iv.epil, 1
  %epil.iter.next = add i64 %epil.iter, 1
  %epil.iter.cmp.not = icmp eq i64 %epil.iter.next, %xtraiter
  br i1 %epil.iter.cmp.not, label %.preheader82, label %.lr.ph88.epil, !llvm.loop !9

.preheader82:                                     ; preds = %.lr.ph88.epil, %.preheader82.unr-lcssa
  %.not7492 = icmp eq i32 %6, 0
  br i1 %.not7492, label %.preheader80, label %.preheader81.lr.ph

.preheader81.lr.ph:                               ; preds = %.preheader82
  %.not7889 = icmp slt i32 %8, 1
  br i1 %.not7889, label %.preheader.lr.ph, label %.preheader81.preheader

.preheader81.preheader:                           ; preds = %.preheader81.lr.ph
  %23 = add nuw nsw i64 %7, 1
  %24 = add nuw nsw i64 %5, 1
  %wide.trip.count118 = and i64 %24, 4294967295
  %wide.trip.count113 = and i64 %23, 4294967295
  br label %.preheader81

.lr.ph88:                                         ; preds = %.lr.ph88, %.lr.ph88.preheader.new
  %indvars.iv = phi i64 [ 0, %.lr.ph88.preheader.new ], [ %indvars.iv.next.3, %.lr.ph88 ]
  %niter = phi i64 [ 0, %.lr.ph88.preheader.new ], [ %niter.next.3, %.lr.ph88 ]
  %25 = mul nuw nsw i64 %12, %indvars.iv
  %26 = getelementptr inbounds i32, ptr %14, i64 %25
  store i32 0, ptr %26, align 16, !tbaa !5
  %indvars.iv.next = or disjoint i64 %indvars.iv, 1
  %27 = mul nuw nsw i64 %12, %indvars.iv.next
  %28 = getelementptr inbounds i32, ptr %14, i64 %27
  store i32 0, ptr %28, align 4, !tbaa !5
  %indvars.iv.next.1 = or disjoint i64 %indvars.iv, 2
  %29 = mul nuw nsw i64 %12, %indvars.iv.next.1
  %30 = getelementptr inbounds i32, ptr %14, i64 %29
  store i32 0, ptr %30, align 8, !tbaa !5
  %indvars.iv.next.2 = or disjoint i64 %indvars.iv, 3
  %31 = mul nuw nsw i64 %12, %indvars.iv.next.2
  %32 = getelementptr inbounds i32, ptr %14, i64 %31
  store i32 0, ptr %32, align 4, !tbaa !5
  %indvars.iv.next.3 = add nuw nsw i64 %indvars.iv, 4
  %niter.next.3 = add i64 %niter, 4
  %niter.ncmp.3 = icmp eq i64 %niter.next.3, %unroll_iter
  br i1 %niter.ncmp.3, label %.preheader82.unr-lcssa, label %.lr.ph88, !llvm.loop !11

.preheader81:                                     ; preds = %.preheader81.preheader, %._crit_edge
  %indvars.iv115 = phi i64 [ 1, %.preheader81.preheader ], [ %indvars.iv.next116, %._crit_edge ]
  %33 = add nsw i64 %indvars.iv115, -1
  %34 = mul nuw nsw i64 %12, %33
  %35 = getelementptr inbounds i32, ptr %14, i64 %34
  %36 = mul nuw nsw i64 %12, %indvars.iv115
  %37 = getelementptr inbounds i32, ptr %14, i64 %36
  br label %42

.preheader80:                                     ; preds = %._crit_edge, %.preheader82
  br i1 %.not7386, label %._crit_edge100, label %.preheader.lr.ph

.preheader.lr.ph:                                 ; preds = %.preheader81.lr.ph, %.preheader80
  br i1 %.not84, label %.preheader.us, label %.preheader.preheader

.preheader.preheader:                             ; preds = %.preheader.lr.ph
  %38 = add nuw nsw i64 %7, 1
  %39 = add nuw nsw i64 %5, 1
  %wide.trip.count128 = and i64 %39, 4294967295
  %wide.trip.count123 = and i64 %38, 4294967295
  br label %.preheader

.preheader.us:                                    ; preds = %.preheader.lr.ph, %.preheader.us
  %.06399.us = phi i32 [ %41, %.preheader.us ], [ 0, %.preheader.lr.ph ]
  %40 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSoS_E(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, ptr noundef nonnull @_ZSt4endlIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_)
  %41 = add nuw i32 %.06399.us, 1
  %exitcond130.not = icmp eq i32 %.06399.us, %6
  br i1 %exitcond130.not, label %._crit_edge100, label %.preheader.us, !llvm.loop !13

._crit_edge:                                      ; preds = %58
  %indvars.iv.next116 = add nuw nsw i64 %indvars.iv115, 1
  %exitcond119.not = icmp eq i64 %indvars.iv.next116, %wide.trip.count118
  br i1 %exitcond119.not, label %.preheader80, label %.preheader81, !llvm.loop !14

42:                                               ; preds = %.preheader81, %58
  %indvars.iv110 = phi i64 [ 1, %.preheader81 ], [ %indvars.iv.next111, %58 ]
  %43 = tail call noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %1, i64 noundef %33)
  %44 = load i8, ptr %43, align 1, !tbaa !15
  %45 = add nsw i64 %indvars.iv110, -1
  %46 = tail call noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %2, i64 noundef %45)
  %47 = load i8, ptr %46, align 1, !tbaa !15
  %48 = icmp eq i8 %44, %47
  br i1 %48, label %49, label %53

49:                                               ; preds = %42
  %50 = getelementptr inbounds i32, ptr %35, i64 %45
  %51 = load i32, ptr %50, align 4, !tbaa !5
  %52 = add nsw i32 %51, 1
  br label %58

53:                                               ; preds = %42
  %54 = getelementptr inbounds i32, ptr %35, i64 %indvars.iv110
  %55 = load i32, ptr %54, align 4, !tbaa !5
  %56 = getelementptr inbounds i32, ptr %37, i64 %45
  %57 = load i32, ptr %56, align 4, !tbaa !5
  %. = tail call i32 @llvm.smax.i32(i32 %55, i32 %57)
  br label %58

58:                                               ; preds = %49, %53
  %.sink = phi i32 [ %52, %49 ], [ %., %53 ]
  %59 = getelementptr inbounds i32, ptr %37, i64 %indvars.iv110
  store i32 %.sink, ptr %59, align 4, !tbaa !5
  %indvars.iv.next111 = add nuw nsw i64 %indvars.iv110, 1
  %exitcond114.not = icmp eq i64 %indvars.iv.next111, %wide.trip.count113
  br i1 %exitcond114.not, label %._crit_edge, label %42, !llvm.loop !16

.preheader:                                       ; preds = %.preheader.preheader, %._crit_edge97
  %indvars.iv125 = phi i64 [ 0, %.preheader.preheader ], [ %indvars.iv.next126, %._crit_edge97 ]
  %60 = mul nuw nsw i64 %12, %indvars.iv125
  %61 = getelementptr inbounds i32, ptr %14, i64 %60
  br label %63

._crit_edge100:                                   ; preds = %._crit_edge97, %.preheader.us, %.preheader83, %.preheader80
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %4) #7
  call void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %4) #7
  invoke void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32) %0, ptr noundef nonnull @.str.2, ptr noundef nonnull align 1 dereferenceable(1) %4)
          to label %68 unwind label %85

._crit_edge97:                                    ; preds = %63
  %62 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSoS_E(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, ptr noundef nonnull @_ZSt4endlIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_)
  %indvars.iv.next126 = add nuw nsw i64 %indvars.iv125, 1
  %exitcond129.not = icmp eq i64 %indvars.iv.next126, %wide.trip.count128
  br i1 %exitcond129.not, label %._crit_edge100, label %.preheader, !llvm.loop !13

63:                                               ; preds = %.preheader, %63
  %indvars.iv120 = phi i64 [ 0, %.preheader ], [ %indvars.iv.next121, %63 ]
  %64 = getelementptr inbounds i32, ptr %61, i64 %indvars.iv120
  %65 = load i32, ptr %64, align 4, !tbaa !5
  %66 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, i32 noundef %65)
  %67 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %66, ptr noundef nonnull @.str)
  %indvars.iv.next121 = add nuw nsw i64 %indvars.iv120, 1
  %exitcond124.not = icmp eq i64 %indvars.iv.next121, %wide.trip.count123
  br i1 %exitcond124.not, label %._crit_edge97, label %63, !llvm.loop !17

68:                                               ; preds = %._crit_edge100
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %4) #7
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %4) #7
  %69 = icmp sgt i32 %8, 0
  %70 = icmp sgt i32 %6, 0
  %71 = and i1 %69, %70
  br i1 %71, label %.lr.ph104, label %._crit_edge105

.lr.ph104:                                        ; preds = %68, %101
  %.0102 = phi i32 [ %.1, %101 ], [ %8, %68 ]
  %.058101 = phi i32 [ %.159, %101 ], [ %6, %68 ]
  %72 = add nsw i32 %.058101, -1
  %73 = zext nneg i32 %72 to i64
  %74 = call noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %1, i64 noundef %73)
  %75 = load i8, ptr %74, align 1, !tbaa !15
  %76 = add nsw i32 %.0102, -1
  %77 = zext nneg i32 %76 to i64
  %78 = call noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %2, i64 noundef %77)
  %79 = load i8, ptr %78, align 1, !tbaa !15
  %80 = icmp eq i8 %75, %79
  br i1 %80, label %81, label %89

81:                                               ; preds = %.lr.ph104
  %82 = call noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %1, i64 noundef %73)
  %83 = load i8, ptr %82, align 1, !tbaa !15
  %84 = invoke noundef nonnull align 8 dereferenceable(32) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEpLEc(ptr noundef nonnull align 8 dereferenceable(32) %0, i8 noundef signext %83)
          to label %101 unwind label %87

85:                                               ; preds = %._crit_edge100
  %86 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %4) #7
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %4) #7
  br label %105

87:                                               ; preds = %81
  %88 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %0) #7
  br label %105

89:                                               ; preds = %.lr.ph104
  %90 = mul nuw nsw i64 %12, %73
  %91 = getelementptr inbounds i32, ptr %14, i64 %90
  %92 = zext nneg i32 %.0102 to i64
  %93 = getelementptr inbounds i32, ptr %91, i64 %92
  %94 = load i32, ptr %93, align 4, !tbaa !5
  %95 = zext nneg i32 %.058101 to i64
  %96 = mul nuw nsw i64 %12, %95
  %97 = getelementptr inbounds i32, ptr %14, i64 %96
  %98 = getelementptr inbounds i32, ptr %97, i64 %77
  %99 = load i32, ptr %98, align 4, !tbaa !5
  %100 = icmp sgt i32 %94, %99
  %spec.select = select i1 %100, i32 %72, i32 %.058101
  %spec.select79 = select i1 %100, i32 %.0102, i32 %76
  br label %101

101:                                              ; preds = %89, %81
  %.159 = phi i32 [ %72, %81 ], [ %spec.select, %89 ]
  %.1 = phi i32 [ %76, %81 ], [ %spec.select79, %89 ]
  %102 = icmp sgt i32 %.1, 0
  %103 = icmp sgt i32 %.159, 0
  %104 = select i1 %102, i1 %103, i1 false
  br i1 %104, label %.lr.ph104, label %._crit_edge105, !llvm.loop !18

._crit_edge105:                                   ; preds = %101, %68
  ret void

105:                                              ; preds = %87, %85
  %.pn = phi { ptr, i32 } [ %88, %87 ], [ %86, %85 ]
  resume { ptr, i32 } %.pn
}

; Function Attrs: mustprogress nounwind uwtable
declare noundef i64 @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(32)) local_unnamed_addr #0 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef) local_unnamed_addr #3

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

; 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)) #3

; Function Attrs: mustprogress nounwind uwtable
declare void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #0 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32), ptr noundef, ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #2 align 2

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #0 align 2

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

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

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


; Effective O3 passes: EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferAlignmentPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,JumpThreadingPass,LCSSAPass,LICMPass,LoopIdiomRecognizePass,LoopRotatePass,LoopSimplifyCFGPass,LoopSimplifyPass,LoopUnrollPass,PostOrderFunctionAttrsPass,ReassociatePass,SROAPass,SimplifyCFGPass,TailCallElimPass