; LLVM IR from ippeb/ACM-ICPC :: graph_theory/edmonds_karp/edmonds_karp_adjacency_lists.ll (Z12edmonds_karpii)

; 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::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>, std::pair<int, int>>, std::_Select1st<std::pair<const std::pair<int, int>, std::pair<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>, std::pair<int, int>>, std::_Select1st<std::pair<const std::pair<int, int>, std::pair<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 }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.__gnu_cxx::__normal_iterator" = type { ptr }
%"struct.std::pair.5" = type { i32, i32 }

@M = external dso_local global %"class.std::map", align 8
@V = external dso_local global [20002 x %"class.std::vector"], align 16

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

; Function Attrs: mustprogress uwtable
declare dso_local i64 @_ZSt9make_pairIRiS0_ESt4pairINSt25__strip_reference_wrapperINSt5decayIT_E4typeEE6__typeENS2_INS3_IT0_E4typeEE6__typeEEOS4_OS9_(ptr noundef nonnull align 4 dereferenceable(4), ptr noundef nonnull align 4 dereferenceable(4)) #1

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

; Function Attrs: mustprogress uwtable
define dso_local noundef i32 @_Z12edmonds_karpii(i32 noundef %0, i32 noundef %1) #1 {
  %3 = alloca i32, align 4
  %4 = alloca i32, align 4
  %5 = alloca i32, align 4
  %6 = alloca [20002 x i32], align 16
  %7 = alloca [20002 x i32], align 16
  %8 = alloca [20002 x i32], align 16
  %9 = alloca i32, align 4
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  %13 = alloca i32, align 4
  %14 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %15 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %16 = alloca %"struct.std::pair.5", align 4
  %17 = alloca %"struct.std::pair.5", align 4
  %18 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %19 = alloca i32, align 4
  %20 = alloca %"struct.std::pair.5", align 4
  %21 = alloca %"struct.std::pair.5", align 4
  %22 = alloca i32, align 4
  %23 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %24 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %25 = alloca %"struct.std::pair.5", align 4
  %26 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  store i32 %0, ptr %4, align 4, !tbaa !5
  store i32 %1, ptr %5, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 80008, ptr %6) #6
  call void @llvm.lifetime.start.p0(i64 80008, ptr %7) #6
  call void @llvm.lifetime.start.p0(i64 80008, ptr %8) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #6
  %27 = load i32, ptr %5, align 4, !tbaa !5
  %28 = load i32, ptr %4, align 4, !tbaa !5
  %29 = icmp eq i32 %27, %28
  br i1 %29, label %30, label %31

30:                                               ; preds = %2
  store i32 1000000000, ptr %3, align 4
  store i32 1, ptr %11, align 4
  br label %189

31:                                               ; preds = %2
  br label %32

32:                                               ; preds = %161, %31
  br label %33

33:                                               ; preds = %32
  %34 = getelementptr inbounds [20002 x i32], ptr %6, i64 0, i64 0
  call void @llvm.memset.p0.i64(ptr align 16 %34, i8 -1, i64 80008, i1 false)
  store i32 0, ptr %10, align 4, !tbaa !5
  store i32 0, ptr %9, align 4, !tbaa !5
  %35 = load i32, ptr %4, align 4, !tbaa !5
  %36 = sext i32 %35 to i64
  %37 = getelementptr inbounds [20002 x i32], ptr %8, i64 0, i64 %36
  store i32 1000000000, ptr %37, align 4, !tbaa !5
  %38 = load i32, ptr %4, align 4, !tbaa !5
  %39 = load i32, ptr %10, align 4, !tbaa !5
  %40 = add nsw i32 %39, 1
  store i32 %40, ptr %10, align 4, !tbaa !5
  %41 = sext i32 %39 to i64
  %42 = getelementptr inbounds [20002 x i32], ptr %7, i64 0, i64 %41
  store i32 %38, ptr %42, align 4, !tbaa !5
  br label %43

43:                                               ; preds = %116, %33
  %44 = load i32, ptr %9, align 4, !tbaa !5
  %45 = load i32, ptr %10, align 4, !tbaa !5
  %46 = icmp slt i32 %44, %45
  br i1 %46, label %47, label %53

47:                                               ; preds = %43
  %48 = load i32, ptr %5, align 4, !tbaa !5
  %49 = sext i32 %48 to i64
  %50 = getelementptr inbounds [20002 x i32], ptr %6, i64 0, i64 %49
  %51 = load i32, ptr %50, align 4, !tbaa !5
  %52 = icmp slt i32 %51, 0
  br label %53

