; LLVM IR from ImperialCollegeLondon/pnflow :: src/pnm/pnflow/psPrc (netStatistics)

; Unoptimized IR (clang -disable-llvm-passes):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

%"class.std::basic_ostream" = type { ptr, %"class.std::basic_ios" }
%"class.std::basic_ios" = type { %"class.std::ios_base", ptr, i8, i8, ptr, ptr, ptr, ptr }
%"class.std::ios_base" = type { ptr, i64, i64, i32, i32, i32, ptr, %"struct.std::ios_base::_Words", [8 x %"struct.std::ios_base::_Words"], i32, ptr, %"class.std::locale" }
%"struct.std::ios_base::_Words" = type { ptr, i64 }
%"class.std::locale" = type { ptr }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<const Elem *, std::allocator<const Elem *>>::_Vector_impl" }
%"struct.std::_Vector_base<const Elem *, std::allocator<const Elem *>>::_Vector_impl" = type { %"struct.std::_Vector_base<const Elem *, std::allocator<const Elem *>>::_Vector_impl_data" }
%"struct.std::_Vector_base<const Elem *, std::allocator<const Elem *>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.__gnu_cxx::__normal_iterator" = type { ptr }
%"class.std::allocator" = type { i8 }
%"class.__gnu_cxx::__normal_iterator.0" = type { ptr }
%class.ElemGCmpRed = type { i8 }

@_ZSt4cout = external global %"class.std::basic_ostream", align 8
@.str.4 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.16 = external hidden unnamed_addr constant [16 x i8], align 1
@.str.17 = external hidden unnamed_addr constant [16 x i8], align 1
@.str.18 = external hidden unnamed_addr constant [17 x i8], align 1

; Function Attrs: inlinehint mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef) #0

; 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 ptr @_ZNKSt6vectorIPK4ElemSaIS2_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24)) #2 align 2

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

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

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

declare i32 @__gxx_personality_v0(...)

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

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

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

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

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

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

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare double @llvm.fmuladd.f64(double, double, double) #4

; Function Attrs: mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEd(ptr noundef nonnull align 8 dereferenceable(8), double noundef) #3 align 2

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

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

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

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

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

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

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZSt4sortIN9__gnu_cxx17__normal_iteratorIPPK4ElemSt6vectorIS4_SaIS4_EEEE11ElemGCmpRedEvT_SB_T0_(ptr, ptr) #0

; Function Attrs: mustprogress uwtable
define dso_local void @_Z24printCornerNumStatisticsRKSt6vectorIPK4ElemSaIS2_EEii(ptr noundef nonnull align 8 dereferenceable(24) %0, i32 noundef %1, i32 noundef %2) #3 personality ptr @__gxx_personality_v0 {
  %4 = alloca ptr, align 8
  %5 = alloca i32, align 4
  %6 = alloca i32, align 4
  %7 = alloca %"class.std::vector", align 8
  %8 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %9 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %10 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %11 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %12 = alloca %"class.std::allocator", align 1
  %13 = alloca ptr, align 8
  %14 = alloca i32, align 4
  %15 = alloca %"class.__gnu_cxx::__normal_iterator.0", align 8
  %16 = alloca %"class.__gnu_cxx::__normal_iterator.0", align 8
  %17 = alloca %class.ElemGCmpRed, align 1
  %18 = alloca double, align 8
  %19 = alloca double, align 8
  %20 = alloca double, align 8
  %21 = alloca i64, align 8
  %22 = alloca double, align 8
  %23 = alloca %"class.std::vector", align 8
  %24 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %25 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %26 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %27 = alloca %"class.std::allocator", align 1
  %28 = alloca %"class.__gnu_cxx::__normal_iterator.0", align 8
  %29 = alloca %"class.__gnu_cxx::__normal_iterator.0", align 8
  %30 = alloca %class.ElemGCmpRed, align 1
  %31 = alloca double, align 8
  %32 = alloca double, align 8
  %33 = alloca double, align 8
  %34 = alloca i64, align 8
  %35 = alloca double, align 8
  %36 = alloca %"class.std::vector", align 8
  %37 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %38 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %39 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %40 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %41 = alloca %"class.std::allocator", align 1
  %42 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %43 = alloca %"class.__gnu_cxx::__normal_iterator.0", align 8
  %44 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %45 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %46 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %47 = alloca %"class.__gnu_cxx::__normal_iterator.0", align 8
  %48 = alloca %"class.__gnu_cxx::__normal_iterator.0", align 8
  %49 = alloca %"class.__gnu_cxx::__normal_iterator.0", align 8
  %50 = alloca %class.ElemGCmpRed, align 1
  %51 = alloca double, align 8
  %52 = alloca double, align 8
  %53 = alloca double, align 8
  %54 = alloca i64, align 8
  store ptr %0, ptr %4, align 8, !tbaa !5
  store i32 %1, ptr %5, align 4, !tbaa !9
  store i32 %2, ptr %6, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 24, ptr %7) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %9) #5
  %55 = load ptr, ptr %4, align 8, !tbaa !5
  %56 = call ptr @_ZNKSt6vectorIPK4ElemSaIS2_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %55) #5
  %57 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %9, i32 0, i32 0
  store ptr %56, ptr %57, align 8
  %58 = load i32, ptr %5, align 4, !tbaa !9
  %59 = sext i32 %58 to i64
  %60 = call ptr @_ZNK9__gnu_cxx17__normal_iteratorIPKPK4ElemSt6vectorIS3_SaIS3_EEEplEl(ptr noundef nonnull align 8 dereferenceable(8) %9, i64 noundef %59) #5
  %61 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %8, i32 0, i32 0
  store ptr %60, ptr %61, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #5
  %62 = load ptr, ptr %4, align 8, !tbaa !5
  %63 = call ptr @_ZNKSt6vectorIPK4ElemSaIS2_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %62) #5
  %64 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %11, i32 0, i32 0
  store ptr %63, ptr %64, align 8
  %65 = load i32, ptr %6, align 4, !tbaa !9
  %66 = sext i32 %65 to i64
  %67 = call ptr @_ZNK9__gnu_cxx17__normal_iteratorIPKPK4ElemSt6vectorIS3_SaIS3_EEEplEl(ptr noundef nonnull align 8 dereferenceable(8) %11, i64 noundef %66) #5
  %68 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %10, i32 0, i32 0
  store ptr %67, ptr %68, align 8
  call void @llvm.lifetime.start.p0(i64 1, ptr %12) #5
  call void @_ZNSaIPK4ElemEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %12) #5
  %69 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %8, i32 0, i32 0
  %70 = load ptr, ptr %69, align 8
  %71 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %10, i32 0, i32 0
  %72 = load ptr, ptr %71, align 8
  invoke void @_ZNSt6vectorIPK4ElemSaIS2_EEC2IN9__gnu_cxx17__normal_iteratorIPKS2_S4_EEvEET_SB_RKS3_(ptr noundef nonnull align 8 dereferenceable(24) %7, ptr %70, ptr %72, ptr noundef nonnull align 1 dereferenceable(1) %12)
          to label %73 unwind label %88

73:                                               ; preds = %3
  call void @_ZNSt15__new_allocatorIPK4ElemED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %12) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr %12) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #5
  %74 = call ptr @_ZNSt6vectorIPK4ElemSaIS2_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %7) #5
  %75 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator.0", ptr %15, i32 0, i32 0
  store ptr %74, ptr %75, align 8
  %76 = call ptr @_ZNSt6vectorIPK4ElemSaIS2_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %7) #5
  %77 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator.0", ptr %16, i32 0, i32 0
  store ptr %76, ptr %77, align 8
  %78 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator.0", ptr %15, i32 0, i32 0
  %79 = load ptr, ptr %78, align 8
  %80 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator.0", ptr %16, i32 0, i32 0
  %81 = load ptr, ptr %80, align 8
  invoke void @_ZSt4sortIN9__gnu_cxx17__normal_iteratorIPPK4ElemSt6vectorIS4_SaIS4_EEEE11ElemGCmpRedEvT_SB_T0_(ptr %79, ptr %81)
          to label %82 unwind label %92

82:                                               ; preds = %73
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #5
  store double 0.000000e+00, ptr %18, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 8, ptr %19) #5
  store double 0.000000e+00, ptr %19, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 8, ptr %20) #5
  store double 0.000000e+00, ptr %20, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 8, ptr %21) #5
  store i64 0, ptr %21, align 8, !tbaa !13
  br label %83

83:                                               ; preds = %135, %82
  %84 = load i64, ptr %21, align 8, !tbaa !13
  %85 = call noundef i64 @_ZNKSt6vectorIPK4ElemSaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %7) #5
  %86 = icmp ult i64 %84, %85
  br i1 %86, label %96, label %87

