; LLVM IR from upupming/algorithm :: AdvancedLevel_C++/1075. PAT Judge (25)  (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.0" = type { %"struct.std::_Vector_base.1" }
%"struct.std::_Vector_base.1" = type { %"struct.std::_Vector_base<node, std::allocator<node>>::_Vector_impl" }
%"struct.std::_Vector_base<node, std::allocator<node>>::_Vector_impl" = type { %"struct.std::_Vector_base<node, std::allocator<node>>::_Vector_impl_data" }
%"struct.std::_Vector_base<node, std::allocator<node>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::allocator.2" = type { i8 }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::allocator" = type { i8 }
%"class.__gnu_cxx::__normal_iterator" = type { ptr }
%struct.node = type <{ i32, i32, i32, [4 x i8], %"class.std::vector", i32, i8, [3 x i8] }>

@.str = external hidden unnamed_addr constant [9 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [11 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [2 x i8], align 1

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_Z4cmp14nodeS_(ptr noundef, ptr noundef) #0

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() #1 personality ptr @__gxx_personality_v0 {
  %1 = alloca i32, align 4
  %2 = alloca i32, align 4
  %3 = alloca i32, align 4
  %4 = alloca i32, align 4
  %5 = alloca i32, align 4
  %6 = alloca i32, align 4
  %7 = alloca i32, align 4
  %8 = alloca %"class.std::vector.0", align 8
  %9 = alloca %"class.std::allocator.2", align 1
  %10 = alloca ptr, align 8
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  %13 = alloca i32, align 4
  %14 = alloca %"class.std::vector", align 8
  %15 = alloca %"class.std::allocator", align 1
  %16 = alloca i32, align 4
  %17 = alloca i32, align 4
  %18 = alloca i32, align 4
  %19 = alloca i32, align 4
  %20 = alloca i32, align 4
  %21 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %22 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %23 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %24 = alloca i32, align 4
  %25 = alloca i32, align 4
  %26 = alloca i32, align 4
  store i32 0, ptr %1, align 4
  call void @llvm.lifetime.start.p0(i64 4, ptr %2) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %3) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %4) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %5) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %6) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #7
  %27 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef %2, ptr noundef %3, ptr noundef %4)
  call void @llvm.lifetime.start.p0(i64 24, ptr %8) #7
  %28 = load i32, ptr %2, align 4, !tbaa !5
  %29 = add nsw i32 %28, 1
  %30 = sext i32 %29 to i64
  call void @llvm.lifetime.start.p0(i64 1, ptr %9) #7
  call void @_ZNSaI4nodeEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %9) #7
  invoke void @_ZNSt6vectorI4nodeSaIS0_EEC2EmRKS1_(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef %30, ptr noundef nonnull align 1 dereferenceable(1) %9)
          to label %31 unwind label %37

31:                                               ; preds = %0
  call void @_ZNSt15__new_allocatorI4nodeED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %9) #7
  call void @llvm.lifetime.end.p0(i64 1, ptr %9) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #7
  store i32 1, ptr %12, align 4, !tbaa !5
  br label %32

32:                                               ; preds = %50, %31
  %33 = load i32, ptr %12, align 4, !tbaa !5
  %34 = load i32, ptr %2, align 4, !tbaa !5
  %35 = icmp sle i32 %33, %34
  br i1 %35, label %41, label %36

36:                                               ; preds = %32
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #7
  br label %57

37:                                               ; preds = %0
  %38 = landingpad { ptr, i32 }
          cleanup
  %39 = extractvalue { ptr, i32 } %38, 0
  store ptr %39, ptr %10, align 8
  %40 = extractvalue { ptr, i32 } %38, 1
  store i32 %40, ptr %11, align 4
  call void @_ZNSt15__new_allocatorI4nodeED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %9) #7
  call void @llvm.lifetime.end.p0(i64 1, ptr %9) #7
  br label %393

41:                                               ; preds = %32
  %42 = load i32, ptr %12, align 4, !tbaa !5
  %43 = sext i32 %42 to i64
  %44 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef %43) #7
  %45 = getelementptr inbounds %struct.node, ptr %44, i32 0, i32 4
  %46 = load i32, ptr %3, align 4, !tbaa !5
  %47 = add nsw i32 %46, 1
  %48 = sext i32 %47 to i64
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #7
  store i32 -1, ptr %13, align 4, !tbaa !5
  invoke void @_ZNSt6vectorIiSaIiEE6resizeEmRKi(ptr noundef nonnull align 8 dereferenceable(24) %45, i64 noundef %48, ptr noundef nonnull align 4 dereferenceable(4) %13)
          to label %49 unwind label %53

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

50:                                               ; preds = %49
  %51 = load i32, ptr %12, align 4, !tbaa !5
  %52 = add nsw i32 %51, 1
  store i32 %52, ptr %12, align 4, !tbaa !5
  br label %32, !llvm.loop !9

53:                                               ; preds = %41
  %54 = landingpad { ptr, i32 }
          cleanup
  %55 = extractvalue { ptr, i32 } %54, 0
  store ptr %55, ptr %10, align 8
  %56 = extractvalue { ptr, i32 } %54, 1
  store i32 %56, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #7
  br label %392

57:                                               ; preds = %36
  call void @llvm.lifetime.start.p0(i64 24, ptr %14) #7
  %58 = load i32, ptr %3, align 4, !tbaa !5
  %59 = add nsw i32 %58, 1
  %60 = sext i32 %59 to i64
  call void @llvm.lifetime.start.p0(i64 1, ptr %15) #7
  call void @_ZNSaIiEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %15) #7
  invoke void @_ZNSt6vectorIiSaIiEEC2EmRKS0_(ptr noundef nonnull align 8 dereferenceable(24) %14, i64 noundef %60, ptr noundef nonnull align 1 dereferenceable(1) %15)
          to label %61 unwind label %67

61:                                               ; preds = %57
  call void @_ZNSt15__new_allocatorIiED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %15) #7
  call void @llvm.lifetime.end.p0(i64 1, ptr %15) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %16) #7
  store i32 1, ptr %16, align 4, !tbaa !5
  br label %62

62:                                               ; preds = %77, %61
  %63 = load i32, ptr %16, align 4, !tbaa !5
  %64 = load i32, ptr %3, align 4, !tbaa !5
  %65 = icmp sle i32 %63, %64
  br i1 %65, label %71, label %66

66:                                               ; preds = %62
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #7
  br label %84

67:                                               ; preds = %57
  %68 = landingpad { ptr, i32 }
          cleanup
  %69 = extractvalue { ptr, i32 } %68, 0
  store ptr %69, ptr %10, align 8
  %70 = extractvalue { ptr, i32 } %68, 1
  store i32 %70, ptr %11, align 4
  call void @_ZNSt15__new_allocatorIiED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %15) #7
  call void @llvm.lifetime.end.p0(i64 1, ptr %15) #7
  br label %391