53:                                               ; preds = %47, %43
  %54 = phi i1 [ false, %43 ], [ %52, %47 ]
  br i1 %54, label %55, label %117

55:                                               ; preds = %53
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #6
  %56 = load i32, ptr %9, align 4, !tbaa !5
  %57 = add nsw i32 %56, 1
  store i32 %57, ptr %9, align 4, !tbaa !5
  %58 = sext i32 %56 to i64
  %59 = getelementptr inbounds [20002 x i32], ptr %7, i64 0, i64 %58
  %60 = load i32, ptr %59, align 4, !tbaa !5
  store i32 %60, ptr %12, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #6
  %61 = load i32, ptr %12, align 4, !tbaa !5
  %62 = sext i32 %61 to i64
  %63 = getelementptr inbounds [20002 x %"class.std::vector"], ptr @V, i64 0, i64 %62
  %64 = call ptr @_ZNSt6vectorIiSaIiEE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %63) #6
  %65 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %14, i32 0, i32 0
  store ptr %64, ptr %65, align 8
  br label %66

66:                                               ; preds = %113, %55
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #6
  %67 = load i32, ptr %12, align 4, !tbaa !5
  %68 = sext i32 %67 to i64
  %69 = getelementptr inbounds [20002 x %"class.std::vector"], ptr @V, i64 0, i64 %68
  %70 = call ptr @_ZNSt6vectorIiSaIiEE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %69) #6
  %71 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %15, i32 0, i32 0
  store ptr %70, ptr %71, align 8
  %72 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPiSt6vectorIiSaIiEEEEbRKNS_17__normal_iteratorIT_T0_EESA_(ptr noundef nonnull align 8 dereferenceable(8) %14, ptr noundef nonnull align 8 dereferenceable(8) %15) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #6
  br i1 %72, label %74, label %73

73:                                               ; preds = %66
  store i32 6, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #6
  br label %116

74:                                               ; preds = %66
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #6
  %75 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %14) #6
  %76 = call i64 @_ZSt9make_pairIRiS0_ESt4pairINSt25__strip_reference_wrapperINSt5decayIT_E4typeEE6__typeENS2_INS3_IT0_E4typeEE6__typeEEOS4_OS9_(ptr noundef nonnull align 4 dereferenceable(4) %12, ptr noundef nonnull align 4 dereferenceable(4) %75)
  store i64 %76, ptr %17, align 4
  %77 = call noundef nonnull align 4 dereferenceable(8) ptr @_ZNSt3mapISt4pairIiiES1_St4lessIS1_ESaIS0_IKS1_S1_EEEixEOS1_(ptr noundef nonnull align 8 dereferenceable(48) @M, ptr noundef nonnull align 4 dereferenceable(8) %17)
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %16, ptr align 4 %77, i64 8, i1 false)
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #6
  %78 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %14) #6
  %79 = load i32, ptr %78, align 4, !tbaa !5
  %80 = sext i32 %79 to i64
  %81 = getelementptr inbounds [20002 x i32], ptr %6, i64 0, i64 %80
  %82 = load i32, ptr %81, align 4, !tbaa !5
  %83 = icmp slt i32 %82, 0
  br i1 %83, label %84, label %112

84:                                               ; preds = %74
  %85 = getelementptr inbounds %"struct.std::pair.5", ptr %16, i32 0, i32 0
  %86 = load i32, ptr %85, align 4, !tbaa !9
  %87 = getelementptr inbounds %"struct.std::pair.5", ptr %16, i32 0, i32 1
  %88 = load i32, ptr %87, align 4, !tbaa !11
  %89 = sub nsw i32 %86, %88
  store i32 %89, ptr %13, align 4, !tbaa !5
  %90 = icmp ne i32 %89, 0
  br i1 %90, label %91, label %112

91:                                               ; preds = %84
  %92 = load i32, ptr %12, align 4, !tbaa !5
  %93 = sext i32 %92 to i64
  %94 = getelementptr inbounds [20002 x i32], ptr %8, i64 0, i64 %93
  %95 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3minIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %94, ptr noundef nonnull align 4 dereferenceable(4) %13)
  %96 = load i32, ptr %95, align 4, !tbaa !5
  %97 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %14) #6
  %98 = load i32, ptr %97, align 4, !tbaa !5
  %99 = sext i32 %98 to i64
  %100 = getelementptr inbounds [20002 x i32], ptr %8, i64 0, i64 %99
  store i32 %96, ptr %100, align 4, !tbaa !5
  %101 = load i32, ptr %12, align 4, !tbaa !5
  %102 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %14) #6
  %103 = load i32, ptr %102, align 4, !tbaa !5
  %104 = sext i32 %103 to i64
  %105 = getelementptr inbounds [20002 x i32], ptr %6, i64 0, i64 %104
  store i32 %101, ptr %105, align 4, !tbaa !5
  %106 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %14) #6
  %107 = load i32, ptr %106, align 4, !tbaa !5
  %108 = load i32, ptr %10, align 4, !tbaa !5
  %109 = add nsw i32 %108, 1
  store i32 %109, ptr %10, align 4, !tbaa !5
  %110 = sext i32 %108 to i64
  %111 = getelementptr inbounds [20002 x i32], ptr %7, i64 0, i64 %110
  store i32 %107, ptr %111, align 4, !tbaa !5
  br label %112

