; LLVM IR from eyangch/competitive-programming :: Codeforces/1380 (d)

; 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_istream" = type { ptr, i64, %"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::basic_ostream" = type { ptr, %"class.std::basic_ios" }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<std::pair<long long, long long>, std::allocator<std::pair<long long, long long>>>::_Vector_impl" }
%"struct.std::_Vector_base<std::pair<long long, long long>, std::allocator<std::pair<long long, long long>>>::_Vector_impl" = type { %"struct.std::_Vector_base<std::pair<long long, long long>, std::allocator<std::pair<long long, long long>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<std::pair<long long, long long>, std::allocator<std::pair<long long, long long>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"struct.std::pair" = type { i64, i64 }
%"class.__gnu_cxx::__normal_iterator" = type { ptr }

@_ZSt3cin = external global %"class.std::basic_istream", align 8
@_ZSt4cout = external global %"class.std::basic_ostream", align 8

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() #0 personality ptr @__gxx_personality_v0 {
  %1 = alloca i32, align 4
  %2 = alloca i64, align 8
  %3 = alloca i64, align 8
  %4 = alloca i64, align 8
  %5 = alloca i64, align 8
  %6 = alloca i64, align 8
  %7 = alloca ptr, align 8
  %8 = alloca i64, align 8
  %9 = alloca i64, align 8
  %10 = alloca i64, align 8
  %11 = alloca i64, align 8
  %12 = alloca %"class.std::vector", align 8
  %13 = alloca i64, align 8
  %14 = alloca i64, align 8
  %15 = alloca i64, align 8
  %16 = alloca %"struct.std::pair", align 8
  %17 = alloca ptr, align 8
  %18 = alloca i32, align 4
  %19 = alloca i32, align 4
  %20 = alloca %"struct.std::pair", align 8
  %21 = alloca i64, align 8
  %22 = alloca ptr, align 8
  %23 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %24 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %25 = alloca %"struct.std::pair", align 8
  %26 = alloca i64, align 8
  %27 = alloca i64, align 8
  %28 = alloca i64, align 8
  %29 = alloca i64, align 8
  %30 = alloca i64, align 8
  %31 = alloca i64, align 8
  %32 = alloca i64, align 8
  %33 = alloca i64, align 8
  %34 = alloca i64, align 8
  store i32 0, ptr %1, align 4
  %35 = call noundef zeroext i1 @_ZNSt8ios_base15sync_with_stdioEb(i1 noundef zeroext false)
  %36 = load ptr, ptr @_ZSt3cin, align 8, !tbaa !5
  %37 = getelementptr i8, ptr %36, i64 -24
  %38 = load i64, ptr %37, align 8
  %39 = getelementptr inbounds i8, ptr @_ZSt3cin, i64 %38
  %40 = call noundef ptr @_ZNSt9basic_iosIcSt11char_traitsIcEE3tieEPSo(ptr noundef nonnull align 8 dereferenceable(264) %39, ptr noundef null)
  call void @llvm.lifetime.start.p0(i64 8, ptr %2) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr %3) #9
  %41 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 8 dereferenceable(8) %2)
  %42 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16) %41, ptr noundef nonnull align 8 dereferenceable(8) %3)
  call void @llvm.lifetime.start.p0(i64 8, ptr %4) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr %5) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr %6) #9
  %43 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 8 dereferenceable(8) %4)
  %44 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16) %43, ptr noundef nonnull align 8 dereferenceable(8) %5)
  %45 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16) %44, ptr noundef nonnull align 8 dereferenceable(8) %6)
  %46 = load i64, ptr %2, align 8, !tbaa !8
  %47 = call ptr @llvm.stacksave.p0()
  store ptr %47, ptr %7, align 8
  %48 = alloca i64, i64 %46, align 16
  store i64 %46, ptr %8, align 8
  %49 = load i64, ptr %3, align 8, !tbaa !8
  %50 = alloca i64, i64 %49, align 16
  store i64 %49, ptr %9, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #9
  store i64 0, ptr %10, align 8, !tbaa !8
  br label %51

51:                                               ; preds = %60, %0
  %52 = load i64, ptr %10, align 8, !tbaa !8
  %53 = load i64, ptr %2, align 8, !tbaa !8
  %54 = icmp slt i64 %52, %53
  br i1 %54, label %56, label %55

55:                                               ; preds = %51
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #9
  br label %63

56:                                               ; preds = %51
  %57 = load i64, ptr %10, align 8, !tbaa !8
  %58 = getelementptr inbounds i64, ptr %48, i64 %57
  %59 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 8 dereferenceable(8) %58)
  br label %60

60:                                               ; preds = %56
  %61 = load i64, ptr %10, align 8, !tbaa !8
  %62 = add nsw i64 %61, 1
  store i64 %62, ptr %10, align 8, !tbaa !8
  br label %51, !llvm.loop !11

63:                                               ; preds = %55
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #9
  store i64 0, ptr %11, align 8, !tbaa !8
  br label %64

64:                                               ; preds = %73, %63
  %65 = load i64, ptr %11, align 8, !tbaa !8
  %66 = load i64, ptr %3, align 8, !tbaa !8
  %67 = icmp slt i64 %65, %66
  br i1 %67, label %69, label %68

68:                                               ; preds = %64
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #9
  br label %76

69:                                               ; preds = %64
  %70 = load i64, ptr %11, align 8, !tbaa !8
  %71 = getelementptr inbounds i64, ptr %50, i64 %70
  %72 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 8 dereferenceable(8) %71)
  br label %73

73:                                               ; preds = %69
  %74 = load i64, ptr %11, align 8, !tbaa !8
  %75 = add nsw i64 %74, 1
  store i64 %75, ptr %11, align 8, !tbaa !8
  br label %64, !llvm.loop !13

76:                                               ; preds = %68
  call void @llvm.lifetime.start.p0(i64 24, ptr %12) #9
  call void @_ZNSt6vectorISt4pairIxxESaIS1_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %12) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #9
  store i64 0, ptr %13, align 8, !tbaa !8
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #9
  store i64 0, ptr %14, align 8, !tbaa !8
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #9
  store i64 0, ptr %15, align 8, !tbaa !8
  br label %77

77:                                               ; preds = %111, %76
  %78 = load i64, ptr %15, align 8, !tbaa !8
  %79 = load i64, ptr %2, align 8, !tbaa !8
  %80 = icmp slt i64 %78, %79
  br i1 %80, label %82, label %81

81:                                               ; preds = %77
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #9
  br label %114

82:                                               ; preds = %77
  %83 = load i64, ptr %14, align 8, !tbaa !8
  %84 = load i64, ptr %3, align 8, !tbaa !8
  %85 = icmp slt i64 %83, %84
  br i1 %85, label %86, label %110