71:                                               ; preds = %62
  %72 = load i32, ptr %16, align 4, !tbaa !5
  %73 = sext i32 %72 to i64
  %74 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %14, i64 noundef %73) #7
  %75 = invoke i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str.1, ptr noundef %74)
          to label %76 unwind label %80

76:                                               ; preds = %71
  br label %77

77:                                               ; preds = %76
  %78 = load i32, ptr %16, align 4, !tbaa !5
  %79 = add nsw i32 %78, 1
  store i32 %79, ptr %16, align 4, !tbaa !5
  br label %62, !llvm.loop !11

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

84:                                               ; preds = %66
  call void @llvm.lifetime.start.p0(i64 4, ptr %17) #7
  store i32 0, ptr %17, align 4, !tbaa !5
  br label %85

85:                                               ; preds = %146, %84
  %86 = load i32, ptr %17, align 4, !tbaa !5
  %87 = load i32, ptr %4, align 4, !tbaa !5
  %88 = icmp slt i32 %86, %87
  br i1 %88, label %90, label %89

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

90:                                               ; preds = %85
  %91 = invoke i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef %5, ptr noundef %6, ptr noundef %7)
          to label %92 unwind label %122

92:                                               ; preds = %90
  %93 = load i32, ptr %5, align 4, !tbaa !5
  %94 = load i32, ptr %5, align 4, !tbaa !5
  %95 = sext i32 %94 to i64
  %96 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef %95) #7
  %97 = getelementptr inbounds %struct.node, ptr %96, i32 0, i32 1
  store i32 %93, ptr %97, align 4, !tbaa !12
  %98 = load i32, ptr %5, align 4, !tbaa !5
  %99 = sext i32 %98 to i64
  %100 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef %99) #7
  %101 = getelementptr inbounds %struct.node, ptr %100, i32 0, i32 4
  %102 = load i32, ptr %6, align 4, !tbaa !5
  %103 = sext i32 %102 to i64
  %104 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %101, i64 noundef %103) #7
  %105 = invoke noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3maxIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %104, ptr noundef nonnull align 4 dereferenceable(4) %7)
          to label %106 unwind label %122

106:                                              ; preds = %92
  %107 = load i32, ptr %105, align 4, !tbaa !5
  %108 = load i32, ptr %5, align 4, !tbaa !5
  %109 = sext i32 %108 to i64
  %110 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef %109) #7
  %111 = getelementptr inbounds %struct.node, ptr %110, i32 0, i32 4
  %112 = load i32, ptr %6, align 4, !tbaa !5
  %113 = sext i32 %112 to i64
  %114 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %111, i64 noundef %113) #7
  store i32 %107, ptr %114, align 4, !tbaa !5
  %115 = load i32, ptr %7, align 4, !tbaa !5
  %116 = icmp ne i32 %115, -1
  br i1 %116, label %117, label %126

117:                                              ; preds = %106
  %118 = load i32, ptr %5, align 4, !tbaa !5
  %119 = sext i32 %118 to i64
  %120 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef %119) #7
  %121 = getelementptr inbounds %struct.node, ptr %120, i32 0, i32 6
  store i8 1, ptr %121, align 4, !tbaa !20
  br label %145

122:                                              ; preds = %92, %90
  %123 = landingpad { ptr, i32 }
          cleanup
  %124 = extractvalue { ptr, i32 } %123, 0
  store ptr %124, ptr %10, align 8
  %125 = extractvalue { ptr, i32 } %123, 1
  store i32 %125, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #7
  br label %390

126:                                              ; preds = %106
  %127 = load i32, ptr %5, align 4, !tbaa !5
  %128 = sext i32 %127 to i64
  %129 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef %128) #7
  %130 = getelementptr inbounds %struct.node, ptr %129, i32 0, i32 4
  %131 = load i32, ptr %6, align 4, !tbaa !5
  %132 = sext i32 %131 to i64
  %133 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %130, i64 noundef %132) #7
  %134 = load i32, ptr %133, align 4, !tbaa !5
  %135 = icmp eq i32 %134, -1
  br i1 %135, label %136, label %144

136:                                              ; preds = %126
  %137 = load i32, ptr %5, align 4, !tbaa !5
  %138 = sext i32 %137 to i64
  %139 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef %138) #7
  %140 = getelementptr inbounds %struct.node, ptr %139, i32 0, i32 4
  %141 = load i32, ptr %6, align 4, !tbaa !5
  %142 = sext i32 %141 to i64
  %143 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %140, i64 noundef %142) #7
  store i32 -2, ptr %143, align 4, !tbaa !5
  br label %144

144:                                              ; preds = %136, %126
  br label %145

145:                                              ; preds = %144, %117
  br label %146

146:                                              ; preds = %145
  %147 = load i32, ptr %17, align 4, !tbaa !5
  %148 = add nsw i32 %147, 1
  store i32 %148, ptr %17, align 4, !tbaa !5
  br label %85, !llvm.loop !21

149:                                              ; preds = %89
  call void @llvm.lifetime.start.p0(i64 4, ptr %18) #7
  store i32 1, ptr %18, align 4, !tbaa !5
  br label %150

150:                                              ; preds = %222, %149
  %151 = load i32, ptr %18, align 4, !tbaa !5
  %152 = load i32, ptr %2, align 4, !tbaa !5
  %153 = icmp sle i32 %151, %152
  br i1 %153, label %155, label %154

154:                                              ; preds = %150
  store i32 11, ptr %19, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %18) #7
  br label %225

155:                                              ; preds = %150
  call void @llvm.lifetime.start.p0(i64 4, ptr %20) #7
  store i32 1, ptr %20, align 4, !tbaa !5
  br label %156

156:                                              ; preds = %218, %155
  %157 = load i32, ptr %20, align 4, !tbaa !5
  %158 = load i32, ptr %3, align 4, !tbaa !5
  %159 = icmp sle i32 %157, %158
  br i1 %159, label %161, label %160

160:                                              ; preds = %156
  store i32 14, ptr %19, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %20) #7
  br label %221

161:                                              ; preds = %156
  %162 = load i32, ptr %18, align 4, !tbaa !5
  %163 = sext i32 %162 to i64
  %164 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef %163) #7
  %165 = getelementptr inbounds %struct.node, ptr %164, i32 0, i32 4
  %166 = load i32, ptr %20, align 4, !tbaa !5
  %167 = sext i32 %166 to i64
  %168 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %165, i64 noundef %167) #7
  %169 = load i32, ptr %168, align 4, !tbaa !5
  %170 = icmp ne i32 %169, -1
  br i1 %170, label %171, label %196

171:                                              ; preds = %161
  %172 = load i32, ptr %18, align 4, !tbaa !5
  %173 = sext i32 %172 to i64
  %174 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef %173) #7
  %175 = getelementptr inbounds %struct.node, ptr %174, i32 0, i32 4
  %176 = load i32, ptr %20, align 4, !tbaa !5
  %177 = sext i32 %176 to i64
  %178 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %175, i64 noundef %177) #7
  %179 = load i32, ptr %178, align 4, !tbaa !5
  %180 = icmp ne i32 %179, -2
  br i1 %180, label %181, label %196

