; LLVM IR from DionysiosB/CodeForces :: 2104D-ArrayAndGCD (main)

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

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

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

31:                                               ; preds = %0
  call void @_ZNSt15__new_allocatorIbED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %5) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr %5) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr %4) #6
  call void @llvm.lifetime.start.p0(i64 16, ptr %8) #6
  %32 = invoke { ptr, i64 } @_ZNSt6vectorIbSaIbEEixEm(ptr noundef nonnull align 8 dereferenceable(40) %3, i64 noundef 1)
          to label %33 unwind label %56

33:                                               ; preds = %31
  %34 = getelementptr inbounds { ptr, i64 }, ptr %8, i32 0, i32 0
  %35 = extractvalue { ptr, i64 } %32, 0
  store ptr %35, ptr %34, align 8
  %36 = getelementptr inbounds { ptr, i64 }, ptr %8, i32 0, i32 1
  %37 = extractvalue { ptr, i64 } %32, 1
  store i64 %37, ptr %36, align 8
  %38 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt14_Bit_referenceaSEb(ptr noundef nonnull align 8 dereferenceable(16) %8, i1 noundef zeroext false) #6
  call void @llvm.lifetime.start.p0(i64 16, ptr %9) #6
  %39 = invoke { ptr, i64 } @_ZNSt6vectorIbSaIbEEixEm(ptr noundef nonnull align 8 dereferenceable(40) %3, i64 noundef 0)
          to label %40 unwind label %60

40:                                               ; preds = %33
  %41 = getelementptr inbounds { ptr, i64 }, ptr %9, i32 0, i32 0
  %42 = extractvalue { ptr, i64 } %39, 0
  store ptr %42, ptr %41, align 8
  %43 = getelementptr inbounds { ptr, i64 }, ptr %9, i32 0, i32 1
  %44 = extractvalue { ptr, i64 } %39, 1
  store i64 %44, ptr %43, align 8
  %45 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt14_Bit_referenceaSERKS_(ptr noundef nonnull align 8 dereferenceable(16) %9, ptr noundef nonnull align 8 dereferenceable(16) %38) #6
  call void @llvm.lifetime.end.p0(i64 16, ptr %9) #6
  call void @llvm.lifetime.end.p0(i64 16, ptr %8) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #6
  store i64 2, ptr %10, align 8, !tbaa !5
  br label %46

46:                                               ; preds = %105, %40
  %47 = load i64, ptr %10, align 8, !tbaa !5
  %48 = load i64, ptr %10, align 8, !tbaa !5
  %49 = mul nsw i64 %47, %48
  %50 = icmp sle i64 %49, 7000000
  br i1 %50, label %65, label %51

51:                                               ; preds = %46
  store i32 2, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #6
  br label %109

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

56:                                               ; preds = %31
  %57 = landingpad { ptr, i32 }
          cleanup
  %58 = extractvalue { ptr, i32 } %57, 0
  store ptr %58, ptr %6, align 8
  %59 = extractvalue { ptr, i32 } %57, 1
  store i32 %59, ptr %7, align 4
  br label %64

60:                                               ; preds = %33
  %61 = landingpad { ptr, i32 }
          cleanup
  %62 = extractvalue { ptr, i32 } %61, 0
  store ptr %62, ptr %6, align 8
  %63 = extractvalue { ptr, i32 } %61, 1
  store i32 %63, ptr %7, align 4
  call void @llvm.lifetime.end.p0(i64 16, ptr %9) #6
  br label %64

64:                                               ; preds = %60, %56
  call void @llvm.lifetime.end.p0(i64 16, ptr %8) #6
  br label %252

65:                                               ; preds = %46
  call void @llvm.lifetime.start.p0(i64 16, ptr %12) #6
  %66 = load i64, ptr %10, align 8, !tbaa !5
  %67 = invoke { ptr, i64 } @_ZNSt6vectorIbSaIbEEixEm(ptr noundef nonnull align 8 dereferenceable(40) %3, i64 noundef %66)
          to label %68 unwind label %76

68:                                               ; preds = %65
  %69 = getelementptr inbounds { ptr, i64 }, ptr %12, i32 0, i32 0
  %70 = extractvalue { ptr, i64 } %67, 0
  store ptr %70, ptr %69, align 8
  %71 = getelementptr inbounds { ptr, i64 }, ptr %12, i32 0, i32 1
  %72 = extractvalue { ptr, i64 } %67, 1
  store i64 %72, ptr %71, align 8
  %73 = call noundef zeroext i1 @_ZNKSt14_Bit_referencecvbEv(ptr noundef nonnull align 8 dereferenceable(16) %12) #6
  %74 = xor i1 %73, true
  call void @llvm.lifetime.end.p0(i64 16, ptr %12) #6
  br i1 %74, label %75, label %80

75:                                               ; preds = %68
  br label %105

76:                                               ; preds = %65
  %77 = landingpad { ptr, i32 }
          cleanup
  %78 = extractvalue { ptr, i32 } %77, 0
  store ptr %78, ptr %6, align 8
  %79 = extractvalue { ptr, i32 } %77, 1
  store i32 %79, ptr %7, align 4
  call void @llvm.lifetime.end.p0(i64 16, ptr %12) #6
  br label %108

