; LLVM IR from CRAFT-THU/BSim :: src/net/SplitNetwork.ll (ZN12MultiNetwork12splitNetworkEv)

; 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<NeuronBase *, std::pair<NeuronBase *const, std::vector<SynapseBase *>>, std::_Select1st<std::pair<NeuronBase *const, std::vector<SynapseBase *>>>, std::less<NeuronBase *>>::_Rb_tree_impl" }
%"struct.std::_Rb_tree<NeuronBase *, std::pair<NeuronBase *const, std::vector<SynapseBase *>>, std::_Select1st<std::pair<NeuronBase *const, std::vector<SynapseBase *>>>, std::less<NeuronBase *>>::_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.__gnu_cxx::__normal_iterator" = type { ptr }
%"class.__gnu_cxx::__normal_iterator.38" = type { ptr }
%"struct.std::_Rb_tree_iterator" = type { ptr }
%"class.__gnu_cxx::__normal_iterator.39" = type { ptr }
%"struct.std::pair.44" = type <{ %"struct.std::_Rb_tree_const_iterator", i8, [7 x i8] }>
%"struct.std::_Rb_tree_const_iterator" = type { ptr }
%class.MultiNetwork = type <{ %"class.std::vector", %"class.std::vector", %"class.std::vector.0", %"class.std::vector.5", %"class.std::vector.5", ptr, i32, [4 x i8] }>
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<std::set<NeuronBase *>, std::allocator<std::set<NeuronBase *>>>::_Vector_impl" }
%"struct.std::_Vector_base<std::set<NeuronBase *>, std::allocator<std::set<NeuronBase *>>>::_Vector_impl" = type { %"struct.std::_Vector_base<std::set<NeuronBase *>, std::allocator<std::set<NeuronBase *>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<std::set<NeuronBase *>, std::allocator<std::set<NeuronBase *>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::vector.0" = type { %"struct.std::_Vector_base.1" }
%"struct.std::_Vector_base.1" = type { %"struct.std::_Vector_base<std::map<NeuronBase *, int>, std::allocator<std::map<NeuronBase *, int>>>::_Vector_impl" }
%"struct.std::_Vector_base<std::map<NeuronBase *, int>, std::allocator<std::map<NeuronBase *, int>>>::_Vector_impl" = type { %"struct.std::_Vector_base<std::map<NeuronBase *, int>, std::allocator<std::map<NeuronBase *, int>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<std::map<NeuronBase *, int>, std::allocator<std::map<NeuronBase *, int>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::vector.5" = type { %"struct.std::_Vector_base.6" }
%"struct.std::_Vector_base.6" = type { %"struct.std::_Vector_base<std::map<Type, int>, std::allocator<std::map<Type, int>>>::_Vector_impl" }
%"struct.std::_Vector_base<std::map<Type, int>, std::allocator<std::map<Type, int>>>::_Vector_impl" = type { %"struct.std::_Vector_base<std::map<Type, int>, std::allocator<std::map<Type, int>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<std::map<Type, int>, std::allocator<std::map<Type, int>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%class.Network = type { %"class.std::vector.10", %"class.std::vector.15", %"class.std::vector.20", i32, i32, i32, float, float, %"class.std::vector.25", %"class.std::vector.25", i32, %"class.std::vector.30", %"class.std::vector.30", %"class.std::vector.30" }
%"class.std::vector.10" = type { %"struct.std::_Vector_base.11" }
%"struct.std::_Vector_base.11" = type { %"struct.std::_Vector_base<NeuronBase *, std::allocator<NeuronBase *>>::_Vector_impl" }
%"struct.std::_Vector_base<NeuronBase *, std::allocator<NeuronBase *>>::_Vector_impl" = type { %"struct.std::_Vector_base<NeuronBase *, std::allocator<NeuronBase *>>::_Vector_impl_data" }
%"struct.std::_Vector_base<NeuronBase *, std::allocator<NeuronBase *>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::vector.15" = type { %"struct.std::_Vector_base.16" }
%"struct.std::_Vector_base.16" = type { %"struct.std::_Vector_base<PopulationBase *, std::allocator<PopulationBase *>>::_Vector_impl" }
%"struct.std::_Vector_base<PopulationBase *, std::allocator<PopulationBase *>>::_Vector_impl" = type { %"struct.std::_Vector_base<PopulationBase *, std::allocator<PopulationBase *>>::_Vector_impl_data" }
%"struct.std::_Vector_base<PopulationBase *, std::allocator<PopulationBase *>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::vector.20" = type { %"struct.std::_Vector_base.21" }
%"struct.std::_Vector_base.21" = type { %"struct.std::_Vector_base<SynapseBase *, std::allocator<SynapseBase *>>::_Vector_impl" }
%"struct.std::_Vector_base<SynapseBase *, std::allocator<SynapseBase *>>::_Vector_impl" = type { %"struct.std::_Vector_base<SynapseBase *, std::allocator<SynapseBase *>>::_Vector_impl_data" }
%"struct.std::_Vector_base<SynapseBase *, std::allocator<SynapseBase *>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::vector.25" = type { %"struct.std::_Vector_base.26" }
%"struct.std::_Vector_base.26" = type { %"struct.std::_Vector_base<Type, std::allocator<Type>>::_Vector_impl" }
%"struct.std::_Vector_base<Type, std::allocator<Type>>::_Vector_impl" = type { %"struct.std::_Vector_base<Type, std::allocator<Type>>::_Vector_impl_data" }
%"struct.std::_Vector_base<Type, std::allocator<Type>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::vector.30" = type { %"struct.std::_Vector_base.31" }
%"struct.std::_Vector_base.31" = 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 }
%"struct.std::pair" = type { ptr, %"class.std::vector.20" }

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN12MultiNetwork12splitNetworkEv(ptr noundef nonnull align 8 dereferenceable(132) %0) #0 align 2 personality ptr @__gxx_personality_v0 {
  %2 = alloca ptr, align 8
  %3 = alloca i32, align 4
  %4 = alloca i32, align 4
  %5 = alloca i32, align 4
  %6 = alloca %"class.std::map", align 8
  %7 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %8 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %9 = alloca ptr, align 8
  %10 = alloca ptr, align 8
  %11 = alloca ptr, align 8
  %12 = alloca i32, align 4
  %13 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %14 = alloca %"class.__gnu_cxx::__normal_iterator.38", align 8
  %15 = alloca %"class.__gnu_cxx::__normal_iterator.38", align 8
  %16 = alloca i32, align 4
  %17 = alloca ptr, align 8
  %18 = alloca i32, align 4
  %19 = alloca %"struct.std::_Rb_tree_iterator", align 8
  %20 = alloca ptr, align 8
  %21 = alloca %"struct.std::_Rb_tree_iterator", align 8
  %22 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %23 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %24 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %25 = alloca %"class.__gnu_cxx::__normal_iterator.38", align 8
  %26 = alloca %"class.__gnu_cxx::__normal_iterator.38", align 8
  %27 = alloca %"class.__gnu_cxx::__normal_iterator.38", align 8
  %28 = alloca ptr, align 8
  %29 = alloca i32, align 4
  %30 = alloca i8, align 1
  %31 = alloca ptr, align 8
  %32 = alloca i32, align 4
  %33 = alloca ptr, align 8
  %34 = alloca %"class.__gnu_cxx::__normal_iterator.39", align 8
  %35 = alloca %"class.__gnu_cxx::__normal_iterator.39", align 8
  %36 = alloca i32, align 4
  %37 = alloca %"struct.std::pair.44", align 8
  %38 = alloca %"class.__gnu_cxx::__normal_iterator.39", align 8
  %39 = alloca %"struct.std::pair.44", align 8
  %40 = alloca %"class.__gnu_cxx::__normal_iterator.38", align 8
  store ptr %0, ptr %2, align 8, !tbaa !5
  %41 = load ptr, ptr %2, align 8
  call void @llvm.lifetime.start.p0(i64 4, ptr %3) #5
  store i32 0, ptr %3, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %4) #5
  store i32 0, ptr %4, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %5) #5
  %42 = getelementptr inbounds %class.MultiNetwork, ptr %41, i32 0, i32 5
  %43 = load ptr, ptr %42, align 8, !tbaa !11
  %44 = getelementptr inbounds %class.Network, ptr %43, i32 0, i32 5
  %45 = load i32, ptr %44, align 8, !tbaa !25
  %46 = getelementptr inbounds %class.MultiNetwork, ptr %41, i32 0, i32 6
  %47 = load i32, ptr %46, align 8, !tbaa !48
  %48 = sdiv i32 %45, %47
  store i32 %48, ptr %5, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 48, ptr %6) #5
  call void @_ZNSt3mapIP10NeuronBaseSt6vectorIP11SynapseBaseSaIS4_EESt4lessIS1_ESaISt4pairIKS1_S6_EEEC2Ev(ptr noundef nonnull align 8 dereferenceable(48) %6) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %7) #5
  %49 = getelementptr inbounds %class.MultiNetwork, ptr %41, i32 0, i32 5
  %50 = load ptr, ptr %49, align 8, !tbaa !11
  %51 = getelementptr inbounds %class.Network, ptr %50, i32 0, i32 2
  %52 = call ptr @_ZNSt6vectorIP11SynapseBaseSaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %51) #5
  %53 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %7, i32 0, i32 0
  store ptr %52, ptr %53, align 8
  br label %54

54:                                               ; preds = %71, %1
  call void @llvm.lifetime.start.p0(i64 8, ptr %8) #5
  %55 = getelementptr inbounds %class.MultiNetwork, ptr %41, i32 0, i32 5
  %56 = load ptr, ptr %55, align 8, !tbaa !11
  %57 = getelementptr inbounds %class.Network, ptr %56, i32 0, i32 2
  %58 = call ptr @_ZNSt6vectorIP11SynapseBaseSaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %57) #5
  %59 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %8, i32 0, i32 0
  store ptr %58, ptr %59, align 8
  %60 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPP11SynapseBaseSt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8) %7, ptr noundef nonnull align 8 dereferenceable(8) %8) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #5
  br i1 %60, label %62, label %61