86:                                               ; preds = %82
  %87 = load i64, ptr %15, align 8, !tbaa !8
  %88 = getelementptr inbounds i64, ptr %48, i64 %87
  %89 = load i64, ptr %88, align 8, !tbaa !8
  %90 = load i64, ptr %14, align 8, !tbaa !8
  %91 = getelementptr inbounds i64, ptr %50, i64 %90
  %92 = load i64, ptr %91, align 8, !tbaa !8
  %93 = icmp eq i64 %89, %92
  br i1 %93, label %94, label %110

94:                                               ; preds = %86
  %95 = load i64, ptr %14, align 8, !tbaa !8
  %96 = add nsw i64 %95, 1
  store i64 %96, ptr %14, align 8, !tbaa !8
  %97 = load i64, ptr %15, align 8, !tbaa !8
  %98 = load i64, ptr %13, align 8, !tbaa !8
  %99 = icmp sgt i64 %97, %98
  br i1 %99, label %100, label %107

100:                                              ; preds = %94
  call void @llvm.lifetime.start.p0(i64 16, ptr %16) #9
  invoke void @_ZNSt4pairIxxEC2IRxS2_TnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairIS4_S5_EEEbE4typeELb1EEEOS4_OS5_(ptr noundef nonnull align 8 dereferenceable(16) %16, ptr noundef nonnull align 8 dereferenceable(8) %13, ptr noundef nonnull align 8 dereferenceable(8) %15)
          to label %101 unwind label %103

101:                                              ; preds = %100
  invoke void @_ZNSt6vectorISt4pairIxxESaIS1_EE9push_backEOS1_(ptr noundef nonnull align 8 dereferenceable(24) %12, ptr noundef nonnull align 8 dereferenceable(16) %16)
          to label %102 unwind label %103

102:                                              ; preds = %101
  call void @llvm.lifetime.end.p0(i64 16, ptr %16) #9
  br label %107

103:                                              ; preds = %101, %100
  %104 = landingpad { ptr, i32 }
          cleanup
  %105 = extractvalue { ptr, i32 } %104, 0
  store ptr %105, ptr %17, align 8
  %106 = extractvalue { ptr, i32 } %104, 1
  store i32 %106, ptr %18, align 4
  call void @llvm.lifetime.end.p0(i64 16, ptr %16) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #9
  br label %315

107:                                              ; preds = %102, %94
  %108 = load i64, ptr %15, align 8, !tbaa !8
  %109 = add nsw i64 %108, 1
  store i64 %109, ptr %13, align 8, !tbaa !8
  br label %110

110:                                              ; preds = %107, %86, %82
  br label %111

111:                                              ; preds = %110
  %112 = load i64, ptr %15, align 8, !tbaa !8
  %113 = add nsw i64 %112, 1
  store i64 %113, ptr %15, align 8, !tbaa !8
  br label %77, !llvm.loop !14

114:                                              ; preds = %81
  %115 = load i64, ptr %14, align 8, !tbaa !8
  %116 = load i64, ptr %3, align 8, !tbaa !8
  %117 = icmp slt i64 %115, %116
  br i1 %117, label %118, label %127

118:                                              ; preds = %114
  %119 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, i32 noundef -1)
          to label %120 unwind label %123

120:                                              ; preds = %118
  %121 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSoS_E(ptr noundef nonnull align 8 dereferenceable(8) %119, ptr noundef @_ZSt4endlIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_)
          to label %122 unwind label %123

122:                                              ; preds = %120
  store i32 0, ptr %1, align 4
  store i32 1, ptr %19, align 4
  br label %312

123:                                              ; preds = %120, %118
  %124 = landingpad { ptr, i32 }
          cleanup
  %125 = extractvalue { ptr, i32 } %124, 0
  store ptr %125, ptr %17, align 8
  %126 = extractvalue { ptr, i32 } %124, 1
  store i32 %126, ptr %18, align 4
  br label %315

127:                                              ; preds = %114
  %128 = load i64, ptr %13, align 8, !tbaa !8
  %129 = load i64, ptr %2, align 8, !tbaa !8
  %130 = icmp ne i64 %128, %129
  br i1 %130, label %131, label %138

131:                                              ; preds = %127
  call void @llvm.lifetime.start.p0(i64 16, ptr %20) #9
  invoke void @_ZNSt4pairIxxEC2IRxS2_TnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairIS4_S5_EEEbE4typeELb1EEEOS4_OS5_(ptr noundef nonnull align 8 dereferenceable(16) %20, ptr noundef nonnull align 8 dereferenceable(8) %13, ptr noundef nonnull align 8 dereferenceable(8) %2)
          to label %132 unwind label %134

132:                                              ; preds = %131
  invoke void @_ZNSt6vectorISt4pairIxxESaIS1_EE9push_backEOS1_(ptr noundef nonnull align 8 dereferenceable(24) %12, ptr noundef nonnull align 8 dereferenceable(16) %20)
          to label %133 unwind label %134

133:                                              ; preds = %132
  call void @llvm.lifetime.end.p0(i64 16, ptr %20) #9
  br label %138

134:                                              ; preds = %132, %131
  %135 = landingpad { ptr, i32 }
          cleanup
  %136 = extractvalue { ptr, i32 } %135, 0
  store ptr %136, ptr %17, align 8
  %137 = extractvalue { ptr, i32 } %135, 1
  store i32 %137, ptr %18, align 4
  call void @llvm.lifetime.end.p0(i64 16, ptr %20) #9
  br label %315

138:                                              ; preds = %133, %127
  call void @llvm.lifetime.start.p0(i64 8, ptr %21) #9
  store i64 0, ptr %21, align 8, !tbaa !8
  call void @llvm.lifetime.start.p0(i64 8, ptr %22) #9
  store ptr %12, ptr %22, align 8, !tbaa !15
  call void @llvm.lifetime.start.p0(i64 8, ptr %23) #9
  %139 = load ptr, ptr %22, align 8, !tbaa !15
  %140 = call ptr @_ZNSt6vectorISt4pairIxxESaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %139) #9
  %141 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %23, i32 0, i32 0
  store ptr %140, ptr %141, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %24) #9
  %142 = load ptr, ptr %22, align 8, !tbaa !15
  %143 = call ptr @_ZNSt6vectorISt4pairIxxESaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %142) #9
  %144 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %24, i32 0, i32 0
  store ptr %143, ptr %144, align 8
  br label %145

145:                                              ; preds = %293, %138
  %146 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPSt4pairIxxESt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8) %23, ptr noundef nonnull align 8 dereferenceable(8) %24) #9
  br i1 %146, label %148, label %147

147:                                              ; preds = %145
  store i32 11, ptr %19, align 4
  br label %298

