; LLVM IR from stonne-simulator/omega :: omega-code/stonne/src/ASNetwork.ll (ZN9ASNetworkD2Ev)

; 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"

%"struct.std::_Rb_tree_iterator" = type { ptr }
%"struct.std::_Rb_tree_iterator.23" = type { ptr }
%class.ASNetwork = type <{ %class.ReduceNetwork, i32, i32, i32, [4 x i8], %"class.std::map", %"class.std::vector", %"class.std::vector", %"class.std::map.6", %"class.std::map.6", %"class.std::vector.11", ptr, ptr, i8, [3 x i8], %class.Config, [4 x i8] }>
%class.ReduceNetwork = type { %class.Unit }
%class.Unit = type { ptr, i32, %"class.std::__cxx11::basic_string" }
%"class.std::__cxx11::basic_string" = type { %"struct.std::__cxx11::basic_string<char>::_Alloc_hider", i64, %union.anon }
%"struct.std::__cxx11::basic_string<char>::_Alloc_hider" = type { ptr }
%union.anon = type { i64, [8 x i8] }
%"class.std::map" = type { %"class.std::_Rb_tree" }
%"class.std::_Rb_tree" = type { %"struct.std::_Rb_tree<std::pair<int, int>, std::pair<const std::pair<int, int>, ASwitch *>, std::_Select1st<std::pair<const std::pair<int, int>, ASwitch *>>, std::less<std::pair<int, int>>>::_Rb_tree_impl" }
%"struct.std::_Rb_tree<std::pair<int, int>, std::pair<const std::pair<int, int>, ASwitch *>, std::_Select1st<std::pair<const std::pair<int, int>, ASwitch *>>, std::less<std::pair<int, int>>>::_Rb_tree_impl" = type { [8 x i8], %"struct.std::_Rb_tree_header" }
%"struct.std::_Rb_tree_header" = type { %"struct.std::_Rb_tree_node_base", i64 }
%"struct.std::_Rb_tree_node_base" = type { i32, ptr, ptr, ptr }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<ASwitch *, std::allocator<ASwitch *>>::_Vector_impl" }
%"struct.std::_Vector_base<ASwitch *, std::allocator<ASwitch *>>::_Vector_impl" = type { %"struct.std::_Vector_base<ASwitch *, std::allocator<ASwitch *>>::_Vector_impl_data" }
%"struct.std::_Vector_base<ASwitch *, std::allocator<ASwitch *>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::map.6" = type { %"class.std::_Rb_tree.7" }
%"class.std::_Rb_tree.7" = type { %"struct.std::_Rb_tree<std::pair<int, int>, std::pair<const std::pair<int, int>, Connection *>, std::_Select1st<std::pair<const std::pair<int, int>, Connection *>>, std::less<std::pair<int, int>>>::_Rb_tree_impl" }
%"struct.std::_Rb_tree<std::pair<int, int>, std::pair<const std::pair<int, int>, Connection *>, std::_Select1st<std::pair<const std::pair<int, int>, Connection *>>, std::less<std::pair<int, int>>>::_Rb_tree_impl" = type { [8 x i8], %"struct.std::_Rb_tree_header" }
%"class.std::vector.11" = type { %"struct.std::_Vector_base.12" }
%"struct.std::_Vector_base.12" = type { %"struct.std::_Vector_base<Connection *, std::allocator<Connection *>>::_Vector_impl" }
%"struct.std::_Vector_base<Connection *, std::allocator<Connection *>>::_Vector_impl" = type { %"struct.std::_Vector_base<Connection *, std::allocator<Connection *>>::_Vector_impl_data" }
%"struct.std::_Vector_base<Connection *, std::allocator<Connection *>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%class.Config = type { i32, %class.DSNetworkConfig, %class.DSwitchConfig, %class.MSNetworkConfig, %class.MSwitchConfig, %class.ASNetworkConfig, %class.ASwitchConfig, %class.LookUpTableConfig, %class.SDMemoryConfig }
%class.DSNetworkConfig = type { i32 }
%class.DSwitchConfig = type { i32, i32, i32, i32 }
%class.MSNetworkConfig = type { i32, i32, i32, i32 }
%class.MSwitchConfig = type { i32, i32, i32, i32, i32, i32 }
%class.ASNetworkConfig = type { i32, i32 }
%class.ASwitchConfig = type { i32, i32, i32, i32, i32, i32 }
%class.LookUpTableConfig = type { i32, i32 }
%class.SDMemoryConfig = type { i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32 }
%"struct.std::pair.21" = type { %"struct.std::pair", ptr }
%"struct.std::pair" = type { i32, i32 }
%"struct.std::pair.24" = type { %"struct.std::pair", ptr }

@_ZTV9ASNetwork = external dso_local unnamed_addr constant { [14 x ptr] }, align 8

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

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

; Function Attrs: nobuiltin nounwind
declare void @_ZdlPvm(ptr noundef, i64 noundef) #1

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

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

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

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

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