61:                                               ; preds = %54
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #5
  br label %78

62:                                               ; preds = %54
  call void @llvm.lifetime.start.p0(i64 8, ptr %9) #5
  %63 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPP11SynapseBaseSt6vectorIS2_SaIS2_EEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %7) #5
  %64 = load ptr, ptr %63, align 8, !tbaa !5
  store ptr %64, ptr %9, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #5
  %65 = load ptr, ptr %9, align 8, !tbaa !5
  %66 = invoke noundef ptr @_ZN11SynapseBase6getDstEv(ptr noundef nonnull align 8 dereferenceable(33) %65)
          to label %67 unwind label %74

67:                                               ; preds = %62
  store ptr %66, ptr %10, align 8, !tbaa !5
  %68 = invoke noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt3mapIP10NeuronBaseSt6vectorIP11SynapseBaseSaIS4_EESt4lessIS1_ESaISt4pairIKS1_S6_EEEixEOS1_(ptr noundef nonnull align 8 dereferenceable(48) %6, ptr noundef nonnull align 8 dereferenceable(8) %10)
          to label %69 unwind label %74

69:                                               ; preds = %67
  invoke void @_ZNSt6vectorIP11SynapseBaseSaIS1_EE9push_backERKS1_(ptr noundef nonnull align 8 dereferenceable(24) %68, ptr noundef nonnull align 8 dereferenceable(8) %9)
          to label %70 unwind label %74

70:                                               ; preds = %69
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #5
  br label %71

71:                                               ; preds = %70
  %72 = call ptr @_ZN9__gnu_cxx17__normal_iteratorIPP11SynapseBaseSt6vectorIS2_SaIS2_EEEppEi(ptr noundef nonnull align 8 dereferenceable(8) %7, i32 noundef 0) #5
  %73 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %13, i32 0, i32 0
  store ptr %72, ptr %73, align 8
  br label %54, !llvm.loop !49

74:                                               ; preds = %69, %67, %62
  %75 = landingpad { ptr, i32 }
          cleanup
  %76 = extractvalue { ptr, i32 } %75, 0
  store ptr %76, ptr %11, align 8
  %77 = extractvalue { ptr, i32 } %75, 1
  store i32 %77, ptr %12, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #5
  br label %334

78:                                               ; preds = %61
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #5
  %79 = getelementptr inbounds %class.MultiNetwork, ptr %41, i32 0, i32 5
  %80 = load ptr, ptr %79, align 8, !tbaa !11
  %81 = getelementptr inbounds %class.Network, ptr %80, i32 0, i32 1
  %82 = call ptr @_ZNSt6vectorIP14PopulationBaseSaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %81) #5
  %83 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator.38", ptr %14, i32 0, i32 0
  store ptr %82, ptr %83, align 8
  br label %84

84:                                               ; preds = %198, %78
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #5
  %85 = getelementptr inbounds %class.MultiNetwork, ptr %41, i32 0, i32 5
  %86 = load ptr, ptr %85, align 8, !tbaa !11
  %87 = getelementptr inbounds %class.Network, ptr %86, i32 0, i32 1
  %88 = call ptr @_ZNSt6vectorIP14PopulationBaseSaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %87) #5
  %89 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator.38", ptr %15, i32 0, i32 0
  store ptr %88, ptr %89, align 8
  %90 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPP14PopulationBaseSt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8) %14, ptr noundef nonnull align 8 dereferenceable(8) %15) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #5
  br i1 %90, label %92, label %91

91:                                               ; preds = %84
  store i32 5, ptr %16, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #5
  br label %202

92:                                               ; preds = %84
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #5
  %93 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPP14PopulationBaseSt6vectorIS2_SaIS2_EEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %14) #5
  %94 = load ptr, ptr %93, align 8, !tbaa !5
  store ptr %94, ptr %17, align 8, !tbaa !5
  %95 = load ptr, ptr %17, align 8, !tbaa !5
  %96 = load i32, ptr %3, align 4, !tbaa !9
  invoke void @_ZN4Base7setNodeEi(ptr noundef nonnull align 8 dereferenceable(16) %95, i32 noundef %96)
          to label %97 unwind label %108

97:                                               ; preds = %92
  call void @llvm.lifetime.start.p0(i64 4, ptr %18) #5
  store i32 0, ptr %18, align 4, !tbaa !9
  br label %98

98:                                               ; preds = %176, %97
  %99 = load i32, ptr %18, align 4, !tbaa !9
  %100 = load ptr, ptr %17, align 8, !tbaa !5
  %101 = load ptr, ptr %100, align 8, !tbaa !51
  %102 = getelementptr inbounds ptr, ptr %101, i64 10
  %103 = load ptr, ptr %102, align 8
  %104 = invoke noundef i32 %103(ptr noundef nonnull align 8 dereferenceable(17) %100)
          to label %105 unwind label %112

105:                                              ; preds = %98
  %106 = icmp slt i32 %99, %104
  br i1 %106, label %116, label %107

107:                                              ; preds = %105
  store i32 8, ptr %16, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %18) #5
  br label %181

108:                                              ; preds = %92
  %109 = landingpad { ptr, i32 }
          cleanup
  %110 = extractvalue { ptr, i32 } %109, 0
  store ptr %110, ptr %11, align 8
  %111 = extractvalue { ptr, i32 } %109, 1
  store i32 %111, ptr %12, align 4
  br label %201

112:                                              ; preds = %123, %116, %98
  %113 = landingpad { ptr, i32 }
          cleanup
  %114 = extractvalue { ptr, i32 } %113, 0
  store ptr %114, ptr %11, align 8
  %115 = extractvalue { ptr, i32 } %113, 1
  store i32 %115, ptr %12, align 4
  br label %180

116:                                              ; preds = %105
  %117 = load ptr, ptr %17, align 8, !tbaa !5
  %118 = load i32, ptr %18, align 4, !tbaa !9
  %119 = load ptr, ptr %117, align 8, !tbaa !51
  %120 = getelementptr inbounds ptr, ptr %119, i64 12
  %121 = load ptr, ptr %120, align 8
  %122 = invoke noundef ptr %121(ptr noundef nonnull align 8 dereferenceable(17) %117, i32 noundef %118)
          to label %123 unwind label %112

123:                                              ; preds = %116
  %124 = load i32, ptr %3, align 4, !tbaa !9
  invoke void @_ZN4Base7setNodeEi(ptr noundef nonnull align 8 dereferenceable(16) %122, i32 noundef %124)
          to label %125 unwind label %112

125:                                              ; preds = %123
  call void @llvm.lifetime.start.p0(i64 8, ptr %19) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %20) #5
  %126 = load ptr, ptr %17, align 8, !tbaa !5
  %127 = load i32, ptr %18, align 4, !tbaa !9
  %128 = load ptr, ptr %126, align 8, !tbaa !51
  %129 = getelementptr inbounds ptr, ptr %128, i64 12
  %130 = load ptr, ptr %129, align 8
  %131 = invoke noundef ptr %130(ptr noundef nonnull align 8 dereferenceable(17) %126, i32 noundef %127)
          to label %132 unwind label %158

132:                                              ; preds = %125
  store ptr %131, ptr %20, align 8, !tbaa !5
  %133 = invoke ptr @_ZNSt3mapIP10NeuronBaseSt6vectorIP11SynapseBaseSaIS4_EESt4lessIS1_ESaISt4pairIKS1_S6_EEE4findERSA_(ptr noundef nonnull align 8 dereferenceable(48) %6, ptr noundef nonnull align 8 dereferenceable(8) %20)
          to label %134 unwind label %158

134:                                              ; preds = %132
  %135 = getelementptr inbounds %"struct.std::_Rb_tree_iterator", ptr %19, i32 0, i32 0
  store ptr %133, ptr %135, align 8
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %21) #5
  %136 = call ptr @_ZNSt3mapIP10NeuronBaseSt6vectorIP11SynapseBaseSaIS4_EESt4lessIS1_ESaISt4pairIKS1_S6_EEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %6) #5
  %137 = getelementptr inbounds %"struct.std::_Rb_tree_iterator", ptr %21, i32 0, i32 0
  store ptr %136, ptr %137, align 8
  %138 = call noundef zeroext i1 @_ZStneRKSt17_Rb_tree_iteratorISt4pairIKP10NeuronBaseSt6vectorIP11SynapseBaseSaIS6_EEEESC_(ptr noundef nonnull align 8 dereferenceable(8) %19, ptr noundef nonnull align 8 dereferenceable(8) %21) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #5
  br i1 %138, label %139, label %175

139:                                              ; preds = %134
  %140 = call noundef ptr @_ZNKSt17_Rb_tree_iteratorISt4pairIKP10NeuronBaseSt6vectorIP11SynapseBaseSaIS6_EEEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %19) #5
  %141 = getelementptr inbounds %"struct.std::pair", ptr %140, i32 0, i32 1
  %142 = call noundef i64 @_ZNKSt6vectorIP11SynapseBaseSaIS1_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %141) #5
  %143 = load i32, ptr %4, align 4, !tbaa !9
  %144 = sext i32 %143 to i64
  %145 = add i64 %144, %142
  %146 = trunc i64 %145 to i32
  store i32 %146, ptr %4, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %22) #5
  %147 = call noundef ptr @_ZNKSt17_Rb_tree_iteratorISt4pairIKP10NeuronBaseSt6vectorIP11SynapseBaseSaIS6_EEEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %19) #5
  %148 = getelementptr inbounds %"struct.std::pair", ptr %147, i32 0, i32 1
  %149 = call ptr @_ZNSt6vectorIP11SynapseBaseSaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %148) #5
  %150 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %22, i32 0, i32 0
  store ptr %149, ptr %150, align 8
  br label %151

