; LLVM IR from VeloxChem/VeloxChem :: src/dft_func/GridPartitioner.ll (ZNK16CGridPartitioner17getGridStatisticsB5cxx11Ev)

; 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::__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::__cxx11::basic_stringstream" = type { %"class.std::basic_iostream.base", %"class.std::__cxx11::basic_stringbuf", %"class.std::basic_ios" }
%"class.std::basic_iostream.base" = type { %"class.std::basic_istream.base", %"class.std::basic_ostream.base" }
%"class.std::basic_istream.base" = type { ptr, i64 }
%"class.std::basic_ostream.base" = type { ptr }
%"class.std::__cxx11::basic_stringbuf" = type { %"class.std::basic_streambuf", i32, %"class.std::__cxx11::basic_string" }
%"class.std::basic_streambuf" = type { ptr, ptr, ptr, ptr, ptr, ptr, ptr, %"class.std::locale" }
%"class.std::locale" = type { ptr }
%"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::vector.18" = type { %"struct.std::_Vector_base.19" }
%"struct.std::_Vector_base.19" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::allocator.20" = type { i8 }
%"struct.std::_List_const_iterator" = type { ptr }
%"struct.std::_Setfill" = type { i8 }
%"struct.std::_Setw" = type { i32 }
%class.CGridPartitioner = type <{ %"class.std::__cxx11::list", i32, [4 x i8] }>
%"class.std::__cxx11::list" = type { %"class.std::__cxx11::_List_base" }
%"class.std::__cxx11::_List_base" = type { %"struct.std::__cxx11::_List_base<CGridBox, std::allocator<CGridBox>>::_List_impl" }
%"struct.std::__cxx11::_List_base<CGridBox, std::allocator<CGridBox>>::_List_impl" = type { %"struct.std::__detail::_List_node_header" }
%"struct.std::__detail::_List_node_header" = type { %"struct.std::__detail::_List_node_base", i64 }
%"struct.std::__detail::_List_node_base" = type { ptr, ptr }

@.str.3 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.11 = external hidden unnamed_addr constant [41 x i8], align 1
@.str.12 = external hidden unnamed_addr constant [24 x i8], align 1
@.str.13 = external hidden unnamed_addr constant [38 x i8], align 1
@.str.14 = external hidden unnamed_addr constant [35 x i8], align 1
@.str.15 = external hidden unnamed_addr constant [35 x i8], align 1
@.str.16 = external hidden unnamed_addr constant [35 x i8], align 1
@.str.17 = external hidden unnamed_addr constant [19 x i8], align 1
@.str.18 = external hidden unnamed_addr constant [18 x i8], align 1
@.str.19 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.20 = external hidden unnamed_addr constant [2 x i8], align 1

declare i32 @__gxx_personality_v0(...)

; 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

declare noundef i32 @_ZNK8CGridBox21getNumberOfGridPointsEv(ptr noundef nonnull align 8 dereferenceable(80)) #1

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

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

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

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

; Function Attrs: mustprogress uwtable
declare void @_ZNSt7__cxx1118basic_stringstreamIcSt11char_traitsIcESaIcEEC1Ev(ptr noundef nonnull align 8 dereferenceable(128)) unnamed_addr #3 align 2

; 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) #4

declare noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8), i32 noundef) #1

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

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

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

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

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

; Function Attrs: mustprogress uwtable
declare void @_ZNKSt7__cxx1118basic_stringstreamIcSt11char_traitsIcESaIcEE3strEv(ptr dead_on_unwind noalias writable sret(%"class.std::__cxx11::basic_string") align 8, ptr noundef nonnull align 8 dereferenceable(128)) #3 align 2

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZNK16CGridPartitioner17getGridStatisticsB5cxx11Ev(ptr dead_on_unwind noalias writable sret(%"class.std::__cxx11::basic_string") align 8 %0, ptr noundef nonnull align 8 dereferenceable(28) %1) #3 align 2 personality ptr @__gxx_personality_v0 {
  %3 = alloca ptr, align 8
  %4 = alloca ptr, align 8
  %5 = alloca %"class.std::__cxx11::basic_stringstream", align 8
  %6 = alloca ptr, align 8
  %7 = alloca i32, align 4
  %8 = alloca i32, align 4
  %9 = alloca i32, align 4
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  %12 = alloca %"class.std::vector.18", align 8
  %13 = alloca i32, align 4
  %14 = alloca %"class.std::allocator.20", align 1
  %15 = alloca %"struct.std::_List_const_iterator", align 8
  %16 = alloca %"struct.std::_List_const_iterator", align 8
  %17 = alloca i32, align 4
  %18 = alloca i64, align 8
  %19 = alloca %"struct.std::_Setfill", align 1
  %20 = alloca %"struct.std::_Setw", align 4
  %21 = alloca %"struct.std::_Setfill", align 1
  %22 = alloca %"struct.std::_Setw", align 4
  %23 = alloca %"struct.std::_Setfill", align 1
  %24 = alloca %"struct.std::_Setw", align 4
  store ptr %0, ptr %3, align 8
  store ptr %1, ptr %4, align 8, !tbaa !5
  %25 = load ptr, ptr %4, align 8
  call void @llvm.lifetime.start.p0(i64 392, ptr %5) #6
  call void @_ZNSt7__cxx1118basic_stringstreamIcSt11char_traitsIcESaIcEEC1Ev(ptr noundef nonnull align 8 dereferenceable(128) %5)
  %26 = getelementptr inbounds i8, ptr %5, i64 16
  %27 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %26, ptr noundef @.str.11)
          to label %28 unwind label %59

28:                                               ; preds = %2
  %29 = getelementptr inbounds %class.CGridPartitioner, ptr %25, i32 0, i32 1
  %30 = load i32, ptr %29, align 8, !tbaa !9
  %31 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) %27, i32 noundef %30)
          to label %32 unwind label %59

