; LLVM IR from DionysiosB/CodeForces :: 1300-1399 (1374E1-ReadingBooksEasyVersion)

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

@.str = external hidden unnamed_addr constant [8 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [12 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [5 x i8], align 1

; 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 %"class.std::vector", align 8
  %5 = alloca %"class.std::vector", align 8
  %6 = alloca %"class.std::vector", align 8
  %7 = alloca i64, align 8
  %8 = alloca i64, align 8
  %9 = alloca i64, align 8
  %10 = alloca i64, align 8
  %11 = alloca ptr, align 8
  %12 = alloca i32, align 4
  %13 = alloca i32, align 4
  %14 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %15 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %16 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %17 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %18 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %19 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %20 = alloca i64, align 8
  %21 = alloca i64, align 8
  %22 = alloca i64, align 8
  %23 = alloca i64, align 8
  %24 = alloca i64, align 8
  %25 = alloca i64, align 8
  %26 = alloca i64, align 8
  store i32 0, ptr %1, align 4
  call void @llvm.lifetime.start.p0(i64 8, ptr %2) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr %3) #6
  %27 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef %2, ptr noundef %3)
  call void @llvm.lifetime.start.p0(i64 24, ptr %4) #6
  call void @_ZNSt6vectorIlSaIlEEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %4) #6
  call void @llvm.lifetime.start.p0(i64 24, ptr %5) #6
  call void @_ZNSt6vectorIlSaIlEEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %5) #6
  call void @llvm.lifetime.start.p0(i64 24, ptr %6) #6
  call void @_ZNSt6vectorIlSaIlEEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %6) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr %7) #6
  store i64 0, ptr %7, align 8, !tbaa !5
  br label %28

28:                                               ; preds = %60, %0
  %29 = load i64, ptr %7, align 8, !tbaa !5
  %30 = load i64, ptr %2, align 8, !tbaa !5
  %31 = icmp slt i64 %29, %30
  br i1 %31, label %33, label %32

32:                                               ; preds = %28
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #6
  br label %63

33:                                               ; preds = %28
  call void @llvm.lifetime.start.p0(i64 8, ptr %8) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr %9) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #6
  %34 = invoke i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str.1, ptr noundef %8, ptr noundef %9, ptr noundef %10)
          to label %35 unwind label %43

35:                                               ; preds = %33
  %36 = load i64, ptr %9, align 8, !tbaa !5
  %37 = icmp ne i64 %36, 0
  br i1 %37, label %38, label %47

38:                                               ; preds = %35
  %39 = load i64, ptr %10, align 8, !tbaa !5
  %40 = icmp ne i64 %39, 0
  br i1 %40, label %41, label %47

41:                                               ; preds = %38
  invoke void @_ZNSt6vectorIlSaIlEE9push_backERKl(ptr noundef nonnull align 8 dereferenceable(24) %6, ptr noundef nonnull align 8 dereferenceable(8) %8)
          to label %42 unwind label %43

42:                                               ; preds = %41
  br label %59

43:                                               ; preds = %55, %50, %41, %33
  %44 = landingpad { ptr, i32 }
          cleanup
  %45 = extractvalue { ptr, i32 } %44, 0
  store ptr %45, ptr %11, align 8
  %46 = extractvalue { ptr, i32 } %44, 1
  store i32 %46, ptr %12, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #6
  br label %237

47:                                               ; preds = %38, %35
  %48 = load i64, ptr %9, align 8, !tbaa !5
  %49 = icmp ne i64 %48, 0
  br i1 %49, label %50, label %52

50:                                               ; preds = %47
  invoke void @_ZNSt6vectorIlSaIlEE9push_backERKl(ptr noundef nonnull align 8 dereferenceable(24) %4, ptr noundef nonnull align 8 dereferenceable(8) %8)
          to label %51 unwind label %43

51:                                               ; preds = %50
  br label %58

52:                                               ; preds = %47
  %53 = load i64, ptr %10, align 8, !tbaa !5
  %54 = icmp ne i64 %53, 0
  br i1 %54, label %55, label %57