151:                                              ; preds = %167, %139
  call void @llvm.lifetime.start.p0(i64 8, ptr %23) #5
  %152 = call noundef ptr @_ZNKSt17_Rb_tree_iteratorISt4pairIKP10NeuronBaseSt6vectorIP11SynapseBaseSaIS6_EEEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %19) #5
  %153 = getelementptr inbounds %"struct.std::pair", ptr %152, i32 0, i32 1
  %154 = call ptr @_ZNSt6vectorIP11SynapseBaseSaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %153) #5
  %155 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %23, i32 0, i32 0
  store ptr %154, ptr %155, align 8
  %156 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPP11SynapseBaseSt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8) %22, ptr noundef nonnull align 8 dereferenceable(8) %23) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %23) #5
  br i1 %156, label %162, label %157

157:                                              ; preds = %151
  store i32 11, ptr %16, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #5
  br label %174

158:                                              ; preds = %132, %125
  %159 = landingpad { ptr, i32 }
          cleanup
  %160 = extractvalue { ptr, i32 } %159, 0
  store ptr %160, ptr %11, align 8
  %161 = extractvalue { ptr, i32 } %159, 1
  store i32 %161, ptr %12, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #5
  br label %179

162:                                              ; preds = %151
  %163 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPP11SynapseBaseSt6vectorIS2_SaIS2_EEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %22) #5
  %164 = load ptr, ptr %163, align 8, !tbaa !5
  %165 = load i32, ptr %3, align 4, !tbaa !9
  invoke void @_ZN4Base7setNodeEi(ptr noundef nonnull align 8 dereferenceable(16) %164, i32 noundef %165)
          to label %166 unwind label %170

166:                                              ; preds = %162
  br label %167

167:                                              ; preds = %166
  %168 = call ptr @_ZN9__gnu_cxx17__normal_iteratorIPP11SynapseBaseSt6vectorIS2_SaIS2_EEEppEi(ptr noundef nonnull align 8 dereferenceable(8) %22, i32 noundef 0) #5
  %169 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %24, i32 0, i32 0
  store ptr %168, ptr %169, align 8
  br label %151, !llvm.loop !53

170:                                              ; preds = %162
  %171 = landingpad { ptr, i32 }
          cleanup
  %172 = extractvalue { ptr, i32 } %171, 0
  store ptr %172, ptr %11, align 8
  %173 = extractvalue { ptr, i32 } %171, 1
  store i32 %173, ptr %12, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #5
  br label %179

174:                                              ; preds = %157
  br label %175

175:                                              ; preds = %174, %134
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #5
  br label %176

176:                                              ; preds = %175
  %177 = load i32, ptr %18, align 4, !tbaa !9
  %178 = add nsw i32 %177, 1
  store i32 %178, ptr %18, align 4, !tbaa !9
  br label %98, !llvm.loop !54

179:                                              ; preds = %170, %158
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #5
  br label %180

180:                                              ; preds = %179, %112
  call void @llvm.lifetime.end.p0(i64 4, ptr %18) #5
  br label %201

181:                                              ; preds = %107
  %182 = load i32, ptr %4, align 4, !tbaa !9
  %183 = load i32, ptr %3, align 4, !tbaa !9
  %184 = add nsw i32 %183, 1
  %185 = load i32, ptr %5, align 4, !tbaa !9
  %186 = mul nsw i32 %184, %185
  %187 = icmp sge i32 %182, %186
  br i1 %187, label %188, label %197

188:                                              ; preds = %181
  %189 = load i32, ptr %3, align 4, !tbaa !9
  %190 = getelementptr inbounds %class.MultiNetwork, ptr %41, i32 0, i32 6
  %191 = load i32, ptr %190, align 8, !tbaa !48
  %192 = sub nsw i32 %191, 1
  %193 = icmp slt i32 %189, %192
  br i1 %193, label %194, label %197

194:                                              ; preds = %188
  %195 = load i32, ptr %3, align 4, !tbaa !9
  %196 = add nsw i32 %195, 1
  store i32 %196, ptr %3, align 4, !tbaa !9
  br label %197

197:                                              ; preds = %194, %188, %181
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #5
  br label %198

198:                                              ; preds = %197
  %199 = call ptr @_ZN9__gnu_cxx17__normal_iteratorIPP14PopulationBaseSt6vectorIS2_SaIS2_EEEppEi(ptr noundef nonnull align 8 dereferenceable(8) %14, i32 noundef 0) #5
  %200 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator.38", ptr %25, i32 0, i32 0
  store ptr %199, ptr %200, align 8
  br label %84, !llvm.loop !55

201:                                              ; preds = %180, %108
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #5
  br label %334

202:                                              ; preds = %91
  call void @_ZNSt3mapIP10NeuronBaseSt6vectorIP11SynapseBaseSaIS4_EESt4lessIS1_ESaISt4pairIKS1_S6_EEE5clearEv(ptr noundef nonnull align 8 dereferenceable(48) %6) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %26) #5
  %203 = getelementptr inbounds %class.MultiNetwork, ptr %41, i32 0, i32 5
  %204 = load ptr, ptr %203, align 8, !tbaa !11
  %205 = getelementptr inbounds %class.Network, ptr %204, i32 0, i32 1
  %206 = call ptr @_ZNSt6vectorIP14PopulationBaseSaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %205) #5
  %207 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator.38", ptr %26, i32 0, i32 0
  store ptr %206, ptr %207, align 8
  br label %208

208:                                              ; preds = %330, %202
  call void @llvm.lifetime.start.p0(i64 8, ptr %27) #5
  %209 = getelementptr inbounds %class.MultiNetwork, ptr %41, i32 0, i32 5
  %210 = load ptr, ptr %209, align 8, !tbaa !11
  %211 = getelementptr inbounds %class.Network, ptr %210, i32 0, i32 1
  %212 = call ptr @_ZNSt6vectorIP14PopulationBaseSaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %211) #5
  %213 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator.38", ptr %27, i32 0, i32 0
  store ptr %212, ptr %213, align 8
  %214 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPP14PopulationBaseSt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8) %26, ptr noundef nonnull align 8 dereferenceable(8) %27) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %27) #5
  br i1 %214, label %216, label %215

215:                                              ; preds = %208
  store i32 14, ptr %16, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %26) #5
  br label %333

216:                                              ; preds = %208
  call void @llvm.lifetime.start.p0(i64 8, ptr %28) #5
  %217 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPP14PopulationBaseSt6vectorIS2_SaIS2_EEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %26) #5
  %218 = load ptr, ptr %217, align 8, !tbaa !5
  store ptr %218, ptr %28, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %29) #5
  store i32 0, ptr %29, align 4, !tbaa !9
  br label %219

219:                                              ; preds = %322, %216
  %220 = load i32, ptr %29, align 4, !tbaa !9
  %221 = load ptr, ptr %28, align 8, !tbaa !5
  %222 = load ptr, ptr %221, align 8, !tbaa !51
  %223 = getelementptr inbounds ptr, ptr %222, i64 10
  %224 = load ptr, ptr %223, align 8
  %225 = invoke noundef i32 %224(ptr noundef nonnull align 8 dereferenceable(17) %221)
          to label %226 unwind label %229

226:                                              ; preds = %219
  %227 = icmp slt i32 %220, %225
  br i1 %227, label %233, label %228

228:                                              ; preds = %226
  store i32 17, ptr %16, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %29) #5
  br label %329

229:                                              ; preds = %219
  %230 = landingpad { ptr, i32 }
          cleanup
  %231 = extractvalue { ptr, i32 } %230, 0
  store ptr %231, ptr %11, align 8
  %232 = extractvalue { ptr, i32 } %230, 1
  store i32 %232, ptr %12, align 4
  br label %328

233:                                              ; preds = %226
  call void @llvm.lifetime.start.p0(i64 1, ptr %30) #5
  store i8 0, ptr %30, align 1, !tbaa !56
  call void @llvm.lifetime.start.p0(i64 8, ptr %31) #5
  %234 = load ptr, ptr %28, align 8, !tbaa !5
  %235 = load i32, ptr %29, align 4, !tbaa !9
  %236 = load ptr, ptr %234, align 8, !tbaa !51
  %237 = getelementptr inbounds ptr, ptr %236, i64 12
  %238 = load ptr, ptr %237, align 8
  %239 = invoke noundef ptr %238(ptr noundef nonnull align 8 dereferenceable(17) %234, i32 noundef %235)
          to label %240 unwind label %268

240:                                              ; preds = %233
  store ptr %239, ptr %31, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %32) #5
  %241 = load ptr, ptr %28, align 8, !tbaa !5
  %242 = load i32, ptr %29, align 4, !tbaa !9
  %243 = load ptr, ptr %241, align 8, !tbaa !51
  %244 = getelementptr inbounds ptr, ptr %243, i64 12
  %245 = load ptr, ptr %244, align 8
  %246 = invoke noundef ptr %245(ptr noundef nonnull align 8 dereferenceable(17) %241, i32 noundef %242)
          to label %247 unwind label %272

247:                                              ; preds = %240
  %248 = invoke noundef i32 @_ZN4Base7getNodeEv(ptr noundef nonnull align 8 dereferenceable(16) %246)
          to label %249 unwind label %272