32:                                               ; preds = %28
  %33 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %31, ptr noundef @.str.3)
          to label %34 unwind label %59

34:                                               ; preds = %32
  %35 = getelementptr inbounds i8, ptr %5, i64 16
  %36 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %35, ptr noundef @.str.12)
          to label %37 unwind label %59

37:                                               ; preds = %34
  %38 = call noundef i32 @_ZNK16CGridPartitioner16getNumberOfBoxesEv(ptr noundef nonnull align 8 dereferenceable(28) %25)
  %39 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) %36, i32 noundef %38)
          to label %40 unwind label %59

40:                                               ; preds = %37
  %41 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %39, ptr noundef @.str.3)
          to label %42 unwind label %59

42:                                               ; preds = %40
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #6
  store i32 -1, ptr %8, align 4, !tbaa !18
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #6
  store i32 -1, ptr %9, align 4, !tbaa !18
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #6
  store i32 0, ptr %10, align 4, !tbaa !18
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #6
  store i32 100, ptr %11, align 4, !tbaa !18
  call void @llvm.lifetime.start.p0(i64 24, ptr %12) #6
  %43 = getelementptr inbounds %class.CGridPartitioner, ptr %25, i32 0, i32 1
  %44 = load i32, ptr %43, align 8, !tbaa !9
  %45 = load i32, ptr %11, align 4, !tbaa !18
  %46 = sdiv i32 %44, %45
  %47 = add nsw i32 %46, 1
  %48 = sext i32 %47 to i64
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #6
  store i32 0, ptr %13, align 4, !tbaa !18
  call void @llvm.lifetime.start.p0(i64 1, ptr %14) #6
  call void @_ZNSaIiEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %14) #6
  invoke void @_ZNSt6vectorIiSaIiEEC2EmRKiRKS0_(ptr noundef nonnull align 8 dereferenceable(24) %12, i64 noundef %48, ptr noundef nonnull align 4 dereferenceable(4) %13, ptr noundef nonnull align 1 dereferenceable(1) %14)
          to label %49 unwind label %63

49:                                               ; preds = %42
  call void @_ZNSt15__new_allocatorIiED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %14) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr %14) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #6
  %50 = getelementptr inbounds %class.CGridPartitioner, ptr %25, i32 0, i32 0
  %51 = call ptr @_ZNKSt7__cxx114listI8CGridBoxSaIS1_EE6cbeginEv(ptr noundef nonnull align 8 dereferenceable(24) %50) #6
  %52 = getelementptr inbounds %"struct.std::_List_const_iterator", ptr %15, i32 0, i32 0
  store ptr %51, ptr %52, align 8
  br label %53

53:                                               ; preds = %103, %49
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #6
  %54 = getelementptr inbounds %class.CGridPartitioner, ptr %25, i32 0, i32 0
  %55 = call ptr @_ZNKSt7__cxx114listI8CGridBoxSaIS1_EE4cendEv(ptr noundef nonnull align 8 dereferenceable(24) %54) #6
  %56 = getelementptr inbounds %"struct.std::_List_const_iterator", ptr %16, i32 0, i32 0
  store ptr %55, ptr %56, align 8
  %57 = call noundef zeroext i1 @_ZStneRKSt20_List_const_iteratorI8CGridBoxES3_(ptr noundef nonnull align 8 dereferenceable(8) %15, ptr noundef nonnull align 8 dereferenceable(8) %16) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #6
  br i1 %57, label %67, label %58

58:                                               ; preds = %53
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #6
  br label %105

59:                                               ; preds = %40, %37, %34, %32, %28, %2
  %60 = landingpad { ptr, i32 }
          cleanup
  %61 = extractvalue { ptr, i32 } %60, 0
  store ptr %61, ptr %6, align 8
  %62 = extractvalue { ptr, i32 } %60, 1
  store i32 %62, ptr %7, align 4
  br label %249

63:                                               ; preds = %42
  %64 = landingpad { ptr, i32 }
          cleanup
  %65 = extractvalue { ptr, i32 } %64, 0
  store ptr %65, ptr %6, align 8
  %66 = extractvalue { ptr, i32 } %64, 1
  store i32 %66, ptr %7, align 4
  call void @_ZNSt15__new_allocatorIiED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %14) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr %14) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #6
  br label %248

67:                                               ; preds = %53
  call void @llvm.lifetime.start.p0(i64 4, ptr %17) #6
  %68 = call noundef ptr @_ZNKSt20_List_const_iteratorI8CGridBoxEptEv(ptr noundef nonnull align 8 dereferenceable(8) %15) #6
  %69 = invoke noundef i32 @_ZNK8CGridBox21getNumberOfGridPointsEv(ptr noundef nonnull align 8 dereferenceable(80) %68)
          to label %70 unwind label %79

70:                                               ; preds = %67
  store i32 %69, ptr %17, align 4, !tbaa !18
  %71 = load i32, ptr %8, align 4, !tbaa !18
  %72 = icmp eq i32 %71, -1
  br i1 %72, label %77, label %73

73:                                               ; preds = %70
  %74 = load i32, ptr %17, align 4, !tbaa !18
  %75 = load i32, ptr %8, align 4, !tbaa !18
  %76 = icmp sgt i32 %74, %75
  br i1 %76, label %77, label %83

77:                                               ; preds = %73, %70
  %78 = load i32, ptr %17, align 4, !tbaa !18
  store i32 %78, ptr %8, align 4, !tbaa !18
  br label %83

79:                                               ; preds = %67
  %80 = landingpad { ptr, i32 }
          cleanup
  %81 = extractvalue { ptr, i32 } %80, 0
  store ptr %81, ptr %6, align 8
  %82 = extractvalue { ptr, i32 } %80, 1
  store i32 %82, ptr %7, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #6
  br label %247

