; LLVM IR from Izaron/ACM-ICPC :: Russian Council of School Olympiads (R.S.O.Sh.)/IOIP/IOIP 2017 (parallelepiped)

; 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::basic_istream" = type { ptr, i64, %"class.std::basic_ios" }
%"class.std::basic_ios" = type { %"class.std::ios_base", ptr, i8, i8, ptr, ptr, ptr, ptr }
%"class.std::ios_base" = type { ptr, i64, i64, i32, i32, i32, ptr, %"struct.std::ios_base::_Words", [8 x %"struct.std::ios_base::_Words"], i32, ptr, %"class.std::locale" }
%"struct.std::ios_base::_Words" = type { ptr, i64 }
%"class.std::locale" = type { ptr }
%"class.std::basic_ostream" = type { ptr, %"class.std::basic_ios" }
%"class.std::map" = type { %"class.std::_Rb_tree" }
%"class.std::_Rb_tree" = type { %"struct.std::_Rb_tree<std::pair<int, int>, std::pair<const std::pair<int, int>, int>, std::_Select1st<std::pair<const std::pair<int, int>, int>>, std::less<std::pair<int, int>>>::_Rb_tree_impl" }
%"struct.std::_Rb_tree<std::pair<int, int>, std::pair<const std::pair<int, int>, int>, std::_Select1st<std::pair<const std::pair<int, int>, int>>, std::less<std::pair<int, int>>>::_Rb_tree_impl" = type { [8 x i8], %"struct.std::_Rb_tree_header" }
%"struct.std::_Rb_tree_header" = type { %"struct.std::_Rb_tree_node_base", i64 }
%"struct.std::_Rb_tree_node_base" = type { i32, ptr, ptr, ptr }
%"struct.std::pair" = type { i32, i32 }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<std::pair<int, int>, std::allocator<std::pair<int, int>>>::_Vector_impl" }
%"struct.std::_Vector_base<std::pair<int, int>, std::allocator<std::pair<int, int>>>::_Vector_impl" = type { %"struct.std::_Vector_base<std::pair<int, int>, std::allocator<std::pair<int, int>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<std::pair<int, int>, std::allocator<std::pair<int, int>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"struct.std::_Rb_tree_iterator" = type { ptr }
%"struct.std::pair.3" = type { %"struct.std::pair", i32 }
%"class.__gnu_cxx::__normal_iterator" = type { ptr }
%"class.std::vector.5" = type { %"struct.std::_Vector_base.6" }
%"struct.std::_Vector_base.6" = type { %"struct.std::_Vector_base<std::set<int>, std::allocator<std::set<int>>>::_Vector_impl" }
%"struct.std::_Vector_base<std::set<int>, std::allocator<std::set<int>>>::_Vector_impl" = type { %"struct.std::_Vector_base<std::set<int>, std::allocator<std::set<int>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<std::set<int>, std::allocator<std::set<int>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::allocator.7" = type { i8 }
%"struct.std::pair.15" = type <{ %"struct.std::_Rb_tree_const_iterator", i8, [7 x i8] }>
%"struct.std::_Rb_tree_const_iterator" = type { ptr }

@.str = external hidden unnamed_addr constant [18 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [2 x i8], align 1
@stdin = external global ptr, align 8
@.str.2 = external hidden unnamed_addr constant [19 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [2 x i8], align 1
@stdout = external global ptr, align 8
@_ZSt3cin = external global %"class.std::basic_istream", align 8
@_ZSt4cout = external global %"class.std::basic_ostream", align 8

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() #0 personality ptr @__gxx_personality_v0 {
  %1 = alloca i32, align 4
  %2 = alloca i32, align 4
  %3 = alloca %"class.std::map", align 8
  %4 = alloca i32, align 4
  %5 = alloca i32, align 4
  %6 = alloca i32, align 4
  %7 = alloca ptr, align 8
  %8 = alloca i32, align 4
  %9 = alloca %"struct.std::pair", align 4
  %10 = alloca %"class.std::vector", align 8
  %11 = alloca ptr, align 8
  %12 = alloca %"struct.std::_Rb_tree_iterator", align 8
  %13 = alloca %"struct.std::_Rb_tree_iterator", align 8
  %14 = alloca %"struct.std::pair.3", align 4
  %15 = alloca ptr, align 8
  %16 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %17 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %18 = alloca %"struct.std::pair", align 4
  %19 = alloca ptr, align 8
  %20 = alloca %"struct.std::_Rb_tree_iterator", align 8
  %21 = alloca %"struct.std::_Rb_tree_iterator", align 8
  %22 = alloca ptr, align 8
  %23 = alloca i64, align 8
  %24 = alloca ptr, align 8
  %25 = alloca %"struct.std::_Rb_tree_iterator", align 8
  %26 = alloca %"struct.std::_Rb_tree_iterator", align 8
  %27 = alloca %"struct.std::pair.3", align 4
  %28 = alloca %"struct.std::pair", align 4
  %29 = alloca i64, align 8
  %30 = alloca ptr, align 8
  %31 = alloca %"struct.std::_Rb_tree_iterator", align 8
  %32 = alloca %"struct.std::_Rb_tree_iterator", align 8
  %33 = alloca %"struct.std::pair.3", align 4
  %34 = alloca %"struct.std::pair", align 4
  %35 = alloca %"struct.std::pair", align 4
  %36 = alloca %"struct.std::pair", align 4
  %37 = alloca i64, align 8
  %38 = alloca i64, align 8
  %39 = alloca %"class.std::vector", align 8
  %40 = alloca ptr, align 8
  %41 = alloca %"struct.std::_Rb_tree_iterator", align 8
  %42 = alloca %"struct.std::_Rb_tree_iterator", align 8
  %43 = alloca %"struct.std::pair.3", align 4
  %44 = alloca %"class.std::vector.5", align 8
  %45 = alloca %"class.std::allocator.7", align 1
  %46 = alloca ptr, align 8
  %47 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %48 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %49 = alloca %"struct.std::pair", align 4
  %50 = alloca %"struct.std::pair.15", align 8
  %51 = alloca i32, align 4
  %52 = alloca i32, align 4
  %53 = alloca i32, align 4
  %54 = alloca i32, align 4
  %55 = alloca ptr, align 8
  %56 = alloca %"struct.std::_Rb_tree_const_iterator", align 8
  %57 = alloca %"struct.std::_Rb_tree_const_iterator", align 8
  %58 = alloca i32, align 4
  %59 = alloca i64, align 8
  %60 = alloca ptr, align 8
  %61 = alloca %"struct.std::_Rb_tree_const_iterator", align 8
  %62 = alloca %"struct.std::_Rb_tree_const_iterator", align 8
  %63 = alloca i32, align 4
  %64 = alloca i64, align 8
  store i32 0, ptr %1, align 4
  %65 = load ptr, ptr @stdin, align 8, !tbaa !5
  %66 = call ptr @freopen(ptr noundef @.str, ptr noundef @.str.1, ptr noundef %65)
  %67 = load ptr, ptr @stdout, align 8, !tbaa !5
  %68 = call ptr @freopen(ptr noundef @.str.2, ptr noundef @.str.3, ptr noundef %67)
  call void @llvm.lifetime.start.p0(i64 4, ptr %2) #8
  %69 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERi(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 4 dereferenceable(4) %2)
  call void @llvm.lifetime.start.p0(i64 48, ptr %3) #8
  call void @_ZNSt3mapISt4pairIiiEiSt4lessIS1_ESaIS0_IKS1_iEEEC2Ev(ptr noundef nonnull align 8 dereferenceable(48) %3) #8
  call void @llvm.lifetime.start.p0(i64 4, ptr %4) #8
  store i32 0, ptr %4, align 4, !tbaa !9
  br label %70

70:                                               ; preds = %94, %0
  %71 = load i32, ptr %4, align 4, !tbaa !9
  %72 = load i32, ptr %2, align 4, !tbaa !9
  %73 = icmp slt i32 %71, %72
  br i1 %73, label %75, label %74

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

75:                                               ; preds = %70
  call void @llvm.lifetime.start.p0(i64 4, ptr %5) #8
  call void @llvm.lifetime.start.p0(i64 4, ptr %6) #8
  %76 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERi(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 4 dereferenceable(4) %5)
          to label %77 unwind label %84

77:                                               ; preds = %75
  %78 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERi(ptr noundef nonnull align 8 dereferenceable(16) %76, ptr noundef nonnull align 4 dereferenceable(4) %6)
          to label %79 unwind label %84

79:                                               ; preds = %77
  %80 = load i32, ptr %5, align 4, !tbaa !9
  %81 = load i32, ptr %6, align 4, !tbaa !9
  %82 = icmp sgt i32 %80, %81
  br i1 %82, label %83, label %88

83:                                               ; preds = %79
  call void @_ZSt4swapIiENSt9enable_ifIXsr6__and_ISt6__not_ISt15__is_tuple_likeIT_EESt21is_move_constructibleIS3_ESt18is_move_assignableIS3_EEE5valueEvE4typeERS3_SC_(ptr noundef nonnull align 4 dereferenceable(4) %5, ptr noundef nonnull align 4 dereferenceable(4) %6) #8
  br label %88

84:                                               ; preds = %77, %75
  %85 = landingpad { ptr, i32 }
          cleanup
  %86 = extractvalue { ptr, i32 } %85, 0
  store ptr %86, ptr %7, align 8
  %87 = extractvalue { ptr, i32 } %85, 1
  store i32 %87, ptr %8, align 4
  br label %101

88:                                               ; preds = %83, %79
  call void @llvm.lifetime.start.p0(i64 8, ptr %9) #8
  invoke void @_ZNSt4pairIiiEC2IRiS2_TnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairIS4_S5_EEEbE4typeELb1EEEOS4_OS5_(ptr noundef nonnull align 4 dereferenceable(8) %9, ptr noundef nonnull align 4 dereferenceable(4) %5, ptr noundef nonnull align 4 dereferenceable(4) %6)
          to label %89 unwind label %97

89:                                               ; preds = %88
  %90 = invoke noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt3mapISt4pairIiiEiSt4lessIS1_ESaIS0_IKS1_iEEEixEOS1_(ptr noundef nonnull align 8 dereferenceable(48) %3, ptr noundef nonnull align 4 dereferenceable(8) %9)
          to label %91 unwind label %97

91:                                               ; preds = %89
  %92 = load i32, ptr %90, align 4, !tbaa !9
  %93 = add nsw i32 %92, 1
  store i32 %93, ptr %90, align 4, !tbaa !9
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %6) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %5) #8
  br label %94

94:                                               ; preds = %91
  %95 = load i32, ptr %4, align 4, !tbaa !9
  %96 = add nsw i32 %95, 1
  store i32 %96, ptr %4, align 4, !tbaa !9
  br label %70, !llvm.loop !11

97:                                               ; preds = %89, %88
  %98 = landingpad { ptr, i32 }
          cleanup
  %99 = extractvalue { ptr, i32 } %98, 0
  store ptr %99, ptr %7, align 8
  %100 = extractvalue { ptr, i32 } %98, 1
  store i32 %100, ptr %8, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #8
  br label %101

101:                                              ; preds = %97, %84
  call void @llvm.lifetime.end.p0(i64 4, ptr %6) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %5) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %4) #8
  br label %502

102:                                              ; preds = %74
  call void @llvm.lifetime.start.p0(i64 24, ptr %10) #8
  call void @_ZNSt6vectorISt4pairIiiESaIS1_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %10) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #8
  store ptr %3, ptr %11, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #8
  %103 = load ptr, ptr %11, align 8, !tbaa !5
  %104 = call ptr @_ZNSt3mapISt4pairIiiEiSt4lessIS1_ESaIS0_IKS1_iEEE5beginEv(ptr noundef nonnull align 8 dereferenceable(48) %103) #8
  %105 = getelementptr inbounds %"struct.std::_Rb_tree_iterator", ptr %12, i32 0, i32 0
  store ptr %104, ptr %105, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #8
  %106 = load ptr, ptr %11, align 8, !tbaa !5
  %107 = call ptr @_ZNSt3mapISt4pairIiiEiSt4lessIS1_ESaIS0_IKS1_iEEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %106) #8
  %108 = getelementptr inbounds %"struct.std::_Rb_tree_iterator", ptr %13, i32 0, i32 0
  store ptr %107, ptr %108, align 8
  br label %109

109:                                              ; preds = %125, %102
  %110 = call noundef zeroext i1 @_ZStneRKSt17_Rb_tree_iteratorISt4pairIKS0_IiiEiEES6_(ptr noundef nonnull align 8 dereferenceable(8) %12, ptr noundef nonnull align 8 dereferenceable(8) %13) #8
  br i1 %110, label %112, label %111

111:                                              ; preds = %109
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #8
  br label %127