112:                                              ; preds = %91, %84, %74
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #6
  br label %113

113:                                              ; preds = %112
  %114 = call ptr @_ZN9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEppEi(ptr noundef nonnull align 8 dereferenceable(8) %14, i32 noundef 0) #6
  %115 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %18, i32 0, i32 0
  store ptr %114, ptr %115, align 8
  br label %66, !llvm.loop !12

116:                                              ; preds = %73
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #6
  br label %43, !llvm.loop !14

117:                                              ; preds = %53
  %118 = load i32, ptr %5, align 4, !tbaa !5
  %119 = sext i32 %118 to i64
  %120 = getelementptr inbounds [20002 x i32], ptr %6, i64 0, i64 %119
  %121 = load i32, ptr %120, align 4, !tbaa !5
  %122 = icmp slt i32 %121, 0
  br i1 %122, label %123, label %124

123:                                              ; preds = %117
  br label %162

124:                                              ; preds = %117
  call void @llvm.lifetime.start.p0(i64 4, ptr %19) #6
  %125 = load i32, ptr %5, align 4, !tbaa !5
  store i32 %125, ptr %19, align 4, !tbaa !5
  br label %126

126:                                              ; preds = %156, %124
  %127 = load i32, ptr %19, align 4, !tbaa !5
  %128 = load i32, ptr %4, align 4, !tbaa !5
  %129 = icmp ne i32 %127, %128
  br i1 %129, label %131, label %130

130:                                              ; preds = %126
  store i32 9, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %19) #6
  br label %161

131:                                              ; preds = %126
  %132 = load i32, ptr %5, align 4, !tbaa !5
  %133 = sext i32 %132 to i64
  %134 = getelementptr inbounds [20002 x i32], ptr %8, i64 0, i64 %133
  %135 = load i32, ptr %134, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %20) #6
  %136 = load i32, ptr %19, align 4, !tbaa !5
  %137 = sext i32 %136 to i64
  %138 = getelementptr inbounds [20002 x i32], ptr %6, i64 0, i64 %137
  %139 = call i64 @_ZSt9make_pairIRiS0_ESt4pairINSt25__strip_reference_wrapperINSt5decayIT_E4typeEE6__typeENS2_INS3_IT0_E4typeEE6__typeEEOS4_OS9_(ptr noundef nonnull align 4 dereferenceable(4) %138, ptr noundef nonnull align 4 dereferenceable(4) %19)
  store i64 %139, ptr %20, align 4
  %140 = call noundef nonnull align 4 dereferenceable(8) ptr @_ZNSt3mapISt4pairIiiES1_St4lessIS1_ESaIS0_IKS1_S1_EEEixEOS1_(ptr noundef nonnull align 8 dereferenceable(48) @M, ptr noundef nonnull align 4 dereferenceable(8) %20)
  %141 = getelementptr inbounds %"struct.std::pair.5", ptr %140, i32 0, i32 1
  %142 = load i32, ptr %141, align 4, !tbaa !11
  %143 = add nsw i32 %142, %135
  store i32 %143, ptr %141, align 4, !tbaa !11
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #6
  %144 = load i32, ptr %5, align 4, !tbaa !5
  %145 = sext i32 %144 to i64
  %146 = getelementptr inbounds [20002 x i32], ptr %8, i64 0, i64 %145
  %147 = load i32, ptr %146, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %21) #6
  %148 = load i32, ptr %19, align 4, !tbaa !5
  %149 = sext i32 %148 to i64
  %150 = getelementptr inbounds [20002 x i32], ptr %6, i64 0, i64 %149
  %151 = call i64 @_ZSt9make_pairIRiS0_ESt4pairINSt25__strip_reference_wrapperINSt5decayIT_E4typeEE6__typeENS2_INS3_IT0_E4typeEE6__typeEEOS4_OS9_(ptr noundef nonnull align 4 dereferenceable(4) %19, ptr noundef nonnull align 4 dereferenceable(4) %150)
  store i64 %151, ptr %21, align 4
  %152 = call noundef nonnull align 4 dereferenceable(8) ptr @_ZNSt3mapISt4pairIiiES1_St4lessIS1_ESaIS0_IKS1_S1_EEEixEOS1_(ptr noundef nonnull align 8 dereferenceable(48) @M, ptr noundef nonnull align 4 dereferenceable(8) %21)
  %153 = getelementptr inbounds %"struct.std::pair.5", ptr %152, i32 0, i32 1
  %154 = load i32, ptr %153, align 4, !tbaa !11
  %155 = sub nsw i32 %154, %147
  store i32 %155, ptr %153, align 4, !tbaa !11
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #6
  br label %156