55:                                               ; preds = %52
  invoke void @_ZNSt6vectorIlSaIlEE9push_backERKl(ptr noundef nonnull align 8 dereferenceable(24) %5, ptr noundef nonnull align 8 dereferenceable(8) %8)
          to label %56 unwind label %43

56:                                               ; preds = %55
  br label %57

57:                                               ; preds = %56, %52
  br label %58

58:                                               ; preds = %57, %51
  br label %59

59:                                               ; preds = %58, %42
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #6
  br label %60

60:                                               ; preds = %59
  %61 = load i64, ptr %7, align 8, !tbaa !5
  %62 = add nsw i64 %61, 1
  store i64 %62, ptr %7, align 8, !tbaa !5
  br label %28, !llvm.loop !9

63:                                               ; preds = %32
  %64 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %4) #6
  %65 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %6) #6
  %66 = add i64 %64, %65
  %67 = load i64, ptr %3, align 8, !tbaa !5
  %68 = icmp ult i64 %66, %67
  br i1 %68, label %75, label %69

69:                                               ; preds = %63
  %70 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %5) #6
  %71 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %6) #6
  %72 = add i64 %70, %71
  %73 = load i64, ptr %3, align 8, !tbaa !5
  %74 = icmp ult i64 %72, %73
  br i1 %74, label %75, label %82

75:                                               ; preds = %69, %63
  %76 = invoke i32 @puts(ptr noundef @.str.2)
          to label %77 unwind label %78

77:                                               ; preds = %75
  store i32 0, ptr %1, align 4
  store i32 1, ptr %13, align 4
  br label %235

78:                                               ; preds = %100, %91, %82, %75
  %79 = landingpad { ptr, i32 }
          cleanup
  %80 = extractvalue { ptr, i32 } %79, 0
  store ptr %80, ptr %11, align 8
  %81 = extractvalue { ptr, i32 } %79, 1
  store i32 %81, ptr %12, align 4
  br label %237

82:                                               ; preds = %69
  %83 = call ptr @_ZNSt6vectorIlSaIlEE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %4) #6
  %84 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %14, i32 0, i32 0
  store ptr %83, ptr %84, align 8
  %85 = call ptr @_ZNSt6vectorIlSaIlEE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %4) #6
  %86 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %15, i32 0, i32 0
  store ptr %85, ptr %86, align 8
  %87 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %14, i32 0, i32 0
  %88 = load ptr, ptr %87, align 8
  %89 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %15, i32 0, i32 0
  %90 = load ptr, ptr %89, align 8
  invoke void @_ZSt4sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEEEvT_S7_(ptr %88, ptr %90)
          to label %91 unwind label %78

91:                                               ; preds = %82
  %92 = call ptr @_ZNSt6vectorIlSaIlEE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %5) #6
  %93 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %16, i32 0, i32 0
  store ptr %92, ptr %93, align 8
  %94 = call ptr @_ZNSt6vectorIlSaIlEE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %5) #6
  %95 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %17, i32 0, i32 0
  store ptr %94, ptr %95, align 8
  %96 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %16, i32 0, i32 0
  %97 = load ptr, ptr %96, align 8
  %98 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %17, i32 0, i32 0
  %99 = load ptr, ptr %98, align 8
  invoke void @_ZSt4sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEEEvT_S7_(ptr %97, ptr %99)
          to label %100 unwind label %78

100:                                              ; preds = %91
  %101 = call ptr @_ZNSt6vectorIlSaIlEE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %6) #6
  %102 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %18, i32 0, i32 0
  store ptr %101, ptr %102, align 8
  %103 = call ptr @_ZNSt6vectorIlSaIlEE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %6) #6
  %104 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %19, i32 0, i32 0
  store ptr %103, ptr %104, align 8
  %105 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %18, i32 0, i32 0
  %106 = load ptr, ptr %105, align 8
  %107 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %19, i32 0, i32 0
  %108 = load ptr, ptr %107, align 8
  invoke void @_ZSt4sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEEEvT_S7_(ptr %106, ptr %108)
          to label %109 unwind label %78