83:                                               ; preds = %77, %73
  %84 = load i32, ptr %9, align 4, !tbaa !18
  %85 = icmp eq i32 %84, -1
  br i1 %85, label %90, label %86

86:                                               ; preds = %83
  %87 = load i32, ptr %17, align 4, !tbaa !18
  %88 = load i32, ptr %9, align 4, !tbaa !18
  %89 = icmp slt i32 %87, %88
  br i1 %89, label %90, label %92

90:                                               ; preds = %86, %83
  %91 = load i32, ptr %17, align 4, !tbaa !18
  store i32 %91, ptr %9, align 4, !tbaa !18
  br label %92

92:                                               ; preds = %90, %86
  %93 = load i32, ptr %17, align 4, !tbaa !18
  %94 = load i32, ptr %10, align 4, !tbaa !18
  %95 = add nsw i32 %94, %93
  store i32 %95, ptr %10, align 4, !tbaa !18
  %96 = load i32, ptr %17, align 4, !tbaa !18
  %97 = load i32, ptr %11, align 4, !tbaa !18
  %98 = sdiv i32 %96, %97
  %99 = sext i32 %98 to i64
  %100 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %12, i64 noundef %99) #6
  %101 = load i32, ptr %100, align 4, !tbaa !18
  %102 = add nsw i32 %101, 1
  store i32 %102, ptr %100, align 4, !tbaa !18
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #6
  br label %103

103:                                              ; preds = %92
  %104 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt20_List_const_iteratorI8CGridBoxEppEv(ptr noundef nonnull align 8 dereferenceable(8) %15) #6
  br label %53, !llvm.loop !19

105:                                              ; preds = %58
  %106 = getelementptr inbounds i8, ptr %5, i64 16
  %107 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %106, ptr noundef @.str.13)
          to label %108 unwind label %154

108:                                              ; preds = %105
  %109 = load i32, ptr %10, align 4, !tbaa !18
  %110 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) %107, i32 noundef %109)
          to label %111 unwind label %154

111:                                              ; preds = %108
  %112 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %110, ptr noundef @.str.3)
          to label %113 unwind label %154

113:                                              ; preds = %111
  %114 = getelementptr inbounds i8, ptr %5, i64 16
  %115 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %114, ptr noundef @.str.14)
          to label %116 unwind label %154

116:                                              ; preds = %113
  %117 = load i32, ptr %8, align 4, !tbaa !18
  %118 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) %115, i32 noundef %117)
          to label %119 unwind label %154

119:                                              ; preds = %116
  %120 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %118, ptr noundef @.str.3)
          to label %121 unwind label %154

121:                                              ; preds = %119
  %122 = getelementptr inbounds i8, ptr %5, i64 16
  %123 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %122, ptr noundef @.str.15)
          to label %124 unwind label %154

124:                                              ; preds = %121
  %125 = load i32, ptr %9, align 4, !tbaa !18
  %126 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) %123, i32 noundef %125)
          to label %127 unwind label %154

127:                                              ; preds = %124
  %128 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %126, ptr noundef @.str.3)
          to label %129 unwind label %154

129:                                              ; preds = %127
  %130 = getelementptr inbounds i8, ptr %5, i64 16
  %131 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %130, ptr noundef @.str.16)
          to label %132 unwind label %154

132:                                              ; preds = %129
  %133 = load i32, ptr %10, align 4, !tbaa !18
  %134 = call noundef i32 @_ZNK16CGridPartitioner16getNumberOfBoxesEv(ptr noundef nonnull align 8 dereferenceable(28) %25)
  %135 = sdiv i32 %133, %134
  %136 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) %131, i32 noundef %135)
          to label %137 unwind label %154

137:                                              ; preds = %132
  %138 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %136, ptr noundef @.str.3)
          to label %139 unwind label %154

139:                                              ; preds = %137
  %140 = getelementptr inbounds i8, ptr %5, i64 16
  %141 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %140, ptr noundef @.str.17)
          to label %142 unwind label %154

142:                                              ; preds = %139
  %143 = getelementptr inbounds i8, ptr %5, i64 16
  %144 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %143, ptr noundef @.str.18)
          to label %145 unwind label %154

145:                                              ; preds = %142
  %146 = getelementptr inbounds i8, ptr %5, i64 16
  %147 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %146, ptr noundef @.str.17)
          to label %148 unwind label %154

148:                                              ; preds = %145
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #6
  store i64 0, ptr %18, align 8, !tbaa !21
  br label %149

149:                                              ; preds = %235, %148
  %150 = load i64, ptr %18, align 8, !tbaa !21
  %151 = call noundef i64 @_ZNKSt6vectorIiSaIiEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %12) #6
  %152 = icmp ult i64 %150, %151
  br i1 %152, label %158, label %153

153:                                              ; preds = %149
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #6
  br label %242

154:                                              ; preds = %245, %242, %145, %142, %139, %137, %132, %129, %127, %124, %121, %119, %116, %113, %111, %108, %105
  %155 = landingpad { ptr, i32 }
          cleanup
  %156 = extractvalue { ptr, i32 } %155, 0
  store ptr %156, ptr %6, align 8
  %157 = extractvalue { ptr, i32 } %155, 1
  store i32 %157, ptr %7, align 4
  br label %247

158:                                              ; preds = %149
  %159 = getelementptr inbounds i8, ptr %5, i64 16
  %160 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSt8ios_baseS0_E(ptr noundef nonnull align 8 dereferenceable(8) %159, ptr noundef @_ZSt5rightRSt8ios_base)
          to label %161 unwind label %238

161:                                              ; preds = %158
  %162 = invoke i8 @_ZSt7setfillIcESt8_SetfillIT_ES1_(i8 noundef signext 32)
          to label %163 unwind label %238

