; LLVM IR from DionysiosB/CodeForces :: 0300-0399 (350B-Resort)

; 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 }

@.str = external hidden unnamed_addr constant [4 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [5 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [5 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [1 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 ptr, align 8
  %4 = alloca ptr, align 8
  %5 = alloca ptr, align 8
  %6 = alloca i32, align 4
  %7 = alloca i64, align 8
  %8 = alloca %"class.std::vector", align 8
  %9 = alloca i32, align 4
  %10 = alloca ptr, align 8
  %11 = alloca i32, align 4
  %12 = alloca i64, align 8
  %13 = alloca i32, align 4
  %14 = alloca %"class.std::vector", align 8
  %15 = alloca i32, align 4
  %16 = alloca %"class.std::vector", align 8
  %17 = alloca i64, align 8
  %18 = alloca i64, align 8
  %19 = alloca i32, align 4
  store i32 0, ptr %1, align 4
  call void @llvm.lifetime.start.p0(i64 8, ptr %2) #7
  store i64 0, ptr %2, align 8, !tbaa !5
  %20 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef %2)
  call void @llvm.lifetime.start.p0(i64 8, ptr %3) #7
  %21 = load i64, ptr %2, align 8, !tbaa !5
  %22 = call noalias noundef nonnull ptr @_Znam(i64 noundef %21) #8
  store ptr %22, ptr %3, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %4) #7
  %23 = load i64, ptr %2, align 8, !tbaa !5
  %24 = call { i64, i1 } @llvm.umul.with.overflow.i64(i64 %23, i64 8)
  %25 = extractvalue { i64, i1 } %24, 1
  %26 = extractvalue { i64, i1 } %24, 0
  %27 = select i1 %25, i64 -1, i64 %26
  %28 = call noalias noundef nonnull ptr @_Znam(i64 noundef %27) #8
  store ptr %28, ptr %4, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %5) #7
  %29 = load i64, ptr %2, align 8, !tbaa !5
  %30 = call { i64, i1 } @llvm.umul.with.overflow.i64(i64 %29, i64 8)
  %31 = extractvalue { i64, i1 } %30, 1
  %32 = extractvalue { i64, i1 } %30, 0
  %33 = select i1 %31, i64 -1, i64 %32
  %34 = call noalias noundef nonnull ptr @_Znam(i64 noundef %33) #8
  store ptr %34, ptr %5, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %6) #7
  store i32 0, ptr %6, align 4, !tbaa !11
  br label %35

35:                                               ; preds = %46, %0
  %36 = load i32, ptr %6, align 4, !tbaa !11
  %37 = sext i32 %36 to i64
  %38 = load i64, ptr %2, align 8, !tbaa !5
  %39 = icmp slt i64 %37, %38
  br i1 %39, label %41, label %40

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

41:                                               ; preds = %35
  %42 = load ptr, ptr %5, align 8, !tbaa !9
  %43 = load i32, ptr %6, align 4, !tbaa !11
  %44 = sext i32 %43 to i64
  %45 = getelementptr inbounds i64, ptr %42, i64 %44
  store i64 0, ptr %45, align 8, !tbaa !5
  br label %46

46:                                               ; preds = %41
  %47 = load i32, ptr %6, align 4, !tbaa !11
  %48 = add nsw i32 %47, 1
  store i32 %48, ptr %6, align 4, !tbaa !11
  br label %35, !llvm.loop !13

49:                                               ; preds = %40
  call void @llvm.lifetime.start.p0(i64 8, ptr %7) #7
  store i64 0, ptr %7, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 24, ptr %8) #7
  call void @_ZNSt6vectorIlSaIlEEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %8) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #7
  store i32 0, ptr %9, align 4, !tbaa !11
  br label %50

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

55:                                               ; preds = %50
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #7
  br label %89

56:                                               ; preds = %50
  %57 = invoke i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef %7)
          to label %58 unwind label %76