249:                                              ; preds = %247
  store i32 %248, ptr %32, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %33) #5
  %250 = load ptr, ptr %28, align 8, !tbaa !5
  %251 = load i32, ptr %29, align 4, !tbaa !9
  %252 = load ptr, ptr %250, align 8, !tbaa !51
  %253 = getelementptr inbounds ptr, ptr %252, i64 12
  %254 = load ptr, ptr %253, align 8
  %255 = invoke noundef ptr %254(ptr noundef nonnull align 8 dereferenceable(17) %250, i32 noundef %251)
          to label %256 unwind label %276

256:                                              ; preds = %249
  %257 = invoke noundef nonnull align 8 dereferenceable(24) ptr @_ZNK10NeuronBase11getSynapsesEv(ptr noundef nonnull align 8 dereferenceable(52) %255)
          to label %258 unwind label %276

258:                                              ; preds = %256
  store ptr %257, ptr %33, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %34) #5
  %259 = load ptr, ptr %33, align 8, !tbaa !5
  %260 = call ptr @_ZNKSt6vectorIP11SynapseBaseSaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %259) #5
  %261 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator.39", ptr %34, i32 0, i32 0
  store ptr %260, ptr %261, align 8
  br label %262

262:                                              ; preds = %304, %258
  call void @llvm.lifetime.start.p0(i64 8, ptr %35) #5
  %263 = load ptr, ptr %33, align 8, !tbaa !5
  %264 = call ptr @_ZNKSt6vectorIP11SynapseBaseSaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %263) #5
  %265 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator.39", ptr %35, i32 0, i32 0
  store ptr %264, ptr %265, align 8
  %266 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPKP11SynapseBaseSt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESD_(ptr noundef nonnull align 8 dereferenceable(8) %34, ptr noundef nonnull align 8 dereferenceable(8) %35) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %35) #5
  br i1 %266, label %280, label %267

267:                                              ; preds = %262
  store i32 20, ptr %16, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %34) #5
  br label %307

268:                                              ; preds = %233
  %269 = landingpad { ptr, i32 }
          cleanup
  %270 = extractvalue { ptr, i32 } %269, 0
  store ptr %270, ptr %11, align 8
  %271 = extractvalue { ptr, i32 } %269, 1
  store i32 %271, ptr %12, align 4
  br label %327

272:                                              ; preds = %247, %240
  %273 = landingpad { ptr, i32 }
          cleanup
  %274 = extractvalue { ptr, i32 } %273, 0
  store ptr %274, ptr %11, align 8
  %275 = extractvalue { ptr, i32 } %273, 1
  store i32 %275, ptr %12, align 4
  br label %326

276:                                              ; preds = %310, %256, %249
  %277 = landingpad { ptr, i32 }
          cleanup
  %278 = extractvalue { ptr, i32 } %277, 0
  store ptr %278, ptr %11, align 8
  %279 = extractvalue { ptr, i32 } %277, 1
  store i32 %279, ptr %12, align 4
  br label %325

280:                                              ; preds = %262
  call void @llvm.lifetime.start.p0(i64 4, ptr %36) #5
  %281 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPKP11SynapseBaseSt6vectorIS2_SaIS2_EEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %34) #5
  %282 = load ptr, ptr %281, align 8, !tbaa !5
  %283 = invoke noundef i32 @_ZN4Base7getNodeEv(ptr noundef nonnull align 8 dereferenceable(16) %282)
          to label %284 unwind label %299

284:                                              ; preds = %280
  store i32 %283, ptr %36, align 4, !tbaa !9
  %285 = load i32, ptr %36, align 4, !tbaa !9
  %286 = load i32, ptr %32, align 4, !tbaa !9
  %287 = icmp ne i32 %285, %286
  br i1 %287, label %288, label %303

288:                                              ; preds = %284
  store i8 1, ptr %30, align 1, !tbaa !56
  %289 = getelementptr inbounds %class.MultiNetwork, ptr %41, i32 0, i32 1
  %290 = load i32, ptr %36, align 4, !tbaa !9
  %291 = sext i32 %290 to i64
  %292 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt6vectorISt3setIP10NeuronBaseSt4lessIS2_ESaIS2_EESaIS6_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %289, i64 noundef %291) #5
  %293 = invoke { ptr, i8 } @_ZNSt3setIP10NeuronBaseSt4lessIS1_ESaIS1_EE6insertERKS1_(ptr noundef nonnull align 8 dereferenceable(48) %292, ptr noundef nonnull align 8 dereferenceable(8) %31)
          to label %294 unwind label %299

294:                                              ; preds = %288
  %295 = getelementptr inbounds { ptr, i8 }, ptr %37, i32 0, i32 0
  %296 = extractvalue { ptr, i8 } %293, 0
  store ptr %296, ptr %295, align 8
  %297 = getelementptr inbounds { ptr, i8 }, ptr %37, i32 0, i32 1
  %298 = extractvalue { ptr, i8 } %293, 1
  store i8 %298, ptr %297, align 8
  br label %303

299:                                              ; preds = %288, %280
  %300 = landingpad { ptr, i32 }
          cleanup
  %301 = extractvalue { ptr, i32 } %300, 0
  store ptr %301, ptr %11, align 8
  %302 = extractvalue { ptr, i32 } %300, 1
  store i32 %302, ptr %12, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %36) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %34) #5
  br label %325

303:                                              ; preds = %294, %284
  call void @llvm.lifetime.end.p0(i64 4, ptr %36) #5
  br label %304

304:                                              ; preds = %303
  %305 = call ptr @_ZN9__gnu_cxx17__normal_iteratorIPKP11SynapseBaseSt6vectorIS2_SaIS2_EEEppEi(ptr noundef nonnull align 8 dereferenceable(8) %34, i32 noundef 0) #5
  %306 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator.39", ptr %38, i32 0, i32 0
  store ptr %305, ptr %306, align 8
  br label %262, !llvm.loop !58

307:                                              ; preds = %267
  %308 = load i8, ptr %30, align 1, !tbaa !56, !range !59, !noundef !60
  %309 = trunc i8 %308 to i1
  br i1 %309, label %310, label %321

310:                                              ; preds = %307
  %311 = getelementptr inbounds %class.MultiNetwork, ptr %41, i32 0, i32 0
  %312 = load i32, ptr %32, align 4, !tbaa !9
  %313 = sext i32 %312 to i64
  %314 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt6vectorISt3setIP10NeuronBaseSt4lessIS2_ESaIS2_EESaIS6_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %311, i64 noundef %313) #5
  %315 = invoke { ptr, i8 } @_ZNSt3setIP10NeuronBaseSt4lessIS1_ESaIS1_EE6insertERKS1_(ptr noundef nonnull align 8 dereferenceable(48) %314, ptr noundef nonnull align 8 dereferenceable(8) %31)
          to label %316 unwind label %276

316:                                              ; preds = %310
  %317 = getelementptr inbounds { ptr, i8 }, ptr %39, i32 0, i32 0
  %318 = extractvalue { ptr, i8 } %315, 0
  store ptr %318, ptr %317, align 8
  %319 = getelementptr inbounds { ptr, i8 }, ptr %39, i32 0, i32 1
  %320 = extractvalue { ptr, i8 } %315, 1
  store i8 %320, ptr %319, align 8
  br label %321

321:                                              ; preds = %316, %307
  call void @llvm.lifetime.end.p0(i64 8, ptr %33) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %32) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %31) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr %30) #5
  br label %322

322:                                              ; preds = %321
  %323 = load i32, ptr %29, align 4, !tbaa !9
  %324 = add nsw i32 %323, 1
  store i32 %324, ptr %29, align 4, !tbaa !9
  br label %219, !llvm.loop !61

325:                                              ; preds = %299, %276
  call void @llvm.lifetime.end.p0(i64 8, ptr %33) #5
  br label %326

326:                                              ; preds = %325, %272
  call void @llvm.lifetime.end.p0(i64 4, ptr %32) #5
  br label %327

327:                                              ; preds = %326, %268
  call void @llvm.lifetime.end.p0(i64 8, ptr %31) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr %30) #5
  br label %328

328:                                              ; preds = %327, %229
  call void @llvm.lifetime.end.p0(i64 4, ptr %29) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %28) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %26) #5
  br label %334

329:                                              ; preds = %228
  call void @llvm.lifetime.end.p0(i64 8, ptr %28) #5
  br label %330

330:                                              ; preds = %329
  %331 = call ptr @_ZN9__gnu_cxx17__normal_iteratorIPP14PopulationBaseSt6vectorIS2_SaIS2_EEEppEi(ptr noundef nonnull align 8 dereferenceable(8) %26, i32 noundef 0) #5
  %332 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator.38", ptr %40, i32 0, i32 0
  store ptr %331, ptr %332, align 8
  br label %208, !llvm.loop !62

333:                                              ; preds = %215
  store i32 1, ptr %16, align 4
  call void @_ZNSt3mapIP10NeuronBaseSt6vectorIP11SynapseBaseSaIS4_EESt4lessIS1_ESaISt4pairIKS1_S6_EEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %6) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr %6) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %5) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %4) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %3) #5
  ret void

334:                                              ; preds = %328, %201, %74
  call void @_ZNSt3mapIP10NeuronBaseSt6vectorIP11SynapseBaseSaIS4_EESt4lessIS1_ESaISt4pairIKS1_S6_EEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %6) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr %6) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %5) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %4) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %3) #5
  br label %335

335:                                              ; preds = %334
  %336 = load ptr, ptr %11, align 8
  %337 = load i32, ptr %12, align 4
  %338 = insertvalue { ptr, i32 } poison, ptr %336, 0
  %339 = insertvalue { ptr, i32 } %338, i32 %337, 1
  resume { ptr, i32 } %339
}

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

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

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

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

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

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

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

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

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

declare i32 @__gxx_personality_v0(...)

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