112:                                              ; preds = %109
  call void @llvm.lifetime.start.p0(i64 12, ptr %14) #8
  %113 = call noundef nonnull align 4 dereferenceable(12) ptr @_ZNKSt17_Rb_tree_iteratorISt4pairIKS0_IiiEiEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %12) #8
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %14, ptr align 4 %113, i64 12, i1 false)
  %114 = getelementptr inbounds %"struct.std::pair.3", ptr %14, i32 0, i32 1
  %115 = load i32, ptr %114, align 4, !tbaa !13
  %116 = icmp eq i32 %115, 1
  br i1 %116, label %117, label %124

117:                                              ; preds = %112
  %118 = getelementptr inbounds %"struct.std::pair.3", ptr %14, i32 0, i32 0
  invoke void @_ZNSt6vectorISt4pairIiiESaIS1_EE9push_backERKS1_(ptr noundef nonnull align 8 dereferenceable(24) %10, ptr noundef nonnull align 4 dereferenceable(8) %118)
          to label %119 unwind label %120

119:                                              ; preds = %117
  br label %124

120:                                              ; preds = %117
  %121 = landingpad { ptr, i32 }
          cleanup
  %122 = extractvalue { ptr, i32 } %121, 0
  store ptr %122, ptr %7, align 8
  %123 = extractvalue { ptr, i32 } %121, 1
  store i32 %123, ptr %8, align 4
  call void @llvm.lifetime.end.p0(i64 12, ptr %14) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #8
  br label %501

124:                                              ; preds = %119, %112
  call void @llvm.lifetime.end.p0(i64 12, ptr %14) #8
  br label %125

125:                                              ; preds = %124
  %126 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt17_Rb_tree_iteratorISt4pairIKS0_IiiEiEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %12) #8
  br label %109

127:                                              ; preds = %111
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #8
  store ptr %10, ptr %15, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #8
  %128 = load ptr, ptr %15, align 8, !tbaa !5
  %129 = call ptr @_ZNSt6vectorISt4pairIiiESaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %128) #8
  %130 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %16, i32 0, i32 0
  store ptr %129, ptr %130, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #8
  %131 = load ptr, ptr %15, align 8, !tbaa !5
  %132 = call ptr @_ZNSt6vectorISt4pairIiiESaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %131) #8
  %133 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %17, i32 0, i32 0
  store ptr %132, ptr %133, align 8
  br label %134

134:                                              ; preds = %141, %127
  %135 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPSt4pairIiiESt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8) %16, ptr noundef nonnull align 8 dereferenceable(8) %17) #8
  br i1 %135, label %137, label %136

136:                                              ; preds = %134
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #8
  br label %147

137:                                              ; preds = %134
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #8
  %138 = call noundef nonnull align 4 dereferenceable(8) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPSt4pairIiiESt6vectorIS2_SaIS2_EEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %16) #8
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %18, ptr align 4 %138, i64 8, i1 false)
  %139 = invoke noundef i64 @_ZNSt3mapISt4pairIiiEiSt4lessIS1_ESaIS0_IKS1_iEEE5eraseERS4_(ptr noundef nonnull align 8 dereferenceable(48) %3, ptr noundef nonnull align 4 dereferenceable(8) %18)
          to label %140 unwind label %143

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

141:                                              ; preds = %140
  %142 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZN9__gnu_cxx17__normal_iteratorIPSt4pairIiiESt6vectorIS2_SaIS2_EEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %16) #8
  br label %134

143:                                              ; preds = %137
  %144 = landingpad { ptr, i32 }
          cleanup
  %145 = extractvalue { ptr, i32 } %144, 0
  store ptr %145, ptr %7, align 8
  %146 = extractvalue { ptr, i32 } %144, 1
  store i32 %146, ptr %8, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #8
  br label %501

147:                                              ; preds = %136
  call void @llvm.lifetime.start.p0(i64 8, ptr %19) #8
  store ptr %3, ptr %19, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %20) #8
  %148 = load ptr, ptr %19, align 8, !tbaa !5
  %149 = call ptr @_ZNSt3mapISt4pairIiiEiSt4lessIS1_ESaIS0_IKS1_iEEE5beginEv(ptr noundef nonnull align 8 dereferenceable(48) %148) #8
  %150 = getelementptr inbounds %"struct.std::_Rb_tree_iterator", ptr %20, i32 0, i32 0
  store ptr %149, ptr %150, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %21) #8
  %151 = load ptr, ptr %19, align 8, !tbaa !5
  %152 = call ptr @_ZNSt3mapISt4pairIiiEiSt4lessIS1_ESaIS0_IKS1_iEEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %151) #8
  %153 = getelementptr inbounds %"struct.std::_Rb_tree_iterator", ptr %21, i32 0, i32 0
  store ptr %152, ptr %153, align 8
  br label %154

154:                                              ; preds = %163, %147
  %155 = call noundef zeroext i1 @_ZStneRKSt17_Rb_tree_iteratorISt4pairIKS0_IiiEiEES6_(ptr noundef nonnull align 8 dereferenceable(8) %20, ptr noundef nonnull align 8 dereferenceable(8) %21) #8
  br i1 %155, label %157, label %156

156:                                              ; preds = %154
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #8
  br label %165

157:                                              ; preds = %154
  call void @llvm.lifetime.start.p0(i64 8, ptr %22) #8
  %158 = call noundef nonnull align 4 dereferenceable(12) ptr @_ZNKSt17_Rb_tree_iteratorISt4pairIKS0_IiiEiEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %20) #8
  store ptr %158, ptr %22, align 8, !tbaa !5
  %159 = load ptr, ptr %22, align 8, !tbaa !5
  %160 = getelementptr inbounds %"struct.std::pair.3", ptr %159, i32 0, i32 1
  %161 = load i32, ptr %160, align 4, !tbaa !13
  %162 = sdiv i32 %161, 2
  store i32 %162, ptr %160, align 4, !tbaa !13
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #8
  br label %163

163:                                              ; preds = %157
  %164 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt17_Rb_tree_iteratorISt4pairIKS0_IiiEiEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %20) #8
  br label %154

165:                                              ; preds = %156
  call void @llvm.lifetime.start.p0(i64 8, ptr %23) #8
  store i64 -1, ptr %23, align 8, !tbaa !16
  call void @llvm.lifetime.start.p0(i64 8, ptr %24) #8
  store ptr %3, ptr %24, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %25) #8
  %166 = load ptr, ptr %24, align 8, !tbaa !5
  %167 = call ptr @_ZNSt3mapISt4pairIiiEiSt4lessIS1_ESaIS0_IKS1_iEEE5beginEv(ptr noundef nonnull align 8 dereferenceable(48) %166) #8
  %168 = getelementptr inbounds %"struct.std::_Rb_tree_iterator", ptr %25, i32 0, i32 0
  store ptr %167, ptr %168, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %26) #8
  %169 = load ptr, ptr %24, align 8, !tbaa !5
  %170 = call ptr @_ZNSt3mapISt4pairIiiEiSt4lessIS1_ESaIS0_IKS1_iEEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %169) #8
  %171 = getelementptr inbounds %"struct.std::_Rb_tree_iterator", ptr %26, i32 0, i32 0
  store ptr %170, ptr %171, align 8
  br label %172

172:                                              ; preds = %207, %165
  %173 = call noundef zeroext i1 @_ZStneRKSt17_Rb_tree_iteratorISt4pairIKS0_IiiEiEES6_(ptr noundef nonnull align 8 dereferenceable(8) %25, ptr noundef nonnull align 8 dereferenceable(8) %26) #8
  br i1 %173, label %175, label %174

174:                                              ; preds = %172
  call void @llvm.lifetime.end.p0(i64 8, ptr %26) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %25) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %24) #8
  br label %209

175:                                              ; preds = %172
  call void @llvm.lifetime.start.p0(i64 12, ptr %27) #8
  %176 = call noundef nonnull align 4 dereferenceable(12) ptr @_ZNKSt17_Rb_tree_iteratorISt4pairIKS0_IiiEiEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %25) #8
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %27, ptr align 4 %176, i64 12, i1 false)
  call void @llvm.lifetime.start.p0(i64 8, ptr %28) #8
  %177 = getelementptr inbounds %"struct.std::pair.3", ptr %27, i32 0, i32 0
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %28, ptr align 4 %177, i64 8, i1 false)
  %178 = getelementptr inbounds %"struct.std::pair", ptr %28, i32 0, i32 0
  %179 = load i32, ptr %178, align 4, !tbaa !18
  %180 = getelementptr inbounds %"struct.std::pair", ptr %28, i32 0, i32 1
  %181 = load i32, ptr %180, align 4, !tbaa !19
  %182 = icmp eq i32 %179, %181
  br i1 %182, label %183, label %206

183:                                              ; preds = %175
  %184 = getelementptr inbounds %"struct.std::pair.3", ptr %27, i32 0, i32 1
  %185 = load i32, ptr %184, align 4, !tbaa !13
  %186 = icmp sge i32 %185, 3
  br i1 %186, label %187, label %206

187:                                              ; preds = %183
  call void @llvm.lifetime.start.p0(i64 8, ptr %29) #8
  %188 = getelementptr inbounds %"struct.std::pair", ptr %28, i32 0, i32 0
  %189 = load i32, ptr %188, align 4, !tbaa !18
  %190 = sext i32 %189 to i64
  %191 = getelementptr inbounds %"struct.std::pair", ptr %28, i32 0, i32 0
  %192 = load i32, ptr %191, align 4, !tbaa !18
  %193 = sext i32 %192 to i64
  %194 = mul nsw i64 %190, %193
  %195 = getelementptr inbounds %"struct.std::pair", ptr %28, i32 0, i32 0
  %196 = load i32, ptr %195, align 4, !tbaa !18
  %197 = sext i32 %196 to i64
  %198 = mul nsw i64 %194, %197
  store i64 %198, ptr %29, align 8, !tbaa !16
  %199 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3maxIxERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) %23, ptr noundef nonnull align 8 dereferenceable(8) %29)
          to label %200 unwind label %202

200:                                              ; preds = %187
  %201 = load i64, ptr %199, align 8, !tbaa !16
  store i64 %201, ptr %23, align 8, !tbaa !16
  call void @llvm.lifetime.end.p0(i64 8, ptr %29) #8
  br label %206

202:                                              ; preds = %187
  %203 = landingpad { ptr, i32 }
          cleanup
  %204 = extractvalue { ptr, i32 } %203, 0
  store ptr %204, ptr %7, align 8
  %205 = extractvalue { ptr, i32 } %203, 1
  store i32 %205, ptr %8, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %29) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %28) #8
  call void @llvm.lifetime.end.p0(i64 12, ptr %27) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %26) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %25) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %24) #8
  br label %500

206:                                              ; preds = %200, %183, %175
  call void @llvm.lifetime.end.p0(i64 8, ptr %28) #8
  call void @llvm.lifetime.end.p0(i64 12, ptr %27) #8
  br label %207

207:                                              ; preds = %206
  %208 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt17_Rb_tree_iteratorISt4pairIKS0_IiiEiEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %25) #8
  br label %172

209:                                              ; preds = %174
  call void @llvm.lifetime.start.p0(i64 8, ptr %30) #8
  store ptr %3, ptr %30, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %31) #8
  %210 = load ptr, ptr %30, align 8, !tbaa !5
  %211 = call ptr @_ZNSt3mapISt4pairIiiEiSt4lessIS1_ESaIS0_IKS1_iEEE5beginEv(ptr noundef nonnull align 8 dereferenceable(48) %210) #8
  %212 = getelementptr inbounds %"struct.std::_Rb_tree_iterator", ptr %31, i32 0, i32 0
  store ptr %211, ptr %212, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %32) #8
  %213 = load ptr, ptr %30, align 8, !tbaa !5
  %214 = call ptr @_ZNSt3mapISt4pairIiiEiSt4lessIS1_ESaIS0_IKS1_iEEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %213) #8
  %215 = getelementptr inbounds %"struct.std::_Rb_tree_iterator", ptr %32, i32 0, i32 0
  store ptr %214, ptr %215, align 8
  br label %216

216:                                              ; preds = %295, %209
  %217 = call noundef zeroext i1 @_ZStneRKSt17_Rb_tree_iteratorISt4pairIKS0_IiiEiEES6_(ptr noundef nonnull align 8 dereferenceable(8) %31, ptr noundef nonnull align 8 dereferenceable(8) %32) #8
  br i1 %217, label %219, label %218

218:                                              ; preds = %216
  call void @llvm.lifetime.end.p0(i64 8, ptr %32) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %31) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %30) #8
  br label %297

