; LLVM IR from Eydcao/Yan-CG-SnowSim :: src/BVH.ll (ZN8BVHAccel14recursiveBuildESt6vectorIP5ShapeSaIS2_EE)

; 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.Bounds3 = type { %"class.Eigen::Matrix", %"class.Eigen::Matrix" }
%"class.Eigen::Matrix" = type { %"class.Eigen::PlainObjectBase" }
%"class.Eigen::PlainObjectBase" = type { %"class.Eigen::DenseStorage" }
%"class.Eigen::DenseStorage" = type { %"struct.Eigen::internal::plain_array" }
%"struct.Eigen::internal::plain_array" = type { [3 x float] }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<Shape *, std::allocator<Shape *>>::_Vector_impl" }
%"struct.std::_Vector_base<Shape *, std::allocator<Shape *>>::_Vector_impl" = type { %"struct.std::_Vector_base<Shape *, std::allocator<Shape *>>::_Vector_impl_data" }
%"struct.std::_Vector_base<Shape *, std::allocator<Shape *>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::initializer_list" = type { ptr, i64 }
%"class.std::allocator" = type { i8 }
%"class.__gnu_cxx::__normal_iterator" = type { ptr }
%class.anon = type { i8 }
%class.anon.3 = type { i8 }
%class.anon.5 = type { i8 }
%struct.BVHBuildNode = type { %class.Bounds3, ptr, ptr, ptr, float, i32, i32, i32 }

@.str = external hidden unnamed_addr constant [58 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [67 x i8], align 1
@__PRETTY_FUNCTION__._ZN8BVHAccel14recursiveBuildESt6vectorIP5ShapeSaIS2_EE = external hidden unnamed_addr constant [61 x i8], align 1

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

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

; Function Attrs: mustprogress uwtable
define dso_local noundef ptr @_ZN8BVHAccel14recursiveBuildESt6vectorIP5ShapeSaIS2_EE(ptr noundef nonnull align 8 dereferenceable(40) %0, ptr noundef %1) #1 align 2 personality ptr @__gxx_personality_v0 {
  %3 = alloca ptr, align 8
  %4 = alloca ptr, align 8
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  %8 = alloca i32, align 4
  %9 = alloca %class.Bounds3, align 4
  %10 = alloca i32, align 4
  %11 = alloca %class.Bounds3, align 4
  %12 = alloca %class.Bounds3, align 4
  %13 = alloca %class.Bounds3, align 4
  %14 = alloca i32, align 4
  %15 = alloca %"class.std::vector", align 8
  %16 = alloca %"class.std::initializer_list", align 8
  %17 = alloca [1 x ptr], align 8
  %18 = alloca %"class.std::allocator", align 1
  %19 = alloca %"class.std::vector", align 8
  %20 = alloca %"class.std::initializer_list", align 8
  %21 = alloca [1 x ptr], align 8
  %22 = alloca %"class.std::allocator", align 1
  %23 = alloca %class.Bounds3, align 4
  %24 = alloca %class.Bounds3, align 4
  %25 = alloca i32, align 4
  %26 = alloca %class.Bounds3, align 4
  %27 = alloca %"class.Eigen::Matrix", align 4
  %28 = alloca %class.Bounds3, align 4
  %29 = alloca i32, align 4
  %30 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %31 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %32 = alloca %class.anon, align 1
  %33 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %34 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %35 = alloca %class.anon.3, align 1
  %36 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %37 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %38 = alloca %class.anon.5, align 1
  %39 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %40 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %41 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %42 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %43 = alloca %"class.std::vector", align 8
  %44 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %45 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %46 = alloca %"class.std::allocator", align 1
  %47 = alloca %"class.std::vector", align 8
  %48 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %49 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %50 = alloca %"class.std::allocator", align 1
  %51 = alloca %"class.std::vector", align 8
  %52 = alloca %"class.std::vector", align 8
  %53 = alloca %class.Bounds3, align 4
  store ptr %0, ptr %4, align 8, !tbaa !5
  store ptr %1, ptr %5, align 8, !tbaa !5
  %54 = load ptr, ptr %4, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %6) #9
  %55 = call noalias noundef nonnull ptr @_Znwm(i64 noundef 64) #10
  invoke void @_ZN12BVHBuildNodeC2Ev(ptr noundef nonnull align 8 dereferenceable(64) %55)
          to label %56 unwind label %63

56:                                               ; preds = %2
  store ptr %55, ptr %6, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 24, ptr %9) #9
  call void @_ZN7Bounds3C2Ev(ptr noundef nonnull align 4 dereferenceable(24) %9)
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #9
  store i32 0, ptr %10, align 4, !tbaa !9
  br label %57

57:                                               ; preds = %76, %56
  %58 = load i32, ptr %10, align 4, !tbaa !9
  %59 = sext i32 %58 to i64
  %60 = call noundef i64 @_ZNKSt6vectorIP5ShapeSaIS1_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #9
  %61 = icmp ult i64 %59, %60
  br i1 %61, label %67, label %62

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

63:                                               ; preds = %2
  %64 = landingpad { ptr, i32 }
          cleanup
  %65 = extractvalue { ptr, i32 } %64, 0
  store ptr %65, ptr %7, align 8
  %66 = extractvalue { ptr, i32 } %64, 1
  store i32 %66, ptr %8, align 4
  call void @_ZdlPvm(ptr noundef %55, i64 noundef 64) #11
  br label %328

67:                                               ; preds = %57
  call void @llvm.lifetime.start.p0(i64 24, ptr %11) #9
  call void @llvm.lifetime.start.p0(i64 24, ptr %12) #9
  %68 = load i32, ptr %10, align 4, !tbaa !9
  %69 = sext i32 %68 to i64
  %70 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIP5ShapeSaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef %69) #9
  %71 = load ptr, ptr %70, align 8, !tbaa !5
  %72 = load ptr, ptr %71, align 8, !tbaa !11
  %73 = getelementptr inbounds ptr, ptr %72, i64 4
  %74 = load ptr, ptr %73, align 8
  call void %74(ptr dead_on_unwind writable sret(%class.Bounds3) align 4 %12, ptr noundef nonnull align 8 dereferenceable(8) %71)
  call void @_Z5UnionRK7Bounds3S1_(ptr dead_on_unwind writable sret(%class.Bounds3) align 4 %11, ptr noundef nonnull align 4 dereferenceable(24) %9, ptr noundef nonnull align 4 dereferenceable(24) %12)
  %75 = call noundef nonnull align 4 dereferenceable(24) ptr @_ZN7Bounds3aSEOS_(ptr noundef nonnull align 4 dereferenceable(24) %9, ptr noundef nonnull align 4 dereferenceable(24) %11) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr %12) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr %11) #9
  br label %76

76:                                               ; preds = %67
  %77 = load i32, ptr %10, align 4, !tbaa !9
  %78 = add nsw i32 %77, 1
  store i32 %78, ptr %10, align 4, !tbaa !9
  br label %57, !llvm.loop !13

79:                                               ; preds = %62
  %80 = call noundef i64 @_ZNKSt6vectorIP5ShapeSaIS1_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #9
  %81 = icmp eq i64 %80, 1
  br i1 %81, label %82, label %108

82:                                               ; preds = %79
  call void @llvm.lifetime.start.p0(i64 24, ptr %13) #9
  %83 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIP5ShapeSaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef 0) #9
  %84 = load ptr, ptr %83, align 8, !tbaa !5
  %85 = load ptr, ptr %84, align 8, !tbaa !11
  %86 = getelementptr inbounds ptr, ptr %85, i64 4
  %87 = load ptr, ptr %86, align 8
  call void %87(ptr dead_on_unwind writable sret(%class.Bounds3) align 4 %13, ptr noundef nonnull align 8 dereferenceable(8) %84)
  %88 = load ptr, ptr %6, align 8, !tbaa !5
  %89 = getelementptr inbounds %struct.BVHBuildNode, ptr %88, i32 0, i32 0
  %90 = call noundef nonnull align 4 dereferenceable(24) ptr @_ZN7Bounds3aSEOS_(ptr noundef nonnull align 4 dereferenceable(24) %89, ptr noundef nonnull align 4 dereferenceable(24) %13) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr %13) #9
  %91 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIP5ShapeSaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef 0) #9
  %92 = load ptr, ptr %91, align 8, !tbaa !5
  %93 = load ptr, ptr %6, align 8, !tbaa !5
  %94 = getelementptr inbounds %struct.BVHBuildNode, ptr %93, i32 0, i32 3
  store ptr %92, ptr %94, align 8, !tbaa !15
  %95 = load ptr, ptr %6, align 8, !tbaa !5
  %96 = getelementptr inbounds %struct.BVHBuildNode, ptr %95, i32 0, i32 1
  store ptr null, ptr %96, align 8, !tbaa !23
  %97 = load ptr, ptr %6, align 8, !tbaa !5
  %98 = getelementptr inbounds %struct.BVHBuildNode, ptr %97, i32 0, i32 2
  store ptr null, ptr %98, align 8, !tbaa !24
  %99 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIP5ShapeSaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef 0) #9
  %100 = load ptr, ptr %99, align 8, !tbaa !5
  %101 = load ptr, ptr %100, align 8, !tbaa !11
  %102 = getelementptr inbounds ptr, ptr %101, i64 2
  %103 = load ptr, ptr %102, align 8
  %104 = call noundef float %103(ptr noundef nonnull align 8 dereferenceable(8) %100)
  %105 = load ptr, ptr %6, align 8, !tbaa !5
  %106 = getelementptr inbounds %struct.BVHBuildNode, ptr %105, i32 0, i32 4
  store float %104, ptr %106, align 8, !tbaa !25
  %107 = load ptr, ptr %6, align 8, !tbaa !5
  store ptr %107, ptr %3, align 8
  store i32 1, ptr %14, align 4
  br label %325