181:                                              ; preds = %171
  %182 = load i32, ptr %18, align 4, !tbaa !5
  %183 = sext i32 %182 to i64
  %184 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef %183) #7
  %185 = getelementptr inbounds %struct.node, ptr %184, i32 0, i32 4
  %186 = load i32, ptr %20, align 4, !tbaa !5
  %187 = sext i32 %186 to i64
  %188 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %185, i64 noundef %187) #7
  %189 = load i32, ptr %188, align 4, !tbaa !5
  %190 = load i32, ptr %18, align 4, !tbaa !5
  %191 = sext i32 %190 to i64
  %192 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef %191) #7
  %193 = getelementptr inbounds %struct.node, ptr %192, i32 0, i32 2
  %194 = load i32, ptr %193, align 8, !tbaa !22
  %195 = add nsw i32 %194, %189
  store i32 %195, ptr %193, align 8, !tbaa !22
  br label %196

196:                                              ; preds = %181, %171, %161
  %197 = load i32, ptr %18, align 4, !tbaa !5
  %198 = sext i32 %197 to i64
  %199 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef %198) #7
  %200 = getelementptr inbounds %struct.node, ptr %199, i32 0, i32 4
  %201 = load i32, ptr %20, align 4, !tbaa !5
  %202 = sext i32 %201 to i64
  %203 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %200, i64 noundef %202) #7
  %204 = load i32, ptr %203, align 4, !tbaa !5
  %205 = load i32, ptr %20, align 4, !tbaa !5
  %206 = sext i32 %205 to i64
  %207 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %14, i64 noundef %206) #7
  %208 = load i32, ptr %207, align 4, !tbaa !5
  %209 = icmp eq i32 %204, %208
  br i1 %209, label %210, label %217

210:                                              ; preds = %196
  %211 = load i32, ptr %18, align 4, !tbaa !5
  %212 = sext i32 %211 to i64
  %213 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef %212) #7
  %214 = getelementptr inbounds %struct.node, ptr %213, i32 0, i32 5
  %215 = load i32, ptr %214, align 8, !tbaa !23
  %216 = add nsw i32 %215, 1
  store i32 %216, ptr %214, align 8, !tbaa !23
  br label %217

217:                                              ; preds = %210, %196
  br label %218

218:                                              ; preds = %217
  %219 = load i32, ptr %20, align 4, !tbaa !5
  %220 = add nsw i32 %219, 1
  store i32 %220, ptr %20, align 4, !tbaa !5
  br label %156, !llvm.loop !24

221:                                              ; preds = %160
  br label %222

222:                                              ; preds = %221
  %223 = load i32, ptr %18, align 4, !tbaa !5
  %224 = add nsw i32 %223, 1
  store i32 %224, ptr %18, align 4, !tbaa !5
  br label %150, !llvm.loop !25

225:                                              ; preds = %154
  call void @llvm.lifetime.start.p0(i64 8, ptr %22) #7
  %226 = call ptr @_ZNSt6vectorI4nodeSaIS0_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %8) #7
  %227 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %22, i32 0, i32 0
  store ptr %226, ptr %227, align 8
  %228 = call ptr @_ZNK9__gnu_cxx17__normal_iteratorIP4nodeSt6vectorIS1_SaIS1_EEEplEl(ptr noundef nonnull align 8 dereferenceable(8) %22, i64 noundef 1) #7
  %229 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %21, i32 0, i32 0
  store ptr %228, ptr %229, align 8
  %230 = call ptr @_ZNSt6vectorI4nodeSaIS0_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %8) #7
  %231 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %23, i32 0, i32 0
  store ptr %230, ptr %231, align 8
  %232 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %21, i32 0, i32 0
  %233 = load ptr, ptr %232, align 8
  %234 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %23, i32 0, i32 0
  %235 = load ptr, ptr %234, align 8
  invoke void @_ZSt4sortIN9__gnu_cxx17__normal_iteratorIP4nodeSt6vectorIS2_SaIS2_EEEEPFbS2_S2_EEvT_SA_T0_(ptr %233, ptr %235, ptr noundef @_Z4cmp14nodeS_)
          to label %236 unwind label %242

236:                                              ; preds = %225
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %24) #7
  store i32 1, ptr %24, align 4, !tbaa !5
  br label %237

237:                                              ; preds = %279, %236
  %238 = load i32, ptr %24, align 4, !tbaa !5
  %239 = load i32, ptr %2, align 4, !tbaa !5
  %240 = icmp sle i32 %238, %239
  br i1 %240, label %246, label %241

241:                                              ; preds = %237
  store i32 17, ptr %19, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %24) #7
  br label %282

242:                                              ; preds = %225
  %243 = landingpad { ptr, i32 }
          cleanup
  %244 = extractvalue { ptr, i32 } %243, 0
  store ptr %244, ptr %10, align 8
  %245 = extractvalue { ptr, i32 } %243, 1
  store i32 %245, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #7
  br label %390

246:                                              ; preds = %237
  %247 = load i32, ptr %24, align 4, !tbaa !5
  %248 = load i32, ptr %24, align 4, !tbaa !5
  %249 = sext i32 %248 to i64
  %250 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef %249) #7
  %251 = getelementptr inbounds %struct.node, ptr %250, i32 0, i32 0
  store i32 %247, ptr %251, align 8, !tbaa !26
  %252 = load i32, ptr %24, align 4, !tbaa !5
  %253 = icmp ne i32 %252, 1
  br i1 %253, label %254, label %278

254:                                              ; preds = %246
  %255 = load i32, ptr %24, align 4, !tbaa !5
  %256 = sext i32 %255 to i64
  %257 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef %256) #7
  %258 = getelementptr inbounds %struct.node, ptr %257, i32 0, i32 2
  %259 = load i32, ptr %258, align 8, !tbaa !22
  %260 = load i32, ptr %24, align 4, !tbaa !5
  %261 = sub nsw i32 %260, 1
  %262 = sext i32 %261 to i64
  %263 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef %262) #7
  %264 = getelementptr inbounds %struct.node, ptr %263, i32 0, i32 2
  %265 = load i32, ptr %264, align 8, !tbaa !22
  %266 = icmp eq i32 %259, %265
  br i1 %266, label %267, label %278

267:                                              ; preds = %254
  %268 = load i32, ptr %24, align 4, !tbaa !5
  %269 = sub nsw i32 %268, 1
  %270 = sext i32 %269 to i64
  %271 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef %270) #7
  %272 = getelementptr inbounds %struct.node, ptr %271, i32 0, i32 0
  %273 = load i32, ptr %272, align 8, !tbaa !26
  %274 = load i32, ptr %24, align 4, !tbaa !5
  %275 = sext i32 %274 to i64
  %276 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef %275) #7
  %277 = getelementptr inbounds %struct.node, ptr %276, i32 0, i32 0
  store i32 %273, ptr %277, align 8, !tbaa !26
  br label %278