; Function Attrs: mustprogress nounwind uwtable
define dso_local void @_ZN9ASNetworkD2Ev(ptr noundef nonnull align 8 dereferenceable(460) %0) unnamed_addr #2 align 2 {
  %2 = alloca ptr, align 8
  %3 = alloca %"struct.std::_Rb_tree_iterator", align 8
  %4 = alloca %"struct.std::_Rb_tree_iterator", align 8
  %5 = alloca %"struct.std::_Rb_tree_iterator.23", align 8
  %6 = alloca %"struct.std::_Rb_tree_iterator.23", align 8
  %7 = alloca %"struct.std::_Rb_tree_iterator.23", align 8
  %8 = alloca %"struct.std::_Rb_tree_iterator.23", align 8
  %9 = alloca i32, align 4
  store ptr %0, ptr %2, align 8, !tbaa !5
  %10 = load ptr, ptr %2, align 8
  store ptr getelementptr inbounds inrange(-16, 96) ({ [14 x ptr] }, ptr @_ZTV9ASNetwork, i32 0, i32 0, i32 2), ptr %10, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %3) #5
  %11 = getelementptr inbounds %class.ASNetwork, ptr %10, i32 0, i32 5
  %12 = call ptr @_ZNSt3mapISt4pairIiiEP7ASwitchSt4lessIS1_ESaIS0_IKS1_S3_EEE5beginEv(ptr noundef nonnull align 8 dereferenceable(48) %11) #5
  %13 = getelementptr inbounds %"struct.std::_Rb_tree_iterator", ptr %3, i32 0, i32 0
  store ptr %12, ptr %13, align 8
  br label %14

14:                                               ; preds = %27, %1
  call void @llvm.lifetime.start.p0(i64 8, ptr %4) #5
  %15 = getelementptr inbounds %class.ASNetwork, ptr %10, i32 0, i32 5
  %16 = call ptr @_ZNSt3mapISt4pairIiiEP7ASwitchSt4lessIS1_ESaIS0_IKS1_S3_EEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %15) #5
  %17 = getelementptr inbounds %"struct.std::_Rb_tree_iterator", ptr %4, i32 0, i32 0
  store ptr %16, ptr %17, align 8
  %18 = call noundef zeroext i1 @_ZStneRKSt17_Rb_tree_iteratorISt4pairIKS0_IiiEP7ASwitchEES8_(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 %4) #5
  br i1 %18, label %20, label %19

19:                                               ; preds = %14
  call void @llvm.lifetime.end.p0(i64 8, ptr %3) #5
  br label %29

20:                                               ; preds = %14
  %21 = call noundef ptr @_ZNKSt17_Rb_tree_iteratorISt4pairIKS0_IiiEP7ASwitchEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %3) #5
  %22 = getelementptr inbounds %"struct.std::pair.21", ptr %21, i32 0, i32 1
  %23 = load ptr, ptr %22, align 8, !tbaa !11
  %24 = icmp eq ptr %23, null
  br i1 %24, label %26, label %25

25:                                               ; preds = %20
  call void @_ZN7ASwitchD1Ev(ptr noundef nonnull align 8 dereferenceable(288) %23) #5
  call void @_ZdlPvm(ptr noundef %23, i64 noundef 288) #6
  br label %26

26:                                               ; preds = %25, %20
  br label %27

27:                                               ; preds = %26
  %28 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt17_Rb_tree_iteratorISt4pairIKS0_IiiEP7ASwitchEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %3) #5
  br label %14, !llvm.loop !15

29:                                               ; preds = %19
  call void @llvm.lifetime.start.p0(i64 8, ptr %5) #5
  %30 = getelementptr inbounds %class.ASNetwork, ptr %10, i32 0, i32 8
  %31 = call ptr @_ZNSt3mapISt4pairIiiEP10ConnectionSt4lessIS1_ESaIS0_IKS1_S3_EEE5beginEv(ptr noundef nonnull align 8 dereferenceable(48) %30) #5
  %32 = getelementptr inbounds %"struct.std::_Rb_tree_iterator.23", ptr %5, i32 0, i32 0
  store ptr %31, ptr %32, align 8
  br label %33

33:                                               ; preds = %46, %29
  call void @llvm.lifetime.start.p0(i64 8, ptr %6) #5
  %34 = getelementptr inbounds %class.ASNetwork, ptr %10, i32 0, i32 8
  %35 = call ptr @_ZNSt3mapISt4pairIiiEP10ConnectionSt4lessIS1_ESaIS0_IKS1_S3_EEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %34) #5
  %36 = getelementptr inbounds %"struct.std::_Rb_tree_iterator.23", ptr %6, i32 0, i32 0
  store ptr %35, ptr %36, align 8
  %37 = call noundef zeroext i1 @_ZStneRKSt17_Rb_tree_iteratorISt4pairIKS0_IiiEP10ConnectionEES8_(ptr noundef nonnull align 8 dereferenceable(8) %5, ptr noundef nonnull align 8 dereferenceable(8) %6) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #5
  br i1 %37, label %39, label %38

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

39:                                               ; preds = %33
  %40 = call noundef ptr @_ZNKSt17_Rb_tree_iteratorISt4pairIKS0_IiiEP10ConnectionEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %5) #5
  %41 = getelementptr inbounds %"struct.std::pair.24", ptr %40, i32 0, i32 1
  %42 = load ptr, ptr %41, align 8, !tbaa !17
  %43 = icmp eq ptr %42, null
  br i1 %43, label %45, label %44

44:                                               ; preds = %39
  call void @_ZN10ConnectionD2Ev(ptr noundef nonnull align 8 dereferenceable(64) %42) #5
  call void @_ZdlPvm(ptr noundef %42, i64 noundef 64) #6
  br label %45

45:                                               ; preds = %44, %39
  br label %46

46:                                               ; preds = %45
  %47 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt17_Rb_tree_iteratorISt4pairIKS0_IiiEP10ConnectionEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %5) #5
  br label %33, !llvm.loop !19