219:                                              ; preds = %216
  call void @llvm.lifetime.start.p0(i64 12, ptr %33) #8
  %220 = call noundef nonnull align 4 dereferenceable(12) ptr @_ZNKSt17_Rb_tree_iteratorISt4pairIKS0_IiiEiEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %31) #8
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %33, ptr align 4 %220, i64 12, i1 false)
  call void @llvm.lifetime.start.p0(i64 8, ptr %34) #8
  %221 = getelementptr inbounds %"struct.std::pair.3", ptr %33, i32 0, i32 0
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %34, ptr align 4 %221, i64 8, i1 false)
  %222 = getelementptr inbounds %"struct.std::pair", ptr %34, i32 0, i32 0
  %223 = load i32, ptr %222, align 4, !tbaa !18
  %224 = getelementptr inbounds %"struct.std::pair", ptr %34, i32 0, i32 1
  %225 = load i32, ptr %224, align 4, !tbaa !19
  %226 = icmp ne i32 %223, %225
  br i1 %226, label %227, label %294

227:                                              ; preds = %219
  %228 = getelementptr inbounds %"struct.std::pair.3", ptr %33, i32 0, i32 1
  %229 = load i32, ptr %228, align 4, !tbaa !13
  %230 = icmp sge i32 %229, 2
  br i1 %230, label %231, label %294

231:                                              ; preds = %227
  call void @llvm.lifetime.start.p0(i64 8, ptr %35) #8
  %232 = getelementptr inbounds %"struct.std::pair", ptr %34, i32 0, i32 0
  %233 = getelementptr inbounds %"struct.std::pair", ptr %34, i32 0, i32 0
  invoke void @_ZNSt4pairIiiEC2IRiS2_TnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairIS4_S5_EEEbE4typeELb1EEEOS4_OS5_(ptr noundef nonnull align 4 dereferenceable(8) %35, ptr noundef nonnull align 4 dereferenceable(4) %232, ptr noundef nonnull align 4 dereferenceable(4) %233)
          to label %234 unwind label %256

234:                                              ; preds = %231
  call void @llvm.lifetime.start.p0(i64 8, ptr %36) #8
  %235 = getelementptr inbounds %"struct.std::pair", ptr %34, i32 0, i32 1
  %236 = getelementptr inbounds %"struct.std::pair", ptr %34, i32 0, i32 1
  invoke void @_ZNSt4pairIiiEC2IRiS2_TnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairIS4_S5_EEEbE4typeELb1EEEOS4_OS5_(ptr noundef nonnull align 4 dereferenceable(8) %36, ptr noundef nonnull align 4 dereferenceable(4) %235, ptr noundef nonnull align 4 dereferenceable(4) %236)
          to label %237 unwind label %260

237:                                              ; preds = %234
  %238 = invoke noundef i64 @_ZNKSt3mapISt4pairIiiEiSt4lessIS1_ESaIS0_IKS1_iEEE5countERS4_(ptr noundef nonnull align 8 dereferenceable(48) %3, ptr noundef nonnull align 4 dereferenceable(8) %35)
          to label %239 unwind label %260

239:                                              ; preds = %237
  %240 = icmp ne i64 %238, 0
  br i1 %240, label %241, label %268

241:                                              ; preds = %239
  call void @llvm.lifetime.start.p0(i64 8, ptr %37) #8
  %242 = getelementptr inbounds %"struct.std::pair", ptr %34, i32 0, i32 0
  %243 = load i32, ptr %242, align 4, !tbaa !18
  %244 = sext i32 %243 to i64
  %245 = getelementptr inbounds %"struct.std::pair", ptr %34, i32 0, i32 0
  %246 = load i32, ptr %245, align 4, !tbaa !18
  %247 = sext i32 %246 to i64
  %248 = mul nsw i64 %244, %247
  %249 = getelementptr inbounds %"struct.std::pair", ptr %34, i32 0, i32 1
  %250 = load i32, ptr %249, align 4, !tbaa !19
  %251 = sext i32 %250 to i64
  %252 = mul nsw i64 %248, %251
  store i64 %252, ptr %37, align 8, !tbaa !16
  %253 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3maxIxERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) %23, ptr noundef nonnull align 8 dereferenceable(8) %37)
          to label %254 unwind label %264

254:                                              ; preds = %241
  %255 = load i64, ptr %253, align 8, !tbaa !16
  store i64 %255, ptr %23, align 8, !tbaa !16
  call void @llvm.lifetime.end.p0(i64 8, ptr %37) #8
  br label %268

256:                                              ; preds = %231
  %257 = landingpad { ptr, i32 }
          cleanup
  %258 = extractvalue { ptr, i32 } %257, 0
  store ptr %258, ptr %7, align 8
  %259 = extractvalue { ptr, i32 } %257, 1
  store i32 %259, ptr %8, align 4
  br label %293

260:                                              ; preds = %268, %237, %234
  %261 = landingpad { ptr, i32 }
          cleanup
  %262 = extractvalue { ptr, i32 } %261, 0
  store ptr %262, ptr %7, align 8
  %263 = extractvalue { ptr, i32 } %261, 1
  store i32 %263, ptr %8, align 4
  br label %292

264:                                              ; preds = %241
  %265 = landingpad { ptr, i32 }
          cleanup
  %266 = extractvalue { ptr, i32 } %265, 0
  store ptr %266, ptr %7, align 8
  %267 = extractvalue { ptr, i32 } %265, 1
  store i32 %267, ptr %8, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %37) #8
  br label %292

268:                                              ; preds = %254, %239
  %269 = invoke noundef i64 @_ZNKSt3mapISt4pairIiiEiSt4lessIS1_ESaIS0_IKS1_iEEE5countERS4_(ptr noundef nonnull align 8 dereferenceable(48) %3, ptr noundef nonnull align 4 dereferenceable(8) %36)
          to label %270 unwind label %260

270:                                              ; preds = %268
  %271 = icmp ne i64 %269, 0
  br i1 %271, label %272, label %291

272:                                              ; preds = %270
  call void @llvm.lifetime.start.p0(i64 8, ptr %38) #8
  %273 = getelementptr inbounds %"struct.std::pair", ptr %34, i32 0, i32 1
  %274 = load i32, ptr %273, align 4, !tbaa !19
  %275 = sext i32 %274 to i64
  %276 = getelementptr inbounds %"struct.std::pair", ptr %34, i32 0, i32 1
  %277 = load i32, ptr %276, align 4, !tbaa !19
  %278 = sext i32 %277 to i64
  %279 = mul nsw i64 %275, %278
  %280 = getelementptr inbounds %"struct.std::pair", ptr %34, i32 0, i32 0
  %281 = load i32, ptr %280, align 4, !tbaa !18
  %282 = sext i32 %281 to i64
  %283 = mul nsw i64 %279, %282
  store i64 %283, ptr %38, align 8, !tbaa !16
  %284 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3maxIxERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) %23, ptr noundef nonnull align 8 dereferenceable(8) %38)
          to label %285 unwind label %287

285:                                              ; preds = %272
  %286 = load i64, ptr %284, align 8, !tbaa !16
  store i64 %286, ptr %23, align 8, !tbaa !16
  call void @llvm.lifetime.end.p0(i64 8, ptr %38) #8
  br label %291

287:                                              ; preds = %272
  %288 = landingpad { ptr, i32 }
          cleanup
  %289 = extractvalue { ptr, i32 } %288, 0
  store ptr %289, ptr %7, align 8
  %290 = extractvalue { ptr, i32 } %288, 1
  store i32 %290, ptr %8, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %38) #8
  br label %292

291:                                              ; preds = %285, %270
  call void @llvm.lifetime.end.p0(i64 8, ptr %36) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %35) #8
  br label %294

292:                                              ; preds = %287, %264, %260
  call void @llvm.lifetime.end.p0(i64 8, ptr %36) #8
  br label %293

293:                                              ; preds = %292, %256
  call void @llvm.lifetime.end.p0(i64 8, ptr %35) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %34) #8
  call void @llvm.lifetime.end.p0(i64 12, ptr %33) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %32) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %31) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %30) #8
  br label %500

294:                                              ; preds = %291, %227, %219
  call void @llvm.lifetime.end.p0(i64 8, ptr %34) #8
  call void @llvm.lifetime.end.p0(i64 12, ptr %33) #8
  br label %295

295:                                              ; preds = %294
  %296 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt17_Rb_tree_iteratorISt4pairIKS0_IiiEiEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %31) #8
  br label %216

297:                                              ; preds = %218
  call void @llvm.lifetime.start.p0(i64 24, ptr %39) #8
  call void @_ZNSt6vectorISt4pairIiiESaIS1_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %39) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr %40) #8
  store ptr %3, ptr %40, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %41) #8
  %298 = load ptr, ptr %40, align 8, !tbaa !5
  %299 = call ptr @_ZNSt3mapISt4pairIiiEiSt4lessIS1_ESaIS0_IKS1_iEEE5beginEv(ptr noundef nonnull align 8 dereferenceable(48) %298) #8
  %300 = getelementptr inbounds %"struct.std::_Rb_tree_iterator", ptr %41, i32 0, i32 0
  store ptr %299, ptr %300, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %42) #8
  %301 = load ptr, ptr %40, align 8, !tbaa !5
  %302 = call ptr @_ZNSt3mapISt4pairIiiEiSt4lessIS1_ESaIS0_IKS1_iEEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %301) #8
  %303 = getelementptr inbounds %"struct.std::_Rb_tree_iterator", ptr %42, i32 0, i32 0
  store ptr %302, ptr %303, align 8
  br label %304

304:                                              ; preds = %324, %297
  %305 = call noundef zeroext i1 @_ZStneRKSt17_Rb_tree_iteratorISt4pairIKS0_IiiEiEES6_(ptr noundef nonnull align 8 dereferenceable(8) %41, ptr noundef nonnull align 8 dereferenceable(8) %42) #8
  br i1 %305, label %307, label %306

306:                                              ; preds = %304
  call void @llvm.lifetime.end.p0(i64 8, ptr %42) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %41) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %40) #8
  br label %326

307:                                              ; preds = %304
  call void @llvm.lifetime.start.p0(i64 12, ptr %43) #8
  %308 = call noundef nonnull align 4 dereferenceable(12) ptr @_ZNKSt17_Rb_tree_iteratorISt4pairIKS0_IiiEiEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %41) #8
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %43, ptr align 4 %308, i64 12, i1 false)
  %309 = getelementptr inbounds %"struct.std::pair.3", ptr %43, i32 0, i32 0
  %310 = getelementptr inbounds %"struct.std::pair", ptr %309, i32 0, i32 0
  %311 = load i32, ptr %310, align 4, !tbaa !20
  %312 = getelementptr inbounds %"struct.std::pair.3", ptr %43, i32 0, i32 0
  %313 = getelementptr inbounds %"struct.std::pair", ptr %312, i32 0, i32 1
  %314 = load i32, ptr %313, align 4, !tbaa !21
  %315 = icmp ne i32 %311, %314
  br i1 %315, label %316, label %323

316:                                              ; preds = %307
  %317 = getelementptr inbounds %"struct.std::pair.3", ptr %43, i32 0, i32 0
  invoke void @_ZNSt6vectorISt4pairIiiESaIS1_EE9push_backERKS1_(ptr noundef nonnull align 8 dereferenceable(24) %39, ptr noundef nonnull align 4 dereferenceable(8) %317)
          to label %318 unwind label %319

318:                                              ; preds = %316
  br label %323

319:                                              ; preds = %316
  %320 = landingpad { ptr, i32 }
          cleanup
  %321 = extractvalue { ptr, i32 } %320, 0
  store ptr %321, ptr %7, align 8
  %322 = extractvalue { ptr, i32 } %320, 1
  store i32 %322, ptr %8, align 4
  call void @llvm.lifetime.end.p0(i64 12, ptr %43) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %42) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %41) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %40) #8
  br label %499

323:                                              ; preds = %318, %307
  call void @llvm.lifetime.end.p0(i64 12, ptr %43) #8
  br label %324

324:                                              ; preds = %323
  %325 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt17_Rb_tree_iteratorISt4pairIKS0_IiiEiEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %41) #8
  br label %304

326:                                              ; preds = %306
  call void @llvm.lifetime.start.p0(i64 24, ptr %44) #8
  call void @llvm.lifetime.start.p0(i64 1, ptr %45) #8
  call void @_ZNSaISt3setIiSt4lessIiESaIiEEEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %45) #8
  invoke void @_ZNSt6vectorISt3setIiSt4lessIiESaIiEESaIS4_EEC2EmRKS5_(ptr noundef nonnull align 8 dereferenceable(24) %44, i64 noundef 1000005, ptr noundef nonnull align 1 dereferenceable(1) %45)
          to label %327 unwind label %337

327:                                              ; preds = %326
  call void @_ZNSt15__new_allocatorISt3setIiSt4lessIiESaIiEEED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %45) #8
  call void @llvm.lifetime.end.p0(i64 1, ptr %45) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr %46) #8
  store ptr %39, ptr %46, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %47) #8
  %328 = load ptr, ptr %46, align 8, !tbaa !5
  %329 = call ptr @_ZNSt6vectorISt4pairIiiESaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %328) #8
  %330 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %47, i32 0, i32 0
  store ptr %329, ptr %330, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %48) #8
  %331 = load ptr, ptr %46, align 8, !tbaa !5
  %332 = call ptr @_ZNSt6vectorISt4pairIiiESaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %331) #8
  %333 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %48, i32 0, i32 0
  store ptr %332, ptr %333, align 8
  br label %334