148:                                              ; preds = %145
  call void @llvm.lifetime.start.p0(i64 16, ptr %25) #9
  %149 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPSt4pairIxxESt6vectorIS2_SaIS2_EEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %23) #9
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %25, ptr align 8 %149, i64 16, i1 false)
  call void @llvm.lifetime.start.p0(i64 8, ptr %26) #9
  %150 = getelementptr inbounds %"struct.std::pair", ptr %25, i32 0, i32 0
  %151 = load i64, ptr %150, align 8, !tbaa !17
  store i64 %151, ptr %26, align 8, !tbaa !8
  call void @llvm.lifetime.start.p0(i64 8, ptr %27) #9
  %152 = getelementptr inbounds %"struct.std::pair", ptr %25, i32 0, i32 1
  %153 = load i64, ptr %152, align 8, !tbaa !19
  store i64 %153, ptr %27, align 8, !tbaa !8
  call void @llvm.lifetime.start.p0(i64 8, ptr %28) #9
  store i64 0, ptr %28, align 8, !tbaa !8
  call void @llvm.lifetime.start.p0(i64 8, ptr %29) #9
  %154 = load i64, ptr %26, align 8, !tbaa !8
  store i64 %154, ptr %29, align 8, !tbaa !8
  br label %155

155:                                              ; preds = %166, %148
  %156 = load i64, ptr %29, align 8, !tbaa !8
  %157 = load i64, ptr %27, align 8, !tbaa !8
  %158 = icmp slt i64 %156, %157
  br i1 %158, label %160, label %159

159:                                              ; preds = %155
  store i32 13, ptr %19, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %29) #9
  br label %173

160:                                              ; preds = %155
  %161 = load i64, ptr %29, align 8, !tbaa !8
  %162 = getelementptr inbounds i64, ptr %48, i64 %161
  %163 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3maxIxERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) %28, ptr noundef nonnull align 8 dereferenceable(8) %162)
          to label %164 unwind label %169

164:                                              ; preds = %160
  %165 = load i64, ptr %163, align 8, !tbaa !8
  store i64 %165, ptr %28, align 8, !tbaa !8
  br label %166

166:                                              ; preds = %164
  %167 = load i64, ptr %29, align 8, !tbaa !8
  %168 = add nsw i64 %167, 1
  store i64 %168, ptr %29, align 8, !tbaa !8
  br label %155, !llvm.loop !20

169:                                              ; preds = %160
  %170 = landingpad { ptr, i32 }
          cleanup
  %171 = extractvalue { ptr, i32 } %170, 0
  store ptr %171, ptr %17, align 8
  %172 = extractvalue { ptr, i32 } %170, 1
  store i32 %172, ptr %18, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %29) #9
  br label %297

173:                                              ; preds = %159
  call void @llvm.lifetime.start.p0(i64 8, ptr %30) #9
  store i64 0, ptr %30, align 8, !tbaa !8
  %174 = load i64, ptr %26, align 8, !tbaa !8
  %175 = icmp sgt i64 %174, 0
  br i1 %175, label %176, label %187

176:                                              ; preds = %173
  %177 = load i64, ptr %26, align 8, !tbaa !8
  %178 = sub nsw i64 %177, 1
  %179 = getelementptr inbounds i64, ptr %48, i64 %178
  %180 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3maxIxERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) %30, ptr noundef nonnull align 8 dereferenceable(8) %179)
          to label %181 unwind label %183

181:                                              ; preds = %176
  %182 = load i64, ptr %180, align 8, !tbaa !8
  store i64 %182, ptr %30, align 8, !tbaa !8
  br label %187

183:                                              ; preds = %191, %176
  %184 = landingpad { ptr, i32 }
          cleanup
  %185 = extractvalue { ptr, i32 } %184, 0
  store ptr %185, ptr %17, align 8
  %186 = extractvalue { ptr, i32 } %184, 1
  store i32 %186, ptr %18, align 4
  br label %296

187:                                              ; preds = %181, %173
  %188 = load i64, ptr %27, align 8, !tbaa !8
  %189 = load i64, ptr %2, align 8, !tbaa !8
  %190 = icmp slt i64 %188, %189
  br i1 %190, label %191, label %197

191:                                              ; preds = %187
  %192 = load i64, ptr %27, align 8, !tbaa !8
  %193 = getelementptr inbounds i64, ptr %48, i64 %192
  %194 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3maxIxERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) %30, ptr noundef nonnull align 8 dereferenceable(8) %193)
          to label %195 unwind label %183

195:                                              ; preds = %191
  %196 = load i64, ptr %194, align 8, !tbaa !8
  store i64 %196, ptr %30, align 8, !tbaa !8
  br label %197

197:                                              ; preds = %195, %187
  call void @llvm.lifetime.start.p0(i64 8, ptr %31) #9
  store i64 9223372036854775807, ptr %31, align 8, !tbaa !8
  %198 = load i64, ptr %30, align 8, !tbaa !8
  %199 = load i64, ptr %28, align 8, !tbaa !8
  %200 = icmp sgt i64 %198, %199
  br i1 %200, label %207, label %201

201:                                              ; preds = %197
  %202 = load i64, ptr %27, align 8, !tbaa !8
  %203 = load i64, ptr %26, align 8, !tbaa !8
  %204 = sub nsw i64 %202, %203
  %205 = load i64, ptr %5, align 8, !tbaa !8
  %206 = icmp sge i64 %204, %205
  br i1 %206, label %207, label %230

207:                                              ; preds = %201, %197
  call void @llvm.lifetime.start.p0(i64 8, ptr %32) #9
  %208 = load i64, ptr %27, align 8, !tbaa !8
  %209 = load i64, ptr %26, align 8, !tbaa !8
  %210 = sub nsw i64 %208, %209
  %211 = load i64, ptr %5, align 8, !tbaa !8
  %212 = sdiv i64 %210, %211
  %213 = load i64, ptr %4, align 8, !tbaa !8
  %214 = mul nsw i64 %212, %213
  %215 = load i64, ptr %27, align 8, !tbaa !8
  %216 = load i64, ptr %26, align 8, !tbaa !8
  %217 = sub nsw i64 %215, %216
  %218 = load i64, ptr %5, align 8, !tbaa !8
  %219 = srem i64 %217, %218
  %220 = load i64, ptr %6, align 8, !tbaa !8
  %221 = mul nsw i64 %219, %220
  %222 = add nsw i64 %214, %221
  store i64 %222, ptr %32, align 8, !tbaa !8
  %223 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3minIxERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) %31, ptr noundef nonnull align 8 dereferenceable(8) %32)
          to label %224 unwind label %226

224:                                              ; preds = %207
  %225 = load i64, ptr %223, align 8, !tbaa !8
  store i64 %225, ptr %31, align 8, !tbaa !8
  call void @llvm.lifetime.end.p0(i64 8, ptr %32) #9
  br label %230

