; LLVM IR from DionysiosB/CodeForces :: 0500-0599 (515B-DrazilAndHisHappyFriends)

; 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::_Bvector_base" }
%"struct.std::_Bvector_base" = type { %"struct.std::_Bvector_base<std::allocator<bool>>::_Bvector_impl" }
%"struct.std::_Bvector_base<std::allocator<bool>>::_Bvector_impl" = type { %"struct.std::_Bvector_base<std::allocator<bool>>::_Bvector_impl_data" }
%"struct.std::_Bvector_base<std::allocator<bool>>::_Bvector_impl_data" = type { %"struct.std::_Bit_iterator", %"struct.std::_Bit_iterator", ptr }
%"struct.std::_Bit_iterator" = type { %"struct.std::_Bit_iterator_base.base", [4 x i8] }
%"struct.std::_Bit_iterator_base.base" = type <{ ptr, i32 }>
%"class.std::allocator.0" = type { i8 }
%"struct.std::_Bit_reference" = type { ptr, i64 }

@.str = external hidden unnamed_addr constant [7 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [4 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 i32, align 4
  %3 = alloca i32, align 4
  %4 = alloca %"class.std::vector", align 8
  %5 = alloca i8, align 1
  %6 = alloca %"class.std::allocator.0", align 1
  %7 = alloca ptr, align 8
  %8 = alloca i32, align 4
  %9 = alloca %"class.std::vector", align 8
  %10 = alloca i8, align 1
  %11 = alloca %"class.std::allocator.0", align 1
  %12 = alloca i32, align 4
  %13 = alloca i32, align 4
  %14 = alloca i32, align 4
  %15 = alloca %"struct.std::_Bit_reference", align 8
  %16 = alloca i32, align 4
  %17 = alloca %"struct.std::_Bit_reference", align 8
  %18 = alloca i64, align 8
  %19 = alloca i64, align 8
  %20 = alloca %"struct.std::_Bit_reference", align 8
  %21 = alloca %"struct.std::_Bit_reference", align 8
  %22 = alloca %"struct.std::_Bit_reference", align 8
  %23 = alloca %"struct.std::_Bit_reference", align 8
  %24 = alloca i32, align 4
  %25 = alloca i32, align 4
  %26 = alloca %"struct.std::_Bit_reference", align 8
  %27 = alloca i32, align 4
  %28 = alloca %"struct.std::_Bit_reference", align 8
  store i32 0, ptr %1, align 4
  call void @llvm.lifetime.start.p0(i64 4, ptr %2) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr %3) #5
  %29 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef %2, ptr noundef %3)
  call void @llvm.lifetime.start.p0(i64 40, ptr %4) #5
  %30 = load i32, ptr %2, align 4, !tbaa !5
  %31 = sext i32 %30 to i64
  call void @llvm.lifetime.start.p0(i64 1, ptr %5) #5
  store i8 0, ptr %5, align 1, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 1, ptr %6) #5
  call void @_ZNSaIbEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %6) #5
  invoke void @_ZNSt6vectorIbSaIbEEC2EmRKbRKS0_(ptr noundef nonnull align 8 dereferenceable(40) %4, i64 noundef %31, ptr noundef nonnull align 1 dereferenceable(1) %5, ptr noundef nonnull align 1 dereferenceable(1) %6)
          to label %32 unwind label %43

32:                                               ; preds = %0
  call void @_ZNSt15__new_allocatorIbED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %6) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr %6) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr %5) #5
  call void @llvm.lifetime.start.p0(i64 40, ptr %9) #5
  %33 = load i32, ptr %3, align 4, !tbaa !5
  %34 = sext i32 %33 to i64
  call void @llvm.lifetime.start.p0(i64 1, ptr %10) #5
  store i8 0, ptr %10, align 1, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 1, ptr %11) #5
  call void @_ZNSaIbEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %11) #5
  invoke void @_ZNSt6vectorIbSaIbEEC2EmRKbRKS0_(ptr noundef nonnull align 8 dereferenceable(40) %9, i64 noundef %34, ptr noundef nonnull align 1 dereferenceable(1) %10, ptr noundef nonnull align 1 dereferenceable(1) %11)
          to label %35 unwind label %47

35:                                               ; preds = %32
  call void @_ZNSt15__new_allocatorIbED2Ev(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 1, ptr %10) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #5
  %36 = invoke i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str.1, ptr noundef %12)
          to label %37 unwind label %51

37:                                               ; preds = %35
  call void @llvm.lifetime.start.p0(i64 4, ptr %14) #5
  store i32 0, ptr %14, align 4, !tbaa !5
  br label %38

38:                                               ; preds = %67, %37
  %39 = load i32, ptr %14, align 4, !tbaa !5
  %40 = load i32, ptr %12, align 4, !tbaa !5
  %41 = icmp slt i32 %39, %40
  br i1 %41, label %55, label %42

42:                                               ; preds = %38
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #5
  br label %79

43:                                               ; preds = %0
  %44 = landingpad { ptr, i32 }
          cleanup
  %45 = extractvalue { ptr, i32 } %44, 0
  store ptr %45, ptr %7, align 8
  %46 = extractvalue { ptr, i32 } %44, 1
  store i32 %46, ptr %8, align 4
  call void @_ZNSt15__new_allocatorIbED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %6) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr %6) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr %5) #5
  br label %277

47:                                               ; preds = %32
  %48 = landingpad { ptr, i32 }
          cleanup
  %49 = extractvalue { ptr, i32 } %48, 0
  store ptr %49, ptr %7, align 8
  %50 = extractvalue { ptr, i32 } %48, 1
  store i32 %50, ptr %8, align 4
  call void @_ZNSt15__new_allocatorIbED2Ev(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 1, ptr %10) #5
  br label %276

51:                                               ; preds = %79, %35
  %52 = landingpad { ptr, i32 }
          cleanup
  %53 = extractvalue { ptr, i32 } %52, 0
  store ptr %53, ptr %7, align 8
  %54 = extractvalue { ptr, i32 } %52, 1
  store i32 %54, ptr %8, align 4
  br label %275