58:                                               ; preds = %56
  %59 = load i64, ptr %7, align 8, !tbaa !5
  %60 = icmp ne i64 %59, 0
  %61 = load ptr, ptr %3, align 8, !tbaa !9
  %62 = load i32, ptr %9, align 4, !tbaa !11
  %63 = sext i32 %62 to i64
  %64 = getelementptr inbounds i8, ptr %61, i64 %63
  %65 = zext i1 %60 to i8
  store i8 %65, ptr %64, align 1, !tbaa !15
  %66 = load ptr, ptr %3, align 8, !tbaa !9
  %67 = load i32, ptr %9, align 4, !tbaa !11
  %68 = sext i32 %67 to i64
  %69 = getelementptr inbounds i8, ptr %66, i64 %68
  %70 = load i8, ptr %69, align 1, !tbaa !15, !range !17, !noundef !18
  %71 = trunc i8 %70 to i1
  br i1 %71, label %72, label %84

72:                                               ; preds = %58
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #7
  %73 = load i32, ptr %9, align 4, !tbaa !11
  %74 = sext i32 %73 to i64
  store i64 %74, ptr %12, align 8, !tbaa !5
  invoke void @_ZNSt6vectorIlSaIlEE9push_backEOl(ptr noundef nonnull align 8 dereferenceable(24) %8, ptr noundef nonnull align 8 dereferenceable(8) %12)
          to label %75 unwind label %80

75:                                               ; preds = %72
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #7
  br label %84

76:                                               ; preds = %56
  %77 = landingpad { ptr, i32 }
          cleanup
  %78 = extractvalue { ptr, i32 } %77, 0
  store ptr %78, ptr %10, align 8
  %79 = extractvalue { ptr, i32 } %77, 1
  store i32 %79, ptr %11, align 4
  br label %88

80:                                               ; preds = %72
  %81 = landingpad { ptr, i32 }
          cleanup
  %82 = extractvalue { ptr, i32 } %81, 0
  store ptr %82, ptr %10, align 8
  %83 = extractvalue { ptr, i32 } %81, 1
  store i32 %83, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #7
  br label %88

84:                                               ; preds = %75, %58
  br label %85

85:                                               ; preds = %84
  %86 = load i32, ptr %9, align 4, !tbaa !11
  %87 = add nsw i32 %86, 1
  store i32 %87, ptr %9, align 4, !tbaa !11
  br label %50, !llvm.loop !19

88:                                               ; preds = %80, %76
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #7
  br label %225

89:                                               ; preds = %55
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #7
  store i32 0, ptr %13, align 4, !tbaa !11
  br label %90

90:                                               ; preds = %124, %89
  %91 = load i32, ptr %13, align 4, !tbaa !11
  %92 = sext i32 %91 to i64
  %93 = load i64, ptr %2, align 8, !tbaa !5
  %94 = icmp slt i64 %92, %93
  br i1 %94, label %96, label %95

95:                                               ; preds = %90
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #7
  br label %127

96:                                               ; preds = %90
  %97 = invoke i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef %7)
          to label %98 unwind label %106

98:                                               ; preds = %96
  %99 = load i64, ptr %7, align 8, !tbaa !5
  %100 = icmp eq i64 %99, 0
  br i1 %100, label %101, label %110

101:                                              ; preds = %98
  %102 = load ptr, ptr %4, align 8, !tbaa !9
  %103 = load i32, ptr %13, align 4, !tbaa !11
  %104 = sext i32 %103 to i64
  %105 = getelementptr inbounds i64, ptr %102, i64 %104
  store i64 -1, ptr %105, align 8, !tbaa !5
  br label %123

106:                                              ; preds = %96
  %107 = landingpad { ptr, i32 }
          cleanup
  %108 = extractvalue { ptr, i32 } %107, 0
  store ptr %108, ptr %10, align 8
  %109 = extractvalue { ptr, i32 } %107, 1
  store i32 %109, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #7
  br label %225