declare noundef nonnull align 8 dereferenceable(24) ptr @_ZNK10NeuronBase11getSynapsesEv(ptr noundef nonnull align 8 dereferenceable(52)) #4

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

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

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

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

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

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

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

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

attributes #0 = { 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 #1 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { 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 #4 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #5 = { 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 = !{!12, !6, i64 120}
!12 = !{!"_ZTS12MultiNetwork", !13, i64 0, !13, i64 24, !17, i64 48, !21, i64 72, !21, i64 96, !6, i64 120, !10, i64 128}
!13 = !{!"_ZTSSt6vectorISt3setIP10NeuronBaseSt4lessIS2_ESaIS2_EESaIS6_EE", !14, i64 0}
!14 = !{!"_ZTSSt12_Vector_baseISt3setIP10NeuronBaseSt4lessIS2_ESaIS2_EESaIS6_EE", !15, i64 0}
!15 = !{!"_ZTSNSt12_Vector_baseISt3setIP10NeuronBaseSt4lessIS2_ESaIS2_EESaIS6_EE12_Vector_implE", !16, i64 0}
!16 = !{!"_ZTSNSt12_Vector_baseISt3setIP10NeuronBaseSt4lessIS2_ESaIS2_EESaIS6_EE17_Vector_impl_dataE", !6, i64 0, !6, i64 8, !6, i64 16}
!17 = !{!"_ZTSSt6vectorISt3mapIP10NeuronBaseiSt4lessIS2_ESaISt4pairIKS2_iEEESaIS9_EE", !18, i64 0}
!18 = !{!"_ZTSSt12_Vector_baseISt3mapIP10NeuronBaseiSt4lessIS2_ESaISt4pairIKS2_iEEESaIS9_EE", !19, i64 0}
!19 = !{!"_ZTSNSt12_Vector_baseISt3mapIP10NeuronBaseiSt4lessIS2_ESaISt4pairIKS2_iEEESaIS9_EE12_Vector_implE", !20, i64 0}
!20 = !{!"_ZTSNSt12_Vector_baseISt3mapIP10NeuronBaseiSt4lessIS2_ESaISt4pairIKS2_iEEESaIS9_EE17_Vector_impl_dataE", !6, i64 0, !6, i64 8, !6, i64 16}
!21 = !{!"_ZTSSt6vectorISt3mapI4TypeiSt4lessIS1_ESaISt4pairIKS1_iEEESaIS8_EE", !22, i64 0}
!22 = !{!"_ZTSSt12_Vector_baseISt3mapI4TypeiSt4lessIS1_ESaISt4pairIKS1_iEEESaIS8_EE", !23, i64 0}
!23 = !{!"_ZTSNSt12_Vector_baseISt3mapI4TypeiSt4lessIS1_ESaISt4pairIKS1_iEEESaIS8_EE12_Vector_implE", !24, i64 0}
!24 = !{!"_ZTSNSt12_Vector_baseISt3mapI4TypeiSt4lessIS1_ESaISt4pairIKS1_iEEESaIS8_EE17_Vector_impl_dataE", !6, i64 0, !6, i64 8, !6, i64 16}
!25 = !{!26, !10, i64 80}
!26 = !{!"_ZTS7Network", !27, i64 0, !31, i64 24, !35, i64 48, !10, i64 72, !10, i64 76, !10, i64 80, !39, i64 84, !39, i64 88, !40, i64 96, !40, i64 120, !10, i64 144, !44, i64 152, !44, i64 176, !44, i64 200}
!27 = !{!"_ZTSSt6vectorIP10NeuronBaseSaIS1_EE", !28, i64 0}
!28 = !{!"_ZTSSt12_Vector_baseIP10NeuronBaseSaIS1_EE", !29, i64 0}
!29 = !{!"_ZTSNSt12_Vector_baseIP10NeuronBaseSaIS1_EE12_Vector_implE", !30, i64 0}
!30 = !{!"_ZTSNSt12_Vector_baseIP10NeuronBaseSaIS1_EE17_Vector_impl_dataE", !6, i64 0, !6, i64 8, !6, i64 16}
!31 = !{!"_ZTSSt6vectorIP14PopulationBaseSaIS1_EE", !32, i64 0}
!32 = !{!"_ZTSSt12_Vector_baseIP14PopulationBaseSaIS1_EE", !33, i64 0}
!33 = !{!"_ZTSNSt12_Vector_baseIP14PopulationBaseSaIS1_EE12_Vector_implE", !34, i64 0}
!34 = !{!"_ZTSNSt12_Vector_baseIP14PopulationBaseSaIS1_EE17_Vector_impl_dataE", !6, i64 0, !6, i64 8, !6, i64 16}
!35 = !{!"_ZTSSt6vectorIP11SynapseBaseSaIS1_EE", !36, i64 0}
!36 = !{!"_ZTSSt12_Vector_baseIP11SynapseBaseSaIS1_EE", !37, i64 0}
!37 = !{!"_ZTSNSt12_Vector_baseIP11SynapseBaseSaIS1_EE12_Vector_implE", !38, i64 0}
!38 = !{!"_ZTSNSt12_Vector_baseIP11SynapseBaseSaIS1_EE17_Vector_impl_dataE", !6, i64 0, !6, i64 8, !6, i64 16}
!39 = !{!"float", !7, i64 0}
!40 = !{!"_ZTSSt6vectorI4TypeSaIS0_EE", !41, i64 0}
!41 = !{!"_ZTSSt12_Vector_baseI4TypeSaIS0_EE", !42, i64 0}
!42 = !{!"_ZTSNSt12_Vector_baseI4TypeSaIS0_EE12_Vector_implE", !43, i64 0}
!43 = !{!"_ZTSNSt12_Vector_baseI4TypeSaIS0_EE17_Vector_impl_dataE", !6, i64 0, !6, i64 8, !6, i64 16}
!44 = !{!"_ZTSSt6vectorIiSaIiEE", !45, i64 0}
!45 = !{!"_ZTSSt12_Vector_baseIiSaIiEE", !46, i64 0}
!46 = !{!"_ZTSNSt12_Vector_baseIiSaIiEE12_Vector_implE", !47, i64 0}
!47 = !{!"_ZTSNSt12_Vector_baseIiSaIiEE17_Vector_impl_dataE", !6, i64 0, !6, i64 8, !6, i64 16}
!48 = !{!12, !10, i64 128}
!49 = distinct !{!49, !50}
!50 = !{!"llvm.loop.mustprogress"}
!51 = !{!52, !52, i64 0}
!52 = !{!"vtable pointer", !8, i64 0}
!53 = distinct !{!53, !50}
!54 = distinct !{!54, !50}
!55 = distinct !{!55, !50}
!56 = !{!57, !57, i64 0}
!57 = !{!"bool", !7, i64 0}
!58 = distinct !{!58, !50}
!59 = !{i8 0, i8 2}
!60 = !{}
!61 = distinct !{!61, !50}
!62 = distinct !{!62, !50}


; 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<NeuronBase *, std::pair<NeuronBase *const, std::vector<SynapseBase *>>, std::_Select1st<std::pair<NeuronBase *const, std::vector<SynapseBase *>>>, std::less<NeuronBase *>>::_Rb_tree_impl" }
%"struct.std::_Rb_tree<NeuronBase *, std::pair<NeuronBase *const, std::vector<SynapseBase *>>, std::_Select1st<std::pair<NeuronBase *const, std::vector<SynapseBase *>>>, std::less<NeuronBase *>>::_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.__gnu_cxx::__normal_iterator" = type { ptr }
%"class.__gnu_cxx::__normal_iterator.38" = type { ptr }
%"struct.std::_Rb_tree_iterator" = type { ptr }
%"class.__gnu_cxx::__normal_iterator.39" = type { ptr }

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN12MultiNetwork12splitNetworkEv(ptr noundef nonnull align 8 dereferenceable(132) %0) local_unnamed_addr #0 align 2 personality ptr @__gxx_personality_v0 {
  %2 = alloca %"class.std::map", align 8
  %3 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %4 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca %"class.__gnu_cxx::__normal_iterator.38", align 8
  %8 = alloca %"class.__gnu_cxx::__normal_iterator.38", align 8
  %9 = alloca %"struct.std::_Rb_tree_iterator", align 8
  %10 = alloca ptr, align 8
  %11 = alloca %"struct.std::_Rb_tree_iterator", align 8
  %12 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %13 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %14 = alloca %"class.__gnu_cxx::__normal_iterator.38", align 8
  %15 = alloca %"class.__gnu_cxx::__normal_iterator.38", align 8
  %16 = alloca ptr, align 8
  %17 = alloca %"class.__gnu_cxx::__normal_iterator.39", align 8
  %18 = alloca %"class.__gnu_cxx::__normal_iterator.39", align 8
  %19 = getelementptr inbounds i8, ptr %0, i64 120
  %20 = load ptr, ptr %19, align 8, !tbaa !5
  %21 = getelementptr inbounds i8, ptr %20, i64 80
  %22 = load i32, ptr %21, align 8, !tbaa !23
  %23 = getelementptr inbounds i8, ptr %0, i64 128
  %24 = load i32, ptr %23, align 8, !tbaa !46
  %25 = sdiv i32 %22, %24
  call void @llvm.lifetime.start.p0(i64 48, ptr nonnull %2) #5
  call void @_ZNSt3mapIP10NeuronBaseSt6vectorIP11SynapseBaseSaIS4_EESt4lessIS1_ESaISt4pairIKS1_S6_EEEC2Ev(ptr noundef nonnull align 8 dereferenceable(48) %2) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %3) #5
  %26 = load ptr, ptr %19, align 8, !tbaa !5
  %27 = getelementptr inbounds i8, ptr %26, i64 48
  %28 = call ptr @_ZNSt6vectorIP11SynapseBaseSaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %27) #5
  store ptr %28, ptr %3, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %4) #5
  %29 = load ptr, ptr %19, align 8, !tbaa !5
  %30 = getelementptr inbounds i8, ptr %29, i64 48
  %31 = call ptr @_ZNSt6vectorIP11SynapseBaseSaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %30) #5
  store ptr %31, ptr %4, align 8
  %32 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPP11SynapseBaseSt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8) %3, ptr noundef nonnull align 8 dereferenceable(8) %4) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %4) #5
  br i1 %32, label %.lr.ph, label %._crit_edge