87:                                               ; preds = %83
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #5
  br label %142

88:                                               ; preds = %3
  %89 = landingpad { ptr, i32 }
          cleanup
  %90 = extractvalue { ptr, i32 } %89, 0
  store ptr %90, ptr %13, align 8
  %91 = extractvalue { ptr, i32 } %89, 1
  store i32 %91, ptr %14, align 4
  call void @_ZNSt15__new_allocatorIPK4ElemED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %12) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr %12) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #5
  br label %205

92:                                               ; preds = %73
  %93 = landingpad { ptr, i32 }
          cleanup
  %94 = extractvalue { ptr, i32 } %93, 0
  store ptr %94, ptr %13, align 8
  %95 = extractvalue { ptr, i32 } %93, 1
  store i32 %95, ptr %14, align 4
  br label %204

96:                                               ; preds = %83
  %97 = load i64, ptr %21, align 8, !tbaa !13
  %98 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPK4ElemSaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef %97) #5
  %99 = load ptr, ptr %98, align 8, !tbaa !5
  %100 = invoke noundef double @_ZNK4Elem10flowVolumeEv(ptr noundef nonnull align 8 dereferenceable(408) %99)
          to label %101 unwind label %138

101:                                              ; preds = %96
  %102 = load double, ptr %20, align 8, !tbaa !11
  %103 = fadd double %102, %100
  store double %103, ptr %20, align 8, !tbaa !11
  %104 = load i64, ptr %21, align 8, !tbaa !13
  %105 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPK4ElemSaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef %104) #5
  %106 = load ptr, ptr %105, align 8, !tbaa !5
  %107 = invoke noundef double @_ZNK4Elem10flowVolumeEv(ptr noundef nonnull align 8 dereferenceable(408) %106)
          to label %108 unwind label %138

108:                                              ; preds = %101
  %109 = load i64, ptr %21, align 8, !tbaa !13
  %110 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPK4ElemSaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef %109) #5
  %111 = load ptr, ptr %110, align 8, !tbaa !5
  %112 = invoke noundef ptr @_ZNK4Elem5modelEv(ptr noundef nonnull align 8 dereferenceable(408) %111)
          to label %113 unwind label %138

113:                                              ; preds = %108
  %114 = load ptr, ptr %112, align 8, !tbaa !15
  %115 = getelementptr inbounds ptr, ptr %114, i64 24
  %116 = load ptr, ptr %115, align 8
  %117 = invoke noundef i32 %116(ptr noundef nonnull align 8 dereferenceable(152) %112)
          to label %118 unwind label %138

118:                                              ; preds = %113
  %119 = sitofp i32 %117 to double
  %120 = load double, ptr %19, align 8, !tbaa !11
  %121 = call double @llvm.fmuladd.f64(double %107, double %119, double %120)
  store double %121, ptr %19, align 8, !tbaa !11
  %122 = load i64, ptr %21, align 8, !tbaa !13
  %123 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPK4ElemSaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef %122) #5
  %124 = load ptr, ptr %123, align 8, !tbaa !5
  %125 = invoke noundef ptr @_ZNK4Elem5modelEv(ptr noundef nonnull align 8 dereferenceable(408) %124)
          to label %126 unwind label %138

126:                                              ; preds = %118
  %127 = load ptr, ptr %125, align 8, !tbaa !15
  %128 = getelementptr inbounds ptr, ptr %127, i64 24
  %129 = load ptr, ptr %128, align 8
  %130 = invoke noundef i32 %129(ptr noundef nonnull align 8 dereferenceable(152) %125)
          to label %131 unwind label %138

131:                                              ; preds = %126
  %132 = sitofp i32 %130 to double
  %133 = load double, ptr %18, align 8, !tbaa !11
  %134 = fadd double %133, %132
  store double %134, ptr %18, align 8, !tbaa !11
  br label %135

135:                                              ; preds = %131
  %136 = load i64, ptr %21, align 8, !tbaa !13
  %137 = add i64 %136, 1
  store i64 %137, ptr %21, align 8, !tbaa !13
  br label %83, !llvm.loop !17

138:                                              ; preds = %126, %118, %113, %108, %101, %96
  %139 = landingpad { ptr, i32 }
          cleanup
  %140 = extractvalue { ptr, i32 } %139, 0
  store ptr %140, ptr %13, align 8
  %141 = extractvalue { ptr, i32 } %139, 1
  store i32 %141, ptr %14, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #5
  br label %203

142:                                              ; preds = %87
  %143 = load double, ptr %18, align 8, !tbaa !11
  %144 = load i32, ptr %6, align 4, !tbaa !9
  %145 = load i32, ptr %5, align 4, !tbaa !9
  %146 = sub nsw i32 %144, %145
  %147 = sitofp i32 %146 to double
  %148 = fdiv double %143, %147
  store double %148, ptr %18, align 8, !tbaa !11
  %149 = load double, ptr %19, align 8, !tbaa !11
  %150 = load double, ptr %20, align 8, !tbaa !11
  %151 = fdiv double %149, %150
  store double %151, ptr %19, align 8, !tbaa !11
  %152 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, ptr noundef @.str.16)
          to label %153 unwind label %199

153:                                              ; preds = %142
  %154 = load double, ptr %18, align 8, !tbaa !11
  %155 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEd(ptr noundef nonnull align 8 dereferenceable(8) %152, double noundef %154)
          to label %156 unwind label %199

156:                                              ; preds = %153
  %157 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %155, ptr noundef @.str.4)
          to label %158 unwind label %199

158:                                              ; preds = %156
  %159 = load double, ptr %19, align 8, !tbaa !11
  %160 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEd(ptr noundef nonnull align 8 dereferenceable(8) %157, double noundef %159)
          to label %161 unwind label %199

161:                                              ; preds = %158
  %162 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSoS_E(ptr noundef nonnull align 8 dereferenceable(8) %160, ptr noundef @_ZSt4endlIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_)
          to label %163 unwind label %199

163:                                              ; preds = %161
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #5
  call void @_ZNSt6vectorIPK4ElemSaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %7) #5
  call void @llvm.lifetime.end.p0(i64 24, ptr %7) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %22) #5
  %164 = load ptr, ptr %4, align 8, !tbaa !5
  %165 = call noundef i64 @_ZNKSt6vectorIPK4ElemSaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %164) #5
  %166 = load i32, ptr %6, align 4, !tbaa !9
  %167 = sext i32 %166 to i64
  %168 = sub i64 %165, %167
  %169 = uitofp i64 %168 to double
  store double %169, ptr %22, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 24, ptr %23) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %25) #5
  %170 = load ptr, ptr %4, align 8, !tbaa !5
  %171 = call ptr @_ZNKSt6vectorIPK4ElemSaIS2_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %170) #5
  %172 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %25, i32 0, i32 0
  store ptr %171, ptr %172, align 8
  %173 = load i32, ptr %6, align 4, !tbaa !9
  %174 = sext i32 %173 to i64
  %175 = call ptr @_ZNK9__gnu_cxx17__normal_iteratorIPKPK4ElemSt6vectorIS3_SaIS3_EEEplEl(ptr noundef nonnull align 8 dereferenceable(8) %25, i64 noundef %174) #5
  %176 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %24, i32 0, i32 0
  store ptr %175, ptr %176, align 8
  %177 = load ptr, ptr %4, align 8, !tbaa !5
  %178 = call ptr @_ZNKSt6vectorIPK4ElemSaIS2_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %177) #5
  %179 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %26, i32 0, i32 0
  store ptr %178, ptr %179, align 8
  call void @llvm.lifetime.start.p0(i64 1, ptr %27) #5
  call void @_ZNSaIPK4ElemEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %27) #5
  %180 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %24, i32 0, i32 0
  %181 = load ptr, ptr %180, align 8
  %182 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %26, i32 0, i32 0
  %183 = load ptr, ptr %182, align 8
  invoke void @_ZNSt6vectorIPK4ElemSaIS2_EEC2IN9__gnu_cxx17__normal_iteratorIPKS2_S4_EEvEET_SB_RKS3_(ptr noundef nonnull align 8 dereferenceable(24) %23, ptr %181, ptr %183, ptr noundef nonnull align 1 dereferenceable(1) %27)
          to label %184 unwind label %206