109:                                              ; preds = %100
  call void @llvm.lifetime.start.p0(i64 8, ptr %20) #6
  store i64 1, ptr %20, align 8, !tbaa !5
  br label %110

110:                                              ; preds = %124, %109
  %111 = load i64, ptr %20, align 8, !tbaa !5
  %112 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %4) #6
  %113 = icmp ult i64 %111, %112
  br i1 %113, label %115, label %114

114:                                              ; preds = %110
  store i32 5, ptr %13, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #6
  br label %127

115:                                              ; preds = %110
  %116 = load i64, ptr %20, align 8, !tbaa !5
  %117 = sub nsw i64 %116, 1
  %118 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %4, i64 noundef %117) #6
  %119 = load i64, ptr %118, align 8, !tbaa !5
  %120 = load i64, ptr %20, align 8, !tbaa !5
  %121 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %4, i64 noundef %120) #6
  %122 = load i64, ptr %121, align 8, !tbaa !5
  %123 = add nsw i64 %122, %119
  store i64 %123, ptr %121, align 8, !tbaa !5
  br label %124

124:                                              ; preds = %115
  %125 = load i64, ptr %20, align 8, !tbaa !5
  %126 = add nsw i64 %125, 1
  store i64 %126, ptr %20, align 8, !tbaa !5
  br label %110, !llvm.loop !11

127:                                              ; preds = %114
  call void @llvm.lifetime.start.p0(i64 8, ptr %21) #6
  store i64 1, ptr %21, align 8, !tbaa !5
  br label %128

128:                                              ; preds = %142, %127
  %129 = load i64, ptr %21, align 8, !tbaa !5
  %130 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %5) #6
  %131 = icmp ult i64 %129, %130
  br i1 %131, label %133, label %132

132:                                              ; preds = %128
  store i32 8, ptr %13, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #6
  br label %145

133:                                              ; preds = %128
  %134 = load i64, ptr %21, align 8, !tbaa !5
  %135 = sub nsw i64 %134, 1
  %136 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %5, i64 noundef %135) #6
  %137 = load i64, ptr %136, align 8, !tbaa !5
  %138 = load i64, ptr %21, align 8, !tbaa !5
  %139 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %5, i64 noundef %138) #6
  %140 = load i64, ptr %139, align 8, !tbaa !5
  %141 = add nsw i64 %140, %137
  store i64 %141, ptr %139, align 8, !tbaa !5
  br label %142

142:                                              ; preds = %133
  %143 = load i64, ptr %21, align 8, !tbaa !5
  %144 = add nsw i64 %143, 1
  store i64 %144, ptr %21, align 8, !tbaa !5
  br label %128, !llvm.loop !12

145:                                              ; preds = %132
  call void @llvm.lifetime.start.p0(i64 8, ptr %22) #6
  store i64 1, ptr %22, align 8, !tbaa !5
  br label %146

146:                                              ; preds = %160, %145
  %147 = load i64, ptr %22, align 8, !tbaa !5
  %148 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %6) #6
  %149 = icmp ult i64 %147, %148
  br i1 %149, label %151, label %150

150:                                              ; preds = %146
  store i32 11, ptr %13, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #6
  br label %163

151:                                              ; preds = %146
  %152 = load i64, ptr %22, align 8, !tbaa !5
  %153 = sub nsw i64 %152, 1
  %154 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %6, i64 noundef %153) #6
  %155 = load i64, ptr %154, align 8, !tbaa !5
  %156 = load i64, ptr %22, align 8, !tbaa !5
  %157 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %6, i64 noundef %156) #6
  %158 = load i64, ptr %157, align 8, !tbaa !5
  %159 = add nsw i64 %158, %155
  store i64 %159, ptr %157, align 8, !tbaa !5
  br label %160

160:                                              ; preds = %151
  %161 = load i64, ptr %22, align 8, !tbaa !5
  %162 = add nsw i64 %161, 1
  store i64 %162, ptr %22, align 8, !tbaa !5
  br label %146, !llvm.loop !13

163:                                              ; preds = %150
  call void @llvm.lifetime.start.p0(i64 8, ptr %23) #6
  store i64 2000000007, ptr %23, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %24) #6
  store i64 0, ptr %24, align 8, !tbaa !5
  br label %164