80:                                               ; preds = %68
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #6
  %81 = load i64, ptr %10, align 8, !tbaa !5
  %82 = mul nsw i64 2, %81
  store i64 %82, ptr %13, align 8, !tbaa !5
  br label %83

83:                                               ; preds = %96, %80
  %84 = load i64, ptr %13, align 8, !tbaa !5
  %85 = icmp slt i64 %84, 7000000
  br i1 %85, label %87, label %86

86:                                               ; preds = %83
  store i32 5, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #6
  br label %104

87:                                               ; preds = %83
  call void @llvm.lifetime.start.p0(i64 16, ptr %14) #6
  %88 = load i64, ptr %13, align 8, !tbaa !5
  %89 = invoke { ptr, i64 } @_ZNSt6vectorIbSaIbEEixEm(ptr noundef nonnull align 8 dereferenceable(40) %3, i64 noundef %88)
          to label %90 unwind label %100

90:                                               ; preds = %87
  %91 = getelementptr inbounds { ptr, i64 }, ptr %14, i32 0, i32 0
  %92 = extractvalue { ptr, i64 } %89, 0
  store ptr %92, ptr %91, align 8
  %93 = getelementptr inbounds { ptr, i64 }, ptr %14, i32 0, i32 1
  %94 = extractvalue { ptr, i64 } %89, 1
  store i64 %94, ptr %93, align 8
  %95 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt14_Bit_referenceaSEb(ptr noundef nonnull align 8 dereferenceable(16) %14, i1 noundef zeroext false) #6
  call void @llvm.lifetime.end.p0(i64 16, ptr %14) #6
  br label %96

96:                                               ; preds = %90
  %97 = load i64, ptr %10, align 8, !tbaa !5
  %98 = load i64, ptr %13, align 8, !tbaa !5
  %99 = add nsw i64 %98, %97
  store i64 %99, ptr %13, align 8, !tbaa !5
  br label %83, !llvm.loop !11

100:                                              ; preds = %87
  %101 = landingpad { ptr, i32 }
          cleanup
  %102 = extractvalue { ptr, i32 } %101, 0
  store ptr %102, ptr %6, align 8
  %103 = extractvalue { ptr, i32 } %101, 1
  store i32 %103, ptr %7, align 4
  call void @llvm.lifetime.end.p0(i64 16, ptr %14) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #6
  br label %108

104:                                              ; preds = %86
  br label %105

105:                                              ; preds = %104, %75
  %106 = load i64, ptr %10, align 8, !tbaa !5
  %107 = add nsw i64 %106, 1
  store i64 %107, ptr %10, align 8, !tbaa !5
  br label %46, !llvm.loop !13

108:                                              ; preds = %100, %76
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #6
  br label %252

109:                                              ; preds = %51
  call void @llvm.lifetime.start.p0(i64 24, ptr %15) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #6
  store i64 0, ptr %16, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 1, ptr %17) #6
  call void @_ZNSaIxEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %17) #6
  invoke void @_ZNSt6vectorIxSaIxEEC2EmRKxRKS0_(ptr noundef nonnull align 8 dereferenceable(24) %15, i64 noundef 1, ptr noundef nonnull align 8 dereferenceable(8) %16, ptr noundef nonnull align 1 dereferenceable(1) %17)
          to label %110 unwind label %115

110:                                              ; preds = %109
  call void @_ZNSt15__new_allocatorIxED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %17) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr %17) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #6
  store i64 0, ptr %18, align 8, !tbaa !5
  br label %111

111:                                              ; preds = %140, %110
  %112 = load i64, ptr %18, align 8, !tbaa !5
  %113 = icmp slt i64 %112, 7000000
  br i1 %113, label %119, label %114

114:                                              ; preds = %111
  store i32 8, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #6
  br label %148

115:                                              ; preds = %109
  %116 = landingpad { ptr, i32 }
          cleanup
  %117 = extractvalue { ptr, i32 } %116, 0
  store ptr %117, ptr %6, align 8
  %118 = extractvalue { ptr, i32 } %116, 1
  store i32 %118, ptr %7, align 4
  call void @_ZNSt15__new_allocatorIxED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %17) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr %17) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #6
  br label %251

119:                                              ; preds = %111
  call void @llvm.lifetime.start.p0(i64 16, ptr %19) #6
  %120 = load i64, ptr %18, align 8, !tbaa !5
  %121 = invoke { ptr, i64 } @_ZNSt6vectorIbSaIbEEixEm(ptr noundef nonnull align 8 dereferenceable(40) %3, i64 noundef %120)
          to label %122 unwind label %130

