; LLVM IR from drohmer/cgp :: library/cgp/11_mesh/mesh (mesh)

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

%"struct.cgp::numarray.22" = type { %"class.std::vector.23" }
%"class.std::vector.23" = type { %"struct.std::_Vector_base.24" }
%"struct.std::_Vector_base.24" = type { %"struct.std::_Vector_base<cgp::numarray<int>, std::allocator<cgp::numarray<int>>>::_Vector_impl" }
%"struct.std::_Vector_base<cgp::numarray<int>, std::allocator<cgp::numarray<int>>>::_Vector_impl" = type { %"struct.std::_Vector_base<cgp::numarray<int>, std::allocator<cgp::numarray<int>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<cgp::numarray<int>, std::allocator<cgp::numarray<int>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"struct.cgp::numarray.28" = type { %"class.std::vector.29" }
%"class.std::vector.29" = type { %"struct.std::_Vector_base.30" }
%"struct.std::_Vector_base.30" = type { %"struct.std::_Vector_base<std::set<int>, std::allocator<std::set<int>>>::_Vector_impl" }
%"struct.std::_Vector_base<std::set<int>, std::allocator<std::set<int>>>::_Vector_impl" = type { %"struct.std::_Vector_base<std::set<int>, std::allocator<std::set<int>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<std::set<int>, std::allocator<std::set<int>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"struct.std::pair" = type <{ %"struct.std::_Rb_tree_const_iterator", i8, [7 x i8] }>
%"struct.std::_Rb_tree_const_iterator" = type { ptr }

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

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) #0

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZN3cgp3getILi0EjEERKT0_RKNS_14numarray_stackIS1_Li3EEE(ptr noundef nonnull align 4 dereferenceable(12)) #1

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZN3cgp3getILi1EjEERKT0_RKNS_14numarray_stackIS1_Li3EEE(ptr noundef nonnull align 4 dereferenceable(12)) #1

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZN3cgp3getILi2EjEERKT0_RKNS_14numarray_stackIS1_Li3EEE(ptr noundef nonnull align 4 dereferenceable(12)) #1

; Function Attrs: mustprogress uwtable
declare dso_local noundef nonnull align 4 dereferenceable(12) ptr @_ZNK3cgp8numarrayINS_14numarray_stackIjLi3EEEEixEi(ptr noundef nonnull align 8 dereferenceable(24), i32 noundef) #2 align 2

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN3cgp21connectivity_one_ringERKNS_8numarrayINS_14numarray_stackIjLi3EEEEE(ptr dead_on_unwind noalias writable sret(%"struct.cgp::numarray.22") align 8 %0, ptr noundef nonnull align 8 dereferenceable(24) %1) #2 personality ptr @__gxx_personality_v0 {
  %3 = alloca ptr, align 8
  %4 = alloca ptr, align 8
  %5 = alloca i64, align 8
  %6 = alloca %"struct.cgp::numarray.28", align 8
  %7 = alloca ptr, align 8
  %8 = alloca i32, align 4
  %9 = alloca i64, align 8
  %10 = alloca ptr, align 8
  %11 = alloca i32, align 4
  %12 = alloca %"struct.std::pair", align 8
  %13 = alloca i32, align 4
  %14 = alloca %"struct.std::pair", align 8
  %15 = alloca i32, align 4
  %16 = alloca %"struct.std::pair", align 8
  %17 = alloca i32, align 4
  %18 = alloca %"struct.std::pair", align 8
  %19 = alloca i32, align 4
  %20 = alloca %"struct.std::pair", align 8
  %21 = alloca i32, align 4
  %22 = alloca %"struct.std::pair", align 8
  %23 = alloca i1, align 1
  %24 = alloca i32, align 4
  %25 = alloca i32, align 4
  %26 = alloca ptr, align 8
  %27 = alloca %"struct.std::_Rb_tree_const_iterator", align 8
  %28 = alloca %"struct.std::_Rb_tree_const_iterator", align 8
  %29 = alloca i32, align 4
  store ptr %0, ptr %3, align 8
  store ptr %1, ptr %4, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %5) #4
  %30 = load ptr, ptr %4, align 8, !tbaa !5
  %31 = call noundef i32 @_ZNK3cgp8numarrayINS_14numarray_stackIjLi3EEEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %30)
  %32 = sext i32 %31 to i64
  store i64 %32, ptr %5, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 24, ptr %6) #4
  call void @_ZN3cgp8numarrayISt3setIiSt4lessIiESaIiEEEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %6)
  %33 = load i64, ptr %5, align 8, !tbaa !9
  %34 = trunc i64 %33 to i32
  %35 = invoke noundef nonnull align 8 dereferenceable(24) ptr @_ZN3cgp8numarrayISt3setIiSt4lessIiESaIiEEE6resizeEi(ptr noundef nonnull align 8 dereferenceable(24) %6, i32 noundef %34)
          to label %36 unwind label %42

36:                                               ; preds = %2
  call void @llvm.lifetime.start.p0(i64 8, ptr %9) #4
  store i64 0, ptr %9, align 8, !tbaa !9
  br label %37

37:                                               ; preds = %148, %36
  %38 = load i64, ptr %9, align 8, !tbaa !9
  %39 = load i64, ptr %5, align 8, !tbaa !9
  %40 = icmp ult i64 %38, %39
  br i1 %40, label %46, label %41

41:                                               ; preds = %37
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #4
  br label %180

42:                                               ; preds = %180, %2
  %43 = landingpad { ptr, i32 }
          cleanup
  %44 = extractvalue { ptr, i32 } %43, 0
  store ptr %44, ptr %7, align 8
  %45 = extractvalue { ptr, i32 } %43, 1
  store i32 %45, ptr %8, align 4
  br label %237