108:                                              ; preds = %79
  %109 = call noundef i64 @_ZNKSt6vectorIP5ShapeSaIS1_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #9
  %110 = icmp eq i64 %109, 2
  br i1 %110, label %111, label %181

111:                                              ; preds = %108
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #9
  %112 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIP5ShapeSaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef 0) #9
  %113 = load ptr, ptr %112, align 8, !tbaa !5
  store ptr %113, ptr %17, align 8, !tbaa !5
  %114 = getelementptr inbounds %"class.std::initializer_list", ptr %16, i32 0, i32 0
  store ptr %17, ptr %114, align 8, !tbaa !26
  %115 = getelementptr inbounds %"class.std::initializer_list", ptr %16, i32 0, i32 1
  store i64 1, ptr %115, align 8, !tbaa !29
  call void @llvm.lifetime.start.p0(i64 1, ptr %18) #9
  call void @_ZNSaIP5ShapeEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %18) #9
  %116 = getelementptr inbounds { ptr, i64 }, ptr %16, i32 0, i32 0
  %117 = load ptr, ptr %116, align 8
  %118 = getelementptr inbounds { ptr, i64 }, ptr %16, i32 0, i32 1
  %119 = load i64, ptr %118, align 8
  invoke void @_ZNSt6vectorIP5ShapeSaIS1_EEC2ESt16initializer_listIS1_ERKS2_(ptr noundef nonnull align 8 dereferenceable(24) %15, ptr %117, i64 %119, ptr noundef nonnull align 1 dereferenceable(1) %18)
          to label %120 unwind label %163

120:                                              ; preds = %111
  %121 = invoke noundef ptr @_ZN8BVHAccel14recursiveBuildESt6vectorIP5ShapeSaIS2_EE(ptr noundef nonnull align 8 dereferenceable(40) %54, ptr noundef %15)
          to label %122 unwind label %167

122:                                              ; preds = %120
  %123 = load ptr, ptr %6, align 8, !tbaa !5
  %124 = getelementptr inbounds %struct.BVHBuildNode, ptr %123, i32 0, i32 1
  store ptr %121, ptr %124, align 8, !tbaa !23
  call void @_ZNSt6vectorIP5ShapeSaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %15) #9
  call void @_ZNSt15__new_allocatorIP5ShapeED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %18) #9
  call void @llvm.lifetime.end.p0(i64 1, ptr %18) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr %21) #9
  %125 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIP5ShapeSaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef 1) #9
  %126 = load ptr, ptr %125, align 8, !tbaa !5
  store ptr %126, ptr %21, align 8, !tbaa !5
  %127 = getelementptr inbounds %"class.std::initializer_list", ptr %20, i32 0, i32 0
  store ptr %21, ptr %127, align 8, !tbaa !26
  %128 = getelementptr inbounds %"class.std::initializer_list", ptr %20, i32 0, i32 1
  store i64 1, ptr %128, align 8, !tbaa !29
  call void @llvm.lifetime.start.p0(i64 1, ptr %22) #9
  call void @_ZNSaIP5ShapeEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %22) #9
  %129 = getelementptr inbounds { ptr, i64 }, ptr %20, i32 0, i32 0
  %130 = load ptr, ptr %129, align 8
  %131 = getelementptr inbounds { ptr, i64 }, ptr %20, i32 0, i32 1
  %132 = load i64, ptr %131, align 8
  invoke void @_ZNSt6vectorIP5ShapeSaIS1_EEC2ESt16initializer_listIS1_ERKS2_(ptr noundef nonnull align 8 dereferenceable(24) %19, ptr %130, i64 %132, ptr noundef nonnull align 1 dereferenceable(1) %22)
          to label %133 unwind label %172

133:                                              ; preds = %122
  %134 = invoke noundef ptr @_ZN8BVHAccel14recursiveBuildESt6vectorIP5ShapeSaIS2_EE(ptr noundef nonnull align 8 dereferenceable(40) %54, ptr noundef %19)
          to label %135 unwind label %176

135:                                              ; preds = %133
  %136 = load ptr, ptr %6, align 8, !tbaa !5
  %137 = getelementptr inbounds %struct.BVHBuildNode, ptr %136, i32 0, i32 2
  store ptr %134, ptr %137, align 8, !tbaa !24
  call void @_ZNSt6vectorIP5ShapeSaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %19) #9
  call void @_ZNSt15__new_allocatorIP5ShapeED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %22) #9
  call void @llvm.lifetime.end.p0(i64 1, ptr %22) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #9
  call void @llvm.lifetime.start.p0(i64 24, ptr %23) #9
  %138 = load ptr, ptr %6, align 8, !tbaa !5
  %139 = getelementptr inbounds %struct.BVHBuildNode, ptr %138, i32 0, i32 1
  %140 = load ptr, ptr %139, align 8, !tbaa !23
  %141 = getelementptr inbounds %struct.BVHBuildNode, ptr %140, i32 0, i32 0
  %142 = load ptr, ptr %6, align 8, !tbaa !5
  %143 = getelementptr inbounds %struct.BVHBuildNode, ptr %142, i32 0, i32 2
  %144 = load ptr, ptr %143, align 8, !tbaa !24
  %145 = getelementptr inbounds %struct.BVHBuildNode, ptr %144, i32 0, i32 0
  call void @_Z5UnionRK7Bounds3S1_(ptr dead_on_unwind writable sret(%class.Bounds3) align 4 %23, ptr noundef nonnull align 4 dereferenceable(24) %141, ptr noundef nonnull align 4 dereferenceable(24) %145)
  %146 = load ptr, ptr %6, align 8, !tbaa !5
  %147 = getelementptr inbounds %struct.BVHBuildNode, ptr %146, i32 0, i32 0
  %148 = call noundef nonnull align 4 dereferenceable(24) ptr @_ZN7Bounds3aSEOS_(ptr noundef nonnull align 4 dereferenceable(24) %147, ptr noundef nonnull align 4 dereferenceable(24) %23) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr %23) #9
  %149 = load ptr, ptr %6, align 8, !tbaa !5
  %150 = getelementptr inbounds %struct.BVHBuildNode, ptr %149, i32 0, i32 1
  %151 = load ptr, ptr %150, align 8, !tbaa !23
  %152 = getelementptr inbounds %struct.BVHBuildNode, ptr %151, i32 0, i32 4
  %153 = load float, ptr %152, align 8, !tbaa !25
  %154 = load ptr, ptr %6, align 8, !tbaa !5
  %155 = getelementptr inbounds %struct.BVHBuildNode, ptr %154, i32 0, i32 2
  %156 = load ptr, ptr %155, align 8, !tbaa !24
  %157 = getelementptr inbounds %struct.BVHBuildNode, ptr %156, i32 0, i32 4
  %158 = load float, ptr %157, align 8, !tbaa !25
  %159 = fadd float %153, %158
  %160 = load ptr, ptr %6, align 8, !tbaa !5
  %161 = getelementptr inbounds %struct.BVHBuildNode, ptr %160, i32 0, i32 4
  store float %159, ptr %161, align 8, !tbaa !25
  %162 = load ptr, ptr %6, align 8, !tbaa !5
  store ptr %162, ptr %3, align 8
  store i32 1, ptr %14, align 4
  br label %325

163:                                              ; preds = %111
  %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
  br label %171

167:                                              ; preds = %120
  %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 @_ZNSt6vectorIP5ShapeSaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %15) #9
  br label %171

171:                                              ; preds = %167, %163
  call void @_ZNSt15__new_allocatorIP5ShapeED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %18) #9
  call void @llvm.lifetime.end.p0(i64 1, ptr %18) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #9
  br label %327