163:                                              ; preds = %161
  %164 = getelementptr inbounds %"struct.std::_Setfill", ptr %19, i32 0, i32 0
  store i8 %162, ptr %164, align 1
  %165 = getelementptr inbounds %"struct.std::_Setfill", ptr %19, i32 0, i32 0
  %166 = load i8, ptr %165, align 1
  %167 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_St8_SetfillIS3_E(ptr noundef nonnull align 8 dereferenceable(8) %160, i8 %166)
          to label %168 unwind label %238

168:                                              ; preds = %163
  %169 = invoke i32 @_ZSt4setwi(i32 noundef 4)
          to label %170 unwind label %238

170:                                              ; preds = %168
  %171 = getelementptr inbounds %"struct.std::_Setw", ptr %20, i32 0, i32 0
  store i32 %169, ptr %171, align 4
  %172 = getelementptr inbounds %"struct.std::_Setw", ptr %20, i32 0, i32 0
  %173 = load i32, ptr %172, align 4
  %174 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_St5_Setw(ptr noundef nonnull align 8 dereferenceable(8) %167, i32 %173)
          to label %175 unwind label %238

175:                                              ; preds = %170
  %176 = load i64, ptr %18, align 8, !tbaa !21
  %177 = load i32, ptr %11, align 4, !tbaa !18
  %178 = sext i32 %177 to i64
  %179 = mul i64 %176, %178
  %180 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEm(ptr noundef nonnull align 8 dereferenceable(8) %174, i64 noundef %179)
          to label %181 unwind label %238

181:                                              ; preds = %175
  %182 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %180, ptr noundef @.str.19)
          to label %183 unwind label %238

183:                                              ; preds = %181
  %184 = getelementptr inbounds i8, ptr %5, i64 16
  %185 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSt8ios_baseS0_E(ptr noundef nonnull align 8 dereferenceable(8) %184, ptr noundef @_ZSt4leftRSt8ios_base)
          to label %186 unwind label %238

186:                                              ; preds = %183
  %187 = invoke i8 @_ZSt7setfillIcESt8_SetfillIT_ES1_(i8 noundef signext 32)
          to label %188 unwind label %238

188:                                              ; preds = %186
  %189 = getelementptr inbounds %"struct.std::_Setfill", ptr %21, i32 0, i32 0
  store i8 %187, ptr %189, align 1
  %190 = getelementptr inbounds %"struct.std::_Setfill", ptr %21, i32 0, i32 0
  %191 = load i8, ptr %190, align 1
  %192 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_St8_SetfillIS3_E(ptr noundef nonnull align 8 dereferenceable(8) %185, i8 %191)
          to label %193 unwind label %238

193:                                              ; preds = %188
  %194 = invoke i32 @_ZSt4setwi(i32 noundef 4)
          to label %195 unwind label %238

195:                                              ; preds = %193
  %196 = getelementptr inbounds %"struct.std::_Setw", ptr %22, i32 0, i32 0
  store i32 %194, ptr %196, align 4
  %197 = getelementptr inbounds %"struct.std::_Setw", ptr %22, i32 0, i32 0
  %198 = load i32, ptr %197, align 4
  %199 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_St5_Setw(ptr noundef nonnull align 8 dereferenceable(8) %192, i32 %198)
          to label %200 unwind label %238

200:                                              ; preds = %195
  %201 = load i64, ptr %18, align 8, !tbaa !21
  %202 = add i64 %201, 1
  %203 = load i32, ptr %11, align 4, !tbaa !18
  %204 = sext i32 %203 to i64
  %205 = mul i64 %202, %204
  %206 = sub i64 %205, 1
  %207 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEm(ptr noundef nonnull align 8 dereferenceable(8) %199, i64 noundef %206)
          to label %208 unwind label %238

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

210:                                              ; preds = %208
  %211 = getelementptr inbounds i8, ptr %5, i64 16
  %212 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSt8ios_baseS0_E(ptr noundef nonnull align 8 dereferenceable(8) %211, ptr noundef @_ZSt5rightRSt8ios_base)
          to label %213 unwind label %238

213:                                              ; preds = %210
  %214 = invoke i8 @_ZSt7setfillIcESt8_SetfillIT_ES1_(i8 noundef signext 32)
          to label %215 unwind label %238

215:                                              ; preds = %213
  %216 = getelementptr inbounds %"struct.std::_Setfill", ptr %23, i32 0, i32 0
  store i8 %214, ptr %216, align 1
  %217 = getelementptr inbounds %"struct.std::_Setfill", ptr %23, i32 0, i32 0
  %218 = load i8, ptr %217, align 1
  %219 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_St8_SetfillIS3_E(ptr noundef nonnull align 8 dereferenceable(8) %212, i8 %218)
          to label %220 unwind label %238

220:                                              ; preds = %215
  %221 = invoke i32 @_ZSt4setwi(i32 noundef 6)
          to label %222 unwind label %238

222:                                              ; preds = %220
  %223 = getelementptr inbounds %"struct.std::_Setw", ptr %24, i32 0, i32 0
  store i32 %221, ptr %223, align 4
  %224 = getelementptr inbounds %"struct.std::_Setw", ptr %24, i32 0, i32 0
  %225 = load i32, ptr %224, align 4
  %226 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_St5_Setw(ptr noundef nonnull align 8 dereferenceable(8) %219, i32 %225)
          to label %227 unwind label %238

227:                                              ; preds = %222
  %228 = load i64, ptr %18, align 8, !tbaa !21
  %229 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %12, i64 noundef %228) #6
  %230 = load i32, ptr %229, align 4, !tbaa !18
  %231 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) %226, i32 noundef %230)
          to label %232 unwind label %238

232:                                              ; preds = %227
  %233 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %231, ptr noundef @.str.3)
          to label %234 unwind label %238