46:                                               ; preds = %37
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #4
  %47 = load ptr, ptr %4, align 8, !tbaa !5
  %48 = load i64, ptr %9, align 8, !tbaa !9
  %49 = trunc i64 %48 to i32
  %50 = invoke noundef nonnull align 4 dereferenceable(12) ptr @_ZNK3cgp8numarrayINS_14numarray_stackIjLi3EEEEixEi(ptr noundef nonnull align 8 dereferenceable(24) %47, i32 noundef %49)
          to label %51 unwind label %151

51:                                               ; preds = %46
  store ptr %50, ptr %10, align 8, !tbaa !5
  %52 = load ptr, ptr %10, align 8, !tbaa !5
  %53 = invoke noundef nonnull align 4 dereferenceable(4) ptr @_ZN3cgp3getILi0EjEERKT0_RKNS_14numarray_stackIS1_Li3EEE(ptr noundef nonnull align 4 dereferenceable(12) %52)
          to label %54 unwind label %151

54:                                               ; preds = %51
  %55 = load i32, ptr %53, align 4, !tbaa !11
  %56 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZN3cgp8numarrayISt3setIiSt4lessIiESaIiEEEixEi(ptr noundef nonnull align 8 dereferenceable(24) %6, i32 noundef %55)
          to label %57 unwind label %151

57:                                               ; preds = %54
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #4
  %58 = load ptr, ptr %10, align 8, !tbaa !5
  %59 = invoke noundef nonnull align 4 dereferenceable(4) ptr @_ZN3cgp3getILi1EjEERKT0_RKNS_14numarray_stackIS1_Li3EEE(ptr noundef nonnull align 4 dereferenceable(12) %58)
          to label %60 unwind label %155

60:                                               ; preds = %57
  %61 = load i32, ptr %59, align 4, !tbaa !11
  store i32 %61, ptr %11, align 4, !tbaa !11
  %62 = invoke { ptr, i8 } @_ZNSt3setIiSt4lessIiESaIiEE6insertEOi(ptr noundef nonnull align 8 dereferenceable(48) %56, ptr noundef nonnull align 4 dereferenceable(4) %11)
          to label %63 unwind label %155

63:                                               ; preds = %60
  %64 = getelementptr inbounds { ptr, i8 }, ptr %12, i32 0, i32 0
  %65 = extractvalue { ptr, i8 } %62, 0
  store ptr %65, ptr %64, align 8
  %66 = getelementptr inbounds { ptr, i8 }, ptr %12, i32 0, i32 1
  %67 = extractvalue { ptr, i8 } %62, 1
  store i8 %67, ptr %66, align 8
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #4
  %68 = load ptr, ptr %10, align 8, !tbaa !5
  %69 = invoke noundef nonnull align 4 dereferenceable(4) ptr @_ZN3cgp3getILi0EjEERKT0_RKNS_14numarray_stackIS1_Li3EEE(ptr noundef nonnull align 4 dereferenceable(12) %68)
          to label %70 unwind label %151

70:                                               ; preds = %63
  %71 = load i32, ptr %69, align 4, !tbaa !11
  %72 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZN3cgp8numarrayISt3setIiSt4lessIiESaIiEEEixEi(ptr noundef nonnull align 8 dereferenceable(24) %6, i32 noundef %71)
          to label %73 unwind label %151

73:                                               ; preds = %70
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #4
  %74 = load ptr, ptr %10, align 8, !tbaa !5
  %75 = invoke noundef nonnull align 4 dereferenceable(4) ptr @_ZN3cgp3getILi2EjEERKT0_RKNS_14numarray_stackIS1_Li3EEE(ptr noundef nonnull align 4 dereferenceable(12) %74)
          to label %76 unwind label %159

76:                                               ; preds = %73
  %77 = load i32, ptr %75, align 4, !tbaa !11
  store i32 %77, ptr %13, align 4, !tbaa !11
  %78 = invoke { ptr, i8 } @_ZNSt3setIiSt4lessIiESaIiEE6insertEOi(ptr noundef nonnull align 8 dereferenceable(48) %72, ptr noundef nonnull align 4 dereferenceable(4) %13)
          to label %79 unwind label %159

79:                                               ; preds = %76
  %80 = getelementptr inbounds { ptr, i8 }, ptr %14, i32 0, i32 0
  %81 = extractvalue { ptr, i8 } %78, 0
  store ptr %81, ptr %80, align 8
  %82 = getelementptr inbounds { ptr, i8 }, ptr %14, i32 0, i32 1
  %83 = extractvalue { ptr, i8 } %78, 1
  store i8 %83, ptr %82, align 8
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #4
  %84 = load ptr, ptr %10, align 8, !tbaa !5
  %85 = invoke noundef nonnull align 4 dereferenceable(4) ptr @_ZN3cgp3getILi1EjEERKT0_RKNS_14numarray_stackIS1_Li3EEE(ptr noundef nonnull align 4 dereferenceable(12) %84)
          to label %86 unwind label %151

86:                                               ; preds = %79
  %87 = load i32, ptr %85, align 4, !tbaa !11
  %88 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZN3cgp8numarrayISt3setIiSt4lessIiESaIiEEEixEi(ptr noundef nonnull align 8 dereferenceable(24) %6, i32 noundef %87)
          to label %89 unwind label %151

89:                                               ; preds = %86
  call void @llvm.lifetime.start.p0(i64 4, ptr %15) #4
  %90 = load ptr, ptr %10, align 8, !tbaa !5
  %91 = invoke noundef nonnull align 4 dereferenceable(4) ptr @_ZN3cgp3getILi0EjEERKT0_RKNS_14numarray_stackIS1_Li3EEE(ptr noundef nonnull align 4 dereferenceable(12) %90)
          to label %92 unwind label %163