278:                                              ; preds = %267, %254, %246
  br label %279

279:                                              ; preds = %278
  %280 = load i32, ptr %24, align 4, !tbaa !5
  %281 = add nsw i32 %280, 1
  store i32 %281, ptr %24, align 4, !tbaa !5
  br label %237, !llvm.loop !27

282:                                              ; preds = %241
  call void @llvm.lifetime.start.p0(i64 4, ptr %25) #7
  store i32 1, ptr %25, align 4, !tbaa !5
  br label %283

283:                                              ; preds = %384, %282
  %284 = load i32, ptr %25, align 4, !tbaa !5
  %285 = load i32, ptr %2, align 4, !tbaa !5
  %286 = icmp sle i32 %284, %285
  br i1 %286, label %288, label %287

287:                                              ; preds = %283
  store i32 20, ptr %19, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %25) #7
  br label %388

288:                                              ; preds = %283
  %289 = load i32, ptr %25, align 4, !tbaa !5
  %290 = sext i32 %289 to i64
  %291 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef %290) #7
  %292 = getelementptr inbounds %struct.node, ptr %291, i32 0, i32 6
  %293 = load i8, ptr %292, align 4, !tbaa !20, !range !28, !noundef !29
  %294 = trunc i8 %293 to i1
  %295 = zext i1 %294 to i32
  %296 = icmp eq i32 %295, 1
  br i1 %296, label %297, label %383

297:                                              ; preds = %288
  %298 = load i32, ptr %25, align 4, !tbaa !5
  %299 = sext i32 %298 to i64
  %300 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef %299) #7
  %301 = getelementptr inbounds %struct.node, ptr %300, i32 0, i32 0
  %302 = load i32, ptr %301, align 8, !tbaa !26
  %303 = load i32, ptr %25, align 4, !tbaa !5
  %304 = sext i32 %303 to i64
  %305 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef %304) #7
  %306 = getelementptr inbounds %struct.node, ptr %305, i32 0, i32 1
  %307 = load i32, ptr %306, align 4, !tbaa !12
  %308 = load i32, ptr %25, align 4, !tbaa !5
  %309 = sext i32 %308 to i64
  %310 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef %309) #7
  %311 = getelementptr inbounds %struct.node, ptr %310, i32 0, i32 2
  %312 = load i32, ptr %311, align 8, !tbaa !22
  %313 = invoke i32 (ptr, ...) @printf(ptr noundef @.str.2, i32 noundef %302, i32 noundef %307, i32 noundef %312)
          to label %314 unwind label %320

314:                                              ; preds = %297
  call void @llvm.lifetime.start.p0(i64 4, ptr %26) #7
  store i32 1, ptr %26, align 4, !tbaa !5
  br label %315

315:                                              ; preds = %377, %314
  %316 = load i32, ptr %26, align 4, !tbaa !5
  %317 = load i32, ptr %3, align 4, !tbaa !5
  %318 = icmp sle i32 %316, %317
  br i1 %318, label %324, label %319

319:                                              ; preds = %315
  store i32 23, ptr %19, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %26) #7
  br label %380

320:                                              ; preds = %380, %297
  %321 = landingpad { ptr, i32 }
          cleanup
  %322 = extractvalue { ptr, i32 } %321, 0
  store ptr %322, ptr %10, align 8
  %323 = extractvalue { ptr, i32 } %321, 1
  store i32 %323, ptr %11, align 4
  br label %387

324:                                              ; preds = %315
  %325 = load i32, ptr %25, align 4, !tbaa !5
  %326 = sext i32 %325 to i64
  %327 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef %326) #7
  %328 = getelementptr inbounds %struct.node, ptr %327, i32 0, i32 4
  %329 = load i32, ptr %26, align 4, !tbaa !5
  %330 = sext i32 %329 to i64
  %331 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %328, i64 noundef %330) #7
  %332 = load i32, ptr %331, align 4, !tbaa !5
  %333 = icmp ne i32 %332, -1
  br i1 %333, label %334, label %359

334:                                              ; preds = %324
  %335 = load i32, ptr %25, align 4, !tbaa !5
  %336 = sext i32 %335 to i64
  %337 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef %336) #7
  %338 = getelementptr inbounds %struct.node, ptr %337, i32 0, i32 4
  %339 = load i32, ptr %26, align 4, !tbaa !5
  %340 = sext i32 %339 to i64
  %341 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %338, i64 noundef %340) #7
  %342 = load i32, ptr %341, align 4, !tbaa !5
  %343 = icmp ne i32 %342, -2
  br i1 %343, label %344, label %359

344:                                              ; preds = %334
  %345 = load i32, ptr %25, align 4, !tbaa !5
  %346 = sext i32 %345 to i64
  %347 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef %346) #7
  %348 = getelementptr inbounds %struct.node, ptr %347, i32 0, i32 4
  %349 = load i32, ptr %26, align 4, !tbaa !5
  %350 = sext i32 %349 to i64
  %351 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %348, i64 noundef %350) #7
  %352 = load i32, ptr %351, align 4, !tbaa !5
  %353 = invoke i32 (ptr, ...) @printf(ptr noundef @.str.3, i32 noundef %352)
          to label %354 unwind label %355

354:                                              ; preds = %344
  br label %376

355:                                              ; preds = %372, %369, %344
  %356 = landingpad { ptr, i32 }
          cleanup
  %357 = extractvalue { ptr, i32 } %356, 0
  store ptr %357, ptr %10, align 8
  %358 = extractvalue { ptr, i32 } %356, 1
  store i32 %358, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %26) #7
  br label %387

359:                                              ; preds = %334, %324
  %360 = load i32, ptr %25, align 4, !tbaa !5
  %361 = sext i32 %360 to i64
  %362 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef %361) #7
  %363 = getelementptr inbounds %struct.node, ptr %362, i32 0, i32 4
  %364 = load i32, ptr %26, align 4, !tbaa !5
  %365 = sext i32 %364 to i64
  %366 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %363, i64 noundef %365) #7
  %367 = load i32, ptr %366, align 4, !tbaa !5
  %368 = icmp eq i32 %367, -1
  br i1 %368, label %369, label %372

369:                                              ; preds = %359
  %370 = invoke i32 (ptr, ...) @printf(ptr noundef @.str.4)
          to label %371 unwind label %355

371:                                              ; preds = %369
  br label %375

372:                                              ; preds = %359
  %373 = invoke i32 (ptr, ...) @printf(ptr noundef @.str.5)
          to label %374 unwind label %355

374:                                              ; preds = %372
  br label %375

375:                                              ; preds = %374, %371
  br label %376

376:                                              ; preds = %375, %354
  br label %377

