; LLVM IR from DionysiosB/CodeForces :: 1922C-ClosestCities (main)

; Unoptimized IR (clang -disable-llvm-passes):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

%"class.std::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.std::allocator" = type { i8 }

@.str = external hidden unnamed_addr constant [4 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [15 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [15 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [8 x i8], align 1
@.str.5 = 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::allocator", align 1
  %6 = alloca ptr, align 8
  %7 = alloca i32, align 4
  %8 = alloca i64, align 8
  %9 = alloca %"class.std::vector", align 8
  %10 = alloca i64, align 8
  %11 = alloca %"class.std::allocator", align 1
  %12 = alloca %"class.std::vector", align 8
  %13 = alloca i64, align 8
  %14 = alloca %"class.std::allocator", align 1
  %15 = alloca i64, align 8
  %16 = alloca i64, align 8
  %17 = alloca i64, align 8
  %18 = alloca i64, align 8
  %19 = alloca i64, 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
  store i32 0, ptr %1, align 4
  call void @llvm.lifetime.start.p0(i64 8, ptr %2) #5
  %26 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef %2)
  br label %27

27:                                               ; preds = %267, %0
  %28 = load i64, ptr %2, align 8, !tbaa !5
  %29 = add nsw i64 %28, -1
  store i64 %29, ptr %2, align 8, !tbaa !5
  %30 = icmp ne i64 %28, 0
  br i1 %30, label %31, label %274

31:                                               ; preds = %27
  call void @llvm.lifetime.start.p0(i64 8, ptr %3) #5
  %32 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef %3)
  call void @llvm.lifetime.start.p0(i64 24, ptr %4) #5
  %33 = load i64, ptr %3, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 1, ptr %5) #5
  call void @_ZNSaIlEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %5) #5
  invoke void @_ZNSt6vectorIlSaIlEEC2EmRKS0_(ptr noundef nonnull align 8 dereferenceable(24) %4, i64 noundef %33, ptr noundef nonnull align 1 dereferenceable(1) %5)
          to label %34 unwind label %40

34:                                               ; preds = %31
  call void @_ZNSt15__new_allocatorIlED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %5) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr %5) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %8) #5
  store i64 0, ptr %8, align 8, !tbaa !5
  br label %35

35:                                               ; preds = %49, %34
  %36 = load i64, ptr %8, align 8, !tbaa !5
  %37 = load i64, ptr %3, align 8, !tbaa !5
  %38 = icmp slt i64 %36, %37
  br i1 %38, label %44, label %39

39:                                               ; preds = %35
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #5
  br label %56

40:                                               ; preds = %31
  %41 = landingpad { ptr, i32 }
          cleanup
  %42 = extractvalue { ptr, i32 } %41, 0
  store ptr %42, ptr %6, align 8
  %43 = extractvalue { ptr, i32 } %41, 1
  store i32 %43, ptr %7, align 4
  call void @_ZNSt15__new_allocatorIlED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %5) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr %5) #5
  br label %273

44:                                               ; preds = %35
  %45 = load i64, ptr %8, align 8, !tbaa !5
  %46 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %4, i64 noundef %45) #5
  %47 = invoke i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef %46)
          to label %48 unwind label %52

48:                                               ; preds = %44
  br label %49

49:                                               ; preds = %48
  %50 = load i64, ptr %8, align 8, !tbaa !5
  %51 = add nsw i64 %50, 1
  store i64 %51, ptr %8, align 8, !tbaa !5
  br label %35, !llvm.loop !9

52:                                               ; preds = %44
  %53 = landingpad { ptr, i32 }
          cleanup
  %54 = extractvalue { ptr, i32 } %53, 0
  store ptr %54, ptr %6, align 8
  %55 = extractvalue { ptr, i32 } %53, 1
  store i32 %55, ptr %7, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #5
  br label %272

56:                                               ; preds = %39
  call void @llvm.lifetime.start.p0(i64 24, ptr %9) #5
  %57 = load i64, ptr %3, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #5
  store i64 0, ptr %10, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 1, ptr %11) #5
  call void @_ZNSaIlEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %11) #5
  invoke void @_ZNSt6vectorIlSaIlEEC2EmRKlRKS0_(ptr noundef nonnull align 8 dereferenceable(24) %9, i64 noundef %57, ptr noundef nonnull align 8 dereferenceable(8) %10, ptr noundef nonnull align 1 dereferenceable(1) %11)
          to label %58 unwind label %71

58:                                               ; preds = %56
  call void @_ZNSt15__new_allocatorIlED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %11) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr %11) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #5
  call void @llvm.lifetime.start.p0(i64 24, ptr %12) #5
  %59 = load i64, ptr %3, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #5
  store i64 0, ptr %13, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 1, ptr %14) #5
  call void @_ZNSaIlEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %14) #5
  invoke void @_ZNSt6vectorIlSaIlEEC2EmRKlRKS0_(ptr noundef nonnull align 8 dereferenceable(24) %12, i64 noundef %59, ptr noundef nonnull align 8 dereferenceable(8) %13, ptr noundef nonnull align 1 dereferenceable(1) %14)
          to label %60 unwind label %75