._crit_edge:                                      ; preds = %45, %1
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %3) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %7) #5
  %33 = load ptr, ptr %19, align 8, !tbaa !5
  %34 = getelementptr inbounds i8, ptr %33, i64 24
  %35 = call ptr @_ZNSt6vectorIP14PopulationBaseSaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %34) #5
  store ptr %35, ptr %7, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %8) #5
  %36 = load ptr, ptr %19, align 8, !tbaa !5
  %37 = getelementptr inbounds i8, ptr %36, i64 24
  %38 = call ptr @_ZNSt6vectorIP14PopulationBaseSaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %37) #5
  store ptr %38, ptr %8, align 8
  %39 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPP14PopulationBaseSt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8) %7, ptr noundef nonnull align 8 dereferenceable(8) %8) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #5
  br i1 %39, label %.lr.ph76, label %._crit_edge77

.lr.ph:                                           ; preds = %1, %45
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %5) #5
  %40 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPP11SynapseBaseSt6vectorIS2_SaIS2_EEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %3) #5
  %41 = load ptr, ptr %40, align 8, !tbaa !47
  store ptr %41, ptr %5, align 8, !tbaa !47
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %6) #5
  %42 = call noundef ptr @_ZN11SynapseBase6getDstEv(ptr noundef nonnull align 8 dereferenceable(33) %41)
  store ptr %42, ptr %6, align 8, !tbaa !47
  %43 = invoke noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt3mapIP10NeuronBaseSt6vectorIP11SynapseBaseSaIS4_EESt4lessIS1_ESaISt4pairIKS1_S6_EEEixEOS1_(ptr noundef nonnull align 8 dereferenceable(48) %2, ptr noundef nonnull align 8 dereferenceable(8) %6)
          to label %44 unwind label %51

44:                                               ; preds = %.lr.ph
  invoke void @_ZNSt6vectorIP11SynapseBaseSaIS1_EE9push_backERKS1_(ptr noundef nonnull align 8 dereferenceable(24) %43, ptr noundef nonnull align 8 dereferenceable(8) %5)
          to label %45 unwind label %51

45:                                               ; preds = %44
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %5) #5
  %46 = call ptr @_ZN9__gnu_cxx17__normal_iteratorIPP11SynapseBaseSt6vectorIS2_SaIS2_EEEppEi(ptr noundef nonnull align 8 dereferenceable(8) %3, i32 noundef 0) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %4) #5
  %47 = load ptr, ptr %19, align 8, !tbaa !5
  %48 = getelementptr inbounds i8, ptr %47, i64 48
  %49 = call ptr @_ZNSt6vectorIP11SynapseBaseSaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %48) #5
  store ptr %49, ptr %4, align 8
  %50 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPP11SynapseBaseSt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8) %3, ptr noundef nonnull align 8 dereferenceable(8) %4) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %4) #5
  br i1 %50, label %.lr.ph, label %._crit_edge, !llvm.loop !48

51:                                               ; preds = %44, %.lr.ph
  %52 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %5) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %3) #5
  br label %190

._crit_edge77:                                    ; preds = %70, %._crit_edge
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #5
  call void @_ZNSt3mapIP10NeuronBaseSt6vectorIP11SynapseBaseSaIS4_EESt4lessIS1_ESaISt4pairIKS1_S6_EEE5clearEv(ptr noundef nonnull align 8 dereferenceable(48) %2) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %14) #5
  %53 = load ptr, ptr %19, align 8, !tbaa !5
  %54 = getelementptr inbounds i8, ptr %53, i64 24
  %55 = call ptr @_ZNSt6vectorIP14PopulationBaseSaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %54) #5
  store ptr %55, ptr %14, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %15) #5
  %56 = load ptr, ptr %19, align 8, !tbaa !5
  %57 = getelementptr inbounds i8, ptr %56, i64 24
  %58 = call ptr @_ZNSt6vectorIP14PopulationBaseSaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %57) #5
  store ptr %58, ptr %15, align 8
  %59 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPP14PopulationBaseSt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8) %14, ptr noundef nonnull align 8 dereferenceable(8) %15) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %15) #5
  br i1 %59, label %.lr.ph83, label %._crit_edge84

.lr.ph83:                                         ; preds = %._crit_edge77
  %60 = getelementptr inbounds i8, ptr %0, i64 24
  br label %123

.lr.ph76:                                         ; preds = %._crit_edge, %70
  %.074 = phi i32 [ %.1, %70 ], [ 0, %._crit_edge ]
  %.04273 = phi i32 [ %.143, %70 ], [ 0, %._crit_edge ]
  %61 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPP14PopulationBaseSt6vectorIS2_SaIS2_EEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %7) #5
  %62 = load ptr, ptr %61, align 8, !tbaa !47
  call void @_ZN4Base7setNodeEi(ptr noundef nonnull align 8 dereferenceable(16) %62, i32 noundef %.074)
  br label %63

63:                                               ; preds = %120, %.lr.ph76
  %.053 = phi i32 [ 0, %.lr.ph76 ], [ %121, %120 ]
  %.143 = phi i32 [ %.04273, %.lr.ph76 ], [ %.2, %120 ]
  %64 = load ptr, ptr %62, align 8, !tbaa !50
  %65 = getelementptr inbounds i8, ptr %64, i64 80
  %66 = load ptr, ptr %65, align 8
  %67 = invoke noundef i32 %66(ptr noundef nonnull align 8 dereferenceable(17) %62)
          to label %68 unwind label %81

68:                                               ; preds = %63
  %69 = icmp slt i32 %.053, %67
  br i1 %69, label %83, label %70

70:                                               ; preds = %68
  %71 = add nsw i32 %.074, 1
  %72 = mul nsw i32 %71, %25
  %.not62 = icmp slt i32 %.143, %72
  %73 = load i32, ptr %23, align 8
  %74 = add nsw i32 %73, -1
  %75 = icmp slt i32 %.074, %74
  %spec.select = select i1 %75, i32 %71, i32 %.074
  %.1 = select i1 %.not62, i32 %.074, i32 %spec.select
  %76 = call ptr @_ZN9__gnu_cxx17__normal_iteratorIPP14PopulationBaseSt6vectorIS2_SaIS2_EEEppEi(ptr noundef nonnull align 8 dereferenceable(8) %7, i32 noundef 0) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %8) #5
  %77 = load ptr, ptr %19, align 8, !tbaa !5
  %78 = getelementptr inbounds i8, ptr %77, i64 24
  %79 = call ptr @_ZNSt6vectorIP14PopulationBaseSaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %78) #5
  store ptr %79, ptr %8, align 8
  %80 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPP14PopulationBaseSt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8) %7, ptr noundef nonnull align 8 dereferenceable(8) %8) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #5
  br i1 %80, label %.lr.ph76, label %._crit_edge77, !llvm.loop !52

81:                                               ; preds = %83, %63
  %82 = landingpad { ptr, i32 }
          cleanup
  br label %122

83:                                               ; preds = %68
  %84 = load ptr, ptr %62, align 8, !tbaa !50
  %85 = getelementptr inbounds i8, ptr %84, i64 96
  %86 = load ptr, ptr %85, align 8
  %87 = invoke noundef ptr %86(ptr noundef nonnull align 8 dereferenceable(17) %62, i32 noundef %.053)
          to label %88 unwind label %81

88:                                               ; preds = %83
  call void @_ZN4Base7setNodeEi(ptr noundef nonnull align 8 dereferenceable(16) %87, i32 noundef %.074)
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %9) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %10) #5
  %89 = load ptr, ptr %62, align 8, !tbaa !50
  %90 = getelementptr inbounds i8, ptr %89, i64 96
  %91 = load ptr, ptr %90, align 8
  %92 = invoke noundef ptr %91(ptr noundef nonnull align 8 dereferenceable(17) %62, i32 noundef %.053)
          to label %93 unwind label %111

93:                                               ; preds = %88
  store ptr %92, ptr %10, align 8, !tbaa !47
  %94 = invoke ptr @_ZNSt3mapIP10NeuronBaseSt6vectorIP11SynapseBaseSaIS4_EESt4lessIS1_ESaISt4pairIKS1_S6_EEE4findERSA_(ptr noundef nonnull align 8 dereferenceable(48) %2, ptr noundef nonnull align 8 dereferenceable(8) %10)
          to label %95 unwind label %111

95:                                               ; preds = %93
  store ptr %94, ptr %9, align 8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %10) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %11) #5
  %96 = call ptr @_ZNSt3mapIP10NeuronBaseSt6vectorIP11SynapseBaseSaIS4_EESt4lessIS1_ESaISt4pairIKS1_S6_EEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %2) #5
  store ptr %96, ptr %11, align 8
  %97 = call noundef zeroext i1 @_ZStneRKSt17_Rb_tree_iteratorISt4pairIKP10NeuronBaseSt6vectorIP11SynapseBaseSaIS6_EEEESC_(ptr noundef nonnull align 8 dereferenceable(8) %9, ptr noundef nonnull align 8 dereferenceable(8) %11) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %11) #5
  br i1 %97, label %98, label %120