234:                                              ; preds = %232
  br label %235

235:                                              ; preds = %234
  %236 = load i64, ptr %18, align 8, !tbaa !21
  %237 = add i64 %236, 1
  store i64 %237, ptr %18, align 8, !tbaa !21
  br label %149, !llvm.loop !22

238:                                              ; preds = %232, %227, %222, %220, %215, %213, %210, %208, %200, %195, %193, %188, %186, %183, %181, %175, %170, %168, %163, %161, %158
  %239 = landingpad { ptr, i32 }
          cleanup
  %240 = extractvalue { ptr, i32 } %239, 0
  store ptr %240, ptr %6, align 8
  %241 = extractvalue { ptr, i32 } %239, 1
  store i32 %241, ptr %7, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #6
  br label %247

242:                                              ; preds = %153
  %243 = getelementptr inbounds i8, ptr %5, i64 16
  %244 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %243, ptr noundef @.str.17)
          to label %245 unwind label %154

245:                                              ; preds = %242
  invoke void @_ZNKSt7__cxx1118basic_stringstreamIcSt11char_traitsIcESaIcEE3strEv(ptr dead_on_unwind writable sret(%"class.std::__cxx11::basic_string") align 8 %0, ptr noundef nonnull align 8 dereferenceable(128) %5)
          to label %246 unwind label %154

246:                                              ; preds = %245
  call void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %12) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr %12) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #6
  call void @_ZNSt7__cxx1118basic_stringstreamIcSt11char_traitsIcESaIcEED1Ev(ptr noundef nonnull align 8 dereferenceable(128) %5) #6
  call void @llvm.lifetime.end.p0(i64 392, ptr %5) #6
  ret void

247:                                              ; preds = %238, %154, %79
  call void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %12) #6
  br label %248

248:                                              ; preds = %247, %63
  call void @llvm.lifetime.end.p0(i64 24, ptr %12) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #6
  br label %249

249:                                              ; preds = %248, %59
  call void @_ZNSt7__cxx1118basic_stringstreamIcSt11char_traitsIcESaIcEED1Ev(ptr noundef nonnull align 8 dereferenceable(128) %5) #6
  call void @llvm.lifetime.end.p0(i64 392, ptr %5) #6
  br label %250

250:                                              ; preds = %249
  %251 = load ptr, ptr %6, align 8
  %252 = load i32, ptr %7, align 4
  %253 = insertvalue { ptr, i32 } poison, ptr %251, 0
  %254 = insertvalue { ptr, i32 } %253, i32 %252, 1
  resume { ptr, i32 } %254
}

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

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

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

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

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local i8 @_ZSt7setfillIcESt8_SetfillIT_ES1_(i8 noundef signext) #5

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local i32 @_ZSt4setwi(i32 noundef) #5

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

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

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

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { mustprogress 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 = { 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 #5 = { 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 #6 = { nounwind }

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !17, i64 24}
!10 = !{!"_ZTS16CGridPartitioner", !11, i64 0, !17, i64 24}
!11 = !{!"_ZTSNSt7__cxx114listI8CGridBoxSaIS1_EEE", !12, i64 0}
!12 = !{!"_ZTSNSt7__cxx1110_List_baseI8CGridBoxSaIS1_EEE", !13, i64 0}
!13 = !{!"_ZTSNSt7__cxx1110_List_baseI8CGridBoxSaIS1_EE10_List_implE", !14, i64 0}
!14 = !{!"_ZTSNSt8__detail17_List_node_headerE", !15, i64 0, !16, i64 16}
!15 = !{!"_ZTSNSt8__detail15_List_node_baseE", !6, i64 0, !6, i64 8}
!16 = !{!"long", !7, i64 0}
!17 = !{!"int", !7, i64 0}
!18 = !{!17, !17, i64 0}
!19 = distinct !{!19, !20}
!20 = !{!"llvm.loop.mustprogress"}
!21 = !{!16, !16, i64 0}
!22 = distinct !{!22, !20}


; 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::__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::__cxx11::basic_stringstream" = type { %"class.std::basic_iostream.base", %"class.std::__cxx11::basic_stringbuf", %"class.std::basic_ios" }
%"class.std::basic_iostream.base" = type { %"class.std::basic_istream.base", %"class.std::basic_ostream.base" }
%"class.std::basic_istream.base" = type { ptr, i64 }
%"class.std::basic_ostream.base" = type { ptr }
%"class.std::__cxx11::basic_stringbuf" = type { %"class.std::basic_streambuf", i32, %"class.std::__cxx11::basic_string" }
%"class.std::basic_streambuf" = type { ptr, ptr, ptr, ptr, ptr, ptr, ptr, %"class.std::locale" }
%"class.std::locale" = type { ptr }
%"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::vector.18" = type { %"struct.std::_Vector_base.19" }
%"struct.std::_Vector_base.19" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::allocator.20" = type { i8 }
%"struct.std::_List_const_iterator" = type { ptr }

@.str.3 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.11 = external hidden unnamed_addr constant [41 x i8], align 1
@.str.12 = external hidden unnamed_addr constant [24 x i8], align 1
@.str.13 = external hidden unnamed_addr constant [38 x i8], align 1
@.str.14 = external hidden unnamed_addr constant [35 x i8], align 1
@.str.15 = external hidden unnamed_addr constant [35 x i8], align 1
@.str.16 = external hidden unnamed_addr constant [35 x i8], align 1
@.str.17 = external hidden unnamed_addr constant [19 x i8], align 1
@.str.18 = external hidden unnamed_addr constant [18 x i8], align 1
@.str.19 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.20 = external hidden unnamed_addr constant [2 x i8], align 1

declare i32 @__gxx_personality_v0(...)

; 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

declare noundef i32 @_ZNK8CGridBox21getNumberOfGridPointsEv(ptr noundef nonnull align 8 dereferenceable(80)) local_unnamed_addr #1

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

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

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

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

; Function Attrs: mustprogress uwtable
declare void @_ZNSt7__cxx1118basic_stringstreamIcSt11char_traitsIcESaIcEEC1Ev(ptr noundef nonnull align 8 dereferenceable(128)) unnamed_addr #3 align 2

; 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 #4

declare noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8), i32 noundef) local_unnamed_addr #1

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

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

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

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