156:                                              ; preds = %131
  %157 = load i32, ptr %19, align 4, !tbaa !5
  %158 = sext i32 %157 to i64
  %159 = getelementptr inbounds [20002 x i32], ptr %6, i64 0, i64 %158
  %160 = load i32, ptr %159, align 4, !tbaa !5
  store i32 %160, ptr %19, align 4, !tbaa !5
  br label %126, !llvm.loop !15

161:                                              ; preds = %130
  br label %32, !llvm.loop !16

162:                                              ; preds = %123
  call void @llvm.lifetime.start.p0(i64 4, ptr %22) #6
  store i32 0, ptr %22, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %23) #6
  %163 = load i32, ptr %4, align 4, !tbaa !5
  %164 = sext i32 %163 to i64
  %165 = getelementptr inbounds [20002 x %"class.std::vector"], ptr @V, i64 0, i64 %164
  %166 = call ptr @_ZNSt6vectorIiSaIiEE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %165) #6
  %167 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %23, i32 0, i32 0
  store ptr %166, ptr %167, align 8
  br label %168

168:                                              ; preds = %184, %162
  call void @llvm.lifetime.start.p0(i64 8, ptr %24) #6
  %169 = load i32, ptr %4, align 4, !tbaa !5
  %170 = sext i32 %169 to i64
  %171 = getelementptr inbounds [20002 x %"class.std::vector"], ptr @V, i64 0, i64 %170
  %172 = call ptr @_ZNSt6vectorIiSaIiEE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %171) #6
  %173 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %24, i32 0, i32 0
  store ptr %172, ptr %173, align 8
  %174 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPiSt6vectorIiSaIiEEEEbRKNS_17__normal_iteratorIT_T0_EESA_(ptr noundef nonnull align 8 dereferenceable(8) %23, ptr noundef nonnull align 8 dereferenceable(8) %24) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %24) #6
  br i1 %174, label %176, label %175

175:                                              ; preds = %168
  store i32 12, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %23) #6
  br label %187

176:                                              ; preds = %168
  call void @llvm.lifetime.start.p0(i64 8, ptr %25) #6
  %177 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %23) #6
  %178 = call i64 @_ZSt9make_pairIRiS0_ESt4pairINSt25__strip_reference_wrapperINSt5decayIT_E4typeEE6__typeENS2_INS3_IT0_E4typeEE6__typeEEOS4_OS9_(ptr noundef nonnull align 4 dereferenceable(4) %4, ptr noundef nonnull align 4 dereferenceable(4) %177)
  store i64 %178, ptr %25, align 4
  %179 = call noundef nonnull align 4 dereferenceable(8) ptr @_ZNSt3mapISt4pairIiiES1_St4lessIS1_ESaIS0_IKS1_S1_EEEixEOS1_(ptr noundef nonnull align 8 dereferenceable(48) @M, ptr noundef nonnull align 4 dereferenceable(8) %25)
  %180 = getelementptr inbounds %"struct.std::pair.5", ptr %179, i32 0, i32 1
  %181 = load i32, ptr %180, align 4, !tbaa !11
  %182 = load i32, ptr %22, align 4, !tbaa !5
  %183 = add nsw i32 %182, %181
  store i32 %183, ptr %22, align 4, !tbaa !5
  call void @llvm.lifetime.end.p0(i64 8, ptr %25) #6
  br label %184

184:                                              ; preds = %176
  %185 = call ptr @_ZN9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEppEi(ptr noundef nonnull align 8 dereferenceable(8) %23, i32 noundef 0) #6
  %186 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %26, i32 0, i32 0
  store ptr %185, ptr %186, align 8
  br label %168, !llvm.loop !17

187:                                              ; preds = %175
  %188 = load i32, ptr %22, align 4, !tbaa !5
  store i32 %188, ptr %3, align 4
  store i32 1, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %22) #6
  br label %189