98:                                               ; preds = %95
  %99 = call noundef ptr @_ZNKSt17_Rb_tree_iteratorISt4pairIKP10NeuronBaseSt6vectorIP11SynapseBaseSaIS6_EEEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %9) #5
  %100 = getelementptr inbounds i8, ptr %99, i64 8
  %101 = call noundef i64 @_ZNKSt6vectorIP11SynapseBaseSaIS1_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %100) #5
  %102 = trunc i64 %101 to i32
  %103 = add i32 %.143, %102
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %12) #5
  %104 = call noundef ptr @_ZNKSt17_Rb_tree_iteratorISt4pairIKP10NeuronBaseSt6vectorIP11SynapseBaseSaIS6_EEEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %9) #5
  %105 = getelementptr inbounds i8, ptr %104, i64 8
  %106 = call ptr @_ZNSt6vectorIP11SynapseBaseSaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %105) #5
  store ptr %106, ptr %12, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %13) #5
  %107 = call noundef ptr @_ZNKSt17_Rb_tree_iteratorISt4pairIKP10NeuronBaseSt6vectorIP11SynapseBaseSaIS6_EEEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %9) #5
  %108 = getelementptr inbounds i8, ptr %107, i64 8
  %109 = call ptr @_ZNSt6vectorIP11SynapseBaseSaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %108) #5
  store ptr %109, ptr %13, align 8
  %110 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPP11SynapseBaseSt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8) %12, ptr noundef nonnull align 8 dereferenceable(8) %13) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %13) #5
  br i1 %110, label %.lr.ph71, label %._crit_edge72

._crit_edge72:                                    ; preds = %.lr.ph71, %98
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %12) #5
  br label %120

111:                                              ; preds = %93, %88
  %112 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %10) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %9) #5
  br label %122

.lr.ph71:                                         ; preds = %98, %.lr.ph71
  %113 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPP11SynapseBaseSt6vectorIS2_SaIS2_EEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %12) #5
  %114 = load ptr, ptr %113, align 8, !tbaa !47
  call void @_ZN4Base7setNodeEi(ptr noundef nonnull align 8 dereferenceable(16) %114, i32 noundef %.074)
  %115 = call ptr @_ZN9__gnu_cxx17__normal_iteratorIPP11SynapseBaseSt6vectorIS2_SaIS2_EEEppEi(ptr noundef nonnull align 8 dereferenceable(8) %12, i32 noundef 0) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %13) #5
  %116 = call noundef ptr @_ZNKSt17_Rb_tree_iteratorISt4pairIKP10NeuronBaseSt6vectorIP11SynapseBaseSaIS6_EEEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %9) #5
  %117 = getelementptr inbounds i8, ptr %116, i64 8
  %118 = call ptr @_ZNSt6vectorIP11SynapseBaseSaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %117) #5
  store ptr %118, ptr %13, align 8
  %119 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPP11SynapseBaseSt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8) %12, ptr noundef nonnull align 8 dereferenceable(8) %13) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %13) #5
  br i1 %119, label %.lr.ph71, label %._crit_edge72, !llvm.loop !53

120:                                              ; preds = %._crit_edge72, %95
  %.2 = phi i32 [ %103, %._crit_edge72 ], [ %.143, %95 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %9) #5
  %121 = add nuw nsw i32 %.053, 1
  br label %63, !llvm.loop !54

122:                                              ; preds = %111, %81
  %.pn63 = phi { ptr, i32 } [ %112, %111 ], [ %82, %81 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #5
  br label %190

._crit_edge84:                                    ; preds = %133, %._crit_edge77
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %14) #5
  call void @_ZNSt3mapIP10NeuronBaseSt6vectorIP11SynapseBaseSaIS4_EESt4lessIS1_ESaISt4pairIKS1_S6_EEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %2) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %2) #5
  ret void

123:                                              ; preds = %.lr.ph83, %133
  %124 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPP14PopulationBaseSt6vectorIS2_SaIS2_EEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %14) #5
  %125 = load ptr, ptr %124, align 8, !tbaa !47
  br label %126

126:                                              ; preds = %186, %123
  %.054 = phi i32 [ 0, %123 ], [ %187, %186 ]
  %127 = load ptr, ptr %125, align 8, !tbaa !50
  %128 = getelementptr inbounds i8, ptr %127, i64 80
  %129 = load ptr, ptr %128, align 8
  %130 = invoke noundef i32 %129(ptr noundef nonnull align 8 dereferenceable(17) %125)
          to label %131 unwind label %139

131:                                              ; preds = %126
  %132 = icmp slt i32 %.054, %130
  br i1 %132, label %141, label %133

133:                                              ; preds = %131
  %134 = call ptr @_ZN9__gnu_cxx17__normal_iteratorIPP14PopulationBaseSt6vectorIS2_SaIS2_EEEppEi(ptr noundef nonnull align 8 dereferenceable(8) %14, i32 noundef 0) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %15) #5
  %135 = load ptr, ptr %19, align 8, !tbaa !5
  %136 = getelementptr inbounds i8, ptr %135, i64 24
  %137 = call ptr @_ZNSt6vectorIP14PopulationBaseSaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %136) #5
  store ptr %137, ptr %15, align 8
  %138 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPP14PopulationBaseSt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8) %14, ptr noundef nonnull align 8 dereferenceable(8) %15) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %15) #5
  br i1 %138, label %123, label %._crit_edge84, !llvm.loop !55

139:                                              ; preds = %126
  %140 = landingpad { ptr, i32 }
          cleanup
  br label %189

141:                                              ; preds = %131
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %16) #5
  %142 = load ptr, ptr %125, align 8, !tbaa !50
  %143 = getelementptr inbounds i8, ptr %142, i64 96
  %144 = load ptr, ptr %143, align 8
  %145 = invoke noundef ptr %144(ptr noundef nonnull align 8 dereferenceable(17) %125, i32 noundef %.054)
          to label %146 unwind label %163

146:                                              ; preds = %141
  store ptr %145, ptr %16, align 8, !tbaa !47
  %147 = load ptr, ptr %125, align 8, !tbaa !50
  %148 = getelementptr inbounds i8, ptr %147, i64 96
  %149 = load ptr, ptr %148, align 8
  %150 = invoke noundef ptr %149(ptr noundef nonnull align 8 dereferenceable(17) %125, i32 noundef %.054)
          to label %151 unwind label %165

151:                                              ; preds = %146
  %152 = call noundef i32 @_ZN4Base7getNodeEv(ptr noundef nonnull align 8 dereferenceable(16) %150)
  %153 = load ptr, ptr %125, align 8, !tbaa !50
  %154 = getelementptr inbounds i8, ptr %153, i64 96
  %155 = load ptr, ptr %154, align 8
  %156 = invoke noundef ptr %155(ptr noundef nonnull align 8 dereferenceable(17) %125, i32 noundef %.054)
          to label %157 unwind label %167

157:                                              ; preds = %151
  %158 = invoke noundef nonnull align 8 dereferenceable(24) ptr @_ZNK10NeuronBase11getSynapsesEv(ptr noundef nonnull align 8 dereferenceable(52) %156)
          to label %159 unwind label %167

159:                                              ; preds = %157
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %17) #5
  %160 = call ptr @_ZNKSt6vectorIP11SynapseBaseSaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %158) #5
  store ptr %160, ptr %17, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %18) #5
  %161 = call ptr @_ZNKSt6vectorIP11SynapseBaseSaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %158) #5
  store ptr %161, ptr %18, align 8
  %162 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPKP11SynapseBaseSt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESD_(ptr noundef nonnull align 8 dereferenceable(8) %17, ptr noundef nonnull align 8 dereferenceable(8) %18) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %18) #5
  br i1 %162, label %.lr.ph80, label %.critedge

._crit_edge81:                                    ; preds = %178
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %17) #5
  br i1 %.156, label %182, label %186

163:                                              ; preds = %141
  %164 = landingpad { ptr, i32 }
          cleanup
  br label %188

165:                                              ; preds = %146
  %166 = landingpad { ptr, i32 }
          cleanup
  br label %188

167:                                              ; preds = %182, %157, %151
  %168 = landingpad { ptr, i32 }
          cleanup
  br label %188

.lr.ph80:                                         ; preds = %159, %178
  %.05578 = phi i1 [ %.156, %178 ], [ false, %159 ]
  %169 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPKP11SynapseBaseSt6vectorIS2_SaIS2_EEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %17) #5
  %170 = load ptr, ptr %169, align 8, !tbaa !47
  %171 = call noundef i32 @_ZN4Base7getNodeEv(ptr noundef nonnull align 8 dereferenceable(16) %170)
  %.not = icmp eq i32 %171, %152
  br i1 %.not, label %178, label %172

172:                                              ; preds = %.lr.ph80
  %173 = sext i32 %171 to i64
  %174 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt6vectorISt3setIP10NeuronBaseSt4lessIS2_ESaIS2_EESaIS6_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %60, i64 noundef %173) #5
  %175 = invoke { ptr, i8 } @_ZNSt3setIP10NeuronBaseSt4lessIS1_ESaIS1_EE6insertERKS1_(ptr noundef nonnull align 8 dereferenceable(48) %174, ptr noundef nonnull align 8 dereferenceable(8) %16)
          to label %178 unwind label %176

176:                                              ; preds = %172
  %177 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %17) #5
  br label %188

178:                                              ; preds = %172, %.lr.ph80
  %.156 = phi i1 [ %.05578, %.lr.ph80 ], [ true, %172 ]
  %179 = call ptr @_ZN9__gnu_cxx17__normal_iteratorIPKP11SynapseBaseSt6vectorIS2_SaIS2_EEEppEi(ptr noundef nonnull align 8 dereferenceable(8) %17, i32 noundef 0) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %18) #5
  %180 = call ptr @_ZNKSt6vectorIP11SynapseBaseSaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %158) #5
  store ptr %180, ptr %18, align 8
  %181 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPKP11SynapseBaseSt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESD_(ptr noundef nonnull align 8 dereferenceable(8) %17, ptr noundef nonnull align 8 dereferenceable(8) %18) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %18) #5
  br i1 %181, label %.lr.ph80, label %._crit_edge81, !llvm.loop !56