48:                                               ; preds = %38
  call void @llvm.lifetime.start.p0(i64 8, ptr %7) #5
  %49 = getelementptr inbounds %class.ASNetwork, ptr %10, i32 0, i32 9
  %50 = call ptr @_ZNSt3mapISt4pairIiiEP10ConnectionSt4lessIS1_ESaIS0_IKS1_S3_EEE5beginEv(ptr noundef nonnull align 8 dereferenceable(48) %49) #5
  %51 = getelementptr inbounds %"struct.std::_Rb_tree_iterator.23", ptr %7, i32 0, i32 0
  store ptr %50, ptr %51, align 8
  br label %52

52:                                               ; preds = %65, %48
  call void @llvm.lifetime.start.p0(i64 8, ptr %8) #5
  %53 = getelementptr inbounds %class.ASNetwork, ptr %10, i32 0, i32 9
  %54 = call ptr @_ZNSt3mapISt4pairIiiEP10ConnectionSt4lessIS1_ESaIS0_IKS1_S3_EEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %53) #5
  %55 = getelementptr inbounds %"struct.std::_Rb_tree_iterator.23", ptr %8, i32 0, i32 0
  store ptr %54, ptr %55, align 8
  %56 = call noundef zeroext i1 @_ZStneRKSt17_Rb_tree_iteratorISt4pairIKS0_IiiEP10ConnectionEES8_(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 %56, label %58, label %57

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

58:                                               ; preds = %52
  %59 = call noundef ptr @_ZNKSt17_Rb_tree_iteratorISt4pairIKS0_IiiEP10ConnectionEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %7) #5
  %60 = getelementptr inbounds %"struct.std::pair.24", ptr %59, i32 0, i32 1
  %61 = load ptr, ptr %60, align 8, !tbaa !17
  %62 = icmp eq ptr %61, null
  br i1 %62, label %64, label %63

63:                                               ; preds = %58
  call void @_ZN10ConnectionD2Ev(ptr noundef nonnull align 8 dereferenceable(64) %61) #5
  call void @_ZdlPvm(ptr noundef %61, i64 noundef 64) #6
  br label %64

64:                                               ; preds = %63, %58
  br label %65

65:                                               ; preds = %64
  %66 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt17_Rb_tree_iteratorISt4pairIKS0_IiiEP10ConnectionEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %7) #5
  br label %52, !llvm.loop !20

67:                                               ; preds = %57
  %68 = getelementptr inbounds %class.ASNetwork, ptr %10, i32 0, i32 13
  %69 = load i8, ptr %68, align 8, !tbaa !21, !range !61, !noundef !62
  %70 = trunc i8 %69 to i1
  %71 = zext i1 %70 to i32
  %72 = icmp sgt i32 %71, 0
  br i1 %72, label %73, label %99

73:                                               ; preds = %67
  %74 = getelementptr inbounds %class.ASNetwork, ptr %10, i32 0, i32 12
  %75 = load ptr, ptr %74, align 8, !tbaa !63
  %76 = icmp eq ptr %75, null
  br i1 %76, label %78, label %77

77:                                               ; preds = %73
  call void @_ZN18AccumulationBufferD1Ev(ptr noundef nonnull align 8 dereferenceable(200) %75) #5
  call void @_ZdlPvm(ptr noundef %75, i64 noundef 200) #6
  br label %78

78:                                               ; preds = %77, %73
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #5
  store i32 0, ptr %9, align 4, !tbaa !64
  br label %79

79:                                               ; preds = %95, %78
  %80 = load i32, ptr %9, align 4, !tbaa !64
  %81 = sext i32 %80 to i64
  %82 = getelementptr inbounds %class.ASNetwork, ptr %10, i32 0, i32 10
  %83 = call noundef i64 @_ZNKSt6vectorIP10ConnectionSaIS1_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %82) #5
  %84 = icmp ult i64 %81, %83
  br i1 %84, label %86, label %85

85:                                               ; preds = %79
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #5
  br label %98

86:                                               ; preds = %79
  %87 = getelementptr inbounds %class.ASNetwork, ptr %10, i32 0, i32 10
  %88 = load i32, ptr %9, align 4, !tbaa !64
  %89 = sext i32 %88 to i64
  %90 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIP10ConnectionSaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %87, i64 noundef %89) #5
  %91 = load ptr, ptr %90, align 8, !tbaa !5
  %92 = icmp eq ptr %91, null
  br i1 %92, label %94, label %93

93:                                               ; preds = %86
  call void @_ZN10ConnectionD2Ev(ptr noundef nonnull align 8 dereferenceable(64) %91) #5
  call void @_ZdlPvm(ptr noundef %91, i64 noundef 64) #6
  br label %94

94:                                               ; preds = %93, %86
  br label %95

95:                                               ; preds = %94
  %96 = load i32, ptr %9, align 4, !tbaa !64
  %97 = add nsw i32 %96, 1
  store i32 %97, ptr %9, align 4, !tbaa !64
  br label %79, !llvm.loop !65

98:                                               ; preds = %85
  br label %99

99:                                               ; preds = %98, %67
  %100 = getelementptr inbounds %class.ASNetwork, ptr %10, i32 0, i32 10
  call void @_ZNSt6vectorIP10ConnectionSaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %100) #5
  %101 = getelementptr inbounds %class.ASNetwork, ptr %10, i32 0, i32 9
  call void @_ZNSt3mapISt4pairIiiEP10ConnectionSt4lessIS1_ESaIS0_IKS1_S3_EEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %101) #5
  %102 = getelementptr inbounds %class.ASNetwork, ptr %10, i32 0, i32 8
  call void @_ZNSt3mapISt4pairIiiEP10ConnectionSt4lessIS1_ESaIS0_IKS1_S3_EEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %102) #5
  %103 = getelementptr inbounds %class.ASNetwork, ptr %10, i32 0, i32 7
  call void @_ZNSt6vectorIP7ASwitchSaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %103) #5
  %104 = getelementptr inbounds %class.ASNetwork, ptr %10, i32 0, i32 6
  call void @_ZNSt6vectorIP7ASwitchSaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %104) #5
  %105 = getelementptr inbounds %class.ASNetwork, ptr %10, i32 0, i32 5
  call void @_ZNSt3mapISt4pairIiiEP7ASwitchSt4lessIS1_ESaIS0_IKS1_S3_EEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %105) #5
  call void @_ZN4UnitD2Ev(ptr noundef nonnull align 8 dereferenceable(48) %10) #5
  ret void
}

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

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

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

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