92:                                               ; preds = %89
  %93 = load i32, ptr %91, align 4, !tbaa !11
  store i32 %93, ptr %15, align 4, !tbaa !11
  %94 = invoke { ptr, i8 } @_ZNSt3setIiSt4lessIiESaIiEE6insertEOi(ptr noundef nonnull align 8 dereferenceable(48) %88, ptr noundef nonnull align 4 dereferenceable(4) %15)
          to label %95 unwind label %163

95:                                               ; preds = %92
  %96 = getelementptr inbounds { ptr, i8 }, ptr %16, i32 0, i32 0
  %97 = extractvalue { ptr, i8 } %94, 0
  store ptr %97, ptr %96, align 8
  %98 = getelementptr inbounds { ptr, i8 }, ptr %16, i32 0, i32 1
  %99 = extractvalue { ptr, i8 } %94, 1
  store i8 %99, ptr %98, align 8
  call void @llvm.lifetime.end.p0(i64 4, ptr %15) #4
  %100 = load ptr, ptr %10, align 8, !tbaa !5
  %101 = invoke noundef nonnull align 4 dereferenceable(4) ptr @_ZN3cgp3getILi1EjEERKT0_RKNS_14numarray_stackIS1_Li3EEE(ptr noundef nonnull align 4 dereferenceable(12) %100)
          to label %102 unwind label %151

102:                                              ; preds = %95
  %103 = load i32, ptr %101, align 4, !tbaa !11
  %104 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZN3cgp8numarrayISt3setIiSt4lessIiESaIiEEEixEi(ptr noundef nonnull align 8 dereferenceable(24) %6, i32 noundef %103)
          to label %105 unwind label %151

105:                                              ; preds = %102
  call void @llvm.lifetime.start.p0(i64 4, ptr %17) #4
  %106 = load ptr, ptr %10, align 8, !tbaa !5
  %107 = invoke noundef nonnull align 4 dereferenceable(4) ptr @_ZN3cgp3getILi2EjEERKT0_RKNS_14numarray_stackIS1_Li3EEE(ptr noundef nonnull align 4 dereferenceable(12) %106)
          to label %108 unwind label %167

108:                                              ; preds = %105
  %109 = load i32, ptr %107, align 4, !tbaa !11
  store i32 %109, ptr %17, align 4, !tbaa !11
  %110 = invoke { ptr, i8 } @_ZNSt3setIiSt4lessIiESaIiEE6insertEOi(ptr noundef nonnull align 8 dereferenceable(48) %104, ptr noundef nonnull align 4 dereferenceable(4) %17)
          to label %111 unwind label %167

111:                                              ; preds = %108
  %112 = getelementptr inbounds { ptr, i8 }, ptr %18, i32 0, i32 0
  %113 = extractvalue { ptr, i8 } %110, 0
  store ptr %113, ptr %112, align 8
  %114 = getelementptr inbounds { ptr, i8 }, ptr %18, i32 0, i32 1
  %115 = extractvalue { ptr, i8 } %110, 1
  store i8 %115, ptr %114, align 8
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #4
  %116 = load ptr, ptr %10, align 8, !tbaa !5
  %117 = invoke noundef nonnull align 4 dereferenceable(4) ptr @_ZN3cgp3getILi2EjEERKT0_RKNS_14numarray_stackIS1_Li3EEE(ptr noundef nonnull align 4 dereferenceable(12) %116)
          to label %118 unwind label %151

118:                                              ; preds = %111
  %119 = load i32, ptr %117, align 4, !tbaa !11
  %120 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZN3cgp8numarrayISt3setIiSt4lessIiESaIiEEEixEi(ptr noundef nonnull align 8 dereferenceable(24) %6, i32 noundef %119)
          to label %121 unwind label %151

121:                                              ; preds = %118
  call void @llvm.lifetime.start.p0(i64 4, ptr %19) #4
  %122 = load ptr, ptr %10, align 8, !tbaa !5
  %123 = invoke noundef nonnull align 4 dereferenceable(4) ptr @_ZN3cgp3getILi0EjEERKT0_RKNS_14numarray_stackIS1_Li3EEE(ptr noundef nonnull align 4 dereferenceable(12) %122)
          to label %124 unwind label %171

124:                                              ; preds = %121
  %125 = load i32, ptr %123, align 4, !tbaa !11
  store i32 %125, ptr %19, align 4, !tbaa !11
  %126 = invoke { ptr, i8 } @_ZNSt3setIiSt4lessIiESaIiEE6insertEOi(ptr noundef nonnull align 8 dereferenceable(48) %120, ptr noundef nonnull align 4 dereferenceable(4) %19)
          to label %127 unwind label %171

127:                                              ; preds = %124
  %128 = getelementptr inbounds { ptr, i8 }, ptr %20, i32 0, i32 0
  %129 = extractvalue { ptr, i8 } %126, 0
  store ptr %129, ptr %128, align 8
  %130 = getelementptr inbounds { ptr, i8 }, ptr %20, i32 0, i32 1
  %131 = extractvalue { ptr, i8 } %126, 1
  store i8 %131, ptr %130, align 8
  call void @llvm.lifetime.end.p0(i64 4, ptr %19) #4
  %132 = load ptr, ptr %10, align 8, !tbaa !5
  %133 = invoke noundef nonnull align 4 dereferenceable(4) ptr @_ZN3cgp3getILi2EjEERKT0_RKNS_14numarray_stackIS1_Li3EEE(ptr noundef nonnull align 4 dereferenceable(12) %132)
          to label %134 unwind label %151

134:                                              ; preds = %127
  %135 = load i32, ptr %133, align 4, !tbaa !11
  %136 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZN3cgp8numarrayISt3setIiSt4lessIiESaIiEEEixEi(ptr noundef nonnull align 8 dereferenceable(24) %6, i32 noundef %135)
          to label %137 unwind label %151