60:                                               ; preds = %58
  call void @_ZNSt15__new_allocatorIlED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %14) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr %14) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #5
  %61 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %9, i64 noundef 0) #5
  store i64 1, ptr %61, align 8, !tbaa !5
  %62 = load i64, ptr %3, align 8, !tbaa !5
  %63 = sub nsw i64 %62, 1
  %64 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %12, i64 noundef %63) #5
  store i64 1, ptr %64, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #5
  store i64 1, ptr %15, align 8, !tbaa !5
  br label %65

65:                                               ; preds = %112, %60
  %66 = load i64, ptr %15, align 8, !tbaa !5
  %67 = add nsw i64 %66, 1
  %68 = load i64, ptr %3, align 8, !tbaa !5
  %69 = icmp slt i64 %67, %68
  br i1 %69, label %79, label %70

70:                                               ; preds = %65
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #5
  br label %115

71:                                               ; preds = %56
  %72 = landingpad { ptr, i32 }
          cleanup
  %73 = extractvalue { ptr, i32 } %72, 0
  store ptr %73, ptr %6, align 8
  %74 = extractvalue { ptr, i32 } %72, 1
  store i32 %74, ptr %7, align 4
  call void @_ZNSt15__new_allocatorIlED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %11) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr %11) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #5
  br label %271

75:                                               ; preds = %58
  %76 = landingpad { ptr, i32 }
          cleanup
  %77 = extractvalue { ptr, i32 } %76, 0
  store ptr %77, ptr %6, align 8
  %78 = extractvalue { ptr, i32 } %76, 1
  store i32 %78, ptr %7, align 4
  call void @_ZNSt15__new_allocatorIlED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %14) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr %14) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #5
  br label %270

79:                                               ; preds = %65
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #5
  %80 = load i64, ptr %15, align 8, !tbaa !5
  %81 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %4, i64 noundef %80) #5
  %82 = load i64, ptr %81, align 8, !tbaa !5
  %83 = load i64, ptr %15, align 8, !tbaa !5
  %84 = sub nsw i64 %83, 1
  %85 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %4, i64 noundef %84) #5
  %86 = load i64, ptr %85, align 8, !tbaa !5
  %87 = sub nsw i64 %82, %86
  store i64 %87, ptr %16, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #5
  %88 = load i64, ptr %15, align 8, !tbaa !5
  %89 = add nsw i64 %88, 1
  %90 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %4, i64 noundef %89) #5
  %91 = load i64, ptr %90, align 8, !tbaa !5
  %92 = load i64, ptr %15, align 8, !tbaa !5
  %93 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %4, i64 noundef %92) #5
  %94 = load i64, ptr %93, align 8, !tbaa !5
  %95 = sub nsw i64 %91, %94
  store i64 %95, ptr %17, align 8, !tbaa !5
  %96 = load i64, ptr %16, align 8, !tbaa !5
  %97 = load i64, ptr %17, align 8, !tbaa !5
  %98 = icmp slt i64 %96, %97
  br i1 %98, label %99, label %105

99:                                               ; preds = %79
  %100 = load i64, ptr %17, align 8, !tbaa !5
  %101 = load i64, ptr %15, align 8, !tbaa !5
  %102 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %9, i64 noundef %101) #5
  store i64 %100, ptr %102, align 8, !tbaa !5
  %103 = load i64, ptr %15, align 8, !tbaa !5
  %104 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %12, i64 noundef %103) #5
  store i64 1, ptr %104, align 8, !tbaa !5
  br label %111

105:                                              ; preds = %79
  %106 = load i64, ptr %15, align 8, !tbaa !5
  %107 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %9, i64 noundef %106) #5
  store i64 1, ptr %107, align 8, !tbaa !5
  %108 = load i64, ptr %16, align 8, !tbaa !5
  %109 = load i64, ptr %15, align 8, !tbaa !5
  %110 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %12, i64 noundef %109) #5
  store i64 %108, ptr %110, align 8, !tbaa !5
  br label %111

111:                                              ; preds = %105, %99
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #5
  br label %112

112:                                              ; preds = %111
  %113 = load i64, ptr %15, align 8, !tbaa !5
  %114 = add nsw i64 %113, 1
  store i64 %114, ptr %15, align 8, !tbaa !5
  br label %65, !llvm.loop !11

115:                                              ; preds = %70
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #5
  store i64 1, ptr %18, align 8, !tbaa !5
  br label %116