334:                                              ; preds = %354, %327
  %335 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPSt4pairIiiESt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8) %47, ptr noundef nonnull align 8 dereferenceable(8) %48) #8
  br i1 %335, label %341, label %336

336:                                              ; preds = %334
  call void @llvm.lifetime.end.p0(i64 8, ptr %48) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %47) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %46) #8
  br label %360

337:                                              ; preds = %326
  %338 = landingpad { ptr, i32 }
          cleanup
  %339 = extractvalue { ptr, i32 } %338, 0
  store ptr %339, ptr %7, align 8
  %340 = extractvalue { ptr, i32 } %338, 1
  store i32 %340, ptr %8, align 4
  call void @_ZNSt15__new_allocatorISt3setIiSt4lessIiESaIiEEED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %45) #8
  call void @llvm.lifetime.end.p0(i64 1, ptr %45) #8
  br label %498

341:                                              ; preds = %334
  call void @llvm.lifetime.start.p0(i64 8, ptr %49) #8
  %342 = call noundef nonnull align 4 dereferenceable(8) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPSt4pairIiiESt6vectorIS2_SaIS2_EEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %47) #8
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %49, ptr align 4 %342, i64 8, i1 false)
  %343 = getelementptr inbounds %"struct.std::pair", ptr %49, i32 0, i32 0
  %344 = load i32, ptr %343, align 4, !tbaa !18
  %345 = sext i32 %344 to i64
  %346 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt6vectorISt3setIiSt4lessIiESaIiEESaIS4_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %44, i64 noundef %345) #8
  %347 = getelementptr inbounds %"struct.std::pair", ptr %49, i32 0, i32 1
  %348 = invoke { ptr, i8 } @_ZNSt3setIiSt4lessIiESaIiEE6insertERKi(ptr noundef nonnull align 8 dereferenceable(48) %346, ptr noundef nonnull align 4 dereferenceable(4) %347)
          to label %349 unwind label %356

349:                                              ; preds = %341
  %350 = getelementptr inbounds { ptr, i8 }, ptr %50, i32 0, i32 0
  %351 = extractvalue { ptr, i8 } %348, 0
  store ptr %351, ptr %350, align 8
  %352 = getelementptr inbounds { ptr, i8 }, ptr %50, i32 0, i32 1
  %353 = extractvalue { ptr, i8 } %348, 1
  store i8 %353, ptr %352, align 8
  call void @llvm.lifetime.end.p0(i64 8, ptr %49) #8
  br label %354

354:                                              ; preds = %349
  %355 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZN9__gnu_cxx17__normal_iteratorIPSt4pairIiiESt6vectorIS2_SaIS2_EEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %47) #8
  br label %334

356:                                              ; preds = %341
  %357 = landingpad { ptr, i32 }
          cleanup
  %358 = extractvalue { ptr, i32 } %357, 0
  store ptr %358, ptr %7, align 8
  %359 = extractvalue { ptr, i32 } %357, 1
  store i32 %359, ptr %8, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %49) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %48) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %47) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %46) #8
  br label %497

360:                                              ; preds = %336
  call void @llvm.lifetime.start.p0(i64 4, ptr %51) #8
  store i32 0, ptr %51, align 4, !tbaa !9
  br label %361

361:                                              ; preds = %482, %360
  %362 = load i32, ptr %51, align 4, !tbaa !9
  %363 = sext i32 %362 to i64
  %364 = call noundef i64 @_ZNKSt6vectorISt4pairIiiESaIS1_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %39) #8
  %365 = icmp ult i64 %363, %364
  br i1 %365, label %367, label %366

366:                                              ; preds = %361
  store i32 19, ptr %52, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %51) #8
  br label %486

367:                                              ; preds = %361
  call void @llvm.lifetime.start.p0(i64 4, ptr %53) #8
  %368 = load i32, ptr %51, align 4, !tbaa !9
  %369 = sext i32 %368 to i64
  %370 = call noundef nonnull align 4 dereferenceable(8) ptr @_ZNSt6vectorISt4pairIiiESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %39, i64 noundef %369) #8
  %371 = getelementptr inbounds %"struct.std::pair", ptr %370, i32 0, i32 0
  %372 = load i32, ptr %371, align 4, !tbaa !18
  store i32 %372, ptr %53, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %54) #8
  %373 = load i32, ptr %51, align 4, !tbaa !9
  %374 = sext i32 %373 to i64
  %375 = call noundef nonnull align 4 dereferenceable(8) ptr @_ZNSt6vectorISt4pairIiiESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %39, i64 noundef %374) #8
  %376 = getelementptr inbounds %"struct.std::pair", ptr %375, i32 0, i32 1
  %377 = load i32, ptr %376, align 4, !tbaa !19
  store i32 %377, ptr %54, align 4, !tbaa !9
  %378 = load i32, ptr %53, align 4, !tbaa !9
  %379 = sext i32 %378 to i64
  %380 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt6vectorISt3setIiSt4lessIiESaIiEESaIS4_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %44, i64 noundef %379) #8
  %381 = call noundef i64 @_ZNKSt3setIiSt4lessIiESaIiEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(48) %380) #8
  %382 = load i32, ptr %54, align 4, !tbaa !9
  %383 = sext i32 %382 to i64
  %384 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt6vectorISt3setIiSt4lessIiESaIiEESaIS4_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %44, i64 noundef %383) #8
  %385 = call noundef i64 @_ZNKSt3setIiSt4lessIiESaIiEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(48) %384) #8
  %386 = icmp ult i64 %381, %385
  br i1 %386, label %387, label %434

387:                                              ; preds = %367
  call void @llvm.lifetime.start.p0(i64 8, ptr %55) #8
  %388 = load i32, ptr %53, align 4, !tbaa !9
  %389 = sext i32 %388 to i64
  %390 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt6vectorISt3setIiSt4lessIiESaIiEESaIS4_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %44, i64 noundef %389) #8
  store ptr %390, ptr %55, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %56) #8
  %391 = load ptr, ptr %55, align 8, !tbaa !5
  %392 = call ptr @_ZNKSt3setIiSt4lessIiESaIiEE5beginEv(ptr noundef nonnull align 8 dereferenceable(48) %391) #8
  %393 = getelementptr inbounds %"struct.std::_Rb_tree_const_iterator", ptr %56, i32 0, i32 0
  store ptr %392, ptr %393, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %57) #8
  %394 = load ptr, ptr %55, align 8, !tbaa !5
  %395 = call ptr @_ZNKSt3setIiSt4lessIiESaIiEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %394) #8
  %396 = getelementptr inbounds %"struct.std::_Rb_tree_const_iterator", ptr %57, i32 0, i32 0
  store ptr %395, ptr %396, align 8
  br label %397

397:                                              ; preds = %430, %387
  %398 = call noundef zeroext i1 @_ZStneRKSt23_Rb_tree_const_iteratorIiES2_(ptr noundef nonnull align 8 dereferenceable(8) %56, ptr noundef nonnull align 8 dereferenceable(8) %57) #8
  br i1 %398, label %400, label %399

399:                                              ; preds = %397
  store i32 22, ptr %52, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %57) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %56) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %55) #8
  br label %433

400:                                              ; preds = %397
  call void @llvm.lifetime.start.p0(i64 4, ptr %58) #8
  %401 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt23_Rb_tree_const_iteratorIiEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %56) #8
  %402 = load i32, ptr %401, align 4, !tbaa !9
  store i32 %402, ptr %58, align 4, !tbaa !9
  %403 = load i32, ptr %54, align 4, !tbaa !9
  %404 = sext i32 %403 to i64
  %405 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt6vectorISt3setIiSt4lessIiESaIiEESaIS4_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %44, i64 noundef %404) #8
  %406 = invoke noundef i64 @_ZNKSt3setIiSt4lessIiESaIiEE5countERKi(ptr noundef nonnull align 8 dereferenceable(48) %405, ptr noundef nonnull align 4 dereferenceable(4) %58)
          to label %407 unwind label %421

407:                                              ; preds = %400
  %408 = icmp ne i64 %406, 0
  br i1 %408, label %409, label %429

409:                                              ; preds = %407
  call void @llvm.lifetime.start.p0(i64 8, ptr %59) #8
  %410 = load i32, ptr %53, align 4, !tbaa !9
  %411 = sext i32 %410 to i64
  %412 = load i32, ptr %54, align 4, !tbaa !9
  %413 = sext i32 %412 to i64
  %414 = mul nsw i64 %411, %413
  %415 = load i32, ptr %58, align 4, !tbaa !9
  %416 = sext i32 %415 to i64
  %417 = mul nsw i64 %414, %416
  store i64 %417, ptr %59, align 8, !tbaa !16
  %418 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3maxIxERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) %23, ptr noundef nonnull align 8 dereferenceable(8) %59)
          to label %419 unwind label %425

419:                                              ; preds = %409
  %420 = load i64, ptr %418, align 8, !tbaa !16
  store i64 %420, ptr %23, align 8, !tbaa !16
  call void @llvm.lifetime.end.p0(i64 8, ptr %59) #8
  br label %429

421:                                              ; preds = %400
  %422 = landingpad { ptr, i32 }
          cleanup
  %423 = extractvalue { ptr, i32 } %422, 0
  store ptr %423, ptr %7, align 8
  %424 = extractvalue { ptr, i32 } %422, 1
  store i32 %424, ptr %8, align 4
  br label %432

425:                                              ; preds = %409
  %426 = landingpad { ptr, i32 }
          cleanup
  %427 = extractvalue { ptr, i32 } %426, 0
  store ptr %427, ptr %7, align 8
  %428 = extractvalue { ptr, i32 } %426, 1
  store i32 %428, ptr %8, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %59) #8
  br label %432

429:                                              ; preds = %419, %407
  call void @llvm.lifetime.end.p0(i64 4, ptr %58) #8
  br label %430

430:                                              ; preds = %429
  %431 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt23_Rb_tree_const_iteratorIiEppEv(ptr noundef nonnull align 8 dereferenceable(8) %56) #8
  br label %397

432:                                              ; preds = %425, %421
  call void @llvm.lifetime.end.p0(i64 4, ptr %58) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %57) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %56) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %55) #8
  br label %485

433:                                              ; preds = %399
  br label %481

434:                                              ; preds = %367
  call void @llvm.lifetime.start.p0(i64 8, ptr %60) #8
  %435 = load i32, ptr %54, align 4, !tbaa !9
  %436 = sext i32 %435 to i64
  %437 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt6vectorISt3setIiSt4lessIiESaIiEESaIS4_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %44, i64 noundef %436) #8
  store ptr %437, ptr %60, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %61) #8
  %438 = load ptr, ptr %60, align 8, !tbaa !5
  %439 = call ptr @_ZNKSt3setIiSt4lessIiESaIiEE5beginEv(ptr noundef nonnull align 8 dereferenceable(48) %438) #8
  %440 = getelementptr inbounds %"struct.std::_Rb_tree_const_iterator", ptr %61, i32 0, i32 0
  store ptr %439, ptr %440, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %62) #8
  %441 = load ptr, ptr %60, align 8, !tbaa !5
  %442 = call ptr @_ZNKSt3setIiSt4lessIiESaIiEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %441) #8
  %443 = getelementptr inbounds %"struct.std::_Rb_tree_const_iterator", ptr %62, i32 0, i32 0
  store ptr %442, ptr %443, align 8
  br label %444

444:                                              ; preds = %477, %434
  %445 = call noundef zeroext i1 @_ZStneRKSt23_Rb_tree_const_iteratorIiES2_(ptr noundef nonnull align 8 dereferenceable(8) %61, ptr noundef nonnull align 8 dereferenceable(8) %62) #8
  br i1 %445, label %447, label %446

446:                                              ; preds = %444
  store i32 24, ptr %52, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %62) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %61) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %60) #8
  br label %480

447:                                              ; preds = %444
  call void @llvm.lifetime.start.p0(i64 4, ptr %63) #8
  %448 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt23_Rb_tree_const_iteratorIiEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %61) #8
  %449 = load i32, ptr %448, align 4, !tbaa !9
  store i32 %449, ptr %63, align 4, !tbaa !9
  %450 = load i32, ptr %53, align 4, !tbaa !9
  %451 = sext i32 %450 to i64
  %452 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt6vectorISt3setIiSt4lessIiESaIiEESaIS4_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %44, i64 noundef %451) #8
  %453 = invoke noundef i64 @_ZNKSt3setIiSt4lessIiESaIiEE5countERKi(ptr noundef nonnull align 8 dereferenceable(48) %452, ptr noundef nonnull align 4 dereferenceable(4) %63)
          to label %454 unwind label %468