137:                                              ; preds = %134
  call void @llvm.lifetime.start.p0(i64 4, ptr %21) #4
  %138 = load ptr, ptr %10, align 8, !tbaa !5
  %139 = invoke noundef nonnull align 4 dereferenceable(4) ptr @_ZN3cgp3getILi1EjEERKT0_RKNS_14numarray_stackIS1_Li3EEE(ptr noundef nonnull align 4 dereferenceable(12) %138)
          to label %140 unwind label %175

140:                                              ; preds = %137
  %141 = load i32, ptr %139, align 4, !tbaa !11
  store i32 %141, ptr %21, align 4, !tbaa !11
  %142 = invoke { ptr, i8 } @_ZNSt3setIiSt4lessIiESaIiEE6insertEOi(ptr noundef nonnull align 8 dereferenceable(48) %136, ptr noundef nonnull align 4 dereferenceable(4) %21)
          to label %143 unwind label %175

143:                                              ; preds = %140
  %144 = getelementptr inbounds { ptr, i8 }, ptr %22, i32 0, i32 0
  %145 = extractvalue { ptr, i8 } %142, 0
  store ptr %145, ptr %144, align 8
  %146 = getelementptr inbounds { ptr, i8 }, ptr %22, i32 0, i32 1
  %147 = extractvalue { ptr, i8 } %142, 1
  store i8 %147, ptr %146, align 8
  call void @llvm.lifetime.end.p0(i64 4, ptr %21) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #4
  br label %148

148:                                              ; preds = %143
  %149 = load i64, ptr %9, align 8, !tbaa !9
  %150 = add i64 %149, 1
  store i64 %150, ptr %9, align 8, !tbaa !9
  br label %37, !llvm.loop !13

151:                                              ; preds = %134, %127, %118, %111, %102, %95, %86, %79, %70, %63, %54, %51, %46
  %152 = landingpad { ptr, i32 }
          cleanup
  %153 = extractvalue { ptr, i32 } %152, 0
  store ptr %153, ptr %7, align 8
  %154 = extractvalue { ptr, i32 } %152, 1
  store i32 %154, ptr %8, align 4
  br label %179

155:                                              ; preds = %60, %57
  %156 = landingpad { ptr, i32 }
          cleanup
  %157 = extractvalue { ptr, i32 } %156, 0
  store ptr %157, ptr %7, align 8
  %158 = extractvalue { ptr, i32 } %156, 1
  store i32 %158, ptr %8, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #4
  br label %179

159:                                              ; preds = %76, %73
  %160 = landingpad { ptr, i32 }
          cleanup
  %161 = extractvalue { ptr, i32 } %160, 0
  store ptr %161, ptr %7, align 8
  %162 = extractvalue { ptr, i32 } %160, 1
  store i32 %162, ptr %8, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #4
  br label %179

163:                                              ; preds = %92, %89
  %164 = landingpad { ptr, i32 }
          cleanup
  %165 = extractvalue { ptr, i32 } %164, 0
  store ptr %165, ptr %7, align 8
  %166 = extractvalue { ptr, i32 } %164, 1
  store i32 %166, ptr %8, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %15) #4
  br label %179

167:                                              ; preds = %108, %105
  %168 = landingpad { ptr, i32 }
          cleanup
  %169 = extractvalue { ptr, i32 } %168, 0
  store ptr %169, ptr %7, align 8
  %170 = extractvalue { ptr, i32 } %168, 1
  store i32 %170, ptr %8, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #4
  br label %179

171:                                              ; preds = %124, %121
  %172 = landingpad { ptr, i32 }
          cleanup
  %173 = extractvalue { ptr, i32 } %172, 0
  store ptr %173, ptr %7, align 8
  %174 = extractvalue { ptr, i32 } %172, 1
  store i32 %174, ptr %8, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %19) #4
  br label %179

175:                                              ; preds = %140, %137
  %176 = landingpad { ptr, i32 }
          cleanup
  %177 = extractvalue { ptr, i32 } %176, 0
  store ptr %177, ptr %7, align 8
  %178 = extractvalue { ptr, i32 } %176, 1
  store i32 %178, ptr %8, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %21) #4
  br label %179

179:                                              ; preds = %175, %171, %167, %163, %159, %155, %151
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #4
  br label %237

180:                                              ; preds = %41
  store i1 false, ptr %23, align 1
  invoke void @_ZN3cgp8numarrayINS0_IiEEEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %0)
          to label %181 unwind label %42

181:                                              ; preds = %180
  %182 = load i64, ptr %5, align 8, !tbaa !9
  %183 = trunc i64 %182 to i32
  %184 = invoke noundef nonnull align 8 dereferenceable(24) ptr @_ZN3cgp8numarrayINS0_IiEEE6resizeEi(ptr noundef nonnull align 8 dereferenceable(24) %0, i32 noundef %183)
          to label %185 unwind label %192

185:                                              ; preds = %181
  call void @llvm.lifetime.start.p0(i64 4, ptr %24) #4
  store i32 0, ptr %24, align 4, !tbaa !11
  br label %186

186:                                              ; preds = %229, %185
  %187 = load i32, ptr %24, align 4, !tbaa !11
  %188 = sext i32 %187 to i64
  %189 = load i64, ptr %5, align 8, !tbaa !9
  %190 = icmp ult i64 %188, %189
  br i1 %190, label %196, label %191

191:                                              ; preds = %186
  store i32 5, ptr %25, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %24) #4
  br label %232

192:                                              ; preds = %181
  %193 = landingpad { ptr, i32 }
          cleanup
  %194 = extractvalue { ptr, i32 } %193, 0
  store ptr %194, ptr %7, align 8
  %195 = extractvalue { ptr, i32 } %193, 1
  store i32 %195, ptr %8, align 4
  br label %236