110:                                              ; preds = %98
  %111 = load i64, ptr %7, align 8, !tbaa !5
  %112 = sub nsw i64 %111, 1
  %113 = load ptr, ptr %4, align 8, !tbaa !9
  %114 = load i32, ptr %13, align 4, !tbaa !11
  %115 = sext i32 %114 to i64
  %116 = getelementptr inbounds i64, ptr %113, i64 %115
  store i64 %112, ptr %116, align 8, !tbaa !5
  %117 = load ptr, ptr %5, align 8, !tbaa !9
  %118 = load i64, ptr %7, align 8, !tbaa !5
  %119 = sub nsw i64 %118, 1
  %120 = getelementptr inbounds i64, ptr %117, i64 %119
  %121 = load i64, ptr %120, align 8, !tbaa !5
  %122 = add nsw i64 %121, 1
  store i64 %122, ptr %120, align 8, !tbaa !5
  br label %123

123:                                              ; preds = %110, %101
  br label %124

124:                                              ; preds = %123
  %125 = load i32, ptr %13, align 4, !tbaa !11
  %126 = add nsw i32 %125, 1
  store i32 %126, ptr %13, align 4, !tbaa !11
  br label %90, !llvm.loop !20

127:                                              ; preds = %95
  call void @llvm.lifetime.start.p0(i64 24, ptr %14) #7
  call void @_ZNSt6vectorIlSaIlEEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %14) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %15) #7
  store i32 0, ptr %15, align 4, !tbaa !11
  br label %128

128:                                              ; preds = %186, %127
  %129 = load i32, ptr %15, align 4, !tbaa !11
  %130 = sext i32 %129 to i64
  %131 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %8) #7
  %132 = icmp ult i64 %130, %131
  br i1 %132, label %134, label %133

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

134:                                              ; preds = %128
  call void @llvm.lifetime.start.p0(i64 24, ptr %16) #7
  call void @_ZNSt6vectorIlSaIlEEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %16) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #7
  %135 = load i32, ptr %15, align 4, !tbaa !11
  %136 = sext i32 %135 to i64
  %137 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef %136) #7
  %138 = load i64, ptr %137, align 8, !tbaa !5
  store i64 %138, ptr %17, align 8, !tbaa !5
  invoke void @_ZNSt6vectorIlSaIlEE9push_backERKl(ptr noundef nonnull align 8 dereferenceable(24) %16, ptr noundef nonnull align 8 dereferenceable(8) %17)
          to label %139 unwind label %170

139:                                              ; preds = %134
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #7
  %140 = load ptr, ptr %4, align 8, !tbaa !9
  %141 = load i32, ptr %15, align 4, !tbaa !11
  %142 = sext i32 %141 to i64
  %143 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef %142) #7
  %144 = load i64, ptr %143, align 8, !tbaa !5
  %145 = getelementptr inbounds i64, ptr %140, i64 %144
  %146 = load i64, ptr %145, align 8, !tbaa !5
  store i64 %146, ptr %18, align 8, !tbaa !5
  br label %147

147:                                              ; preds = %165, %139
  %148 = load i64, ptr %18, align 8, !tbaa !5
  %149 = icmp sge i64 %148, 0
  br i1 %149, label %150, label %162

150:                                              ; preds = %147
  %151 = load ptr, ptr %3, align 8, !tbaa !9
  %152 = load i64, ptr %18, align 8, !tbaa !5
  %153 = getelementptr inbounds i8, ptr %151, i64 %152
  %154 = load i8, ptr %153, align 1, !tbaa !15, !range !17, !noundef !18
  %155 = trunc i8 %154 to i1
  br i1 %155, label %162, label %156

156:                                              ; preds = %150
  %157 = load ptr, ptr %5, align 8, !tbaa !9
  %158 = load i64, ptr %18, align 8, !tbaa !5
  %159 = getelementptr inbounds i64, ptr %157, i64 %158
  %160 = load i64, ptr %159, align 8, !tbaa !5
  %161 = icmp sle i64 %160, 1
  br label %162

162:                                              ; preds = %156, %150, %147
  %163 = phi i1 [ false, %150 ], [ false, %147 ], [ %161, %156 ]
  br i1 %163, label %164, label %178