164:                                              ; preds = %224, %163
  %165 = load i64, ptr %24, align 8, !tbaa !5
  %166 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %6) #6
  %167 = icmp ule i64 %165, %166
  br i1 %167, label %168, label %172

168:                                              ; preds = %164
  %169 = load i64, ptr %24, align 8, !tbaa !5
  %170 = load i64, ptr %3, align 8, !tbaa !5
  %171 = icmp sle i64 %169, %170
  br label %172

172:                                              ; preds = %168, %164
  %173 = phi i1 [ false, %164 ], [ %171, %168 ]
  br i1 %173, label %175, label %174

174:                                              ; preds = %172
  store i32 14, ptr %13, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %24) #6
  br label %227

175:                                              ; preds = %172
  call void @llvm.lifetime.start.p0(i64 8, ptr %25) #6
  %176 = load i64, ptr %24, align 8, !tbaa !5
  %177 = icmp sgt i64 %176, 0
  br i1 %177, label %178, label %183

178:                                              ; preds = %175
  %179 = load i64, ptr %24, align 8, !tbaa !5
  %180 = sub nsw i64 %179, 1
  %181 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %6, i64 noundef %180) #6
  %182 = load i64, ptr %181, align 8, !tbaa !5
  br label %184

183:                                              ; preds = %175
  br label %184

184:                                              ; preds = %183, %178
  %185 = phi i64 [ %182, %178 ], [ 0, %183 ]
  store i64 %185, ptr %25, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %26) #6
  %186 = load i64, ptr %3, align 8, !tbaa !5
  %187 = load i64, ptr %24, align 8, !tbaa !5
  %188 = sub nsw i64 %186, %187
  store i64 %188, ptr %26, align 8, !tbaa !5
  %189 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %4) #6
  %190 = load i64, ptr %26, align 8, !tbaa !5
  %191 = icmp uge i64 %189, %190
  br i1 %191, label %192, label %223

192:                                              ; preds = %184
  %193 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %5) #6
  %194 = load i64, ptr %26, align 8, !tbaa !5
  %195 = icmp uge i64 %193, %194
  br i1 %195, label %196, label %223

196:                                              ; preds = %192
  %197 = load i64, ptr %26, align 8, !tbaa !5
  %198 = icmp sgt i64 %197, 0
  br i1 %198, label %199, label %209

199:                                              ; preds = %196
  %200 = load i64, ptr %26, align 8, !tbaa !5
  %201 = sub nsw i64 %200, 1
  %202 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %4, i64 noundef %201) #6
  %203 = load i64, ptr %202, align 8, !tbaa !5
  %204 = load i64, ptr %26, align 8, !tbaa !5
  %205 = sub nsw i64 %204, 1
  %206 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %5, i64 noundef %205) #6
  %207 = load i64, ptr %206, align 8, !tbaa !5
  %208 = add nsw i64 %203, %207
  br label %210

209:                                              ; preds = %196
  br label %210

210:                                              ; preds = %209, %199
  %211 = phi i64 [ %208, %199 ], [ 0, %209 ]
  %212 = load i64, ptr %25, align 8, !tbaa !5
  %213 = add nsw i64 %212, %211
  store i64 %213, ptr %25, align 8, !tbaa !5
  %214 = load i64, ptr %23, align 8, !tbaa !5
  %215 = load i64, ptr %25, align 8, !tbaa !5
  %216 = icmp slt i64 %214, %215
  br i1 %216, label %217, label %219

217:                                              ; preds = %210
  %218 = load i64, ptr %23, align 8, !tbaa !5
  br label %221

219:                                              ; preds = %210
  %220 = load i64, ptr %25, align 8, !tbaa !5
  br label %221

221:                                              ; preds = %219, %217
  %222 = phi i64 [ %218, %217 ], [ %220, %219 ]
  store i64 %222, ptr %23, align 8, !tbaa !5
  br label %223

223:                                              ; preds = %221, %192, %184
  call void @llvm.lifetime.end.p0(i64 8, ptr %26) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %25) #6
  br label %224