116:                                              ; preds = %131, %115
  %117 = load i64, ptr %18, align 8, !tbaa !5
  %118 = add nsw i64 %117, 1
  %119 = load i64, ptr %3, align 8, !tbaa !5
  %120 = icmp slt i64 %118, %119
  br i1 %120, label %122, label %121

121:                                              ; preds = %116
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #5
  br label %134

122:                                              ; preds = %116
  %123 = load i64, ptr %18, align 8, !tbaa !5
  %124 = sub nsw i64 %123, 1
  %125 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %9, i64 noundef %124) #5
  %126 = load i64, ptr %125, align 8, !tbaa !5
  %127 = load i64, ptr %18, align 8, !tbaa !5
  %128 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %9, i64 noundef %127) #5
  %129 = load i64, ptr %128, align 8, !tbaa !5
  %130 = add nsw i64 %129, %126
  store i64 %130, ptr %128, align 8, !tbaa !5
  br label %131

131:                                              ; preds = %122
  %132 = load i64, ptr %18, align 8, !tbaa !5
  %133 = add nsw i64 %132, 1
  store i64 %133, ptr %18, align 8, !tbaa !5
  br label %116, !llvm.loop !12

134:                                              ; preds = %121
  call void @llvm.lifetime.start.p0(i64 8, ptr %19) #5
  %135 = load i64, ptr %3, align 8, !tbaa !5
  %136 = sub nsw i64 %135, 2
  store i64 %136, ptr %19, align 8, !tbaa !5
  br label %137

137:                                              ; preds = %150, %134
  %138 = load i64, ptr %19, align 8, !tbaa !5
  %139 = icmp sgt i64 %138, 0
  br i1 %139, label %141, label %140

140:                                              ; preds = %137
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #5
  br label %153

141:                                              ; preds = %137
  %142 = load i64, ptr %19, align 8, !tbaa !5
  %143 = add nsw i64 %142, 1
  %144 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %12, i64 noundef %143) #5
  %145 = load i64, ptr %144, align 8, !tbaa !5
  %146 = load i64, ptr %19, align 8, !tbaa !5
  %147 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %12, i64 noundef %146) #5
  %148 = load i64, ptr %147, align 8, !tbaa !5
  %149 = add nsw i64 %148, %145
  store i64 %149, ptr %147, align 8, !tbaa !5
  br label %150

150:                                              ; preds = %141
  %151 = load i64, ptr %19, align 8, !tbaa !5
  %152 = add nsw i64 %151, -1
  store i64 %152, ptr %19, align 8, !tbaa !5
  br label %137, !llvm.loop !13

153:                                              ; preds = %140
  call void @llvm.lifetime.start.p0(i64 8, ptr %20) #5
  store i64 0, ptr %20, align 8, !tbaa !5
  br label %154

154:                                              ; preds = %166, %153
  %155 = load i64, ptr %20, align 8, !tbaa !5
  %156 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %9) #5
  %157 = icmp ult i64 %155, %156
  br i1 %157, label %159, label %158

158:                                              ; preds = %154
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #5
  br label %173

159:                                              ; preds = %154
  %160 = load i64, ptr %20, align 8, !tbaa !5
  %161 = load i64, ptr %20, align 8, !tbaa !5
  %162 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %9, i64 noundef %161) #5
  %163 = load i64, ptr %162, align 8, !tbaa !5
  %164 = invoke i32 (ptr, ...) @printf(ptr noundef @.str.1, i64 noundef %160, i64 noundef %163)
          to label %165 unwind label %169

165:                                              ; preds = %159
  br label %166

166:                                              ; preds = %165
  %167 = load i64, ptr %20, align 8, !tbaa !5
  %168 = add nsw i64 %167, 1
  store i64 %168, ptr %20, align 8, !tbaa !5
  br label %154, !llvm.loop !14

169:                                              ; preds = %159
  %170 = landingpad { ptr, i32 }
          cleanup
  %171 = extractvalue { ptr, i32 } %170, 0
  store ptr %171, ptr %6, align 8
  %172 = extractvalue { ptr, i32 } %170, 1
  store i32 %172, ptr %7, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #5
  br label %269

173:                                              ; preds = %158
  %174 = invoke i32 @puts(ptr noundef @.str.2)
          to label %175 unwind label %181

175:                                              ; preds = %173
  call void @llvm.lifetime.start.p0(i64 8, ptr %21) #5
  store i64 0, ptr %21, align 8, !tbaa !5
  br label %176

176:                                              ; preds = %192, %175
  %177 = load i64, ptr %21, align 8, !tbaa !5
  %178 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %12) #5
  %179 = icmp ult i64 %177, %178
  br i1 %179, label %185, label %180

180:                                              ; preds = %176
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #5
  br label %199