184:                                              ; preds = %163
  call void @_ZNSt15__new_allocatorIPK4ElemED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %27) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr %27) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %25) #5
  %185 = call ptr @_ZNSt6vectorIPK4ElemSaIS2_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %23) #5
  %186 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator.0", ptr %28, i32 0, i32 0
  store ptr %185, ptr %186, align 8
  %187 = call ptr @_ZNSt6vectorIPK4ElemSaIS2_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %23) #5
  %188 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator.0", ptr %29, i32 0, i32 0
  store ptr %187, ptr %188, align 8
  %189 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator.0", ptr %28, i32 0, i32 0
  %190 = load ptr, ptr %189, align 8
  %191 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator.0", ptr %29, i32 0, i32 0
  %192 = load ptr, ptr %191, align 8
  invoke void @_ZSt4sortIN9__gnu_cxx17__normal_iteratorIPPK4ElemSt6vectorIS4_SaIS4_EEEE11ElemGCmpRedEvT_SB_T0_(ptr %190, ptr %192)
          to label %193 unwind label %210

193:                                              ; preds = %184
  call void @llvm.lifetime.start.p0(i64 8, ptr %31) #5
  store double 0.000000e+00, ptr %31, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 8, ptr %32) #5
  store double 0.000000e+00, ptr %32, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 8, ptr %33) #5
  store double 0.000000e+00, ptr %33, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 8, ptr %34) #5
  store i64 0, ptr %34, align 8, !tbaa !13
  br label %194

194:                                              ; preds = %253, %193
  %195 = load i64, ptr %34, align 8, !tbaa !13
  %196 = call noundef i64 @_ZNKSt6vectorIPK4ElemSaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %23) #5
  %197 = icmp ult i64 %195, %196
  br i1 %197, label %214, label %198

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

199:                                              ; preds = %161, %158, %156, %153, %142
  %200 = landingpad { ptr, i32 }
          cleanup
  %201 = extractvalue { ptr, i32 } %200, 0
  store ptr %201, ptr %13, align 8
  %202 = extractvalue { ptr, i32 } %200, 1
  store i32 %202, ptr %14, align 4
  br label %203

203:                                              ; preds = %199, %138
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #5
  br label %204

204:                                              ; preds = %203, %92
  call void @_ZNSt6vectorIPK4ElemSaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %7) #5
  br label %205

205:                                              ; preds = %204, %88
  call void @llvm.lifetime.end.p0(i64 24, ptr %7) #5
  br label %430

206:                                              ; preds = %163
  %207 = landingpad { ptr, i32 }
          cleanup
  %208 = extractvalue { ptr, i32 } %207, 0
  store ptr %208, ptr %13, align 8
  %209 = extractvalue { ptr, i32 } %207, 1
  store i32 %209, ptr %14, align 4
  call void @_ZNSt15__new_allocatorIPK4ElemED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %27) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr %27) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %25) #5
  br label %345

210:                                              ; preds = %184
  %211 = landingpad { ptr, i32 }
          cleanup
  %212 = extractvalue { ptr, i32 } %211, 0
  store ptr %212, ptr %13, align 8
  %213 = extractvalue { ptr, i32 } %211, 1
  store i32 %213, ptr %14, align 4
  br label %344

214:                                              ; preds = %194
  %215 = load i64, ptr %34, align 8, !tbaa !13
  %216 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPK4ElemSaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %23, i64 noundef %215) #5
  %217 = load ptr, ptr %216, align 8, !tbaa !5
  %218 = invoke noundef double @_ZNK4Elem10flowVolumeEv(ptr noundef nonnull align 8 dereferenceable(408) %217)
          to label %219 unwind label %256

219:                                              ; preds = %214
  %220 = load double, ptr %33, align 8, !tbaa !11
  %221 = fadd double %220, %218
  store double %221, ptr %33, align 8, !tbaa !11
  %222 = load i64, ptr %34, align 8, !tbaa !13
  %223 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPK4ElemSaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %23, i64 noundef %222) #5
  %224 = load ptr, ptr %223, align 8, !tbaa !5
  %225 = invoke noundef double @_ZNK4Elem10flowVolumeEv(ptr noundef nonnull align 8 dereferenceable(408) %224)
          to label %226 unwind label %256

226:                                              ; preds = %219
  %227 = load i64, ptr %34, align 8, !tbaa !13
  %228 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPK4ElemSaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %23, i64 noundef %227) #5
  %229 = load ptr, ptr %228, align 8, !tbaa !5
  %230 = invoke noundef ptr @_ZNK4Elem5modelEv(ptr noundef nonnull align 8 dereferenceable(408) %229)
          to label %231 unwind label %256

231:                                              ; preds = %226
  %232 = load ptr, ptr %230, align 8, !tbaa !15
  %233 = getelementptr inbounds ptr, ptr %232, i64 24
  %234 = load ptr, ptr %233, align 8
  %235 = invoke noundef i32 %234(ptr noundef nonnull align 8 dereferenceable(152) %230)
          to label %236 unwind label %256

236:                                              ; preds = %231
  %237 = sitofp i32 %235 to double
  %238 = load double, ptr %32, align 8, !tbaa !11
  %239 = call double @llvm.fmuladd.f64(double %225, double %237, double %238)
  store double %239, ptr %32, align 8, !tbaa !11
  %240 = load i64, ptr %34, align 8, !tbaa !13
  %241 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPK4ElemSaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %23, i64 noundef %240) #5
  %242 = load ptr, ptr %241, align 8, !tbaa !5
  %243 = invoke noundef ptr @_ZNK4Elem5modelEv(ptr noundef nonnull align 8 dereferenceable(408) %242)
          to label %244 unwind label %256

244:                                              ; preds = %236
  %245 = load ptr, ptr %243, align 8, !tbaa !15
  %246 = getelementptr inbounds ptr, ptr %245, i64 24
  %247 = load ptr, ptr %246, align 8
  %248 = invoke noundef i32 %247(ptr noundef nonnull align 8 dereferenceable(152) %243)
          to label %249 unwind label %256

249:                                              ; preds = %244
  %250 = sitofp i32 %248 to double
  %251 = load double, ptr %31, align 8, !tbaa !11
  %252 = fadd double %251, %250
  store double %252, ptr %31, align 8, !tbaa !11
  br label %253

253:                                              ; preds = %249
  %254 = load i64, ptr %34, align 8, !tbaa !13
  %255 = add i64 %254, 1
  store i64 %255, ptr %34, align 8, !tbaa !13
  br label %194, !llvm.loop !19

256:                                              ; preds = %244, %236, %231, %226, %219, %214
  %257 = landingpad { ptr, i32 }
          cleanup
  %258 = extractvalue { ptr, i32 } %257, 0
  store ptr %258, ptr %13, align 8
  %259 = extractvalue { ptr, i32 } %257, 1
  store i32 %259, ptr %14, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %34) #5
  br label %343

260:                                              ; preds = %198
  %261 = load double, ptr %31, align 8, !tbaa !11
  %262 = load double, ptr %22, align 8, !tbaa !11
  %263 = fdiv double %261, %262
  store double %263, ptr %31, align 8, !tbaa !11
  %264 = load double, ptr %32, align 8, !tbaa !11
  %265 = load double, ptr %33, align 8, !tbaa !11
  %266 = fdiv double %264, %265
  store double %266, ptr %32, align 8, !tbaa !11
  %267 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, ptr noundef @.str.17)
          to label %268 unwind label %339

268:                                              ; preds = %260
  %269 = load double, ptr %31, align 8, !tbaa !11
  %270 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEd(ptr noundef nonnull align 8 dereferenceable(8) %267, double noundef %269)
          to label %271 unwind label %339

271:                                              ; preds = %268
  %272 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %270, ptr noundef @.str.4)
          to label %273 unwind label %339

273:                                              ; preds = %271
  %274 = load double, ptr %32, align 8, !tbaa !11
  %275 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEd(ptr noundef nonnull align 8 dereferenceable(8) %272, double noundef %274)
          to label %276 unwind label %339

276:                                              ; preds = %273
  %277 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSoS_E(ptr noundef nonnull align 8 dereferenceable(8) %275, ptr noundef @_ZSt4endlIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_)
          to label %278 unwind label %339