55:                                               ; preds = %38
  %56 = invoke i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str.1, ptr noundef %13)
          to label %57 unwind label %70

57:                                               ; preds = %55
  call void @llvm.lifetime.start.p0(i64 16, ptr %15) #5
  %58 = load i32, ptr %13, align 4, !tbaa !5
  %59 = sext i32 %58 to i64
  %60 = invoke { ptr, i64 } @_ZNSt6vectorIbSaIbEEixEm(ptr noundef nonnull align 8 dereferenceable(40) %4, i64 noundef %59)
          to label %61 unwind label %74

61:                                               ; preds = %57
  %62 = getelementptr inbounds { ptr, i64 }, ptr %15, i32 0, i32 0
  %63 = extractvalue { ptr, i64 } %60, 0
  store ptr %63, ptr %62, align 8
  %64 = getelementptr inbounds { ptr, i64 }, ptr %15, i32 0, i32 1
  %65 = extractvalue { ptr, i64 } %60, 1
  store i64 %65, ptr %64, align 8
  %66 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt14_Bit_referenceaSEb(ptr noundef nonnull align 8 dereferenceable(16) %15, i1 noundef zeroext true) #5
  call void @llvm.lifetime.end.p0(i64 16, ptr %15) #5
  br label %67

67:                                               ; preds = %61
  %68 = load i32, ptr %14, align 4, !tbaa !5
  %69 = add nsw i32 %68, 1
  store i32 %69, ptr %14, align 4, !tbaa !5
  br label %38, !llvm.loop !11

70:                                               ; preds = %55
  %71 = landingpad { ptr, i32 }
          cleanup
  %72 = extractvalue { ptr, i32 } %71, 0
  store ptr %72, ptr %7, align 8
  %73 = extractvalue { ptr, i32 } %71, 1
  store i32 %73, ptr %8, align 4
  br label %78

74:                                               ; preds = %57
  %75 = landingpad { ptr, i32 }
          cleanup
  %76 = extractvalue { ptr, i32 } %75, 0
  store ptr %76, ptr %7, align 8
  %77 = extractvalue { ptr, i32 } %75, 1
  store i32 %77, ptr %8, align 4
  call void @llvm.lifetime.end.p0(i64 16, ptr %15) #5
  br label %78

78:                                               ; preds = %74, %70
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #5
  br label %275

79:                                               ; preds = %42
  %80 = invoke i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str.1, ptr noundef %12)
          to label %81 unwind label %51

81:                                               ; preds = %79
  call void @llvm.lifetime.start.p0(i64 4, ptr %16) #5
  store i32 0, ptr %16, align 4, !tbaa !5
  br label %82

82:                                               ; preds = %99, %81
  %83 = load i32, ptr %16, align 4, !tbaa !5
  %84 = load i32, ptr %12, align 4, !tbaa !5
  %85 = icmp slt i32 %83, %84
  br i1 %85, label %87, label %86

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

87:                                               ; preds = %82
  %88 = invoke i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str.1, ptr noundef %13)
          to label %89 unwind label %102

89:                                               ; preds = %87
  call void @llvm.lifetime.start.p0(i64 16, ptr %17) #5
  %90 = load i32, ptr %13, align 4, !tbaa !5
  %91 = sext i32 %90 to i64
  %92 = invoke { ptr, i64 } @_ZNSt6vectorIbSaIbEEixEm(ptr noundef nonnull align 8 dereferenceable(40) %9, i64 noundef %91)
          to label %93 unwind label %106

93:                                               ; preds = %89
  %94 = getelementptr inbounds { ptr, i64 }, ptr %17, i32 0, i32 0
  %95 = extractvalue { ptr, i64 } %92, 0
  store ptr %95, ptr %94, align 8
  %96 = getelementptr inbounds { ptr, i64 }, ptr %17, i32 0, i32 1
  %97 = extractvalue { ptr, i64 } %92, 1
  store i64 %97, ptr %96, align 8
  %98 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt14_Bit_referenceaSEb(ptr noundef nonnull align 8 dereferenceable(16) %17, i1 noundef zeroext true) #5
  call void @llvm.lifetime.end.p0(i64 16, ptr %17) #5
  br label %99

99:                                               ; preds = %93
  %100 = load i32, ptr %16, align 4, !tbaa !5
  %101 = add nsw i32 %100, 1
  store i32 %101, ptr %16, align 4, !tbaa !5
  br label %82, !llvm.loop !13

102:                                              ; preds = %87
  %103 = landingpad { ptr, i32 }
          cleanup
  %104 = extractvalue { ptr, i32 } %103, 0
  store ptr %104, ptr %7, align 8
  %105 = extractvalue { ptr, i32 } %103, 1
  store i32 %105, ptr %8, align 4
  br label %110

106:                                              ; preds = %89
  %107 = landingpad { ptr, i32 }
          cleanup
  %108 = extractvalue { ptr, i32 } %107, 0
  store ptr %108, ptr %7, align 8
  %109 = extractvalue { ptr, i32 } %107, 1
  store i32 %109, ptr %8, align 4
  call void @llvm.lifetime.end.p0(i64 16, ptr %17) #5
  br label %110

110:                                              ; preds = %106, %102
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #5
  br label %275

111:                                              ; preds = %86
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #5
  store i64 0, ptr %18, align 8, !tbaa !14
  call void @llvm.lifetime.start.p0(i64 8, ptr %19) #5
  store i64 0, ptr %19, align 8, !tbaa !14
  br label %112

112:                                              ; preds = %173, %111
  %113 = load i64, ptr %19, align 8, !tbaa !14
  %114 = load i32, ptr %3, align 4, !tbaa !5
  %115 = load i32, ptr %3, align 4, !tbaa !5
  %116 = mul nsw i32 %114, %115
  %117 = load i32, ptr %2, align 4, !tbaa !5
  %118 = mul nsw i32 %116, %117
  %119 = load i32, ptr %2, align 4, !tbaa !5
  %120 = mul nsw i32 %118, %119
  %121 = sext i32 %120 to i64
  %122 = icmp slt i64 %113, %121
  br i1 %122, label %124, label %123

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