; Function Attrs: nounwind
declare void @_ZN7ASwitchD1Ev(ptr noundef nonnull align 8 dereferenceable(288)) unnamed_addr #4

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

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

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

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

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

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

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

; Function Attrs: nounwind
declare void @_ZN18AccumulationBufferD1Ev(ptr noundef nonnull align 8 dereferenceable(200)) unnamed_addr #4

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i64 @_ZNKSt6vectorIP10ConnectionSaIS1_EE4sizeEv(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 @_ZNSt6vectorIP10ConnectionSaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24), i64 noundef) #2 align 2

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { nobuiltin nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #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 = { nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #5 = { nounwind }
attributes #6 = { builtin 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 = !{!"vtable pointer", !8, i64 0}
!11 = !{!12, !6, i64 8}
!12 = !{!"_ZTSSt4pairIKS_IiiEP7ASwitchE", !13, i64 0, !6, i64 8}
!13 = !{!"_ZTSSt4pairIiiE", !14, i64 0, !14, i64 4}
!14 = !{!"int", !7, i64 0}
!15 = distinct !{!15, !16}
!16 = !{!"llvm.loop.mustprogress"}
!17 = !{!18, !6, i64 8}
!18 = !{!"_ZTSSt4pairIKS_IiiEP10ConnectionE", !13, i64 0, !6, i64 8}
!19 = distinct !{!19, !16}
!20 = distinct !{!20, !16}
!21 = !{!22, !47, i64 296}
!22 = !{!"_ZTS9ASNetwork", !23, i64 0, !14, i64 48, !14, i64 52, !14, i64 56, !28, i64 64, !36, i64 112, !36, i64 136, !40, i64 160, !40, i64 208, !43, i64 256, !6, i64 280, !6, i64 288, !47, i64 296, !48, i64 300}
!23 = !{!"_ZTS13ReduceNetwork", !24, i64 0}
!24 = !{!"_ZTS4Unit", !14, i64 8, !25, i64 16}
!25 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", !26, i64 0, !27, i64 8, !7, i64 16}
!26 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_Alloc_hiderE", !6, i64 0}
!27 = !{!"long", !7, i64 0}
!28 = !{!"_ZTSSt3mapISt4pairIiiEP7ASwitchSt4lessIS1_ESaIS0_IKS1_S3_EEE", !29, i64 0}
!29 = !{!"_ZTSSt8_Rb_treeISt4pairIiiES0_IKS1_P7ASwitchESt10_Select1stIS5_ESt4lessIS1_ESaIS5_EE", !30, i64 0}
!30 = !{!"_ZTSNSt8_Rb_treeISt4pairIiiES0_IKS1_P7ASwitchESt10_Select1stIS5_ESt4lessIS1_ESaIS5_EE13_Rb_tree_implIS9_Lb1EEE", !31, i64 0, !33, i64 8}
!31 = !{!"_ZTSSt20_Rb_tree_key_compareISt4lessISt4pairIiiEEE", !32, i64 0}
!32 = !{!"_ZTSSt4lessISt4pairIiiEE"}
!33 = !{!"_ZTSSt15_Rb_tree_header", !34, i64 0, !27, i64 32}
!34 = !{!"_ZTSSt18_Rb_tree_node_base", !35, i64 0, !6, i64 8, !6, i64 16, !6, i64 24}
!35 = !{!"_ZTSSt14_Rb_tree_color", !7, i64 0}
!36 = !{!"_ZTSSt6vectorIP7ASwitchSaIS1_EE", !37, i64 0}
!37 = !{!"_ZTSSt12_Vector_baseIP7ASwitchSaIS1_EE", !38, i64 0}
!38 = !{!"_ZTSNSt12_Vector_baseIP7ASwitchSaIS1_EE12_Vector_implE", !39, i64 0}
!39 = !{!"_ZTSNSt12_Vector_baseIP7ASwitchSaIS1_EE17_Vector_impl_dataE", !6, i64 0, !6, i64 8, !6, i64 16}
!40 = !{!"_ZTSSt3mapISt4pairIiiEP10ConnectionSt4lessIS1_ESaIS0_IKS1_S3_EEE", !41, i64 0}
!41 = !{!"_ZTSSt8_Rb_treeISt4pairIiiES0_IKS1_P10ConnectionESt10_Select1stIS5_ESt4lessIS1_ESaIS5_EE", !42, i64 0}
!42 = !{!"_ZTSNSt8_Rb_treeISt4pairIiiES0_IKS1_P10ConnectionESt10_Select1stIS5_ESt4lessIS1_ESaIS5_EE13_Rb_tree_implIS9_Lb1EEE", !31, i64 0, !33, i64 8}
!43 = !{!"_ZTSSt6vectorIP10ConnectionSaIS1_EE", !44, i64 0}
!44 = !{!"_ZTSSt12_Vector_baseIP10ConnectionSaIS1_EE", !45, i64 0}
!45 = !{!"_ZTSNSt12_Vector_baseIP10ConnectionSaIS1_EE12_Vector_implE", !46, i64 0}
!46 = !{!"_ZTSNSt12_Vector_baseIP10ConnectionSaIS1_EE17_Vector_impl_dataE", !6, i64 0, !6, i64 8, !6, i64 16}
!47 = !{!"bool", !7, i64 0}
!48 = !{!"_ZTS6Config", !14, i64 0, !49, i64 4, !50, i64 8, !51, i64 24, !53, i64 40, !54, i64 64, !56, i64 72, !57, i64 96, !58, i64 104}
!49 = !{!"_ZTS15DSNetworkConfig", !14, i64 0}
!50 = !{!"_ZTS13DSwitchConfig", !14, i64 0, !14, i64 4, !14, i64 8, !14, i64 12}
!51 = !{!"_ZTS15MSNetworkConfig", !52, i64 0, !14, i64 4, !14, i64 8, !14, i64 12}
!52 = !{!"_ZTS19MultiplierNetwork_t", !7, i64 0}
!53 = !{!"_ZTS13MSwitchConfig", !14, i64 0, !14, i64 4, !14, i64 8, !14, i64 12, !14, i64 16, !14, i64 20}
!54 = !{!"_ZTS15ASNetworkConfig", !55, i64 0, !14, i64 4}
!55 = !{!"_ZTS15ReduceNetwork_t", !7, i64 0}
!56 = !{!"_ZTS13ASwitchConfig", !14, i64 0, !14, i64 4, !14, i64 8, !14, i64 12, !14, i64 16, !14, i64 20}
!57 = !{!"_ZTS17LookUpTableConfig", !14, i64 0, !14, i64 4}
!58 = !{!"_ZTS14SDMemoryConfig", !59, i64 0, !14, i64 4, !14, i64 8, !14, i64 12, !14, i64 16, !14, i64 20, !14, i64 24, !60, i64 28, !14, i64 32, !14, i64 36, !14, i64 40, !14, i64 44, !14, i64 48, !14, i64 52}
!59 = !{!"_ZTS18MemoryController_t", !7, i64 0}
!60 = !{!"_ZTS17MemoryHierarchy_t", !7, i64 0}
!61 = !{i8 0, i8 2}
!62 = !{}
!63 = !{!22, !6, i64 288}
!64 = !{!14, !14, i64 0}
!65 = distinct !{!65, !16}


; 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"

%"struct.std::_Rb_tree_iterator" = type { ptr }
%"struct.std::_Rb_tree_iterator.23" = type { ptr }

@_ZTV9ASNetwork = external dso_local unnamed_addr constant { [14 x ptr] }, align 8

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

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

; Function Attrs: nobuiltin nounwind
declare void @_ZdlPvm(ptr noundef, i64 noundef) local_unnamed_addr #1

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

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

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

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

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

; Function Attrs: mustprogress nounwind uwtable
define dso_local void @_ZN9ASNetworkD2Ev(ptr noundef nonnull align 8 dereferenceable(460) %0) unnamed_addr #2 align 2 {
  %2 = alloca %"struct.std::_Rb_tree_iterator", align 8
  %3 = alloca %"struct.std::_Rb_tree_iterator", align 8
  %4 = alloca %"struct.std::_Rb_tree_iterator.23", align 8
  %5 = alloca %"struct.std::_Rb_tree_iterator.23", align 8
  %6 = alloca %"struct.std::_Rb_tree_iterator.23", align 8
  %7 = alloca %"struct.std::_Rb_tree_iterator.23", align 8
  store ptr getelementptr inbounds inrange(-16, 96) (i8, ptr @_ZTV9ASNetwork, i64 16), ptr %0, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %2) #5
  %8 = getelementptr inbounds i8, ptr %0, i64 64
  %9 = tail call ptr @_ZNSt3mapISt4pairIiiEP7ASwitchSt4lessIS1_ESaIS0_IKS1_S3_EEE5beginEv(ptr noundef nonnull align 8 dereferenceable(48) %8) #5
  store ptr %9, ptr %2, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %3) #5
  %10 = tail call ptr @_ZNSt3mapISt4pairIiiEP7ASwitchSt4lessIS1_ESaIS0_IKS1_S3_EEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %8) #5
  store ptr %10, ptr %3, align 8
  %11 = call noundef zeroext i1 @_ZStneRKSt17_Rb_tree_iteratorISt4pairIKS0_IiiEP7ASwitchEES8_(ptr noundef nonnull align 8 dereferenceable(8) %2, ptr noundef nonnull align 8 dereferenceable(8) %3) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %3) #5
  br i1 %11, label %.lr.ph, label %._crit_edge