224:                                              ; preds = %223
  %225 = load i64, ptr %24, align 8, !tbaa !5
  %226 = add nsw i64 %225, 1
  store i64 %226, ptr %24, align 8, !tbaa !5
  br label %164, !llvm.loop !14

227:                                              ; preds = %174
  %228 = load i64, ptr %23, align 8, !tbaa !5
  %229 = invoke i32 (ptr, ...) @printf(ptr noundef @.str.3, i64 noundef %228)
          to label %230 unwind label %231

230:                                              ; preds = %227
  store i32 0, ptr %1, align 4
  store i32 1, ptr %13, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %23) #6
  br label %235

231:                                              ; preds = %227
  %232 = landingpad { ptr, i32 }
          cleanup
  %233 = extractvalue { ptr, i32 } %232, 0
  store ptr %233, ptr %11, align 8
  %234 = extractvalue { ptr, i32 } %232, 1
  store i32 %234, ptr %12, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %23) #6
  br label %237

235:                                              ; preds = %230, %77
  call void @_ZNSt6vectorIlSaIlEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %6) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr %6) #6
  call void @_ZNSt6vectorIlSaIlEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %5) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr %5) #6
  call void @_ZNSt6vectorIlSaIlEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %4) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr %4) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %3) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %2) #6
  %236 = load i32, ptr %1, align 4
  ret i32 %236

237:                                              ; preds = %231, %78, %43
  call void @_ZNSt6vectorIlSaIlEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %6) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr %6) #6
  call void @_ZNSt6vectorIlSaIlEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %5) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr %5) #6
  call void @_ZNSt6vectorIlSaIlEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %4) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr %4) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %3) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %2) #6
  br label %238

238:                                              ; preds = %237
  %239 = load ptr, ptr %11, align 8
  %240 = load i32, ptr %12, align 4
  %241 = insertvalue { ptr, i32 } poison, ptr %239, 0
  %242 = insertvalue { ptr, i32 } %241, i32 %240, 1
  resume { ptr, i32 } %242
}

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

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

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

declare i32 @__gxx_personality_v0(...)

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

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

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

declare i32 @puts(ptr noundef) #2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZSt4sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEEEvT_S7_(ptr, ptr) #5

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

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

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

declare i32 @printf(ptr noundef, ...) #2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt6vectorIlSaIlEED2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #3 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 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { "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 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 = { 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 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", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = distinct !{!9, !10}
!10 = !{!"llvm.loop.mustprogress"}
!11 = distinct !{!11, !10}
!12 = distinct !{!12, !10}
!13 = distinct !{!13, !10}
!14 = distinct !{!14, !10}


; 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::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<long, std::allocator<long>>::_Vector_impl" }
%"struct.std::_Vector_base<long, std::allocator<long>>::_Vector_impl" = type { %"struct.std::_Vector_base<long, std::allocator<long>>::_Vector_impl_data" }
%"struct.std::_Vector_base<long, std::allocator<long>>::_Vector_impl_data" = type { ptr, ptr, ptr }

@.str = external hidden unnamed_addr constant [8 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [12 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [5 x i8], align 1

; 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 %"class.std::vector", align 8
  %4 = alloca %"class.std::vector", align 8
  %5 = alloca %"class.std::vector", align 8
  %6 = alloca i64, align 8
  %7 = alloca i64, align 8
  %8 = alloca i64, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %1) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %2) #7
  %9 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull %1, ptr noundef nonnull %2)
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %3) #7
  call void @_ZNSt6vectorIlSaIlEEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %3) #7
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %4) #7
  call void @_ZNSt6vectorIlSaIlEEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %4) #7
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %5) #7
  call void @_ZNSt6vectorIlSaIlEEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %5) #7
  %10 = load i64, ptr %1, align 8, !tbaa !5
  %11 = icmp sgt i64 %10, 0
  br i1 %11, label %.lr.ph, label %._crit_edge

._crit_edge:                                      ; preds = %24, %0
  %12 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %3) #7
  %13 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %5) #7
  %14 = add i64 %13, %12
  %15 = load i64, ptr %2, align 8, !tbaa !5
  %16 = icmp ult i64 %14, %15
  br i1 %16, label %34, label %28