181:                                              ; preds = %173
  %182 = landingpad { ptr, i32 }
          cleanup
  %183 = extractvalue { ptr, i32 } %182, 0
  store ptr %183, ptr %6, align 8
  %184 = extractvalue { ptr, i32 } %182, 1
  store i32 %184, ptr %7, align 4
  br label %269

185:                                              ; preds = %176
  %186 = load i64, ptr %21, align 8, !tbaa !5
  %187 = load i64, ptr %21, align 8, !tbaa !5
  %188 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %12, i64 noundef %187) #5
  %189 = load i64, ptr %188, align 8, !tbaa !5
  %190 = invoke i32 (ptr, ...) @printf(ptr noundef @.str.3, i64 noundef %186, i64 noundef %189)
          to label %191 unwind label %195

191:                                              ; preds = %185
  br label %192

192:                                              ; preds = %191
  %193 = load i64, ptr %21, align 8, !tbaa !5
  %194 = add nsw i64 %193, 1
  store i64 %194, ptr %21, align 8, !tbaa !5
  br label %176, !llvm.loop !15

195:                                              ; preds = %185
  %196 = landingpad { ptr, i32 }
          cleanup
  %197 = extractvalue { ptr, i32 } %196, 0
  store ptr %197, ptr %6, align 8
  %198 = extractvalue { ptr, i32 } %196, 1
  store i32 %198, ptr %7, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #5
  br label %269

199:                                              ; preds = %180
  call void @llvm.lifetime.start.p0(i64 8, ptr %22) #5
  %200 = invoke i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef %22)
          to label %201 unwind label %232

201:                                              ; preds = %199
  br label %202

202:                                              ; preds = %261, %201
  %203 = load i64, ptr %22, align 8, !tbaa !5
  %204 = add nsw i64 %203, -1
  store i64 %204, ptr %22, align 8, !tbaa !5
  %205 = icmp ne i64 %203, 0
  br i1 %205, label %206, label %267

206:                                              ; preds = %202
  call void @llvm.lifetime.start.p0(i64 8, ptr %23) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %24) #5
  %207 = invoke i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str.4, ptr noundef %23, ptr noundef %24)
          to label %208 unwind label %236

208:                                              ; preds = %206
  %209 = load i64, ptr %23, align 8, !tbaa !5
  %210 = add nsw i64 %209, -1
  store i64 %210, ptr %23, align 8, !tbaa !5
  %211 = load i64, ptr %24, align 8, !tbaa !5
  %212 = add nsw i64 %211, -1
  store i64 %212, ptr %24, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %25) #5
  store i64 0, ptr %25, align 8, !tbaa !5
  %213 = load i64, ptr %23, align 8, !tbaa !5
  %214 = load i64, ptr %24, align 8, !tbaa !5
  %215 = icmp slt i64 %213, %214
  br i1 %215, label %216, label %240

216:                                              ; preds = %208
  %217 = load i64, ptr %24, align 8, !tbaa !5
  %218 = sub nsw i64 %217, 1
  %219 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %9, i64 noundef %218) #5
  %220 = load i64, ptr %219, align 8, !tbaa !5
  %221 = load i64, ptr %23, align 8, !tbaa !5
  %222 = icmp ne i64 %221, 0
  br i1 %222, label %223, label %228

223:                                              ; preds = %216
  %224 = load i64, ptr %23, align 8, !tbaa !5
  %225 = sub nsw i64 %224, 1
  %226 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %9, i64 noundef %225) #5
  %227 = load i64, ptr %226, align 8, !tbaa !5
  br label %229

228:                                              ; preds = %216
  br label %229

229:                                              ; preds = %228, %223
  %230 = phi i64 [ %227, %223 ], [ 0, %228 ]
  %231 = sub nsw i64 %220, %230
  store i64 %231, ptr %25, align 8, !tbaa !5
  br label %258

232:                                              ; preds = %199
  %233 = landingpad { ptr, i32 }
          cleanup
  %234 = extractvalue { ptr, i32 } %233, 0
  store ptr %234, ptr %6, align 8
  %235 = extractvalue { ptr, i32 } %233, 1
  store i32 %235, ptr %7, align 4
  br label %268

236:                                              ; preds = %206
  %237 = landingpad { ptr, i32 }
          cleanup
  %238 = extractvalue { ptr, i32 } %237, 0
  store ptr %238, ptr %6, align 8
  %239 = extractvalue { ptr, i32 } %237, 1
  store i32 %239, ptr %7, align 4
  br label %266

240:                                              ; preds = %208
  %241 = load i64, ptr %24, align 8, !tbaa !5
  %242 = add nsw i64 %241, 1
  %243 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %12, i64 noundef %242) #5
  %244 = load i64, ptr %243, align 8, !tbaa !5
  %245 = load i64, ptr %23, align 8, !tbaa !5
  %246 = add nsw i64 %245, 1
  %247 = load i64, ptr %3, align 8, !tbaa !5
  %248 = icmp slt i64 %246, %247
  br i1 %248, label %249, label %254