189:                                              ; preds = %187, %30
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #6
  call void @llvm.lifetime.end.p0(i64 80008, ptr %8) #6
  call void @llvm.lifetime.end.p0(i64 80008, ptr %7) #6
  call void @llvm.lifetime.end.p0(i64 80008, ptr %6) #6
  %190 = load i32, ptr %3, align 4
  ret i32 %190
}

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: write)
declare void @llvm.memset.p0.i64(ptr nocapture writeonly, i8, i64, i1 immarg) #2

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

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

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEdeEv(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) #5

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

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

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { 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 #2 = { nocallback nofree nounwind willreturn memory(argmem: write) }
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 = { nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #6 = { nounwind }

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

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


; 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::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>, std::pair<int, int>>, std::_Select1st<std::pair<const std::pair<int, int>, std::pair<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>, std::pair<int, int>>, std::_Select1st<std::pair<const std::pair<int, int>, std::pair<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 }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.__gnu_cxx::__normal_iterator" = type { ptr }
%"struct.std::pair.5" = type { i32, i32 }

@M = external dso_local global %"class.std::map", align 8
@V = external dso_local global [20002 x %"class.std::vector"], align 16

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

; Function Attrs: mustprogress uwtable
declare dso_local i64 @_ZSt9make_pairIRiS0_ESt4pairINSt25__strip_reference_wrapperINSt5decayIT_E4typeEE6__typeENS2_INS3_IT0_E4typeEE6__typeEEOS4_OS9_(ptr noundef nonnull align 4 dereferenceable(4), ptr noundef nonnull align 4 dereferenceable(4)) local_unnamed_addr #1

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

; Function Attrs: mustprogress uwtable
define dso_local noundef i32 @_Z12edmonds_karpii(i32 noundef %0, i32 noundef %1) local_unnamed_addr #1 {
  %3 = alloca i32, align 4
  %4 = alloca [20002 x i32], align 16
  %5 = alloca [20002 x i32], align 16
  %6 = alloca [20002 x i32], align 16
  %7 = alloca i32, align 4
  %8 = alloca i32, align 4
  %9 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %10 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %11 = alloca %"struct.std::pair.5", align 8
  %12 = alloca i32, align 4
  %13 = alloca %"struct.std::pair.5", align 8
  %14 = alloca %"struct.std::pair.5", align 8
  %15 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %16 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %17 = alloca %"struct.std::pair.5", align 8
  store i32 %0, ptr %3, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 80008, ptr nonnull %4) #5
  call void @llvm.lifetime.start.p0(i64 80008, ptr nonnull %5) #5
  call void @llvm.lifetime.start.p0(i64 80008, ptr nonnull %6) #5
  %18 = icmp eq i32 %1, %0
  br i1 %18, label %121, label %.preheader

.preheader:                                       ; preds = %2
  %19 = sext i32 %1 to i64
  %20 = getelementptr inbounds [20002 x i32], ptr %4, i64 0, i64 %19
  %21 = getelementptr inbounds [20002 x i32], ptr %6, i64 0, i64 %19
  br label %22

22:                                               ; preds = %.preheader, %._crit_edge27
  %23 = phi i32 [ %0, %.preheader ], [ %81, %._crit_edge27 ]
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 16 dereferenceable(80008) %4, i8 -1, i64 80008, i1 false)
  %24 = sext i32 %23 to i64
  %25 = getelementptr inbounds [20002 x i32], ptr %6, i64 0, i64 %24
  store i32 1000000000, ptr %25, align 4, !tbaa !5
  store i32 %23, ptr %5, align 16, !tbaa !5
  br label %26

26:                                               ; preds = %22, %._crit_edge
  %indvars.iv = phi i64 [ 0, %22 ], [ %indvars.iv.next, %._crit_edge ]
  %.01821 = phi i32 [ 1, %22 ], [ %.1.lcssa, %._crit_edge ]
  %27 = load i32, ptr %20, align 4, !tbaa !5
  %28 = icmp slt i32 %27, 0
  br i1 %28, label %29, label %.critedge.thread