122:                                              ; preds = %119
  %123 = getelementptr inbounds { ptr, i64 }, ptr %19, i32 0, i32 0
  %124 = extractvalue { ptr, i64 } %121, 0
  store ptr %124, ptr %123, align 8
  %125 = getelementptr inbounds { ptr, i64 }, ptr %19, i32 0, i32 1
  %126 = extractvalue { ptr, i64 } %121, 1
  store i64 %126, ptr %125, align 8
  %127 = call noundef zeroext i1 @_ZNKSt14_Bit_referencecvbEv(ptr noundef nonnull align 8 dereferenceable(16) %19) #6
  %128 = xor i1 %127, true
  call void @llvm.lifetime.end.p0(i64 16, ptr %19) #6
  br i1 %128, label %129, label %134

129:                                              ; preds = %122
  br label %140

130:                                              ; preds = %119
  %131 = landingpad { ptr, i32 }
          cleanup
  %132 = extractvalue { ptr, i32 } %131, 0
  store ptr %132, ptr %6, align 8
  %133 = extractvalue { ptr, i32 } %131, 1
  store i32 %133, ptr %7, align 4
  call void @llvm.lifetime.end.p0(i64 16, ptr %19) #6
  br label %147

134:                                              ; preds = %122
  call void @llvm.lifetime.start.p0(i64 8, ptr %20) #6
  %135 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIxSaIxEE4backEv(ptr noundef nonnull align 8 dereferenceable(24) %15) #6
  %136 = load i64, ptr %135, align 8, !tbaa !5
  %137 = load i64, ptr %18, align 8, !tbaa !5
  %138 = add nsw i64 %136, %137
  store i64 %138, ptr %20, align 8, !tbaa !5
  invoke void @_ZNSt6vectorIxSaIxEE9push_backEOx(ptr noundef nonnull align 8 dereferenceable(24) %15, ptr noundef nonnull align 8 dereferenceable(8) %20)
          to label %139 unwind label %143

139:                                              ; preds = %134
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #6
  br label %140

140:                                              ; preds = %139, %129
  %141 = load i64, ptr %18, align 8, !tbaa !5
  %142 = add nsw i64 %141, 1
  store i64 %142, ptr %18, align 8, !tbaa !5
  br label %111, !llvm.loop !14

143:                                              ; preds = %134
  %144 = landingpad { ptr, i32 }
          cleanup
  %145 = extractvalue { ptr, i32 } %144, 0
  store ptr %145, ptr %6, align 8
  %146 = extractvalue { ptr, i32 } %144, 1
  store i32 %146, ptr %7, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #6
  br label %147

147:                                              ; preds = %143, %130
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #6
  br label %250

148:                                              ; preds = %114
  call void @llvm.lifetime.start.p0(i64 8, ptr %21) #6
  %149 = invoke i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef %21)
          to label %150 unwind label %165

150:                                              ; preds = %148
  br label %151

151:                                              ; preds = %239, %150
  %152 = load i64, ptr %21, align 8, !tbaa !5
  %153 = add nsw i64 %152, -1
  store i64 %153, ptr %21, align 8, !tbaa !5
  %154 = icmp ne i64 %152, 0
  br i1 %154, label %155, label %247

155:                                              ; preds = %151
  call void @llvm.lifetime.start.p0(i64 8, ptr %22) #6
  %156 = invoke i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef %22)
          to label %157 unwind label %169

157:                                              ; preds = %155
  call void @llvm.lifetime.start.p0(i64 24, ptr %23) #6
  %158 = load i64, ptr %22, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 1, ptr %24) #6
  call void @_ZNSaIxEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %24) #6
  invoke void @_ZNSt6vectorIxSaIxEEC2EmRKS0_(ptr noundef nonnull align 8 dereferenceable(24) %23, i64 noundef %158, ptr noundef nonnull align 1 dereferenceable(1) %24)
          to label %159 unwind label %173

159:                                              ; preds = %157
  call void @_ZNSt15__new_allocatorIxED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %24) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr %24) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr %25) #6
  store i64 0, ptr %25, align 8, !tbaa !5
  br label %160

160:                                              ; preds = %182, %159
  %161 = load i64, ptr %25, align 8, !tbaa !5
  %162 = load i64, ptr %22, align 8, !tbaa !5
  %163 = icmp slt i64 %161, %162
  br i1 %163, label %177, label %164

164:                                              ; preds = %160
  store i32 13, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %25) #6
  br label %189

165:                                              ; preds = %148
  %166 = landingpad { ptr, i32 }
          cleanup
  %167 = extractvalue { ptr, i32 } %166, 0
  store ptr %167, ptr %6, align 8
  %168 = extractvalue { ptr, i32 } %166, 1
  store i32 %168, ptr %7, align 4
  br label %249

169:                                              ; preds = %155
  %170 = landingpad { ptr, i32 }
          cleanup
  %171 = extractvalue { ptr, i32 } %170, 0
  store ptr %171, ptr %6, align 8
  %172 = extractvalue { ptr, i32 } %170, 1
  store i32 %172, ptr %7, align 4
  br label %246

173:                                              ; preds = %157
  %174 = landingpad { ptr, i32 }
          cleanup
  %175 = extractvalue { ptr, i32 } %174, 0
  store ptr %175, ptr %6, align 8
  %176 = extractvalue { ptr, i32 } %174, 1
  store i32 %176, ptr %7, align 4
  call void @_ZNSt15__new_allocatorIxED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %24) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr %24) #6
  br label %245