226:                                              ; preds = %207
  %227 = landingpad { ptr, i32 }
          cleanup
  %228 = extractvalue { ptr, i32 } %227, 0
  store ptr %228, ptr %17, align 8
  %229 = extractvalue { ptr, i32 } %227, 1
  store i32 %229, ptr %18, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %32) #9
  br label %295

230:                                              ; preds = %224, %201
  %231 = load i64, ptr %30, align 8, !tbaa !8
  %232 = load i64, ptr %28, align 8, !tbaa !8
  %233 = icmp sgt i64 %231, %232
  br i1 %233, label %234, label %247

234:                                              ; preds = %230
  call void @llvm.lifetime.start.p0(i64 8, ptr %33) #9
  %235 = load i64, ptr %27, align 8, !tbaa !8
  %236 = load i64, ptr %26, align 8, !tbaa !8
  %237 = sub nsw i64 %235, %236
  %238 = load i64, ptr %6, align 8, !tbaa !8
  %239 = mul nsw i64 %237, %238
  store i64 %239, ptr %33, align 8, !tbaa !8
  %240 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3minIxERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) %31, ptr noundef nonnull align 8 dereferenceable(8) %33)
          to label %241 unwind label %243

241:                                              ; preds = %234
  %242 = load i64, ptr %240, align 8, !tbaa !8
  store i64 %242, ptr %31, align 8, !tbaa !8
  call void @llvm.lifetime.end.p0(i64 8, ptr %33) #9
  br label %271

243:                                              ; preds = %234
  %244 = landingpad { ptr, i32 }
          cleanup
  %245 = extractvalue { ptr, i32 } %244, 0
  store ptr %245, ptr %17, align 8
  %246 = extractvalue { ptr, i32 } %244, 1
  store i32 %246, ptr %18, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %33) #9
  br label %295

247:                                              ; preds = %230
  %248 = load i64, ptr %27, align 8, !tbaa !8
  %249 = load i64, ptr %26, align 8, !tbaa !8
  %250 = sub nsw i64 %248, %249
  %251 = load i64, ptr %5, align 8, !tbaa !8
  %252 = icmp sge i64 %250, %251
  br i1 %252, label %253, label %270

253:                                              ; preds = %247
  call void @llvm.lifetime.start.p0(i64 8, ptr %34) #9
  %254 = load i64, ptr %4, align 8, !tbaa !8
  %255 = load i64, ptr %27, align 8, !tbaa !8
  %256 = load i64, ptr %26, align 8, !tbaa !8
  %257 = sub nsw i64 %255, %256
  %258 = load i64, ptr %5, align 8, !tbaa !8
  %259 = sub nsw i64 %257, %258
  %260 = load i64, ptr %6, align 8, !tbaa !8
  %261 = mul nsw i64 %259, %260
  %262 = add nsw i64 %254, %261
  store i64 %262, ptr %34, align 8, !tbaa !8
  %263 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3minIxERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) %31, ptr noundef nonnull align 8 dereferenceable(8) %34)
          to label %264 unwind label %266

264:                                              ; preds = %253
  %265 = load i64, ptr %263, align 8, !tbaa !8
  store i64 %265, ptr %31, align 8, !tbaa !8
  call void @llvm.lifetime.end.p0(i64 8, ptr %34) #9
  br label %270

266:                                              ; preds = %253
  %267 = landingpad { ptr, i32 }
          cleanup
  %268 = extractvalue { ptr, i32 } %267, 0
  store ptr %268, ptr %17, align 8
  %269 = extractvalue { ptr, i32 } %267, 1
  store i32 %269, ptr %18, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %34) #9
  br label %295

270:                                              ; preds = %264, %247
  br label %271

271:                                              ; preds = %270, %241
  %272 = load i64, ptr %31, align 8, !tbaa !8
  %273 = icmp eq i64 %272, 9223372036854775807
  br i1 %273, label %274, label %283

274:                                              ; preds = %271
  %275 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, i32 noundef -1)
          to label %276 unwind label %279

276:                                              ; preds = %274
  %277 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSoS_E(ptr noundef nonnull align 8 dereferenceable(8) %275, ptr noundef @_ZSt4endlIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_)
          to label %278 unwind label %279

278:                                              ; preds = %276
  store i32 0, ptr %1, align 4
  store i32 1, ptr %19, align 4
  br label %287

279:                                              ; preds = %276, %274
  %280 = landingpad { ptr, i32 }
          cleanup
  %281 = extractvalue { ptr, i32 } %280, 0
  store ptr %281, ptr %17, align 8
  %282 = extractvalue { ptr, i32 } %280, 1
  store i32 %282, ptr %18, align 4
  br label %295

283:                                              ; preds = %271
  %284 = load i64, ptr %31, align 8, !tbaa !8
  %285 = load i64, ptr %21, align 8, !tbaa !8
  %286 = add nsw i64 %285, %284
  store i64 %286, ptr %21, align 8, !tbaa !8
  store i32 0, ptr %19, align 4
  br label %287

287:                                              ; preds = %283, %278
  call void @llvm.lifetime.end.p0(i64 8, ptr %31) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %30) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %28) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %27) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %26) #9
  %288 = load i32, ptr %19, align 4
  switch i32 %288, label %290 [
    i32 0, label %289
  ]

289:                                              ; preds = %287
  store i32 0, ptr %19, align 4
  br label %290

290:                                              ; preds = %289, %287
  call void @llvm.lifetime.end.p0(i64 16, ptr %25) #9
  %291 = load i32, ptr %19, align 4
  switch i32 %291, label %298 [
    i32 0, label %292
  ]

292:                                              ; preds = %290
  br label %293

293:                                              ; preds = %292
  %294 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZN9__gnu_cxx17__normal_iteratorIPSt4pairIxxESt6vectorIS2_SaIS2_EEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %23) #9
  br label %145

295:                                              ; preds = %279, %266, %243, %226
  call void @llvm.lifetime.end.p0(i64 8, ptr %31) #9
  br label %296

296:                                              ; preds = %295, %183
  call void @llvm.lifetime.end.p0(i64 8, ptr %30) #9
  br label %297

297:                                              ; preds = %296, %169
  call void @llvm.lifetime.end.p0(i64 8, ptr %28) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %27) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %26) #9
  call void @llvm.lifetime.end.p0(i64 16, ptr %25) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %24) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %23) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #9
  br label %311

298:                                              ; preds = %290, %147
  call void @llvm.lifetime.end.p0(i64 8, ptr %24) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %23) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #9
  %299 = load i32, ptr %19, align 4
  switch i32 %299, label %310 [
    i32 11, label %300
  ]