29:                                               ; preds = %26
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %7) #5
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %30 = getelementptr inbounds [20002 x i32], ptr %5, i64 0, i64 %indvars.iv
  %31 = load i32, ptr %30, align 4, !tbaa !5
  store i32 %31, ptr %7, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %8) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %9) #5
  %32 = sext i32 %31 to i64
  %33 = getelementptr inbounds [20002 x %"class.std::vector"], ptr @V, i64 0, i64 %32
  %34 = call ptr @_ZNSt6vectorIiSaIiEE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %33) #5
  store ptr %34, ptr %9, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %10) #5
  %35 = load i32, ptr %7, align 4, !tbaa !5
  %36 = sext i32 %35 to i64
  %37 = getelementptr inbounds [20002 x %"class.std::vector"], ptr @V, i64 0, i64 %36
  %38 = call ptr @_ZNSt6vectorIiSaIiEE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %37) #5
  store ptr %38, ptr %10, align 8
  %39 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPiSt6vectorIiSaIiEEEEbRKNS_17__normal_iteratorIT_T0_EESA_(ptr noundef nonnull align 8 dereferenceable(8) %9, ptr noundef nonnull align 8 dereferenceable(8) %10) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %10) #5
  br i1 %39, label %.lr.ph, label %._crit_edge

._crit_edge:                                      ; preds = %73, %29
  %.1.lcssa = phi i32 [ %.01821, %29 ], [ %.2, %73 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %9) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %8) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %7) #5
  %40 = sext i32 %.1.lcssa to i64
  %41 = icmp slt i64 %indvars.iv.next, %40
  br i1 %41, label %26, label %.critedge, !llvm.loop !9

.lr.ph:                                           ; preds = %29, %73
  %.120 = phi i32 [ %.2, %73 ], [ %.01821, %29 ]
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %11) #5
  %42 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %9) #5
  %43 = call i64 @_ZSt9make_pairIRiS0_ESt4pairINSt25__strip_reference_wrapperINSt5decayIT_E4typeEE6__typeENS2_INS3_IT0_E4typeEE6__typeEEOS4_OS9_(ptr noundef nonnull align 4 dereferenceable(4) %7, ptr noundef nonnull align 4 dereferenceable(4) %42)
  store i64 %43, ptr %11, align 8
  %44 = call noundef nonnull align 4 dereferenceable(8) ptr @_ZNSt3mapISt4pairIiiES1_St4lessIS1_ESaIS0_IKS1_S1_EEEixEOS1_(ptr noundef nonnull align 8 dereferenceable(48) @M, ptr noundef nonnull align 4 dereferenceable(8) %11)
  %.sroa.03.0.copyload = load i32, ptr %44, align 4
  %.sroa.4.0..sroa_idx = getelementptr inbounds i8, ptr %44, i64 4
  %.sroa.4.0.copyload = load i32, ptr %.sroa.4.0..sroa_idx, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %11) #5
  %45 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %9) #5
  %46 = load i32, ptr %45, align 4, !tbaa !5
  %47 = sext i32 %46 to i64
  %48 = getelementptr inbounds [20002 x i32], ptr %4, i64 0, i64 %47
  %49 = load i32, ptr %48, align 4, !tbaa !5
  %50 = icmp slt i32 %49, 0
  br i1 %50, label %51, label %73

51:                                               ; preds = %.lr.ph
  %52 = sub nsw i32 %.sroa.03.0.copyload, %.sroa.4.0.copyload
  store i32 %52, ptr %8, align 4, !tbaa !5
  %.not19 = icmp eq i32 %.sroa.03.0.copyload, %.sroa.4.0.copyload
  br i1 %.not19, label %73, label %53

53:                                               ; preds = %51
  %54 = load i32, ptr %7, align 4, !tbaa !5
  %55 = sext i32 %54 to i64
  %56 = getelementptr inbounds [20002 x i32], ptr %6, i64 0, i64 %55
  %57 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3minIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %56, ptr noundef nonnull align 4 dereferenceable(4) %8)
  %58 = load i32, ptr %57, align 4, !tbaa !5
  %59 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %9) #5
  %60 = load i32, ptr %59, align 4, !tbaa !5
  %61 = sext i32 %60 to i64
  %62 = getelementptr inbounds [20002 x i32], ptr %6, i64 0, i64 %61
  store i32 %58, ptr %62, align 4, !tbaa !5
  %63 = load i32, ptr %7, align 4, !tbaa !5
  %64 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %9) #5
  %65 = load i32, ptr %64, align 4, !tbaa !5
  %66 = sext i32 %65 to i64
  %67 = getelementptr inbounds [20002 x i32], ptr %4, i64 0, i64 %66
  store i32 %63, ptr %67, align 4, !tbaa !5
  %68 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %9) #5
  %69 = load i32, ptr %68, align 4, !tbaa !5
  %70 = add nsw i32 %.120, 1
  %71 = sext i32 %.120 to i64
  %72 = getelementptr inbounds [20002 x i32], ptr %5, i64 0, i64 %71
  store i32 %69, ptr %72, align 4, !tbaa !5
  br label %73