177:                                              ; preds = %160
  %178 = load i64, ptr %25, align 8, !tbaa !5
  %179 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIxSaIxEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %23, i64 noundef %178) #6
  %180 = invoke i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef %179)
          to label %181 unwind label %185

181:                                              ; preds = %177
  br label %182

182:                                              ; preds = %181
  %183 = load i64, ptr %25, align 8, !tbaa !5
  %184 = add nsw i64 %183, 1
  store i64 %184, ptr %25, align 8, !tbaa !5
  br label %160, !llvm.loop !15

185:                                              ; preds = %177
  %186 = landingpad { ptr, i32 }
          cleanup
  %187 = extractvalue { ptr, i32 } %186, 0
  store ptr %187, ptr %6, align 8
  %188 = extractvalue { ptr, i32 } %186, 1
  store i32 %188, ptr %7, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %25) #6
  br label %244

189:                                              ; preds = %164
  call void @_ZNSt6vectorIxSaIxEE6rbeginEv(ptr dead_on_unwind writable sret(%"class.std::reverse_iterator") align 8 %26, ptr noundef nonnull align 8 dereferenceable(24) %23) #6
  call void @_ZNSt6vectorIxSaIxEE4rendEv(ptr dead_on_unwind writable sret(%"class.std::reverse_iterator") align 8 %27, ptr noundef nonnull align 8 dereferenceable(24) %23) #6
  invoke void @_ZSt4sortISt16reverse_iteratorIN9__gnu_cxx17__normal_iteratorIPxSt6vectorIxSaIxEEEEEEvT_S9_(ptr noundef %26, ptr noundef %27)
          to label %190 unwind label %196

190:                                              ; preds = %189
  call void @llvm.lifetime.start.p0(i64 8, ptr %28) #6
  store i64 1, ptr %28, align 8, !tbaa !5
  br label %191

191:                                              ; preds = %209, %190
  %192 = load i64, ptr %28, align 8, !tbaa !5
  %193 = load i64, ptr %22, align 8, !tbaa !5
  %194 = icmp slt i64 %192, %193
  br i1 %194, label %200, label %195

195:                                              ; preds = %191
  store i32 16, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %28) #6
  br label %212

196:                                              ; preds = %189
  %197 = landingpad { ptr, i32 }
          cleanup
  %198 = extractvalue { ptr, i32 } %197, 0
  store ptr %198, ptr %6, align 8
  %199 = extractvalue { ptr, i32 } %197, 1
  store i32 %199, ptr %7, align 4
  br label %244

200:                                              ; preds = %191
  %201 = load i64, ptr %28, align 8, !tbaa !5
  %202 = sub nsw i64 %201, 1
  %203 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIxSaIxEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %23, i64 noundef %202) #6
  %204 = load i64, ptr %203, align 8, !tbaa !5
  %205 = load i64, ptr %28, align 8, !tbaa !5
  %206 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIxSaIxEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %23, i64 noundef %205) #6
  %207 = load i64, ptr %206, align 8, !tbaa !5
  %208 = add nsw i64 %207, %204
  store i64 %208, ptr %206, align 8, !tbaa !5
  br label %209

209:                                              ; preds = %200
  %210 = load i64, ptr %28, align 8, !tbaa !5
  %211 = add nsw i64 %210, 1
  store i64 %211, ptr %28, align 8, !tbaa !5
  br label %191, !llvm.loop !16

212:                                              ; preds = %195
  call void @llvm.lifetime.start.p0(i64 8, ptr %29) #6
  store i64 0, ptr %29, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %30) #6
  store i64 0, ptr %30, align 8, !tbaa !5
  br label %213

213:                                              ; preds = %232, %212
  %214 = load i64, ptr %30, align 8, !tbaa !5
  %215 = load i64, ptr %22, align 8, !tbaa !5
  %216 = icmp slt i64 %214, %215
  br i1 %216, label %218, label %217

217:                                              ; preds = %213
  store i32 19, ptr %11, align 4
  br label %235

218:                                              ; preds = %213
  %219 = load i64, ptr %30, align 8, !tbaa !5
  %220 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIxSaIxEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %23, i64 noundef %219) #6
  %221 = load i64, ptr %220, align 8, !tbaa !5
  %222 = load i64, ptr %30, align 8, !tbaa !5
  %223 = add nsw i64 %222, 1
  %224 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIxSaIxEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %15, i64 noundef %223) #6
  %225 = load i64, ptr %224, align 8, !tbaa !5
  %226 = icmp slt i64 %221, %225
  br i1 %226, label %227, label %231

227:                                              ; preds = %218
  %228 = load i64, ptr %22, align 8, !tbaa !5
  %229 = load i64, ptr %30, align 8, !tbaa !5
  %230 = sub nsw i64 %228, %229
  store i64 %230, ptr %29, align 8, !tbaa !5
  store i32 19, ptr %11, align 4
  br label %235

231:                                              ; preds = %218
  br label %232

232:                                              ; preds = %231
  %233 = load i64, ptr %30, align 8, !tbaa !5
  %234 = add nsw i64 %233, 1
  store i64 %234, ptr %30, align 8, !tbaa !5
  br label %213, !llvm.loop !17