172:                                              ; preds = %122
  %173 = landingpad { ptr, i32 }
          cleanup
  %174 = extractvalue { ptr, i32 } %173, 0
  store ptr %174, ptr %7, align 8
  %175 = extractvalue { ptr, i32 } %173, 1
  store i32 %175, ptr %8, align 4
  br label %180

176:                                              ; preds = %133
  %177 = landingpad { ptr, i32 }
          cleanup
  %178 = extractvalue { ptr, i32 } %177, 0
  store ptr %178, ptr %7, align 8
  %179 = extractvalue { ptr, i32 } %177, 1
  store i32 %179, ptr %8, align 4
  call void @_ZNSt6vectorIP5ShapeSaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %19) #9
  br label %180

180:                                              ; preds = %176, %172
  call void @_ZNSt15__new_allocatorIP5ShapeED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %22) #9
  call void @llvm.lifetime.end.p0(i64 1, ptr %22) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #9
  br label %327

181:                                              ; preds = %108
  call void @llvm.lifetime.start.p0(i64 24, ptr %24) #9
  call void @_ZN7Bounds3C2Ev(ptr noundef nonnull align 4 dereferenceable(24) %24)
  call void @llvm.lifetime.start.p0(i64 4, ptr %25) #9
  store i32 0, ptr %25, align 4, !tbaa !9
  br label %182

182:                                              ; preds = %197, %181
  %183 = load i32, ptr %25, align 4, !tbaa !9
  %184 = sext i32 %183 to i64
  %185 = call noundef i64 @_ZNKSt6vectorIP5ShapeSaIS1_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #9
  %186 = icmp ult i64 %184, %185
  br i1 %186, label %188, label %187

187:                                              ; preds = %182
  store i32 5, ptr %14, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %25) #9
  br label %200

188:                                              ; preds = %182
  call void @llvm.lifetime.start.p0(i64 24, ptr %26) #9
  call void @llvm.lifetime.start.p0(i64 12, ptr %27) #9
  call void @llvm.lifetime.start.p0(i64 24, ptr %28) #9
  %189 = load i32, ptr %25, align 4, !tbaa !9
  %190 = sext i32 %189 to i64
  %191 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIP5ShapeSaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef %190) #9
  %192 = load ptr, ptr %191, align 8, !tbaa !5
  %193 = load ptr, ptr %192, align 8, !tbaa !11
  %194 = getelementptr inbounds ptr, ptr %193, i64 4
  %195 = load ptr, ptr %194, align 8
  call void %195(ptr dead_on_unwind writable sret(%class.Bounds3) align 4 %28, ptr noundef nonnull align 8 dereferenceable(8) %192)
  call void @_ZN7Bounds38CentroidEv(ptr dead_on_unwind writable sret(%"class.Eigen::Matrix") align 4 %27, ptr noundef nonnull align 4 dereferenceable(24) %28)
  call void @_Z5UnionRK7Bounds3RKN5Eigen6MatrixIfLi3ELi1ELi0ELi3ELi1EEE(ptr dead_on_unwind writable sret(%class.Bounds3) align 4 %26, ptr noundef nonnull align 4 dereferenceable(24) %24, ptr noundef nonnull align 4 dereferenceable(12) %27)
  %196 = call noundef nonnull align 4 dereferenceable(24) ptr @_ZN7Bounds3aSEOS_(ptr noundef nonnull align 4 dereferenceable(24) %24, ptr noundef nonnull align 4 dereferenceable(24) %26) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr %28) #9
  call void @llvm.lifetime.end.p0(i64 12, ptr %27) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr %26) #9
  br label %197

197:                                              ; preds = %188
  %198 = load i32, ptr %25, align 4, !tbaa !9
  %199 = add nsw i32 %198, 1
  store i32 %199, ptr %25, align 4, !tbaa !9
  br label %182, !llvm.loop !30

200:                                              ; preds = %187
  call void @llvm.lifetime.start.p0(i64 4, ptr %29) #9
  %201 = call noundef i32 @_ZNK7Bounds39maxExtentEv(ptr noundef nonnull align 4 dereferenceable(24) %24)
  store i32 %201, ptr %29, align 4, !tbaa !9
  %202 = load i32, ptr %29, align 4, !tbaa !9
  switch i32 %202, label %230 [
    i32 0, label %203
    i32 1, label %212
    i32 2, label %221
  ]

203:                                              ; preds = %200
  %204 = call ptr @_ZNSt6vectorIP5ShapeSaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #9
  %205 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %30, i32 0, i32 0
  store ptr %204, ptr %205, align 8
  %206 = call ptr @_ZNSt6vectorIP5ShapeSaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #9
  %207 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %31, i32 0, i32 0
  store ptr %206, ptr %207, align 8
  %208 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %30, i32 0, i32 0
  %209 = load ptr, ptr %208, align 8
  %210 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %31, i32 0, i32 0
  %211 = load ptr, ptr %210, align 8
  call void @"_ZSt4sortIN9__gnu_cxx17__normal_iteratorIPP5ShapeSt6vectorIS3_SaIS3_EEEEZN8BVHAccel14recursiveBuildES7_E3$_0EvT_SB_T0_"(ptr %209, ptr %211)
  br label %230

212:                                              ; preds = %200
  %213 = call ptr @_ZNSt6vectorIP5ShapeSaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #9
  %214 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %33, i32 0, i32 0
  store ptr %213, ptr %214, align 8
  %215 = call ptr @_ZNSt6vectorIP5ShapeSaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #9
  %216 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %34, i32 0, i32 0
  store ptr %215, ptr %216, align 8
  %217 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %33, i32 0, i32 0
  %218 = load ptr, ptr %217, align 8
  %219 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %34, i32 0, i32 0
  %220 = load ptr, ptr %219, align 8
  call void @"_ZSt4sortIN9__gnu_cxx17__normal_iteratorIPP5ShapeSt6vectorIS3_SaIS3_EEEEZN8BVHAccel14recursiveBuildES7_E3$_1EvT_SB_T0_"(ptr %218, ptr %220)
  br label %230

221:                                              ; preds = %200
  %222 = call ptr @_ZNSt6vectorIP5ShapeSaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #9
  %223 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %36, i32 0, i32 0
  store ptr %222, ptr %223, align 8
  %224 = call ptr @_ZNSt6vectorIP5ShapeSaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #9
  %225 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %37, i32 0, i32 0
  store ptr %224, ptr %225, align 8
  %226 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %36, i32 0, i32 0
  %227 = load ptr, ptr %226, align 8
  %228 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %37, i32 0, i32 0
  %229 = load ptr, ptr %228, align 8
  call void @"_ZSt4sortIN9__gnu_cxx17__normal_iteratorIPP5ShapeSt6vectorIS3_SaIS3_EEEEZN8BVHAccel14recursiveBuildES7_E3$_2EvT_SB_T0_"(ptr %227, ptr %229)
  br label %230

230:                                              ; preds = %221, %212, %203, %200
  call void @llvm.lifetime.start.p0(i64 8, ptr %39) #9
  %231 = call ptr @_ZNSt6vectorIP5ShapeSaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #9
  %232 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %39, i32 0, i32 0
  store ptr %231, ptr %232, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %40) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr %41) #9
  %233 = call ptr @_ZNSt6vectorIP5ShapeSaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #9
  %234 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %41, i32 0, i32 0
  store ptr %233, ptr %234, align 8
  %235 = call noundef i64 @_ZNKSt6vectorIP5ShapeSaIS1_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #9
  %236 = udiv i64 %235, 2
  %237 = call ptr @_ZNK9__gnu_cxx17__normal_iteratorIPP5ShapeSt6vectorIS2_SaIS2_EEEplEl(ptr noundef nonnull align 8 dereferenceable(8) %41, i64 noundef %236) #9
  %238 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %40, i32 0, i32 0
  store ptr %237, ptr %238, align 8
  call void @llvm.lifetime.end.p0(i64 8, ptr %41) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr %42) #9
  %239 = call ptr @_ZNSt6vectorIP5ShapeSaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #9
  %240 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %42, i32 0, i32 0
  store ptr %239, ptr %240, align 8
  call void @llvm.lifetime.start.p0(i64 24, ptr %43) #9
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %44, ptr align 8 %39, i64 8, i1 false), !tbaa.struct !31
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %45, ptr align 8 %40, i64 8, i1 false), !tbaa.struct !31
  call void @llvm.lifetime.start.p0(i64 1, ptr %46) #9
  call void @_ZNSaIP5ShapeEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %46) #9
  %241 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %44, i32 0, i32 0
  %242 = load ptr, ptr %241, align 8
  %243 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %45, i32 0, i32 0
  %244 = load ptr, ptr %243, align 8
  invoke void @_ZNSt6vectorIP5ShapeSaIS1_EEC2IN9__gnu_cxx17__normal_iteratorIPS1_S3_EEvEET_S9_RKS2_(ptr noundef nonnull align 8 dereferenceable(24) %43, ptr %242, ptr %244, ptr noundef nonnull align 1 dereferenceable(1) %46)
          to label %245 unwind label %258