278:                                              ; preds = %276
  call void @llvm.lifetime.end.p0(i64 8, ptr %33) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %32) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %31) #5
  call void @_ZNSt6vectorIPK4ElemSaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %23) #5
  call void @llvm.lifetime.end.p0(i64 24, ptr %23) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %35) #5
  %279 = load ptr, ptr %4, align 8, !tbaa !5
  %280 = call noundef i64 @_ZNKSt6vectorIPK4ElemSaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %279) #5
  %281 = load i32, ptr %5, align 4, !tbaa !9
  %282 = sext i32 %281 to i64
  %283 = sub i64 %280, %282
  %284 = uitofp i64 %283 to double
  store double %284, ptr %35, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 24, ptr %36) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %38) #5
  %285 = load ptr, ptr %4, align 8, !tbaa !5
  %286 = call ptr @_ZNKSt6vectorIPK4ElemSaIS2_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %285) #5
  %287 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %38, i32 0, i32 0
  store ptr %286, ptr %287, align 8
  %288 = load i32, ptr %5, align 4, !tbaa !9
  %289 = sext i32 %288 to i64
  %290 = call ptr @_ZNK9__gnu_cxx17__normal_iteratorIPKPK4ElemSt6vectorIS3_SaIS3_EEEplEl(ptr noundef nonnull align 8 dereferenceable(8) %38, i64 noundef %289) #5
  %291 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %37, i32 0, i32 0
  store ptr %290, ptr %291, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %40) #5
  %292 = load ptr, ptr %4, align 8, !tbaa !5
  %293 = call ptr @_ZNKSt6vectorIPK4ElemSaIS2_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %292) #5
  %294 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %40, i32 0, i32 0
  store ptr %293, ptr %294, align 8
  %295 = load i32, ptr %6, align 4, !tbaa !9
  %296 = sext i32 %295 to i64
  %297 = call ptr @_ZNK9__gnu_cxx17__normal_iteratorIPKPK4ElemSt6vectorIS3_SaIS3_EEEplEl(ptr noundef nonnull align 8 dereferenceable(8) %40, i64 noundef %296) #5
  %298 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %39, i32 0, i32 0
  store ptr %297, ptr %298, align 8
  call void @llvm.lifetime.start.p0(i64 1, ptr %41) #5
  call void @_ZNSaIPK4ElemEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %41) #5
  %299 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %37, i32 0, i32 0
  %300 = load ptr, ptr %299, align 8
  %301 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %39, i32 0, i32 0
  %302 = load ptr, ptr %301, align 8
  invoke void @_ZNSt6vectorIPK4ElemSaIS2_EEC2IN9__gnu_cxx17__normal_iteratorIPKS2_S4_EEvEET_SB_RKS3_(ptr noundef nonnull align 8 dereferenceable(24) %36, ptr %300, ptr %302, ptr noundef nonnull align 1 dereferenceable(1) %41)
          to label %303 unwind label %346

303:                                              ; preds = %278
  call void @_ZNSt15__new_allocatorIPK4ElemED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %41) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr %41) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %40) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %38) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %43) #5
  %304 = call ptr @_ZNSt6vectorIPK4ElemSaIS2_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %36) #5
  %305 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator.0", ptr %43, i32 0, i32 0
  store ptr %304, ptr %305, align 8
  call void @_ZN9__gnu_cxx17__normal_iteratorIPKPK4ElemSt6vectorIS3_SaIS3_EEEC2IPS3_vEERKNS0_IT_S8_EE(ptr noundef nonnull align 8 dereferenceable(8) %42, ptr noundef nonnull align 8 dereferenceable(8) %43) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %45) #5
  %306 = load ptr, ptr %4, align 8, !tbaa !5
  %307 = call ptr @_ZNKSt6vectorIPK4ElemSaIS2_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %306) #5
  %308 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %45, i32 0, i32 0
  store ptr %307, ptr %308, align 8
  %309 = load i32, ptr %6, align 4, !tbaa !9
  %310 = sext i32 %309 to i64
  %311 = call ptr @_ZNK9__gnu_cxx17__normal_iteratorIPKPK4ElemSt6vectorIS3_SaIS3_EEEplEl(ptr noundef nonnull align 8 dereferenceable(8) %45, i64 noundef %310) #5
  %312 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %44, i32 0, i32 0
  store ptr %311, ptr %312, align 8
  %313 = load ptr, ptr %4, align 8, !tbaa !5
  %314 = call ptr @_ZNKSt6vectorIPK4ElemSaIS2_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %313) #5
  %315 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %46, i32 0, i32 0
  store ptr %314, ptr %315, align 8
  %316 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %42, i32 0, i32 0
  %317 = load ptr, ptr %316, align 8
  %318 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %44, i32 0, i32 0
  %319 = load ptr, ptr %318, align 8
  %320 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %46, i32 0, i32 0
  %321 = load ptr, ptr %320, align 8
  %322 = invoke ptr @_ZNSt6vectorIPK4ElemSaIS2_EE6insertIN9__gnu_cxx17__normal_iteratorIPKS2_S4_EEvEENS7_IPS2_S4_EESA_T_SD_(ptr noundef nonnull align 8 dereferenceable(24) %36, ptr %317, ptr %319, ptr %321)
          to label %323 unwind label %350

323:                                              ; preds = %303
  %324 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator.0", ptr %47, i32 0, i32 0
  store ptr %322, ptr %324, align 8
  call void @llvm.lifetime.end.p0(i64 8, ptr %45) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %43) #5
  %325 = call ptr @_ZNSt6vectorIPK4ElemSaIS2_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %36) #5
  %326 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator.0", ptr %48, i32 0, i32 0
  store ptr %325, ptr %326, align 8
  %327 = call ptr @_ZNSt6vectorIPK4ElemSaIS2_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %36) #5
  %328 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator.0", ptr %49, i32 0, i32 0
  store ptr %327, ptr %328, align 8
  %329 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator.0", ptr %48, i32 0, i32 0
  %330 = load ptr, ptr %329, align 8
  %331 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator.0", ptr %49, i32 0, i32 0
  %332 = load ptr, ptr %331, align 8
  invoke void @_ZSt4sortIN9__gnu_cxx17__normal_iteratorIPPK4ElemSt6vectorIS4_SaIS4_EEEE11ElemGCmpRedEvT_SB_T0_(ptr %330, ptr %332)
          to label %333 unwind label %354

333:                                              ; preds = %323
  call void @llvm.lifetime.start.p0(i64 8, ptr %51) #5
  store double 0.000000e+00, ptr %51, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 8, ptr %52) #5
  store double 0.000000e+00, ptr %52, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 8, ptr %53) #5
  store double 0.000000e+00, ptr %53, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 8, ptr %54) #5
  store i64 0, ptr %54, align 8, !tbaa !13
  br label %334

334:                                              ; preds = %397, %333
  %335 = load i64, ptr %54, align 8, !tbaa !13
  %336 = call noundef i64 @_ZNKSt6vectorIPK4ElemSaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %36) #5
  %337 = icmp ult i64 %335, %336
  br i1 %337, label %358, label %338

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

339:                                              ; preds = %276, %273, %271, %268, %260
  %340 = landingpad { ptr, i32 }
          cleanup
  %341 = extractvalue { ptr, i32 } %340, 0
  store ptr %341, ptr %13, align 8
  %342 = extractvalue { ptr, i32 } %340, 1
  store i32 %342, ptr %14, align 4
  br label %343

343:                                              ; preds = %339, %256
  call void @llvm.lifetime.end.p0(i64 8, ptr %33) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %32) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %31) #5
  br label %344

344:                                              ; preds = %343, %210
  call void @_ZNSt6vectorIPK4ElemSaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %23) #5
  br label %345

345:                                              ; preds = %344, %206
  call void @llvm.lifetime.end.p0(i64 24, ptr %23) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #5
  br label %430

346:                                              ; preds = %278
  %347 = landingpad { ptr, i32 }
          cleanup
  %348 = extractvalue { ptr, i32 } %347, 0
  store ptr %348, ptr %13, align 8
  %349 = extractvalue { ptr, i32 } %347, 1
  store i32 %349, ptr %14, align 4
  call void @_ZNSt15__new_allocatorIPK4ElemED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %41) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr %41) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %40) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %38) #5
  br label %429

350:                                              ; preds = %303
  %351 = landingpad { ptr, i32 }
          cleanup
  %352 = extractvalue { ptr, i32 } %351, 0
  store ptr %352, ptr %13, align 8
  %353 = extractvalue { ptr, i32 } %351, 1
  store i32 %353, ptr %14, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %45) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %43) #5
  br label %428

354:                                              ; preds = %323
  %355 = landingpad { ptr, i32 }
          cleanup
  %356 = extractvalue { ptr, i32 } %355, 0
  store ptr %356, ptr %13, align 8
  %357 = extractvalue { ptr, i32 } %355, 1
  store i32 %357, ptr %14, align 4
  br label %428

358:                                              ; preds = %334
  %359 = load i64, ptr %54, align 8, !tbaa !13
  %360 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPK4ElemSaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %36, i64 noundef %359) #5
  %361 = load ptr, ptr %360, align 8, !tbaa !5
  %362 = invoke noundef double @_ZNK4Elem10flowVolumeEv(ptr noundef nonnull align 8 dereferenceable(408) %361)
          to label %363 unwind label %400