454:                                              ; preds = %447
  %455 = icmp ne i64 %453, 0
  br i1 %455, label %456, label %476

456:                                              ; preds = %454
  call void @llvm.lifetime.start.p0(i64 8, ptr %64) #8
  %457 = load i32, ptr %53, align 4, !tbaa !9
  %458 = sext i32 %457 to i64
  %459 = load i32, ptr %54, align 4, !tbaa !9
  %460 = sext i32 %459 to i64
  %461 = mul nsw i64 %458, %460
  %462 = load i32, ptr %63, align 4, !tbaa !9
  %463 = sext i32 %462 to i64
  %464 = mul nsw i64 %461, %463
  store i64 %464, ptr %64, align 8, !tbaa !16
  %465 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3maxIxERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) %23, ptr noundef nonnull align 8 dereferenceable(8) %64)
          to label %466 unwind label %472

466:                                              ; preds = %456
  %467 = load i64, ptr %465, align 8, !tbaa !16
  store i64 %467, ptr %23, align 8, !tbaa !16
  call void @llvm.lifetime.end.p0(i64 8, ptr %64) #8
  br label %476

468:                                              ; preds = %447
  %469 = landingpad { ptr, i32 }
          cleanup
  %470 = extractvalue { ptr, i32 } %469, 0
  store ptr %470, ptr %7, align 8
  %471 = extractvalue { ptr, i32 } %469, 1
  store i32 %471, ptr %8, align 4
  br label %479

472:                                              ; preds = %456
  %473 = landingpad { ptr, i32 }
          cleanup
  %474 = extractvalue { ptr, i32 } %473, 0
  store ptr %474, ptr %7, align 8
  %475 = extractvalue { ptr, i32 } %473, 1
  store i32 %475, ptr %8, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %64) #8
  br label %479

476:                                              ; preds = %466, %454
  call void @llvm.lifetime.end.p0(i64 4, ptr %63) #8
  br label %477

477:                                              ; preds = %476
  %478 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt23_Rb_tree_const_iteratorIiEppEv(ptr noundef nonnull align 8 dereferenceable(8) %61) #8
  br label %444

479:                                              ; preds = %472, %468
  call void @llvm.lifetime.end.p0(i64 4, ptr %63) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %62) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %61) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %60) #8
  br label %485

480:                                              ; preds = %446
  br label %481

481:                                              ; preds = %480, %433
  call void @llvm.lifetime.end.p0(i64 4, ptr %54) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %53) #8
  br label %482

482:                                              ; preds = %481
  %483 = load i32, ptr %51, align 4, !tbaa !9
  %484 = add nsw i32 %483, 1
  store i32 %484, ptr %51, align 4, !tbaa !9
  br label %361, !llvm.loop !22

485:                                              ; preds = %479, %432
  call void @llvm.lifetime.end.p0(i64 4, ptr %54) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %53) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %51) #8
  br label %497

486:                                              ; preds = %366
  %487 = load i64, ptr %23, align 8, !tbaa !16
  %488 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEx(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, i64 noundef %487)
          to label %489 unwind label %493

489:                                              ; preds = %486
  %490 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSoS_E(ptr noundef nonnull align 8 dereferenceable(8) %488, ptr noundef @_ZSt4endlIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_)
          to label %491 unwind label %493

491:                                              ; preds = %489
  call void @_ZNSt6vectorISt3setIiSt4lessIiESaIiEESaIS4_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %44) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %44) #8
  call void @_ZNSt6vectorISt4pairIiiESaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %39) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %39) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %23) #8
  call void @_ZNSt6vectorISt4pairIiiESaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %10) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %10) #8
  call void @_ZNSt3mapISt4pairIiiEiSt4lessIS1_ESaIS0_IKS1_iEEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %3) #8
  call void @llvm.lifetime.end.p0(i64 48, ptr %3) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %2) #8
  %492 = load i32, ptr %1, align 4
  ret i32 %492

493:                                              ; preds = %489, %486
  %494 = landingpad { ptr, i32 }
          cleanup
  %495 = extractvalue { ptr, i32 } %494, 0
  store ptr %495, ptr %7, align 8
  %496 = extractvalue { ptr, i32 } %494, 1
  store i32 %496, ptr %8, align 4
  br label %497

497:                                              ; preds = %493, %485, %356
  call void @_ZNSt6vectorISt3setIiSt4lessIiESaIiEESaIS4_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %44) #8
  br label %498

498:                                              ; preds = %497, %337
  call void @llvm.lifetime.end.p0(i64 24, ptr %44) #8
  br label %499

499:                                              ; preds = %498, %319
  call void @_ZNSt6vectorISt4pairIiiESaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %39) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %39) #8
  br label %500

500:                                              ; preds = %499, %293, %202
  call void @llvm.lifetime.end.p0(i64 8, ptr %23) #8
  br label %501

501:                                              ; preds = %500, %143, %120
  call void @_ZNSt6vectorISt4pairIiiESaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %10) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %10) #8
  br label %502

502:                                              ; preds = %501, %101
  call void @_ZNSt3mapISt4pairIiiEiSt4lessIS1_ESaIS0_IKS1_iEEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %3) #8
  call void @llvm.lifetime.end.p0(i64 48, ptr %3) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %2) #8
  br label %503

503:                                              ; preds = %502
  %504 = load ptr, ptr %7, align 8
  %505 = load i32, ptr %8, align 4
  %506 = insertvalue { ptr, i32 } poison, ptr %504, 0
  %507 = insertvalue { ptr, i32 } %506, i32 %505, 1
  resume { ptr, i32 } %507
}

declare ptr @freopen(ptr noundef, ptr noundef, ptr noundef) #1

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

declare noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERi(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 4 dereferenceable(4)) #1

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

declare i32 @__gxx_personality_v0(...)

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt3mapISt4pairIiiEiSt4lessIS1_ESaIS0_IKS1_iEEEixEOS1_(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 4 dereferenceable(8)) #5 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt4pairIiiEC2IRiS2_TnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairIS4_S5_EEEbE4typeELb1EEEOS4_OS5_(ptr noundef nonnull align 4 dereferenceable(8), ptr noundef nonnull align 4 dereferenceable(4), ptr noundef nonnull align 4 dereferenceable(4)) unnamed_addr #3 align 2

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

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

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

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(12) ptr @_ZNKSt17_Rb_tree_iteratorISt4pairIKS0_IiiEiEEdeEv(ptr noundef nonnull align 8 dereferenceable(8)) #3 align 2

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #6

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

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

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZN9__gnu_cxxneIPSt4pairIiiESt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(8)) #4

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef i64 @_ZNSt3mapISt4pairIiiEiSt4lessIS1_ESaIS0_IKS1_iEEE5eraseERS4_(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 4 dereferenceable(8)) #5 align 2

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

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef i64 @_ZNKSt3mapISt4pairIiiEiSt4lessIS1_ESaIS0_IKS1_iEEE5countERS4_(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 4 dereferenceable(8)) #5 align 2

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

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

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

; Function Attrs: mustprogress uwtable
declare dso_local { ptr, i8 } @_ZNSt3setIiSt4lessIiESaIiEE6insertERKi(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 4 dereferenceable(4)) #5 align 2

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

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

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

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

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

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

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef i64 @_ZNKSt3setIiSt4lessIiESaIiEE5countERKi(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 4 dereferenceable(4)) #5 align 2

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

; Function Attrs: mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEx(ptr noundef nonnull align 8 dereferenceable(8), i64 noundef) #5 align 2

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

; Function Attrs: inlinehint mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZSt4endlIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_(ptr noundef nonnull align 8 dereferenceable(8)) #7

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

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

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

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

attributes #0 = { mustprogress norecurse uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { "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 = { mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #4 = { 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 #5 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #6 = { nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #7 = { 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 #8 = { 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 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"int", !7, i64 0}
!11 = distinct !{!11, !12}
!12 = !{!"llvm.loop.mustprogress"}
!13 = !{!14, !10, i64 8}
!14 = !{!"_ZTSSt4pairIKS_IiiEiE", !15, i64 0, !10, i64 8}
!15 = !{!"_ZTSSt4pairIiiE", !10, i64 0, !10, i64 4}
!16 = !{!17, !17, i64 0}
!17 = !{!"long long", !7, i64 0}
!18 = !{!15, !10, i64 0}
!19 = !{!15, !10, i64 4}
!20 = !{!14, !10, i64 0}
!21 = !{!14, !10, i64 4}
!22 = distinct !{!22, !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::basic_istream" = type { ptr, i64, %"class.std::basic_ios" }
%"class.std::basic_ios" = type { %"class.std::ios_base", ptr, i8, i8, ptr, ptr, ptr, ptr }
%"class.std::ios_base" = type { ptr, i64, i64, i32, i32, i32, ptr, %"struct.std::ios_base::_Words", [8 x %"struct.std::ios_base::_Words"], i32, ptr, %"class.std::locale" }
%"struct.std::ios_base::_Words" = type { ptr, i64 }
%"class.std::locale" = type { ptr }
%"class.std::basic_ostream" = type { ptr, %"class.std::basic_ios" }
%"class.std::map" = type { %"class.std::_Rb_tree" }
%"class.std::_Rb_tree" = type { %"struct.std::_Rb_tree<std::pair<int, int>, std::pair<const std::pair<int, int>, int>, std::_Select1st<std::pair<const std::pair<int, int>, int>>, std::less<std::pair<int, int>>>::_Rb_tree_impl" }
%"struct.std::_Rb_tree<std::pair<int, int>, std::pair<const std::pair<int, int>, int>, std::_Select1st<std::pair<const std::pair<int, int>, int>>, std::less<std::pair<int, int>>>::_Rb_tree_impl" = type { [8 x i8], %"struct.std::_Rb_tree_header" }
%"struct.std::_Rb_tree_header" = type { %"struct.std::_Rb_tree_node_base", i64 }
%"struct.std::_Rb_tree_node_base" = type { i32, ptr, ptr, ptr }
%"struct.std::pair" = type { i32, i32 }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<std::pair<int, int>, std::allocator<std::pair<int, int>>>::_Vector_impl" }
%"struct.std::_Vector_base<std::pair<int, int>, std::allocator<std::pair<int, int>>>::_Vector_impl" = type { %"struct.std::_Vector_base<std::pair<int, int>, std::allocator<std::pair<int, int>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<std::pair<int, int>, std::allocator<std::pair<int, int>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"struct.std::_Rb_tree_iterator" = type { ptr }
%"struct.std::pair.3" = type { %"struct.std::pair", i32 }
%"class.__gnu_cxx::__normal_iterator" = type { ptr }
%"class.std::vector.5" = type { %"struct.std::_Vector_base.6" }
%"struct.std::_Vector_base.6" = type { %"struct.std::_Vector_base<std::set<int>, std::allocator<std::set<int>>>::_Vector_impl" }
%"struct.std::_Vector_base<std::set<int>, std::allocator<std::set<int>>>::_Vector_impl" = type { %"struct.std::_Vector_base<std::set<int>, std::allocator<std::set<int>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<std::set<int>, std::allocator<std::set<int>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::allocator.7" = type { i8 }
%"struct.std::_Rb_tree_const_iterator" = type { ptr }

@.str = external hidden unnamed_addr constant [18 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [2 x i8], align 1
@stdin = external local_unnamed_addr global ptr, align 8
@.str.2 = external hidden unnamed_addr constant [19 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [2 x i8], align 1
@stdout = external local_unnamed_addr global ptr, align 8
@_ZSt3cin = external global %"class.std::basic_istream", align 8
@_ZSt4cout = external global %"class.std::basic_ostream", align 8

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() local_unnamed_addr #0 personality ptr @__gxx_personality_v0 {
  %1 = alloca i32, align 4
  %2 = alloca %"class.std::map", align 8
  %3 = alloca i32, align 4
  %4 = alloca i32, align 4
  %5 = alloca %"struct.std::pair", align 4
  %6 = alloca %"class.std::vector", align 8
  %7 = alloca %"struct.std::_Rb_tree_iterator", align 8
  %8 = alloca %"struct.std::_Rb_tree_iterator", align 8
  %9 = alloca %"struct.std::pair.3", align 4
  %10 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %11 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %12 = alloca %"struct.std::pair", align 8
  %13 = alloca %"struct.std::_Rb_tree_iterator", align 8
  %14 = alloca %"struct.std::_Rb_tree_iterator", align 8
  %15 = alloca i64, align 8
  %16 = alloca %"struct.std::_Rb_tree_iterator", align 8
  %17 = alloca %"struct.std::_Rb_tree_iterator", align 8
  %18 = alloca i64, align 8
  %19 = alloca %"struct.std::_Rb_tree_iterator", align 8
  %20 = alloca %"struct.std::_Rb_tree_iterator", align 8
  %21 = alloca %"struct.std::pair", align 8
  %22 = alloca %"struct.std::pair", align 4
  %23 = alloca %"struct.std::pair", align 4
  %24 = alloca i64, align 8
  %25 = alloca i64, align 8
  %26 = alloca %"class.std::vector", align 8
  %27 = alloca %"struct.std::_Rb_tree_iterator", align 8
  %28 = alloca %"struct.std::_Rb_tree_iterator", align 8
  %29 = alloca %"struct.std::pair.3", align 4
  %30 = alloca %"class.std::vector.5", align 8
  %31 = alloca %"class.std::allocator.7", align 1
  %32 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %33 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %34 = alloca %"struct.std::pair", align 8
  %35 = alloca %"struct.std::_Rb_tree_const_iterator", align 8
  %36 = alloca %"struct.std::_Rb_tree_const_iterator", align 8
  %37 = alloca i32, align 4
  %38 = alloca i64, align 8
  %39 = alloca %"struct.std::_Rb_tree_const_iterator", align 8
  %40 = alloca %"struct.std::_Rb_tree_const_iterator", align 8
  %41 = alloca i32, align 4
  %42 = alloca i64, align 8
  %43 = load ptr, ptr @stdin, align 8, !tbaa !5
  %44 = tail call ptr @freopen(ptr noundef nonnull @.str, ptr noundef nonnull @.str.1, ptr noundef %43)
  %45 = load ptr, ptr @stdout, align 8, !tbaa !5
  %46 = tail call ptr @freopen(ptr noundef nonnull @.str.2, ptr noundef nonnull @.str.3, ptr noundef %45)
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %1) #8
  %47 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERi(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 4 dereferenceable(4) %1)
  call void @llvm.lifetime.start.p0(i64 48, ptr nonnull %2) #8
  call void @_ZNSt3mapISt4pairIiiEiSt4lessIS1_ESaIS0_IKS1_iEEEC2Ev(ptr noundef nonnull align 8 dereferenceable(48) %2) #8
  %48 = load i32, ptr %1, align 4, !tbaa !9
  %49 = icmp sgt i32 %48, 0
  br i1 %49, label %.lr.ph, label %._crit_edge

._crit_edge:                                      ; preds = %66, %0
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %6) #8
  call void @_ZNSt6vectorISt4pairIiiESaIS1_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %6) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %7) #8
  %50 = call ptr @_ZNSt3mapISt4pairIiiEiSt4lessIS1_ESaIS0_IKS1_iEEE5beginEv(ptr noundef nonnull align 8 dereferenceable(48) %2) #8
  store ptr %50, ptr %7, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %8) #8
  %51 = call ptr @_ZNSt3mapISt4pairIiiEiSt4lessIS1_ESaIS0_IKS1_iEEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %2) #8
  store ptr %51, ptr %8, align 8
  %52 = call noundef zeroext i1 @_ZStneRKSt17_Rb_tree_iteratorISt4pairIKS0_IiiEiEES6_(ptr noundef nonnull align 8 dereferenceable(8) %7, ptr noundef nonnull align 8 dereferenceable(8) %8) #8
  br i1 %52, label %.lr.ph79, label %._crit_edge80