245:                                              ; preds = %230
  call void @_ZNSt15__new_allocatorIP5ShapeED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %46) #9
  call void @llvm.lifetime.end.p0(i64 1, ptr %46) #9
  call void @llvm.lifetime.start.p0(i64 24, ptr %47) #9
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %48, ptr align 8 %40, i64 8, i1 false), !tbaa.struct !31
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %49, ptr align 8 %42, i64 8, i1 false), !tbaa.struct !31
  call void @llvm.lifetime.start.p0(i64 1, ptr %50) #9
  call void @_ZNSaIP5ShapeEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %50) #9
  %246 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %48, i32 0, i32 0
  %247 = load ptr, ptr %246, align 8
  %248 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %49, i32 0, i32 0
  %249 = load ptr, ptr %248, align 8
  invoke void @_ZNSt6vectorIP5ShapeSaIS1_EEC2IN9__gnu_cxx17__normal_iteratorIPS1_S3_EEvEET_S9_RKS2_(ptr noundef nonnull align 8 dereferenceable(24) %47, ptr %247, ptr %249, ptr noundef nonnull align 1 dereferenceable(1) %50)
          to label %250 unwind label %262

250:                                              ; preds = %245
  call void @_ZNSt15__new_allocatorIP5ShapeED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %50) #9
  call void @llvm.lifetime.end.p0(i64 1, ptr %50) #9
  %251 = call noundef i64 @_ZNKSt6vectorIP5ShapeSaIS1_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #9
  %252 = call noundef i64 @_ZNKSt6vectorIP5ShapeSaIS1_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %43) #9
  %253 = call noundef i64 @_ZNKSt6vectorIP5ShapeSaIS1_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %47) #9
  %254 = add i64 %252, %253
  %255 = icmp eq i64 %251, %254
  br i1 %255, label %256, label %257

256:                                              ; preds = %250
  br label %267

257:                                              ; preds = %250
  call void @__assert_fail(ptr noundef @.str, ptr noundef @.str.4, i32 noundef 91, ptr noundef @__PRETTY_FUNCTION__._ZN8BVHAccel14recursiveBuildESt6vectorIP5ShapeSaIS2_EE) #12
  unreachable

258:                                              ; preds = %230
  %259 = landingpad { ptr, i32 }
          cleanup
  %260 = extractvalue { ptr, i32 } %259, 0
  store ptr %260, ptr %7, align 8
  %261 = extractvalue { ptr, i32 } %259, 1
  store i32 %261, ptr %8, align 4
  call void @_ZNSt15__new_allocatorIP5ShapeED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %46) #9
  call void @llvm.lifetime.end.p0(i64 1, ptr %46) #9
  br label %321

262:                                              ; preds = %245
  %263 = landingpad { ptr, i32 }
          cleanup
  %264 = extractvalue { ptr, i32 } %263, 0
  store ptr %264, ptr %7, align 8
  %265 = extractvalue { ptr, i32 } %263, 1
  store i32 %265, ptr %8, align 4
  call void @_ZNSt15__new_allocatorIP5ShapeED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %50) #9
  call void @llvm.lifetime.end.p0(i64 1, ptr %50) #9
  br label %320

266:                                              ; No predecessors!
  br label %267

267:                                              ; preds = %266, %256
  invoke void @_ZNSt6vectorIP5ShapeSaIS1_EEC2ERKS3_(ptr noundef nonnull align 8 dereferenceable(24) %51, ptr noundef nonnull align 8 dereferenceable(24) %43)
          to label %268 unwind label %303

268:                                              ; preds = %267
  %269 = invoke noundef ptr @_ZN8BVHAccel14recursiveBuildESt6vectorIP5ShapeSaIS2_EE(ptr noundef nonnull align 8 dereferenceable(40) %54, ptr noundef %51)
          to label %270 unwind label %307

270:                                              ; preds = %268
  %271 = load ptr, ptr %6, align 8, !tbaa !5
  %272 = getelementptr inbounds %struct.BVHBuildNode, ptr %271, i32 0, i32 1
  store ptr %269, ptr %272, align 8, !tbaa !23
  call void @_ZNSt6vectorIP5ShapeSaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %51) #9
  invoke void @_ZNSt6vectorIP5ShapeSaIS1_EEC2ERKS3_(ptr noundef nonnull align 8 dereferenceable(24) %52, ptr noundef nonnull align 8 dereferenceable(24) %47)
          to label %273 unwind label %303

273:                                              ; preds = %270
  %274 = invoke noundef ptr @_ZN8BVHAccel14recursiveBuildESt6vectorIP5ShapeSaIS2_EE(ptr noundef nonnull align 8 dereferenceable(40) %54, ptr noundef %52)
          to label %275 unwind label %311

275:                                              ; preds = %273
  %276 = load ptr, ptr %6, align 8, !tbaa !5
  %277 = getelementptr inbounds %struct.BVHBuildNode, ptr %276, i32 0, i32 2
  store ptr %274, ptr %277, align 8, !tbaa !24
  call void @_ZNSt6vectorIP5ShapeSaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %52) #9
  call void @llvm.lifetime.start.p0(i64 24, ptr %53) #9
  %278 = load ptr, ptr %6, align 8, !tbaa !5
  %279 = getelementptr inbounds %struct.BVHBuildNode, ptr %278, i32 0, i32 1
  %280 = load ptr, ptr %279, align 8, !tbaa !23
  %281 = getelementptr inbounds %struct.BVHBuildNode, ptr %280, i32 0, i32 0
  %282 = load ptr, ptr %6, align 8, !tbaa !5
  %283 = getelementptr inbounds %struct.BVHBuildNode, ptr %282, i32 0, i32 2
  %284 = load ptr, ptr %283, align 8, !tbaa !24
  %285 = getelementptr inbounds %struct.BVHBuildNode, ptr %284, i32 0, i32 0
  invoke void @_Z5UnionRK7Bounds3S1_(ptr dead_on_unwind writable sret(%class.Bounds3) align 4 %53, ptr noundef nonnull align 4 dereferenceable(24) %281, ptr noundef nonnull align 4 dereferenceable(24) %285)
          to label %286 unwind label %315

286:                                              ; preds = %275
  %287 = load ptr, ptr %6, align 8, !tbaa !5
  %288 = getelementptr inbounds %struct.BVHBuildNode, ptr %287, i32 0, i32 0
  %289 = call noundef nonnull align 4 dereferenceable(24) ptr @_ZN7Bounds3aSEOS_(ptr noundef nonnull align 4 dereferenceable(24) %288, ptr noundef nonnull align 4 dereferenceable(24) %53) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr %53) #9
  %290 = load ptr, ptr %6, align 8, !tbaa !5
  %291 = getelementptr inbounds %struct.BVHBuildNode, ptr %290, i32 0, i32 1
  %292 = load ptr, ptr %291, align 8, !tbaa !23
  %293 = getelementptr inbounds %struct.BVHBuildNode, ptr %292, i32 0, i32 4
  %294 = load float, ptr %293, align 8, !tbaa !25
  %295 = load ptr, ptr %6, align 8, !tbaa !5
  %296 = getelementptr inbounds %struct.BVHBuildNode, ptr %295, i32 0, i32 2
  %297 = load ptr, ptr %296, align 8, !tbaa !24
  %298 = getelementptr inbounds %struct.BVHBuildNode, ptr %297, i32 0, i32 4
  %299 = load float, ptr %298, align 8, !tbaa !25
  %300 = fadd float %294, %299
  %301 = load ptr, ptr %6, align 8, !tbaa !5
  %302 = getelementptr inbounds %struct.BVHBuildNode, ptr %301, i32 0, i32 4
  store float %300, ptr %302, align 8, !tbaa !25
  call void @_ZNSt6vectorIP5ShapeSaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %47) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr %47) #9
  call void @_ZNSt6vectorIP5ShapeSaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %43) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr %43) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %42) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %40) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %39) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %29) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr %24) #9
  br label %322

303:                                              ; preds = %270, %267
  %304 = landingpad { ptr, i32 }
          cleanup
  %305 = extractvalue { ptr, i32 } %304, 0
  store ptr %305, ptr %7, align 8
  %306 = extractvalue { ptr, i32 } %304, 1
  store i32 %306, ptr %8, align 4
  br label %319

307:                                              ; preds = %268
  %308 = landingpad { ptr, i32 }
          cleanup
  %309 = extractvalue { ptr, i32 } %308, 0
  store ptr %309, ptr %7, align 8
  %310 = extractvalue { ptr, i32 } %308, 1
  store i32 %310, ptr %8, align 4
  call void @_ZNSt6vectorIP5ShapeSaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %51) #9
  br label %319