._crit_edge:                                      ; preds = %21, %1
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %2) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %4) #5
  %12 = getelementptr inbounds i8, ptr %0, i64 160
  %13 = call ptr @_ZNSt3mapISt4pairIiiEP10ConnectionSt4lessIS1_ESaIS0_IKS1_S3_EEE5beginEv(ptr noundef nonnull align 8 dereferenceable(48) %12) #5
  store ptr %13, ptr %4, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %5) #5
  %14 = call ptr @_ZNSt3mapISt4pairIiiEP10ConnectionSt4lessIS1_ESaIS0_IKS1_S3_EEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %12) #5
  store ptr %14, ptr %5, align 8
  %15 = call noundef zeroext i1 @_ZStneRKSt17_Rb_tree_iteratorISt4pairIKS0_IiiEP10ConnectionEES8_(ptr noundef nonnull align 8 dereferenceable(8) %4, ptr noundef nonnull align 8 dereferenceable(8) %5) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %5) #5
  br i1 %15, label %.lr.ph10, label %._crit_edge11

.lr.ph:                                           ; preds = %1, %21
  %16 = call noundef ptr @_ZNKSt17_Rb_tree_iteratorISt4pairIKS0_IiiEP7ASwitchEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %2) #5
  %17 = getelementptr inbounds i8, ptr %16, i64 8
  %18 = load ptr, ptr %17, align 8, !tbaa !8
  %19 = icmp eq ptr %18, null
  br i1 %19, label %21, label %20