124:                                              ; preds = %112
  call void @llvm.lifetime.start.p0(i64 16, ptr %20) #5
  %125 = load i64, ptr %19, align 8, !tbaa !14
  %126 = load i32, ptr %2, align 4, !tbaa !5
  %127 = sext i32 %126 to i64
  %128 = srem i64 %125, %127
  %129 = invoke { ptr, i64 } @_ZNSt6vectorIbSaIbEEixEm(ptr noundef nonnull align 8 dereferenceable(40) %4, i64 noundef %128)
          to label %130 unwind label %176

130:                                              ; preds = %124
  %131 = getelementptr inbounds { ptr, i64 }, ptr %20, i32 0, i32 0
  %132 = extractvalue { ptr, i64 } %129, 0
  store ptr %132, ptr %131, align 8
  %133 = getelementptr inbounds { ptr, i64 }, ptr %20, i32 0, i32 1
  %134 = extractvalue { ptr, i64 } %129, 1
  store i64 %134, ptr %133, align 8
  %135 = call noundef zeroext i1 @_ZNKSt14_Bit_referencecvbEv(ptr noundef nonnull align 8 dereferenceable(16) %20) #5
  %136 = zext i1 %135 to i32
  call void @llvm.lifetime.start.p0(i64 16, ptr %21) #5
  %137 = load i64, ptr %19, align 8, !tbaa !14
  %138 = load i32, ptr %3, align 4, !tbaa !5
  %139 = sext i32 %138 to i64
  %140 = srem i64 %137, %139
  %141 = invoke { ptr, i64 } @_ZNSt6vectorIbSaIbEEixEm(ptr noundef nonnull align 8 dereferenceable(40) %9, i64 noundef %140)
          to label %142 unwind label %180

142:                                              ; preds = %130
  %143 = getelementptr inbounds { ptr, i64 }, ptr %21, i32 0, i32 0
  %144 = extractvalue { ptr, i64 } %141, 0
  store ptr %144, ptr %143, align 8
  %145 = getelementptr inbounds { ptr, i64 }, ptr %21, i32 0, i32 1
  %146 = extractvalue { ptr, i64 } %141, 1
  store i64 %146, ptr %145, align 8
  %147 = call noundef zeroext i1 @_ZNKSt14_Bit_referencecvbEv(ptr noundef nonnull align 8 dereferenceable(16) %21) #5
  %148 = zext i1 %147 to i32
  %149 = or i32 %136, %148
  %150 = icmp ne i32 %149, 0
  call void @llvm.lifetime.start.p0(i64 16, ptr %22) #5
  %151 = load i64, ptr %19, align 8, !tbaa !14
  %152 = load i32, ptr %3, align 4, !tbaa !5
  %153 = sext i32 %152 to i64
  %154 = srem i64 %151, %153
  %155 = invoke { ptr, i64 } @_ZNSt6vectorIbSaIbEEixEm(ptr noundef nonnull align 8 dereferenceable(40) %9, i64 noundef %154)
          to label %156 unwind label %184

156:                                              ; preds = %142
  %157 = getelementptr inbounds { ptr, i64 }, ptr %22, i32 0, i32 0
  %158 = extractvalue { ptr, i64 } %155, 0
  store ptr %158, ptr %157, align 8
  %159 = getelementptr inbounds { ptr, i64 }, ptr %22, i32 0, i32 1
  %160 = extractvalue { ptr, i64 } %155, 1
  store i64 %160, ptr %159, align 8
  %161 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt14_Bit_referenceaSEb(ptr noundef nonnull align 8 dereferenceable(16) %22, i1 noundef zeroext %150) #5
  call void @llvm.lifetime.start.p0(i64 16, ptr %23) #5
  %162 = load i64, ptr %19, align 8, !tbaa !14
  %163 = load i32, ptr %2, align 4, !tbaa !5
  %164 = sext i32 %163 to i64
  %165 = srem i64 %162, %164
  %166 = invoke { ptr, i64 } @_ZNSt6vectorIbSaIbEEixEm(ptr noundef nonnull align 8 dereferenceable(40) %4, i64 noundef %165)
          to label %167 unwind label %188

167:                                              ; preds = %156
  %168 = getelementptr inbounds { ptr, i64 }, ptr %23, i32 0, i32 0
  %169 = extractvalue { ptr, i64 } %166, 0
  store ptr %169, ptr %168, align 8
  %170 = getelementptr inbounds { ptr, i64 }, ptr %23, i32 0, i32 1
  %171 = extractvalue { ptr, i64 } %166, 1
  store i64 %171, ptr %170, align 8
  %172 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt14_Bit_referenceaSERKS_(ptr noundef nonnull align 8 dereferenceable(16) %23, ptr noundef nonnull align 8 dereferenceable(16) %161) #5
  call void @llvm.lifetime.end.p0(i64 16, ptr %23) #5
  call void @llvm.lifetime.end.p0(i64 16, ptr %22) #5
  call void @llvm.lifetime.end.p0(i64 16, ptr %21) #5
  call void @llvm.lifetime.end.p0(i64 16, ptr %20) #5
  br label %173

173:                                              ; preds = %167
  %174 = load i64, ptr %19, align 8, !tbaa !14
  %175 = add nsw i64 %174, 1
  store i64 %175, ptr %19, align 8, !tbaa !14
  br label %112, !llvm.loop !16

176:                                              ; preds = %124
  %177 = landingpad { ptr, i32 }
          cleanup
  %178 = extractvalue { ptr, i32 } %177, 0
  store ptr %178, ptr %7, align 8
  %179 = extractvalue { ptr, i32 } %177, 1
  store i32 %179, ptr %8, align 4
  br label %194

180:                                              ; preds = %130
  %181 = landingpad { ptr, i32 }
          cleanup
  %182 = extractvalue { ptr, i32 } %181, 0
  store ptr %182, ptr %7, align 8
  %183 = extractvalue { ptr, i32 } %181, 1
  store i32 %183, ptr %8, align 4
  br label %193