311:                                              ; preds = %273
  %312 = landingpad { ptr, i32 }
          cleanup
  %313 = extractvalue { ptr, i32 } %312, 0
  store ptr %313, ptr %7, align 8
  %314 = extractvalue { ptr, i32 } %312, 1
  store i32 %314, ptr %8, align 4
  call void @_ZNSt6vectorIP5ShapeSaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %52) #9
  br label %319

315:                                              ; preds = %275
  %316 = landingpad { ptr, i32 }
          cleanup
  %317 = extractvalue { ptr, i32 } %316, 0
  store ptr %317, ptr %7, align 8
  %318 = extractvalue { ptr, i32 } %316, 1
  store i32 %318, ptr %8, align 4
  call void @llvm.lifetime.end.p0(i64 24, ptr %53) #9
  br label %319

319:                                              ; preds = %315, %311, %307, %303
  call void @_ZNSt6vectorIP5ShapeSaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %47) #9
  br label %320

320:                                              ; preds = %319, %262
  call void @llvm.lifetime.end.p0(i64 24, ptr %47) #9
  call void @_ZNSt6vectorIP5ShapeSaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %43) #9
  br label %321

321:                                              ; preds = %320, %258
  call void @llvm.lifetime.end.p0(i64 24, ptr %43) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %42) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %40) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %39) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %29) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr %24) #9
  br label %327

322:                                              ; preds = %286
  br label %323

323:                                              ; preds = %322
  %324 = load ptr, ptr %6, align 8, !tbaa !5
  store ptr %324, ptr %3, align 8
  store i32 1, ptr %14, align 4
  br label %325

325:                                              ; preds = %323, %135, %82
  call void @llvm.lifetime.end.p0(i64 24, ptr %9) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #9
  %326 = load ptr, ptr %3, align 8
  ret ptr %326

327:                                              ; preds = %321, %180, %171
  call void @llvm.lifetime.end.p0(i64 24, ptr %9) #9
  br label %328

328:                                              ; preds = %327, %63
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #9
  br label %329

329:                                              ; preds = %328
  %330 = load ptr, ptr %7, align 8
  %331 = load i32, ptr %8, align 4
  %332 = insertvalue { ptr, i32 } poison, ptr %330, 0
  %333 = insertvalue { ptr, i32 } %332, i32 %331, 1
  resume { ptr, i32 } %333
}

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

declare i32 @__gxx_personality_v0(...)

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

; Function Attrs: nobuiltin allocsize(0)
declare noundef nonnull ptr @_Znwm(i64 noundef) #3

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

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

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

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

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_Z5UnionRK7Bounds3S1_(ptr dead_on_unwind noalias writable sret(%class.Bounds3) align 4, ptr noundef nonnull align 4 dereferenceable(24), ptr noundef nonnull align 4 dereferenceable(24)) #5

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(24) ptr @_ZN7Bounds3aSEOS_(ptr noundef nonnull align 4 dereferenceable(24), ptr noundef nonnull align 4 dereferenceable(24)) #6 align 2

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

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

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_Z5UnionRK7Bounds3RKN5Eigen6MatrixIfLi3ELi1ELi0ELi3ELi1EEE(ptr dead_on_unwind noalias writable sret(%class.Bounds3) align 4, ptr noundef nonnull align 4 dereferenceable(24), ptr noundef nonnull align 4 dereferenceable(12)) #5

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN7Bounds38CentroidEv(ptr dead_on_unwind noalias writable sret(%"class.Eigen::Matrix") align 4, ptr noundef nonnull align 4 dereferenceable(24)) #1 align 2

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

; Function Attrs: inlinehint mustprogress uwtable
declare hidden void @"_ZSt4sortIN9__gnu_cxx17__normal_iteratorIPP5ShapeSt6vectorIS3_SaIS3_EEEEZN8BVHAccel14recursiveBuildES7_E3$_0EvT_SB_T0_"(ptr, ptr) #5

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

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

; Function Attrs: inlinehint mustprogress uwtable
declare hidden void @"_ZSt4sortIN9__gnu_cxx17__normal_iteratorIPP5ShapeSt6vectorIS3_SaIS3_EEEEZN8BVHAccel14recursiveBuildES7_E3$_1EvT_SB_T0_"(ptr, ptr) #5

; Function Attrs: inlinehint mustprogress uwtable
declare hidden void @"_ZSt4sortIN9__gnu_cxx17__normal_iteratorIPP5ShapeSt6vectorIS3_SaIS3_EEEEZN8BVHAccel14recursiveBuildES7_E3$_2EvT_SB_T0_"(ptr, ptr) #5

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

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #7

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

; Function Attrs: noreturn nounwind
declare void @__assert_fail(ptr noundef, ptr noundef, i32 noundef, ptr noundef) #8

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

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

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"int", !7, i64 0}
!11 = !{!12, !12, i64 0}
!12 = !{!"vtable pointer", !8, i64 0}
!13 = distinct !{!13, !14}
!14 = !{!"llvm.loop.mustprogress"}
!15 = !{!16, !6, i64 40}
!16 = !{!"_ZTS12BVHBuildNode", !17, i64 0, !6, i64 24, !6, i64 32, !6, i64 40, !22, i64 48, !10, i64 52, !10, i64 56, !10, i64 60}
!17 = !{!"_ZTS7Bounds3", !18, i64 0, !18, i64 12}
!18 = !{!"_ZTSN5Eigen6MatrixIfLi3ELi1ELi0ELi3ELi1EEE", !19, i64 0}
!19 = !{!"_ZTSN5Eigen15PlainObjectBaseINS_6MatrixIfLi3ELi1ELi0ELi3ELi1EEEEE", !20, i64 0}
!20 = !{!"_ZTSN5Eigen12DenseStorageIfLi3ELi3ELi1ELi0EEE", !21, i64 0}
!21 = !{!"_ZTSN5Eigen8internal11plain_arrayIfLi3ELi0ELi0EEE", !7, i64 0}
!22 = !{!"float", !7, i64 0}
!23 = !{!16, !6, i64 24}
!24 = !{!16, !6, i64 32}
!25 = !{!16, !22, i64 48}
!26 = !{!27, !6, i64 0}
!27 = !{!"_ZTSSt16initializer_listIP5ShapeE", !6, i64 0, !28, i64 8}
!28 = !{!"long", !7, i64 0}
!29 = !{!27, !28, i64 8}
!30 = distinct !{!30, !14}
!31 = !{i64 0, i64 8, !5}


; 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.Bounds3 = type { %"class.Eigen::Matrix", %"class.Eigen::Matrix" }
%"class.Eigen::Matrix" = type { %"class.Eigen::PlainObjectBase" }
%"class.Eigen::PlainObjectBase" = type { %"class.Eigen::DenseStorage" }
%"class.Eigen::DenseStorage" = type { %"struct.Eigen::internal::plain_array" }
%"struct.Eigen::internal::plain_array" = type { [3 x float] }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<Shape *, std::allocator<Shape *>>::_Vector_impl" }
%"struct.std::_Vector_base<Shape *, std::allocator<Shape *>>::_Vector_impl" = type { %"struct.std::_Vector_base<Shape *, std::allocator<Shape *>>::_Vector_impl_data" }
%"struct.std::_Vector_base<Shape *, std::allocator<Shape *>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::allocator" = type { i8 }
%"class.__gnu_cxx::__normal_iterator" = type { ptr }