249:                                              ; preds = %240
  %250 = load i64, ptr %23, align 8, !tbaa !5
  %251 = add nsw i64 %250, 1
  %252 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %12, i64 noundef %251) #5
  %253 = load i64, ptr %252, align 8, !tbaa !5
  br label %255

254:                                              ; preds = %240
  br label %255

255:                                              ; preds = %254, %249
  %256 = phi i64 [ %253, %249 ], [ 0, %254 ]
  %257 = sub nsw i64 %244, %256
  store i64 %257, ptr %25, align 8, !tbaa !5
  br label %258

258:                                              ; preds = %255, %229
  %259 = load i64, ptr %25, align 8, !tbaa !5
  %260 = invoke i32 (ptr, ...) @printf(ptr noundef @.str.5, i64 noundef %259)
          to label %261 unwind label %262

261:                                              ; preds = %258
  call void @llvm.lifetime.end.p0(i64 8, ptr %25) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %24) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %23) #5
  br label %202, !llvm.loop !16

262:                                              ; preds = %258
  %263 = landingpad { ptr, i32 }
          cleanup
  %264 = extractvalue { ptr, i32 } %263, 0
  store ptr %264, ptr %6, align 8
  %265 = extractvalue { ptr, i32 } %263, 1
  store i32 %265, ptr %7, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %25) #5
  br label %266

266:                                              ; preds = %262, %236
  call void @llvm.lifetime.end.p0(i64 8, ptr %24) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %23) #5
  br label %268

267:                                              ; preds = %202
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #5
  call void @_ZNSt6vectorIlSaIlEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %12) #5
  call void @llvm.lifetime.end.p0(i64 24, ptr %12) #5
  call void @_ZNSt6vectorIlSaIlEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %9) #5
  call void @llvm.lifetime.end.p0(i64 24, ptr %9) #5
  call void @_ZNSt6vectorIlSaIlEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %4) #5
  call void @llvm.lifetime.end.p0(i64 24, ptr %4) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %3) #5
  br label %27, !llvm.loop !17

268:                                              ; preds = %266, %232
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #5
  br label %269

269:                                              ; preds = %268, %195, %181, %169
  call void @_ZNSt6vectorIlSaIlEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %12) #5
  br label %270

270:                                              ; preds = %269, %75
  call void @llvm.lifetime.end.p0(i64 24, ptr %12) #5
  call void @_ZNSt6vectorIlSaIlEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %9) #5
  br label %271

271:                                              ; preds = %270, %71
  call void @llvm.lifetime.end.p0(i64 24, ptr %9) #5
  br label %272

272:                                              ; preds = %271, %52
  call void @_ZNSt6vectorIlSaIlEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %4) #5
  br label %273

273:                                              ; preds = %272, %40
  call void @llvm.lifetime.end.p0(i64 24, ptr %4) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %3) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %2) #5
  br label %276

274:                                              ; preds = %27
  call void @llvm.lifetime.end.p0(i64 8, ptr %2) #5
  %275 = load i32, ptr %1, align 4
  ret i32 %275

276:                                              ; preds = %273
  %277 = load ptr, ptr %6, align 8
  %278 = load i32, ptr %7, align 4
  %279 = insertvalue { ptr, i32 } poison, ptr %277, 0
  %280 = insertvalue { ptr, i32 } %279, i32 %278, 1
  resume { ptr, i32 } %280
}

; 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 @_ZNSaIlEC2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #3 align 2

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

declare i32 @__gxx_personality_v0(...)

; 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 nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24), i64 noundef) #3 align 2

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

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

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

declare i32 @puts(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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt15__new_allocatorIlED2Ev(ptr noundef nonnull align 1 dereferenceable(1)) 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 = { 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 = distinct !{!15, !10}
!16 = distinct !{!16, !10}
!17 = distinct !{!17, !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 }
%"class.std::allocator" = type { i8 }

@.str = external hidden unnamed_addr constant [4 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [15 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [15 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [8 x i8], align 1
@.str.5 = 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::allocator", align 1
  %5 = alloca %"class.std::vector", align 8
  %6 = alloca i64, align 8
  %7 = alloca %"class.std::allocator", align 1
  %8 = alloca %"class.std::vector", align 8
  %9 = alloca i64, align 8
  %10 = alloca %"class.std::allocator", align 1
  %11 = alloca i64, align 8
  %12 = alloca i64, align 8
  %13 = alloca i64, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %1) #5
  %14 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull %1)
  %15 = load i64, ptr %1, align 8, !tbaa !5
  %16 = add nsw i64 %15, -1
  store i64 %16, ptr %1, align 8, !tbaa !5
  %.not81 = icmp eq i64 %15, 0
  br i1 %.not81, label %._crit_edge84, label %.lr.ph83

.lr.ph83:                                         ; preds = %0, %._crit_edge80
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %2) #5
  %17 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull %2)
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %3) #5
  %18 = load i64, ptr %2, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %4) #5
  call void @_ZNSaIlEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %4) #5
  invoke void @_ZNSt6vectorIlSaIlEEC2EmRKS0_(ptr noundef nonnull align 8 dereferenceable(24) %3, i64 noundef %18, ptr noundef nonnull align 1 dereferenceable(1) %4)
          to label %19 unwind label %22