20:                                               ; preds = %.lr.ph
  call void @_ZN7ASwitchD1Ev(ptr noundef nonnull align 8 dereferenceable(288) %18) #5
  call void @_ZdlPvm(ptr noundef nonnull %18, i64 noundef 288) #6
  br label %21

21:                                               ; preds = %.lr.ph, %20
  %22 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt17_Rb_tree_iteratorISt4pairIKS0_IiiEP7ASwitchEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %2) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %3) #5
  %23 = call ptr @_ZNSt3mapISt4pairIiiEP7ASwitchSt4lessIS1_ESaIS0_IKS1_S3_EEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %8) #5
  store ptr %23, ptr %3, align 8
  %24 = call noundef zeroext i1 @_ZStneRKSt17_Rb_tree_iteratorISt4pairIKS0_IiiEP7ASwitchEES8_(ptr noundef nonnull align 8 dereferenceable(8) %2, ptr noundef nonnull align 8 dereferenceable(8) %3) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %3) #5
  br i1 %24, label %.lr.ph, label %._crit_edge, !llvm.loop !14

._crit_edge11:                                    ; preds = %34, %._crit_edge
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %4) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %6) #5
  %25 = getelementptr inbounds i8, ptr %0, i64 208
  %26 = call ptr @_ZNSt3mapISt4pairIiiEP10ConnectionSt4lessIS1_ESaIS0_IKS1_S3_EEE5beginEv(ptr noundef nonnull align 8 dereferenceable(48) %25) #5
  store ptr %26, ptr %6, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %7) #5
  %27 = call ptr @_ZNSt3mapISt4pairIiiEP10ConnectionSt4lessIS1_ESaIS0_IKS1_S3_EEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %25) #5
  store ptr %27, ptr %7, align 8
  %28 = call noundef zeroext i1 @_ZStneRKSt17_Rb_tree_iteratorISt4pairIKS0_IiiEP10ConnectionEES8_(ptr noundef nonnull align 8 dereferenceable(8) %6, ptr noundef nonnull align 8 dereferenceable(8) %7) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #5
  br i1 %28, label %.lr.ph13, label %._crit_edge14

.lr.ph10:                                         ; preds = %._crit_edge, %34
  %29 = call noundef ptr @_ZNKSt17_Rb_tree_iteratorISt4pairIKS0_IiiEP10ConnectionEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %4) #5
  %30 = getelementptr inbounds i8, ptr %29, i64 8
  %31 = load ptr, ptr %30, align 8, !tbaa !16
  %32 = icmp eq ptr %31, null
  br i1 %32, label %34, label %33

33:                                               ; preds = %.lr.ph10
  call void @_ZN10ConnectionD2Ev(ptr noundef nonnull align 8 dereferenceable(64) %31) #5
  call void @_ZdlPvm(ptr noundef nonnull %31, i64 noundef 64) #6
  br label %34

34:                                               ; preds = %.lr.ph10, %33
  %35 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt17_Rb_tree_iteratorISt4pairIKS0_IiiEP10ConnectionEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %4) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %5) #5
  %36 = call ptr @_ZNSt3mapISt4pairIiiEP10ConnectionSt4lessIS1_ESaIS0_IKS1_S3_EEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %12) #5
  store ptr %36, ptr %5, align 8
  %37 = call noundef zeroext i1 @_ZStneRKSt17_Rb_tree_iteratorISt4pairIKS0_IiiEP10ConnectionEES8_(ptr noundef nonnull align 8 dereferenceable(8) %4, ptr noundef nonnull align 8 dereferenceable(8) %5) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %5) #5
  br i1 %37, label %.lr.ph10, label %._crit_edge11, !llvm.loop !18

._crit_edge14:                                    ; preds = %46, %._crit_edge11
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #5
  %38 = getelementptr inbounds i8, ptr %0, i64 296
  %39 = load i8, ptr %38, align 8, !tbaa !19, !range !59, !noundef !60
  %40 = trunc nuw i8 %39 to i1
  br i1 %40, label %50, label %.loopexit

.lr.ph13:                                         ; preds = %._crit_edge11, %46
  %41 = call noundef ptr @_ZNKSt17_Rb_tree_iteratorISt4pairIKS0_IiiEP10ConnectionEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %6) #5
  %42 = getelementptr inbounds i8, ptr %41, i64 8
  %43 = load ptr, ptr %42, align 8, !tbaa !16
  %44 = icmp eq ptr %43, null
  br i1 %44, label %46, label %45

45:                                               ; preds = %.lr.ph13
  call void @_ZN10ConnectionD2Ev(ptr noundef nonnull align 8 dereferenceable(64) %43) #5
  call void @_ZdlPvm(ptr noundef nonnull %43, i64 noundef 64) #6
  br label %46