300:                                              ; preds = %298
  %301 = load i64, ptr %21, align 8, !tbaa !8
  %302 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEx(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, i64 noundef %301)
          to label %303 unwind label %306

303:                                              ; preds = %300
  %304 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSoS_E(ptr noundef nonnull align 8 dereferenceable(8) %302, ptr noundef @_ZSt4endlIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_)
          to label %305 unwind label %306

305:                                              ; preds = %303
  store i32 0, ptr %1, align 4
  store i32 1, ptr %19, align 4
  br label %310

306:                                              ; preds = %303, %300
  %307 = landingpad { ptr, i32 }
          cleanup
  %308 = extractvalue { ptr, i32 } %307, 0
  store ptr %308, ptr %17, align 8
  %309 = extractvalue { ptr, i32 } %307, 1
  store i32 %309, ptr %18, align 4
  br label %311

310:                                              ; preds = %305, %298
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #9
  br label %312

311:                                              ; preds = %306, %297
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #9
  br label %315

312:                                              ; preds = %310, %122
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #9
  call void @_ZNSt6vectorISt4pairIxxESaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %12) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr %12) #9
  %313 = load ptr, ptr %7, align 8
  call void @llvm.stackrestore.p0(ptr %313)
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %5) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %4) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %3) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %2) #9
  %314 = load i32, ptr %1, align 4
  ret i32 %314

315:                                              ; preds = %311, %134, %123, %103
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #9
  call void @_ZNSt6vectorISt4pairIxxESaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %12) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr %12) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %5) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %4) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %3) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %2) #9
  br label %316

316:                                              ; preds = %315
  %317 = load ptr, ptr %17, align 8
  %318 = load i32, ptr %18, align 4
  %319 = insertvalue { ptr, i32 } poison, ptr %317, 0
  %320 = insertvalue { ptr, i32 } %319, i32 %318, 1
  resume { ptr, i32 } %320
}

declare noundef zeroext i1 @_ZNSt8ios_base15sync_with_stdioEb(i1 noundef zeroext) #1

; Function Attrs: mustprogress nounwind uwtable
declare noundef ptr @_ZNSt9basic_iosIcSt11char_traitsIcEE3tieEPSo(ptr noundef nonnull align 8 dereferenceable(264), ptr noundef) #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: mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 8 dereferenceable(8)) #4 align 2

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt6vectorISt4pairIxxESaIS1_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt6vectorISt4pairIxxESaIS1_EE9push_backEOS1_(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(16)) #4 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt4pairIxxEC2IRxS2_TnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairIS4_S5_EEEbE4typeELb1EEEOS4_OS5_(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(8)) unnamed_addr #2 align 2

declare i32 @__gxx_personality_v0(...)

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) #4 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 ptr @_ZNSt6vectorISt4pairIxxESaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24)) #2 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local ptr @_ZNSt6vectorISt4pairIxxESaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24)) #2 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZN9__gnu_cxxneIPSt4pairIxxESt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(8)) #7

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(16) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPSt4pairIxxESt6vectorIS2_SaIS2_EEEdeEv(ptr noundef nonnull align 8 dereferenceable(8)) #2 align 2

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #8

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(8) ptr @_ZN9__gnu_cxx17__normal_iteratorIPSt4pairIxxESt6vectorIS2_SaIS2_EEEppEv(ptr noundef nonnull align 8 dereferenceable(8)) #2 align 2

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt6vectorISt4pairIxxESaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #2 align 2

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

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 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 #3 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #4 = { 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 = { nocallback nofree nosync nounwind willreturn }
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 = { 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 #8 = { nocallback nofree nounwind willreturn memory(argmem: readwrite) }
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 = !{!"vtable pointer", !7, i64 0}
!7 = !{!"Simple C++ TBAA"}
!8 = !{!9, !9, i64 0}
!9 = !{!"long long", !10, i64 0}
!10 = !{!"omnipotent char", !7, i64 0}
!11 = distinct !{!11, !12}
!12 = !{!"llvm.loop.mustprogress"}
!13 = distinct !{!13, !12}
!14 = distinct !{!14, !12}
!15 = !{!16, !16, i64 0}
!16 = !{!"any pointer", !10, i64 0}
!17 = !{!18, !9, i64 0}
!18 = !{!"_ZTSSt4pairIxxE", !9, i64 0, !9, i64 8}
!19 = !{!18, !9, i64 8}
!20 = distinct !{!20, !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_istream" = type { ptr, i64, %"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::basic_ostream" = type { ptr, %"class.std::basic_ios" }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<std::pair<long long, long long>, std::allocator<std::pair<long long, long long>>>::_Vector_impl" }
%"struct.std::_Vector_base<std::pair<long long, long long>, std::allocator<std::pair<long long, long long>>>::_Vector_impl" = type { %"struct.std::_Vector_base<std::pair<long long, long long>, std::allocator<std::pair<long long, long long>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<std::pair<long long, long long>, std::allocator<std::pair<long long, long long>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"struct.std::pair" = type { i64, i64 }
%"class.__gnu_cxx::__normal_iterator" = type { ptr }

@_ZSt3cin = external global %"class.std::basic_istream", align 8
@_ZSt4cout = external global %"class.std::basic_ostream", align 8

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() local_unnamed_addr #0 personality ptr @__gxx_personality_v0 {
  %1 = alloca i64, align 8
  %2 = alloca i64, align 8
  %3 = alloca i64, align 8
  %4 = alloca i64, align 8
  %5 = alloca i64, align 8
  %6 = alloca %"class.std::vector", align 8
  %7 = alloca i64, align 8
  %8 = alloca i64, align 8
  %9 = alloca %"struct.std::pair", align 8
  %10 = alloca %"struct.std::pair", align 8
  %11 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %12 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %13 = alloca i64, align 8
  %14 = alloca i64, align 8
  %15 = alloca i64, align 8
  %16 = alloca i64, align 8
  %17 = alloca i64, align 8
  %18 = alloca i64, align 8
  %19 = tail call noundef zeroext i1 @_ZNSt8ios_base15sync_with_stdioEb(i1 noundef zeroext false)
  %20 = load ptr, ptr @_ZSt3cin, align 8, !tbaa !5
  %21 = getelementptr i8, ptr %20, i64 -24
  %22 = load i64, ptr %21, align 8
  %23 = getelementptr inbounds i8, ptr @_ZSt3cin, i64 %22
  %24 = tail call noundef ptr @_ZNSt9basic_iosIcSt11char_traitsIcEE3tieEPSo(ptr noundef nonnull align 8 dereferenceable(264) %23, ptr noundef null)
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %1) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %2) #8
  %25 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 8 dereferenceable(8) %1)
  %26 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16) %25, ptr noundef nonnull align 8 dereferenceable(8) %2)
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %3) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %4) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %5) #8
  %27 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 8 dereferenceable(8) %3)
  %28 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16) %27, ptr noundef nonnull align 8 dereferenceable(8) %4)
  %29 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16) %28, ptr noundef nonnull align 8 dereferenceable(8) %5)
  %30 = load i64, ptr %1, align 8, !tbaa !8
  %31 = call ptr @llvm.stacksave.p0()
  %32 = alloca i64, i64 %30, align 16
  %33 = load i64, ptr %2, align 8, !tbaa !8
  %34 = alloca i64, i64 %33, align 16
  %35 = load i64, ptr %1, align 8, !tbaa !8
  %36 = icmp sgt i64 %35, 0
  br i1 %36, label %.lr.ph, label %.preheader