164:                                              ; preds = %162
  invoke void @_ZNSt6vectorIlSaIlEE9push_backERKl(ptr noundef nonnull align 8 dereferenceable(24) %16, ptr noundef nonnull align 8 dereferenceable(8) %18)
          to label %165 unwind label %174

165:                                              ; preds = %164
  %166 = load ptr, ptr %4, align 8, !tbaa !9
  %167 = load i64, ptr %18, align 8, !tbaa !5
  %168 = getelementptr inbounds i64, ptr %166, i64 %167
  %169 = load i64, ptr %168, align 8, !tbaa !5
  store i64 %169, ptr %18, align 8, !tbaa !5
  br label %147, !llvm.loop !21

170:                                              ; preds = %134
  %171 = landingpad { ptr, i32 }
          cleanup
  %172 = extractvalue { ptr, i32 } %171, 0
  store ptr %172, ptr %10, align 8
  %173 = extractvalue { ptr, i32 } %171, 1
  store i32 %173, ptr %11, align 4
  br label %189

174:                                              ; preds = %182, %164
  %175 = landingpad { ptr, i32 }
          cleanup
  %176 = extractvalue { ptr, i32 } %175, 0
  store ptr %176, ptr %10, align 8
  %177 = extractvalue { ptr, i32 } %175, 1
  store i32 %177, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #7
  br label %189

178:                                              ; preds = %162
  %179 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %16) #7
  %180 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %14) #7
  %181 = icmp ugt i64 %179, %180
  br i1 %181, label %182, label %185

182:                                              ; preds = %178
  %183 = invoke noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorIlSaIlEEaSERKS1_(ptr noundef nonnull align 8 dereferenceable(24) %14, ptr noundef nonnull align 8 dereferenceable(24) %16)
          to label %184 unwind label %174

184:                                              ; preds = %182
  br label %185

185:                                              ; preds = %184, %178
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #7
  call void @_ZNSt6vectorIlSaIlEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %16) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr %16) #7
  br label %186

186:                                              ; preds = %185
  %187 = load i32, ptr %15, align 4, !tbaa !11
  %188 = add nsw i32 %187, 1
  store i32 %188, ptr %15, align 4, !tbaa !11
  br label %128, !llvm.loop !22

189:                                              ; preds = %174, %170
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #7
  call void @_ZNSt6vectorIlSaIlEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %16) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr %16) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %15) #7
  br label %224

190:                                              ; preds = %133
  %191 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %14) #7
  %192 = invoke i32 (ptr, ...) @printf(ptr noundef @.str.1, i64 noundef %191)
          to label %193 unwind label %201

193:                                              ; preds = %190
  call void @llvm.lifetime.start.p0(i64 4, ptr %19) #7
  %194 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %14) #7
  %195 = sub i64 %194, 1
  %196 = trunc i64 %195 to i32
  store i32 %196, ptr %19, align 4, !tbaa !11
  br label %197

197:                                              ; preds = %213, %193
  %198 = load i32, ptr %19, align 4, !tbaa !11
  %199 = icmp sge i32 %198, 0
  br i1 %199, label %205, label %200

200:                                              ; preds = %197
  call void @llvm.lifetime.end.p0(i64 4, ptr %19) #7
  br label %220

201:                                              ; preds = %220, %190
  %202 = landingpad { ptr, i32 }
          cleanup
  %203 = extractvalue { ptr, i32 } %202, 0
  store ptr %203, ptr %10, align 8
  %204 = extractvalue { ptr, i32 } %202, 1
  store i32 %204, ptr %11, align 4
  br label %224

205:                                              ; preds = %197
  %206 = load i32, ptr %19, align 4, !tbaa !11
  %207 = sext i32 %206 to i64
  %208 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %14, i64 noundef %207) #7
  %209 = load i64, ptr %208, align 8, !tbaa !5
  %210 = add nsw i64 1, %209
  %211 = invoke i32 (ptr, ...) @printf(ptr noundef @.str.2, i64 noundef %210)
          to label %212 unwind label %216

212:                                              ; preds = %205
  br label %213