; Function Attrs: mustprogress uwtable
declare void @_ZNKSt7__cxx1118basic_stringstreamIcSt11char_traitsIcESaIcEE3strEv(ptr dead_on_unwind noalias writable sret(%"class.std::__cxx11::basic_string") align 8, ptr noundef nonnull align 8 dereferenceable(128)) local_unnamed_addr #3 align 2

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZNK16CGridPartitioner17getGridStatisticsB5cxx11Ev(ptr dead_on_unwind noalias writable sret(%"class.std::__cxx11::basic_string") align 8 %0, ptr noundef nonnull align 8 dereferenceable(28) %1) local_unnamed_addr #3 align 2 personality ptr @__gxx_personality_v0 {
  %3 = alloca %"class.std::__cxx11::basic_stringstream", align 8
  %4 = alloca %"class.std::vector.18", align 8
  %5 = alloca i32, align 4
  %6 = alloca %"class.std::allocator.20", align 1
  %7 = alloca %"struct.std::_List_const_iterator", align 8
  %8 = alloca %"struct.std::_List_const_iterator", align 8
  call void @llvm.lifetime.start.p0(i64 392, ptr nonnull %3) #7
  call void @_ZNSt7__cxx1118basic_stringstreamIcSt11char_traitsIcESaIcEEC1Ev(ptr noundef nonnull align 8 dereferenceable(128) %3)
  %9 = getelementptr inbounds i8, ptr %3, i64 16
  %10 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %9, ptr noundef nonnull @.str.11)
          to label %11 unwind label %34

11:                                               ; preds = %2
  %12 = getelementptr inbounds i8, ptr %1, i64 24
  %13 = load i32, ptr %12, align 8, !tbaa !5
  %14 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) %10, i32 noundef %13)
          to label %15 unwind label %34

15:                                               ; preds = %11
  %16 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %14, ptr noundef nonnull @.str.3)
          to label %17 unwind label %34

17:                                               ; preds = %15
  %18 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %9, ptr noundef nonnull @.str.12)
          to label %19 unwind label %34

19:                                               ; preds = %17
  %20 = call noundef i32 @_ZNK16CGridPartitioner16getNumberOfBoxesEv(ptr noundef nonnull align 8 dereferenceable(28) %1)
  %21 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) %18, i32 noundef %20)
          to label %22 unwind label %34

22:                                               ; preds = %19
  %23 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %21, ptr noundef nonnull @.str.3)
          to label %24 unwind label %34

24:                                               ; preds = %22
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %4) #7
  %25 = load i32, ptr %12, align 8, !tbaa !5
  %26 = sdiv i32 %25, 100
  %27 = add nsw i32 %26, 1
  %28 = sext i32 %27 to i64
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %5) #7
  store i32 0, ptr %5, align 4, !tbaa !17
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %6) #7
  call void @_ZNSaIiEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %6) #7
  invoke void @_ZNSt6vectorIiSaIiEEC2EmRKiRKS0_(ptr noundef nonnull align 8 dereferenceable(24) %4, i64 noundef %28, ptr noundef nonnull align 4 dereferenceable(4) %5, ptr noundef nonnull align 1 dereferenceable(1) %6)
          to label %29 unwind label %36

29:                                               ; preds = %24
  call void @_ZNSt15__new_allocatorIiED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %6) #7
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %6) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %5) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %7) #7
  %30 = call ptr @_ZNKSt7__cxx114listI8CGridBoxSaIS1_EE6cbeginEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #7
  store ptr %30, ptr %7, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %8) #7
  %31 = call ptr @_ZNKSt7__cxx114listI8CGridBoxSaIS1_EE4cendEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #7
  store ptr %31, ptr %8, align 8
  %32 = call noundef zeroext i1 @_ZStneRKSt20_List_const_iteratorI8CGridBoxES3_(ptr noundef nonnull align 8 dereferenceable(8) %7, ptr noundef nonnull align 8 dereferenceable(8) %8) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #7
  br i1 %32, label %.lr.ph, label %._crit_edge

._crit_edge:                                      ; preds = %40, %29
  %.038.lcssa = phi i32 [ 0, %29 ], [ %45, %40 ]
  %.036.lcssa = phi i32 [ -1, %29 ], [ %.137, %40 ]
  %.034.lcssa = phi i32 [ -1, %29 ], [ %.135, %40 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #7
  %33 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %9, ptr noundef nonnull @.str.13)
          to label %56 unwind label %90

34:                                               ; preds = %22, %19, %17, %15, %11, %2
  %35 = landingpad { ptr, i32 }
          cleanup
  br label %140

36:                                               ; preds = %24
  %37 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt15__new_allocatorIiED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %6) #7
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %6) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %5) #7
  br label %139

.lr.ph:                                           ; preds = %29, %40
  %.03449 = phi i32 [ %.135, %40 ], [ -1, %29 ]
  %.03648 = phi i32 [ %.137, %40 ], [ -1, %29 ]
  %.03847 = phi i32 [ %45, %40 ], [ 0, %29 ]
  %38 = call noundef ptr @_ZNKSt20_List_const_iteratorI8CGridBoxEptEv(ptr noundef nonnull align 8 dereferenceable(8) %7) #7
  %39 = invoke noundef i32 @_ZNK8CGridBox21getNumberOfGridPointsEv(ptr noundef nonnull align 8 dereferenceable(80) %38)
          to label %40 unwind label %54