.lr.ph79:                                         ; preds = %._crit_edge
  %53 = getelementptr inbounds i8, ptr %9, i64 8
  br label %78

.lr.ph:                                           ; preds = %0, %66
  %.077 = phi i32 [ %69, %66 ], [ 0, %0 ]
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %3) #8
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %4) #8
  %54 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERi(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 4 dereferenceable(4) %3)
          to label %55 unwind label %62

55:                                               ; preds = %.lr.ph
  %56 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERi(ptr noundef nonnull align 8 dereferenceable(16) %54, ptr noundef nonnull align 4 dereferenceable(4) %4)
          to label %57 unwind label %62

57:                                               ; preds = %55
  %58 = load i32, ptr %3, align 4, !tbaa !9
  %59 = load i32, ptr %4, align 4, !tbaa !9
  %60 = icmp sgt i32 %58, %59
  br i1 %60, label %61, label %64

61:                                               ; preds = %57
  call void @_ZSt4swapIiENSt9enable_ifIXsr6__and_ISt6__not_ISt15__is_tuple_likeIT_EESt21is_move_constructibleIS3_ESt18is_move_assignableIS3_EEE5valueEvE4typeERS3_SC_(ptr noundef nonnull align 4 dereferenceable(4) %3, ptr noundef nonnull align 4 dereferenceable(4) %4) #8
  br label %64

62:                                               ; preds = %55, %.lr.ph
  %63 = landingpad { ptr, i32 }
          cleanup
  br label %74

64:                                               ; preds = %61, %57
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %5) #8
  call void @_ZNSt4pairIiiEC2IRiS2_TnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairIS4_S5_EEEbE4typeELb1EEEOS4_OS5_(ptr noundef nonnull align 4 dereferenceable(8) %5, ptr noundef nonnull align 4 dereferenceable(4) %3, ptr noundef nonnull align 4 dereferenceable(4) %4)
  %65 = invoke noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt3mapISt4pairIiiEiSt4lessIS1_ESaIS0_IKS1_iEEEixEOS1_(ptr noundef nonnull align 8 dereferenceable(48) %2, ptr noundef nonnull align 4 dereferenceable(8) %5)
          to label %66 unwind label %72

66:                                               ; preds = %64
  %67 = load i32, ptr %65, align 4, !tbaa !9
  %68 = add nsw i32 %67, 1
  store i32 %68, ptr %65, align 4, !tbaa !9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %5) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %4) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %3) #8
  %69 = add nuw nsw i32 %.077, 1
  %70 = load i32, ptr %1, align 4, !tbaa !9
  %71 = icmp slt i32 %69, %70
  br i1 %71, label %.lr.ph, label %._crit_edge, !llvm.loop !11

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

74:                                               ; preds = %72, %62
  %.pn74 = phi { ptr, i32 } [ %73, %72 ], [ %63, %62 ]
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %4) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %3) #8
  br label %268

._crit_edge80:                                    ; preds = %85, %._crit_edge
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %10) #8
  %75 = call ptr @_ZNSt6vectorISt4pairIiiESaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %6) #8
  store ptr %75, ptr %10, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %11) #8
  %76 = call ptr @_ZNSt6vectorISt4pairIiiESaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %6) #8
  store ptr %76, ptr %11, align 8
  %77 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPSt4pairIiiESt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8) %10, ptr noundef nonnull align 8 dereferenceable(8) %11) #8
  br i1 %77, label %.lr.ph82, label %._crit_edge83

78:                                               ; preds = %.lr.ph79, %85
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %9) #8
  %79 = call noundef nonnull align 4 dereferenceable(12) ptr @_ZNKSt17_Rb_tree_iteratorISt4pairIKS0_IiiEiEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %7) #8
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(12) %9, ptr noundef nonnull align 4 dereferenceable(12) %79, i64 12, i1 false)
  %80 = load i32, ptr %53, align 4, !tbaa !13
  %81 = icmp eq i32 %80, 1
  br i1 %81, label %82, label %85

82:                                               ; preds = %78
  invoke void @_ZNSt6vectorISt4pairIiiESaIS1_EE9push_backERKS1_(ptr noundef nonnull align 8 dereferenceable(24) %6, ptr noundef nonnull align 4 dereferenceable(8) %9)
          to label %85 unwind label %83

83:                                               ; preds = %82
  %84 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %9) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #8
  br label %267

85:                                               ; preds = %82, %78
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %9) #8
  %86 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt17_Rb_tree_iteratorISt4pairIKS0_IiiEiEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %7) #8
  %87 = call noundef zeroext i1 @_ZStneRKSt17_Rb_tree_iteratorISt4pairIKS0_IiiEiEES6_(ptr noundef nonnull align 8 dereferenceable(8) %7, ptr noundef nonnull align 8 dereferenceable(8) %8) #8
  br i1 %87, label %78, label %._crit_edge80

._crit_edge83:                                    ; preds = %94, %._crit_edge80
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %11) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %10) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %13) #8
  %88 = call ptr @_ZNSt3mapISt4pairIiiEiSt4lessIS1_ESaIS0_IKS1_iEEE5beginEv(ptr noundef nonnull align 8 dereferenceable(48) %2) #8
  store ptr %88, ptr %13, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %14) #8
  %89 = call ptr @_ZNSt3mapISt4pairIiiEiSt4lessIS1_ESaIS0_IKS1_iEEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %2) #8
  store ptr %89, ptr %14, align 8
  %90 = call noundef zeroext i1 @_ZStneRKSt17_Rb_tree_iteratorISt4pairIKS0_IiiEiEES6_(ptr noundef nonnull align 8 dereferenceable(8) %13, ptr noundef nonnull align 8 dereferenceable(8) %14) #8
  br i1 %90, label %.lr.ph85, label %._crit_edge86

.lr.ph82:                                         ; preds = %._crit_edge80, %94
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %12) #8
  %91 = call noundef nonnull align 4 dereferenceable(8) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPSt4pairIiiESt6vectorIS2_SaIS2_EEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %10) #8
  %92 = load i64, ptr %91, align 4
  store i64 %92, ptr %12, align 8
  %93 = invoke noundef i64 @_ZNSt3mapISt4pairIiiEiSt4lessIS1_ESaIS0_IKS1_iEEE5eraseERS4_(ptr noundef nonnull align 8 dereferenceable(48) %2, ptr noundef nonnull align 4 dereferenceable(8) %12)
          to label %94 unwind label %97

94:                                               ; preds = %.lr.ph82
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %12) #8
  %95 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZN9__gnu_cxx17__normal_iteratorIPSt4pairIiiESt6vectorIS2_SaIS2_EEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %10) #8
  %96 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPSt4pairIiiESt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8) %10, ptr noundef nonnull align 8 dereferenceable(8) %11) #8
  br i1 %96, label %.lr.ph82, label %._crit_edge83

97:                                               ; preds = %.lr.ph82
  %98 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %12) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %11) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %10) #8
  br label %267

._crit_edge86:                                    ; preds = %.lr.ph85, %._crit_edge83
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %14) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %13) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %15) #8
  store i64 -1, ptr %15, align 8, !tbaa !16
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %16) #8
  %99 = call ptr @_ZNSt3mapISt4pairIiiEiSt4lessIS1_ESaIS0_IKS1_iEEE5beginEv(ptr noundef nonnull align 8 dereferenceable(48) %2) #8
  store ptr %99, ptr %16, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %17) #8
  %100 = call ptr @_ZNSt3mapISt4pairIiiEiSt4lessIS1_ESaIS0_IKS1_iEEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %2) #8
  store ptr %100, ptr %17, align 8
  %101 = call noundef zeroext i1 @_ZStneRKSt17_Rb_tree_iteratorISt4pairIKS0_IiiEiEES6_(ptr noundef nonnull align 8 dereferenceable(8) %16, ptr noundef nonnull align 8 dereferenceable(8) %17) #8
  br i1 %101, label %.lr.ph88, label %._crit_edge89

.lr.ph85:                                         ; preds = %._crit_edge83, %.lr.ph85
  %102 = call noundef nonnull align 4 dereferenceable(12) ptr @_ZNKSt17_Rb_tree_iteratorISt4pairIKS0_IiiEiEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %13) #8
  %103 = getelementptr inbounds i8, ptr %102, i64 8
  %104 = load i32, ptr %103, align 4, !tbaa !13
  %105 = sdiv i32 %104, 2
  store i32 %105, ptr %103, align 4, !tbaa !13
  %106 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt17_Rb_tree_iteratorISt4pairIKS0_IiiEiEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %13) #8
  %107 = call noundef zeroext i1 @_ZStneRKSt17_Rb_tree_iteratorISt4pairIKS0_IiiEiEES6_(ptr noundef nonnull align 8 dereferenceable(8) %13, ptr noundef nonnull align 8 dereferenceable(8) %14) #8
  br i1 %107, label %.lr.ph85, label %._crit_edge86

._crit_edge89:                                    ; preds = %121, %._crit_edge86
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %17) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %16) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %19) #8
  %108 = call ptr @_ZNSt3mapISt4pairIiiEiSt4lessIS1_ESaIS0_IKS1_iEEE5beginEv(ptr noundef nonnull align 8 dereferenceable(48) %2) #8
  store ptr %108, ptr %19, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %20) #8
  %109 = call ptr @_ZNSt3mapISt4pairIiiEiSt4lessIS1_ESaIS0_IKS1_iEEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %2) #8
  store ptr %109, ptr %20, align 8
  %110 = call noundef zeroext i1 @_ZStneRKSt17_Rb_tree_iteratorISt4pairIKS0_IiiEiEES6_(ptr noundef nonnull align 8 dereferenceable(8) %19, ptr noundef nonnull align 8 dereferenceable(8) %20) #8
  br i1 %110, label %.lr.ph91, label %._crit_edge92