363:                                              ; preds = %358
  %364 = load double, ptr %53, align 8, !tbaa !11
  %365 = fadd double %364, %362
  store double %365, ptr %53, align 8, !tbaa !11
  %366 = load i64, ptr %54, align 8, !tbaa !13
  %367 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPK4ElemSaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %36, i64 noundef %366) #5
  %368 = load ptr, ptr %367, align 8, !tbaa !5
  %369 = invoke noundef double @_ZNK4Elem10flowVolumeEv(ptr noundef nonnull align 8 dereferenceable(408) %368)
          to label %370 unwind label %400

370:                                              ; preds = %363
  %371 = load i64, ptr %54, align 8, !tbaa !13
  %372 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPK4ElemSaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %36, i64 noundef %371) #5
  %373 = load ptr, ptr %372, align 8, !tbaa !5
  %374 = invoke noundef ptr @_ZNK4Elem5modelEv(ptr noundef nonnull align 8 dereferenceable(408) %373)
          to label %375 unwind label %400

375:                                              ; preds = %370
  %376 = load ptr, ptr %374, align 8, !tbaa !15
  %377 = getelementptr inbounds ptr, ptr %376, i64 24
  %378 = load ptr, ptr %377, align 8
  %379 = invoke noundef i32 %378(ptr noundef nonnull align 8 dereferenceable(152) %374)
          to label %380 unwind label %400

380:                                              ; preds = %375
  %381 = sitofp i32 %379 to double
  %382 = load double, ptr %52, align 8, !tbaa !11
  %383 = call double @llvm.fmuladd.f64(double %369, double %381, double %382)
  store double %383, ptr %52, align 8, !tbaa !11
  %384 = load i64, ptr %54, align 8, !tbaa !13
  %385 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPK4ElemSaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %36, i64 noundef %384) #5
  %386 = load ptr, ptr %385, align 8, !tbaa !5
  %387 = invoke noundef ptr @_ZNK4Elem5modelEv(ptr noundef nonnull align 8 dereferenceable(408) %386)
          to label %388 unwind label %400

388:                                              ; preds = %380
  %389 = load ptr, ptr %387, align 8, !tbaa !15
  %390 = getelementptr inbounds ptr, ptr %389, i64 24
  %391 = load ptr, ptr %390, align 8
  %392 = invoke noundef i32 %391(ptr noundef nonnull align 8 dereferenceable(152) %387)
          to label %393 unwind label %400

393:                                              ; preds = %388
  %394 = sitofp i32 %392 to double
  %395 = load double, ptr %51, align 8, !tbaa !11
  %396 = fadd double %395, %394
  store double %396, ptr %51, align 8, !tbaa !11
  br label %397

397:                                              ; preds = %393
  %398 = load i64, ptr %54, align 8, !tbaa !13
  %399 = add i64 %398, 1
  store i64 %399, ptr %54, align 8, !tbaa !13
  br label %334, !llvm.loop !20

400:                                              ; preds = %388, %380, %375, %370, %363, %358
  %401 = landingpad { ptr, i32 }
          cleanup
  %402 = extractvalue { ptr, i32 } %401, 0
  store ptr %402, ptr %13, align 8
  %403 = extractvalue { ptr, i32 } %401, 1
  store i32 %403, ptr %14, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %54) #5
  br label %427

404:                                              ; preds = %338
  %405 = load double, ptr %51, align 8, !tbaa !11
  %406 = load double, ptr %35, align 8, !tbaa !11
  %407 = fdiv double %405, %406
  store double %407, ptr %51, align 8, !tbaa !11
  %408 = load double, ptr %52, align 8, !tbaa !11
  %409 = load double, ptr %53, align 8, !tbaa !11
  %410 = fdiv double %408, %409
  store double %410, ptr %52, align 8, !tbaa !11
  %411 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, ptr noundef @.str.18)
          to label %412 unwind label %423

412:                                              ; preds = %404
  %413 = load double, ptr %51, align 8, !tbaa !11
  %414 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEd(ptr noundef nonnull align 8 dereferenceable(8) %411, double noundef %413)
          to label %415 unwind label %423

415:                                              ; preds = %412
  %416 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %414, ptr noundef @.str.4)
          to label %417 unwind label %423

417:                                              ; preds = %415
  %418 = load double, ptr %52, align 8, !tbaa !11
  %419 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEd(ptr noundef nonnull align 8 dereferenceable(8) %416, double noundef %418)
          to label %420 unwind label %423

420:                                              ; preds = %417
  %421 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSoS_E(ptr noundef nonnull align 8 dereferenceable(8) %419, ptr noundef @_ZSt4endlIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_)
          to label %422 unwind label %423

422:                                              ; preds = %420
  call void @llvm.lifetime.end.p0(i64 8, ptr %53) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %52) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %51) #5
  call void @_ZNSt6vectorIPK4ElemSaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %36) #5
  call void @llvm.lifetime.end.p0(i64 24, ptr %36) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %35) #5
  ret void

423:                                              ; preds = %420, %417, %415, %412, %404
  %424 = landingpad { ptr, i32 }
          cleanup
  %425 = extractvalue { ptr, i32 } %424, 0
  store ptr %425, ptr %13, align 8
  %426 = extractvalue { ptr, i32 } %424, 1
  store i32 %426, ptr %14, align 4
  br label %427

427:                                              ; preds = %423, %400
  call void @llvm.lifetime.end.p0(i64 8, ptr %53) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %52) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %51) #5
  br label %428

428:                                              ; preds = %427, %354, %350
  call void @_ZNSt6vectorIPK4ElemSaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %36) #5
  br label %429

429:                                              ; preds = %428, %346
  call void @llvm.lifetime.end.p0(i64 24, ptr %36) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %35) #5
  br label %430

430:                                              ; preds = %429, %345, %205
  %431 = load ptr, ptr %13, align 8
  %432 = load i32, ptr %14, align 4
  %433 = insertvalue { ptr, i32 } poison, ptr %431, 0
  %434 = insertvalue { ptr, i32 } %433, i32 %432, 1
  resume { ptr, i32 } %434
}

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

attributes #0 = { inlinehint mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #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 = { 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 #4 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
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, !12, i64 0}
!12 = !{!"double", !7, i64 0}
!13 = !{!14, !14, i64 0}
!14 = !{!"long", !7, i64 0}
!15 = !{!16, !16, i64 0}
!16 = !{!"vtable pointer", !8, i64 0}
!17 = distinct !{!17, !18}
!18 = !{!"llvm.loop.mustprogress"}
!19 = distinct !{!19, !18}
!20 = distinct !{!20, !18}


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

%"class.std::basic_ostream" = type { ptr, %"class.std::basic_ios" }
%"class.std::basic_ios" = type { %"class.std::ios_base", ptr, i8, i8, ptr, ptr, ptr, ptr }
%"class.std::ios_base" = type { ptr, i64, i64, i32, i32, i32, ptr, %"struct.std::ios_base::_Words", [8 x %"struct.std::ios_base::_Words"], i32, ptr, %"class.std::locale" }
%"struct.std::ios_base::_Words" = type { ptr, i64 }
%"class.std::locale" = type { ptr }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<const Elem *, std::allocator<const Elem *>>::_Vector_impl" }
%"struct.std::_Vector_base<const Elem *, std::allocator<const Elem *>>::_Vector_impl" = type { %"struct.std::_Vector_base<const Elem *, std::allocator<const Elem *>>::_Vector_impl_data" }
%"struct.std::_Vector_base<const Elem *, std::allocator<const Elem *>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.__gnu_cxx::__normal_iterator" = type { ptr }
%"class.std::allocator" = type { i8 }
%"class.__gnu_cxx::__normal_iterator.0" = type { ptr }

@_ZSt4cout = external global %"class.std::basic_ostream", align 8
@.str.4 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.16 = external hidden unnamed_addr constant [16 x i8], align 1
@.str.17 = external hidden unnamed_addr constant [16 x i8], align 1
@.str.18 = external hidden unnamed_addr constant [17 x i8], align 1

; Function Attrs: inlinehint mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef) local_unnamed_addr #0

; 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 ptr @_ZNKSt6vectorIPK4ElemSaIS2_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #2 align 2

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

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

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

declare i32 @__gxx_personality_v0(...)

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

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

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

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

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

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

; Function Attrs: mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare double @llvm.fmuladd.f64(double, double, double) #4

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

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

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

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

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

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

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

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZSt4sortIN9__gnu_cxx17__normal_iteratorIPPK4ElemSt6vectorIS4_SaIS4_EEEE11ElemGCmpRedEvT_SB_T0_(ptr, ptr) local_unnamed_addr #0