40:                                               ; preds = %.lr.ph
  %41 = icmp eq i32 %.03449, -1
  %42 = call i32 @llvm.smax.i32(i32 %39, i32 %.03449)
  %.135 = select i1 %41, i32 %39, i32 %42
  %43 = icmp eq i32 %.03648, -1
  %44 = call i32 @llvm.smin.i32(i32 %39, i32 %.03648)
  %.137 = select i1 %43, i32 %39, i32 %44
  %45 = add nsw i32 %39, %.03847
  %46 = sdiv i32 %39, 100
  %47 = sext i32 %46 to i64
  %48 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %4, i64 noundef %47) #7
  %49 = load i32, ptr %48, align 4, !tbaa !17
  %50 = add nsw i32 %49, 1
  store i32 %50, ptr %48, align 4, !tbaa !17
  %51 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt20_List_const_iteratorI8CGridBoxEppEv(ptr noundef nonnull align 8 dereferenceable(8) %7) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %8) #7
  %52 = call ptr @_ZNKSt7__cxx114listI8CGridBoxSaIS1_EE4cendEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #7
  store ptr %52, ptr %8, align 8
  %53 = call noundef zeroext i1 @_ZStneRKSt20_List_const_iteratorI8CGridBoxES3_(ptr noundef nonnull align 8 dereferenceable(8) %7, ptr noundef nonnull align 8 dereferenceable(8) %8) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #7
  br i1 %53, label %.lr.ph, label %._crit_edge, !llvm.loop !18

54:                                               ; preds = %.lr.ph
  %55 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #7
  br label %138

56:                                               ; preds = %._crit_edge
  %57 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) %33, i32 noundef %.038.lcssa)
          to label %58 unwind label %90

58:                                               ; preds = %56
  %59 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %57, ptr noundef nonnull @.str.3)
          to label %60 unwind label %90

60:                                               ; preds = %58
  %61 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %9, ptr noundef nonnull @.str.14)
          to label %62 unwind label %90

62:                                               ; preds = %60
  %63 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) %61, i32 noundef %.034.lcssa)
          to label %64 unwind label %90

64:                                               ; preds = %62
  %65 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %63, ptr noundef nonnull @.str.3)
          to label %66 unwind label %90

66:                                               ; preds = %64
  %67 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %9, ptr noundef nonnull @.str.15)
          to label %68 unwind label %90

68:                                               ; preds = %66
  %69 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) %67, i32 noundef %.036.lcssa)
          to label %70 unwind label %90

70:                                               ; preds = %68
  %71 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %69, ptr noundef nonnull @.str.3)
          to label %72 unwind label %90

72:                                               ; preds = %70
  %73 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %9, ptr noundef nonnull @.str.16)
          to label %74 unwind label %90

74:                                               ; preds = %72
  %75 = call noundef i32 @_ZNK16CGridPartitioner16getNumberOfBoxesEv(ptr noundef nonnull align 8 dereferenceable(28) %1)
  %76 = sdiv i32 %.038.lcssa, %75
  %77 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) %73, i32 noundef %76)
          to label %78 unwind label %90

78:                                               ; preds = %74
  %79 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %77, ptr noundef nonnull @.str.3)
          to label %80 unwind label %90

80:                                               ; preds = %78
  %81 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %9, ptr noundef nonnull @.str.17)
          to label %82 unwind label %90

82:                                               ; preds = %80
  %83 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %9, ptr noundef nonnull @.str.18)
          to label %84 unwind label %90

84:                                               ; preds = %82
  %85 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %9, ptr noundef nonnull @.str.17)
          to label %.preheader unwind label %90

.preheader:                                       ; preds = %84, %132
  %.039 = phi i64 [ %114, %132 ], [ 0, %84 ]
  %86 = call noundef i64 @_ZNKSt6vectorIiSaIiEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %4) #7
  %87 = icmp ult i64 %.039, %86
  br i1 %87, label %92, label %88

88:                                               ; preds = %.preheader
  %89 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %9, ptr noundef nonnull @.str.17)
          to label %136 unwind label %90

90:                                               ; preds = %136, %88, %84, %82, %80, %78, %74, %72, %70, %68, %66, %64, %62, %60, %58, %56, %._crit_edge
  %91 = landingpad { ptr, i32 }
          cleanup
  br label %138

92:                                               ; preds = %.preheader
  %93 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSt8ios_baseS0_E(ptr noundef nonnull align 8 dereferenceable(8) %9, ptr noundef nonnull @_ZSt5rightRSt8ios_base)
          to label %94 unwind label %134

94:                                               ; preds = %92
  %95 = call i8 @_ZSt7setfillIcESt8_SetfillIT_ES1_(i8 noundef signext 32)
  %96 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_St8_SetfillIS3_E(ptr noundef nonnull align 8 dereferenceable(8) %93, i8 %95)
          to label %97 unwind label %134

97:                                               ; preds = %94
  %98 = call i32 @_ZSt4setwi(i32 noundef 4)
  %99 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_St5_Setw(ptr noundef nonnull align 8 dereferenceable(8) %96, i32 %98)
          to label %100 unwind label %134

100:                                              ; preds = %97
  %101 = mul i64 %.039, 100
  %102 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEm(ptr noundef nonnull align 8 dereferenceable(8) %99, i64 noundef %101)
          to label %103 unwind label %134

103:                                              ; preds = %100
  %104 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %102, ptr noundef nonnull @.str.19)
          to label %105 unwind label %134

105:                                              ; preds = %103
  %106 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSt8ios_baseS0_E(ptr noundef nonnull align 8 dereferenceable(8) %9, ptr noundef nonnull @_ZSt4leftRSt8ios_base)
          to label %107 unwind label %134

