; LLVM IR from kazunetakahashi/atcoder :: 2017/0723_agc018 (C)

; 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::tuple" = type { %"struct.std::_Tuple_impl" }
%"struct.std::_Tuple_impl" = type { %"struct.std::_Tuple_impl.0", %"struct.std::_Head_base.3" }
%"struct.std::_Tuple_impl.0" = type { %"struct.std::_Tuple_impl.1", %"struct.std::_Head_base.2" }
%"struct.std::_Tuple_impl.1" = type { %"struct.std::_Head_base" }
%"struct.std::_Head_base" = type { i64 }
%"struct.std::_Head_base.2" = type { i64 }
%"struct.std::_Head_base.3" = type { i64 }
%"class.std::priority_queue" = type <{ %"class.std::vector", [8 x i8] }>
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<long long, std::allocator<long long>>::_Vector_impl" }
%"struct.std::_Vector_base<long long, std::allocator<long long>>::_Vector_impl" = type { %"struct.std::_Vector_base<long long, std::allocator<long long>>::_Vector_impl_data" }
%"struct.std::_Vector_base<long long, std::allocator<long long>>::_Vector_impl_data" = type { ptr, ptr, ptr }

@X = external dso_local global i64, align 8
@Y = external dso_local global i64, align 8
@Z = external dso_local global i64, align 8
@A = external dso_local global [100010 x i64], align 16
@B = external dso_local global [100010 x i64], align 16
@C = external dso_local global [100010 x i64], align 16
@silver = external dso_local global [100010 x i64], align 16
@gold = external dso_local global [100010 x i64], align 16
@_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 i32, align 4
  %4 = alloca i64, align 8
  %5 = alloca i32, align 4
  %6 = alloca [100010 x %"class.std::tuple"], align 16
  %7 = alloca i32, align 4
  %8 = alloca %"class.std::tuple", align 8
  %9 = alloca i64, align 8
  %10 = alloca i32, align 4
  %11 = alloca i64, align 8
  %12 = alloca %"class.std::priority_queue", align 8
  %13 = alloca i32, align 4
  %14 = alloca ptr, align 8
  %15 = alloca i32, align 4
  %16 = alloca %"class.std::priority_queue", align 8
  %17 = alloca i64, align 8
  %18 = alloca i64, align 8
  %19 = alloca i64, align 8
  %20 = alloca i64, align 8
  store i32 0, ptr %1, align 4
  %21 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 8 dereferenceable(8) @X)
  %22 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16) %21, ptr noundef nonnull align 8 dereferenceable(8) @Y)
  %23 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16) %22, ptr noundef nonnull align 8 dereferenceable(8) @Z)
  call void @llvm.lifetime.start.p0(i64 8, ptr %2) #6
  %24 = load i64, ptr @X, align 8, !tbaa !5
  %25 = load i64, ptr @Y, align 8, !tbaa !5
  %26 = add nsw i64 %24, %25
  %27 = load i64, ptr @Z, align 8, !tbaa !5
  %28 = add nsw i64 %26, %27
  store i64 %28, ptr %2, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %3) #6
  store i32 0, ptr %3, align 4, !tbaa !9
  br label %29

29:                                               ; preds = %48, %0
  %30 = load i32, ptr %3, align 4, !tbaa !9
  %31 = sext i32 %30 to i64
  %32 = load i64, ptr %2, align 8, !tbaa !5
  %33 = icmp slt i64 %31, %32
  br i1 %33, label %35, label %34

34:                                               ; preds = %29
  call void @llvm.lifetime.end.p0(i64 4, ptr %3) #6
  br label %51

35:                                               ; preds = %29
  %36 = load i32, ptr %3, align 4, !tbaa !9
  %37 = sext i32 %36 to i64
  %38 = getelementptr inbounds [100010 x i64], ptr @A, i64 0, i64 %37
  %39 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 8 dereferenceable(8) %38)
  %40 = load i32, ptr %3, align 4, !tbaa !9
  %41 = sext i32 %40 to i64
  %42 = getelementptr inbounds [100010 x i64], ptr @B, i64 0, i64 %41
  %43 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16) %39, ptr noundef nonnull align 8 dereferenceable(8) %42)
  %44 = load i32, ptr %3, align 4, !tbaa !9
  %45 = sext i32 %44 to i64
  %46 = getelementptr inbounds [100010 x i64], ptr @C, i64 0, i64 %45
  %47 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16) %43, ptr noundef nonnull align 8 dereferenceable(8) %46)
  br label %48

48:                                               ; preds = %35
  %49 = load i32, ptr %3, align 4, !tbaa !9
  %50 = add nsw i32 %49, 1
  store i32 %50, ptr %3, align 4, !tbaa !9
  br label %29, !llvm.loop !11

51:                                               ; preds = %34
  call void @llvm.lifetime.start.p0(i64 8, ptr %4) #6
  store i64 0, ptr %4, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %5) #6
  store i32 0, ptr %5, align 4, !tbaa !9
  br label %52

52:                                               ; preds = %83, %51
  %53 = load i32, ptr %5, align 4, !tbaa !9
  %54 = sext i32 %53 to i64
  %55 = load i64, ptr %2, align 8, !tbaa !5
  %56 = icmp slt i64 %54, %55
  br i1 %56, label %58, label %57

57:                                               ; preds = %52
  call void @llvm.lifetime.end.p0(i64 4, ptr %5) #6
  br label %86

58:                                               ; preds = %52
  %59 = load i32, ptr %5, align 4, !tbaa !9
  %60 = sext i32 %59 to i64
  %61 = getelementptr inbounds [100010 x i64], ptr @C, i64 0, i64 %60
  %62 = load i64, ptr %61, align 8, !tbaa !5
  %63 = load i32, ptr %5, align 4, !tbaa !9
  %64 = sext i32 %63 to i64
  %65 = getelementptr inbounds [100010 x i64], ptr @A, i64 0, i64 %64
  %66 = load i64, ptr %65, align 8, !tbaa !5
  %67 = sub nsw i64 %66, %62
  store i64 %67, ptr %65, align 8, !tbaa !5
  %68 = load i32, ptr %5, align 4, !tbaa !9
  %69 = sext i32 %68 to i64
  %70 = getelementptr inbounds [100010 x i64], ptr @C, i64 0, i64 %69
  %71 = load i64, ptr %70, align 8, !tbaa !5
  %72 = load i32, ptr %5, align 4, !tbaa !9
  %73 = sext i32 %72 to i64
  %74 = getelementptr inbounds [100010 x i64], ptr @B, i64 0, i64 %73
  %75 = load i64, ptr %74, align 8, !tbaa !5
  %76 = sub nsw i64 %75, %71
  store i64 %76, ptr %74, align 8, !tbaa !5
  %77 = load i32, ptr %5, align 4, !tbaa !9
  %78 = sext i32 %77 to i64
  %79 = getelementptr inbounds [100010 x i64], ptr @C, i64 0, i64 %78
  %80 = load i64, ptr %79, align 8, !tbaa !5
  %81 = load i64, ptr %4, align 8, !tbaa !5
  %82 = add nsw i64 %81, %80
  store i64 %82, ptr %4, align 8, !tbaa !5
  br label %83