184:                                              ; preds = %142
  %185 = landingpad { ptr, i32 }
          cleanup
  %186 = extractvalue { ptr, i32 } %185, 0
  store ptr %186, ptr %7, align 8
  %187 = extractvalue { ptr, i32 } %185, 1
  store i32 %187, ptr %8, align 4
  br label %192

188:                                              ; preds = %156
  %189 = landingpad { ptr, i32 }
          cleanup
  %190 = extractvalue { ptr, i32 } %189, 0
  store ptr %190, ptr %7, align 8
  %191 = extractvalue { ptr, i32 } %189, 1
  store i32 %191, ptr %8, align 4
  call void @llvm.lifetime.end.p0(i64 16, ptr %23) #5
  br label %192

192:                                              ; preds = %188, %184
  call void @llvm.lifetime.end.p0(i64 16, ptr %22) #5
  br label %193

193:                                              ; preds = %192, %180
  call void @llvm.lifetime.end.p0(i64 16, ptr %21) #5
  br label %194

194:                                              ; preds = %193, %176
  call void @llvm.lifetime.end.p0(i64 16, ptr %20) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #5
  br label %274

195:                                              ; preds = %123
  call void @llvm.lifetime.start.p0(i64 4, ptr %24) #5
  store i32 0, ptr %24, align 4, !tbaa !5
  br label %196

196:                                              ; preds = %224, %195
  %197 = load i32, ptr %24, align 4, !tbaa !5
  %198 = load i32, ptr %2, align 4, !tbaa !5
  %199 = icmp slt i32 %197, %198
  br i1 %199, label %201, label %200

200:                                              ; preds = %196
  store i32 11, ptr %25, align 4
  br label %227

201:                                              ; preds = %196
  call void @llvm.lifetime.start.p0(i64 16, ptr %26) #5
  %202 = load i32, ptr %24, align 4, !tbaa !5
  %203 = sext i32 %202 to i64
  %204 = invoke { ptr, i64 } @_ZNSt6vectorIbSaIbEEixEm(ptr noundef nonnull align 8 dereferenceable(40) %4, i64 noundef %203)
          to label %205 unwind label %215

205:                                              ; preds = %201
  %206 = getelementptr inbounds { ptr, i64 }, ptr %26, i32 0, i32 0
  %207 = extractvalue { ptr, i64 } %204, 0
  store ptr %207, ptr %206, align 8
  %208 = getelementptr inbounds { ptr, i64 }, ptr %26, i32 0, i32 1
  %209 = extractvalue { ptr, i64 } %204, 1
  store i64 %209, ptr %208, align 8
  %210 = call noundef zeroext i1 @_ZNKSt14_Bit_referencecvbEv(ptr noundef nonnull align 8 dereferenceable(16) %26) #5
  %211 = xor i1 %210, true
  call void @llvm.lifetime.end.p0(i64 16, ptr %26) #5
  br i1 %211, label %212, label %223

212:                                              ; preds = %205
  %213 = invoke i32 @puts(ptr noundef @.str.2)
          to label %214 unwind label %219

214:                                              ; preds = %212
  store i32 0, ptr %1, align 4
  store i32 1, ptr %25, align 4
  br label %227

215:                                              ; preds = %201
  %216 = landingpad { ptr, i32 }
          cleanup
  %217 = extractvalue { ptr, i32 } %216, 0
  store ptr %217, ptr %7, align 8
  %218 = extractvalue { ptr, i32 } %216, 1
  store i32 %218, ptr %8, align 4
  call void @llvm.lifetime.end.p0(i64 16, ptr %26) #5
  br label %229

219:                                              ; preds = %212
  %220 = landingpad { ptr, i32 }
          cleanup
  %221 = extractvalue { ptr, i32 } %220, 0
  store ptr %221, ptr %7, align 8
  %222 = extractvalue { ptr, i32 } %220, 1
  store i32 %222, ptr %8, align 4
  br label %229

223:                                              ; preds = %205
  br label %224

224:                                              ; preds = %223
  %225 = load i32, ptr %24, align 4, !tbaa !5
  %226 = add nsw i32 %225, 1
  store i32 %226, ptr %24, align 4, !tbaa !5
  br label %196, !llvm.loop !17

227:                                              ; preds = %214, %200
  call void @llvm.lifetime.end.p0(i64 4, ptr %24) #5
  %228 = load i32, ptr %25, align 4
  switch i32 %228, label %272 [
    i32 11, label %230
  ]

229:                                              ; preds = %219, %215
  call void @llvm.lifetime.end.p0(i64 4, ptr %24) #5
  br label %274

230:                                              ; preds = %227
  call void @llvm.lifetime.start.p0(i64 4, ptr %27) #5
  store i32 0, ptr %27, align 4, !tbaa !5
  br label %231

231:                                              ; preds = %259, %230
  %232 = load i32, ptr %27, align 4, !tbaa !5
  %233 = load i32, ptr %3, align 4, !tbaa !5
  %234 = icmp slt i32 %232, %233
  br i1 %234, label %236, label %235

235:                                              ; preds = %231
  store i32 14, ptr %25, align 4
  br label %262

236:                                              ; preds = %231
  call void @llvm.lifetime.start.p0(i64 16, ptr %28) #5
  %237 = load i32, ptr %27, align 4, !tbaa !5
  %238 = sext i32 %237 to i64
  %239 = invoke { ptr, i64 } @_ZNSt6vectorIbSaIbEEixEm(ptr noundef nonnull align 8 dereferenceable(40) %9, i64 noundef %238)
          to label %240 unwind label %250

240:                                              ; preds = %236
  %241 = getelementptr inbounds { ptr, i64 }, ptr %28, i32 0, i32 0
  %242 = extractvalue { ptr, i64 } %239, 0
  store ptr %242, ptr %241, align 8
  %243 = getelementptr inbounds { ptr, i64 }, ptr %28, i32 0, i32 1
  %244 = extractvalue { ptr, i64 } %239, 1
  store i64 %244, ptr %243, align 8
  %245 = call noundef zeroext i1 @_ZNKSt14_Bit_referencecvbEv(ptr noundef nonnull align 8 dereferenceable(16) %28) #5
  %246 = xor i1 %245, true
  call void @llvm.lifetime.end.p0(i64 16, ptr %28) #5
  br i1 %246, label %247, label %258