196:                                              ; preds = %186
  call void @llvm.lifetime.start.p0(i64 8, ptr %26) #4
  %197 = load i32, ptr %24, align 4, !tbaa !11
  %198 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZN3cgp8numarrayISt3setIiSt4lessIiESaIiEEEixEi(ptr noundef nonnull align 8 dereferenceable(24) %6, i32 noundef %197)
          to label %199 unwind label %209

199:                                              ; preds = %196
  store ptr %198, ptr %26, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %27) #4
  %200 = load ptr, ptr %26, align 8, !tbaa !5
  %201 = call ptr @_ZNKSt3setIiSt4lessIiESaIiEE5beginEv(ptr noundef nonnull align 8 dereferenceable(48) %200) #4
  %202 = getelementptr inbounds %"struct.std::_Rb_tree_const_iterator", ptr %27, i32 0, i32 0
  store ptr %201, ptr %202, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %28) #4
  %203 = load ptr, ptr %26, align 8, !tbaa !5
  %204 = call ptr @_ZNKSt3setIiSt4lessIiESaIiEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %203) #4
  %205 = getelementptr inbounds %"struct.std::_Rb_tree_const_iterator", ptr %28, i32 0, i32 0
  store ptr %204, ptr %205, align 8
  br label %206

206:                                              ; preds = %221, %199
  %207 = call noundef zeroext i1 @_ZStneRKSt23_Rb_tree_const_iteratorIiES2_(ptr noundef nonnull align 8 dereferenceable(8) %27, ptr noundef nonnull align 8 dereferenceable(8) %28) #4
  br i1 %207, label %213, label %208

208:                                              ; preds = %206
  store i32 8, ptr %25, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %28) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %27) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %26) #4
  br label %228

209:                                              ; preds = %196
  %210 = landingpad { ptr, i32 }
          cleanup
  %211 = extractvalue { ptr, i32 } %210, 0
  store ptr %211, ptr %7, align 8
  %212 = extractvalue { ptr, i32 } %210, 1
  store i32 %212, ptr %8, align 4
  br label %227

213:                                              ; preds = %206
  call void @llvm.lifetime.start.p0(i64 4, ptr %29) #4
  %214 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt23_Rb_tree_const_iteratorIiEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %27) #4
  %215 = load i32, ptr %214, align 4, !tbaa !11
  store i32 %215, ptr %29, align 4, !tbaa !11
  %216 = load i32, ptr %24, align 4, !tbaa !11
  %217 = invoke noundef nonnull align 8 dereferenceable(24) ptr @_ZN3cgp8numarrayINS0_IiEEEixEi(ptr noundef nonnull align 8 dereferenceable(24) %0, i32 noundef %216)
          to label %218 unwind label %223

218:                                              ; preds = %213
  %219 = invoke noundef nonnull align 8 dereferenceable(24) ptr @_ZN3cgp8numarrayIiE9push_backERKi(ptr noundef nonnull align 8 dereferenceable(24) %217, ptr noundef nonnull align 4 dereferenceable(4) %29)
          to label %220 unwind label %223

220:                                              ; preds = %218
  call void @llvm.lifetime.end.p0(i64 4, ptr %29) #4
  br label %221

221:                                              ; preds = %220
  %222 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt23_Rb_tree_const_iteratorIiEppEv(ptr noundef nonnull align 8 dereferenceable(8) %27) #4
  br label %206

223:                                              ; preds = %218, %213
  %224 = landingpad { ptr, i32 }
          cleanup
  %225 = extractvalue { ptr, i32 } %224, 0
  store ptr %225, ptr %7, align 8
  %226 = extractvalue { ptr, i32 } %224, 1
  store i32 %226, ptr %8, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %29) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %28) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %27) #4
  br label %227

227:                                              ; preds = %223, %209
  call void @llvm.lifetime.end.p0(i64 8, ptr %26) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %24) #4
  br label %236

228:                                              ; preds = %208
  br label %229

229:                                              ; preds = %228
  %230 = load i32, ptr %24, align 4, !tbaa !11
  %231 = add nsw i32 %230, 1
  store i32 %231, ptr %24, align 4, !tbaa !11
  br label %186, !llvm.loop !15

232:                                              ; preds = %191
  store i1 true, ptr %23, align 1
  store i32 1, ptr %25, align 4
  %233 = load i1, ptr %23, align 1
  br i1 %233, label %235, label %234

234:                                              ; preds = %232
  call void @_ZN3cgp8numarrayINS0_IiEEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %0) #4
  br label %235

235:                                              ; preds = %234, %232
  call void @_ZN3cgp8numarrayISt3setIiSt4lessIiESaIiEEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %6) #4
  call void @llvm.lifetime.end.p0(i64 24, ptr %6) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %5) #4
  ret void

236:                                              ; preds = %227, %192
  call void @_ZN3cgp8numarrayINS0_IiEEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %0) #4
  br label %237

237:                                              ; preds = %236, %179, %42
  call void @_ZN3cgp8numarrayISt3setIiSt4lessIiESaIiEEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %6) #4
  call void @llvm.lifetime.end.p0(i64 24, ptr %6) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %5) #4
  br label %238

238:                                              ; preds = %237
  %239 = load ptr, ptr %7, align 8
  %240 = load i32, ptr %8, align 4
  %241 = insertvalue { ptr, i32 } poison, ptr %239, 0
  %242 = insertvalue { ptr, i32 } %241, i32 %240, 1
  resume { ptr, i32 } %242
}

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

!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 = !{!"long", !7, i64 0}
!11 = !{!12, !12, i64 0}
!12 = !{!"int", !7, i64 0}
!13 = distinct !{!13, !14}
!14 = !{!"llvm.loop.mustprogress"}
!15 = distinct !{!15, !14}


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