83:                                               ; preds = %58
  %84 = load i32, ptr %5, align 4, !tbaa !9
  %85 = add nsw i32 %84, 1
  store i32 %85, ptr %5, align 4, !tbaa !9
  br label %52, !llvm.loop !13

86:                                               ; preds = %57
  call void @llvm.lifetime.start.p0(i64 2400240, ptr %6) #6
  %87 = getelementptr inbounds [100010 x %"class.std::tuple"], ptr %6, i32 0, i32 0
  %88 = getelementptr inbounds %"class.std::tuple", ptr %87, i64 100010
  br label %89

89:                                               ; preds = %89, %86
  %90 = phi ptr [ %87, %86 ], [ %91, %89 ]
  call void @_ZNSt5tupleIJxxxEEC2IvTnNSt9enable_ifIXclsr4_TCCIXsr7is_voidIT_EE5valueEEE37__is_implicitly_default_constructibleEEbE4typeELb1EEEv(ptr noundef nonnull align 8 dereferenceable(24) %90) #6
  %91 = getelementptr inbounds %"class.std::tuple", ptr %90, i64 1
  %92 = icmp eq ptr %91, %88
  br i1 %92, label %93, label %89

93:                                               ; preds = %89
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #6
  store i32 0, ptr %7, align 4, !tbaa !9
  br label %94

94:                                               ; preds = %120, %93
  %95 = load i32, ptr %7, align 4, !tbaa !9
  %96 = sext i32 %95 to i64
  %97 = load i64, ptr %2, align 8, !tbaa !5
  %98 = icmp slt i64 %96, %97
  br i1 %98, label %100, label %99

99:                                               ; preds = %94
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #6
  br label %123

100:                                              ; preds = %94
  call void @llvm.lifetime.start.p0(i64 24, ptr %8) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr %9) #6
  %101 = load i32, ptr %7, align 4, !tbaa !9
  %102 = sext i32 %101 to i64
  %103 = getelementptr inbounds [100010 x i64], ptr @A, i64 0, i64 %102
  %104 = load i64, ptr %103, align 8, !tbaa !5
  %105 = load i32, ptr %7, align 4, !tbaa !9
  %106 = sext i32 %105 to i64
  %107 = getelementptr inbounds [100010 x i64], ptr @B, i64 0, i64 %106
  %108 = load i64, ptr %107, align 8, !tbaa !5
  %109 = sub nsw i64 %104, %108
  store i64 %109, ptr %9, align 8, !tbaa !5
  %110 = load i32, ptr %7, align 4, !tbaa !9
  %111 = sext i32 %110 to i64
  %112 = getelementptr inbounds [100010 x i64], ptr @A, i64 0, i64 %111
  %113 = load i32, ptr %7, align 4, !tbaa !9
  %114 = sext i32 %113 to i64
  %115 = getelementptr inbounds [100010 x i64], ptr @B, i64 0, i64 %114
  call void @_ZNSt5tupleIJxxxEEC2IJxRxS2_ELb1ETnNSt9enable_ifIXclsr4_TCCIXT0_EEE29__is_implicitly_constructibleIDpT_EEEbE4typeELb1EEEDpOS4_(ptr noundef nonnull align 8 dereferenceable(24) %8, ptr noundef nonnull align 8 dereferenceable(8) %9, ptr noundef nonnull align 8 dereferenceable(8) %112, ptr noundef nonnull align 8 dereferenceable(8) %115) #6
  %116 = load i32, ptr %7, align 4, !tbaa !9
  %117 = sext i32 %116 to i64
  %118 = getelementptr inbounds [100010 x %"class.std::tuple"], ptr %6, i64 0, i64 %117
  %119 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt5tupleIJxxxEEaSEOS0_(ptr noundef nonnull align 8 dereferenceable(24) %118, ptr noundef nonnull align 8 dereferenceable(24) %8) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr %8) #6
  br label %120

120:                                              ; preds = %100
  %121 = load i32, ptr %7, align 4, !tbaa !9
  %122 = add nsw i32 %121, 1
  store i32 %122, ptr %7, align 4, !tbaa !9
  br label %94, !llvm.loop !14

123:                                              ; preds = %99
  %124 = getelementptr inbounds [100010 x %"class.std::tuple"], ptr %6, i64 0, i64 0
  %125 = getelementptr inbounds [100010 x %"class.std::tuple"], ptr %6, i64 0, i64 0
  %126 = load i64, ptr %2, align 8, !tbaa !5
  %127 = getelementptr inbounds %"class.std::tuple", ptr %125, i64 %126
  call void @_ZSt4sortIPSt5tupleIJxxxEEEvT_S3_(ptr noundef %124, ptr noundef %127)
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #6
  store i32 0, ptr %10, align 4, !tbaa !9
  br label %128

128:                                              ; preds = %151, %123
  %129 = load i32, ptr %10, align 4, !tbaa !9
  %130 = sext i32 %129 to i64
  %131 = load i64, ptr %2, align 8, !tbaa !5
  %132 = icmp slt i64 %130, %131
  br i1 %132, label %134, label %133

133:                                              ; preds = %128
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #6
  br label %154

134:                                              ; preds = %128
  %135 = load i32, ptr %10, align 4, !tbaa !9
  %136 = sext i32 %135 to i64
  %137 = getelementptr inbounds [100010 x %"class.std::tuple"], ptr %6, i64 0, i64 %136
  %138 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3getILm1EJxxxEERNSt13tuple_elementIXT_ESt5tupleIJDpT0_EEE4typeERS4_(ptr noundef nonnull align 8 dereferenceable(24) %137) #6
  %139 = load i64, ptr %138, align 8, !tbaa !5
  %140 = load i32, ptr %10, align 4, !tbaa !9
  %141 = sext i32 %140 to i64
  %142 = getelementptr inbounds [100010 x i64], ptr @A, i64 0, i64 %141
  store i64 %139, ptr %142, align 8, !tbaa !5
  %143 = load i32, ptr %10, align 4, !tbaa !9
  %144 = sext i32 %143 to i64
  %145 = getelementptr inbounds [100010 x %"class.std::tuple"], ptr %6, i64 0, i64 %144
  %146 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3getILm2EJxxxEERNSt13tuple_elementIXT_ESt5tupleIJDpT0_EEE4typeERS4_(ptr noundef nonnull align 8 dereferenceable(24) %145) #6
  %147 = load i64, ptr %146, align 8, !tbaa !5
  %148 = load i32, ptr %10, align 4, !tbaa !9
  %149 = sext i32 %148 to i64
  %150 = getelementptr inbounds [100010 x i64], ptr @B, i64 0, i64 %149
  store i64 %147, ptr %150, align 8, !tbaa !5
  br label %151