213:                                              ; preds = %212
  %214 = load i32, ptr %19, align 4, !tbaa !11
  %215 = add nsw i32 %214, -1
  store i32 %215, ptr %19, align 4, !tbaa !11
  br label %197, !llvm.loop !23

216:                                              ; preds = %205
  %217 = landingpad { ptr, i32 }
          cleanup
  %218 = extractvalue { ptr, i32 } %217, 0
  store ptr %218, ptr %10, align 8
  %219 = extractvalue { ptr, i32 } %217, 1
  store i32 %219, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %19) #7
  br label %224

220:                                              ; preds = %200
  %221 = invoke i32 @puts(ptr noundef @.str.3)
          to label %222 unwind label %201

222:                                              ; preds = %220
  store i32 0, ptr %1, align 4
  call void @_ZNSt6vectorIlSaIlEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %14) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr %14) #7
  call void @_ZNSt6vectorIlSaIlEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %8) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr %8) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %5) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %4) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %3) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %2) #7
  %223 = load i32, ptr %1, align 4
  ret i32 %223

224:                                              ; preds = %216, %201, %189
  call void @_ZNSt6vectorIlSaIlEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %14) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr %14) #7
  br label %225

225:                                              ; preds = %224, %106, %88
  call void @_ZNSt6vectorIlSaIlEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %8) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr %8) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %5) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %4) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %3) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %2) #7
  br label %226

226:                                              ; preds = %225
  %227 = load ptr, ptr %10, align 8
  %228 = load i32, ptr %11, align 4
  %229 = insertvalue { ptr, i32 } poison, ptr %227, 0
  %230 = insertvalue { ptr, i32 } %229, i32 %228, 1
  resume { ptr, i32 } %230
}

; 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: nobuiltin allocsize(0)
declare noundef nonnull ptr @_Znam(i64 noundef) #3

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare { i64, i1 } @llvm.umul.with.overflow.i64(i64, i64) #4

; 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 void @_ZNSt6vectorIlSaIlEEC2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #5 align 2

declare i32 @__gxx_personality_v0(...)

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24)) #5 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) #5 align 2

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

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

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

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

declare i32 @puts(ptr noundef) #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 = { nobuiltin allocsize(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 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #5 = { mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #6 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #7 = { nounwind }
attributes #8 = { builtin allocsize(0) }

!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 = !{!10, !10, i64 0}
!10 = !{!"any pointer", !7, i64 0}
!11 = !{!12, !12, i64 0}
!12 = !{!"int", !7, i64 0}
!13 = distinct !{!13, !14}
!14 = !{!"llvm.loop.mustprogress"}
!15 = !{!16, !16, i64 0}
!16 = !{!"bool", !7, i64 0}
!17 = !{i8 0, i8 2}
!18 = !{}
!19 = distinct !{!19, !14}
!20 = distinct !{!20, !14}
!21 = distinct !{!21, !14}
!22 = distinct !{!22, !14}
!23 = distinct !{!23, !14}


; 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 [4 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [5 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [5 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [1 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 i64, 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
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %1) #7
  store i64 0, ptr %1, align 8, !tbaa !5
  %9 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull %1)
  %10 = load i64, ptr %1, align 8, !tbaa !5
  %11 = call noalias noundef nonnull ptr @_Znam(i64 noundef %10) #8
  %12 = icmp ugt i64 %10, 2305843009213693951
  %13 = shl nuw i64 %10, 3
  %14 = select i1 %12, i64 -1, i64 %13
  %15 = call noalias noundef nonnull ptr @_Znam(i64 noundef %14) #8
  %16 = call noalias noundef nonnull ptr @_Znam(i64 noundef %14) #8
  %17 = icmp sgt i64 %10, 0
  br i1 %17, label %.lr.ph.preheader, label %._crit_edge

.lr.ph.preheader:                                 ; preds = %0
  call void @llvm.memset.p0.i64(ptr nonnull align 8 %16, i8 0, i64 %13, i1 false), !tbaa !5
  br label %._crit_edge

._crit_edge:                                      ; preds = %.lr.ph.preheader, %0
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %2) #7
  store i64 0, ptr %2, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %3) #7
  call void @_ZNSt6vectorIlSaIlEEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %3) #7
  %18 = load i64, ptr %1, align 8, !tbaa !5
  %19 = icmp sgt i64 %18, 0
  br i1 %19, label %.lr.ph51, label %._crit_edge54