19:                                               ; preds = %.lr.ph83
  call void @_ZNSt15__new_allocatorIlED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %4) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %4) #5
  %20 = load i64, ptr %2, align 8, !tbaa !5
  %21 = icmp sgt i64 %20, 0
  br i1 %21, label %.lr.ph, label %._crit_edge

._crit_edge:                                      ; preds = %.lr.ph, %19
  %.lcssa = phi i64 [ %20, %19 ], [ %27, %.lr.ph ]
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %5) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %6) #5
  store i64 0, ptr %6, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %7) #5
  call void @_ZNSaIlEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %7) #5
  invoke void @_ZNSt6vectorIlSaIlEEC2EmRKlRKS0_(ptr noundef nonnull align 8 dereferenceable(24) %5, i64 noundef %.lcssa, ptr noundef nonnull align 8 dereferenceable(8) %6, ptr noundef nonnull align 1 dereferenceable(1) %7)
          to label %29 unwind label %39

22:                                               ; preds = %.lr.ph83
  %23 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt15__new_allocatorIlED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %4) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %4) #5
  br label %137

.lr.ph:                                           ; preds = %19, %.lr.ph
  %.04459 = phi i64 [ %26, %.lr.ph ], [ 0, %19 ]
  %24 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %3, i64 noundef %.04459) #5
  %25 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull %24)
  %26 = add nuw nsw i64 %.04459, 1
  %27 = load i64, ptr %2, align 8, !tbaa !5
  %28 = icmp slt i64 %26, %27
  br i1 %28, label %.lr.ph, label %._crit_edge, !llvm.loop !9

29:                                               ; preds = %._crit_edge
  call void @_ZNSt15__new_allocatorIlED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %7) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %7) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #5
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %8) #5
  %30 = load i64, ptr %2, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %9) #5
  store i64 0, ptr %9, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %10) #5
  call void @_ZNSaIlEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %10) #5
  invoke void @_ZNSt6vectorIlSaIlEEC2EmRKlRKS0_(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef %30, ptr noundef nonnull align 8 dereferenceable(8) %9, ptr noundef nonnull align 1 dereferenceable(1) %10)
          to label %31 unwind label %41

31:                                               ; preds = %29
  call void @_ZNSt15__new_allocatorIlED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %10) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %10) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %9) #5
  %32 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %5, i64 noundef 0) #5
  store i64 1, ptr %32, align 8, !tbaa !5
  %33 = load i64, ptr %2, align 8, !tbaa !5
  %34 = add nsw i64 %33, -1
  %35 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef %34) #5
  store i64 1, ptr %35, align 8, !tbaa !5
  %36 = load i64, ptr %2, align 8, !tbaa !5
  %37 = icmp sgt i64 %36, 2
  br i1 %37, label %.lr.ph62, label %.preheader

.preheader57:                                     ; preds = %.lr.ph62
  %38 = icmp sgt i64 %59, 2
  br i1 %38, label %.lr.ph64, label %.preheader

39:                                               ; preds = %._crit_edge
  %40 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt15__new_allocatorIlED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %7) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %7) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #5
  br label %136

41:                                               ; preds = %29
  %42 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt15__new_allocatorIlED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %10) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %10) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %9) #5
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %8) #5
  call void @_ZNSt6vectorIlSaIlEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %5) #5
  br label %136

.lr.ph62:                                         ; preds = %31, %.lr.ph62
  %43 = phi i64 [ %58, %.lr.ph62 ], [ 2, %31 ]
  %.04360 = phi i64 [ %43, %.lr.ph62 ], [ 1, %31 ]
  %44 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %3, i64 noundef %.04360) #5
  %45 = load i64, ptr %44, align 8, !tbaa !5
  %46 = add nsw i64 %.04360, -1
  %47 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %3, i64 noundef %46) #5
  %48 = load i64, ptr %47, align 8, !tbaa !5
  %49 = sub nsw i64 %45, %48
  %50 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %3, i64 noundef %43) #5
  %51 = load i64, ptr %50, align 8, !tbaa !5
  %52 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %3, i64 noundef %.04360) #5
  %53 = load i64, ptr %52, align 8, !tbaa !5
  %54 = sub nsw i64 %51, %53
  %55 = icmp slt i64 %49, %54
  %56 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %5, i64 noundef %.04360) #5
  %. = select i1 %55, i64 %54, i64 1
  %.95 = select i1 %55, i64 1, i64 %49
  store i64 %., ptr %56, align 8, !tbaa !5
  %57 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef %.04360) #5
  store i64 %.95, ptr %57, align 8, !tbaa !5
  %58 = add nuw nsw i64 %43, 1
  %59 = load i64, ptr %2, align 8, !tbaa !5
  %60 = icmp slt i64 %58, %59
  br i1 %60, label %.lr.ph62, label %.preheader57, !llvm.loop !11