151:                                              ; preds = %134
  %152 = load i32, ptr %10, align 4, !tbaa !9
  %153 = add nsw i32 %152, 1
  store i32 %153, ptr %10, align 4, !tbaa !9
  br label %128, !llvm.loop !15

154:                                              ; preds = %133
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #6
  store i64 0, ptr %11, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 32, ptr %12) #6
  call void @_ZNSt14priority_queueIxSt6vectorIxSaIxEESt7greaterIxEEC2IS2_vEEv(ptr noundef nonnull align 8 dereferenceable(25) %12)
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #6
  store i32 0, ptr %13, align 4, !tbaa !9
  br label %155

155:                                              ; preds = %193, %154
  %156 = load i32, ptr %13, align 4, !tbaa !9
  %157 = sext i32 %156 to i64
  %158 = load i64, ptr %2, align 8, !tbaa !5
  %159 = icmp slt i64 %157, %158
  br i1 %159, label %161, label %160

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

161:                                              ; preds = %155
  %162 = load i32, ptr %13, align 4, !tbaa !9
  %163 = sext i32 %162 to i64
  %164 = getelementptr inbounds [100010 x i64], ptr @B, i64 0, i64 %163
  %165 = load i64, ptr %164, align 8, !tbaa !5
  %166 = load i64, ptr %11, align 8, !tbaa !5
  %167 = add nsw i64 %166, %165
  store i64 %167, ptr %11, align 8, !tbaa !5
  %168 = load i32, ptr %13, align 4, !tbaa !9
  %169 = sext i32 %168 to i64
  %170 = getelementptr inbounds [100010 x i64], ptr @B, i64 0, i64 %169
  invoke void @_ZNSt14priority_queueIxSt6vectorIxSaIxEESt7greaterIxEE4pushERKx(ptr noundef nonnull align 8 dereferenceable(25) %12, ptr noundef nonnull align 8 dereferenceable(8) %170)
          to label %171 unwind label %184

171:                                              ; preds = %161
  br label %172

172:                                              ; preds = %183, %171
  %173 = invoke noundef i64 @_ZNKSt14priority_queueIxSt6vectorIxSaIxEESt7greaterIxEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(25) %12)
          to label %174 unwind label %184

174:                                              ; preds = %172
  %175 = load i64, ptr @Y, align 8, !tbaa !5
  %176 = icmp sgt i64 %173, %175
  br i1 %176, label %177, label %188

177:                                              ; preds = %174
  %178 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt14priority_queueIxSt6vectorIxSaIxEESt7greaterIxEE3topEv(ptr noundef nonnull align 8 dereferenceable(25) %12)
          to label %179 unwind label %184

179:                                              ; preds = %177
  %180 = load i64, ptr %178, align 8, !tbaa !5
  %181 = load i64, ptr %11, align 8, !tbaa !5
  %182 = sub nsw i64 %181, %180
  store i64 %182, ptr %11, align 8, !tbaa !5
  invoke void @_ZNSt14priority_queueIxSt6vectorIxSaIxEESt7greaterIxEE3popEv(ptr noundef nonnull align 8 dereferenceable(25) %12)
          to label %183 unwind label %184

183:                                              ; preds = %179
  br label %172, !llvm.loop !16

184:                                              ; preds = %179, %177, %172, %161
  %185 = landingpad { ptr, i32 }
          cleanup
  %186 = extractvalue { ptr, i32 } %185, 0
  store ptr %186, ptr %14, align 8
  %187 = extractvalue { ptr, i32 } %185, 1
  store i32 %187, ptr %15, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #6
  br label %286

188:                                              ; preds = %174
  %189 = load i64, ptr %11, align 8, !tbaa !5
  %190 = load i32, ptr %13, align 4, !tbaa !9
  %191 = sext i32 %190 to i64
  %192 = getelementptr inbounds [100010 x i64], ptr @silver, i64 0, i64 %191
  store i64 %189, ptr %192, align 8, !tbaa !5
  br label %193

193:                                              ; preds = %188
  %194 = load i32, ptr %13, align 4, !tbaa !9
  %195 = add nsw i32 %194, 1
  store i32 %195, ptr %13, align 4, !tbaa !9
  br label %155, !llvm.loop !17

196:                                              ; preds = %160
  store i64 0, ptr %11, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 32, ptr %16) #6
  invoke void @_ZNSt14priority_queueIxSt6vectorIxSaIxEESt7greaterIxEEC2IS2_vEEv(ptr noundef nonnull align 8 dereferenceable(25) %16)
          to label %197 unwind label %204

197:                                              ; preds = %196
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #6
  %198 = load i64, ptr %2, align 8, !tbaa !5
  %199 = sub nsw i64 %198, 1
  store i64 %199, ptr %17, align 8, !tbaa !5
  br label %200

200:                                              ; preds = %237, %197
  %201 = load i64, ptr %17, align 8, !tbaa !5
  %202 = icmp sge i64 %201, 0
  br i1 %202, label %208, label %203

203:                                              ; preds = %200
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #6
  br label %240

204:                                              ; preds = %196
  %205 = landingpad { ptr, i32 }
          cleanup
  %206 = extractvalue { ptr, i32 } %205, 0
  store ptr %206, ptr %14, align 8
  %207 = extractvalue { ptr, i32 } %205, 1
  store i32 %207, ptr %15, align 4
  br label %285

208:                                              ; preds = %200
  %209 = load i64, ptr %17, align 8, !tbaa !5
  %210 = getelementptr inbounds [100010 x i64], ptr @A, i64 0, i64 %209
  %211 = load i64, ptr %210, align 8, !tbaa !5
  %212 = load i64, ptr %11, align 8, !tbaa !5
  %213 = add nsw i64 %212, %211
  store i64 %213, ptr %11, align 8, !tbaa !5
  %214 = load i64, ptr %17, align 8, !tbaa !5
  %215 = getelementptr inbounds [100010 x i64], ptr @A, i64 0, i64 %214
  invoke void @_ZNSt14priority_queueIxSt6vectorIxSaIxEESt7greaterIxEE4pushERKx(ptr noundef nonnull align 8 dereferenceable(25) %16, ptr noundef nonnull align 8 dereferenceable(8) %215)
          to label %216 unwind label %229

216:                                              ; preds = %208
  br label %217

217:                                              ; preds = %228, %216
  %218 = invoke noundef i64 @_ZNKSt14priority_queueIxSt6vectorIxSaIxEESt7greaterIxEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(25) %16)
          to label %219 unwind label %229

219:                                              ; preds = %217
  %220 = load i64, ptr @X, align 8, !tbaa !5
  %221 = icmp sgt i64 %218, %220
  br i1 %221, label %222, label %233