%"struct.cgp::numarray.22" = type { %"class.std::vector.23" }
%"class.std::vector.23" = type { %"struct.std::_Vector_base.24" }
%"struct.std::_Vector_base.24" = type { %"struct.std::_Vector_base<cgp::numarray<int>, std::allocator<cgp::numarray<int>>>::_Vector_impl" }
%"struct.std::_Vector_base<cgp::numarray<int>, std::allocator<cgp::numarray<int>>>::_Vector_impl" = type { %"struct.std::_Vector_base<cgp::numarray<int>, std::allocator<cgp::numarray<int>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<cgp::numarray<int>, std::allocator<cgp::numarray<int>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"struct.cgp::numarray.28" = type { %"class.std::vector.29" }
%"class.std::vector.29" = type { %"struct.std::_Vector_base.30" }
%"struct.std::_Vector_base.30" = type { %"struct.std::_Vector_base<std::set<int>, std::allocator<std::set<int>>>::_Vector_impl" }
%"struct.std::_Vector_base<std::set<int>, std::allocator<std::set<int>>>::_Vector_impl" = type { %"struct.std::_Vector_base<std::set<int>, std::allocator<std::set<int>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<std::set<int>, std::allocator<std::set<int>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"struct.std::_Rb_tree_const_iterator" = type { ptr }

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

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) #0

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZN3cgp3getILi0EjEERKT0_RKNS_14numarray_stackIS1_Li3EEE(ptr noundef nonnull align 4 dereferenceable(12)) local_unnamed_addr #1

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZN3cgp3getILi1EjEERKT0_RKNS_14numarray_stackIS1_Li3EEE(ptr noundef nonnull align 4 dereferenceable(12)) local_unnamed_addr #1

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZN3cgp3getILi2EjEERKT0_RKNS_14numarray_stackIS1_Li3EEE(ptr noundef nonnull align 4 dereferenceable(12)) local_unnamed_addr #1

; Function Attrs: mustprogress uwtable
declare dso_local noundef nonnull align 4 dereferenceable(12) ptr @_ZNK3cgp8numarrayINS_14numarray_stackIjLi3EEEEixEi(ptr noundef nonnull align 8 dereferenceable(24), i32 noundef) local_unnamed_addr #2 align 2

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN3cgp21connectivity_one_ringERKNS_8numarrayINS_14numarray_stackIjLi3EEEEE(ptr dead_on_unwind noalias writable sret(%"struct.cgp::numarray.22") align 8 %0, ptr noundef nonnull align 8 dereferenceable(24) %1) local_unnamed_addr #2 personality ptr @__gxx_personality_v0 {
  %3 = alloca %"struct.cgp::numarray.28", align 8
  %4 = alloca i32, align 4
  %5 = alloca i32, align 4
  %6 = alloca i32, align 4
  %7 = alloca i32, align 4
  %8 = alloca i32, align 4
  %9 = alloca i32, align 4
  %10 = alloca %"struct.std::_Rb_tree_const_iterator", align 8
  %11 = alloca %"struct.std::_Rb_tree_const_iterator", align 8
  %12 = alloca i32, align 4
  %13 = tail call noundef i32 @_ZNK3cgp8numarrayINS_14numarray_stackIjLi3EEEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %1)
  %14 = sext i32 %13 to i64
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %3) #4
  call void @_ZN3cgp8numarrayISt3setIiSt4lessIiESaIiEEEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %3)
  %15 = invoke noundef nonnull align 8 dereferenceable(24) ptr @_ZN3cgp8numarrayISt3setIiSt4lessIiESaIiEEE6resizeEi(ptr noundef nonnull align 8 dereferenceable(24) %3, i32 noundef %13)
          to label %.preheader51 unwind label %17

.preheader51:                                     ; preds = %2
  %.not = icmp eq i32 %13, 0
  br i1 %.not, label %._crit_edge, label %.lr.ph

._crit_edge:                                      ; preds = %69, %.preheader51
  call void @_ZN3cgp8numarrayINS0_IiEEEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %0)
  %16 = invoke noundef nonnull align 8 dereferenceable(24) ptr @_ZN3cgp8numarrayINS0_IiEEE6resizeEi(ptr noundef nonnull align 8 dereferenceable(24) %0, i32 noundef %13)
          to label %.preheader unwind label %85

.preheader:                                       ; preds = %._crit_edge
  br i1 %.not, label %._crit_edge58, label %.lr.ph57

17:                                               ; preds = %2
  %18 = landingpad { ptr, i32 }
          cleanup
  br label %106

.lr.ph:                                           ; preds = %.preheader51, %69
  %.04452 = phi i64 [ %70, %69 ], [ 0, %.preheader51 ]
  %19 = trunc i64 %.04452 to i32
  %20 = invoke noundef nonnull align 4 dereferenceable(12) ptr @_ZNK3cgp8numarrayINS_14numarray_stackIjLi3EEEEixEi(ptr noundef nonnull align 8 dereferenceable(24) %1, i32 noundef %19)
          to label %21 unwind label %71

21:                                               ; preds = %.lr.ph
  %22 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZN3cgp3getILi0EjEERKT0_RKNS_14numarray_stackIS1_Li3EEE(ptr noundef nonnull align 4 dereferenceable(12) %20)
  %23 = load i32, ptr %22, align 4, !tbaa !5
  %24 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZN3cgp8numarrayISt3setIiSt4lessIiESaIiEEEixEi(ptr noundef nonnull align 8 dereferenceable(24) %3, i32 noundef %23)
          to label %25 unwind label %71