.preheader.loopexit:                              ; preds = %.lr.ph
  %.pre = load i64, ptr %2, align 8, !tbaa !8
  br label %.preheader

.preheader:                                       ; preds = %.preheader.loopexit, %0
  %37 = phi i64 [ %.pre, %.preheader.loopexit ], [ %33, %0 ]
  %38 = icmp sgt i64 %37, 0
  br i1 %38, label %.lr.ph75, label %._crit_edge

.lr.ph:                                           ; preds = %0, %.lr.ph
  %.04473 = phi i64 [ %41, %.lr.ph ], [ 0, %0 ]
  %39 = getelementptr inbounds i64, ptr %32, i64 %.04473
  %40 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 8 dereferenceable(8) %39)
  %41 = add nuw nsw i64 %.04473, 1
  %42 = load i64, ptr %1, align 8, !tbaa !8
  %43 = icmp slt i64 %41, %42
  br i1 %43, label %.lr.ph, label %.preheader.loopexit, !llvm.loop !11

._crit_edge:                                      ; preds = %.lr.ph75, %.preheader
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %6) #8
  call void @_ZNSt6vectorISt4pairIxxESaIS1_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %6) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %7) #8
  store i64 0, ptr %7, align 8, !tbaa !8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %8) #8
  store i64 0, ptr %8, align 8, !tbaa !8
  %44 = load i64, ptr %1, align 8, !tbaa !8
  %45 = icmp sgt i64 %44, 0
  br i1 %45, label %.lr.ph79, label %._crit_edge80

.lr.ph75:                                         ; preds = %.preheader, %.lr.ph75
  %.04574 = phi i64 [ %48, %.lr.ph75 ], [ 0, %.preheader ]
  %46 = getelementptr inbounds i64, ptr %34, i64 %.04574
  %47 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 8 dereferenceable(8) %46)
  %48 = add nuw nsw i64 %.04574, 1
  %49 = load i64, ptr %2, align 8, !tbaa !8
  %50 = icmp slt i64 %48, %49
  br i1 %50, label %.lr.ph75, label %._crit_edge, !llvm.loop !13

._crit_edge80:                                    ; preds = %74, %._crit_edge
  %51 = phi i64 [ 0, %._crit_edge ], [ %77, %74 ]
  %.046.lcssa = phi i64 [ 0, %._crit_edge ], [ %.147, %74 ]
  %.lcssa = phi i64 [ %44, %._crit_edge ], [ %75, %74 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #8
  %52 = load i64, ptr %2, align 8, !tbaa !8
  %53 = icmp slt i64 %.046.lcssa, %52
  br i1 %53, label %80, label %86

.lr.ph79:                                         ; preds = %._crit_edge, %74
  %.pre96101 = phi i64 [ %.pre96102, %74 ], [ %44, %._crit_edge ]
  %54 = phi i64 [ %75, %74 ], [ %44, %._crit_edge ]
  %55 = phi i64 [ %77, %74 ], [ 0, %._crit_edge ]
  %.04677 = phi i64 [ %.147, %74 ], [ 0, %._crit_edge ]
  %storemerge76 = phi i64 [ %78, %74 ], [ 0, %._crit_edge ]
  %56 = load i64, ptr %2, align 8, !tbaa !8
  %57 = icmp slt i64 %.04677, %56
  br i1 %57, label %58, label %74

58:                                               ; preds = %.lr.ph79
  %59 = getelementptr inbounds i64, ptr %32, i64 %storemerge76
  %60 = load i64, ptr %59, align 8, !tbaa !8
  %61 = getelementptr inbounds i64, ptr %34, i64 %.04677
  %62 = load i64, ptr %61, align 8, !tbaa !8
  %63 = icmp eq i64 %60, %62
  br i1 %63, label %64, label %74

64:                                               ; preds = %58
  %65 = add nsw i64 %.04677, 1
  %66 = icmp sgt i64 %storemerge76, %55
  br i1 %66, label %67, label %71

67:                                               ; preds = %64
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %9) #8
  call void @_ZNSt4pairIxxEC2IRxS2_TnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairIS4_S5_EEEbE4typeELb1EEEOS4_OS5_(ptr noundef nonnull align 8 dereferenceable(16) %9, ptr noundef nonnull align 8 dereferenceable(8) %7, ptr noundef nonnull align 8 dereferenceable(8) %8)
  invoke void @_ZNSt6vectorISt4pairIxxESaIS1_EE9push_backEOS1_(ptr noundef nonnull align 8 dereferenceable(24) %6, ptr noundef nonnull align 8 dereferenceable(16) %9)
          to label %68 unwind label %69

68:                                               ; preds = %67
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %9) #8
  %.pre95 = load i64, ptr %8, align 8, !tbaa !8
  %.pre96.pre = load i64, ptr %1, align 8, !tbaa !8
  br label %71

69:                                               ; preds = %67
  %70 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %9) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #8
  br label %165

71:                                               ; preds = %68, %64
  %.pre96 = phi i64 [ %.pre96.pre, %68 ], [ %.pre96101, %64 ]
  %72 = phi i64 [ %.pre95, %68 ], [ %storemerge76, %64 ]
  %73 = add nsw i64 %72, 1
  store i64 %73, ptr %7, align 8, !tbaa !8
  br label %74

74:                                               ; preds = %.lr.ph79, %58, %71
  %.pre96102 = phi i64 [ %.pre96, %71 ], [ %.pre96101, %58 ], [ %.pre96101, %.lr.ph79 ]
  %75 = phi i64 [ %.pre96, %71 ], [ %54, %58 ], [ %54, %.lr.ph79 ]
  %76 = phi i64 [ %72, %71 ], [ %storemerge76, %58 ], [ %storemerge76, %.lr.ph79 ]
  %77 = phi i64 [ %73, %71 ], [ %55, %58 ], [ %55, %.lr.ph79 ]
  %.147 = phi i64 [ %65, %71 ], [ %.04677, %58 ], [ %.04677, %.lr.ph79 ]
  %78 = add nsw i64 %76, 1
  store i64 %78, ptr %8, align 8, !tbaa !8
  %79 = icmp slt i64 %78, %75
  br i1 %79, label %.lr.ph79, label %._crit_edge80, !llvm.loop !14