46:                                               ; preds = %.lr.ph13, %45
  %47 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt17_Rb_tree_iteratorISt4pairIKS0_IiiEP10ConnectionEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %6) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %7) #5
  %48 = call ptr @_ZNSt3mapISt4pairIiiEP10ConnectionSt4lessIS1_ESaIS0_IKS1_S3_EEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %25) #5
  store ptr %48, ptr %7, align 8
  %49 = call noundef zeroext i1 @_ZStneRKSt17_Rb_tree_iteratorISt4pairIKS0_IiiEP10ConnectionEES8_(ptr noundef nonnull align 8 dereferenceable(8) %6, ptr noundef nonnull align 8 dereferenceable(8) %7) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #5
  br i1 %49, label %.lr.ph13, label %._crit_edge14, !llvm.loop !61

50:                                               ; preds = %._crit_edge14
  %51 = getelementptr inbounds i8, ptr %0, i64 288
  %52 = load ptr, ptr %51, align 8, !tbaa !62
  %53 = icmp eq ptr %52, null
  br i1 %53, label %55, label %54

54:                                               ; preds = %50
  call void @_ZN18AccumulationBufferD1Ev(ptr noundef nonnull align 8 dereferenceable(200) %52) #5
  call void @_ZdlPvm(ptr noundef nonnull %52, i64 noundef 200) #6
  br label %55

55:                                               ; preds = %54, %50
  %56 = getelementptr inbounds i8, ptr %0, i64 256
  %57 = call noundef i64 @_ZNKSt6vectorIP10ConnectionSaIS1_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %56) #5
  %.not = icmp eq i64 %57, 0
  br i1 %.not, label %.loopexit, label %.lr.ph17

.lr.ph17:                                         ; preds = %55, %62
  %indvars.iv = phi i64 [ %indvars.iv.next, %62 ], [ 0, %55 ]
  %58 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIP10ConnectionSaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %56, i64 noundef %indvars.iv) #5
  %59 = load ptr, ptr %58, align 8, !tbaa !63
  %60 = icmp eq ptr %59, null
  br i1 %60, label %62, label %61

61:                                               ; preds = %.lr.ph17
  call void @_ZN10ConnectionD2Ev(ptr noundef nonnull align 8 dereferenceable(64) %59) #5
  call void @_ZdlPvm(ptr noundef nonnull %59, i64 noundef 64) #6
  br label %62

62:                                               ; preds = %.lr.ph17, %61
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %63 = call noundef i64 @_ZNKSt6vectorIP10ConnectionSaIS1_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %56) #5
  %64 = icmp ugt i64 %63, %indvars.iv.next
  br i1 %64, label %.lr.ph17, label %.loopexit, !llvm.loop !64

.loopexit:                                        ; preds = %62, %55, %._crit_edge14
  %65 = getelementptr inbounds i8, ptr %0, i64 256
  call void @_ZNSt6vectorIP10ConnectionSaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %65) #5
  call void @_ZNSt3mapISt4pairIiiEP10ConnectionSt4lessIS1_ESaIS0_IKS1_S3_EEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %25) #5
  call void @_ZNSt3mapISt4pairIiiEP10ConnectionSt4lessIS1_ESaIS0_IKS1_S3_EEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %12) #5
  %66 = getelementptr inbounds i8, ptr %0, i64 136
  call void @_ZNSt6vectorIP7ASwitchSaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %66) #5
  %67 = getelementptr inbounds i8, ptr %0, i64 112
  call void @_ZNSt6vectorIP7ASwitchSaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %67) #5
  call void @_ZNSt3mapISt4pairIiiEP7ASwitchSt4lessIS1_ESaIS0_IKS1_S3_EEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %8) #5
  call void @_ZN4UnitD2Ev(ptr noundef nonnull align 8 dereferenceable(48) %0) #5
  ret void
}

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

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

; Function Attrs: nounwind
declare void @_ZN7ASwitchD1Ev(ptr noundef nonnull align 8 dereferenceable(288)) unnamed_addr #4

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

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

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

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

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