247:                                              ; preds = %240
  %248 = invoke i32 @puts(ptr noundef @.str.2)
          to label %249 unwind label %254

249:                                              ; preds = %247
  store i32 0, ptr %1, align 4
  store i32 1, ptr %25, align 4
  br label %262

250:                                              ; preds = %236
  %251 = landingpad { ptr, i32 }
          cleanup
  %252 = extractvalue { ptr, i32 } %251, 0
  store ptr %252, ptr %7, align 8
  %253 = extractvalue { ptr, i32 } %251, 1
  store i32 %253, ptr %8, align 4
  call void @llvm.lifetime.end.p0(i64 16, ptr %28) #5
  br label %264

254:                                              ; preds = %247
  %255 = landingpad { ptr, i32 }
          cleanup
  %256 = extractvalue { ptr, i32 } %255, 0
  store ptr %256, ptr %7, align 8
  %257 = extractvalue { ptr, i32 } %255, 1
  store i32 %257, ptr %8, align 4
  br label %264

258:                                              ; preds = %240
  br label %259

259:                                              ; preds = %258
  %260 = load i32, ptr %27, align 4, !tbaa !5
  %261 = add nsw i32 %260, 1
  store i32 %261, ptr %27, align 4, !tbaa !5
  br label %231, !llvm.loop !18

262:                                              ; preds = %249, %235
  call void @llvm.lifetime.end.p0(i64 4, ptr %27) #5
  %263 = load i32, ptr %25, align 4
  switch i32 %263, label %272 [
    i32 14, label %265
  ]

264:                                              ; preds = %254, %250
  call void @llvm.lifetime.end.p0(i64 4, ptr %27) #5
  br label %274

265:                                              ; preds = %262
  %266 = invoke i32 @puts(ptr noundef @.str.3)
          to label %267 unwind label %268

267:                                              ; preds = %265
  store i32 0, ptr %1, align 4
  store i32 1, ptr %25, align 4
  br label %272

268:                                              ; preds = %265
  %269 = landingpad { ptr, i32 }
          cleanup
  %270 = extractvalue { ptr, i32 } %269, 0
  store ptr %270, ptr %7, align 8
  %271 = extractvalue { ptr, i32 } %269, 1
  store i32 %271, ptr %8, align 4
  br label %274

272:                                              ; preds = %267, %262, %227
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #5
  call void @_ZNSt13_Bvector_baseISaIbEED2Ev(ptr noundef nonnull align 8 dereferenceable(40) %9) #5
  call void @llvm.lifetime.end.p0(i64 40, ptr %9) #5
  call void @_ZNSt13_Bvector_baseISaIbEED2Ev(ptr noundef nonnull align 8 dereferenceable(40) %4) #5
  call void @llvm.lifetime.end.p0(i64 40, ptr %4) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %3) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %2) #5
  %273 = load i32, ptr %1, align 4
  ret i32 %273

274:                                              ; preds = %268, %264, %229, %194
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #5
  br label %275

275:                                              ; preds = %274, %110, %78, %51
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #5
  call void @_ZNSt13_Bvector_baseISaIbEED2Ev(ptr noundef nonnull align 8 dereferenceable(40) %9) #5
  br label %276

276:                                              ; preds = %275, %47
  call void @llvm.lifetime.end.p0(i64 40, ptr %9) #5
  call void @_ZNSt13_Bvector_baseISaIbEED2Ev(ptr noundef nonnull align 8 dereferenceable(40) %4) #5
  br label %277

277:                                              ; preds = %276, %43
  call void @llvm.lifetime.end.p0(i64 40, ptr %4) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %3) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %2) #5
  br label %278

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

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

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

declare i32 @__gxx_personality_v0(...)

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

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

; Function Attrs: mustprogress uwtable
declare dso_local { ptr, i64 } @_ZNSt6vectorIbSaIbEEixEm(ptr noundef nonnull align 8 dereferenceable(40), i64 noundef) #4 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt14_Bit_referenceaSEb(ptr noundef nonnull align 8 dereferenceable(16), i1 noundef zeroext) #3 align 2

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

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

declare i32 @puts(ptr noundef) #2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt13_Bvector_baseISaIbEED2Ev(ptr noundef nonnull align 8 dereferenceable(40)) 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 = !{!"int", !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 = !{!15, !15, i64 0}
!15 = !{!"long", !7, i64 0}
!16 = distinct !{!16, !12}
!17 = distinct !{!17, !12}
!18 = distinct !{!18, !12}


; Optimized IR (opt -passes='default<O3>'):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

%"class.std::vector" = type { %"struct.std::_Bvector_base" }
%"struct.std::_Bvector_base" = type { %"struct.std::_Bvector_base<std::allocator<bool>>::_Bvector_impl" }
%"struct.std::_Bvector_base<std::allocator<bool>>::_Bvector_impl" = type { %"struct.std::_Bvector_base<std::allocator<bool>>::_Bvector_impl_data" }
%"struct.std::_Bvector_base<std::allocator<bool>>::_Bvector_impl_data" = type { %"struct.std::_Bit_iterator", %"struct.std::_Bit_iterator", ptr }
%"struct.std::_Bit_iterator" = type { %"struct.std::_Bit_iterator_base.base", [4 x i8] }
%"struct.std::_Bit_iterator_base.base" = type <{ ptr, i32 }>
%"class.std::allocator.0" = type { i8 }
%"struct.std::_Bit_reference" = type { ptr, i64 }