377:                                              ; preds = %376
  %378 = load i32, ptr %26, align 4, !tbaa !5
  %379 = add nsw i32 %378, 1
  store i32 %379, ptr %26, align 4, !tbaa !5
  br label %315, !llvm.loop !30

380:                                              ; preds = %319
  %381 = invoke i32 (ptr, ...) @printf(ptr noundef @.str.6)
          to label %382 unwind label %320

382:                                              ; preds = %380
  br label %383

383:                                              ; preds = %382, %288
  br label %384

384:                                              ; preds = %383
  %385 = load i32, ptr %25, align 4, !tbaa !5
  %386 = add nsw i32 %385, 1
  store i32 %386, ptr %25, align 4, !tbaa !5
  br label %283, !llvm.loop !31

387:                                              ; preds = %355, %320
  call void @llvm.lifetime.end.p0(i64 4, ptr %25) #7
  br label %390

388:                                              ; preds = %287
  store i32 0, ptr %1, align 4
  store i32 1, ptr %19, align 4
  call void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %14) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr %14) #7
  call void @_ZNSt6vectorI4nodeSaIS0_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %8) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr %8) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %6) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %5) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %4) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %3) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %2) #7
  %389 = load i32, ptr %1, align 4
  ret i32 %389

390:                                              ; preds = %387, %242, %122, %80
  call void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %14) #7
  br label %391

391:                                              ; preds = %390, %67
  call void @llvm.lifetime.end.p0(i64 24, ptr %14) #7
  br label %392

392:                                              ; preds = %391, %53
  call void @_ZNSt6vectorI4nodeSaIS0_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %8) #7
  br label %393

393:                                              ; preds = %392, %37
  call void @llvm.lifetime.end.p0(i64 24, ptr %8) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %6) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %5) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %4) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %3) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %2) #7
  br label %394

394:                                              ; preds = %393
  %395 = load ptr, ptr %10, align 8
  %396 = load i32, ptr %11, align 4
  %397 = insertvalue { ptr, i32 } poison, ptr %395, 0
  %398 = insertvalue { ptr, i32 } %397, i32 %396, 1
  resume { ptr, i32 } %398
}

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

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

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

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

declare i32 @__gxx_personality_v0(...)

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

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

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

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

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3maxIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4), ptr noundef nonnull align 4 dereferenceable(4)) #5

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

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

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

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

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

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

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

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

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

attributes #0 = { 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 #1 = { 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 #2 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #3 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #4 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #5 = { inlinehint mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #6 = { 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 #7 = { nounwind }

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"int", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = distinct !{!9, !10}
!10 = !{!"llvm.loop.mustprogress"}
!11 = distinct !{!11, !10}
!12 = !{!13, !6, i64 4}
!13 = !{!"_ZTS4node", !6, i64 0, !6, i64 4, !6, i64 8, !14, i64 16, !6, i64 40, !19, i64 44}
!14 = !{!"_ZTSSt6vectorIiSaIiEE", !15, i64 0}
!15 = !{!"_ZTSSt12_Vector_baseIiSaIiEE", !16, i64 0}
!16 = !{!"_ZTSNSt12_Vector_baseIiSaIiEE12_Vector_implE", !17, i64 0}
!17 = !{!"_ZTSNSt12_Vector_baseIiSaIiEE17_Vector_impl_dataE", !18, i64 0, !18, i64 8, !18, i64 16}
!18 = !{!"any pointer", !7, i64 0}
!19 = !{!"bool", !7, i64 0}
!20 = !{!13, !19, i64 44}
!21 = distinct !{!21, !10}
!22 = !{!13, !6, i64 8}
!23 = !{!13, !6, i64 40}
!24 = distinct !{!24, !10}
!25 = distinct !{!25, !10}
!26 = !{!13, !6, i64 0}
!27 = distinct !{!27, !10}
!28 = !{i8 0, i8 2}
!29 = !{}
!30 = distinct !{!30, !10}
!31 = distinct !{!31, !10}


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

%"class.std::vector.0" = type { %"struct.std::_Vector_base.1" }
%"struct.std::_Vector_base.1" = type { %"struct.std::_Vector_base<node, std::allocator<node>>::_Vector_impl" }
%"struct.std::_Vector_base<node, std::allocator<node>>::_Vector_impl" = type { %"struct.std::_Vector_base<node, std::allocator<node>>::_Vector_impl_data" }
%"struct.std::_Vector_base<node, std::allocator<node>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::allocator.2" = type { i8 }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::allocator" = type { i8 }
%"class.__gnu_cxx::__normal_iterator" = type { ptr }

@.str = external hidden unnamed_addr constant [9 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [11 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [2 x i8], align 1

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_Z4cmp14nodeS_(ptr noundef, ptr noundef) #0

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() local_unnamed_addr #1 personality ptr @__gxx_personality_v0 {
  %1 = alloca i32, align 4
  %2 = alloca i32, align 4
  %3 = alloca i32, align 4
  %4 = alloca i32, align 4
  %5 = alloca i32, align 4
  %6 = alloca i32, align 4
  %7 = alloca %"class.std::vector.0", align 8
  %8 = alloca %"class.std::allocator.2", align 1
  %9 = alloca i32, align 4
  %10 = alloca %"class.std::vector", align 8
  %11 = alloca %"class.std::allocator", align 1
  %12 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %1) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %2) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %3) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %4) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %5) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %6) #7
  %13 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull %1, ptr noundef nonnull %2, ptr noundef nonnull %3)
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %7) #7
  %14 = load i32, ptr %1, align 4, !tbaa !5
  %15 = add nsw i32 %14, 1
  %16 = sext i32 %15 to i64
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %8) #7
  call void @_ZNSaI4nodeEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %8) #7
  invoke void @_ZNSt6vectorI4nodeSaIS0_EEC2EmRKS1_(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef %16, ptr noundef nonnull align 1 dereferenceable(1) %8)
          to label %17 unwind label %22

17:                                               ; preds = %0
  call void @_ZNSt15__new_allocatorI4nodeED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %8) #7
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %8) #7
  %18 = load i32, ptr %1, align 4, !tbaa !5
  %.not81 = icmp slt i32 %18, 1
  br i1 %.not81, label %._crit_edge, label %.lr.ph

._crit_edge:                                      ; preds = %29, %17
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %10) #7
  %19 = load i32, ptr %2, align 4, !tbaa !5
  %20 = add nsw i32 %19, 1
  %21 = sext i32 %20 to i64
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %11) #7
  call void @_ZNSaIiEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %11) #7
  invoke void @_ZNSt6vectorIiSaIiEEC2EmRKS0_(ptr noundef nonnull align 8 dereferenceable(24) %10, i64 noundef %21, ptr noundef nonnull align 1 dereferenceable(1) %11)
          to label %34 unwind label %38

22:                                               ; preds = %0
  %23 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt15__new_allocatorI4nodeED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %8) #7
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %8) #7
  br label %209