222:                                              ; preds = %219
  %223 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt14priority_queueIxSt6vectorIxSaIxEESt7greaterIxEE3topEv(ptr noundef nonnull align 8 dereferenceable(25) %16)
          to label %224 unwind label %229

224:                                              ; preds = %222
  %225 = load i64, ptr %223, align 8, !tbaa !5
  %226 = load i64, ptr %11, align 8, !tbaa !5
  %227 = sub nsw i64 %226, %225
  store i64 %227, ptr %11, align 8, !tbaa !5
  invoke void @_ZNSt14priority_queueIxSt6vectorIxSaIxEESt7greaterIxEE3popEv(ptr noundef nonnull align 8 dereferenceable(25) %16)
          to label %228 unwind label %229

228:                                              ; preds = %224
  br label %217, !llvm.loop !18

229:                                              ; preds = %224, %222, %217, %208
  %230 = landingpad { ptr, i32 }
          cleanup
  %231 = extractvalue { ptr, i32 } %230, 0
  store ptr %231, ptr %14, align 8
  %232 = extractvalue { ptr, i32 } %230, 1
  store i32 %232, ptr %15, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #6
  br label %284

233:                                              ; preds = %219
  %234 = load i64, ptr %11, align 8, !tbaa !5
  %235 = load i64, ptr %17, align 8, !tbaa !5
  %236 = getelementptr inbounds [100010 x i64], ptr @gold, i64 0, i64 %235
  store i64 %234, ptr %236, align 8, !tbaa !5
  br label %237

237:                                              ; preds = %233
  %238 = load i64, ptr %17, align 8, !tbaa !5
  %239 = add nsw i64 %238, -1
  store i64 %239, ptr %17, align 8, !tbaa !5
  br label %200, !llvm.loop !19

240:                                              ; preds = %203
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #6
  store i64 -1000000000000000000, ptr %18, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %19) #6
  %241 = load i64, ptr @Y, align 8, !tbaa !5
  %242 = sub nsw i64 %241, 1
  store i64 %242, ptr %19, align 8, !tbaa !5
  br label %243

243:                                              ; preds = %263, %240
  %244 = load i64, ptr %19, align 8, !tbaa !5
  %245 = load i64, ptr @Y, align 8, !tbaa !5
  %246 = load i64, ptr @Z, align 8, !tbaa !5
  %247 = add nsw i64 %245, %246
  %248 = sub nsw i64 %247, 1
  %249 = icmp sle i64 %244, %248
  br i1 %249, label %251, label %250

250:                                              ; preds = %243
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #6
  br label %270

251:                                              ; preds = %243
  call void @llvm.lifetime.start.p0(i64 8, ptr %20) #6
  %252 = load i64, ptr %19, align 8, !tbaa !5
  %253 = add nsw i64 %252, 1
  %254 = getelementptr inbounds [100010 x i64], ptr @gold, i64 0, i64 %253
  %255 = load i64, ptr %254, align 8, !tbaa !5
  %256 = load i64, ptr %19, align 8, !tbaa !5
  %257 = getelementptr inbounds [100010 x i64], ptr @silver, i64 0, i64 %256
  %258 = load i64, ptr %257, align 8, !tbaa !5
  %259 = add nsw i64 %255, %258
  store i64 %259, ptr %20, align 8, !tbaa !5
  %260 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3maxIxERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) %18, ptr noundef nonnull align 8 dereferenceable(8) %20)
          to label %261 unwind label %266

261:                                              ; preds = %251
  %262 = load i64, ptr %260, align 8, !tbaa !5
  store i64 %262, ptr %18, align 8, !tbaa !5
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #6
  br label %263

263:                                              ; preds = %261
  %264 = load i64, ptr %19, align 8, !tbaa !5
  %265 = add nsw i64 %264, 1
  store i64 %265, ptr %19, align 8, !tbaa !5
  br label %243, !llvm.loop !20

266:                                              ; preds = %251
  %267 = landingpad { ptr, i32 }
          cleanup
  %268 = extractvalue { ptr, i32 } %267, 0
  store ptr %268, ptr %14, align 8
  %269 = extractvalue { ptr, i32 } %267, 1
  store i32 %269, ptr %15, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #6
  br label %283

270:                                              ; preds = %250
  %271 = load i64, ptr %4, align 8, !tbaa !5
  %272 = load i64, ptr %18, align 8, !tbaa !5
  %273 = add nsw i64 %271, %272
  %274 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEx(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, i64 noundef %273)
          to label %275 unwind label %279

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

277:                                              ; preds = %275
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #6
  call void @_ZNSt14priority_queueIxSt6vectorIxSaIxEESt7greaterIxEED2Ev(ptr noundef nonnull align 8 dereferenceable(25) %16) #6
  call void @llvm.lifetime.end.p0(i64 32, ptr %16) #6
  call void @_ZNSt14priority_queueIxSt6vectorIxSaIxEESt7greaterIxEED2Ev(ptr noundef nonnull align 8 dereferenceable(25) %12) #6
  call void @llvm.lifetime.end.p0(i64 32, ptr %12) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #6
  call void @llvm.lifetime.end.p0(i64 2400240, ptr %6) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %4) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %2) #6
  %278 = load i32, ptr %1, align 4
  ret i32 %278

279:                                              ; preds = %275, %270
  %280 = landingpad { ptr, i32 }
          cleanup
  %281 = extractvalue { ptr, i32 } %280, 0
  store ptr %281, ptr %14, align 8
  %282 = extractvalue { ptr, i32 } %280, 1
  store i32 %282, ptr %15, align 4
  br label %283

283:                                              ; preds = %279, %266
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #6
  br label %284

284:                                              ; preds = %283, %229
  call void @_ZNSt14priority_queueIxSt6vectorIxSaIxEESt7greaterIxEED2Ev(ptr noundef nonnull align 8 dereferenceable(25) %16) #6
  br label %285

285:                                              ; preds = %284, %204
  call void @llvm.lifetime.end.p0(i64 32, ptr %16) #6
  br label %286

286:                                              ; preds = %285, %184
  call void @_ZNSt14priority_queueIxSt6vectorIxSaIxEESt7greaterIxEED2Ev(ptr noundef nonnull align 8 dereferenceable(25) %12) #6
  call void @llvm.lifetime.end.p0(i64 32, ptr %12) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #6
  call void @llvm.lifetime.end.p0(i64 2400240, ptr %6) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %4) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %2) #6
  br label %287

287:                                              ; preds = %286
  %288 = load ptr, ptr %14, align 8
  %289 = load i32, ptr %15, 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 uwtable
declare noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 8 dereferenceable(8)) #1 align 2

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

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

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

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

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

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZSt4sortIPSt5tupleIJxxxEEEvT_S3_(ptr noundef, ptr noundef) #4

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

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

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

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

declare i32 @__gxx_personality_v0(...)

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt14priority_queueIxSt6vectorIxSaIxEESt7greaterIxEE3popEv(ptr noundef nonnull align 8 dereferenceable(25)) #1 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)) #5

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