; Function Attrs: nounwind
declare void @_ZN18AccumulationBufferD1Ev(ptr noundef nonnull align 8 dereferenceable(200)) unnamed_addr #4

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i64 @_ZNKSt6vectorIP10ConnectionSaIS1_EE4sizeEv(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 @_ZNSt6vectorIP10ConnectionSaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24), i64 noundef) local_unnamed_addr #2 align 2

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { nobuiltin nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #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 = { nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #5 = { nounwind }
attributes #6 = { builtin 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 = !{!"vtable pointer", !7, i64 0}
!7 = !{!"Simple C++ TBAA"}
!8 = !{!9, !13, i64 8}
!9 = !{!"_ZTSSt4pairIKS_IiiEP7ASwitchE", !10, i64 0, !13, i64 8}
!10 = !{!"_ZTSSt4pairIiiE", !11, i64 0, !11, i64 4}
!11 = !{!"int", !12, i64 0}
!12 = !{!"omnipotent char", !7, i64 0}
!13 = !{!"any pointer", !12, i64 0}
!14 = distinct !{!14, !15}
!15 = !{!"llvm.loop.mustprogress"}
!16 = !{!17, !13, i64 8}
!17 = !{!"_ZTSSt4pairIKS_IiiEP10ConnectionE", !10, i64 0, !13, i64 8}
!18 = distinct !{!18, !15}
!19 = !{!20, !45, i64 296}
!20 = !{!"_ZTS9ASNetwork", !21, i64 0, !11, i64 48, !11, i64 52, !11, i64 56, !26, i64 64, !34, i64 112, !34, i64 136, !38, i64 160, !38, i64 208, !41, i64 256, !13, i64 280, !13, i64 288, !45, i64 296, !46, i64 300}
!21 = !{!"_ZTS13ReduceNetwork", !22, i64 0}
!22 = !{!"_ZTS4Unit", !11, i64 8, !23, i64 16}
!23 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", !24, i64 0, !25, i64 8, !12, i64 16}
!24 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_Alloc_hiderE", !13, i64 0}
!25 = !{!"long", !12, i64 0}
!26 = !{!"_ZTSSt3mapISt4pairIiiEP7ASwitchSt4lessIS1_ESaIS0_IKS1_S3_EEE", !27, i64 0}
!27 = !{!"_ZTSSt8_Rb_treeISt4pairIiiES0_IKS1_P7ASwitchESt10_Select1stIS5_ESt4lessIS1_ESaIS5_EE", !28, i64 0}
!28 = !{!"_ZTSNSt8_Rb_treeISt4pairIiiES0_IKS1_P7ASwitchESt10_Select1stIS5_ESt4lessIS1_ESaIS5_EE13_Rb_tree_implIS9_Lb1EEE", !29, i64 0, !31, i64 8}
!29 = !{!"_ZTSSt20_Rb_tree_key_compareISt4lessISt4pairIiiEEE", !30, i64 0}
!30 = !{!"_ZTSSt4lessISt4pairIiiEE"}
!31 = !{!"_ZTSSt15_Rb_tree_header", !32, i64 0, !25, i64 32}
!32 = !{!"_ZTSSt18_Rb_tree_node_base", !33, i64 0, !13, i64 8, !13, i64 16, !13, i64 24}
!33 = !{!"_ZTSSt14_Rb_tree_color", !12, i64 0}
!34 = !{!"_ZTSSt6vectorIP7ASwitchSaIS1_EE", !35, i64 0}
!35 = !{!"_ZTSSt12_Vector_baseIP7ASwitchSaIS1_EE", !36, i64 0}
!36 = !{!"_ZTSNSt12_Vector_baseIP7ASwitchSaIS1_EE12_Vector_implE", !37, i64 0}
!37 = !{!"_ZTSNSt12_Vector_baseIP7ASwitchSaIS1_EE17_Vector_impl_dataE", !13, i64 0, !13, i64 8, !13, i64 16}
!38 = !{!"_ZTSSt3mapISt4pairIiiEP10ConnectionSt4lessIS1_ESaIS0_IKS1_S3_EEE", !39, i64 0}
!39 = !{!"_ZTSSt8_Rb_treeISt4pairIiiES0_IKS1_P10ConnectionESt10_Select1stIS5_ESt4lessIS1_ESaIS5_EE", !40, i64 0}
!40 = !{!"_ZTSNSt8_Rb_treeISt4pairIiiES0_IKS1_P10ConnectionESt10_Select1stIS5_ESt4lessIS1_ESaIS5_EE13_Rb_tree_implIS9_Lb1EEE", !29, i64 0, !31, i64 8}
!41 = !{!"_ZTSSt6vectorIP10ConnectionSaIS1_EE", !42, i64 0}
!42 = !{!"_ZTSSt12_Vector_baseIP10ConnectionSaIS1_EE", !43, i64 0}
!43 = !{!"_ZTSNSt12_Vector_baseIP10ConnectionSaIS1_EE12_Vector_implE", !44, i64 0}
!44 = !{!"_ZTSNSt12_Vector_baseIP10ConnectionSaIS1_EE17_Vector_impl_dataE", !13, i64 0, !13, i64 8, !13, i64 16}
!45 = !{!"bool", !12, i64 0}
!46 = !{!"_ZTS6Config", !11, i64 0, !47, i64 4, !48, i64 8, !49, i64 24, !51, i64 40, !52, i64 64, !54, i64 72, !55, i64 96, !56, i64 104}
!47 = !{!"_ZTS15DSNetworkConfig", !11, i64 0}
!48 = !{!"_ZTS13DSwitchConfig", !11, i64 0, !11, i64 4, !11, i64 8, !11, i64 12}
!49 = !{!"_ZTS15MSNetworkConfig", !50, i64 0, !11, i64 4, !11, i64 8, !11, i64 12}
!50 = !{!"_ZTS19MultiplierNetwork_t", !12, i64 0}
!51 = !{!"_ZTS13MSwitchConfig", !11, i64 0, !11, i64 4, !11, i64 8, !11, i64 12, !11, i64 16, !11, i64 20}
!52 = !{!"_ZTS15ASNetworkConfig", !53, i64 0, !11, i64 4}
!53 = !{!"_ZTS15ReduceNetwork_t", !12, i64 0}
!54 = !{!"_ZTS13ASwitchConfig", !11, i64 0, !11, i64 4, !11, i64 8, !11, i64 12, !11, i64 16, !11, i64 20}
!55 = !{!"_ZTS17LookUpTableConfig", !11, i64 0, !11, i64 4}
!56 = !{!"_ZTS14SDMemoryConfig", !57, i64 0, !11, i64 4, !11, i64 8, !11, i64 12, !11, i64 16, !11, i64 20, !11, i64 24, !58, i64 28, !11, i64 32, !11, i64 36, !11, i64 40, !11, i64 44, !11, i64 48, !11, i64 52}
!57 = !{!"_ZTS18MemoryController_t", !12, i64 0}
!58 = !{!"_ZTS17MemoryHierarchy_t", !12, i64 0}
!59 = !{i8 0, i8 2}
!60 = !{}
!61 = distinct !{!61, !15}
!62 = !{!20, !13, i64 288}
!63 = !{!13, !13, i64 0}
!64 = distinct !{!64, !15}


; Effective O3 passes: CorrelatedValuePropagationPass,EarlyCSEPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferFunctionAttrsPass,InstCombinePass,JumpThreadingPass,LICMPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,SROAPass,SimplifyCFGPass,TailCallElimPass