.lr.ph:                                           ; preds = %17, %29
  %indvars.iv = phi i64 [ %indvars.iv.next, %29 ], [ 1, %17 ]
  %24 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef %indvars.iv) #7
  %25 = getelementptr inbounds i8, ptr %24, i64 16
  %26 = load i32, ptr %2, align 4, !tbaa !5
  %27 = add nsw i32 %26, 1
  %28 = sext i32 %27 to i64
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %9) #7
  store i32 -1, ptr %9, align 4, !tbaa !5
  invoke void @_ZNSt6vectorIiSaIiEE6resizeEmRKi(ptr noundef nonnull align 8 dereferenceable(24) %25, i64 noundef %28, ptr noundef nonnull align 4 dereferenceable(4) %9)
          to label %29 unwind label %32

29:                                               ; preds = %.lr.ph
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %9) #7
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %30 = load i32, ptr %1, align 4, !tbaa !5
  %31 = sext i32 %30 to i64
  %.not.not = icmp slt i64 %indvars.iv, %31
  br i1 %.not.not, label %.lr.ph, label %._crit_edge, !llvm.loop !9

32:                                               ; preds = %.lr.ph
  %33 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %9) #7
  br label %208

34:                                               ; preds = %._crit_edge
  call void @_ZNSt15__new_allocatorIiED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %11) #7
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %11) #7
  %35 = load i32, ptr %2, align 4, !tbaa !5
  %.not6283 = icmp slt i32 %35, 1
  br i1 %.not6283, label %.preheader80, label %.lr.ph86

.preheader80:                                     ; preds = %.lr.ph86, %34
  %36 = load i32, ptr %3, align 4, !tbaa !5
  %37 = icmp sgt i32 %36, 0
  br i1 %37, label %.lr.ph88, label %.preheader79

38:                                               ; preds = %._crit_edge
  %39 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt15__new_allocatorIiED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %11) #7
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %11) #7
  br label %207

.lr.ph86:                                         ; preds = %34, %.lr.ph86
  %indvars.iv111 = phi i64 [ %indvars.iv.next112, %.lr.ph86 ], [ 1, %34 ]
  %40 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %10, i64 noundef %indvars.iv111) #7
  %41 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str.1, ptr noundef nonnull %40)
  %indvars.iv.next112 = add nuw nsw i64 %indvars.iv111, 1
  %42 = load i32, ptr %2, align 4, !tbaa !5
  %43 = sext i32 %42 to i64
  %.not62.not = icmp slt i64 %indvars.iv111, %43
  br i1 %.not62.not, label %.lr.ph86, label %.preheader80, !llvm.loop !11

.preheader79:                                     ; preds = %89, %.preheader80
  %44 = load i32, ptr %1, align 4, !tbaa !5
  %.not6393 = icmp slt i32 %44, 1
  %45 = load i32, ptr %2, align 4
  %46 = icmp slt i32 %45, 1
  %or.cond = select i1 %.not6393, i1 true, i1 %46
  br i1 %or.cond, label %._crit_edge95, label %.preheader78

.lr.ph88:                                         ; preds = %.preheader80, %89
  %.05687 = phi i32 [ %90, %89 ], [ 0, %.preheader80 ]
  %47 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull %4, ptr noundef nonnull %5, ptr noundef nonnull %6)
  %48 = load i32, ptr %4, align 4, !tbaa !5
  %49 = sext i32 %48 to i64
  %50 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef %49) #7
  %51 = getelementptr inbounds i8, ptr %50, i64 4
  store i32 %48, ptr %51, align 4, !tbaa !12
  %52 = load i32, ptr %4, align 4, !tbaa !5
  %53 = sext i32 %52 to i64
  %54 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef %53) #7
  %55 = getelementptr inbounds i8, ptr %54, i64 16
  %56 = load i32, ptr %5, align 4, !tbaa !5
  %57 = sext i32 %56 to i64
  %58 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %55, i64 noundef %57) #7
  %59 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3maxIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %58, ptr noundef nonnull align 4 dereferenceable(4) %6)
  %60 = load i32, ptr %59, align 4, !tbaa !5
  %61 = load i32, ptr %4, align 4, !tbaa !5
  %62 = sext i32 %61 to i64
  %63 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef %62) #7
  %64 = getelementptr inbounds i8, ptr %63, i64 16
  %65 = load i32, ptr %5, align 4, !tbaa !5
  %66 = sext i32 %65 to i64
  %67 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %64, i64 noundef %66) #7
  store i32 %60, ptr %67, align 4, !tbaa !5
  %68 = load i32, ptr %6, align 4, !tbaa !5
  %.not74 = icmp eq i32 %68, -1
  %69 = load i32, ptr %4, align 4, !tbaa !5
  %70 = sext i32 %69 to i64
  %71 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef %70) #7
  br i1 %.not74, label %74, label %72

72:                                               ; preds = %.lr.ph88
  %73 = getelementptr inbounds i8, ptr %71, i64 44
  store i8 1, ptr %73, align 4, !tbaa !20
  br label %89

74:                                               ; preds = %.lr.ph88
  %75 = getelementptr inbounds i8, ptr %71, i64 16
  %76 = load i32, ptr %5, align 4, !tbaa !5
  %77 = sext i32 %76 to i64
  %78 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %75, i64 noundef %77) #7
  %79 = load i32, ptr %78, align 4, !tbaa !5
  %80 = icmp eq i32 %79, -1
  br i1 %80, label %81, label %89

81:                                               ; preds = %74
  %82 = load i32, ptr %4, align 4, !tbaa !5
  %83 = sext i32 %82 to i64
  %84 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef %83) #7
  %85 = getelementptr inbounds i8, ptr %84, i64 16
  %86 = load i32, ptr %5, align 4, !tbaa !5
  %87 = sext i32 %86 to i64
  %88 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %85, i64 noundef %87) #7
  store i32 -2, ptr %88, align 4, !tbaa !5
  br label %89

89:                                               ; preds = %72, %81, %74
  %90 = add nuw nsw i32 %.05687, 1
  %91 = load i32, ptr %3, align 4, !tbaa !5
  %92 = icmp slt i32 %90, %91
  br i1 %92, label %.lr.ph88, label %.preheader79, !llvm.loop !21

.preheader78:                                     ; preds = %.preheader79, %._crit_edge92
  %93 = phi i32 [ %98, %._crit_edge92 ], [ %44, %.preheader79 ]
  %94 = phi i32 [ %99, %._crit_edge92 ], [ %45, %.preheader79 ]
  %indvars.iv117 = phi i64 [ %indvars.iv.next118, %._crit_edge92 ], [ 1, %.preheader79 ]
  %.not7189 = icmp slt i32 %94, 1
  br i1 %.not7189, label %._crit_edge92, label %.lr.ph91