; Function Attrs: mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSoS_E(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef) #1 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: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZNSt14priority_queueIxSt6vectorIxSaIxEESt7greaterIxEED2Ev(ptr noundef nonnull align 8 dereferenceable(25)) unnamed_addr #5 align 2

attributes #0 = { mustprogress norecurse uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { 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 #2 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #3 = { 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 #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 = { 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 #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 = !{!"long long", !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 = distinct !{!14, !12}
!15 = distinct !{!15, !12}
!16 = distinct !{!16, !12}
!17 = distinct !{!17, !12}
!18 = distinct !{!18, !12}
!19 = distinct !{!19, !12}
!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::tuple" = type { %"struct.std::_Tuple_impl" }
%"struct.std::_Tuple_impl" = type { %"struct.std::_Tuple_impl.0", %"struct.std::_Head_base.3" }
%"struct.std::_Tuple_impl.0" = type { %"struct.std::_Tuple_impl.1", %"struct.std::_Head_base.2" }
%"struct.std::_Tuple_impl.1" = type { %"struct.std::_Head_base" }
%"struct.std::_Head_base" = type { i64 }
%"struct.std::_Head_base.2" = type { i64 }
%"struct.std::_Head_base.3" = type { i64 }
%"class.std::priority_queue" = type <{ %"class.std::vector", [8 x i8] }>
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<long long, std::allocator<long long>>::_Vector_impl" }
%"struct.std::_Vector_base<long long, std::allocator<long long>>::_Vector_impl" = type { %"struct.std::_Vector_base<long long, std::allocator<long long>>::_Vector_impl_data" }
%"struct.std::_Vector_base<long long, std::allocator<long long>>::_Vector_impl_data" = type { ptr, ptr, ptr }

@X = external dso_local global i64, align 8
@Y = external dso_local global i64, align 8
@Z = external dso_local global i64, align 8
@A = external dso_local global [100010 x i64], align 16
@B = external dso_local global [100010 x i64], align 16
@C = external dso_local global [100010 x i64], align 16
@silver = external dso_local local_unnamed_addr global [100010 x i64], align 16
@gold = external dso_local local_unnamed_addr global [100010 x i64], align 16
@_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 [100010 x %"class.std::tuple"], align 16
  %2 = alloca %"class.std::tuple", align 8
  %3 = alloca i64, align 8
  %4 = alloca %"class.std::priority_queue", align 8
  %5 = alloca %"class.std::priority_queue", align 8
  %6 = alloca i64, align 8
  %7 = alloca i64, align 8
  %8 = tail call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 8 dereferenceable(8) @X)
  %9 = tail call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16) %8, ptr noundef nonnull align 8 dereferenceable(8) @Y)
  %10 = tail call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16) %9, ptr noundef nonnull align 8 dereferenceable(8) @Z)
  %11 = load i64, ptr @X, align 8, !tbaa !5
  %12 = load i64, ptr @Y, align 8, !tbaa !5
  %13 = add nsw i64 %12, %11
  %14 = load i64, ptr @Z, align 8, !tbaa !5
  %15 = add nsw i64 %13, %14
  %16 = icmp sgt i64 %15, 0
  br i1 %16, label %.lr.ph, label %._crit_edge

.preheader85:                                     ; preds = %.lr.ph
  br i1 %16, label %.lr.ph91.preheader, label %._crit_edge

.lr.ph91.preheader:                               ; preds = %.preheader85
  %min.iters.check = icmp ult i64 %15, 4
  br i1 %min.iters.check, label %.lr.ph91.preheader148, label %vector.ph

.lr.ph91.preheader148:                            ; preds = %middle.block, %.lr.ph91.preheader
  %indvars.iv118.ph = phi i64 [ 0, %.lr.ph91.preheader ], [ %n.vec, %middle.block ]
  %.06689.ph = phi i64 [ 0, %.lr.ph91.preheader ], [ %30, %middle.block ]
  br label %.lr.ph91

vector.ph:                                        ; preds = %.lr.ph91.preheader
  %n.vec = and i64 %15, 9223372036854775804
  br label %vector.body

vector.body:                                      ; preds = %vector.body, %vector.ph
  %index = phi i64 [ 0, %vector.ph ], [ %index.next, %vector.body ]
  %vec.phi = phi <2 x i64> [ zeroinitializer, %vector.ph ], [ %27, %vector.body ]
  %vec.phi140 = phi <2 x i64> [ zeroinitializer, %vector.ph ], [ %28, %vector.body ]
  %17 = getelementptr inbounds [100010 x i64], ptr @C, i64 0, i64 %index
  %18 = getelementptr inbounds i8, ptr %17, i64 16
  %wide.load = load <2 x i64>, ptr %17, align 16, !tbaa !5
  %wide.load141 = load <2 x i64>, ptr %18, align 16, !tbaa !5
  %19 = getelementptr inbounds [100010 x i64], ptr @A, i64 0, i64 %index
  %20 = getelementptr inbounds i8, ptr %19, i64 16
  %wide.load142 = load <2 x i64>, ptr %19, align 16, !tbaa !5
  %wide.load143 = load <2 x i64>, ptr %20, align 16, !tbaa !5
  %21 = sub nsw <2 x i64> %wide.load142, %wide.load
  %22 = sub nsw <2 x i64> %wide.load143, %wide.load141
  store <2 x i64> %21, ptr %19, align 16, !tbaa !5
  store <2 x i64> %22, ptr %20, align 16, !tbaa !5
  %23 = getelementptr inbounds [100010 x i64], ptr @B, i64 0, i64 %index
  %24 = getelementptr inbounds i8, ptr %23, i64 16
  %wide.load144 = load <2 x i64>, ptr %23, align 16, !tbaa !5
  %wide.load145 = load <2 x i64>, ptr %24, align 16, !tbaa !5
  %25 = sub nsw <2 x i64> %wide.load144, %wide.load
  %26 = sub nsw <2 x i64> %wide.load145, %wide.load141
  store <2 x i64> %25, ptr %23, align 16, !tbaa !5
  store <2 x i64> %26, ptr %24, align 16, !tbaa !5
  %27 = add <2 x i64> %wide.load, %vec.phi
  %28 = add <2 x i64> %wide.load141, %vec.phi140
  %index.next = add nuw i64 %index, 4
  %29 = icmp eq i64 %index.next, %n.vec
  br i1 %29, label %middle.block, label %vector.body, !llvm.loop !9

middle.block:                                     ; preds = %vector.body
  %bin.rdx = add <2 x i64> %28, %27
  %30 = tail call i64 @llvm.vector.reduce.add.v2i64(<2 x i64> %bin.rdx)
  %cmp.n = icmp eq i64 %15, %n.vec
  br i1 %cmp.n, label %._crit_edge, label %.lr.ph91.preheader148