._crit_edge65:                                    ; preds = %.lr.ph64
  %61 = icmp sgt i64 %71, 2
  br i1 %61, label %.lr.ph69.preheader, label %.preheader

.lr.ph69.preheader:                               ; preds = %._crit_edge65
  %62 = add nsw i64 %71, -2
  br label %.lr.ph69

.lr.ph64:                                         ; preds = %.preheader57, %.lr.ph64
  %63 = phi i64 [ %70, %.lr.ph64 ], [ 2, %.preheader57 ]
  %.03963 = phi i64 [ %63, %.lr.ph64 ], [ 1, %.preheader57 ]
  %64 = add nsw i64 %.03963, -1
  %65 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %5, i64 noundef %64) #5
  %66 = load i64, ptr %65, align 8, !tbaa !5
  %67 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %5, i64 noundef %.03963) #5
  %68 = load i64, ptr %67, align 8, !tbaa !5
  %69 = add nsw i64 %68, %66
  store i64 %69, ptr %67, align 8, !tbaa !5
  %70 = add nuw nsw i64 %63, 1
  %71 = load i64, ptr %2, align 8, !tbaa !5
  %72 = icmp slt i64 %70, %71
  br i1 %72, label %.lr.ph64, label %._crit_edge65, !llvm.loop !12

.preheader:                                       ; preds = %.lr.ph69, %31, %.preheader57, %._crit_edge65
  %73 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %5) #5
  %.not85 = icmp eq i64 %73, 0
  br i1 %.not85, label %._crit_edge72, label %.lr.ph71

.lr.ph69:                                         ; preds = %.lr.ph69.preheader, %.lr.ph69
  %.03867 = phi i64 [ %80, %.lr.ph69 ], [ %62, %.lr.ph69.preheader ]
  %74 = add nuw nsw i64 %.03867, 1
  %75 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef %74) #5
  %76 = load i64, ptr %75, align 8, !tbaa !5
  %77 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef %.03867) #5
  %78 = load i64, ptr %77, align 8, !tbaa !5
  %79 = add nsw i64 %78, %76
  store i64 %79, ptr %77, align 8, !tbaa !5
  %80 = add nsw i64 %.03867, -1
  %81 = icmp ugt i64 %.03867, 1
  br i1 %81, label %.lr.ph69, label %.preheader, !llvm.loop !13

._crit_edge72:                                    ; preds = %.lr.ph71, %.preheader
  %82 = call i32 @puts(ptr noundef nonnull dereferenceable(1) @.str.2)
  %83 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %8) #5
  %.not86 = icmp eq i64 %83, 0
  br i1 %.not86, label %._crit_edge76, label %.lr.ph75

.lr.ph71:                                         ; preds = %.preheader, %.lr.ph71
  %.03770 = phi i64 [ %87, %.lr.ph71 ], [ 0, %.preheader ]
  %84 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %5, i64 noundef %.03770) #5
  %85 = load i64, ptr %84, align 8, !tbaa !5
  %86 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.1, i64 noundef %.03770, i64 noundef %85)
  %87 = add nuw nsw i64 %.03770, 1
  %88 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %5) #5
  %89 = icmp ult i64 %87, %88
  br i1 %89, label %.lr.ph71, label %._crit_edge72, !llvm.loop !14

._crit_edge76:                                    ; preds = %.lr.ph75, %._crit_edge72
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %11) #5
  %90 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull %11)
  %91 = load i64, ptr %11, align 8, !tbaa !5
  %92 = add nsw i64 %91, -1
  store i64 %92, ptr %11, align 8, !tbaa !5
  %.not5577 = icmp eq i64 %91, 0
  br i1 %.not5577, label %._crit_edge80, label %.lr.ph79

.lr.ph75:                                         ; preds = %._crit_edge72, %.lr.ph75
  %.03673 = phi i64 [ %96, %.lr.ph75 ], [ 0, %._crit_edge72 ]
  %93 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef %.03673) #5
  %94 = load i64, ptr %93, align 8, !tbaa !5
  %95 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.3, i64 noundef %.03673, i64 noundef %94)
  %96 = add nuw nsw i64 %.03673, 1
  %97 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %8) #5
  %98 = icmp ult i64 %96, %97
  br i1 %98, label %.lr.ph75, label %._crit_edge76, !llvm.loop !15