; Function Attrs: mustprogress uwtable
define dso_local void @_Z24printCornerNumStatisticsRKSt6vectorIPK4ElemSaIS2_EEii(ptr noundef nonnull align 8 dereferenceable(24) %0, i32 noundef %1, i32 noundef %2) local_unnamed_addr #3 personality ptr @__gxx_personality_v0 {
  %4 = alloca %"class.std::vector", align 8
  %5 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %6 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %7 = alloca %"class.std::allocator", align 1
  %8 = alloca %"class.std::vector", align 8
  %9 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %10 = alloca %"class.std::allocator", align 1
  %11 = alloca %"class.std::vector", align 8
  %12 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %13 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %14 = alloca %"class.std::allocator", align 1
  %15 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %16 = alloca %"class.__gnu_cxx::__normal_iterator.0", align 8
  %17 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %4) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %5) #5
  %18 = tail call ptr @_ZNKSt6vectorIPK4ElemSaIS2_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %0) #5
  store ptr %18, ptr %5, align 8
  %19 = sext i32 %1 to i64
  %20 = call ptr @_ZNK9__gnu_cxx17__normal_iteratorIPKPK4ElemSt6vectorIS3_SaIS3_EEEplEl(ptr noundef nonnull align 8 dereferenceable(8) %5, i64 noundef %19) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %6) #5
  %21 = call ptr @_ZNKSt6vectorIPK4ElemSaIS2_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %0) #5
  store ptr %21, ptr %6, align 8
  %22 = sext i32 %2 to i64
  %23 = call ptr @_ZNK9__gnu_cxx17__normal_iteratorIPKPK4ElemSt6vectorIS3_SaIS3_EEEplEl(ptr noundef nonnull align 8 dereferenceable(8) %6, i64 noundef %22) #5
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %7) #5
  call void @_ZNSaIPK4ElemEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %7) #5
  invoke void @_ZNSt6vectorIPK4ElemSaIS2_EEC2IN9__gnu_cxx17__normal_iteratorIPKS2_S4_EEvEET_SB_RKS3_(ptr noundef nonnull align 8 dereferenceable(24) %4, ptr %20, ptr %23, ptr noundef nonnull align 1 dereferenceable(1) %7)
          to label %24 unwind label %31

24:                                               ; preds = %3
  call void @_ZNSt15__new_allocatorIPK4ElemED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %7) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %7) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %5) #5
  %25 = call ptr @_ZNSt6vectorIPK4ElemSaIS2_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %4) #5
  %26 = call ptr @_ZNSt6vectorIPK4ElemSaIS2_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %4) #5
  invoke void @_ZSt4sortIN9__gnu_cxx17__normal_iteratorIPPK4ElemSt6vectorIS4_SaIS4_EEEE11ElemGCmpRedEvT_SB_T0_(ptr %25, ptr %26)
          to label %.preheader114 unwind label %33

.preheader114:                                    ; preds = %24
  %27 = call noundef i64 @_ZNKSt6vectorIPK4ElemSaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %4) #5
  %.not = icmp eq i64 %27, 0
  br i1 %.not, label %._crit_edge, label %.lr.ph

._crit_edge.loopexit:                             ; preds = %57
  %28 = fdiv double %59, %38
  br label %._crit_edge

._crit_edge:                                      ; preds = %._crit_edge.loopexit, %.preheader114
  %.093.lcssa = phi double [ 0.000000e+00, %.preheader114 ], [ %61, %._crit_edge.loopexit ]
  %29 = phi double [ 0x7FF8000000000000, %.preheader114 ], [ %28, %._crit_edge.loopexit ]
  %30 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, ptr noundef nonnull @.str.16)
          to label %67 unwind label %92

31:                                               ; preds = %3
  %32 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt15__new_allocatorIPK4ElemED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %7) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %7) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %5) #5
  br label %95

33:                                               ; preds = %24
  %34 = landingpad { ptr, i32 }
          cleanup
  br label %94

.lr.ph:                                           ; preds = %.preheader114, %57
  %.093127 = phi double [ %61, %57 ], [ 0.000000e+00, %.preheader114 ]
  %.094126 = phi double [ %59, %57 ], [ 0.000000e+00, %.preheader114 ]
  %.095125 = phi double [ %38, %57 ], [ 0.000000e+00, %.preheader114 ]
  %.096124 = phi i64 [ %62, %57 ], [ 0, %.preheader114 ]
  %35 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPK4ElemSaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %4, i64 noundef %.096124) #5
  %36 = load ptr, ptr %35, align 8, !tbaa !5
  %37 = call noundef double @_ZNK4Elem10flowVolumeEv(ptr noundef nonnull align 8 dereferenceable(408) %36)
  %38 = fadd double %.095125, %37
  %39 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPK4ElemSaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %4, i64 noundef %.096124) #5
  %40 = load ptr, ptr %39, align 8, !tbaa !5
  %41 = call noundef double @_ZNK4Elem10flowVolumeEv(ptr noundef nonnull align 8 dereferenceable(408) %40)
  %42 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPK4ElemSaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %4, i64 noundef %.096124) #5
  %43 = load ptr, ptr %42, align 8, !tbaa !5
  %44 = call noundef ptr @_ZNK4Elem5modelEv(ptr noundef nonnull align 8 dereferenceable(408) %43)
  %45 = load ptr, ptr %44, align 8, !tbaa !9
  %46 = getelementptr inbounds i8, ptr %45, i64 192
  %47 = load ptr, ptr %46, align 8
  %48 = invoke noundef i32 %47(ptr noundef nonnull align 8 dereferenceable(152) %44)
          to label %49 unwind label %65

49:                                               ; preds = %.lr.ph
  %50 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPK4ElemSaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %4, i64 noundef %.096124) #5
  %51 = load ptr, ptr %50, align 8, !tbaa !5
  %52 = call noundef ptr @_ZNK4Elem5modelEv(ptr noundef nonnull align 8 dereferenceable(408) %51)
  %53 = load ptr, ptr %52, align 8, !tbaa !9
  %54 = getelementptr inbounds i8, ptr %53, i64 192
  %55 = load ptr, ptr %54, align 8
  %56 = invoke noundef i32 %55(ptr noundef nonnull align 8 dereferenceable(152) %52)
          to label %57 unwind label %65

57:                                               ; preds = %49
  %58 = sitofp i32 %48 to double
  %59 = call double @llvm.fmuladd.f64(double %41, double %58, double %.094126)
  %60 = sitofp i32 %56 to double
  %61 = fadd double %.093127, %60
  %62 = add nuw i64 %.096124, 1
  %63 = call noundef i64 @_ZNKSt6vectorIPK4ElemSaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %4) #5
  %64 = icmp ult i64 %62, %63
  br i1 %64, label %.lr.ph, label %._crit_edge.loopexit, !llvm.loop !11

65:                                               ; preds = %49, %.lr.ph
  %66 = landingpad { ptr, i32 }
          cleanup
  br label %94

67:                                               ; preds = %._crit_edge
  %68 = sub nsw i32 %2, %1
  %69 = sitofp i32 %68 to double
  %70 = fdiv double %.093.lcssa, %69
  %71 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEd(ptr noundef nonnull align 8 dereferenceable(8) %30, double noundef %70)
          to label %72 unwind label %92

72:                                               ; preds = %67
  %73 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %71, ptr noundef nonnull @.str.4)
          to label %74 unwind label %92

74:                                               ; preds = %72
  %75 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEd(ptr noundef nonnull align 8 dereferenceable(8) %73, double noundef %29)
          to label %76 unwind label %92

76:                                               ; preds = %74
  %77 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSoS_E(ptr noundef nonnull align 8 dereferenceable(8) %75, ptr noundef nonnull @_ZSt4endlIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_)
          to label %78 unwind label %92

78:                                               ; preds = %76
  call void @_ZNSt6vectorIPK4ElemSaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %4) #5
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %4) #5
  %79 = call noundef i64 @_ZNKSt6vectorIPK4ElemSaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %0) #5
  %80 = sub i64 %79, %22
  %81 = uitofp i64 %80 to double
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %8) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %9) #5
  %82 = call ptr @_ZNKSt6vectorIPK4ElemSaIS2_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %0) #5
  store ptr %82, ptr %9, align 8
  %83 = call ptr @_ZNK9__gnu_cxx17__normal_iteratorIPKPK4ElemSt6vectorIS3_SaIS3_EEEplEl(ptr noundef nonnull align 8 dereferenceable(8) %9, i64 noundef %22) #5
  %84 = call ptr @_ZNKSt6vectorIPK4ElemSaIS2_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %0) #5
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %10) #5
  call void @_ZNSaIPK4ElemEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %10) #5
  invoke void @_ZNSt6vectorIPK4ElemSaIS2_EEC2IN9__gnu_cxx17__normal_iteratorIPKS2_S4_EEvEET_SB_RKS3_(ptr noundef nonnull align 8 dereferenceable(24) %8, ptr %83, ptr %84, ptr noundef nonnull align 1 dereferenceable(1) %10)
          to label %85 unwind label %96