.lr.ph:                                           ; preds = %0, %.lr.ph
  %indvars.iv = phi i64 [ %indvars.iv.next, %.lr.ph ], [ 0, %0 ]
  %31 = getelementptr inbounds [100010 x i64], ptr @A, i64 0, i64 %indvars.iv
  %32 = tail call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 8 dereferenceable(8) %31)
  %33 = getelementptr inbounds [100010 x i64], ptr @B, i64 0, i64 %indvars.iv
  %34 = tail call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16) %32, ptr noundef nonnull align 8 dereferenceable(8) %33)
  %35 = getelementptr inbounds [100010 x i64], ptr @C, i64 0, i64 %indvars.iv
  %36 = tail call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERx(ptr noundef nonnull align 8 dereferenceable(16) %34, ptr noundef nonnull align 8 dereferenceable(8) %35)
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %exitcond.not = icmp eq i64 %indvars.iv.next, %15
  br i1 %exitcond.not, label %.preheader85, label %.lr.ph, !llvm.loop !13

._crit_edge:                                      ; preds = %.lr.ph91, %middle.block, %0, %.preheader85
  %.066.lcssa = phi i64 [ 0, %.preheader85 ], [ 0, %0 ], [ %30, %middle.block ], [ %45, %.lr.ph91 ]
  call void @llvm.lifetime.start.p0(i64 2400240, ptr nonnull %1) #7
  br label %46

.lr.ph91:                                         ; preds = %.lr.ph91.preheader148, %.lr.ph91
  %indvars.iv118 = phi i64 [ %indvars.iv.next119, %.lr.ph91 ], [ %indvars.iv118.ph, %.lr.ph91.preheader148 ]
  %.06689 = phi i64 [ %45, %.lr.ph91 ], [ %.06689.ph, %.lr.ph91.preheader148 ]
  %37 = getelementptr inbounds [100010 x i64], ptr @C, i64 0, i64 %indvars.iv118
  %38 = load i64, ptr %37, align 8, !tbaa !5
  %39 = getelementptr inbounds [100010 x i64], ptr @A, i64 0, i64 %indvars.iv118
  %40 = load i64, ptr %39, align 8, !tbaa !5
  %41 = sub nsw i64 %40, %38
  store i64 %41, ptr %39, align 8, !tbaa !5
  %42 = getelementptr inbounds [100010 x i64], ptr @B, i64 0, i64 %indvars.iv118
  %43 = load i64, ptr %42, align 8, !tbaa !5
  %44 = sub nsw i64 %43, %38
  store i64 %44, ptr %42, align 8, !tbaa !5
  %45 = add nsw i64 %38, %.06689
  %indvars.iv.next119 = add nuw nsw i64 %indvars.iv118, 1
  %exitcond121.not = icmp eq i64 %indvars.iv.next119, %15
  br i1 %exitcond121.not, label %._crit_edge, label %.lr.ph91, !llvm.loop !14

46:                                               ; preds = %46, %._crit_edge
  %.idx = phi i64 [ 0, %._crit_edge ], [ %.add, %46 ]
  %.ptr = getelementptr inbounds i8, ptr %1, i64 %.idx
  call void @_ZNSt5tupleIJxxxEEC2IvTnNSt9enable_ifIXclsr4_TCCIXsr7is_voidIT_EE5valueEEE37__is_implicitly_default_constructibleEEbE4typeELb1EEEv(ptr noundef nonnull align 8 dereferenceable(24) %.ptr) #7
  %.add = add nuw nsw i64 %.idx, 24
  %47 = icmp eq i64 %.add, 2400240
  br i1 %47, label %.preheader84, label %46

.preheader84:                                     ; preds = %46
  br i1 %16, label %.lr.ph93, label %._crit_edge94.thread

._crit_edge94.thread:                             ; preds = %.preheader84
  %48 = getelementptr inbounds %"class.std::tuple", ptr %1, i64 %15
  call void @_ZSt4sortIPSt5tupleIJxxxEEEvT_S3_(ptr noundef nonnull %1, ptr noundef nonnull %48)
  br label %._crit_edge98.thread

._crit_edge94:                                    ; preds = %.lr.ph93
  %49 = getelementptr inbounds %"class.std::tuple", ptr %1, i64 %15
  call void @_ZSt4sortIPSt5tupleIJxxxEEEvT_S3_(ptr noundef nonnull %1, ptr noundef nonnull %49)
  br i1 %16, label %.lr.ph97, label %._crit_edge98.thread

.lr.ph93:                                         ; preds = %.preheader84, %.lr.ph93
  %indvars.iv122 = phi i64 [ %indvars.iv.next123, %.lr.ph93 ], [ 0, %.preheader84 ]
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %2) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %3) #7
  %50 = getelementptr inbounds [100010 x i64], ptr @A, i64 0, i64 %indvars.iv122
  %51 = load i64, ptr %50, align 8, !tbaa !5
  %52 = getelementptr inbounds [100010 x i64], ptr @B, i64 0, i64 %indvars.iv122
  %53 = load i64, ptr %52, align 8, !tbaa !5
  %54 = sub nsw i64 %51, %53
  store i64 %54, ptr %3, align 8, !tbaa !5
  call void @_ZNSt5tupleIJxxxEEC2IJxRxS2_ELb1ETnNSt9enable_ifIXclsr4_TCCIXT0_EEE29__is_implicitly_constructibleIDpT_EEEbE4typeELb1EEEDpOS4_(ptr noundef nonnull align 8 dereferenceable(24) %2, ptr noundef nonnull align 8 dereferenceable(8) %3, ptr noundef nonnull align 8 dereferenceable(8) %50, ptr noundef nonnull align 8 dereferenceable(8) %52) #7
  %55 = getelementptr inbounds [100010 x %"class.std::tuple"], ptr %1, i64 0, i64 %indvars.iv122
  %56 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt5tupleIJxxxEEaSEOS0_(ptr noundef nonnull align 8 dereferenceable(24) %55, ptr noundef nonnull align 8 dereferenceable(24) %2) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %3) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %2) #7
  %indvars.iv.next123 = add nuw nsw i64 %indvars.iv122, 1
  %exitcond125.not = icmp eq i64 %indvars.iv.next123, %15
  br i1 %exitcond125.not, label %._crit_edge94, label %.lr.ph93, !llvm.loop !15

._crit_edge98.thread:                             ; preds = %._crit_edge94.thread, %._crit_edge94
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %4) #7
  call void @_ZNSt14priority_queueIxSt6vectorIxSaIxEESt7greaterIxEEC2IS2_vEEv(ptr noundef nonnull align 8 dereferenceable(25) %4)
  br label %._crit_edge103.thread

._crit_edge98:                                    ; preds = %.lr.ph97
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %4) #7
  call void @_ZNSt14priority_queueIxSt6vectorIxSaIxEESt7greaterIxEEC2IS2_vEEv(ptr noundef nonnull align 8 dereferenceable(25) %4)
  br i1 %16, label %.lr.ph102, label %._crit_edge103.thread