25:                                               ; preds = %21
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %4) #4
  %26 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZN3cgp3getILi1EjEERKT0_RKNS_14numarray_stackIS1_Li3EEE(ptr noundef nonnull align 4 dereferenceable(12) %20)
  %27 = load i32, ptr %26, align 4, !tbaa !5
  store i32 %27, ptr %4, align 4, !tbaa !5
  %28 = invoke { ptr, i8 } @_ZNSt3setIiSt4lessIiESaIiEE6insertEOi(ptr noundef nonnull align 8 dereferenceable(48) %24, ptr noundef nonnull align 4 dereferenceable(4) %4)
          to label %29 unwind label %73

29:                                               ; preds = %25
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %4) #4
  %30 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZN3cgp3getILi0EjEERKT0_RKNS_14numarray_stackIS1_Li3EEE(ptr noundef nonnull align 4 dereferenceable(12) %20)
  %31 = load i32, ptr %30, align 4, !tbaa !5
  %32 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZN3cgp8numarrayISt3setIiSt4lessIiESaIiEEEixEi(ptr noundef nonnull align 8 dereferenceable(24) %3, i32 noundef %31)
          to label %33 unwind label %71

33:                                               ; preds = %29
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %5) #4
  %34 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZN3cgp3getILi2EjEERKT0_RKNS_14numarray_stackIS1_Li3EEE(ptr noundef nonnull align 4 dereferenceable(12) %20)
  %35 = load i32, ptr %34, align 4, !tbaa !5
  store i32 %35, ptr %5, align 4, !tbaa !5
  %36 = invoke { ptr, i8 } @_ZNSt3setIiSt4lessIiESaIiEE6insertEOi(ptr noundef nonnull align 8 dereferenceable(48) %32, ptr noundef nonnull align 4 dereferenceable(4) %5)
          to label %37 unwind label %75

37:                                               ; preds = %33
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %5) #4
  %38 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZN3cgp3getILi1EjEERKT0_RKNS_14numarray_stackIS1_Li3EEE(ptr noundef nonnull align 4 dereferenceable(12) %20)
  %39 = load i32, ptr %38, align 4, !tbaa !5
  %40 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZN3cgp8numarrayISt3setIiSt4lessIiESaIiEEEixEi(ptr noundef nonnull align 8 dereferenceable(24) %3, i32 noundef %39)
          to label %41 unwind label %71

41:                                               ; preds = %37
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %6) #4
  %42 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZN3cgp3getILi0EjEERKT0_RKNS_14numarray_stackIS1_Li3EEE(ptr noundef nonnull align 4 dereferenceable(12) %20)
  %43 = load i32, ptr %42, align 4, !tbaa !5
  store i32 %43, ptr %6, align 4, !tbaa !5
  %44 = invoke { ptr, i8 } @_ZNSt3setIiSt4lessIiESaIiEE6insertEOi(ptr noundef nonnull align 8 dereferenceable(48) %40, ptr noundef nonnull align 4 dereferenceable(4) %6)
          to label %45 unwind label %77

45:                                               ; preds = %41
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %6) #4
  %46 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZN3cgp3getILi1EjEERKT0_RKNS_14numarray_stackIS1_Li3EEE(ptr noundef nonnull align 4 dereferenceable(12) %20)
  %47 = load i32, ptr %46, align 4, !tbaa !5
  %48 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZN3cgp8numarrayISt3setIiSt4lessIiESaIiEEEixEi(ptr noundef nonnull align 8 dereferenceable(24) %3, i32 noundef %47)
          to label %49 unwind label %71

49:                                               ; preds = %45
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %7) #4
  %50 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZN3cgp3getILi2EjEERKT0_RKNS_14numarray_stackIS1_Li3EEE(ptr noundef nonnull align 4 dereferenceable(12) %20)
  %51 = load i32, ptr %50, align 4, !tbaa !5
  store i32 %51, ptr %7, align 4, !tbaa !5
  %52 = invoke { ptr, i8 } @_ZNSt3setIiSt4lessIiESaIiEE6insertEOi(ptr noundef nonnull align 8 dereferenceable(48) %48, ptr noundef nonnull align 4 dereferenceable(4) %7)
          to label %53 unwind label %79

53:                                               ; preds = %49
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %7) #4
  %54 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZN3cgp3getILi2EjEERKT0_RKNS_14numarray_stackIS1_Li3EEE(ptr noundef nonnull align 4 dereferenceable(12) %20)
  %55 = load i32, ptr %54, align 4, !tbaa !5
  %56 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZN3cgp8numarrayISt3setIiSt4lessIiESaIiEEEixEi(ptr noundef nonnull align 8 dereferenceable(24) %3, i32 noundef %55)
          to label %57 unwind label %71

57:                                               ; preds = %53
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %8) #4
  %58 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZN3cgp3getILi0EjEERKT0_RKNS_14numarray_stackIS1_Li3EEE(ptr noundef nonnull align 4 dereferenceable(12) %20)
  %59 = load i32, ptr %58, align 4, !tbaa !5
  store i32 %59, ptr %8, align 4, !tbaa !5
  %60 = invoke { ptr, i8 } @_ZNSt3setIiSt4lessIiESaIiEE6insertEOi(ptr noundef nonnull align 8 dereferenceable(48) %56, ptr noundef nonnull align 4 dereferenceable(4) %8)
          to label %61 unwind label %81

61:                                               ; preds = %57
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %8) #4
  %62 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZN3cgp3getILi2EjEERKT0_RKNS_14numarray_stackIS1_Li3EEE(ptr noundef nonnull align 4 dereferenceable(12) %20)
  %63 = load i32, ptr %62, align 4, !tbaa !5
  %64 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZN3cgp8numarrayISt3setIiSt4lessIiESaIiEEEixEi(ptr noundef nonnull align 8 dereferenceable(24) %3, i32 noundef %63)
          to label %65 unwind label %71