.lr.ph91:                                         ; preds = %._crit_edge89
  %111 = getelementptr inbounds i8, ptr %21, i64 4
  br label %128

.lr.ph88:                                         ; preds = %._crit_edge86, %121
  %112 = call noundef nonnull align 4 dereferenceable(12) ptr @_ZNKSt17_Rb_tree_iteratorISt4pairIKS0_IiiEiEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %16) #8
  %.sroa.033.0.copyload = load i32, ptr %112, align 4
  %.sroa.4.0..sroa_idx = getelementptr inbounds i8, ptr %112, i64 4
  %.sroa.4.0.copyload = load i32, ptr %.sroa.4.0..sroa_idx, align 4
  %.sroa.534.0..sroa_idx = getelementptr inbounds i8, ptr %112, i64 8
  %.sroa.534.0.copyload = load i32, ptr %.sroa.534.0..sroa_idx, align 4
  %113 = icmp eq i32 %.sroa.033.0.copyload, %.sroa.4.0.copyload
  %114 = icmp sgt i32 %.sroa.534.0.copyload, 2
  %or.cond = select i1 %113, i1 %114, i1 false
  br i1 %or.cond, label %115, label %121

115:                                              ; preds = %.lr.ph88
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %18) #8
  %116 = sext i32 %.sroa.033.0.copyload to i64
  %117 = mul nsw i64 %116, %116
  %118 = mul nsw i64 %117, %116
  store i64 %118, ptr %18, align 8, !tbaa !16
  %119 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3maxIxERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) %15, ptr noundef nonnull align 8 dereferenceable(8) %18)
  %120 = load i64, ptr %119, align 8, !tbaa !16
  store i64 %120, ptr %15, align 8, !tbaa !16
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %18) #8
  br label %121

121:                                              ; preds = %115, %.lr.ph88
  %122 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt17_Rb_tree_iteratorISt4pairIKS0_IiiEiEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %16) #8
  %123 = call noundef zeroext i1 @_ZStneRKSt17_Rb_tree_iteratorISt4pairIKS0_IiiEiEES6_(ptr noundef nonnull align 8 dereferenceable(8) %16, ptr noundef nonnull align 8 dereferenceable(8) %17) #8
  br i1 %123, label %.lr.ph88, label %._crit_edge89

._crit_edge92:                                    ; preds = %163, %._crit_edge89
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %20) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %19) #8
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %26) #8
  call void @_ZNSt6vectorISt4pairIiiESaIS1_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %26) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %27) #8
  %124 = call ptr @_ZNSt3mapISt4pairIiiEiSt4lessIS1_ESaIS0_IKS1_iEEE5beginEv(ptr noundef nonnull align 8 dereferenceable(48) %2) #8
  store ptr %124, ptr %27, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %28) #8
  %125 = call ptr @_ZNSt3mapISt4pairIiiEiSt4lessIS1_ESaIS0_IKS1_iEEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %2) #8
  store ptr %125, ptr %28, align 8
  %126 = call noundef zeroext i1 @_ZStneRKSt17_Rb_tree_iteratorISt4pairIKS0_IiiEiEES6_(ptr noundef nonnull align 8 dereferenceable(8) %27, ptr noundef nonnull align 8 dereferenceable(8) %28) #8
  br i1 %126, label %.lr.ph94, label %._crit_edge95

.lr.ph94:                                         ; preds = %._crit_edge92
  %127 = getelementptr inbounds i8, ptr %29, i64 4
  br label %166

128:                                              ; preds = %.lr.ph91, %163
  %129 = call noundef nonnull align 4 dereferenceable(12) ptr @_ZNKSt17_Rb_tree_iteratorISt4pairIKS0_IiiEiEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %19) #8
  %130 = load i64, ptr %129, align 4
  %.sroa.5.0..sroa_idx = getelementptr inbounds i8, ptr %129, i64 8
  %.sroa.5.0.copyload = load i32, ptr %.sroa.5.0..sroa_idx, align 4
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %21) #8
  store i64 %130, ptr %21, align 8
  %131 = trunc i64 %130 to i32
  %132 = lshr i64 %130, 32
  %133 = trunc nuw i64 %132 to i32
  %134 = icmp ne i32 %131, %133
  %135 = icmp sgt i32 %.sroa.5.0.copyload, 1
  %or.cond5 = select i1 %134, i1 %135, i1 false
  br i1 %or.cond5, label %136, label %163

136:                                              ; preds = %128
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %22) #8
  call void @_ZNSt4pairIiiEC2IRiS2_TnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairIS4_S5_EEEbE4typeELb1EEEOS4_OS5_(ptr noundef nonnull align 4 dereferenceable(8) %22, ptr noundef nonnull align 4 dereferenceable(4) %21, ptr noundef nonnull align 4 dereferenceable(4) %21)
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %23) #8
  call void @_ZNSt4pairIiiEC2IRiS2_TnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairIS4_S5_EEEbE4typeELb1EEEOS4_OS5_(ptr noundef nonnull align 4 dereferenceable(8) %23, ptr noundef nonnull align 4 dereferenceable(4) %111, ptr noundef nonnull align 4 dereferenceable(4) %111)
  %137 = invoke noundef i64 @_ZNKSt3mapISt4pairIiiEiSt4lessIS1_ESaIS0_IKS1_iEEE5countERS4_(ptr noundef nonnull align 8 dereferenceable(48) %2, ptr noundef nonnull align 4 dereferenceable(8) %22)
          to label %138 unwind label %148

138:                                              ; preds = %136
  %.not68 = icmp eq i64 %137, 0
  br i1 %.not68, label %150, label %139

139:                                              ; preds = %138
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %24) #8
  %140 = load i32, ptr %21, align 8, !tbaa !18
  %141 = sext i32 %140 to i64
  %142 = mul nsw i64 %141, %141
  %143 = load i32, ptr %111, align 4, !tbaa !19
  %144 = sext i32 %143 to i64
  %145 = mul nsw i64 %142, %144
  store i64 %145, ptr %24, align 8, !tbaa !16
  %146 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3maxIxERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) %15, ptr noundef nonnull align 8 dereferenceable(8) %24)
  %147 = load i64, ptr %146, align 8, !tbaa !16
  store i64 %147, ptr %15, align 8, !tbaa !16
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %24) #8
  br label %150

148:                                              ; preds = %150, %136
  %149 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %23) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %22) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %21) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %20) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %19) #8
  br label %266

150:                                              ; preds = %139, %138
  %151 = invoke noundef i64 @_ZNKSt3mapISt4pairIiiEiSt4lessIS1_ESaIS0_IKS1_iEEE5countERS4_(ptr noundef nonnull align 8 dereferenceable(48) %2, ptr noundef nonnull align 4 dereferenceable(8) %23)
          to label %152 unwind label %148

152:                                              ; preds = %150
  %.not71 = icmp eq i64 %151, 0
  br i1 %.not71, label %162, label %153

153:                                              ; preds = %152
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %25) #8
  %154 = load i32, ptr %111, align 4, !tbaa !19
  %155 = sext i32 %154 to i64
  %156 = mul nsw i64 %155, %155
  %157 = load i32, ptr %21, align 8, !tbaa !18
  %158 = sext i32 %157 to i64
  %159 = mul nsw i64 %156, %158
  store i64 %159, ptr %25, align 8, !tbaa !16
  %160 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3maxIxERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) %15, ptr noundef nonnull align 8 dereferenceable(8) %25)
  %161 = load i64, ptr %160, align 8, !tbaa !16
  store i64 %161, ptr %15, align 8, !tbaa !16
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %25) #8
  br label %162

162:                                              ; preds = %153, %152
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %23) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %22) #8
  br label %163

163:                                              ; preds = %162, %128
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %21) #8
  %164 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt17_Rb_tree_iteratorISt4pairIKS0_IiiEiEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %19) #8
  %165 = call noundef zeroext i1 @_ZStneRKSt17_Rb_tree_iteratorISt4pairIKS0_IiiEiEES6_(ptr noundef nonnull align 8 dereferenceable(8) %19, ptr noundef nonnull align 8 dereferenceable(8) %20) #8
  br i1 %165, label %128, label %._crit_edge92

._crit_edge95:                                    ; preds = %173, %._crit_edge92
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %28) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %27) #8
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %30) #8
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %31) #8
  call void @_ZNSaISt3setIiSt4lessIiESaIiEEEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %31) #8
  invoke void @_ZNSt6vectorISt3setIiSt4lessIiESaIiEESaIS4_EEC2EmRKS5_(ptr noundef nonnull align 8 dereferenceable(24) %30, i64 noundef 1000005, ptr noundef nonnull align 1 dereferenceable(1) %31)
          to label %176 unwind label %182

166:                                              ; preds = %.lr.ph94, %173
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %29) #8
  %167 = call noundef nonnull align 4 dereferenceable(12) ptr @_ZNKSt17_Rb_tree_iteratorISt4pairIKS0_IiiEiEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %27) #8
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(12) %29, ptr noundef nonnull align 4 dereferenceable(12) %167, i64 12, i1 false)
  %168 = load i32, ptr %29, align 4, !tbaa !20
  %169 = load i32, ptr %127, align 4, !tbaa !21
  %.not65 = icmp eq i32 %168, %169
  br i1 %.not65, label %173, label %170

170:                                              ; preds = %166
  invoke void @_ZNSt6vectorISt4pairIiiESaIS1_EE9push_backERKS1_(ptr noundef nonnull align 8 dereferenceable(24) %26, ptr noundef nonnull align 4 dereferenceable(8) %29)
          to label %173 unwind label %171

171:                                              ; preds = %170
  %172 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %29) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %28) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %27) #8
  br label %265

173:                                              ; preds = %170, %166
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %29) #8
  %174 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt17_Rb_tree_iteratorISt4pairIKS0_IiiEiEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %27) #8
  %175 = call noundef zeroext i1 @_ZStneRKSt17_Rb_tree_iteratorISt4pairIKS0_IiiEiEES6_(ptr noundef nonnull align 8 dereferenceable(8) %27, ptr noundef nonnull align 8 dereferenceable(8) %28) #8
  br i1 %175, label %166, label %._crit_edge95

176:                                              ; preds = %._crit_edge95
  call void @_ZNSt15__new_allocatorISt3setIiSt4lessIiESaIiEEED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %31) #8
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %31) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %32) #8
  %177 = call ptr @_ZNSt6vectorISt4pairIiiESaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %26) #8
  store ptr %177, ptr %32, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %33) #8
  %178 = call ptr @_ZNSt6vectorISt4pairIiiESaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %26) #8
  store ptr %178, ptr %33, align 8
  %179 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPSt4pairIiiESt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8) %32, ptr noundef nonnull align 8 dereferenceable(8) %33) #8
  br i1 %179, label %.lr.ph97, label %._crit_edge98

.lr.ph97:                                         ; preds = %176
  %180 = getelementptr inbounds i8, ptr %34, i64 4
  br label %184

._crit_edge98:                                    ; preds = %190, %176
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %33) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %32) #8
  %181 = call noundef i64 @_ZNKSt6vectorISt4pairIiiESaIS1_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %26) #8
  %.not109 = icmp eq i64 %181, 0
  br i1 %.not109, label %._crit_edge108, label %.lr.ph107

182:                                              ; preds = %._crit_edge95
  %183 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt15__new_allocatorISt3setIiSt4lessIiESaIiEEED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %31) #8
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %31) #8
  br label %264

184:                                              ; preds = %.lr.ph97, %190
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %34) #8
  %185 = call noundef nonnull align 4 dereferenceable(8) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPSt4pairIiiESt6vectorIS2_SaIS2_EEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %32) #8
  %186 = load i64, ptr %185, align 4
  store i64 %186, ptr %34, align 8
  %sext = shl i64 %186, 32
  %187 = ashr exact i64 %sext, 32
  %188 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt6vectorISt3setIiSt4lessIiESaIiEESaIS4_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %30, i64 noundef %187) #8
  %189 = invoke { ptr, i8 } @_ZNSt3setIiSt4lessIiESaIiEE6insertERKi(ptr noundef nonnull align 8 dereferenceable(48) %188, ptr noundef nonnull align 4 dereferenceable(4) %180)
          to label %190 unwind label %193

190:                                              ; preds = %184
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %34) #8
  %191 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZN9__gnu_cxx17__normal_iteratorIPSt4pairIiiESt6vectorIS2_SaIS2_EEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %32) #8
  %192 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPSt4pairIiiESt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8) %32, ptr noundef nonnull align 8 dereferenceable(8) %33) #8
  br i1 %192, label %184, label %._crit_edge98

193:                                              ; preds = %184
  %194 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %34) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %33) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %32) #8
  br label %263

._crit_edge108:                                   ; preds = %255, %._crit_edge98
  %195 = load i64, ptr %15, align 8, !tbaa !16
  %196 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEx(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, i64 noundef %195)
          to label %258 unwind label %261