235:                                              ; preds = %227, %217
  call void @llvm.lifetime.end.p0(i64 8, ptr %30) #6
  br label %236

236:                                              ; preds = %235
  %237 = load i64, ptr %29, align 8, !tbaa !5
  %238 = invoke i32 (ptr, ...) @printf(ptr noundef @.str.1, i64 noundef %237)
          to label %239 unwind label %240

239:                                              ; preds = %236
  call void @llvm.lifetime.end.p0(i64 8, ptr %29) #6
  call void @_ZNSt6vectorIxSaIxEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %23) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr %23) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #6
  br label %151, !llvm.loop !18

240:                                              ; preds = %236
  %241 = landingpad { ptr, i32 }
          cleanup
  %242 = extractvalue { ptr, i32 } %241, 0
  store ptr %242, ptr %6, align 8
  %243 = extractvalue { ptr, i32 } %241, 1
  store i32 %243, ptr %7, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %29) #6
  br label %244

244:                                              ; preds = %240, %196, %185
  call void @_ZNSt6vectorIxSaIxEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %23) #6
  br label %245

245:                                              ; preds = %244, %173
  call void @llvm.lifetime.end.p0(i64 24, ptr %23) #6
  br label %246

246:                                              ; preds = %245, %169
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #6
  br label %249

247:                                              ; preds = %151
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #6
  call void @_ZNSt6vectorIxSaIxEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %15) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr %15) #6
  call void @_ZNSt13_Bvector_baseISaIbEED2Ev(ptr noundef nonnull align 8 dereferenceable(40) %3) #6
  call void @llvm.lifetime.end.p0(i64 40, ptr %3) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %2) #6
  %248 = load i32, ptr %1, align 4
  ret i32 %248

249:                                              ; preds = %246, %165
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #6
  br label %250

250:                                              ; preds = %249, %147
  call void @_ZNSt6vectorIxSaIxEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %15) #6
  br label %251

251:                                              ; preds = %250, %115
  call void @llvm.lifetime.end.p0(i64 24, ptr %15) #6
  br label %252

252:                                              ; preds = %251, %108, %64
  call void @_ZNSt13_Bvector_baseISaIbEED2Ev(ptr noundef nonnull align 8 dereferenceable(40) %3) #6
  br label %253

253:                                              ; preds = %252, %52
  call void @llvm.lifetime.end.p0(i64 40, ptr %3) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %2) #6
  br label %254

254:                                              ; preds = %253
  %255 = load ptr, ptr %6, align 8
  %256 = load i32, ptr %7, align 4
  %257 = insertvalue { ptr, i32 } poison, ptr %255, 0
  %258 = insertvalue { ptr, i32 } %257, i32 %256, 1
  resume { ptr, i32 } %258
}

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSaIbEC2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #2 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 #3 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 #2 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) #3 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) #2 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)) #2 align 2

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

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

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

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

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

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

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

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt6vectorIxSaIxEE6rbeginEv(ptr dead_on_unwind noalias writable sret(%"class.std::reverse_iterator") align 8, ptr noundef nonnull align 8 dereferenceable(24)) #2 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt6vectorIxSaIxEE4rendEv(ptr dead_on_unwind noalias writable sret(%"class.std::reverse_iterator") align 8, ptr noundef nonnull align 8 dereferenceable(24)) #2 align 2

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

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt15__new_allocatorIxED2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #2 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 = { 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 #3 = { 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 #4 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #5 = { inlinehint mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #6 = { nounwind }

!llvm.module.flags = !{!0, !1, !2, !3}
!llvm.ident = !{!4}

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"long 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 = distinct !{!14, !12}
!15 = distinct !{!15, !12}
!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 }
%"class.std::vector.3" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<long long, std::allocator<long long>>::_Vector_impl" }
%"struct.std::_Vector_base<long long, std::allocator<long long>>::_Vector_impl" = type { %"struct.std::_Vector_base<long long, std::allocator<long long>>::_Vector_impl_data" }
%"struct.std::_Vector_base<long long, std::allocator<long long>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::allocator.4" = type { i8 }
%"class.std::reverse_iterator" = type { %"class.__gnu_cxx::__normal_iterator" }
%"class.__gnu_cxx::__normal_iterator" = type { ptr }

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

19:                                               ; preds = %0
  call void @_ZNSt15__new_allocatorIbED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %3) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %3) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %2) #6
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %4) #6
  %20 = invoke { ptr, i64 } @_ZNSt6vectorIbSaIbEEixEm(ptr noundef nonnull align 8 dereferenceable(40) %1, i64 noundef 1)
          to label %21 unwind label %37

21:                                               ; preds = %19
  %22 = extractvalue { ptr, i64 } %20, 0
  store ptr %22, ptr %4, align 8
  %23 = getelementptr inbounds i8, ptr %4, i64 8
  %24 = extractvalue { ptr, i64 } %20, 1
  store i64 %24, ptr %23, align 8
  %25 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt14_Bit_referenceaSEb(ptr noundef nonnull align 8 dereferenceable(16) %4, i1 noundef zeroext false) #6
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %5) #6
  %26 = invoke { ptr, i64 } @_ZNSt6vectorIbSaIbEEixEm(ptr noundef nonnull align 8 dereferenceable(40) %1, i64 noundef 0)
          to label %27 unwind label %39