@.str = external hidden unnamed_addr constant [7 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [4 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 i32, align 4
  %2 = alloca i32, align 4
  %3 = alloca %"class.std::vector", align 8
  %4 = alloca i8, align 1
  %5 = alloca %"class.std::allocator.0", align 1
  %6 = alloca %"class.std::vector", align 8
  %7 = alloca i8, align 1
  %8 = alloca %"class.std::allocator.0", align 1
  %9 = alloca i32, align 4
  %10 = alloca i32, align 4
  %11 = alloca %"struct.std::_Bit_reference", align 8
  %12 = alloca %"struct.std::_Bit_reference", align 8
  %13 = alloca %"struct.std::_Bit_reference", align 8
  %14 = alloca %"struct.std::_Bit_reference", align 8
  %15 = alloca %"struct.std::_Bit_reference", align 8
  %16 = alloca %"struct.std::_Bit_reference", align 8
  %17 = alloca %"struct.std::_Bit_reference", align 8
  %18 = alloca %"struct.std::_Bit_reference", align 8
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %1) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %2) #5
  %19 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull %1, ptr noundef nonnull %2)
  call void @llvm.lifetime.start.p0(i64 40, ptr nonnull %3) #5
  %20 = load i32, ptr %1, align 4, !tbaa !5
  %21 = sext i32 %20 to i64
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %4) #5
  store i8 0, ptr %4, align 1, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %5) #5
  call void @_ZNSaIbEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %5) #5
  invoke void @_ZNSt6vectorIbSaIbEEC2EmRKbRKS0_(ptr noundef nonnull align 8 dereferenceable(40) %3, i64 noundef %21, ptr noundef nonnull align 1 dereferenceable(1) %4, ptr noundef nonnull align 1 dereferenceable(1) %5)
          to label %22 unwind label %34

22:                                               ; preds = %0
  call void @_ZNSt15__new_allocatorIbED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %5) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %5) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %4) #5
  call void @llvm.lifetime.start.p0(i64 40, ptr nonnull %6) #5
  %23 = load i32, ptr %2, align 4, !tbaa !5
  %24 = sext i32 %23 to i64
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %7) #5
  store i8 0, ptr %7, align 1, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %8) #5
  call void @_ZNSaIbEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %8) #5
  invoke void @_ZNSt6vectorIbSaIbEEC2EmRKbRKS0_(ptr noundef nonnull align 8 dereferenceable(40) %6, i64 noundef %24, ptr noundef nonnull align 1 dereferenceable(1) %7, ptr noundef nonnull align 1 dereferenceable(1) %8)
          to label %25 unwind label %36

25:                                               ; preds = %22
  call void @_ZNSt15__new_allocatorIbED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %8) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %8) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %7) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %9) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %10) #5
  %26 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str.1, ptr noundef nonnull %9)
  %27 = load i32, ptr %9, align 4, !tbaa !5
  %28 = icmp sgt i32 %27, 0
  br i1 %28, label %.lr.ph, label %._crit_edge

.lr.ph:                                           ; preds = %25
  %29 = getelementptr inbounds i8, ptr %11, i64 8
  br label %38

._crit_edge:                                      ; preds = %43, %25
  %30 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str.1, ptr noundef nonnull %9)
  %31 = load i32, ptr %9, align 4, !tbaa !5
  %32 = icmp sgt i32 %31, 0
  br i1 %32, label %.lr.ph53, label %.preheader49

.lr.ph53:                                         ; preds = %._crit_edge
  %33 = getelementptr inbounds i8, ptr %12, i64 8
  br label %61

34:                                               ; preds = %0
  %35 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt15__new_allocatorIbED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %5) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %5) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %4) #5
  br label %156

36:                                               ; preds = %22
  %37 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt15__new_allocatorIbED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %8) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %8) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %7) #5
  br label %155

38:                                               ; preds = %.lr.ph, %43
  %.02750 = phi i32 [ 0, %.lr.ph ], [ %47, %43 ]
  %39 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str.1, ptr noundef nonnull %10)
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %11) #5
  %40 = load i32, ptr %10, align 4, !tbaa !5
  %41 = sext i32 %40 to i64
  %42 = invoke { ptr, i64 } @_ZNSt6vectorIbSaIbEEixEm(ptr noundef nonnull align 8 dereferenceable(40) %3, i64 noundef %41)
          to label %43 unwind label %50

43:                                               ; preds = %38
  %44 = extractvalue { ptr, i64 } %42, 0
  store ptr %44, ptr %11, align 8
  %45 = extractvalue { ptr, i64 } %42, 1
  store i64 %45, ptr %29, align 8
  %46 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt14_Bit_referenceaSEb(ptr noundef nonnull align 8 dereferenceable(16) %11, i1 noundef zeroext true) #5
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %11) #5
  %47 = add nuw nsw i32 %.02750, 1
  %48 = load i32, ptr %9, align 4, !tbaa !5
  %49 = icmp slt i32 %47, %48
  br i1 %49, label %38, label %._crit_edge, !llvm.loop !11

50:                                               ; preds = %38
  %51 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %11) #5
  br label %154

.preheader49:                                     ; preds = %66, %._crit_edge
  %52 = load i32, ptr %2, align 4, !tbaa !5
  %53 = load i32, ptr %1, align 4, !tbaa !5
  %54 = mul i32 %53, %52
  %55 = mul i32 %54, %54
  %56 = icmp sgt i32 %55, 0
  br i1 %56, label %.lr.ph55, label %.preheader

.lr.ph55:                                         ; preds = %.preheader49
  %57 = getelementptr inbounds i8, ptr %13, i64 8
  %58 = getelementptr inbounds i8, ptr %14, i64 8
  %59 = getelementptr inbounds i8, ptr %15, i64 8
  %60 = getelementptr inbounds i8, ptr %16, i64 8
  br label %78

61:                                               ; preds = %.lr.ph53, %66
  %.02651 = phi i32 [ 0, %.lr.ph53 ], [ %70, %66 ]
  %62 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str.1, ptr noundef nonnull %10)
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %12) #5
  %63 = load i32, ptr %10, align 4, !tbaa !5
  %64 = sext i32 %63 to i64
  %65 = invoke { ptr, i64 } @_ZNSt6vectorIbSaIbEEixEm(ptr noundef nonnull align 8 dereferenceable(40) %6, i64 noundef %64)
          to label %66 unwind label %73