.preheader:                                       ; preds = %30
  %20 = icmp sgt i64 %31, 0
  %invariant.gep = getelementptr i8, ptr %16, i64 -8
  br i1 %20, label %.lr.ph53, label %._crit_edge54

.lr.ph51:                                         ; preds = %._crit_edge, %30
  %indvars.iv = phi i64 [ %indvars.iv.next, %30 ], [ 0, %._crit_edge ]
  %21 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull %2)
  %22 = load i64, ptr %2, align 8, !tbaa !5
  %23 = icmp ne i64 %22, 0
  %24 = getelementptr inbounds i8, ptr %11, i64 %indvars.iv
  %25 = zext i1 %23 to i8
  store i8 %25, ptr %24, align 1, !tbaa !9
  br i1 %23, label %26, label %30

26:                                               ; preds = %.lr.ph51
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %4) #7
  store i64 %indvars.iv, ptr %4, align 8, !tbaa !5
  invoke void @_ZNSt6vectorIlSaIlEE9push_backEOl(ptr noundef nonnull align 8 dereferenceable(24) %3, ptr noundef nonnull align 8 dereferenceable(8) %4)
          to label %27 unwind label %28

27:                                               ; preds = %26
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %4) #7
  br label %30

28:                                               ; preds = %26
  %29 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %4) #7
  br label %90

30:                                               ; preds = %.lr.ph51, %27
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %31 = load i64, ptr %1, align 8, !tbaa !5
  %32 = icmp sgt i64 %31, %indvars.iv.next
  br i1 %32, label %.lr.ph51, label %.preheader, !llvm.loop !11

._crit_edge54:                                    ; preds = %41, %._crit_edge, %.preheader
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %5) #7
  call void @_ZNSt6vectorIlSaIlEEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %5) #7
  %33 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %3) #7
  %.not = icmp eq i64 %33, 0
  br i1 %.not, label %._crit_edge58, label %.lr.ph57

.lr.ph53:                                         ; preds = %.preheader, %41
  %indvars.iv66 = phi i64 [ %indvars.iv.next67, %41 ], [ 0, %.preheader ]
  %34 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull %2)
  %35 = load i64, ptr %2, align 8, !tbaa !5
  %36 = icmp eq i64 %35, 0
  br i1 %36, label %41, label %37

37:                                               ; preds = %.lr.ph53
  %38 = add nsw i64 %35, -1
  %gep = getelementptr i64, ptr %invariant.gep, i64 %35
  %39 = load i64, ptr %gep, align 8, !tbaa !5
  %40 = add nsw i64 %39, 1
  store i64 %40, ptr %gep, align 8, !tbaa !5
  br label %41

41:                                               ; preds = %.lr.ph53, %37
  %.sink = phi i64 [ %38, %37 ], [ -1, %.lr.ph53 ]
  %42 = getelementptr inbounds i64, ptr %15, i64 %indvars.iv66
  store i64 %.sink, ptr %42, align 8
  %indvars.iv.next67 = add nuw nsw i64 %indvars.iv66, 1
  %43 = load i64, ptr %1, align 8, !tbaa !5
  %44 = icmp sgt i64 %43, %indvars.iv.next67
  br i1 %44, label %.lr.ph53, label %._crit_edge54, !llvm.loop !13

._crit_edge58:                                    ; preds = %81, %._crit_edge54
  %45 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %5) #7
  %46 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.1, i64 noundef %45)
  %47 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %5) #7
  %48 = trunc i64 %47 to i32
  %.059 = add i32 %48, -1
  %49 = icmp sgt i32 %.059, -1
  br i1 %49, label %.lr.ph62.preheader, label %._crit_edge63