27:                                               ; preds = %21
  %28 = extractvalue { ptr, i64 } %26, 0
  store ptr %28, ptr %5, align 8
  %29 = getelementptr inbounds i8, ptr %5, i64 8
  %30 = extractvalue { ptr, i64 } %26, 1
  store i64 %30, ptr %29, align 8
  %31 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt14_Bit_referenceaSERKS_(ptr noundef nonnull align 8 dereferenceable(16) %5, ptr noundef nonnull align 8 dereferenceable(16) %25) #6
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %5) #6
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %4) #6
  %32 = getelementptr inbounds i8, ptr %6, i64 8
  %33 = getelementptr inbounds i8, ptr %7, i64 8
  br label %42

34:                                               ; preds = %.loopexit55
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %8) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %9) #6
  store i64 0, ptr %9, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %10) #6
  call void @_ZNSaIxEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %10) #6
  invoke void @_ZNSt6vectorIxSaIxEEC2EmRKxRKS0_(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef 1, ptr noundef nonnull align 8 dereferenceable(8) %9, ptr noundef nonnull align 1 dereferenceable(1) %10)
          to label %61 unwind label %67

35:                                               ; preds = %0
  %36 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt15__new_allocatorIbED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %3) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %3) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %2) #6
  br label %130

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

39:                                               ; preds = %21
  %40 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %5) #6
  br label %41

41:                                               ; preds = %39, %37
  %.pn = phi { ptr, i32 } [ %40, %39 ], [ %38, %37 ]
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %4) #6
  br label %129

42:                                               ; preds = %27, %.loopexit55
  %.03358 = phi i64 [ 2, %27 ], [ %60, %.loopexit55 ]
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %6) #6
  %43 = invoke { ptr, i64 } @_ZNSt6vectorIbSaIbEEixEm(ptr noundef nonnull align 8 dereferenceable(40) %1, i64 noundef %.03358)
          to label %44 unwind label %49

44:                                               ; preds = %42
  %45 = extractvalue { ptr, i64 } %43, 0
  store ptr %45, ptr %6, align 8
  %46 = extractvalue { ptr, i64 } %43, 1
  store i64 %46, ptr %32, align 8
  %47 = call noundef zeroext i1 @_ZNKSt14_Bit_referencecvbEv(ptr noundef nonnull align 8 dereferenceable(16) %6) #6
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %6) #6
  br i1 %47, label %.lr.ph.preheader, label %.loopexit55

.lr.ph.preheader:                                 ; preds = %44
  %48 = shl nuw nsw i64 %.03358, 1
  br label %.lr.ph

49:                                               ; preds = %42
  %50 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %6) #6
  br label %129

.lr.ph:                                           ; preds = %.lr.ph.preheader, %52
  %.03257 = phi i64 [ %56, %52 ], [ %48, %.lr.ph.preheader ]
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %7) #6
  %51 = invoke { ptr, i64 } @_ZNSt6vectorIbSaIbEEixEm(ptr noundef nonnull align 8 dereferenceable(40) %1, i64 noundef %.03257)
          to label %52 unwind label %58

52:                                               ; preds = %.lr.ph
  %53 = extractvalue { ptr, i64 } %51, 0
  store ptr %53, ptr %7, align 8
  %54 = extractvalue { ptr, i64 } %51, 1
  store i64 %54, ptr %33, align 8
  %55 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt14_Bit_referenceaSEb(ptr noundef nonnull align 8 dereferenceable(16) %7, i1 noundef zeroext false) #6
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %7) #6
  %56 = add nuw nsw i64 %.03257, %.03358
  %57 = icmp ult i64 %56, 7000000
  br i1 %57, label %.lr.ph, label %.loopexit55, !llvm.loop !11

58:                                               ; preds = %.lr.ph
  %59 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %7) #6
  br label %129

.loopexit55:                                      ; preds = %52, %44
  %60 = add nuw nsw i64 %.03358, 1
  %exitcond.not = icmp eq i64 %60, 2646
  br i1 %exitcond.not, label %34, label %42, !llvm.loop !13

61:                                               ; preds = %34
  call void @_ZNSt15__new_allocatorIxED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %10) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %10) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %9) #6
  %62 = getelementptr inbounds i8, ptr %11, i64 8
  br label %69

63:                                               ; preds = %82
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %13) #6
  %64 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull %13)
  %65 = load i64, ptr %13, align 8, !tbaa !9
  %66 = add nsw i64 %65, -1
  store i64 %66, ptr %13, align 8, !tbaa !9
  %.not65 = icmp eq i64 %65, 0
  br i1 %.not65, label %._crit_edge68, label %.lr.ph67

67:                                               ; preds = %34
  %68 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt15__new_allocatorIxED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %10) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %10) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %9) #6
  br label %128