._crit_edge95:                                    ; preds = %._crit_edge92, %.preheader79
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %12) #7
  %95 = call ptr @_ZNSt6vectorI4nodeSaIS0_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %7) #7
  store ptr %95, ptr %12, align 8
  %96 = call ptr @_ZNK9__gnu_cxx17__normal_iteratorIP4nodeSt6vectorIS1_SaIS1_EEEplEl(ptr noundef nonnull align 8 dereferenceable(8) %12, i64 noundef 1) #7
  %97 = call ptr @_ZNSt6vectorI4nodeSaIS0_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %7) #7
  invoke void @_ZSt4sortIN9__gnu_cxx17__normal_iteratorIP4nodeSt6vectorIS2_SaIS2_EEEEPFbS2_S2_EEvT_SA_T0_(ptr %96, ptr %97, ptr noundef nonnull @_Z4cmp14nodeS_)
          to label %135 unwind label %141

._crit_edge92.loopexit:                           ; preds = %132
  %.pre = load i32, ptr %1, align 4, !tbaa !5
  br label %._crit_edge92

._crit_edge92:                                    ; preds = %._crit_edge92.loopexit, %.preheader78
  %98 = phi i32 [ %.pre, %._crit_edge92.loopexit ], [ %93, %.preheader78 ]
  %99 = phi i32 [ %133, %._crit_edge92.loopexit ], [ %94, %.preheader78 ]
  %indvars.iv.next118 = add nuw nsw i64 %indvars.iv117, 1
  %100 = sext i32 %98 to i64
  %.not63.not = icmp slt i64 %indvars.iv117, %100
  br i1 %.not63.not, label %.preheader78, label %._crit_edge95, !llvm.loop !22

.lr.ph91:                                         ; preds = %.preheader78, %132
  %indvars.iv114 = phi i64 [ %indvars.iv.next115, %132 ], [ 1, %.preheader78 ]
  %101 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef %indvars.iv117) #7
  %102 = getelementptr inbounds i8, ptr %101, i64 16
  %103 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %102, i64 noundef %indvars.iv114) #7
  %104 = load i32, ptr %103, align 4, !tbaa !5
  %.not72 = icmp eq i32 %104, -1
  br i1 %.not72, label %119, label %105

105:                                              ; preds = %.lr.ph91
  %106 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef %indvars.iv117) #7
  %107 = getelementptr inbounds i8, ptr %106, i64 16
  %108 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %107, i64 noundef %indvars.iv114) #7
  %109 = load i32, ptr %108, align 4, !tbaa !5
  %.not73 = icmp eq i32 %109, -2
  br i1 %.not73, label %119, label %110

110:                                              ; preds = %105
  %111 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef %indvars.iv117) #7
  %112 = getelementptr inbounds i8, ptr %111, i64 16
  %113 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %112, i64 noundef %indvars.iv114) #7
  %114 = load i32, ptr %113, align 4, !tbaa !5
  %115 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef %indvars.iv117) #7
  %116 = getelementptr inbounds i8, ptr %115, i64 8
  %117 = load i32, ptr %116, align 8, !tbaa !24
  %118 = add nsw i32 %117, %114
  store i32 %118, ptr %116, align 8, !tbaa !24
  br label %119

119:                                              ; preds = %110, %105, %.lr.ph91
  %120 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef %indvars.iv117) #7
  %121 = getelementptr inbounds i8, ptr %120, i64 16
  %122 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %121, i64 noundef %indvars.iv114) #7
  %123 = load i32, ptr %122, align 4, !tbaa !5
  %124 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %10, i64 noundef %indvars.iv114) #7
  %125 = load i32, ptr %124, align 4, !tbaa !5
  %126 = icmp eq i32 %123, %125
  br i1 %126, label %127, label %132

127:                                              ; preds = %119
  %128 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef %indvars.iv117) #7
  %129 = getelementptr inbounds i8, ptr %128, i64 40
  %130 = load i32, ptr %129, align 8, !tbaa !25
  %131 = add nsw i32 %130, 1
  store i32 %131, ptr %129, align 8, !tbaa !25
  br label %132

132:                                              ; preds = %119, %127
  %indvars.iv.next115 = add nuw nsw i64 %indvars.iv114, 1
  %133 = load i32, ptr %2, align 4, !tbaa !5
  %134 = sext i32 %133 to i64
  %.not71.not = icmp slt i64 %indvars.iv114, %134
  br i1 %.not71.not, label %.lr.ph91, label %._crit_edge92.loopexit, !llvm.loop !26

135:                                              ; preds = %._crit_edge95
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %12) #7
  %136 = load i32, ptr %1, align 4, !tbaa !5
  %.not6596 = icmp slt i32 %136, 1
  br i1 %.not6596, label %._crit_edge108, label %137

137:                                              ; preds = %135
  %138 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef 1) #7
  store i32 1, ptr %138, align 8, !tbaa !27
  %.pre131 = load i32, ptr %1, align 4, !tbaa !5
  %.not65.not.peel = icmp sgt i32 %.pre131, 1
  br i1 %.not65.not.peel, label %.lr.ph99.peel.next, label %.preheader

.preheader:                                       ; preds = %157, %137
  %139 = phi i32 [ %.pre131, %137 ], [ %158, %157 ]
  %140 = icmp slt i32 %139, 1
  br i1 %140, label %._crit_edge108, label %.lr.ph107

141:                                              ; preds = %._crit_edge95
  %142 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %12) #7
  call void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %10) #7
  br label %207

.lr.ph99.peel.next:                               ; preds = %137, %157
  %indvars.iv120 = phi i64 [ %indvars.iv.next121, %157 ], [ 2, %137 ]
  %143 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef %indvars.iv120) #7
  %144 = trunc nuw nsw i64 %indvars.iv120 to i32
  store i32 %144, ptr %143, align 8, !tbaa !27
  %145 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef %indvars.iv120) #7
  %146 = getelementptr inbounds i8, ptr %145, i64 8
  %147 = load i32, ptr %146, align 8, !tbaa !24
  %148 = add nsw i64 %indvars.iv120, -1
  %149 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef %148) #7
  %150 = getelementptr inbounds i8, ptr %149, i64 8
  %151 = load i32, ptr %150, align 8, !tbaa !24
  %152 = icmp eq i32 %147, %151
  br i1 %152, label %153, label %157

153:                                              ; preds = %.lr.ph99.peel.next
  %154 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef %148) #7
  %155 = load i32, ptr %154, align 8, !tbaa !27
  %156 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef %indvars.iv120) #7
  store i32 %155, ptr %156, align 8, !tbaa !27
  br label %157

157:                                              ; preds = %.lr.ph99.peel.next, %153
  %indvars.iv.next121 = add nuw nsw i64 %indvars.iv120, 1
  %158 = load i32, ptr %1, align 4, !tbaa !5
  %159 = sext i32 %158 to i64
  %.not65.not = icmp slt i64 %indvars.iv120, %159
  br i1 %.not65.not, label %.lr.ph99.peel.next, label %.preheader, !llvm.loop !28

._crit_edge108:                                   ; preds = %204, %135, %.preheader
  call void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %10) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %10) #7
  call void @_ZNSt6vectorI4nodeSaIS0_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %7) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %7) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %6) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %5) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %4) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %3) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %2) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %1) #7
  ret i32 0