80:                                               ; preds = %._crit_edge80
  %81 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, i32 noundef -1)
          to label %82 unwind label %84

82:                                               ; preds = %80
  %83 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSoS_E(ptr noundef nonnull align 8 dereferenceable(8) %81, ptr noundef nonnull @_ZSt4endlIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_)
          to label %164 unwind label %84

84:                                               ; preds = %82, %80
  %85 = landingpad { ptr, i32 }
          cleanup
  br label %165

86:                                               ; preds = %._crit_edge80
  %.not = icmp eq i64 %51, %.lcssa
  br i1 %.not, label %91, label %87

87:                                               ; preds = %86
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %10) #8
  call void @_ZNSt4pairIxxEC2IRxS2_TnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairIS4_S5_EEEbE4typeELb1EEEOS4_OS5_(ptr noundef nonnull align 8 dereferenceable(16) %10, ptr noundef nonnull align 8 dereferenceable(8) %7, ptr noundef nonnull align 8 dereferenceable(8) %1)
  invoke void @_ZNSt6vectorISt4pairIxxESaIS1_EE9push_backEOS1_(ptr noundef nonnull align 8 dereferenceable(24) %6, ptr noundef nonnull align 8 dereferenceable(16) %10)
          to label %88 unwind label %89

88:                                               ; preds = %87
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %10) #8
  br label %91

89:                                               ; preds = %87
  %90 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %10) #8
  br label %165

91:                                               ; preds = %88, %86
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %11) #8
  %92 = call ptr @_ZNSt6vectorISt4pairIxxESaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %6) #8
  store ptr %92, ptr %11, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %12) #8
  %93 = call ptr @_ZNSt6vectorISt4pairIxxESaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %6) #8
  store ptr %93, ptr %12, align 8
  %invariant.gep = getelementptr i8, ptr %32, i64 -8
  %94 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPSt4pairIxxESt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8) %11, ptr noundef nonnull align 8 dereferenceable(8) %12) #8
  br i1 %94, label %.lr.ph88, label %.loopexit

.lr.ph88:                                         ; preds = %91, %154
  %.05086 = phi i64 [ %155, %154 ], [ 0, %91 ]
  %95 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPSt4pairIxxESt6vectorIS2_SaIS2_EEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %11) #8
  %.sroa.0.0.copyload = load i64, ptr %95, align 8
  %.sroa.5.0..sroa_idx = getelementptr inbounds i8, ptr %95, i64 8
  %.sroa.5.0.copyload = load i64, ptr %.sroa.5.0..sroa_idx, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %13) #8
  store i64 0, ptr %13, align 8, !tbaa !8
  %96 = icmp slt i64 %.sroa.0.0.copyload, %.sroa.5.0.copyload
  br i1 %96, label %.lr.ph84, label %._crit_edge85

._crit_edge85:                                    ; preds = %.lr.ph84, %.lr.ph88
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %14) #8
  store i64 0, ptr %14, align 8, !tbaa !8
  %97 = icmp sgt i64 %.sroa.0.0.copyload, 0
  br i1 %97, label %102, label %105

.lr.ph84:                                         ; preds = %.lr.ph88, %.lr.ph84
  %.082 = phi i64 [ %101, %.lr.ph84 ], [ %.sroa.0.0.copyload, %.lr.ph88 ]
  %98 = getelementptr inbounds i64, ptr %32, i64 %.082
  %99 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3maxIxERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) %13, ptr noundef nonnull align 8 dereferenceable(8) %98)
  %100 = load i64, ptr %99, align 8, !tbaa !8
  store i64 %100, ptr %13, align 8, !tbaa !8
  %101 = add i64 %.082, 1
  %exitcond.not = icmp eq i64 %101, %.sroa.5.0.copyload
  br i1 %exitcond.not, label %._crit_edge85, label %.lr.ph84, !llvm.loop !15

102:                                              ; preds = %._crit_edge85
  %gep = getelementptr i64, ptr %invariant.gep, i64 %.sroa.0.0.copyload
  %103 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3maxIxERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) %14, ptr noundef nonnull align 8 dereferenceable(8) %gep)
  %104 = load i64, ptr %103, align 8, !tbaa !8
  store i64 %104, ptr %14, align 8, !tbaa !8
  br label %105

105:                                              ; preds = %102, %._crit_edge85
  %106 = phi i64 [ %104, %102 ], [ 0, %._crit_edge85 ]
  %107 = load i64, ptr %1, align 8, !tbaa !8
  %108 = icmp slt i64 %.sroa.5.0.copyload, %107
  br i1 %108, label %109, label %113

109:                                              ; preds = %105
  %110 = getelementptr inbounds i64, ptr %32, i64 %.sroa.5.0.copyload
  %111 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3maxIxERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) %14, ptr noundef nonnull align 8 dereferenceable(8) %110)
  %112 = load i64, ptr %111, align 8, !tbaa !8
  store i64 %112, ptr %14, align 8, !tbaa !8
  br label %113

113:                                              ; preds = %109, %105
  %114 = phi i64 [ %112, %109 ], [ %106, %105 ]
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %15) #8
  store i64 9223372036854775807, ptr %15, align 8, !tbaa !8
  %115 = load i64, ptr %13, align 8, !tbaa !8
  %116 = icmp sle i64 %114, %115
  %.pre97 = load i64, ptr %4, align 8, !tbaa !8
  %.pre106 = sub nsw i64 %.sroa.5.0.copyload, %.sroa.0.0.copyload
  %.not60 = icmp slt i64 %.pre106, %.pre97
  %or.cond = select i1 %116, i1 %.not60, i1 false
  br i1 %or.cond, label %126, label %._crit_edge105

._crit_edge105:                                   ; preds = %113
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %16) #8
  %117 = sdiv i64 %.pre106, %.pre97
  %118 = load i64, ptr %3, align 8, !tbaa !8
  %119 = mul nsw i64 %118, %117
  %120 = srem i64 %.pre106, %.pre97
  %121 = load i64, ptr %5, align 8, !tbaa !8
  %122 = mul nsw i64 %121, %120
  %123 = add nsw i64 %122, %119
  store i64 %123, ptr %16, align 8, !tbaa !8
  %124 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3minIxERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) %15, ptr noundef nonnull align 8 dereferenceable(8) %16)
  %125 = load i64, ptr %124, align 8, !tbaa !8
  store i64 %125, ptr %15, align 8, !tbaa !8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %16) #8
  %.pre98 = load i64, ptr %14, align 8, !tbaa !8
  %.pre99 = load i64, ptr %13, align 8, !tbaa !8
  br label %126