66:                                               ; preds = %61
  %67 = extractvalue { ptr, i64 } %65, 0
  store ptr %67, ptr %12, align 8
  %68 = extractvalue { ptr, i64 } %65, 1
  store i64 %68, ptr %33, align 8
  %69 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt14_Bit_referenceaSEb(ptr noundef nonnull align 8 dereferenceable(16) %12, i1 noundef zeroext true) #5
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %12) #5
  %70 = add nuw nsw i32 %.02651, 1
  %71 = load i32, ptr %9, align 4, !tbaa !5
  %72 = icmp slt i32 %70, %71
  br i1 %72, label %61, label %.preheader49, !llvm.loop !13

73:                                               ; preds = %61
  %74 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %12) #5
  br label %154

.preheader:                                       ; preds = %108, %.preheader49
  %75 = phi i32 [ %52, %.preheader49 ], [ %113, %108 ]
  %76 = phi i32 [ %53, %.preheader49 ], [ %114, %108 ]
  %.not56 = icmp sgt i32 %76, 0
  br i1 %.not56, label %.lr.ph58, label %.critedge.preheader

.lr.ph58:                                         ; preds = %.preheader
  %77 = getelementptr inbounds i8, ptr %17, i64 8
  br label %135

78:                                               ; preds = %.lr.ph55, %108
  %79 = phi i32 [ %53, %.lr.ph55 ], [ %114, %108 ]
  %.02354 = phi i64 [ 0, %.lr.ph55 ], [ %112, %108 ]
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %13) #5
  %80 = sext i32 %79 to i64
  %81 = srem i64 %.02354, %80
  %82 = invoke { ptr, i64 } @_ZNSt6vectorIbSaIbEEixEm(ptr noundef nonnull align 8 dereferenceable(40) %3, i64 noundef %81)
          to label %83 unwind label %119

83:                                               ; preds = %78
  %84 = extractvalue { ptr, i64 } %82, 0
  store ptr %84, ptr %13, align 8
  %85 = extractvalue { ptr, i64 } %82, 1
  store i64 %85, ptr %57, align 8
  %86 = call noundef zeroext i1 @_ZNKSt14_Bit_referencecvbEv(ptr noundef nonnull align 8 dereferenceable(16) %13) #5
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %14) #5
  %87 = load i32, ptr %2, align 4, !tbaa !5
  %88 = sext i32 %87 to i64
  %89 = srem i64 %.02354, %88
  %90 = invoke { ptr, i64 } @_ZNSt6vectorIbSaIbEEixEm(ptr noundef nonnull align 8 dereferenceable(40) %6, i64 noundef %89)
          to label %91 unwind label %121

91:                                               ; preds = %83
  %92 = extractvalue { ptr, i64 } %90, 0
  store ptr %92, ptr %14, align 8
  %93 = extractvalue { ptr, i64 } %90, 1
  store i64 %93, ptr %58, align 8
  %94 = call noundef zeroext i1 @_ZNKSt14_Bit_referencecvbEv(ptr noundef nonnull align 8 dereferenceable(16) %14) #5
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %15) #5
  %95 = load i32, ptr %2, align 4, !tbaa !5
  %96 = sext i32 %95 to i64
  %97 = srem i64 %.02354, %96
  %98 = invoke { ptr, i64 } @_ZNSt6vectorIbSaIbEEixEm(ptr noundef nonnull align 8 dereferenceable(40) %6, i64 noundef %97)
          to label %99 unwind label %123

99:                                               ; preds = %91
  %100 = or i1 %86, %94
  %101 = extractvalue { ptr, i64 } %98, 0
  store ptr %101, ptr %15, align 8
  %102 = extractvalue { ptr, i64 } %98, 1
  store i64 %102, ptr %59, align 8
  %103 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt14_Bit_referenceaSEb(ptr noundef nonnull align 8 dereferenceable(16) %15, i1 noundef zeroext %100) #5
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %16) #5
  %104 = load i32, ptr %1, align 4, !tbaa !5
  %105 = sext i32 %104 to i64
  %106 = srem i64 %.02354, %105
  %107 = invoke { ptr, i64 } @_ZNSt6vectorIbSaIbEEixEm(ptr noundef nonnull align 8 dereferenceable(40) %3, i64 noundef %106)
          to label %108 unwind label %125

108:                                              ; preds = %99
  %109 = extractvalue { ptr, i64 } %107, 0
  store ptr %109, ptr %16, align 8
  %110 = extractvalue { ptr, i64 } %107, 1
  store i64 %110, ptr %60, align 8
  %111 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt14_Bit_referenceaSERKS_(ptr noundef nonnull align 8 dereferenceable(16) %16, ptr noundef nonnull align 8 dereferenceable(16) %103) #5
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %16) #5
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %15) #5
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %14) #5
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %13) #5
  %112 = add nuw nsw i64 %.02354, 1
  %113 = load i32, ptr %2, align 4, !tbaa !5
  %114 = load i32, ptr %1, align 4, !tbaa !5
  %115 = mul i32 %114, %113
  %116 = mul i32 %115, %115
  %117 = sext i32 %116 to i64
  %118 = icmp slt i64 %112, %117
  br i1 %118, label %78, label %.preheader, !llvm.loop !14

119:                                              ; preds = %78
  %120 = landingpad { ptr, i32 }
          cleanup
  br label %129

121:                                              ; preds = %83
  %122 = landingpad { ptr, i32 }
          cleanup
  br label %128

123:                                              ; preds = %91
  %124 = landingpad { ptr, i32 }
          cleanup
  br label %127

125:                                              ; preds = %99
  %126 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %16) #5
  br label %127

127:                                              ; preds = %125, %123
  %.pn = phi { ptr, i32 } [ %126, %125 ], [ %124, %123 ]
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %15) #5
  br label %128

128:                                              ; preds = %127, %121
  %.pn.pn = phi { ptr, i32 } [ %.pn, %127 ], [ %122, %121 ]
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %14) #5
  br label %129

129:                                              ; preds = %128, %119
  %.pn.pn.pn = phi { ptr, i32 } [ %.pn.pn, %128 ], [ %120, %119 ]
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %13) #5
  br label %154

130:                                              ; preds = %137
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %131 = load i32, ptr %1, align 4, !tbaa !5
  %132 = sext i32 %131 to i64
  %.not = icmp slt i64 %indvars.iv.next, %132
  br i1 %.not, label %135, label %.critedge.preheader.loopexit, !llvm.loop !15