85:                                               ; preds = %78
  call void @_ZNSt15__new_allocatorIPK4ElemED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %10) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %10) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %9) #5
  %86 = call ptr @_ZNSt6vectorIPK4ElemSaIS2_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %8) #5
  %87 = call ptr @_ZNSt6vectorIPK4ElemSaIS2_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %8) #5
  invoke void @_ZSt4sortIN9__gnu_cxx17__normal_iteratorIPPK4ElemSt6vectorIS4_SaIS4_EEEE11ElemGCmpRedEvT_SB_T0_(ptr %86, ptr %87)
          to label %.preheader113 unwind label %98

.preheader113:                                    ; preds = %85
  %88 = call noundef i64 @_ZNKSt6vectorIPK4ElemSaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %8) #5
  %.not148 = icmp eq i64 %88, 0
  br i1 %.not148, label %._crit_edge135, label %.lr.ph134

._crit_edge135.loopexit:                          ; preds = %122
  %89 = fdiv double %124, %103
  br label %._crit_edge135

._crit_edge135:                                   ; preds = %._crit_edge135.loopexit, %.preheader113
  %.097.lcssa = phi double [ 0.000000e+00, %.preheader113 ], [ %126, %._crit_edge135.loopexit ]
  %90 = phi double [ 0x7FF8000000000000, %.preheader113 ], [ %89, %._crit_edge135.loopexit ]
  %91 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, ptr noundef nonnull @.str.17)
          to label %132 unwind label %163

92:                                               ; preds = %76, %74, %72, %67, %._crit_edge
  %93 = landingpad { ptr, i32 }
          cleanup
  br label %94

94:                                               ; preds = %65, %92, %33
  %.pn108.pn = phi { ptr, i32 } [ %34, %33 ], [ %66, %65 ], [ %93, %92 ]
  call void @_ZNSt6vectorIPK4ElemSaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %4) #5
  br label %95

95:                                               ; preds = %94, %31
  %.pn108.pn.pn = phi { ptr, i32 } [ %.pn108.pn, %94 ], [ %32, %31 ]
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %4) #5
  br label %219

96:                                               ; preds = %78
  %97 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt15__new_allocatorIPK4ElemED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %10) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %10) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %9) #5
  br label %166

98:                                               ; preds = %85
  %99 = landingpad { ptr, i32 }
          cleanup
  br label %165

.lr.ph134:                                        ; preds = %.preheader113, %122
  %.097133 = phi double [ %126, %122 ], [ 0.000000e+00, %.preheader113 ]
  %.098132 = phi double [ %124, %122 ], [ 0.000000e+00, %.preheader113 ]
  %.099131 = phi i64 [ %127, %122 ], [ 0, %.preheader113 ]
  %.0100130 = phi double [ %103, %122 ], [ 0.000000e+00, %.preheader113 ]
  %100 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPK4ElemSaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef %.099131) #5
  %101 = load ptr, ptr %100, align 8, !tbaa !5
  %102 = call noundef double @_ZNK4Elem10flowVolumeEv(ptr noundef nonnull align 8 dereferenceable(408) %101)
  %103 = fadd double %.0100130, %102
  %104 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPK4ElemSaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef %.099131) #5
  %105 = load ptr, ptr %104, align 8, !tbaa !5
  %106 = call noundef double @_ZNK4Elem10flowVolumeEv(ptr noundef nonnull align 8 dereferenceable(408) %105)
  %107 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPK4ElemSaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef %.099131) #5
  %108 = load ptr, ptr %107, align 8, !tbaa !5
  %109 = call noundef ptr @_ZNK4Elem5modelEv(ptr noundef nonnull align 8 dereferenceable(408) %108)
  %110 = load ptr, ptr %109, align 8, !tbaa !9
  %111 = getelementptr inbounds i8, ptr %110, i64 192
  %112 = load ptr, ptr %111, align 8
  %113 = invoke noundef i32 %112(ptr noundef nonnull align 8 dereferenceable(152) %109)
          to label %114 unwind label %130

114:                                              ; preds = %.lr.ph134
  %115 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPK4ElemSaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef %.099131) #5
  %116 = load ptr, ptr %115, align 8, !tbaa !5
  %117 = call noundef ptr @_ZNK4Elem5modelEv(ptr noundef nonnull align 8 dereferenceable(408) %116)
  %118 = load ptr, ptr %117, align 8, !tbaa !9
  %119 = getelementptr inbounds i8, ptr %118, i64 192
  %120 = load ptr, ptr %119, align 8
  %121 = invoke noundef i32 %120(ptr noundef nonnull align 8 dereferenceable(152) %117)
          to label %122 unwind label %130

122:                                              ; preds = %114
  %123 = sitofp i32 %113 to double
  %124 = call double @llvm.fmuladd.f64(double %106, double %123, double %.098132)
  %125 = sitofp i32 %121 to double
  %126 = fadd double %.097133, %125
  %127 = add nuw i64 %.099131, 1
  %128 = call noundef i64 @_ZNKSt6vectorIPK4ElemSaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %8) #5
  %129 = icmp ult i64 %127, %128
  br i1 %129, label %.lr.ph134, label %._crit_edge135.loopexit, !llvm.loop !13

130:                                              ; preds = %114, %.lr.ph134
  %131 = landingpad { ptr, i32 }
          cleanup
  br label %165

132:                                              ; preds = %._crit_edge135
  %133 = fdiv double %.097.lcssa, %81
  %134 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEd(ptr noundef nonnull align 8 dereferenceable(8) %91, double noundef %133)
          to label %135 unwind label %163

135:                                              ; preds = %132
  %136 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %134, ptr noundef nonnull @.str.4)
          to label %137 unwind label %163

137:                                              ; preds = %135
  %138 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEd(ptr noundef nonnull align 8 dereferenceable(8) %136, double noundef %90)
          to label %139 unwind label %163

139:                                              ; preds = %137
  %140 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSoS_E(ptr noundef nonnull align 8 dereferenceable(8) %138, ptr noundef nonnull @_ZSt4endlIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_)
          to label %141 unwind label %163

141:                                              ; preds = %139
  call void @_ZNSt6vectorIPK4ElemSaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %8) #5
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %8) #5
  %142 = call noundef i64 @_ZNKSt6vectorIPK4ElemSaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %0) #5
  %143 = sub i64 %142, %19
  %144 = uitofp i64 %143 to double
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %11) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %12) #5
  %145 = call ptr @_ZNKSt6vectorIPK4ElemSaIS2_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %0) #5
  store ptr %145, ptr %12, align 8
  %146 = call ptr @_ZNK9__gnu_cxx17__normal_iteratorIPKPK4ElemSt6vectorIS3_SaIS3_EEEplEl(ptr noundef nonnull align 8 dereferenceable(8) %12, i64 noundef %19) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %13) #5
  %147 = call ptr @_ZNKSt6vectorIPK4ElemSaIS2_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %0) #5
  store ptr %147, ptr %13, align 8
  %148 = call ptr @_ZNK9__gnu_cxx17__normal_iteratorIPKPK4ElemSt6vectorIS3_SaIS3_EEEplEl(ptr noundef nonnull align 8 dereferenceable(8) %13, i64 noundef %22) #5
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %14) #5
  call void @_ZNSaIPK4ElemEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %14) #5
  invoke void @_ZNSt6vectorIPK4ElemSaIS2_EEC2IN9__gnu_cxx17__normal_iteratorIPKS2_S4_EEvEET_SB_RKS3_(ptr noundef nonnull align 8 dereferenceable(24) %11, ptr %146, ptr %148, ptr noundef nonnull align 1 dereferenceable(1) %14)
          to label %149 unwind label %167