126:                                              ; preds = %113, %._crit_edge105
  %.pr = phi i64 [ %125, %._crit_edge105 ], [ 9223372036854775807, %113 ]
  %127 = phi i64 [ %.pre99, %._crit_edge105 ], [ %115, %113 ]
  %128 = phi i64 [ %.pre98, %._crit_edge105 ], [ %114, %113 ]
  %129 = icmp sgt i64 %128, %127
  br i1 %129, label %130, label %136

130:                                              ; preds = %126
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %17) #8
  %131 = sub nsw i64 %.sroa.5.0.copyload, %.sroa.0.0.copyload
  %132 = load i64, ptr %5, align 8, !tbaa !8
  %133 = mul nsw i64 %132, %131
  store i64 %133, ptr %17, align 8, !tbaa !8
  %134 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3minIxERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) %15, ptr noundef nonnull align 8 dereferenceable(8) %17)
  %135 = load i64, ptr %134, align 8, !tbaa !8
  store i64 %135, ptr %15, align 8, !tbaa !8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %17) #8
  br label %thread-pre-split

136:                                              ; preds = %126
  %137 = sub nsw i64 %.sroa.5.0.copyload, %.sroa.0.0.copyload
  %138 = load i64, ptr %4, align 8, !tbaa !8
  %.not61 = icmp slt i64 %137, %138
  br i1 %.not61, label %thread-pre-split, label %139

139:                                              ; preds = %136
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %18) #8
  %140 = load i64, ptr %3, align 8, !tbaa !8
  %141 = sub nsw i64 %137, %138
  %142 = load i64, ptr %5, align 8, !tbaa !8
  %143 = mul nsw i64 %142, %141
  %144 = add nsw i64 %143, %140
  store i64 %144, ptr %18, align 8, !tbaa !8
  %145 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3minIxERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) %15, ptr noundef nonnull align 8 dereferenceable(8) %18)
  %146 = load i64, ptr %145, align 8, !tbaa !8
  store i64 %146, ptr %15, align 8, !tbaa !8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %18) #8
  br label %thread-pre-split

thread-pre-split:                                 ; preds = %136, %139, %130
  %147 = phi i64 [ %146, %139 ], [ %135, %130 ], [ %.pr, %136 ]
  %.not62 = icmp eq i64 %147, 9223372036854775807
  br i1 %.not62, label %148, label %154

148:                                              ; preds = %thread-pre-split
  %149 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, i32 noundef -1)
          to label %150 unwind label %152

150:                                              ; preds = %148
  %151 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSoS_E(ptr noundef nonnull align 8 dereferenceable(8) %149, ptr noundef nonnull @_ZSt4endlIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_)
          to label %158 unwind label %152

152:                                              ; preds = %150, %148
  %153 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %15) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %14) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %13) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %12) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %11) #8
  br label %165

154:                                              ; preds = %thread-pre-split
  %155 = add nsw i64 %147, %.05086
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %15) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %14) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %13) #8
  %156 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZN9__gnu_cxx17__normal_iteratorIPSt4pairIxxESt6vectorIS2_SaIS2_EEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %11) #8
  %157 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPSt4pairIxxESt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8) %11, ptr noundef nonnull align 8 dereferenceable(8) %12) #8
  br i1 %157, label %.lr.ph88, label %.loopexit

158:                                              ; preds = %150
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %15) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %14) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %13) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %12) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %11) #8
  br label %164

.loopexit:                                        ; preds = %154, %91
  %.050.lcssa = phi i64 [ 0, %91 ], [ %155, %154 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %12) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %11) #8
  %159 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEx(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, i64 noundef %.050.lcssa)
          to label %160 unwind label %162

160:                                              ; preds = %.loopexit
  %161 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSoS_E(ptr noundef nonnull align 8 dereferenceable(8) %159, ptr noundef nonnull @_ZSt4endlIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_)
          to label %164 unwind label %162

162:                                              ; preds = %160, %.loopexit
  %163 = landingpad { ptr, i32 }
          cleanup
  br label %165

164:                                              ; preds = %158, %160, %82
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #8
  call void @_ZNSt6vectorISt4pairIxxESaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %6) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %6) #8
  call void @llvm.stackrestore.p0(ptr %31)
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %5) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %4) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %3) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %2) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %1) #8
  ret i32 0

165:                                              ; preds = %152, %162, %89, %84, %69
  %.pn64 = phi { ptr, i32 } [ %70, %69 ], [ %85, %84 ], [ %90, %89 ], [ %163, %162 ], [ %153, %152 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #8
  call void @_ZNSt6vectorISt4pairIxxESaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %6) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %6) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %5) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %4) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %3) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %2) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %1) #8
  resume { ptr, i32 } %.pn64
}

declare noundef zeroext i1 @_ZNSt8ios_base15sync_with_stdioEb(i1 noundef zeroext) local_unnamed_addr #1

; Function Attrs: mustprogress nounwind uwtable
declare noundef ptr @_ZNSt9basic_iosIcSt11char_traitsIcEE3tieEPSo(ptr noundef nonnull align 8 dereferenceable(264), ptr noundef) 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 uwtable
declare noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #4 align 2

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt6vectorISt4pairIxxESaIS1_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt6vectorISt4pairIxxESaIS1_EE9push_backEOS1_(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(16)) local_unnamed_addr #4 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt4pairIxxEC2IRxS2_TnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairIS4_S5_EEEbE4typeELb1EEEOS4_OS5_(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(8)) unnamed_addr #2 align 2

declare i32 @__gxx_personality_v0(...)

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

; 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 #4 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 ptr @_ZNSt6vectorISt4pairIxxESaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #2 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local ptr @_ZNSt6vectorISt4pairIxxESaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #2 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZN9__gnu_cxxneIPSt4pairIxxESt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #7

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(16) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPSt4pairIxxESt6vectorIS2_SaIS2_EEEdeEv(ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #2 align 2

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

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

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt6vectorISt4pairIxxESaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #2 align 2

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

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 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 #3 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #4 = { 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 = { mustprogress nocallback nofree nosync nounwind willreturn }
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 = { 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 #8 = { 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 = !{!"vtable pointer", !7, i64 0}
!7 = !{!"Simple C++ TBAA"}
!8 = !{!9, !9, i64 0}
!9 = !{!"long long", !10, i64 0}
!10 = !{!"omnipotent char", !7, i64 0}
!11 = distinct !{!11, !12}
!12 = !{!"llvm.loop.mustprogress"}
!13 = distinct !{!13, !12}
!14 = distinct !{!14, !12}
!15 = distinct !{!15, !12}


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