.critedge.preheader.loopexit:                     ; preds = %130
  %.pre = load i32, ptr %2, align 4, !tbaa !5
  br label %.critedge.preheader

.critedge.preheader:                              ; preds = %.critedge.preheader.loopexit, %.preheader
  %133 = phi i32 [ %.pre, %.critedge.preheader.loopexit ], [ %75, %.preheader ]
  %.not3859 = icmp sgt i32 %133, 0
  br i1 %.not3859, label %.lr.ph61, label %.critedge48

.lr.ph61:                                         ; preds = %.critedge.preheader
  %134 = getelementptr inbounds i8, ptr %18, i64 8
  br label %145

135:                                              ; preds = %.lr.ph58, %130
  %indvars.iv = phi i64 [ 0, %.lr.ph58 ], [ %indvars.iv.next, %130 ]
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %17) #5
  %136 = invoke { ptr, i64 } @_ZNSt6vectorIbSaIbEEixEm(ptr noundef nonnull align 8 dereferenceable(40) %3, i64 noundef %indvars.iv)
          to label %137 unwind label %141

137:                                              ; preds = %135
  %138 = extractvalue { ptr, i64 } %136, 0
  store ptr %138, ptr %17, align 8
  %139 = extractvalue { ptr, i64 } %136, 1
  store i64 %139, ptr %77, align 8
  %140 = call noundef zeroext i1 @_ZNKSt14_Bit_referencecvbEv(ptr noundef nonnull align 8 dereferenceable(16) %17) #5
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %17) #5
  br i1 %140, label %130, label %.critedge48

141:                                              ; preds = %135
  %142 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %17) #5
  br label %154

.critedge:                                        ; preds = %147
  %indvars.iv.next64 = add nuw nsw i64 %indvars.iv63, 1
  %143 = load i32, ptr %2, align 4, !tbaa !5
  %144 = sext i32 %143 to i64
  %.not38 = icmp slt i64 %indvars.iv.next64, %144
  br i1 %.not38, label %145, label %.critedge48, !llvm.loop !16

145:                                              ; preds = %.lr.ph61, %.critedge
  %indvars.iv63 = phi i64 [ 0, %.lr.ph61 ], [ %indvars.iv.next64, %.critedge ]
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %18) #5
  %146 = invoke { ptr, i64 } @_ZNSt6vectorIbSaIbEEixEm(ptr noundef nonnull align 8 dereferenceable(40) %6, i64 noundef %indvars.iv63)
          to label %147 unwind label %151

147:                                              ; preds = %145
  %148 = extractvalue { ptr, i64 } %146, 0
  store ptr %148, ptr %18, align 8
  %149 = extractvalue { ptr, i64 } %146, 1
  store i64 %149, ptr %134, align 8
  %150 = call noundef zeroext i1 @_ZNKSt14_Bit_referencecvbEv(ptr noundef nonnull align 8 dereferenceable(16) %18) #5
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %18) #5
  br i1 %150, label %.critedge, label %.critedge48

151:                                              ; preds = %145
  %152 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %18) #5
  br label %154

.critedge48:                                      ; preds = %137, %.critedge, %147, %.critedge.preheader
  %.str.2.sink = phi ptr [ @.str.3, %.critedge.preheader ], [ @.str.2, %147 ], [ @.str.3, %.critedge ], [ @.str.2, %137 ]
  %153 = call i32 @puts(ptr noundef nonnull dereferenceable(1) %.str.2.sink)
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %10) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %9) #5
  call void @_ZNSt13_Bvector_baseISaIbEED2Ev(ptr noundef nonnull align 8 dereferenceable(40) %6) #5
  call void @llvm.lifetime.end.p0(i64 40, ptr nonnull %6) #5
  call void @_ZNSt13_Bvector_baseISaIbEED2Ev(ptr noundef nonnull align 8 dereferenceable(40) %3) #5
  call void @llvm.lifetime.end.p0(i64 40, ptr nonnull %3) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %2) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %1) #5
  ret i32 0

154:                                              ; preds = %129, %141, %151, %73, %50
  %.pn43 = phi { ptr, i32 } [ %51, %50 ], [ %74, %73 ], [ %.pn.pn.pn, %129 ], [ %152, %151 ], [ %142, %141 ]
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %10) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %9) #5
  call void @_ZNSt13_Bvector_baseISaIbEED2Ev(ptr noundef nonnull align 8 dereferenceable(40) %6) #5
  br label %155

155:                                              ; preds = %154, %36
  %.pn43.pn = phi { ptr, i32 } [ %.pn43, %154 ], [ %37, %36 ]
  call void @llvm.lifetime.end.p0(i64 40, ptr nonnull %6) #5
  call void @_ZNSt13_Bvector_baseISaIbEED2Ev(ptr noundef nonnull align 8 dereferenceable(40) %3) #5
  br label %156

156:                                              ; preds = %155, %34
  %.pn43.pn.pn = phi { ptr, i32 } [ %.pn43.pn, %155 ], [ %35, %34 ]
  call void @llvm.lifetime.end.p0(i64 40, ptr nonnull %3) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %2) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %1) #5
  resume { ptr, i32 } %.pn43.pn.pn
}

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

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

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

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

declare i32 @__gxx_personality_v0(...)

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

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

; Function Attrs: mustprogress uwtable
declare dso_local { ptr, i64 } @_ZNSt6vectorIbSaIbEEixEm(ptr noundef nonnull align 8 dereferenceable(40), i64 noundef) local_unnamed_addr #4 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt14_Bit_referenceaSEb(ptr noundef nonnull align 8 dereferenceable(16), i1 noundef zeroext) local_unnamed_addr #3 align 2

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt14_Bit_referenceaSERKS_(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 8 dereferenceable(16)) local_unnamed_addr #3 align 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 @_ZNSt13_Bvector_baseISaIbEED2Ev(ptr noundef nonnull align 8 dereferenceable(40)) 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 = !{!"int", !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 = distinct !{!14, !12}
!15 = distinct !{!15, !12}
!16 = distinct !{!16, !12}


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