73:                                               ; preds = %53, %51, %.lr.ph
  %.2 = phi i32 [ %70, %53 ], [ %.120, %51 ], [ %.120, %.lr.ph ]
  %74 = call ptr @_ZN9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEppEi(ptr noundef nonnull align 8 dereferenceable(8) %9, i32 noundef 0) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %10) #5
  %75 = load i32, ptr %7, align 4, !tbaa !5
  %76 = sext i32 %75 to i64
  %77 = getelementptr inbounds [20002 x %"class.std::vector"], ptr @V, i64 0, i64 %76
  %78 = call ptr @_ZNSt6vectorIiSaIiEE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %77) #5
  store ptr %78, ptr %10, align 8
  %79 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPiSt6vectorIiSaIiEEEEbRKNS_17__normal_iteratorIT_T0_EESA_(ptr noundef nonnull align 8 dereferenceable(8) %9, ptr noundef nonnull align 8 dereferenceable(8) %10) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %10) #5
  br i1 %79, label %.lr.ph, label %._crit_edge, !llvm.loop !11

.critedge:                                        ; preds = %._crit_edge
  %.pre = load i32, ptr %20, align 4, !tbaa !5
  %80 = icmp slt i32 %.pre, 0
  br i1 %80, label %103, label %.critedge.thread

.critedge.thread:                                 ; preds = %26, %.critedge
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %12) #5
  store i32 %1, ptr %12, align 4, !tbaa !5
  %.not23 = icmp eq i32 %23, %1
  br i1 %.not23, label %._crit_edge27, label %.lr.ph26

._crit_edge27:                                    ; preds = %.lr.ph26, %.critedge.thread
  %81 = phi i32 [ %1, %.critedge.thread ], [ %0, %.lr.ph26 ]
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %12) #5
  br label %22, !llvm.loop !12

.lr.ph26:                                         ; preds = %.critedge.thread, %.lr.ph26
  %storemerge24 = phi i32 [ %102, %.lr.ph26 ], [ %1, %.critedge.thread ]
  %82 = load i32, ptr %21, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %13) #5
  %83 = sext i32 %storemerge24 to i64
  %84 = getelementptr inbounds [20002 x i32], ptr %4, i64 0, i64 %83
  %85 = call i64 @_ZSt9make_pairIRiS0_ESt4pairINSt25__strip_reference_wrapperINSt5decayIT_E4typeEE6__typeENS2_INS3_IT0_E4typeEE6__typeEEOS4_OS9_(ptr noundef nonnull align 4 dereferenceable(4) %84, ptr noundef nonnull align 4 dereferenceable(4) %12)
  store i64 %85, ptr %13, align 8
  %86 = call noundef nonnull align 4 dereferenceable(8) ptr @_ZNSt3mapISt4pairIiiES1_St4lessIS1_ESaIS0_IKS1_S1_EEEixEOS1_(ptr noundef nonnull align 8 dereferenceable(48) @M, ptr noundef nonnull align 4 dereferenceable(8) %13)
  %87 = getelementptr inbounds i8, ptr %86, i64 4
  %88 = load i32, ptr %87, align 4, !tbaa !13
  %89 = add nsw i32 %88, %82
  store i32 %89, ptr %87, align 4, !tbaa !13
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %13) #5
  %90 = load i32, ptr %21, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %14) #5
  %91 = load i32, ptr %12, align 4, !tbaa !5
  %92 = sext i32 %91 to i64
  %93 = getelementptr inbounds [20002 x i32], ptr %4, i64 0, i64 %92
  %94 = call i64 @_ZSt9make_pairIRiS0_ESt4pairINSt25__strip_reference_wrapperINSt5decayIT_E4typeEE6__typeENS2_INS3_IT0_E4typeEE6__typeEEOS4_OS9_(ptr noundef nonnull align 4 dereferenceable(4) %12, ptr noundef nonnull align 4 dereferenceable(4) %93)
  store i64 %94, ptr %14, align 8
  %95 = call noundef nonnull align 4 dereferenceable(8) ptr @_ZNSt3mapISt4pairIiiES1_St4lessIS1_ESaIS0_IKS1_S1_EEEixEOS1_(ptr noundef nonnull align 8 dereferenceable(48) @M, ptr noundef nonnull align 4 dereferenceable(8) %14)
  %96 = getelementptr inbounds i8, ptr %95, i64 4
  %97 = load i32, ptr %96, align 4, !tbaa !13
  %98 = sub nsw i32 %97, %90
  store i32 %98, ptr %96, align 4, !tbaa !13
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %14) #5
  %99 = load i32, ptr %12, align 4, !tbaa !5
  %100 = sext i32 %99 to i64
  %101 = getelementptr inbounds [20002 x i32], ptr %4, i64 0, i64 %100
  %102 = load i32, ptr %101, align 4, !tbaa !5
  store i32 %102, ptr %12, align 4, !tbaa !5
  %.not = icmp eq i32 %102, %0
  br i1 %.not, label %._crit_edge27, label %.lr.ph26, !llvm.loop !15