65:                                               ; preds = %61
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %9) #4
  %66 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZN3cgp3getILi1EjEERKT0_RKNS_14numarray_stackIS1_Li3EEE(ptr noundef nonnull align 4 dereferenceable(12) %20)
  %67 = load i32, ptr %66, align 4, !tbaa !5
  store i32 %67, ptr %9, align 4, !tbaa !5
  %68 = invoke { ptr, i8 } @_ZNSt3setIiSt4lessIiESaIiEE6insertEOi(ptr noundef nonnull align 8 dereferenceable(48) %64, ptr noundef nonnull align 4 dereferenceable(4) %9)
          to label %69 unwind label %83

69:                                               ; preds = %65
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %9) #4
  %70 = add nuw i64 %.04452, 1
  %exitcond.not = icmp eq i64 %70, %14
  br i1 %exitcond.not, label %._crit_edge, label %.lr.ph, !llvm.loop !9

71:                                               ; preds = %61, %53, %45, %37, %29, %21, %.lr.ph
  %72 = landingpad { ptr, i32 }
          cleanup
  br label %106

73:                                               ; preds = %25
  %74 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %4) #4
  br label %106

75:                                               ; preds = %33
  %76 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %5) #4
  br label %106

77:                                               ; preds = %41
  %78 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %6) #4
  br label %106

79:                                               ; preds = %49
  %80 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %7) #4
  br label %106

81:                                               ; preds = %57
  %82 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %8) #4
  br label %106

83:                                               ; preds = %65
  %84 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %9) #4
  br label %106

85:                                               ; preds = %._crit_edge
  %86 = landingpad { ptr, i32 }
          cleanup
  br label %105

.lr.ph57:                                         ; preds = %.preheader, %._crit_edge55
  %.03956 = phi i32 [ %92, %._crit_edge55 ], [ 0, %.preheader ]
  %87 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZN3cgp8numarrayISt3setIiSt4lessIiESaIiEEEixEi(ptr noundef nonnull align 8 dereferenceable(24) %3, i32 noundef %.03956)
          to label %88 unwind label %93

88:                                               ; preds = %.lr.ph57
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %10) #4
  %89 = call ptr @_ZNKSt3setIiSt4lessIiESaIiEE5beginEv(ptr noundef nonnull align 8 dereferenceable(48) %87) #4
  store ptr %89, ptr %10, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %11) #4
  %90 = call ptr @_ZNKSt3setIiSt4lessIiESaIiEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %87) #4
  store ptr %90, ptr %11, align 8
  %91 = call noundef zeroext i1 @_ZStneRKSt23_Rb_tree_const_iteratorIiES2_(ptr noundef nonnull align 8 dereferenceable(8) %10, ptr noundef nonnull align 8 dereferenceable(8) %11) #4
  br i1 %91, label %.lr.ph54, label %._crit_edge55

._crit_edge55:                                    ; preds = %100, %88
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %11) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %10) #4
  %92 = add nuw i32 %.03956, 1
  %exitcond60.not = icmp eq i32 %92, %13
  br i1 %exitcond60.not, label %._crit_edge58, label %.lr.ph57, !llvm.loop !11

93:                                               ; preds = %.lr.ph57
  %94 = landingpad { ptr, i32 }
          cleanup
  br label %105

.lr.ph54:                                         ; preds = %88, %100
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %12) #4
  %95 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt23_Rb_tree_const_iteratorIiEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %10) #4
  %96 = load i32, ptr %95, align 4, !tbaa !5
  store i32 %96, ptr %12, align 4, !tbaa !5
  %97 = invoke noundef nonnull align 8 dereferenceable(24) ptr @_ZN3cgp8numarrayINS0_IiEEEixEi(ptr noundef nonnull align 8 dereferenceable(24) %0, i32 noundef %.03956)
          to label %98 unwind label %103

98:                                               ; preds = %.lr.ph54
  %99 = invoke noundef nonnull align 8 dereferenceable(24) ptr @_ZN3cgp8numarrayIiE9push_backERKi(ptr noundef nonnull align 8 dereferenceable(24) %97, ptr noundef nonnull align 4 dereferenceable(4) %12)
          to label %100 unwind label %103

100:                                              ; preds = %98
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %12) #4
  %101 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt23_Rb_tree_const_iteratorIiEppEv(ptr noundef nonnull align 8 dereferenceable(8) %10) #4
  %102 = call noundef zeroext i1 @_ZStneRKSt23_Rb_tree_const_iteratorIiES2_(ptr noundef nonnull align 8 dereferenceable(8) %10, ptr noundef nonnull align 8 dereferenceable(8) %11) #4
  br i1 %102, label %.lr.ph54, label %._crit_edge55

103:                                              ; preds = %98, %.lr.ph54
  %104 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %12) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %11) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %10) #4
  br label %105

._crit_edge58:                                    ; preds = %._crit_edge55, %.preheader
  call void @_ZN3cgp8numarrayISt3setIiSt4lessIiESaIiEEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %3) #4
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %3) #4
  ret void

105:                                              ; preds = %93, %103, %85
  %.pn.pn = phi { ptr, i32 } [ %86, %85 ], [ %104, %103 ], [ %94, %93 ]
  call void @_ZN3cgp8numarrayINS0_IiEEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %0) #4
  br label %106

106:                                              ; preds = %71, %73, %75, %77, %79, %81, %83, %105, %17
  %.pn48.pn = phi { ptr, i32 } [ %.pn.pn, %105 ], [ %18, %17 ], [ %84, %83 ], [ %72, %71 ], [ %82, %81 ], [ %80, %79 ], [ %78, %77 ], [ %76, %75 ], [ %74, %73 ]
  call void @_ZN3cgp8numarrayISt3setIiSt4lessIiESaIiEEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %3) #4
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %3) #4
  resume { ptr, i32 } %.pn48.pn
}

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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


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