.lr.ph:                                           ; preds = %0, %24
  %.04453 = phi i64 [ %25, %24 ], [ 0, %0 ]
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %6) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %7) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %8) #7
  %17 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str.1, ptr noundef nonnull %6, ptr noundef nonnull %7, ptr noundef nonnull %8)
  %18 = load i64, ptr %7, align 8, !tbaa !5
  %19 = icmp ne i64 %18, 0
  %20 = load i64, ptr %8, align 8
  %21 = icmp ne i64 %20, 0
  %brmerge65 = select i1 %19, i1 true, i1 %21
  br i1 %brmerge65, label %.invoke, label %24

22:                                               ; preds = %.invoke
  %23 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #7
  br label %132

.invoke:                                          ; preds = %.lr.ph
  %or.cond = select i1 %19, i1 %21, i1 false
  %.mux = select i1 %or.cond, ptr %5, ptr %3
  %.mux.mux = select i1 %19, ptr %.mux, ptr %4
  invoke void @_ZNSt6vectorIlSaIlEE9push_backERKl(ptr noundef nonnull align 8 dereferenceable(24) %.mux.mux, ptr noundef nonnull align 8 dereferenceable(8) %6)
          to label %24 unwind label %22

24:                                               ; preds = %.lr.ph, %.invoke
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #7
  %25 = add nuw nsw i64 %.04453, 1
  %26 = load i64, ptr %1, align 8, !tbaa !5
  %27 = icmp slt i64 %25, %26
  br i1 %27, label %.lr.ph, label %._crit_edge, !llvm.loop !9

28:                                               ; preds = %._crit_edge
  %29 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %4) #7
  %30 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %5) #7
  %31 = add i64 %30, %29
  %32 = load i64, ptr %2, align 8, !tbaa !5
  %33 = icmp ult i64 %31, %32
  br i1 %33, label %34, label %38

34:                                               ; preds = %28, %._crit_edge
  %35 = call i32 @puts(ptr noundef nonnull dereferenceable(1) @.str.2)
  br label %131

36:                                               ; preds = %44, %41, %38
  %37 = landingpad { ptr, i32 }
          cleanup
  br label %132

38:                                               ; preds = %28
  %39 = call ptr @_ZNSt6vectorIlSaIlEE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %3) #7
  %40 = call ptr @_ZNSt6vectorIlSaIlEE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %3) #7
  invoke void @_ZSt4sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEEEvT_S7_(ptr %39, ptr %40)
          to label %41 unwind label %36

41:                                               ; preds = %38
  %42 = call ptr @_ZNSt6vectorIlSaIlEE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %4) #7
  %43 = call ptr @_ZNSt6vectorIlSaIlEE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %4) #7
  invoke void @_ZSt4sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEEEvT_S7_(ptr %42, ptr %43)
          to label %44 unwind label %36

44:                                               ; preds = %41
  %45 = call ptr @_ZNSt6vectorIlSaIlEE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %5) #7
  %46 = call ptr @_ZNSt6vectorIlSaIlEE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %5) #7
  invoke void @_ZSt4sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEEEvT_S7_(ptr %45, ptr %46)
          to label %.preheader52 unwind label %36

.preheader52:                                     ; preds = %44
  %47 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %3) #7
  %48 = icmp ugt i64 %47, 1
  br i1 %48, label %.lr.ph55, label %.preheader51

.preheader51:                                     ; preds = %.lr.ph55, %.preheader52
  %49 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %4) #7
  %50 = icmp ugt i64 %49, 1
  br i1 %50, label %.lr.ph57, label %.preheader50

.lr.ph55:                                         ; preds = %.preheader52, %.lr.ph55
  %.04354 = phi i64 [ %57, %.lr.ph55 ], [ 1, %.preheader52 ]
  %51 = add nsw i64 %.04354, -1
  %52 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %3, i64 noundef %51) #7
  %53 = load i64, ptr %52, align 8, !tbaa !5
  %54 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %3, i64 noundef %.04354) #7
  %55 = load i64, ptr %54, align 8, !tbaa !5
  %56 = add nsw i64 %55, %53
  store i64 %56, ptr %54, align 8, !tbaa !5
  %57 = add nuw nsw i64 %.04354, 1
  %58 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %3) #7
  %59 = icmp ult i64 %57, %58
  br i1 %59, label %.lr.ph55, label %.preheader51, !llvm.loop !11