103:                                              ; preds = %.critedge
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %15) #5
  %104 = sext i32 %0 to i64
  %105 = getelementptr inbounds [20002 x %"class.std::vector"], ptr @V, i64 0, i64 %104
  %106 = call ptr @_ZNSt6vectorIiSaIiEE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %105) #5
  store ptr %106, ptr %15, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %16) #5
  %107 = call ptr @_ZNSt6vectorIiSaIiEE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %105) #5
  store ptr %107, ptr %16, align 8
  %108 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPiSt6vectorIiSaIiEEEEbRKNS_17__normal_iteratorIT_T0_EESA_(ptr noundef nonnull align 8 dereferenceable(8) %15, ptr noundef nonnull align 8 dereferenceable(8) %16) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %16) #5
  br i1 %108, label %.lr.ph30, label %._crit_edge31

._crit_edge31:                                    ; preds = %.lr.ph30, %103
  %.016.lcssa = phi i32 [ 0, %103 ], [ %114, %.lr.ph30 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %15) #5
  br label %121

.lr.ph30:                                         ; preds = %103, %.lr.ph30
  %.01628 = phi i32 [ %114, %.lr.ph30 ], [ 0, %103 ]
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %17) #5
  %109 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %15) #5
  %110 = call i64 @_ZSt9make_pairIRiS0_ESt4pairINSt25__strip_reference_wrapperINSt5decayIT_E4typeEE6__typeENS2_INS3_IT0_E4typeEE6__typeEEOS4_OS9_(ptr noundef nonnull align 4 dereferenceable(4) %3, ptr noundef nonnull align 4 dereferenceable(4) %109)
  store i64 %110, ptr %17, align 8
  %111 = call noundef nonnull align 4 dereferenceable(8) ptr @_ZNSt3mapISt4pairIiiES1_St4lessIS1_ESaIS0_IKS1_S1_EEEixEOS1_(ptr noundef nonnull align 8 dereferenceable(48) @M, ptr noundef nonnull align 4 dereferenceable(8) %17)
  %112 = getelementptr inbounds i8, ptr %111, i64 4
  %113 = load i32, ptr %112, align 4, !tbaa !13
  %114 = add nsw i32 %113, %.01628
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %17) #5
  %115 = call ptr @_ZN9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEppEi(ptr noundef nonnull align 8 dereferenceable(8) %15, i32 noundef 0) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %16) #5
  %116 = load i32, ptr %3, align 4, !tbaa !5
  %117 = sext i32 %116 to i64
  %118 = getelementptr inbounds [20002 x %"class.std::vector"], ptr @V, i64 0, i64 %117
  %119 = call ptr @_ZNSt6vectorIiSaIiEE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %118) #5
  store ptr %119, ptr %16, align 8
  %120 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPiSt6vectorIiSaIiEEEEbRKNS_17__normal_iteratorIT_T0_EESA_(ptr noundef nonnull align 8 dereferenceable(8) %15, ptr noundef nonnull align 8 dereferenceable(8) %16) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %16) #5
  br i1 %120, label %.lr.ph30, label %._crit_edge31, !llvm.loop !16

121:                                              ; preds = %2, %._crit_edge31
  %.0 = phi i32 [ %.016.lcssa, %._crit_edge31 ], [ 1000000000, %2 ]
  call void @llvm.lifetime.end.p0(i64 80008, ptr nonnull %6) #5
  call void @llvm.lifetime.end.p0(i64 80008, ptr nonnull %5) #5
  call void @llvm.lifetime.end.p0(i64 80008, ptr nonnull %4) #5
  ret i32 %.0
}

; Function Attrs: mustprogress nocallback nofree nounwind willreturn memory(argmem: write)
declare void @llvm.memset.p0.i64(ptr nocapture writeonly, i8, i64, i1 immarg) #2

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEdeEv(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 4 dereferenceable(4) ptr @_ZSt3minIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4), ptr noundef nonnull align 4 dereferenceable(4)) local_unnamed_addr #4

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

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { 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 #2 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: write) }
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 = { nounwind }

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

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


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