.lr.ph97:                                         ; preds = %._crit_edge94, %.lr.ph97
  %indvars.iv126 = phi i64 [ %indvars.iv.next127, %.lr.ph97 ], [ 0, %._crit_edge94 ]
  %57 = getelementptr inbounds [100010 x %"class.std::tuple"], ptr %1, i64 0, i64 %indvars.iv126
  %58 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3getILm1EJxxxEERNSt13tuple_elementIXT_ESt5tupleIJDpT0_EEE4typeERS4_(ptr noundef nonnull align 8 dereferenceable(24) %57) #7
  %59 = load i64, ptr %58, align 8, !tbaa !5
  %60 = getelementptr inbounds [100010 x i64], ptr @A, i64 0, i64 %indvars.iv126
  store i64 %59, ptr %60, align 8, !tbaa !5
  %61 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3getILm2EJxxxEERNSt13tuple_elementIXT_ESt5tupleIJDpT0_EEE4typeERS4_(ptr noundef nonnull align 8 dereferenceable(24) %57) #7
  %62 = load i64, ptr %61, align 8, !tbaa !5
  %63 = getelementptr inbounds [100010 x i64], ptr @B, i64 0, i64 %indvars.iv126
  store i64 %62, ptr %63, align 8, !tbaa !5
  %indvars.iv.next127 = add nuw nsw i64 %indvars.iv126, 1
  %exitcond129.not = icmp eq i64 %indvars.iv.next127, %15
  br i1 %exitcond129.not, label %._crit_edge98, label %.lr.ph97, !llvm.loop !16

._crit_edge103.thread:                            ; preds = %._crit_edge98.thread, %._crit_edge98
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %5) #7
  call void @_ZNSt14priority_queueIxSt6vectorIxSaIxEESt7greaterIxEEC2IS2_vEEv(ptr noundef nonnull align 8 dereferenceable(25) %5)
  br label %._crit_edge109

._crit_edge103:                                   ; preds = %74
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %5) #7
  call void @_ZNSt14priority_queueIxSt6vectorIxSaIxEESt7greaterIxEEC2IS2_vEEv(ptr noundef nonnull align 8 dereferenceable(25) %5)
  br i1 %16, label %.lr.ph108, label %._crit_edge109

.lr.ph102:                                        ; preds = %._crit_edge98, %74
  %indvars.iv130 = phi i64 [ %indvars.iv.next131, %74 ], [ 0, %._crit_edge98 ]
  %.06199 = phi i64 [ %.162, %74 ], [ 0, %._crit_edge98 ]
  %64 = getelementptr inbounds [100010 x i64], ptr @B, i64 0, i64 %indvars.iv130
  %65 = load i64, ptr %64, align 8, !tbaa !5
  invoke void @_ZNSt14priority_queueIxSt6vectorIxSaIxEESt7greaterIxEE4pushERKx(ptr noundef nonnull align 8 dereferenceable(25) %4, ptr noundef nonnull align 8 dereferenceable(8) %64)
          to label %.preheader78.preheader unwind label %.loopexit.split-lp80

.preheader78.preheader:                           ; preds = %.lr.ph102
  %66 = add nsw i64 %65, %.06199
  br label %.preheader78

.preheader78:                                     ; preds = %.preheader78.preheader, %70
  %.162 = phi i64 [ %73, %70 ], [ %66, %.preheader78.preheader ]
  %67 = call noundef i64 @_ZNKSt14priority_queueIxSt6vectorIxSaIxEESt7greaterIxEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(25) %4)
  %68 = load i64, ptr @Y, align 8, !tbaa !5
  %69 = icmp sgt i64 %67, %68
  br i1 %69, label %70, label %74

70:                                               ; preds = %.preheader78
  %71 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt14priority_queueIxSt6vectorIxSaIxEESt7greaterIxEE3topEv(ptr noundef nonnull align 8 dereferenceable(25) %4)
  %72 = load i64, ptr %71, align 8, !tbaa !5
  %73 = sub nsw i64 %.162, %72
  invoke void @_ZNSt14priority_queueIxSt6vectorIxSaIxEESt7greaterIxEE3popEv(ptr noundef nonnull align 8 dereferenceable(25) %4)
          to label %.preheader78 unwind label %.loopexit79, !llvm.loop !17

.loopexit79:                                      ; preds = %70
  %lpad.loopexit81 = landingpad { ptr, i32 }
          cleanup
  br label %112

.loopexit.split-lp80:                             ; preds = %.lr.ph102
  %lpad.loopexit.split-lp82 = landingpad { ptr, i32 }
          cleanup
  br label %112

74:                                               ; preds = %.preheader78
  %75 = getelementptr inbounds [100010 x i64], ptr @silver, i64 0, i64 %indvars.iv130
  store i64 %.162, ptr %75, align 8, !tbaa !5
  %indvars.iv.next131 = add nuw nsw i64 %indvars.iv130, 1
  %exitcond133.not = icmp eq i64 %indvars.iv.next131, %15
  br i1 %exitcond133.not, label %._crit_edge103, label %.lr.ph102, !llvm.loop !18

._crit_edge109:                                   ; preds = %89, %._crit_edge103.thread, %._crit_edge103
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %6) #7
  store i64 -1000000000000000000, ptr %6, align 8, !tbaa !5
  %76 = load i64, ptr @Z, align 8, !tbaa !5
  %.not.not110 = icmp sgt i64 %76, -1
  br i1 %.not.not110, label %.lr.ph113.preheader, label %._crit_edge114

.lr.ph113.preheader:                              ; preds = %._crit_edge109
  %77 = load i64, ptr @Y, align 8, !tbaa !5
  %78 = add nsw i64 %77, -1
  br label %.lr.ph113

.lr.ph108:                                        ; preds = %._crit_edge103, %89
  %.056106.in = phi i64 [ %.056106, %89 ], [ %15, %._crit_edge103 ]
  %.2105 = phi i64 [ %.3, %89 ], [ 0, %._crit_edge103 ]
  %.056106 = add nsw i64 %.056106.in, -1
  %79 = getelementptr inbounds [100010 x i64], ptr @A, i64 0, i64 %.056106
  %80 = load i64, ptr %79, align 8, !tbaa !5
  invoke void @_ZNSt14priority_queueIxSt6vectorIxSaIxEESt7greaterIxEE4pushERKx(ptr noundef nonnull align 8 dereferenceable(25) %5, ptr noundef nonnull align 8 dereferenceable(8) %79)
          to label %.preheader.preheader unwind label %.loopexit.split-lp

.preheader.preheader:                             ; preds = %.lr.ph108
  %81 = add nsw i64 %80, %.2105
  br label %.preheader