.preheader50:                                     ; preds = %.lr.ph57, %.preheader51
  %60 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %5) #7
  %61 = icmp ugt i64 %60, 1
  br i1 %61, label %.lr.ph59, label %.preheader

.lr.ph57:                                         ; preds = %.preheader51, %.lr.ph57
  %.04256 = phi i64 [ %68, %.lr.ph57 ], [ 1, %.preheader51 ]
  %62 = add nsw i64 %.04256, -1
  %63 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %4, i64 noundef %62) #7
  %64 = load i64, ptr %63, align 8, !tbaa !5
  %65 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %4, i64 noundef %.04256) #7
  %66 = load i64, ptr %65, align 8, !tbaa !5
  %67 = add nsw i64 %66, %64
  store i64 %67, ptr %65, align 8, !tbaa !5
  %68 = add nuw nsw i64 %.04256, 1
  %69 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %4) #7
  %70 = icmp ult i64 %68, %69
  br i1 %70, label %.lr.ph57, label %.preheader50, !llvm.loop !12

.preheader:                                       ; preds = %.lr.ph59, %.preheader50
  %71 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %5) #7
  %72 = load i64, ptr %2, align 8
  %73 = icmp sgt i64 %72, -1
  br i1 %73, label %.lr.ph62.preheader, label %._crit_edge63

.lr.ph62.preheader:                               ; preds = %.preheader
  %74 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %3) #7
  %.not47.peel = icmp ult i64 %74, %72
  br i1 %.not47.peel, label %88, label %75

75:                                               ; preds = %.lr.ph62.preheader
  %76 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %4) #7
  %.not48.peel = icmp ult i64 %76, %72
  br i1 %.not48.peel, label %88, label %77

77:                                               ; preds = %75
  %.not = icmp eq i64 %72, 0
  br i1 %.not, label %85, label %78

78:                                               ; preds = %77
  %79 = add nsw i64 %72, -1
  %80 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %3, i64 noundef %79) #7
  %81 = load i64, ptr %80, align 8, !tbaa !5
  %82 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %4, i64 noundef %79) #7
  %83 = load i64, ptr %82, align 8, !tbaa !5
  %84 = add nsw i64 %83, %81
  br label %85

85:                                               ; preds = %78, %77
  %86 = phi i64 [ %84, %78 ], [ 0, %77 ]
  %87 = call i64 @llvm.smin.i64(i64 %86, i64 2000000007)
  br label %88

88:                                               ; preds = %85, %75, %.lr.ph62.preheader
  %.1.peel = phi i64 [ %87, %85 ], [ 2000000007, %75 ], [ 2000000007, %.lr.ph62.preheader ]
  %89 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %5) #7
  %90 = icmp ne i64 %89, 0
  %91 = load i64, ptr %2, align 8
  %92 = icmp sgt i64 %91, 0
  %93 = select i1 %90, i1 %92, i1 false
  br i1 %93, label %.lr.ph62.peel.next, label %._crit_edge63

.lr.ph59:                                         ; preds = %.preheader50, %.lr.ph59
  %.04158 = phi i64 [ %100, %.lr.ph59 ], [ 1, %.preheader50 ]
  %94 = add nsw i64 %.04158, -1
  %95 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %5, i64 noundef %94) #7
  %96 = load i64, ptr %95, align 8, !tbaa !5
  %97 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %5, i64 noundef %.04158) #7
  %98 = load i64, ptr %97, align 8, !tbaa !5
  %99 = add nsw i64 %98, %96
  store i64 %99, ptr %97, align 8, !tbaa !5
  %100 = add nuw nsw i64 %.04158, 1
  %101 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %5) #7
  %102 = icmp ult i64 %100, %101
  br i1 %102, label %.lr.ph59, label %.preheader, !llvm.loop !13