149:                                              ; preds = %141
  call void @_ZNSt15__new_allocatorIPK4ElemED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %14) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %14) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %13) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %12) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %16) #5
  %150 = call ptr @_ZNSt6vectorIPK4ElemSaIS2_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %11) #5
  store ptr %150, ptr %16, align 8
  call void @_ZN9__gnu_cxx17__normal_iteratorIPKPK4ElemSt6vectorIS3_SaIS3_EEEC2IPS3_vEERKNS0_IT_S8_EE(ptr noundef nonnull align 8 dereferenceable(8) %15, ptr noundef nonnull align 8 dereferenceable(8) %16) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %17) #5
  %151 = call ptr @_ZNKSt6vectorIPK4ElemSaIS2_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %0) #5
  store ptr %151, ptr %17, align 8
  %152 = call ptr @_ZNK9__gnu_cxx17__normal_iteratorIPKPK4ElemSt6vectorIS3_SaIS3_EEEplEl(ptr noundef nonnull align 8 dereferenceable(8) %17, i64 noundef %22) #5
  %153 = call ptr @_ZNKSt6vectorIPK4ElemSaIS2_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %0) #5
  %154 = load ptr, ptr %15, align 8
  %155 = invoke ptr @_ZNSt6vectorIPK4ElemSaIS2_EE6insertIN9__gnu_cxx17__normal_iteratorIPKS2_S4_EEvEENS7_IPS2_S4_EESA_T_SD_(ptr noundef nonnull align 8 dereferenceable(24) %11, ptr %154, ptr %152, ptr %153)
          to label %156 unwind label %169

156:                                              ; preds = %149
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %17) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %16) #5
  %157 = call ptr @_ZNSt6vectorIPK4ElemSaIS2_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %11) #5
  %158 = call ptr @_ZNSt6vectorIPK4ElemSaIS2_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %11) #5
  invoke void @_ZSt4sortIN9__gnu_cxx17__normal_iteratorIPPK4ElemSt6vectorIS4_SaIS4_EEEE11ElemGCmpRedEvT_SB_T0_(ptr %157, ptr %158)
          to label %.preheader unwind label %171

.preheader:                                       ; preds = %156
  %159 = call noundef i64 @_ZNKSt6vectorIPK4ElemSaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %11) #5
  %.not149 = icmp eq i64 %159, 0
  br i1 %.not149, label %._crit_edge144, label %.lr.ph143

._crit_edge144.loopexit:                          ; preds = %195
  %160 = fdiv double %197, %176
  br label %._crit_edge144

._crit_edge144:                                   ; preds = %._crit_edge144.loopexit, %.preheader
  %.081.lcssa = phi double [ 0.000000e+00, %.preheader ], [ %199, %._crit_edge144.loopexit ]
  %161 = phi double [ 0x7FF8000000000000, %.preheader ], [ %160, %._crit_edge144.loopexit ]
  %162 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, ptr noundef nonnull @.str.18)
          to label %205 unwind label %215

163:                                              ; preds = %139, %137, %135, %132, %._crit_edge135
  %164 = landingpad { ptr, i32 }
          cleanup
  br label %165

165:                                              ; preds = %130, %163, %98
  %.pn104.pn = phi { ptr, i32 } [ %99, %98 ], [ %131, %130 ], [ %164, %163 ]
  call void @_ZNSt6vectorIPK4ElemSaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %8) #5
  br label %166

166:                                              ; preds = %165, %96
  %.pn104.pn.pn = phi { ptr, i32 } [ %.pn104.pn, %165 ], [ %97, %96 ]
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %8) #5
  br label %219

167:                                              ; preds = %141
  %168 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt15__new_allocatorIPK4ElemED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %14) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %14) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %13) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %12) #5
  br label %218

169:                                              ; preds = %149
  %170 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %17) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %16) #5
  br label %217

171:                                              ; preds = %156
  %172 = landingpad { ptr, i32 }
          cleanup
  br label %217

.lr.ph143:                                        ; preds = %.preheader, %195
  %.0142 = phi i64 [ %200, %195 ], [ 0, %.preheader ]
  %.079141 = phi double [ %176, %195 ], [ 0.000000e+00, %.preheader ]
  %.080140 = phi double [ %197, %195 ], [ 0.000000e+00, %.preheader ]
  %.081139 = phi double [ %199, %195 ], [ 0.000000e+00, %.preheader ]
  %173 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPK4ElemSaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %11, i64 noundef %.0142) #5
  %174 = load ptr, ptr %173, align 8, !tbaa !5
  %175 = call noundef double @_ZNK4Elem10flowVolumeEv(ptr noundef nonnull align 8 dereferenceable(408) %174)
  %176 = fadd double %.079141, %175
  %177 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPK4ElemSaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %11, i64 noundef %.0142) #5
  %178 = load ptr, ptr %177, align 8, !tbaa !5
  %179 = call noundef double @_ZNK4Elem10flowVolumeEv(ptr noundef nonnull align 8 dereferenceable(408) %178)
  %180 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPK4ElemSaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %11, i64 noundef %.0142) #5
  %181 = load ptr, ptr %180, align 8, !tbaa !5
  %182 = call noundef ptr @_ZNK4Elem5modelEv(ptr noundef nonnull align 8 dereferenceable(408) %181)
  %183 = load ptr, ptr %182, align 8, !tbaa !9
  %184 = getelementptr inbounds i8, ptr %183, i64 192
  %185 = load ptr, ptr %184, align 8
  %186 = invoke noundef i32 %185(ptr noundef nonnull align 8 dereferenceable(152) %182)
          to label %187 unwind label %203

187:                                              ; preds = %.lr.ph143
  %188 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPK4ElemSaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %11, i64 noundef %.0142) #5
  %189 = load ptr, ptr %188, align 8, !tbaa !5
  %190 = call noundef ptr @_ZNK4Elem5modelEv(ptr noundef nonnull align 8 dereferenceable(408) %189)
  %191 = load ptr, ptr %190, align 8, !tbaa !9
  %192 = getelementptr inbounds i8, ptr %191, i64 192
  %193 = load ptr, ptr %192, align 8
  %194 = invoke noundef i32 %193(ptr noundef nonnull align 8 dereferenceable(152) %190)
          to label %195 unwind label %203

195:                                              ; preds = %187
  %196 = sitofp i32 %186 to double
  %197 = call double @llvm.fmuladd.f64(double %179, double %196, double %.080140)
  %198 = sitofp i32 %194 to double
  %199 = fadd double %.081139, %198
  %200 = add nuw i64 %.0142, 1
  %201 = call noundef i64 @_ZNKSt6vectorIPK4ElemSaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %11) #5
  %202 = icmp ult i64 %200, %201
  br i1 %202, label %.lr.ph143, label %._crit_edge144.loopexit, !llvm.loop !14

203:                                              ; preds = %187, %.lr.ph143
  %204 = landingpad { ptr, i32 }
          cleanup
  br label %217

205:                                              ; preds = %._crit_edge144
  %206 = fdiv double %.081.lcssa, %144
  %207 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEd(ptr noundef nonnull align 8 dereferenceable(8) %162, double noundef %206)
          to label %208 unwind label %215

208:                                              ; preds = %205
  %209 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %207, ptr noundef nonnull @.str.4)
          to label %210 unwind label %215

210:                                              ; preds = %208
  %211 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEd(ptr noundef nonnull align 8 dereferenceable(8) %209, double noundef %161)
          to label %212 unwind label %215

212:                                              ; preds = %210
  %213 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSoS_E(ptr noundef nonnull align 8 dereferenceable(8) %211, ptr noundef nonnull @_ZSt4endlIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_)
          to label %214 unwind label %215

214:                                              ; preds = %212
  call void @_ZNSt6vectorIPK4ElemSaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %11) #5
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %11) #5
  ret void

215:                                              ; preds = %212, %210, %208, %205, %._crit_edge144
  %216 = landingpad { ptr, i32 }
          cleanup
  br label %217

217:                                              ; preds = %203, %215, %171, %169
  %.pn.pn = phi { ptr, i32 } [ %172, %171 ], [ %170, %169 ], [ %204, %203 ], [ %216, %215 ]
  call void @_ZNSt6vectorIPK4ElemSaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %11) #5
  br label %218

218:                                              ; preds = %217, %167
  %.pn.pn.pn = phi { ptr, i32 } [ %.pn.pn, %217 ], [ %168, %167 ]
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %11) #5
  br label %219

219:                                              ; preds = %218, %166, %95
  %.pn108.pn.pn.pn = phi { ptr, i32 } [ %.pn108.pn.pn, %95 ], [ %.pn104.pn.pn, %166 ], [ %.pn.pn.pn, %218 ]
  resume { ptr, i32 } %.pn108.pn.pn.pn
}

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

attributes #0 = { inlinehint mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #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 = { 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 #4 = { mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none) }
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 = !{!"vtable pointer", !8, i64 0}
!11 = distinct !{!11, !12}
!12 = !{!"llvm.loop.mustprogress"}
!13 = distinct !{!13, !12}
!14 = distinct !{!14, !12}


; Effective O3 passes: CorrelatedValuePropagationPass,EarlyCSEPass,GVNPass,GlobalOptPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,LCSSAPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,SROAPass,SimplifyCFGPass,TailCallElimPass