@.str = external hidden unnamed_addr constant [58 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [67 x i8], align 1
@__PRETTY_FUNCTION__._ZN8BVHAccel14recursiveBuildESt6vectorIP5ShapeSaIS2_EE = external hidden unnamed_addr constant [61 x i8], align 1

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

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

; Function Attrs: mustprogress uwtable
define dso_local noundef ptr @_ZN8BVHAccel14recursiveBuildESt6vectorIP5ShapeSaIS2_EE(ptr noundef nonnull align 8 dereferenceable(40) %0, ptr noundef %1) local_unnamed_addr #1 align 2 personality ptr @__gxx_personality_v0 {
  %3 = alloca %class.Bounds3, align 4
  %4 = alloca %class.Bounds3, align 4
  %5 = alloca %class.Bounds3, align 4
  %6 = alloca %class.Bounds3, align 4
  %7 = alloca %"class.std::vector", align 8
  %8 = alloca [1 x ptr], align 8
  %9 = alloca %"class.std::allocator", align 1
  %10 = alloca %"class.std::vector", align 8
  %11 = alloca [1 x ptr], align 8
  %12 = alloca %"class.std::allocator", align 1
  %13 = alloca %class.Bounds3, align 4
  %14 = alloca %class.Bounds3, align 4
  %15 = alloca %class.Bounds3, align 4
  %16 = alloca %"class.Eigen::Matrix", align 4
  %17 = alloca %class.Bounds3, align 4
  %18 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %19 = alloca %"class.std::vector", align 8
  %20 = alloca %"class.std::allocator", align 1
  %21 = alloca %"class.std::vector", align 8
  %22 = alloca %"class.std::allocator", align 1
  %23 = alloca %"class.std::vector", align 8
  %24 = alloca %"class.std::vector", align 8
  %25 = alloca %class.Bounds3, align 4
  %26 = tail call noalias noundef nonnull dereferenceable(64) ptr @_Znwm(i64 noundef 64) #9
  invoke void @_ZN12BVHBuildNodeC2Ev(ptr noundef nonnull align 8 dereferenceable(64) %26)
          to label %27 unwind label %31

27:                                               ; preds = %2
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %3) #10
  call void @_ZN7Bounds3C2Ev(ptr noundef nonnull align 4 dereferenceable(24) %3)
  %28 = call noundef i64 @_ZNKSt6vectorIP5ShapeSaIS1_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #10
  %.not = icmp eq i64 %28, 0
  br i1 %.not, label %._crit_edge, label %.lr.ph

._crit_edge:                                      ; preds = %.lr.ph, %27
  %29 = call noundef i64 @_ZNKSt6vectorIP5ShapeSaIS1_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #10
  %30 = icmp eq i64 %29, 1
  br i1 %30, label %41, label %59

31:                                               ; preds = %2
  %32 = landingpad { ptr, i32 }
          cleanup
  tail call void @_ZdlPvm(ptr noundef nonnull %26, i64 noundef 64) #11
  br label %169

.lr.ph:                                           ; preds = %27, %.lr.ph
  %indvars.iv = phi i64 [ %indvars.iv.next, %.lr.ph ], [ 0, %27 ]
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %4) #10
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %5) #10
  %33 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIP5ShapeSaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef %indvars.iv) #10
  %34 = load ptr, ptr %33, align 8, !tbaa !5
  %35 = load ptr, ptr %34, align 8, !tbaa !9
  %36 = getelementptr inbounds i8, ptr %35, i64 32
  %37 = load ptr, ptr %36, align 8
  call void %37(ptr dead_on_unwind nonnull writable sret(%class.Bounds3) align 4 %5, ptr noundef nonnull align 8 dereferenceable(8) %34)
  call void @_Z5UnionRK7Bounds3S1_(ptr dead_on_unwind nonnull writable sret(%class.Bounds3) align 4 %4, ptr noundef nonnull align 4 dereferenceable(24) %3, ptr noundef nonnull align 4 dereferenceable(24) %5)
  %38 = call noundef nonnull align 4 dereferenceable(24) ptr @_ZN7Bounds3aSEOS_(ptr noundef nonnull align 4 dereferenceable(24) %3, ptr noundef nonnull align 4 dereferenceable(24) %4) #10
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %5) #10
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %4) #10
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %39 = call noundef i64 @_ZNKSt6vectorIP5ShapeSaIS1_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #10
  %40 = icmp ugt i64 %39, %indvars.iv.next
  br i1 %40, label %.lr.ph, label %._crit_edge, !llvm.loop !11

41:                                               ; preds = %._crit_edge
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %6) #10
  %42 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIP5ShapeSaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef 0) #10
  %43 = load ptr, ptr %42, align 8, !tbaa !5
  %44 = load ptr, ptr %43, align 8, !tbaa !9
  %45 = getelementptr inbounds i8, ptr %44, i64 32
  %46 = load ptr, ptr %45, align 8
  call void %46(ptr dead_on_unwind nonnull writable sret(%class.Bounds3) align 4 %6, ptr noundef nonnull align 8 dereferenceable(8) %43)
  %47 = call noundef nonnull align 4 dereferenceable(24) ptr @_ZN7Bounds3aSEOS_(ptr noundef nonnull align 4 dereferenceable(24) %26, ptr noundef nonnull align 4 dereferenceable(24) %6) #10
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %6) #10
  %48 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIP5ShapeSaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef 0) #10
  %49 = load ptr, ptr %48, align 8, !tbaa !5
  %50 = getelementptr inbounds i8, ptr %26, i64 40
  store ptr %49, ptr %50, align 8, !tbaa !13
  %51 = getelementptr inbounds i8, ptr %26, i64 24
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %51, i8 0, i64 16, i1 false)
  %52 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIP5ShapeSaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef 0) #10
  %53 = load ptr, ptr %52, align 8, !tbaa !5
  %54 = load ptr, ptr %53, align 8, !tbaa !9
  %55 = getelementptr inbounds i8, ptr %54, i64 16
  %56 = load ptr, ptr %55, align 8
  %57 = call noundef float %56(ptr noundef nonnull align 8 dereferenceable(8) %53)
  %58 = getelementptr inbounds i8, ptr %26, i64 48
  store float %57, ptr %58, align 8, !tbaa !22
  br label %167

59:                                               ; preds = %._crit_edge
  %60 = call noundef i64 @_ZNKSt6vectorIP5ShapeSaIS1_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #10
  %61 = icmp eq i64 %60, 2
  br i1 %61, label %62, label %96

62:                                               ; preds = %59
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %8) #10
  %63 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIP5ShapeSaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef 0) #10
  %64 = load ptr, ptr %63, align 8, !tbaa !5
  store ptr %64, ptr %8, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %9) #10
  call void @_ZNSaIP5ShapeEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %9) #10
  invoke void @_ZNSt6vectorIP5ShapeSaIS1_EEC2ESt16initializer_listIS1_ERKS2_(ptr noundef nonnull align 8 dereferenceable(24) %7, ptr nonnull %8, i64 1, ptr noundef nonnull align 1 dereferenceable(1) %9)
          to label %65 unwind label %86

65:                                               ; preds = %62
  %66 = invoke noundef ptr @_ZN8BVHAccel14recursiveBuildESt6vectorIP5ShapeSaIS2_EE(ptr noundef nonnull align 8 dereferenceable(40) %0, ptr noundef nonnull %7)
          to label %67 unwind label %88

67:                                               ; preds = %65
  %68 = getelementptr inbounds i8, ptr %26, i64 24
  store ptr %66, ptr %68, align 8, !tbaa !23
  call void @_ZNSt6vectorIP5ShapeSaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %7) #10
  call void @_ZNSt15__new_allocatorIP5ShapeED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %9) #10
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %9) #10
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #10
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %11) #10
  %69 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIP5ShapeSaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef 1) #10
  %70 = load ptr, ptr %69, align 8, !tbaa !5
  store ptr %70, ptr %11, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %12) #10
  call void @_ZNSaIP5ShapeEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %12) #10
  invoke void @_ZNSt6vectorIP5ShapeSaIS1_EEC2ESt16initializer_listIS1_ERKS2_(ptr noundef nonnull align 8 dereferenceable(24) %10, ptr nonnull %11, i64 1, ptr noundef nonnull align 1 dereferenceable(1) %12)
          to label %71 unwind label %91

71:                                               ; preds = %67
  %72 = invoke noundef ptr @_ZN8BVHAccel14recursiveBuildESt6vectorIP5ShapeSaIS2_EE(ptr noundef nonnull align 8 dereferenceable(40) %0, ptr noundef nonnull %10)
          to label %73 unwind label %93

73:                                               ; preds = %71
  %74 = getelementptr inbounds i8, ptr %26, i64 32
  store ptr %72, ptr %74, align 8, !tbaa !24
  call void @_ZNSt6vectorIP5ShapeSaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %10) #10
  call void @_ZNSt15__new_allocatorIP5ShapeED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %12) #10
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %12) #10
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %11) #10
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %13) #10
  %75 = load ptr, ptr %68, align 8, !tbaa !23
  %76 = load ptr, ptr %74, align 8, !tbaa !24
  call void @_Z5UnionRK7Bounds3S1_(ptr dead_on_unwind nonnull writable sret(%class.Bounds3) align 4 %13, ptr noundef nonnull align 4 dereferenceable(24) %75, ptr noundef nonnull align 4 dereferenceable(24) %76)
  %77 = call noundef nonnull align 4 dereferenceable(24) ptr @_ZN7Bounds3aSEOS_(ptr noundef nonnull align 4 dereferenceable(24) %26, ptr noundef nonnull align 4 dereferenceable(24) %13) #10
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %13) #10
  %78 = load ptr, ptr %68, align 8, !tbaa !23
  %79 = getelementptr inbounds i8, ptr %78, i64 48
  %80 = load float, ptr %79, align 8, !tbaa !22
  %81 = load ptr, ptr %74, align 8, !tbaa !24
  %82 = getelementptr inbounds i8, ptr %81, i64 48
  %83 = load float, ptr %82, align 8, !tbaa !22
  %84 = fadd float %80, %83
  %85 = getelementptr inbounds i8, ptr %26, i64 48
  store float %84, ptr %85, align 8, !tbaa !22
  br label %167