.lr.ph62.preheader:                               ; preds = %._crit_edge58
  %50 = zext nneg i32 %.059 to i64
  br label %.lr.ph62

.lr.ph57:                                         ; preds = %._crit_edge54, %81
  %indvars.iv73 = phi i64 [ %indvars.iv.next74, %81 ], [ 0, %._crit_edge54 ]
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %6) #7
  call void @_ZNSt6vectorIlSaIlEEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %6) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %7) #7
  %51 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %3, i64 noundef %indvars.iv73) #7
  %52 = load i64, ptr %51, align 8, !tbaa !5
  store i64 %52, ptr %7, align 8, !tbaa !5
  invoke void @_ZNSt6vectorIlSaIlEE9push_backERKl(ptr noundef nonnull align 8 dereferenceable(24) %6, ptr noundef nonnull align 8 dereferenceable(8) %7)
          to label %.peel.begin unwind label %74

.peel.begin:                                      ; preds = %.lr.ph57
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %8) #7
  %53 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %3, i64 noundef %indvars.iv73) #7
  %.pn.peel = load i64, ptr %53, align 8, !tbaa !5
  %storemerge.in.peel = getelementptr inbounds i64, ptr %15, i64 %.pn.peel
  %storemerge.peel = load i64, ptr %storemerge.in.peel, align 8, !tbaa !5
  store i64 %storemerge.peel, ptr %8, align 8, !tbaa !5
  %54 = icmp sgt i64 %storemerge.peel, -1
  br i1 %54, label %55, label %.critedge

55:                                               ; preds = %.peel.begin
  %56 = getelementptr inbounds i8, ptr %11, i64 %storemerge.peel
  %57 = load i8, ptr %56, align 1, !tbaa !9, !range !14, !noundef !15
  %58 = trunc nuw i8 %57 to i1
  br i1 %58, label %.critedge, label %59

59:                                               ; preds = %55
  %60 = getelementptr inbounds i64, ptr %16, i64 %storemerge.peel
  %61 = load i64, ptr %60, align 8, !tbaa !5
  %62 = icmp slt i64 %61, 2
  br i1 %62, label %63, label %.critedge

63:                                               ; preds = %59
  invoke void @_ZNSt6vectorIlSaIlEE9push_backERKl(ptr noundef nonnull align 8 dereferenceable(24) %6, ptr noundef nonnull align 8 dereferenceable(8) %8)
          to label %.peel.next unwind label %.loopexit.loopexit.split-lp

.peel.next:                                       ; preds = %63, %73
  %.pn = load i64, ptr %8, align 8, !tbaa !5
  %storemerge.in = getelementptr inbounds i64, ptr %15, i64 %.pn
  %storemerge = load i64, ptr %storemerge.in, align 8, !tbaa !5
  store i64 %storemerge, ptr %8, align 8, !tbaa !5
  %64 = icmp sgt i64 %storemerge, -1
  br i1 %64, label %65, label %.critedge

65:                                               ; preds = %.peel.next
  %66 = getelementptr inbounds i8, ptr %11, i64 %storemerge
  %67 = load i8, ptr %66, align 1, !tbaa !9, !range !14, !noundef !15
  %68 = trunc nuw i8 %67 to i1
  br i1 %68, label %.critedge, label %69

69:                                               ; preds = %65
  %70 = getelementptr inbounds i64, ptr %16, i64 %storemerge
  %71 = load i64, ptr %70, align 8, !tbaa !5
  %72 = icmp slt i64 %71, 2
  br i1 %72, label %73, label %.critedge

73:                                               ; preds = %69
  invoke void @_ZNSt6vectorIlSaIlEE9push_backERKl(ptr noundef nonnull align 8 dereferenceable(24) %6, ptr noundef nonnull align 8 dereferenceable(8) %8)
          to label %.peel.next unwind label %.loopexit.loopexit, !llvm.loop !16

74:                                               ; preds = %.lr.ph57
  %75 = landingpad { ptr, i32 }
          cleanup
  br label %84

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

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

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