69:                                               ; preds = %61, %82
  %.03160 = phi i64 [ 0, %61 ], [ %83, %82 ]
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %11) #6
  %70 = invoke { ptr, i64 } @_ZNSt6vectorIbSaIbEEixEm(ptr noundef nonnull align 8 dereferenceable(40) %1, i64 noundef %.03160)
          to label %71 unwind label %75

71:                                               ; preds = %69
  %72 = extractvalue { ptr, i64 } %70, 0
  store ptr %72, ptr %11, align 8
  %73 = extractvalue { ptr, i64 } %70, 1
  store i64 %73, ptr %62, align 8
  %74 = call noundef zeroext i1 @_ZNKSt14_Bit_referencecvbEv(ptr noundef nonnull align 8 dereferenceable(16) %11) #6
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %11) #6
  br i1 %74, label %77, label %82

75:                                               ; preds = %69
  %76 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %11) #6
  br label %127

77:                                               ; preds = %71
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %12) #6
  %78 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIxSaIxEE4backEv(ptr noundef nonnull align 8 dereferenceable(24) %8) #6
  %79 = load i64, ptr %78, align 8, !tbaa !9
  %80 = add nsw i64 %79, %.03160
  store i64 %80, ptr %12, align 8, !tbaa !9
  invoke void @_ZNSt6vectorIxSaIxEE9push_backEOx(ptr noundef nonnull align 8 dereferenceable(24) %8, ptr noundef nonnull align 8 dereferenceable(8) %12)
          to label %81 unwind label %84

81:                                               ; preds = %77
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %12) #6
  br label %82

82:                                               ; preds = %71, %81
  %83 = add nuw nsw i64 %.03160, 1
  %exitcond71.not = icmp eq i64 %83, 7000000
  br i1 %exitcond71.not, label %63, label %69, !llvm.loop !14

84:                                               ; preds = %77
  %85 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %12) #6
  br label %127

.lr.ph67:                                         ; preds = %63, %.loopexit
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %14) #6
  %86 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull %14)
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %15) #6
  %87 = load i64, ptr %14, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %16) #6
  call void @_ZNSaIxEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %16) #6
  invoke void @_ZNSt6vectorIxSaIxEEC2EmRKS0_(ptr noundef nonnull align 8 dereferenceable(24) %15, i64 noundef %87, ptr noundef nonnull align 1 dereferenceable(1) %16)
          to label %88 unwind label %93

88:                                               ; preds = %.lr.ph67
  call void @_ZNSt15__new_allocatorIxED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %16) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %16) #6
  %89 = load i64, ptr %14, align 8, !tbaa !9
  %90 = icmp sgt i64 %89, 0
  br i1 %90, label %.lr.ph62, label %._crit_edge

._crit_edge:                                      ; preds = %.lr.ph62, %88
  call void @_ZNSt6vectorIxSaIxEE6rbeginEv(ptr dead_on_unwind nonnull writable sret(%"class.std::reverse_iterator") align 8 %17, ptr noundef nonnull align 8 dereferenceable(24) %15) #6
  call void @_ZNSt6vectorIxSaIxEE4rendEv(ptr dead_on_unwind nonnull writable sret(%"class.std::reverse_iterator") align 8 %18, ptr noundef nonnull align 8 dereferenceable(24) %15) #6
  invoke void @_ZSt4sortISt16reverse_iteratorIN9__gnu_cxx17__normal_iteratorIPxSt6vectorIxSaIxEEEEEEvT_S9_(ptr noundef nonnull %17, ptr noundef nonnull %18)
          to label %.preheader54 unwind label %100

.preheader54:                                     ; preds = %._crit_edge
  %91 = load i64, ptr %14, align 8, !tbaa !9
  %92 = icmp sgt i64 %91, 1
  br i1 %92, label %.lr.ph64, label %.preheader.preheader

93:                                               ; preds = %.lr.ph67
  %94 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt15__new_allocatorIxED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %16) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %16) #6
  br label %126

.lr.ph62:                                         ; preds = %88, %.lr.ph62
  %.03061 = phi i64 [ %97, %.lr.ph62 ], [ 0, %88 ]
  %95 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIxSaIxEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %15, i64 noundef %.03061) #6
  %96 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull %95)
  %97 = add nuw nsw i64 %.03061, 1
  %98 = load i64, ptr %14, align 8, !tbaa !9
  %99 = icmp slt i64 %97, %98
  br i1 %99, label %.lr.ph62, label %._crit_edge, !llvm.loop !15

100:                                              ; preds = %._crit_edge
  %101 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt6vectorIxSaIxEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %15) #6
  br label %126

.lr.ph64:                                         ; preds = %.preheader54, %.lr.ph64
  %.02963 = phi i64 [ %108, %.lr.ph64 ], [ 1, %.preheader54 ]
  %102 = add nsw i64 %.02963, -1
  %103 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIxSaIxEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %15, i64 noundef %102) #6
  %104 = load i64, ptr %103, align 8, !tbaa !9
  %105 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIxSaIxEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %15, i64 noundef %.02963) #6
  %106 = load i64, ptr %105, align 8, !tbaa !9
  %107 = add nsw i64 %106, %104
  store i64 %107, ptr %105, align 8, !tbaa !9
  %108 = add nuw nsw i64 %.02963, 1
  %109 = load i64, ptr %14, align 8, !tbaa !9
  %110 = icmp slt i64 %108, %109
  br i1 %110, label %.lr.ph64, label %.preheader.preheader, !llvm.loop !16