.lr.ph79:                                         ; preds = %._crit_edge76, %130
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %12) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %13) #5
  %99 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str.4, ptr noundef nonnull %12, ptr noundef nonnull %13)
  %100 = load i64, ptr %12, align 8, !tbaa !5
  %101 = add nsw i64 %100, -1
  store i64 %101, ptr %12, align 8, !tbaa !5
  %102 = load i64, ptr %13, align 8, !tbaa !5
  %103 = add nsw i64 %102, -1
  store i64 %103, ptr %13, align 8, !tbaa !5
  %104 = icmp slt i64 %100, %102
  br i1 %104, label %105, label %117

105:                                              ; preds = %.lr.ph79
  %106 = add nsw i64 %102, -2
  %107 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %5, i64 noundef %106) #5
  %108 = load i64, ptr %107, align 8, !tbaa !5
  %109 = load i64, ptr %12, align 8, !tbaa !5
  %.not56 = icmp eq i64 %109, 0
  br i1 %.not56, label %114, label %110

110:                                              ; preds = %105
  %111 = add nsw i64 %109, -1
  %112 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %5, i64 noundef %111) #5
  %113 = load i64, ptr %112, align 8, !tbaa !5
  br label %114

114:                                              ; preds = %105, %110
  %115 = phi i64 [ %113, %110 ], [ 0, %105 ]
  %116 = sub nsw i64 %108, %115
  br label %130

117:                                              ; preds = %.lr.ph79
  %118 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef %102) #5
  %119 = load i64, ptr %118, align 8, !tbaa !5
  %120 = load i64, ptr %12, align 8, !tbaa !5
  %121 = add nsw i64 %120, 1
  %122 = load i64, ptr %2, align 8, !tbaa !5
  %123 = icmp slt i64 %121, %122
  br i1 %123, label %124, label %127

124:                                              ; preds = %117
  %125 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef %121) #5
  %126 = load i64, ptr %125, align 8, !tbaa !5
  br label %127

127:                                              ; preds = %117, %124
  %128 = phi i64 [ %126, %124 ], [ 0, %117 ]
  %129 = sub nsw i64 %119, %128
  br label %130

130:                                              ; preds = %127, %114
  %.0 = phi i64 [ %116, %114 ], [ %129, %127 ]
  %131 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.5, i64 noundef %.0)
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %13) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %12) #5
  %132 = load i64, ptr %11, align 8, !tbaa !5
  %133 = add nsw i64 %132, -1
  store i64 %133, ptr %11, align 8, !tbaa !5
  %.not55 = icmp eq i64 %132, 0
  br i1 %.not55, label %._crit_edge80, label %.lr.ph79, !llvm.loop !16

._crit_edge80:                                    ; preds = %130, %._crit_edge76
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %11) #5
  call void @_ZNSt6vectorIlSaIlEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %8) #5
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %8) #5
  call void @_ZNSt6vectorIlSaIlEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %5) #5
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %5) #5
  call void @_ZNSt6vectorIlSaIlEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %3) #5
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %3) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %2) #5
  %134 = load i64, ptr %1, align 8, !tbaa !5
  %135 = add nsw i64 %134, -1
  store i64 %135, ptr %1, align 8, !tbaa !5
  %.not = icmp eq i64 %134, 0
  br i1 %.not, label %._crit_edge84, label %.lr.ph83, !llvm.loop !17

136:                                              ; preds = %41, %39
  %.pn = phi { ptr, i32 } [ %42, %41 ], [ %40, %39 ]
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %5) #5
  call void @_ZNSt6vectorIlSaIlEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %3) #5
  br label %137

137:                                              ; preds = %136, %22
  %.pn.pn = phi { ptr, i32 } [ %.pn, %136 ], [ %23, %22 ]
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %3) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %2) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %1) #5
  resume { ptr, i32 } %.pn.pn

._crit_edge84:                                    ; preds = %._crit_edge80, %0
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %1) #5
  ret i32 0
}

; 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 @_ZNSaIlEC2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #3 align 2

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

declare i32 @__gxx_personality_v0(...)

; 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 nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24), i64 noundef) local_unnamed_addr #3 align 2

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

; 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 @printf(ptr nocapture noundef readonly, ...) local_unnamed_addr #2

; Function Attrs: nofree nounwind
declare noundef i32 @puts(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: mustprogress nounwind uwtable
declare dso_local void @_ZNSt15__new_allocatorIlED2Ev(ptr noundef nonnull align 1 dereferenceable(1)) 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 = { 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 = { 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 = distinct !{!15, !10}
!16 = distinct !{!16, !10}
!17 = distinct !{!17, !10}


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