.lr.ph107:                                        ; preds = %._crit_edge98, %255
  %indvars.iv = phi i64 [ %indvars.iv.next, %255 ], [ 0, %._crit_edge98 ]
  %197 = call noundef nonnull align 4 dereferenceable(8) ptr @_ZNSt6vectorISt4pairIiiESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %26, i64 noundef %indvars.iv) #8
  %198 = load i32, ptr %197, align 4, !tbaa !18
  %199 = call noundef nonnull align 4 dereferenceable(8) ptr @_ZNSt6vectorISt4pairIiiESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %26, i64 noundef %indvars.iv) #8
  %200 = getelementptr inbounds i8, ptr %199, i64 4
  %201 = load i32, ptr %200, align 4, !tbaa !19
  %202 = sext i32 %198 to i64
  %203 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt6vectorISt3setIiSt4lessIiESaIiEESaIS4_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %30, i64 noundef %202) #8
  %204 = call noundef i64 @_ZNKSt3setIiSt4lessIiESaIiEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(48) %203) #8
  %205 = sext i32 %201 to i64
  %206 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt6vectorISt3setIiSt4lessIiESaIiEESaIS4_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %30, i64 noundef %205) #8
  %207 = call noundef i64 @_ZNKSt3setIiSt4lessIiESaIiEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(48) %206) #8
  %208 = icmp ult i64 %204, %207
  br i1 %208, label %209, label %232

209:                                              ; preds = %.lr.ph107
  %210 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt6vectorISt3setIiSt4lessIiESaIiEESaIS4_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %30, i64 noundef %202) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %35) #8
  %211 = call ptr @_ZNKSt3setIiSt4lessIiESaIiEE5beginEv(ptr noundef nonnull align 8 dereferenceable(48) %210) #8
  store ptr %211, ptr %35, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %36) #8
  %212 = call ptr @_ZNKSt3setIiSt4lessIiESaIiEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %210) #8
  store ptr %212, ptr %36, align 8
  %213 = call noundef zeroext i1 @_ZStneRKSt23_Rb_tree_const_iteratorIiES2_(ptr noundef nonnull align 8 dereferenceable(8) %35, ptr noundef nonnull align 8 dereferenceable(8) %36) #8
  br i1 %213, label %.lr.ph103, label %._crit_edge104

.lr.ph103:                                        ; preds = %209
  %214 = mul nsw i64 %205, %202
  br label %215

._crit_edge104:                                   ; preds = %229, %209
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %36) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %35) #8
  br label %255

215:                                              ; preds = %.lr.ph103, %229
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %37) #8
  %216 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt23_Rb_tree_const_iteratorIiEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %35) #8
  %217 = load i32, ptr %216, align 4, !tbaa !9
  store i32 %217, ptr %37, align 4, !tbaa !9
  %218 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt6vectorISt3setIiSt4lessIiESaIiEESaIS4_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %30, i64 noundef %205) #8
  %219 = invoke noundef i64 @_ZNKSt3setIiSt4lessIiESaIiEE5countERKi(ptr noundef nonnull align 8 dereferenceable(48) %218, ptr noundef nonnull align 4 dereferenceable(4) %37)
          to label %220 unwind label %227

220:                                              ; preds = %215
  %.not61 = icmp eq i64 %219, 0
  br i1 %.not61, label %229, label %221

221:                                              ; preds = %220
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %38) #8
  %222 = load i32, ptr %37, align 4, !tbaa !9
  %223 = sext i32 %222 to i64
  %224 = mul nsw i64 %214, %223
  store i64 %224, ptr %38, align 8, !tbaa !16
  %225 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3maxIxERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) %15, ptr noundef nonnull align 8 dereferenceable(8) %38)
  %226 = load i64, ptr %225, align 8, !tbaa !16
  store i64 %226, ptr %15, align 8, !tbaa !16
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %38) #8
  br label %229

227:                                              ; preds = %215
  %228 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %37) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %36) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %35) #8
  br label %263

229:                                              ; preds = %221, %220
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %37) #8
  %230 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt23_Rb_tree_const_iteratorIiEppEv(ptr noundef nonnull align 8 dereferenceable(8) %35) #8
  %231 = call noundef zeroext i1 @_ZStneRKSt23_Rb_tree_const_iteratorIiES2_(ptr noundef nonnull align 8 dereferenceable(8) %35, ptr noundef nonnull align 8 dereferenceable(8) %36) #8
  br i1 %231, label %215, label %._crit_edge104

232:                                              ; preds = %.lr.ph107
  %233 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt6vectorISt3setIiSt4lessIiESaIiEESaIS4_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %30, i64 noundef %205) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %39) #8
  %234 = call ptr @_ZNKSt3setIiSt4lessIiESaIiEE5beginEv(ptr noundef nonnull align 8 dereferenceable(48) %233) #8
  store ptr %234, ptr %39, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %40) #8
  %235 = call ptr @_ZNKSt3setIiSt4lessIiESaIiEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %233) #8
  store ptr %235, ptr %40, align 8
  %236 = call noundef zeroext i1 @_ZStneRKSt23_Rb_tree_const_iteratorIiES2_(ptr noundef nonnull align 8 dereferenceable(8) %39, ptr noundef nonnull align 8 dereferenceable(8) %40) #8
  br i1 %236, label %.lr.ph100, label %._crit_edge101

.lr.ph100:                                        ; preds = %232
  %237 = mul nsw i64 %205, %202
  br label %238

._crit_edge101:                                   ; preds = %252, %232
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %40) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %39) #8
  br label %255

238:                                              ; preds = %.lr.ph100, %252
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %41) #8
  %239 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt23_Rb_tree_const_iteratorIiEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %39) #8
  %240 = load i32, ptr %239, align 4, !tbaa !9
  store i32 %240, ptr %41, align 4, !tbaa !9
  %241 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt6vectorISt3setIiSt4lessIiESaIiEESaIS4_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %30, i64 noundef %202) #8
  %242 = invoke noundef i64 @_ZNKSt3setIiSt4lessIiESaIiEE5countERKi(ptr noundef nonnull align 8 dereferenceable(48) %241, ptr noundef nonnull align 4 dereferenceable(4) %41)
          to label %243 unwind label %250

243:                                              ; preds = %238
  %.not = icmp eq i64 %242, 0
  br i1 %.not, label %252, label %244

244:                                              ; preds = %243
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %42) #8
  %245 = load i32, ptr %41, align 4, !tbaa !9
  %246 = sext i32 %245 to i64
  %247 = mul nsw i64 %237, %246
  store i64 %247, ptr %42, align 8, !tbaa !16
  %248 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3maxIxERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) %15, ptr noundef nonnull align 8 dereferenceable(8) %42)
  %249 = load i64, ptr %248, align 8, !tbaa !16
  store i64 %249, ptr %15, align 8, !tbaa !16
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %42) #8
  br label %252

250:                                              ; preds = %238
  %251 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %41) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %40) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %39) #8
  br label %263

252:                                              ; preds = %244, %243
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %41) #8
  %253 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt23_Rb_tree_const_iteratorIiEppEv(ptr noundef nonnull align 8 dereferenceable(8) %39) #8
  %254 = call noundef zeroext i1 @_ZStneRKSt23_Rb_tree_const_iteratorIiES2_(ptr noundef nonnull align 8 dereferenceable(8) %39, ptr noundef nonnull align 8 dereferenceable(8) %40) #8
  br i1 %254, label %238, label %._crit_edge101

255:                                              ; preds = %._crit_edge101, %._crit_edge104
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %256 = call noundef i64 @_ZNKSt6vectorISt4pairIiiESaIS1_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %26) #8
  %257 = icmp ugt i64 %256, %indvars.iv.next
  br i1 %257, label %.lr.ph107, label %._crit_edge108, !llvm.loop !22

258:                                              ; preds = %._crit_edge108
  %259 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSoS_E(ptr noundef nonnull align 8 dereferenceable(8) %196, ptr noundef nonnull @_ZSt4endlIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_)
          to label %260 unwind label %261

260:                                              ; preds = %258
  call void @_ZNSt6vectorISt3setIiSt4lessIiESaIiEESaIS4_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %30) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %30) #8
  call void @_ZNSt6vectorISt4pairIiiESaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %26) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %26) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %15) #8
  call void @_ZNSt6vectorISt4pairIiiESaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %6) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %6) #8
  call void @_ZNSt3mapISt4pairIiiEiSt4lessIS1_ESaIS0_IKS1_iEEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %2) #8
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %2) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %1) #8
  ret i32 0

261:                                              ; preds = %258, %._crit_edge108
  %262 = landingpad { ptr, i32 }
          cleanup
  br label %263

263:                                              ; preds = %227, %250, %261, %193
  %.pn62 = phi { ptr, i32 } [ %194, %193 ], [ %262, %261 ], [ %228, %227 ], [ %251, %250 ]
  call void @_ZNSt6vectorISt3setIiSt4lessIiESaIiEESaIS4_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %30) #8
  br label %264

264:                                              ; preds = %263, %182
  %.pn62.pn = phi { ptr, i32 } [ %.pn62, %263 ], [ %183, %182 ]
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %30) #8
  br label %265

265:                                              ; preds = %264, %171
  %.pn66 = phi { ptr, i32 } [ %172, %171 ], [ %.pn62.pn, %264 ]
  call void @_ZNSt6vectorISt4pairIiiESaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %26) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %26) #8
  br label %266

266:                                              ; preds = %265, %148
  %.pn69 = phi { ptr, i32 } [ %149, %148 ], [ %.pn66, %265 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %15) #8
  br label %267

267:                                              ; preds = %266, %97, %83
  %.pn72 = phi { ptr, i32 } [ %84, %83 ], [ %98, %97 ], [ %.pn69, %266 ]
  call void @_ZNSt6vectorISt4pairIiiESaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %6) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %6) #8
  br label %268

268:                                              ; preds = %267, %74
  %.pn74.pn = phi { ptr, i32 } [ %.pn74, %74 ], [ %.pn72, %267 ]
  call void @_ZNSt3mapISt4pairIiiEiSt4lessIS1_ESaIS0_IKS1_iEEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %2) #8
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %2) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %1) #8
  resume { ptr, i32 } %.pn74.pn
}

declare ptr @freopen(ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #1

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

declare noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERi(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 4 dereferenceable(4)) local_unnamed_addr #1

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

declare i32 @__gxx_personality_v0(...)

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt4pairIiiEC2IRiS2_TnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairIS4_S5_EEEbE4typeELb1EEEOS4_OS5_(ptr noundef nonnull align 4 dereferenceable(8), ptr noundef nonnull align 4 dereferenceable(4), ptr noundef nonnull align 4 dereferenceable(4)) unnamed_addr #3 align 2

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

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

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

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(12) ptr @_ZNKSt17_Rb_tree_iteratorISt4pairIKS0_IiiEiEEdeEv(ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #3 align 2

; Function Attrs: mustprogress nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #6

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

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

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZN9__gnu_cxxneIPSt4pairIiiESt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #4

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef i64 @_ZNSt3mapISt4pairIiiEiSt4lessIS1_ESaIS0_IKS1_iEEE5eraseERS4_(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 4 dereferenceable(8)) local_unnamed_addr #5 align 2

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

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef i64 @_ZNKSt3mapISt4pairIiiEiSt4lessIS1_ESaIS0_IKS1_iEEE5countERS4_(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 4 dereferenceable(8)) local_unnamed_addr #5 align 2

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

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

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

; Function Attrs: mustprogress uwtable
declare dso_local { ptr, i8 } @_ZNSt3setIiSt4lessIiESaIiEE6insertERKi(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 4 dereferenceable(4)) local_unnamed_addr #5 align 2

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

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

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

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

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

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

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef i64 @_ZNKSt3setIiSt4lessIiESaIiEE5countERKi(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 4 dereferenceable(4)) local_unnamed_addr #5 align 2

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

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

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

; Function Attrs: inlinehint mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZSt4endlIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_(ptr noundef nonnull align 8 dereferenceable(8)) #7

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

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

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

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

attributes #0 = { mustprogress norecurse uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { "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 = { mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #4 = { 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 #5 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #6 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #7 = { 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 #8 = { 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 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"int", !7, i64 0}
!11 = distinct !{!11, !12}
!12 = !{!"llvm.loop.mustprogress"}
!13 = !{!14, !10, i64 8}
!14 = !{!"_ZTSSt4pairIKS_IiiEiE", !15, i64 0, !10, i64 8}
!15 = !{!"_ZTSSt4pairIiiE", !10, i64 0, !10, i64 4}
!16 = !{!17, !17, i64 0}
!17 = !{!"long long", !7, i64 0}
!18 = !{!15, !10, i64 0}
!19 = !{!15, !10, i64 4}
!20 = !{!14, !10, i64 0}
!21 = !{!14, !10, i64 4}
!22 = distinct !{!22, !12}


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