182:                                              ; preds = %._crit_edge81
  %183 = sext i32 %152 to i64
  %184 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt6vectorISt3setIP10NeuronBaseSt4lessIS2_ESaIS2_EESaIS6_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %0, i64 noundef %183) #5
  %185 = invoke { ptr, i8 } @_ZNSt3setIP10NeuronBaseSt4lessIS1_ESaIS1_EE6insertERKS1_(ptr noundef nonnull align 8 dereferenceable(48) %184, ptr noundef nonnull align 8 dereferenceable(8) %16)
          to label %186 unwind label %167

.critedge:                                        ; preds = %159
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %17) #5
  br label %186

186:                                              ; preds = %.critedge, %182, %._crit_edge81
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %16) #5
  %187 = add nuw nsw i32 %.054, 1
  br label %126, !llvm.loop !57

188:                                              ; preds = %165, %176, %167, %163
  %.pn.pn.pn = phi { ptr, i32 } [ %164, %163 ], [ %166, %165 ], [ %177, %176 ], [ %168, %167 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %16) #5
  br label %189

189:                                              ; preds = %188, %139
  %.pn.pn.pn.pn = phi { ptr, i32 } [ %.pn.pn.pn, %188 ], [ %140, %139 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %14) #5
  br label %190

190:                                              ; preds = %189, %122, %51
  %.pn65 = phi { ptr, i32 } [ %52, %51 ], [ %.pn63, %122 ], [ %.pn.pn.pn.pn, %189 ]
  call void @_ZNSt3mapIP10NeuronBaseSt6vectorIP11SynapseBaseSaIS4_EESt4lessIS1_ESaISt4pairIKS1_S6_EEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %2) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %2) #5
  resume { ptr, i32 } %.pn65
}

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

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZN9__gnu_cxxneIPP11SynapseBaseSt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(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 ptr @_ZNSt6vectorIP11SynapseBaseSaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #2 align 2

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

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

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

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

declare i32 @__gxx_personality_v0(...)

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

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZN9__gnu_cxxneIPP14PopulationBaseSt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(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 ptr @_ZNSt6vectorIP14PopulationBaseSaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #2 align 2

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

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

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

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

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

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

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

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

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

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

declare noundef nonnull align 8 dereferenceable(24) ptr @_ZNK10NeuronBase11getSynapsesEv(ptr noundef nonnull align 8 dereferenceable(52)) local_unnamed_addr #4

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZN9__gnu_cxxneIPKP11SynapseBaseSt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESD_(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 ptr @_ZNKSt6vectorIP11SynapseBaseSaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #2 align 2

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

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

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

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

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

attributes #0 = { 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 #1 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { 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 #4 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #5 = { 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, !11, i64 120}
!6 = !{!"_ZTS12MultiNetwork", !7, i64 0, !7, i64 24, !14, i64 48, !18, i64 72, !18, i64 96, !11, i64 120, !22, i64 128}
!7 = !{!"_ZTSSt6vectorISt3setIP10NeuronBaseSt4lessIS2_ESaIS2_EESaIS6_EE", !8, i64 0}
!8 = !{!"_ZTSSt12_Vector_baseISt3setIP10NeuronBaseSt4lessIS2_ESaIS2_EESaIS6_EE", !9, i64 0}
!9 = !{!"_ZTSNSt12_Vector_baseISt3setIP10NeuronBaseSt4lessIS2_ESaIS2_EESaIS6_EE12_Vector_implE", !10, i64 0}
!10 = !{!"_ZTSNSt12_Vector_baseISt3setIP10NeuronBaseSt4lessIS2_ESaIS2_EESaIS6_EE17_Vector_impl_dataE", !11, i64 0, !11, i64 8, !11, i64 16}
!11 = !{!"any pointer", !12, i64 0}
!12 = !{!"omnipotent char", !13, i64 0}
!13 = !{!"Simple C++ TBAA"}
!14 = !{!"_ZTSSt6vectorISt3mapIP10NeuronBaseiSt4lessIS2_ESaISt4pairIKS2_iEEESaIS9_EE", !15, i64 0}
!15 = !{!"_ZTSSt12_Vector_baseISt3mapIP10NeuronBaseiSt4lessIS2_ESaISt4pairIKS2_iEEESaIS9_EE", !16, i64 0}
!16 = !{!"_ZTSNSt12_Vector_baseISt3mapIP10NeuronBaseiSt4lessIS2_ESaISt4pairIKS2_iEEESaIS9_EE12_Vector_implE", !17, i64 0}
!17 = !{!"_ZTSNSt12_Vector_baseISt3mapIP10NeuronBaseiSt4lessIS2_ESaISt4pairIKS2_iEEESaIS9_EE17_Vector_impl_dataE", !11, i64 0, !11, i64 8, !11, i64 16}
!18 = !{!"_ZTSSt6vectorISt3mapI4TypeiSt4lessIS1_ESaISt4pairIKS1_iEEESaIS8_EE", !19, i64 0}
!19 = !{!"_ZTSSt12_Vector_baseISt3mapI4TypeiSt4lessIS1_ESaISt4pairIKS1_iEEESaIS8_EE", !20, i64 0}
!20 = !{!"_ZTSNSt12_Vector_baseISt3mapI4TypeiSt4lessIS1_ESaISt4pairIKS1_iEEESaIS8_EE12_Vector_implE", !21, i64 0}
!21 = !{!"_ZTSNSt12_Vector_baseISt3mapI4TypeiSt4lessIS1_ESaISt4pairIKS1_iEEESaIS8_EE17_Vector_impl_dataE", !11, i64 0, !11, i64 8, !11, i64 16}
!22 = !{!"int", !12, i64 0}
!23 = !{!24, !22, i64 80}
!24 = !{!"_ZTS7Network", !25, i64 0, !29, i64 24, !33, i64 48, !22, i64 72, !22, i64 76, !22, i64 80, !37, i64 84, !37, i64 88, !38, i64 96, !38, i64 120, !22, i64 144, !42, i64 152, !42, i64 176, !42, i64 200}
!25 = !{!"_ZTSSt6vectorIP10NeuronBaseSaIS1_EE", !26, i64 0}
!26 = !{!"_ZTSSt12_Vector_baseIP10NeuronBaseSaIS1_EE", !27, i64 0}
!27 = !{!"_ZTSNSt12_Vector_baseIP10NeuronBaseSaIS1_EE12_Vector_implE", !28, i64 0}
!28 = !{!"_ZTSNSt12_Vector_baseIP10NeuronBaseSaIS1_EE17_Vector_impl_dataE", !11, i64 0, !11, i64 8, !11, i64 16}
!29 = !{!"_ZTSSt6vectorIP14PopulationBaseSaIS1_EE", !30, i64 0}
!30 = !{!"_ZTSSt12_Vector_baseIP14PopulationBaseSaIS1_EE", !31, i64 0}
!31 = !{!"_ZTSNSt12_Vector_baseIP14PopulationBaseSaIS1_EE12_Vector_implE", !32, i64 0}
!32 = !{!"_ZTSNSt12_Vector_baseIP14PopulationBaseSaIS1_EE17_Vector_impl_dataE", !11, i64 0, !11, i64 8, !11, i64 16}
!33 = !{!"_ZTSSt6vectorIP11SynapseBaseSaIS1_EE", !34, i64 0}
!34 = !{!"_ZTSSt12_Vector_baseIP11SynapseBaseSaIS1_EE", !35, i64 0}
!35 = !{!"_ZTSNSt12_Vector_baseIP11SynapseBaseSaIS1_EE12_Vector_implE", !36, i64 0}
!36 = !{!"_ZTSNSt12_Vector_baseIP11SynapseBaseSaIS1_EE17_Vector_impl_dataE", !11, i64 0, !11, i64 8, !11, i64 16}
!37 = !{!"float", !12, i64 0}
!38 = !{!"_ZTSSt6vectorI4TypeSaIS0_EE", !39, i64 0}
!39 = !{!"_ZTSSt12_Vector_baseI4TypeSaIS0_EE", !40, i64 0}
!40 = !{!"_ZTSNSt12_Vector_baseI4TypeSaIS0_EE12_Vector_implE", !41, i64 0}
!41 = !{!"_ZTSNSt12_Vector_baseI4TypeSaIS0_EE17_Vector_impl_dataE", !11, i64 0, !11, i64 8, !11, i64 16}
!42 = !{!"_ZTSSt6vectorIiSaIiEE", !43, i64 0}
!43 = !{!"_ZTSSt12_Vector_baseIiSaIiEE", !44, i64 0}
!44 = !{!"_ZTSNSt12_Vector_baseIiSaIiEE12_Vector_implE", !45, i64 0}
!45 = !{!"_ZTSNSt12_Vector_baseIiSaIiEE17_Vector_impl_dataE", !11, i64 0, !11, i64 8, !11, i64 16}
!46 = !{!6, !22, i64 128}
!47 = !{!11, !11, i64 0}
!48 = distinct !{!48, !49}
!49 = !{!"llvm.loop.mustprogress"}
!50 = !{!51, !51, i64 0}
!51 = !{!"vtable pointer", !13, i64 0}
!52 = distinct !{!52, !49}
!53 = distinct !{!53, !49}
!54 = distinct !{!54, !49}
!55 = distinct !{!55, !49}
!56 = distinct !{!56, !49}
!57 = distinct !{!57, !49}


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