._crit_edge63:                                    ; preds = %124, %88, %.preheader
  %.040.lcssa = phi i64 [ 2000000007, %.preheader ], [ %.1.peel, %88 ], [ %.1, %124 ]
  %103 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.3, i64 noundef %.040.lcssa)
  br label %131

.lr.ph62.peel.next:                               ; preds = %88, %124
  %.03961 = phi i64 [ %125, %124 ], [ 1, %88 ]
  %.04060 = phi i64 [ %.1, %124 ], [ %.1.peel, %88 ]
  %104 = add nsw i64 %.03961, -1
  %105 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %5, i64 noundef %104) #7
  %106 = load i64, ptr %105, align 8, !tbaa !5
  %.pre = load i64, ptr %2, align 8, !tbaa !5
  %107 = sub nsw i64 %.pre, %.03961
  %108 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %3) #7
  %.not47 = icmp ult i64 %108, %107
  br i1 %.not47, label %124, label %109

109:                                              ; preds = %.lr.ph62.peel.next
  %110 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %4) #7
  %.not48 = icmp ult i64 %110, %107
  br i1 %.not48, label %124, label %111

111:                                              ; preds = %109
  %112 = icmp sgt i64 %107, 0
  br i1 %112, label %113, label %120

113:                                              ; preds = %111
  %114 = add nsw i64 %107, -1
  %115 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %3, i64 noundef %114) #7
  %116 = load i64, ptr %115, align 8, !tbaa !5
  %117 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %4, i64 noundef %114) #7
  %118 = load i64, ptr %117, align 8, !tbaa !5
  %119 = add nsw i64 %118, %116
  br label %120

120:                                              ; preds = %111, %113
  %121 = phi i64 [ %119, %113 ], [ 0, %111 ]
  %122 = add nsw i64 %121, %106
  %123 = call i64 @llvm.smin.i64(i64 %.04060, i64 %122)
  br label %124

124:                                              ; preds = %120, %109, %.lr.ph62.peel.next
  %.1 = phi i64 [ %123, %120 ], [ %.04060, %109 ], [ %.04060, %.lr.ph62.peel.next ]
  %125 = add nuw nsw i64 %.03961, 1
  %126 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %5) #7
  %127 = icmp ult i64 %.03961, %126
  %128 = load i64, ptr %2, align 8
  %129 = icmp slt i64 %.03961, %128
  %130 = select i1 %127, i1 %129, i1 false
  br i1 %130, label %.lr.ph62.peel.next, label %._crit_edge63, !llvm.loop !14

131:                                              ; preds = %._crit_edge63, %34
  call void @_ZNSt6vectorIlSaIlEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %5) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %5) #7
  call void @_ZNSt6vectorIlSaIlEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %4) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %4) #7
  call void @_ZNSt6vectorIlSaIlEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %3) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %3) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %2) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %1) #7
  ret i32 0

132:                                              ; preds = %36, %22
  %.pn = phi { ptr, i32 } [ %23, %22 ], [ %37, %36 ]
  call void @_ZNSt6vectorIlSaIlEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %5) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %5) #7
  call void @_ZNSt6vectorIlSaIlEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %4) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %4) #7
  call void @_ZNSt6vectorIlSaIlEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %3) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %3) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %2) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %1) #7
  resume { ptr, i32 } %.pn
}

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

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

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

declare i32 @__gxx_personality_v0(...)

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

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

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

; Function Attrs: nofree nounwind
declare noundef i32 @puts(ptr nocapture noundef readonly) local_unnamed_addr #2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZSt4sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEEEvT_S7_(ptr, ptr) local_unnamed_addr #5

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

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

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

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

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

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i64 @llvm.smin.i64(i64, 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 nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { nofree nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #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 = { 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 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", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = distinct !{!9, !10}
!10 = !{!"llvm.loop.mustprogress"}
!11 = distinct !{!11, !10}
!12 = distinct !{!12, !10}
!13 = distinct !{!13, !10}
!14 = distinct !{!14, !10, !15}
!15 = !{!"llvm.loop.peeled.count", i32 1}


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