.preheader:                                       ; preds = %.preheader.preheader, %85
  %.3 = phi i64 [ %88, %85 ], [ %81, %.preheader.preheader ]
  %82 = call noundef i64 @_ZNKSt14priority_queueIxSt6vectorIxSaIxEESt7greaterIxEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(25) %5)
  %83 = load i64, ptr @X, align 8, !tbaa !5
  %84 = icmp sgt i64 %82, %83
  br i1 %84, label %85, label %89

85:                                               ; preds = %.preheader
  %86 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt14priority_queueIxSt6vectorIxSaIxEESt7greaterIxEE3topEv(ptr noundef nonnull align 8 dereferenceable(25) %5)
  %87 = load i64, ptr %86, align 8, !tbaa !5
  %88 = sub nsw i64 %.3, %87
  invoke void @_ZNSt14priority_queueIxSt6vectorIxSaIxEESt7greaterIxEE3popEv(ptr noundef nonnull align 8 dereferenceable(25) %5)
          to label %.preheader unwind label %.loopexit, !llvm.loop !19

.loopexit:                                        ; preds = %85
  %lpad.loopexit = landingpad { ptr, i32 }
          cleanup
  br label %111

.loopexit.split-lp:                               ; preds = %.lr.ph108
  %lpad.loopexit.split-lp = landingpad { ptr, i32 }
          cleanup
  br label %111

89:                                               ; preds = %.preheader
  %90 = getelementptr inbounds [100010 x i64], ptr @gold, i64 0, i64 %.056106
  store i64 %.3, ptr %90, align 8, !tbaa !5
  %91 = icmp sgt i64 %.056106.in, 1
  br i1 %91, label %.lr.ph108, label %._crit_edge109, !llvm.loop !20

._crit_edge114:                                   ; preds = %.lr.ph113, %._crit_edge109
  %92 = phi i64 [ -1000000000000000000, %._crit_edge109 ], [ %102, %.lr.ph113 ]
  %93 = add nsw i64 %92, %.066.lcssa
  %94 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEx(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, i64 noundef %93)
          to label %106 unwind label %109

.lr.ph113:                                        ; preds = %.lr.ph113.preheader, %.lr.ph113
  %.0111 = phi i64 [ %95, %.lr.ph113 ], [ %78, %.lr.ph113.preheader ]
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %7) #7
  %95 = add nsw i64 %.0111, 1
  %96 = getelementptr inbounds [100010 x i64], ptr @gold, i64 0, i64 %95
  %97 = load i64, ptr %96, align 8, !tbaa !5
  %98 = getelementptr inbounds [100010 x i64], ptr @silver, i64 0, i64 %.0111
  %99 = load i64, ptr %98, align 8, !tbaa !5
  %100 = add nsw i64 %99, %97
  store i64 %100, ptr %7, align 8, !tbaa !5
  %101 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3maxIxERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) %6, ptr noundef nonnull align 8 dereferenceable(8) %7)
  %102 = load i64, ptr %101, align 8, !tbaa !5
  store i64 %102, ptr %6, align 8, !tbaa !5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #7
  %103 = load i64, ptr @Y, align 8, !tbaa !5
  %104 = load i64, ptr @Z, align 8, !tbaa !5
  %105 = add nsw i64 %104, %103
  %.not.not = icmp slt i64 %95, %105
  br i1 %.not.not, label %.lr.ph113, label %._crit_edge114, !llvm.loop !21

106:                                              ; preds = %._crit_edge114
  %107 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSoS_E(ptr noundef nonnull align 8 dereferenceable(8) %94, ptr noundef nonnull @_ZSt4endlIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_)
          to label %108 unwind label %109

108:                                              ; preds = %106
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #7
  call void @_ZNSt14priority_queueIxSt6vectorIxSaIxEESt7greaterIxEED2Ev(ptr noundef nonnull align 8 dereferenceable(25) %5) #7
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %5) #7
  call void @_ZNSt14priority_queueIxSt6vectorIxSaIxEESt7greaterIxEED2Ev(ptr noundef nonnull align 8 dereferenceable(25) %4) #7
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %4) #7
  call void @llvm.lifetime.end.p0(i64 2400240, ptr nonnull %1) #7
  ret i32 0

109:                                              ; preds = %106, %._crit_edge114
  %110 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #7
  br label %111

111:                                              ; preds = %.loopexit, %.loopexit.split-lp, %109
  %.pn = phi { ptr, i32 } [ %110, %109 ], [ %lpad.loopexit, %.loopexit ], [ %lpad.loopexit.split-lp, %.loopexit.split-lp ]
  call void @_ZNSt14priority_queueIxSt6vectorIxSaIxEESt7greaterIxEED2Ev(ptr noundef nonnull align 8 dereferenceable(25) %5) #7
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %5) #7
  br label %112

112:                                              ; preds = %.loopexit79, %.loopexit.split-lp80, %111
  %.pn76 = phi { ptr, i32 } [ %.pn, %111 ], [ %lpad.loopexit81, %.loopexit79 ], [ %lpad.loopexit.split-lp82, %.loopexit.split-lp80 ]
  call void @_ZNSt14priority_queueIxSt6vectorIxSaIxEESt7greaterIxEED2Ev(ptr noundef nonnull align 8 dereferenceable(25) %4) #7
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %4) #7
  call void @llvm.lifetime.end.p0(i64 2400240, ptr nonnull %1) #7
  resume { ptr, i32 } %.pn76
}

; 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 #1 align 2

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

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

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

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

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

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZSt4sortIPSt5tupleIJxxxEEEvT_S3_(ptr noundef, ptr noundef) local_unnamed_addr #4

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

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt14priority_queueIxSt6vectorIxSaIxEESt7greaterIxEE4pushERKx(ptr noundef nonnull align 8 dereferenceable(25), ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #1 align 2

declare i32 @__gxx_personality_v0(...)

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt14priority_queueIxSt6vectorIxSaIxEESt7greaterIxEE3popEv(ptr noundef nonnull align 8 dereferenceable(25)) local_unnamed_addr #1 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 #5

; 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 #1 align 2

; 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 #1 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: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZNSt14priority_queueIxSt6vectorIxSaIxEESt7greaterIxEED2Ev(ptr noundef nonnull align 8 dereferenceable(25)) unnamed_addr #5 align 2

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i64 @llvm.vector.reduce.add.v2i64(<2 x i64>) #6

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 = { 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 #2 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #3 = { 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 #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 = { 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 #6 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
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 = !{!"long long", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = distinct !{!9, !10, !11, !12}
!10 = !{!"llvm.loop.mustprogress"}
!11 = !{!"llvm.loop.isvectorized", i32 1}
!12 = !{!"llvm.loop.unroll.runtime.disable"}
!13 = distinct !{!13, !10}
!14 = distinct !{!14, !10, !12, !11}
!15 = distinct !{!15, !10}
!16 = distinct !{!16, !10}
!17 = distinct !{!17, !10}
!18 = distinct !{!18, !10}
!19 = distinct !{!19, !10}
!20 = distinct !{!20, !10}
!21 = distinct !{!21, !10}


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