86:                                               ; preds = %62
  %87 = landingpad { ptr, i32 }
          cleanup
  br label %90

88:                                               ; preds = %65
  %89 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt6vectorIP5ShapeSaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %7) #10
  br label %90

90:                                               ; preds = %88, %86
  %.pn63 = phi { ptr, i32 } [ %89, %88 ], [ %87, %86 ]
  call void @_ZNSt15__new_allocatorIP5ShapeED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %9) #10
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %9) #10
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #10
  br label %168

91:                                               ; preds = %67
  %92 = landingpad { ptr, i32 }
          cleanup
  br label %95

93:                                               ; preds = %71
  %94 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt6vectorIP5ShapeSaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %10) #10
  br label %95

95:                                               ; preds = %93, %91
  %.pn65 = phi { ptr, i32 } [ %94, %93 ], [ %92, %91 ]
  call void @_ZNSt15__new_allocatorIP5ShapeED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %12) #10
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %12) #10
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %11) #10
  br label %168

96:                                               ; preds = %59
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %14) #10
  call void @_ZN7Bounds3C2Ev(ptr noundef nonnull align 4 dereferenceable(24) %14)
  %97 = call noundef i64 @_ZNKSt6vectorIP5ShapeSaIS1_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #10
  %.not74 = icmp eq i64 %97, 0
  br i1 %.not74, label %._crit_edge73, label %.lr.ph72

._crit_edge73:                                    ; preds = %.lr.ph72, %96
  %98 = call noundef i32 @_ZNK7Bounds39maxExtentEv(ptr noundef nonnull align 4 dereferenceable(24) %14)
  switch i32 %98, label %116 [
    i32 0, label %107
    i32 1, label %110
    i32 2, label %113
  ]

.lr.ph72:                                         ; preds = %96, %.lr.ph72
  %indvars.iv76 = phi i64 [ %indvars.iv.next77, %.lr.ph72 ], [ 0, %96 ]
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %15) #10
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %16) #10
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %17) #10
  %99 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIP5ShapeSaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef %indvars.iv76) #10
  %100 = load ptr, ptr %99, align 8, !tbaa !5
  %101 = load ptr, ptr %100, align 8, !tbaa !9
  %102 = getelementptr inbounds i8, ptr %101, i64 32
  %103 = load ptr, ptr %102, align 8
  call void %103(ptr dead_on_unwind nonnull writable sret(%class.Bounds3) align 4 %17, ptr noundef nonnull align 8 dereferenceable(8) %100)
  call void @_ZN7Bounds38CentroidEv(ptr dead_on_unwind nonnull writable sret(%"class.Eigen::Matrix") align 4 %16, ptr noundef nonnull align 4 dereferenceable(24) %17)
  call void @_Z5UnionRK7Bounds3RKN5Eigen6MatrixIfLi3ELi1ELi0ELi3ELi1EEE(ptr dead_on_unwind nonnull writable sret(%class.Bounds3) align 4 %15, ptr noundef nonnull align 4 dereferenceable(24) %14, ptr noundef nonnull align 4 dereferenceable(12) %16)
  %104 = call noundef nonnull align 4 dereferenceable(24) ptr @_ZN7Bounds3aSEOS_(ptr noundef nonnull align 4 dereferenceable(24) %14, ptr noundef nonnull align 4 dereferenceable(24) %15) #10
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %17) #10
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %16) #10
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %15) #10
  %indvars.iv.next77 = add nuw nsw i64 %indvars.iv76, 1
  %105 = call noundef i64 @_ZNKSt6vectorIP5ShapeSaIS1_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #10
  %106 = icmp ugt i64 %105, %indvars.iv.next77
  br i1 %106, label %.lr.ph72, label %._crit_edge73, !llvm.loop !25

107:                                              ; preds = %._crit_edge73
  %108 = call ptr @_ZNSt6vectorIP5ShapeSaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #10
  %109 = call ptr @_ZNSt6vectorIP5ShapeSaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #10
  call void @"_ZSt4sortIN9__gnu_cxx17__normal_iteratorIPP5ShapeSt6vectorIS3_SaIS3_EEEEZN8BVHAccel14recursiveBuildES7_E3$_0EvT_SB_T0_"(ptr %108, ptr %109)
  br label %116

110:                                              ; preds = %._crit_edge73
  %111 = call ptr @_ZNSt6vectorIP5ShapeSaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #10
  %112 = call ptr @_ZNSt6vectorIP5ShapeSaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #10
  call void @"_ZSt4sortIN9__gnu_cxx17__normal_iteratorIPP5ShapeSt6vectorIS3_SaIS3_EEEEZN8BVHAccel14recursiveBuildES7_E3$_1EvT_SB_T0_"(ptr %111, ptr %112)
  br label %116

113:                                              ; preds = %._crit_edge73
  %114 = call ptr @_ZNSt6vectorIP5ShapeSaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #10
  %115 = call ptr @_ZNSt6vectorIP5ShapeSaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #10
  call void @"_ZSt4sortIN9__gnu_cxx17__normal_iteratorIPP5ShapeSt6vectorIS3_SaIS3_EEEEZN8BVHAccel14recursiveBuildES7_E3$_2EvT_SB_T0_"(ptr %114, ptr %115)
  br label %116

116:                                              ; preds = %113, %110, %107, %._crit_edge73
  %117 = call ptr @_ZNSt6vectorIP5ShapeSaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #10
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %18) #10
  %118 = call ptr @_ZNSt6vectorIP5ShapeSaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #10
  store ptr %118, ptr %18, align 8
  %119 = call noundef i64 @_ZNKSt6vectorIP5ShapeSaIS1_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #10
  %120 = lshr i64 %119, 1
  %121 = call ptr @_ZNK9__gnu_cxx17__normal_iteratorIPP5ShapeSt6vectorIS2_SaIS2_EEEplEl(ptr noundef nonnull align 8 dereferenceable(8) %18, i64 noundef %120) #10
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %18) #10
  %122 = call ptr @_ZNSt6vectorIP5ShapeSaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #10
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %19) #10
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %20) #10
  call void @_ZNSaIP5ShapeEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %20) #10
  invoke void @_ZNSt6vectorIP5ShapeSaIS1_EEC2IN9__gnu_cxx17__normal_iteratorIPS1_S3_EEvEET_S9_RKS2_(ptr noundef nonnull align 8 dereferenceable(24) %19, ptr %117, ptr %121, ptr noundef nonnull align 1 dereferenceable(1) %20)
          to label %123 unwind label %131

123:                                              ; preds = %116
  call void @_ZNSt15__new_allocatorIP5ShapeED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %20) #10
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %20) #10
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %21) #10
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %22) #10
  call void @_ZNSaIP5ShapeEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %22) #10
  invoke void @_ZNSt6vectorIP5ShapeSaIS1_EEC2IN9__gnu_cxx17__normal_iteratorIPS1_S3_EEvEET_S9_RKS2_(ptr noundef nonnull align 8 dereferenceable(24) %21, ptr %121, ptr %122, ptr noundef nonnull align 1 dereferenceable(1) %22)
          to label %124 unwind label %133

124:                                              ; preds = %123
  call void @_ZNSt15__new_allocatorIP5ShapeED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %22) #10
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %22) #10
  %125 = call noundef i64 @_ZNKSt6vectorIP5ShapeSaIS1_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #10
  %126 = call noundef i64 @_ZNKSt6vectorIP5ShapeSaIS1_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %19) #10
  %127 = call noundef i64 @_ZNKSt6vectorIP5ShapeSaIS1_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %21) #10
  %128 = add i64 %127, %126
  %129 = icmp eq i64 %125, %128
  br i1 %129, label %135, label %130

130:                                              ; preds = %124
  call void @__assert_fail(ptr noundef nonnull @.str, ptr noundef nonnull @.str.4, i32 noundef 91, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN8BVHAccel14recursiveBuildESt6vectorIP5ShapeSaIS2_EE) #12
  unreachable

131:                                              ; preds = %116
  %132 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt15__new_allocatorIP5ShapeED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %20) #10
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %20) #10
  br label %166

133:                                              ; preds = %123
  %134 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt15__new_allocatorIP5ShapeED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %22) #10
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %22) #10
  br label %165

135:                                              ; preds = %124
  invoke void @_ZNSt6vectorIP5ShapeSaIS1_EEC2ERKS3_(ptr noundef nonnull align 8 dereferenceable(24) %23, ptr noundef nonnull align 8 dereferenceable(24) %19)
          to label %136 unwind label %156