107:                                              ; preds = %105
  %108 = call i8 @_ZSt7setfillIcESt8_SetfillIT_ES1_(i8 noundef signext 32)
  %109 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_St8_SetfillIS3_E(ptr noundef nonnull align 8 dereferenceable(8) %106, i8 %108)
          to label %110 unwind label %134

110:                                              ; preds = %107
  %111 = call i32 @_ZSt4setwi(i32 noundef 4)
  %112 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_St5_Setw(ptr noundef nonnull align 8 dereferenceable(8) %109, i32 %111)
          to label %113 unwind label %134

113:                                              ; preds = %110
  %114 = add nuw i64 %.039, 1
  %115 = mul i64 %114, 100
  %116 = add i64 %115, -1
  %117 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEm(ptr noundef nonnull align 8 dereferenceable(8) %112, i64 noundef %116)
          to label %118 unwind label %134

118:                                              ; preds = %113
  %119 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %117, ptr noundef nonnull @.str.20)
          to label %120 unwind label %134

120:                                              ; preds = %118
  %121 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSt8ios_baseS0_E(ptr noundef nonnull align 8 dereferenceable(8) %9, ptr noundef nonnull @_ZSt5rightRSt8ios_base)
          to label %122 unwind label %134

122:                                              ; preds = %120
  %123 = call i8 @_ZSt7setfillIcESt8_SetfillIT_ES1_(i8 noundef signext 32)
  %124 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_St8_SetfillIS3_E(ptr noundef nonnull align 8 dereferenceable(8) %121, i8 %123)
          to label %125 unwind label %134

125:                                              ; preds = %122
  %126 = call i32 @_ZSt4setwi(i32 noundef 6)
  %127 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_St5_Setw(ptr noundef nonnull align 8 dereferenceable(8) %124, i32 %126)
          to label %128 unwind label %134

128:                                              ; preds = %125
  %129 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %4, i64 noundef %.039) #7
  %130 = load i32, ptr %129, align 4, !tbaa !17
  %131 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) %127, i32 noundef %130)
          to label %132 unwind label %134

132:                                              ; preds = %128
  %133 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %131, ptr noundef nonnull @.str.3)
          to label %.preheader unwind label %134, !llvm.loop !20

134:                                              ; preds = %132, %128, %125, %122, %120, %118, %113, %110, %107, %105, %103, %100, %97, %94, %92
  %135 = landingpad { ptr, i32 }
          cleanup
  br label %138

136:                                              ; preds = %88
  invoke void @_ZNKSt7__cxx1118basic_stringstreamIcSt11char_traitsIcESaIcEE3strEv(ptr dead_on_unwind writable sret(%"class.std::__cxx11::basic_string") align 8 %0, ptr noundef nonnull align 8 dereferenceable(128) %3)
          to label %137 unwind label %90

137:                                              ; preds = %136
  call void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %4) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %4) #7
  call void @_ZNSt7__cxx1118basic_stringstreamIcSt11char_traitsIcESaIcEED1Ev(ptr noundef nonnull align 8 dereferenceable(128) %3) #7
  call void @llvm.lifetime.end.p0(i64 392, ptr nonnull %3) #7
  ret void

138:                                              ; preds = %134, %90, %54
  %.pn = phi { ptr, i32 } [ %55, %54 ], [ %135, %134 ], [ %91, %90 ]
  call void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %4) #7
  br label %139

139:                                              ; preds = %138, %36
  %.pn.pn = phi { ptr, i32 } [ %.pn, %138 ], [ %37, %36 ]
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %4) #7
  br label %140

140:                                              ; preds = %139, %34
  %.pn.pn.pn = phi { ptr, i32 } [ %.pn.pn, %139 ], [ %35, %34 ]
  call void @_ZNSt7__cxx1118basic_stringstreamIcSt11char_traitsIcESaIcEED1Ev(ptr noundef nonnull align 8 dereferenceable(128) %3) #7
  call void @llvm.lifetime.end.p0(i64 392, ptr nonnull %3) #7
  resume { ptr, i32 } %.pn.pn.pn
}

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

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

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

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

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local i8 @_ZSt7setfillIcESt8_SetfillIT_ES1_(i8 noundef signext) local_unnamed_addr #5

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local i32 @_ZSt4setwi(i32 noundef) local_unnamed_addr #5

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

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

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

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i32 @llvm.smax.i32(i32, i32) #6

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i32 @llvm.smin.i32(i32, i32) #6

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { mustprogress 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 = { 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 #5 = { 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 #6 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #7 = { 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, !16, i64 24}
!6 = !{!"_ZTS16CGridPartitioner", !7, i64 0, !16, i64 24}
!7 = !{!"_ZTSNSt7__cxx114listI8CGridBoxSaIS1_EEE", !8, i64 0}
!8 = !{!"_ZTSNSt7__cxx1110_List_baseI8CGridBoxSaIS1_EEE", !9, i64 0}
!9 = !{!"_ZTSNSt7__cxx1110_List_baseI8CGridBoxSaIS1_EE10_List_implE", !10, i64 0}
!10 = !{!"_ZTSNSt8__detail17_List_node_headerE", !11, i64 0, !15, i64 16}
!11 = !{!"_ZTSNSt8__detail15_List_node_baseE", !12, i64 0, !12, i64 8}
!12 = !{!"any pointer", !13, i64 0}
!13 = !{!"omnipotent char", !14, i64 0}
!14 = !{!"Simple C++ TBAA"}
!15 = !{!"long", !13, i64 0}
!16 = !{!"int", !13, i64 0}
!17 = !{!16, !16, i64 0}
!18 = distinct !{!18, !19}
!19 = !{!"llvm.loop.mustprogress"}
!20 = distinct !{!20, !19}


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