.loopexit:                                        ; preds = %.loopexit.loopexit, %.loopexit.loopexit.split-lp, %.loopexit.split-lp
  %lpad.phi = phi { ptr, i32 } [ %lpad.loopexit.split-lp, %.loopexit.split-lp ], [ %lpad.loopexit70, %.loopexit.loopexit ], [ %lpad.loopexit.split-lp71, %.loopexit.loopexit.split-lp ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #7
  br label %84

.critedge:                                        ; preds = %65, %.peel.next, %69, %59, %55, %.peel.begin
  %76 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %6) #7
  %77 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %5) #7
  %78 = icmp ugt i64 %76, %77
  br i1 %78, label %79, label %81

79:                                               ; preds = %.critedge
  %80 = invoke noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorIlSaIlEEaSERKS1_(ptr noundef nonnull align 8 dereferenceable(24) %5, ptr noundef nonnull align 8 dereferenceable(24) %6)
          to label %81 unwind label %.loopexit.split-lp

81:                                               ; preds = %79, %.critedge
  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 @_ZNSt6vectorIlSaIlEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %6) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %6) #7
  %indvars.iv.next74 = add nuw nsw i64 %indvars.iv73, 1
  %82 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %3) #7
  %83 = icmp ugt i64 %82, %indvars.iv.next74
  br i1 %83, label %.lr.ph57, label %._crit_edge58, !llvm.loop !18

84:                                               ; preds = %.loopexit, %74
  %.pn44 = phi { ptr, i32 } [ %lpad.phi, %.loopexit ], [ %75, %74 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #7
  call void @_ZNSt6vectorIlSaIlEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %6) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %6) #7
  call void @_ZNSt6vectorIlSaIlEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %5) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %5) #7
  br label %90

._crit_edge63:                                    ; preds = %.lr.ph62, %._crit_edge58
  %85 = call i32 @puts(ptr noundef nonnull dereferenceable(1) @.str.3)
  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) %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

.lr.ph62:                                         ; preds = %.lr.ph62.preheader, %.lr.ph62
  %indvars.iv76 = phi i64 [ %50, %.lr.ph62.preheader ], [ %indvars.iv.next77, %.lr.ph62 ]
  %86 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %5, i64 noundef %indvars.iv76) #7
  %87 = load i64, ptr %86, align 8, !tbaa !5
  %88 = add nsw i64 %87, 1
  %89 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.2, i64 noundef %88)
  %indvars.iv.next77 = add nsw i64 %indvars.iv76, -1
  %.not80 = icmp eq i64 %indvars.iv76, 0
  br i1 %.not80, label %._crit_edge63, label %.lr.ph62, !llvm.loop !19

90:                                               ; preds = %84, %28
  %.pn46 = phi { ptr, i32 } [ %29, %28 ], [ %.pn44, %84 ]
  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 } %.pn46
}

; 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: nobuiltin allocsize(0)
declare noundef nonnull ptr @_Znam(i64 noundef) local_unnamed_addr #3

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

declare i32 @__gxx_personality_v0(...)

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #4 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 #4 align 2

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt6vectorIlSaIlEED2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #4 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: nocallback nofree nounwind willreturn memory(argmem: write)
declare void @llvm.memset.p0.i64(ptr nocapture writeonly, i8, i64, i1 immarg) #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 = { nobuiltin allocsize(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 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 #5 = { 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 nounwind willreturn memory(argmem: write) }
attributes #7 = { nounwind }
attributes #8 = { builtin allocsize(0) }

!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 = !{!10, !10, i64 0}
!10 = !{!"bool", !7, i64 0}
!11 = distinct !{!11, !12}
!12 = !{!"llvm.loop.mustprogress"}
!13 = distinct !{!13, !12}
!14 = !{i8 0, i8 2}
!15 = !{}
!16 = distinct !{!16, !12, !17}
!17 = !{!"llvm.loop.peeled.count", i32 1}
!18 = distinct !{!18, !12}
!19 = distinct !{!19, !12}


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