136:                                              ; preds = %135
  %137 = invoke noundef ptr @_ZN8BVHAccel14recursiveBuildESt6vectorIP5ShapeSaIS2_EE(ptr noundef nonnull align 8 dereferenceable(40) %0, ptr noundef nonnull %23)
          to label %138 unwind label %158

138:                                              ; preds = %136
  %139 = getelementptr inbounds i8, ptr %26, i64 24
  store ptr %137, ptr %139, align 8, !tbaa !23
  call void @_ZNSt6vectorIP5ShapeSaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %23) #10
  invoke void @_ZNSt6vectorIP5ShapeSaIS1_EEC2ERKS3_(ptr noundef nonnull align 8 dereferenceable(24) %24, ptr noundef nonnull align 8 dereferenceable(24) %21)
          to label %140 unwind label %156

140:                                              ; preds = %138
  %141 = invoke noundef ptr @_ZN8BVHAccel14recursiveBuildESt6vectorIP5ShapeSaIS2_EE(ptr noundef nonnull align 8 dereferenceable(40) %0, ptr noundef nonnull %24)
          to label %142 unwind label %160

142:                                              ; preds = %140
  %143 = getelementptr inbounds i8, ptr %26, i64 32
  store ptr %141, ptr %143, align 8, !tbaa !24
  call void @_ZNSt6vectorIP5ShapeSaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %24) #10
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %25) #10
  %144 = load ptr, ptr %139, align 8, !tbaa !23
  %145 = load ptr, ptr %143, align 8, !tbaa !24
  invoke void @_Z5UnionRK7Bounds3S1_(ptr dead_on_unwind nonnull writable sret(%class.Bounds3) align 4 %25, ptr noundef nonnull align 4 dereferenceable(24) %144, ptr noundef nonnull align 4 dereferenceable(24) %145)
          to label %146 unwind label %162

146:                                              ; preds = %142
  %147 = call noundef nonnull align 4 dereferenceable(24) ptr @_ZN7Bounds3aSEOS_(ptr noundef nonnull align 4 dereferenceable(24) %26, ptr noundef nonnull align 4 dereferenceable(24) %25) #10
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %25) #10
  %148 = load ptr, ptr %139, align 8, !tbaa !23
  %149 = getelementptr inbounds i8, ptr %148, i64 48
  %150 = load float, ptr %149, align 8, !tbaa !22
  %151 = load ptr, ptr %143, align 8, !tbaa !24
  %152 = getelementptr inbounds i8, ptr %151, i64 48
  %153 = load float, ptr %152, align 8, !tbaa !22
  %154 = fadd float %150, %153
  %155 = getelementptr inbounds i8, ptr %26, i64 48
  store float %154, ptr %155, align 8, !tbaa !22
  call void @_ZNSt6vectorIP5ShapeSaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %21) #10
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %21) #10
  call void @_ZNSt6vectorIP5ShapeSaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %19) #10
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %19) #10
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %14) #10
  br label %167

156:                                              ; preds = %138, %135
  %157 = landingpad { ptr, i32 }
          cleanup
  br label %164

158:                                              ; preds = %136
  %159 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt6vectorIP5ShapeSaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %23) #10
  br label %164

160:                                              ; preds = %140
  %161 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt6vectorIP5ShapeSaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %24) #10
  br label %164

162:                                              ; preds = %142
  %163 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %25) #10
  br label %164

164:                                              ; preds = %162, %160, %158, %156
  %.pn = phi { ptr, i32 } [ %163, %162 ], [ %161, %160 ], [ %157, %156 ], [ %159, %158 ]
  call void @_ZNSt6vectorIP5ShapeSaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %21) #10
  br label %165

165:                                              ; preds = %164, %133
  %.pn.pn = phi { ptr, i32 } [ %.pn, %164 ], [ %134, %133 ]
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %21) #10
  call void @_ZNSt6vectorIP5ShapeSaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %19) #10
  br label %166

166:                                              ; preds = %165, %131
  %.pn.pn.pn = phi { ptr, i32 } [ %.pn.pn, %165 ], [ %132, %131 ]
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %19) #10
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %14) #10
  br label %168

167:                                              ; preds = %146, %73, %41
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %3) #10
  ret ptr %26

168:                                              ; preds = %166, %95, %90
  %.pn65.pn = phi { ptr, i32 } [ %.pn65, %95 ], [ %.pn63, %90 ], [ %.pn.pn.pn, %166 ]
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %3) #10
  br label %169

169:                                              ; preds = %168, %31
  %.pn65.pn.pn = phi { ptr, i32 } [ %.pn65.pn, %168 ], [ %32, %31 ]
  resume { ptr, i32 } %.pn65.pn.pn
}

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

declare i32 @__gxx_personality_v0(...)

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

; Function Attrs: nobuiltin allocsize(0)
declare noundef nonnull ptr @_Znwm(i64 noundef) local_unnamed_addr #3

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

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

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

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

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_Z5UnionRK7Bounds3S1_(ptr dead_on_unwind noalias writable sret(%class.Bounds3) align 4, ptr noundef nonnull align 4 dereferenceable(24), ptr noundef nonnull align 4 dereferenceable(24)) local_unnamed_addr #5

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(24) ptr @_ZN7Bounds3aSEOS_(ptr noundef nonnull align 4 dereferenceable(24), ptr noundef nonnull align 4 dereferenceable(24)) local_unnamed_addr #6 align 2

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

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

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_Z5UnionRK7Bounds3RKN5Eigen6MatrixIfLi3ELi1ELi0ELi3ELi1EEE(ptr dead_on_unwind noalias writable sret(%class.Bounds3) align 4, ptr noundef nonnull align 4 dereferenceable(24), ptr noundef nonnull align 4 dereferenceable(12)) local_unnamed_addr #5

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN7Bounds38CentroidEv(ptr dead_on_unwind noalias writable sret(%"class.Eigen::Matrix") align 4, ptr noundef nonnull align 4 dereferenceable(24)) local_unnamed_addr #1 align 2

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

; Function Attrs: inlinehint mustprogress uwtable
declare hidden void @"_ZSt4sortIN9__gnu_cxx17__normal_iteratorIPP5ShapeSt6vectorIS3_SaIS3_EEEEZN8BVHAccel14recursiveBuildES7_E3$_0EvT_SB_T0_"(ptr, ptr) local_unnamed_addr #5

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

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

; Function Attrs: inlinehint mustprogress uwtable
declare hidden void @"_ZSt4sortIN9__gnu_cxx17__normal_iteratorIPP5ShapeSt6vectorIS3_SaIS3_EEEEZN8BVHAccel14recursiveBuildES7_E3$_1EvT_SB_T0_"(ptr, ptr) local_unnamed_addr #5

; Function Attrs: inlinehint mustprogress uwtable
declare hidden void @"_ZSt4sortIN9__gnu_cxx17__normal_iteratorIPP5ShapeSt6vectorIS3_SaIS3_EEEEZN8BVHAccel14recursiveBuildES7_E3$_2EvT_SB_T0_"(ptr, ptr) local_unnamed_addr #5

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

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

; Function Attrs: noreturn nounwind
declare void @__assert_fail(ptr noundef, ptr noundef, i32 noundef, ptr noundef) local_unnamed_addr #7

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

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: write)
declare void @llvm.memset.p0.i64(ptr nocapture writeonly, i8, i64, i1 immarg) #8

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

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"vtable pointer", !8, i64 0}
!11 = distinct !{!11, !12}
!12 = !{!"llvm.loop.mustprogress"}
!13 = !{!14, !6, i64 40}
!14 = !{!"_ZTS12BVHBuildNode", !15, i64 0, !6, i64 24, !6, i64 32, !6, i64 40, !20, i64 48, !21, i64 52, !21, i64 56, !21, i64 60}
!15 = !{!"_ZTS7Bounds3", !16, i64 0, !16, i64 12}
!16 = !{!"_ZTSN5Eigen6MatrixIfLi3ELi1ELi0ELi3ELi1EEE", !17, i64 0}
!17 = !{!"_ZTSN5Eigen15PlainObjectBaseINS_6MatrixIfLi3ELi1ELi0ELi3ELi1EEEEE", !18, i64 0}
!18 = !{!"_ZTSN5Eigen12DenseStorageIfLi3ELi3ELi1ELi0EEE", !19, i64 0}
!19 = !{!"_ZTSN5Eigen8internal11plain_arrayIfLi3ELi0ELi0EEE", !7, i64 0}
!20 = !{!"float", !7, i64 0}
!21 = !{!"int", !7, i64 0}
!22 = !{!14, !20, i64 48}
!23 = !{!14, !6, i64 24}
!24 = !{!14, !6, i64 32}
!25 = distinct !{!25, !12}


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