.lr.ph107:                                        ; preds = %.preheader, %204
  %indvars.iv127 = phi i64 [ %indvars.iv.next128, %204 ], [ 1, %.preheader ]
  %160 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef %indvars.iv127) #7
  %161 = getelementptr inbounds i8, ptr %160, i64 44
  %162 = load i8, ptr %161, align 4, !tbaa !20, !range !30, !noundef !31
  %163 = trunc nuw i8 %162 to i1
  br i1 %163, label %164, label %204

164:                                              ; preds = %.lr.ph107
  %165 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef %indvars.iv127) #7
  %166 = load i32, ptr %165, align 8, !tbaa !27
  %167 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef %indvars.iv127) #7
  %168 = getelementptr inbounds i8, ptr %167, i64 4
  %169 = load i32, ptr %168, align 4, !tbaa !12
  %170 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef %indvars.iv127) #7
  %171 = getelementptr inbounds i8, ptr %170, i64 8
  %172 = load i32, ptr %171, align 8, !tbaa !24
  %173 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.2, i32 noundef %166, i32 noundef %169, i32 noundef %172)
  %174 = load i32, ptr %2, align 4, !tbaa !5
  %.not67100 = icmp slt i32 %174, 1
  br i1 %.not67100, label %._crit_edge104, label %.lr.ph103

._crit_edge104:                                   ; preds = %201, %164
  %175 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.6)
  br label %204

.lr.ph103:                                        ; preds = %164, %201
  %indvars.iv124 = phi i64 [ %indvars.iv.next125, %201 ], [ 1, %164 ]
  %176 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef %indvars.iv127) #7
  %177 = getelementptr inbounds i8, ptr %176, i64 16
  %178 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %177, i64 noundef %indvars.iv124) #7
  %179 = load i32, ptr %178, align 4, !tbaa !5
  %.not68 = icmp eq i32 %179, -1
  br i1 %.not68, label %191, label %180

180:                                              ; preds = %.lr.ph103
  %181 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef %indvars.iv127) #7
  %182 = getelementptr inbounds i8, ptr %181, i64 16
  %183 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %182, i64 noundef %indvars.iv124) #7
  %184 = load i32, ptr %183, align 4, !tbaa !5
  %.not69 = icmp eq i32 %184, -2
  br i1 %.not69, label %191, label %185

185:                                              ; preds = %180
  %186 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef %indvars.iv127) #7
  %187 = getelementptr inbounds i8, ptr %186, i64 16
  %188 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %187, i64 noundef %indvars.iv124) #7
  %189 = load i32, ptr %188, align 4, !tbaa !5
  %190 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.3, i32 noundef %189)
  br label %201

191:                                              ; preds = %180, %.lr.ph103
  %192 = call noundef nonnull align 8 dereferenceable(45) ptr @_ZNSt6vectorI4nodeSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef %indvars.iv127) #7
  %193 = getelementptr inbounds i8, ptr %192, i64 16
  %194 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %193, i64 noundef %indvars.iv124) #7
  %195 = load i32, ptr %194, align 4, !tbaa !5
  %196 = icmp eq i32 %195, -1
  br i1 %196, label %197, label %199

197:                                              ; preds = %191
  %198 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.4)
  br label %201

199:                                              ; preds = %191
  %200 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.5)
  br label %201

201:                                              ; preds = %185, %199, %197
  %indvars.iv.next125 = add nuw nsw i64 %indvars.iv124, 1
  %202 = load i32, ptr %2, align 4, !tbaa !5
  %203 = sext i32 %202 to i64
  %.not67.not = icmp slt i64 %indvars.iv124, %203
  br i1 %.not67.not, label %.lr.ph103, label %._crit_edge104, !llvm.loop !32

204:                                              ; preds = %.lr.ph107, %._crit_edge104
  %indvars.iv.next128 = add nuw nsw i64 %indvars.iv127, 1
  %205 = load i32, ptr %1, align 4, !tbaa !5
  %206 = sext i32 %205 to i64
  %.not66.not = icmp slt i64 %indvars.iv127, %206
  br i1 %.not66.not, label %.lr.ph107, label %._crit_edge108, !llvm.loop !33

207:                                              ; preds = %141, %38
  %.pn = phi { ptr, i32 } [ %142, %141 ], [ %39, %38 ]
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %10) #7
  br label %208

208:                                              ; preds = %207, %32
  %.pn75 = phi { ptr, i32 } [ %33, %32 ], [ %.pn, %207 ]
  call void @_ZNSt6vectorI4nodeSaIS0_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %7) #7
  br label %209

209:                                              ; preds = %208, %22
  %.pn75.pn = phi { ptr, i32 } [ %.pn75, %208 ], [ %23, %22 ]
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %7) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %6) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %5) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %4) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %3) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %2) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %1) #7
  resume { ptr, i32 } %.pn75.pn
}

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

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

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

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

declare i32 @__gxx_personality_v0(...)

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

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

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

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

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3maxIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4), ptr noundef nonnull align 4 dereferenceable(4)) local_unnamed_addr #5

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

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

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

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

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

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

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

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

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

attributes #0 = { 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 #1 = { 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 #2 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #3 = { 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 #4 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #5 = { inlinehint mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #6 = { 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 #7 = { nounwind }

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"int", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = distinct !{!9, !10}
!10 = !{!"llvm.loop.mustprogress"}
!11 = distinct !{!11, !10}
!12 = !{!13, !6, i64 4}
!13 = !{!"_ZTS4node", !6, i64 0, !6, i64 4, !6, i64 8, !14, i64 16, !6, i64 40, !19, i64 44}
!14 = !{!"_ZTSSt6vectorIiSaIiEE", !15, i64 0}
!15 = !{!"_ZTSSt12_Vector_baseIiSaIiEE", !16, i64 0}
!16 = !{!"_ZTSNSt12_Vector_baseIiSaIiEE12_Vector_implE", !17, i64 0}
!17 = !{!"_ZTSNSt12_Vector_baseIiSaIiEE17_Vector_impl_dataE", !18, i64 0, !18, i64 8, !18, i64 16}
!18 = !{!"any pointer", !7, i64 0}
!19 = !{!"bool", !7, i64 0}
!20 = !{!13, !19, i64 44}
!21 = distinct !{!21, !10}
!22 = distinct !{!22, !10, !23}
!23 = !{!"llvm.loop.unswitch.partial.disable"}
!24 = !{!13, !6, i64 8}
!25 = !{!13, !6, i64 40}
!26 = distinct !{!26, !10}
!27 = !{!13, !6, i64 0}
!28 = distinct !{!28, !10, !29}
!29 = !{!"llvm.loop.peeled.count", i32 1}
!30 = !{i8 0, i8 2}
!31 = !{}
!32 = distinct !{!32, !10}
!33 = distinct !{!33, !10}


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