.preheader.preheader:                             ; preds = %.lr.ph64, %.preheader54
  br label %.preheader

.preheader:                                       ; preds = %.preheader.preheader, %113
  %.0 = phi i64 [ %116, %113 ], [ 0, %.preheader.preheader ]
  %111 = load i64, ptr %14, align 8, !tbaa !9
  %112 = icmp slt i64 %.0, %111
  br i1 %112, label %113, label %.loopexit

113:                                              ; preds = %.preheader
  %114 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIxSaIxEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %15, i64 noundef %.0) #6
  %115 = load i64, ptr %114, align 8, !tbaa !9
  %116 = add nuw nsw i64 %.0, 1
  %117 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIxSaIxEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef %116) #6
  %118 = load i64, ptr %117, align 8, !tbaa !9
  %119 = icmp slt i64 %115, %118
  br i1 %119, label %120, label %.preheader, !llvm.loop !17

120:                                              ; preds = %113
  %121 = load i64, ptr %14, align 8, !tbaa !9
  %122 = sub nsw i64 %121, %.0
  br label %.loopexit

.loopexit:                                        ; preds = %.preheader, %120
  %.028 = phi i64 [ %122, %120 ], [ 0, %.preheader ]
  %123 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.1, i64 noundef %.028)
  call void @_ZNSt6vectorIxSaIxEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %15) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %15) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %14) #6
  %124 = load i64, ptr %13, align 8, !tbaa !9
  %125 = add nsw i64 %124, -1
  store i64 %125, ptr %13, align 8, !tbaa !9
  %.not = icmp eq i64 %124, 0
  br i1 %.not, label %._crit_edge68, label %.lr.ph67, !llvm.loop !18

126:                                              ; preds = %100, %93
  %.pn44 = phi { ptr, i32 } [ %101, %100 ], [ %94, %93 ]
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %15) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %14) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %13) #6
  br label %127

._crit_edge68:                                    ; preds = %.loopexit, %63
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %13) #6
  call void @_ZNSt6vectorIxSaIxEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %8) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %8) #6
  call void @_ZNSt13_Bvector_baseISaIbEED2Ev(ptr noundef nonnull align 8 dereferenceable(40) %1) #6
  call void @llvm.lifetime.end.p0(i64 40, ptr nonnull %1) #6
  ret i32 0

127:                                              ; preds = %75, %84, %126
  %.pn46.pn = phi { ptr, i32 } [ %.pn44, %126 ], [ %85, %84 ], [ %76, %75 ]
  call void @_ZNSt6vectorIxSaIxEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %8) #6
  br label %128

128:                                              ; preds = %127, %67
  %.pn46.pn.pn = phi { ptr, i32 } [ %.pn46.pn, %127 ], [ %68, %67 ]
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %8) #6
  br label %129

129:                                              ; preds = %49, %58, %128, %41
  %.pn50.pn = phi { ptr, i32 } [ %.pn46.pn.pn, %128 ], [ %.pn, %41 ], [ %59, %58 ], [ %50, %49 ]
  call void @_ZNSt13_Bvector_baseISaIbEED2Ev(ptr noundef nonnull align 8 dereferenceable(40) %1) #6
  br label %130

130:                                              ; preds = %129, %35
  %.pn50.pn.pn = phi { ptr, i32 } [ %.pn50.pn, %129 ], [ %36, %35 ]
  call void @llvm.lifetime.end.p0(i64 40, ptr nonnull %1) #6
  resume { ptr, i32 } %.pn50.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: mustprogress nounwind uwtable
declare dso_local void @_ZNSaIbEC2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #2 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 #3 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 #2 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 #3 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 #2 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 #2 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 #2 align 2

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

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

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

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

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

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

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt6vectorIxSaIxEE6rbeginEv(ptr dead_on_unwind noalias writable sret(%"class.std::reverse_iterator") align 8, ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #2 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt6vectorIxSaIxEE4rendEv(ptr dead_on_unwind noalias writable sret(%"class.std::reverse_iterator") align 8, ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #2 align 2

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

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt15__new_allocatorIxED2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #2 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 = { 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 #3 = { 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 #4 = { 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 #5 = { inlinehint mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #6 = { nounwind }

!llvm.module.flags = !{!0, !1, !2, !3}
!llvm.ident = !{!4}

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"bool", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"long long", !7, i64 0}
!11 = distinct !{!11, !12}
!12 = !{!"llvm.loop.mustprogress"}
!13 = distinct !{!13, !12}
!14 = distinct !{!14, !12}
!15 = distinct !{!15, !12}
!16 = distinct !{!16, !12}
!17 = distinct !{!17, !12}
!18 = distinct !{!18, !12}


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