; LLVM IR from yangfengzzz/Arche-webgpu :: vox.geometry (implicit_surface_set2)

; 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.__gnu_cxx::__normal_iterator" = type { ptr }
%"class.vox::ImplicitSurfaceSet2" = type <{ %"class.vox::ImplicitSurface2.base", [7 x i8], %"class.std::vector", %"class.std::vector", %"class.vox::Bvh2", i8, [7 x i8] }>
%"class.vox::ImplicitSurface2.base" = type { %"class.vox::Surface2.base" }
%"class.vox::Surface2.base" = type <{ ptr, %"class.vox::Transform2", i8 }>
%"class.vox::Transform2" = type { %"struct.vox::Vector", double, double, double }
%"struct.vox::Vector" = type { double, double }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<std::shared_ptr<vox::ImplicitSurface2>, std::allocator<std::shared_ptr<vox::ImplicitSurface2>>>::_Vector_impl" }
%"struct.std::_Vector_base<std::shared_ptr<vox::ImplicitSurface2>, std::allocator<std::shared_ptr<vox::ImplicitSurface2>>>::_Vector_impl" = type { %"struct.std::_Vector_base<std::shared_ptr<vox::ImplicitSurface2>, std::allocator<std::shared_ptr<vox::ImplicitSurface2>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<std::shared_ptr<vox::ImplicitSurface2>, std::allocator<std::shared_ptr<vox::ImplicitSurface2>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.vox::Bvh2" = type { %"class.vox::IntersectionQueryEngine2", %"class.vox::NearestNeighborQueryEngine2", %"struct.vox::BoundingBox", %"class.std::vector", %"class.std::vector.0", %"class.std::vector.5" }
%"class.vox::IntersectionQueryEngine2" = type { ptr }
%"class.vox::NearestNeighborQueryEngine2" = type { ptr }
%"struct.vox::BoundingBox" = type { %"struct.vox::Point", %"struct.vox::Point" }
%"struct.vox::Point" = type { double, double }
%"class.std::vector.0" = type { %"struct.std::_Vector_base.1" }
%"struct.std::_Vector_base.1" = type { %"struct.std::_Vector_base<vox::BoundingBox<double, 2>, std::allocator<vox::BoundingBox<double, 2>>>::_Vector_impl" }
%"struct.std::_Vector_base<vox::BoundingBox<double, 2>, std::allocator<vox::BoundingBox<double, 2>>>::_Vector_impl" = type { %"struct.std::_Vector_base<vox::BoundingBox<double, 2>, std::allocator<vox::BoundingBox<double, 2>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<vox::BoundingBox<double, 2>, std::allocator<vox::BoundingBox<double, 2>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::vector.5" = type { %"struct.std::_Vector_base.6" }
%"struct.std::_Vector_base.6" = type { %"struct.std::_Vector_base<vox::Bvh2<std::shared_ptr<vox::ImplicitSurface2>>::Node, std::allocator<vox::Bvh2<std::shared_ptr<vox::ImplicitSurface2>>::Node>>::_Vector_impl" }
%"struct.std::_Vector_base<vox::Bvh2<std::shared_ptr<vox::ImplicitSurface2>>::Node, std::allocator<vox::Bvh2<std::shared_ptr<vox::ImplicitSurface2>>::Node>>::_Vector_impl" = type { %"struct.std::_Vector_base<vox::Bvh2<std::shared_ptr<vox::ImplicitSurface2>>::Node, std::allocator<vox::Bvh2<std::shared_ptr<vox::ImplicitSurface2>>::Node>>::_Vector_impl_data" }
%"struct.std::_Vector_base<vox::Bvh2<std::shared_ptr<vox::ImplicitSurface2>>::Node, std::allocator<vox::Bvh2<std::shared_ptr<vox::ImplicitSurface2>>::Node>>::_Vector_impl_data" = type { ptr, ptr, ptr }

@_ZTVN3vox19ImplicitSurfaceSet2E = external dso_local unnamed_addr constant { [15 x ptr] }, align 8

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

declare void @_ZN3vox16ImplicitSurface2C2ERKNS_10Transform2IdEEb(ptr noundef nonnull align 8 dereferenceable(49), ptr noundef nonnull align 8 dereferenceable(40), i1 noundef zeroext) unnamed_addr #1

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

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

declare i32 @__gxx_personality_v0(...)

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

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN3vox19ImplicitSurfaceSet2C2ESt6vectorISt10shared_ptrINS_16ImplicitSurface2EESaIS4_EERKNS_10Transform2IdEEb(ptr noundef nonnull align 8 dereferenceable(232) %0, ptr noundef %1, ptr noundef nonnull align 8 dereferenceable(40) %2, i1 noundef zeroext %3) unnamed_addr #3 align 2 personality ptr @__gxx_personality_v0 {
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  %8 = alloca i8, align 1
  %9 = alloca ptr, align 8
  %10 = alloca i32, align 4
  %11 = alloca ptr, align 8
  %12 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %13 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %14 = alloca ptr, align 8
  store ptr %0, ptr %5, align 8, !tbaa !5
  store ptr %1, ptr %6, align 8, !tbaa !5
  store ptr %2, ptr %7, align 8, !tbaa !5
  %15 = zext i1 %3 to i8
  store i8 %15, ptr %8, align 1, !tbaa !9
  %16 = load ptr, ptr %5, align 8
  %17 = load ptr, ptr %7, align 8, !tbaa !5
  %18 = load i8, ptr %8, align 1, !tbaa !9, !range !11, !noundef !12
  %19 = trunc i8 %18 to i1
  call void @_ZN3vox16ImplicitSurface2C2ERKNS_10Transform2IdEEb(ptr noundef nonnull align 8 dereferenceable(49) %16, ptr noundef nonnull align 8 dereferenceable(40) %17, i1 noundef zeroext %19)
  store ptr getelementptr inbounds inrange(-16, 104) ({ [15 x ptr] }, ptr @_ZTVN3vox19ImplicitSurfaceSet2E, i32 0, i32 0, i32 2), ptr %16, align 8, !tbaa !13
  %20 = getelementptr inbounds %"class.vox::ImplicitSurfaceSet2", ptr %16, i32 0, i32 2
  call void @_ZNSt6vectorISt10shared_ptrIN3vox16ImplicitSurface2EESaIS3_EEC2EOS5_(ptr noundef nonnull align 8 dereferenceable(24) %20, ptr noundef nonnull align 8 dereferenceable(24) %1) #6
  %21 = getelementptr inbounds %"class.vox::ImplicitSurfaceSet2", ptr %16, i32 0, i32 3
  call void @_ZNSt6vectorISt10shared_ptrIN3vox16ImplicitSurface2EESaIS3_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %21) #6
  %22 = getelementptr inbounds %"class.vox::ImplicitSurfaceSet2", ptr %16, i32 0, i32 4
  invoke void @_ZN3vox4Bvh2ISt10shared_ptrINS_16ImplicitSurface2EEEC2Ev(ptr noundef nonnull align 8 dereferenceable(120) %22)
          to label %23 unwind label %35

23:                                               ; preds = %4
  %24 = getelementptr inbounds %"class.vox::ImplicitSurfaceSet2", ptr %16, i32 0, i32 5
  store i8 1, ptr %24, align 8, !tbaa !15
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #6
  %25 = getelementptr inbounds %"class.vox::ImplicitSurfaceSet2", ptr %16, i32 0, i32 2
  store ptr %25, ptr %11, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #6
  %26 = load ptr, ptr %11, align 8, !tbaa !5
  %27 = call ptr @_ZNSt6vectorISt10shared_ptrIN3vox16ImplicitSurface2EESaIS3_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %26) #6
  %28 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %12, i32 0, i32 0
  store ptr %27, ptr %28, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #6
  %29 = load ptr, ptr %11, align 8, !tbaa !5
  %30 = call ptr @_ZNSt6vectorISt10shared_ptrIN3vox16ImplicitSurface2EESaIS3_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %29) #6
  %31 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %13, i32 0, i32 0
  store ptr %30, ptr %31, align 8
  br label %32

32:                                               ; preds = %57, %23
  %33 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPSt10shared_ptrIN3vox16ImplicitSurface2EESt6vectorIS4_SaIS4_EEEEbRKNS_17__normal_iteratorIT_T0_EESE_(ptr noundef nonnull align 8 dereferenceable(8) %12, ptr noundef nonnull align 8 dereferenceable(8) %13) #6
  br i1 %33, label %39, label %34

34:                                               ; preds = %32
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #6
  br label %59

35:                                               ; preds = %4
  %36 = landingpad { ptr, i32 }
          cleanup
  %37 = extractvalue { ptr, i32 } %36, 0
  store ptr %37, ptr %9, align 8
  %38 = extractvalue { ptr, i32 } %36, 1
  store i32 %38, ptr %10, align 4
  br label %66

39:                                               ; preds = %32
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #6
  %40 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPSt10shared_ptrIN3vox16ImplicitSurface2EESt6vectorIS4_SaIS4_EEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %12) #6
  store ptr %40, ptr %14, align 8, !tbaa !5
  %41 = load ptr, ptr %14, align 8, !tbaa !5
  %42 = call noundef ptr @_ZNKSt19__shared_ptr_accessIN3vox16ImplicitSurface2ELN9__gnu_cxx12_Lock_policyE2ELb0ELb0EEptEv(ptr noundef nonnull align 1 dereferenceable(1) %41) #6
  %43 = load ptr, ptr %42, align 8, !tbaa !13
  %44 = getelementptr inbounds ptr, ptr %43, i64 3
  %45 = load ptr, ptr %44, align 8
  %46 = invoke noundef zeroext i1 %45(ptr noundef nonnull align 8 dereferenceable(49) %42)
          to label %47 unwind label %52

47:                                               ; preds = %39
  br i1 %46, label %56, label %48

48:                                               ; preds = %47
  %49 = getelementptr inbounds %"class.vox::ImplicitSurfaceSet2", ptr %16, i32 0, i32 3
  %50 = load ptr, ptr %14, align 8, !tbaa !5
  invoke void @_ZNSt6vectorISt10shared_ptrIN3vox16ImplicitSurface2EESaIS3_EE9push_backERKS3_(ptr noundef nonnull align 8 dereferenceable(24) %49, ptr noundef nonnull align 8 dereferenceable(16) %50)
          to label %51 unwind label %52

51:                                               ; preds = %48
  br label %56

52:                                               ; preds = %48, %39
  %53 = landingpad { ptr, i32 }
          cleanup
  %54 = extractvalue { ptr, i32 } %53, 0
  store ptr %54, ptr %9, align 8
  %55 = extractvalue { ptr, i32 } %53, 1
  store i32 %55, ptr %10, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #6
  br label %65

56:                                               ; preds = %51, %47
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #6
  br label %57

57:                                               ; preds = %56
  %58 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZN9__gnu_cxx17__normal_iteratorIPSt10shared_ptrIN3vox16ImplicitSurface2EESt6vectorIS4_SaIS4_EEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %12) #6
  br label %32

59:                                               ; preds = %34
  invoke void @_ZN3vox19ImplicitSurfaceSet213invalidateBvhEv(ptr noundef nonnull align 8 dereferenceable(232) %16)
          to label %60 unwind label %61

60:                                               ; preds = %59
  ret void

61:                                               ; preds = %59
  %62 = landingpad { ptr, i32 }
          cleanup
  %63 = extractvalue { ptr, i32 } %62, 0
  store ptr %63, ptr %9, align 8
  %64 = extractvalue { ptr, i32 } %62, 1
  store i32 %64, ptr %10, align 4
  br label %65

65:                                               ; preds = %61, %52
  call void @_ZN3vox4Bvh2ISt10shared_ptrINS_16ImplicitSurface2EEED2Ev(ptr noundef nonnull align 8 dereferenceable(120) %22) #6
  br label %66

66:                                               ; preds = %65, %35
  call void @_ZNSt6vectorISt10shared_ptrIN3vox16ImplicitSurface2EESaIS3_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %21) #6
  call void @_ZNSt6vectorISt10shared_ptrIN3vox16ImplicitSurface2EESaIS3_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %20) #6
  call void @_ZN3vox16ImplicitSurface2D2Ev(ptr noundef nonnull align 8 dereferenceable(49) %16) #6
  br label %67

67:                                               ; preds = %66
  %68 = load ptr, ptr %9, align 8
  %69 = load i32, ptr %10, align 4
  %70 = insertvalue { ptr, i32 } poison, ptr %68, 0
  %71 = insertvalue { ptr, i32 } %70, i32 %69, 1
  resume { ptr, i32 } %71
}

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

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

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

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

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

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

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

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZN3vox4Bvh2ISt10shared_ptrINS_16ImplicitSurface2EEED2Ev(ptr noundef nonnull align 8 dereferenceable(120)) unnamed_addr #5 align 2

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

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"bool", !7, i64 0}
!11 = !{i8 0, i8 2}
!12 = !{}
!13 = !{!14, !14, i64 0}
!14 = !{!"vtable pointer", !8, i64 0}
!15 = !{!16, !10, i64 224}
!16 = !{!"_ZTSN3vox19ImplicitSurfaceSet2E", !17, i64 0, !22, i64 56, !22, i64 80, !26, i64 104, !10, i64 224}
!17 = !{!"_ZTSN3vox16ImplicitSurface2E", !18, i64 0}
!18 = !{!"_ZTSN3vox8Surface2E", !19, i64 8, !10, i64 48}
!19 = !{!"_ZTSN3vox10Transform2IdEE", !20, i64 0, !21, i64 16, !21, i64 24, !21, i64 32}
!20 = !{!"_ZTSN3vox6VectorIdLm2EEE", !21, i64 0, !21, i64 8}
!21 = !{!"double", !7, i64 0}
!22 = !{!"_ZTSSt6vectorISt10shared_ptrIN3vox16ImplicitSurface2EESaIS3_EE", !23, i64 0}
!23 = !{!"_ZTSSt12_Vector_baseISt10shared_ptrIN3vox16ImplicitSurface2EESaIS3_EE", !24, i64 0}
!24 = !{!"_ZTSNSt12_Vector_baseISt10shared_ptrIN3vox16ImplicitSurface2EESaIS3_EE12_Vector_implE", !25, i64 0}
!25 = !{!"_ZTSNSt12_Vector_baseISt10shared_ptrIN3vox16ImplicitSurface2EESaIS3_EE17_Vector_impl_dataE", !6, i64 0, !6, i64 8, !6, i64 16}
!26 = !{!"_ZTSN3vox4Bvh2ISt10shared_ptrINS_16ImplicitSurface2EEEE", !27, i64 0, !28, i64 8, !29, i64 16, !22, i64 48, !31, i64 72, !35, i64 96}
!27 = !{!"_ZTSN3vox24IntersectionQueryEngine2ISt10shared_ptrINS_16ImplicitSurface2EEEE"}
!28 = !{!"_ZTSN3vox27NearestNeighborQueryEngine2ISt10shared_ptrINS_16ImplicitSurface2EEEE"}
!29 = !{!"_ZTSN3vox11BoundingBoxIdLm2EEE", !30, i64 0, !30, i64 16}
!30 = !{!"_ZTSN3vox5PointIdLm2EEE", !21, i64 0, !21, i64 8}
!31 = !{!"_ZTSSt6vectorIN3vox11BoundingBoxIdLm2EEESaIS2_EE", !32, i64 0}
!32 = !{!"_ZTSSt12_Vector_baseIN3vox11BoundingBoxIdLm2EEESaIS2_EE", !33, i64 0}
!33 = !{!"_ZTSNSt12_Vector_baseIN3vox11BoundingBoxIdLm2EEESaIS2_EE12_Vector_implE", !34, i64 0}
!34 = !{!"_ZTSNSt12_Vector_baseIN3vox11BoundingBoxIdLm2EEESaIS2_EE17_Vector_impl_dataE", !6, i64 0, !6, i64 8, !6, i64 16}
!35 = !{!"_ZTSSt6vectorIN3vox4Bvh2ISt10shared_ptrINS0_16ImplicitSurface2EEE4NodeESaIS6_EE", !36, i64 0}
!36 = !{!"_ZTSSt12_Vector_baseIN3vox4Bvh2ISt10shared_ptrINS0_16ImplicitSurface2EEE4NodeESaIS6_EE", !37, i64 0}
!37 = !{!"_ZTSNSt12_Vector_baseIN3vox4Bvh2ISt10shared_ptrINS0_16ImplicitSurface2EEE4NodeESaIS6_EE12_Vector_implE", !38, i64 0}
!38 = !{!"_ZTSNSt12_Vector_baseIN3vox4Bvh2ISt10shared_ptrINS0_16ImplicitSurface2EEE4NodeESaIS6_EE17_Vector_impl_dataE", !6, i64 0, !6, i64 8, !6, i64 16}


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

%"class.__gnu_cxx::__normal_iterator" = type { ptr }

@_ZTVN3vox19ImplicitSurfaceSet2E = external dso_local unnamed_addr constant { [15 x ptr] }, align 8

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

declare void @_ZN3vox16ImplicitSurface2C2ERKNS_10Transform2IdEEb(ptr noundef nonnull align 8 dereferenceable(49), ptr noundef nonnull align 8 dereferenceable(40), i1 noundef zeroext) unnamed_addr #1

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

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

declare i32 @__gxx_personality_v0(...)

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

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN3vox19ImplicitSurfaceSet2C2ESt6vectorISt10shared_ptrINS_16ImplicitSurface2EESaIS4_EERKNS_10Transform2IdEEb(ptr noundef nonnull align 8 dereferenceable(232) %0, ptr noundef %1, ptr noundef nonnull align 8 dereferenceable(40) %2, i1 noundef zeroext %3) unnamed_addr #3 align 2 personality ptr @__gxx_personality_v0 {
  %5 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %6 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  tail call void @_ZN3vox16ImplicitSurface2C2ERKNS_10Transform2IdEEb(ptr noundef nonnull align 8 dereferenceable(49) %0, ptr noundef nonnull align 8 dereferenceable(40) %2, i1 noundef zeroext %3)
  store ptr getelementptr inbounds inrange(-16, 104) (i8, ptr @_ZTVN3vox19ImplicitSurfaceSet2E, i64 16), ptr %0, align 8, !tbaa !5
  %7 = getelementptr inbounds i8, ptr %0, i64 56
  tail call void @_ZNSt6vectorISt10shared_ptrIN3vox16ImplicitSurface2EESaIS3_EEC2EOS5_(ptr noundef nonnull align 8 dereferenceable(24) %7, ptr noundef nonnull align 8 dereferenceable(24) %1) #6
  %8 = getelementptr inbounds i8, ptr %0, i64 80
  tail call void @_ZNSt6vectorISt10shared_ptrIN3vox16ImplicitSurface2EESaIS3_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %8) #6
  %9 = getelementptr inbounds i8, ptr %0, i64 104
  invoke void @_ZN3vox4Bvh2ISt10shared_ptrINS_16ImplicitSurface2EEEC2Ev(ptr noundef nonnull align 8 dereferenceable(120) %9)
          to label %10 unwind label %15

10:                                               ; preds = %4
  %11 = getelementptr inbounds i8, ptr %0, i64 224
  store i8 1, ptr %11, align 8, !tbaa !8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %5) #6
  %12 = tail call ptr @_ZNSt6vectorISt10shared_ptrIN3vox16ImplicitSurface2EESaIS3_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %7) #6
  store ptr %12, ptr %5, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %6) #6
  %13 = tail call ptr @_ZNSt6vectorISt10shared_ptrIN3vox16ImplicitSurface2EESaIS3_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %7) #6
  store ptr %13, ptr %6, align 8
  %14 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPSt10shared_ptrIN3vox16ImplicitSurface2EESt6vectorIS4_SaIS4_EEEEbRKNS_17__normal_iteratorIT_T0_EESE_(ptr noundef nonnull align 8 dereferenceable(8) %5, ptr noundef nonnull align 8 dereferenceable(8) %6) #6
  br i1 %14, label %.lr.ph, label %._crit_edge

._crit_edge:                                      ; preds = %27, %10
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %5) #6
  call void @_ZN3vox19ImplicitSurfaceSet213invalidateBvhEv(ptr noundef nonnull align 8 dereferenceable(232) %0)
  ret void

15:                                               ; preds = %4
  %16 = landingpad { ptr, i32 }
          cleanup
  br label %30

.lr.ph:                                           ; preds = %10, %27
  %17 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPSt10shared_ptrIN3vox16ImplicitSurface2EESt6vectorIS4_SaIS4_EEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %5) #6
  %18 = call noundef ptr @_ZNKSt19__shared_ptr_accessIN3vox16ImplicitSurface2ELN9__gnu_cxx12_Lock_policyE2ELb0ELb0EEptEv(ptr noundef nonnull align 1 dereferenceable(1) %17) #6
  %19 = load ptr, ptr %18, align 8, !tbaa !5
  %20 = getelementptr inbounds i8, ptr %19, i64 24
  %21 = load ptr, ptr %20, align 8
  %22 = invoke noundef zeroext i1 %21(ptr noundef nonnull align 8 dereferenceable(49) %18)
          to label %23 unwind label %25

23:                                               ; preds = %.lr.ph
  br i1 %22, label %27, label %24

24:                                               ; preds = %23
  invoke void @_ZNSt6vectorISt10shared_ptrIN3vox16ImplicitSurface2EESaIS3_EE9push_backERKS3_(ptr noundef nonnull align 8 dereferenceable(24) %8, ptr noundef nonnull align 8 dereferenceable(16) %17)
          to label %27 unwind label %25

25:                                               ; preds = %24, %.lr.ph
  %26 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %5) #6
  call void @_ZN3vox4Bvh2ISt10shared_ptrINS_16ImplicitSurface2EEED2Ev(ptr noundef nonnull align 8 dereferenceable(120) %9) #6
  br label %30

27:                                               ; preds = %24, %23
  %28 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZN9__gnu_cxx17__normal_iteratorIPSt10shared_ptrIN3vox16ImplicitSurface2EESt6vectorIS4_SaIS4_EEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %5) #6
  %29 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPSt10shared_ptrIN3vox16ImplicitSurface2EESt6vectorIS4_SaIS4_EEEEbRKNS_17__normal_iteratorIT_T0_EESE_(ptr noundef nonnull align 8 dereferenceable(8) %5, ptr noundef nonnull align 8 dereferenceable(8) %6) #6
  br i1 %29, label %.lr.ph, label %._crit_edge

30:                                               ; preds = %25, %15
  %.pn = phi { ptr, i32 } [ %26, %25 ], [ %16, %15 ]
  call void @_ZNSt6vectorISt10shared_ptrIN3vox16ImplicitSurface2EESaIS3_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %8) #6
  call void @_ZNSt6vectorISt10shared_ptrIN3vox16ImplicitSurface2EESaIS3_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %7) #6
  call void @_ZN3vox16ImplicitSurface2D2Ev(ptr noundef nonnull align 8 dereferenceable(49) %0) #6
  resume { ptr, i32 } %.pn
}

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

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

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

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

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

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

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

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZN3vox4Bvh2ISt10shared_ptrINS_16ImplicitSurface2EEED2Ev(ptr noundef nonnull align 8 dereferenceable(120)) unnamed_addr #5 align 2

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

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"vtable pointer", !7, i64 0}
!7 = !{!"Simple C++ TBAA"}
!8 = !{!9, !16, i64 224}
!9 = !{!"_ZTSN3vox19ImplicitSurfaceSet2E", !10, i64 0, !17, i64 56, !17, i64 80, !22, i64 104, !16, i64 224}
!10 = !{!"_ZTSN3vox16ImplicitSurface2E", !11, i64 0}
!11 = !{!"_ZTSN3vox8Surface2E", !12, i64 8, !16, i64 48}
!12 = !{!"_ZTSN3vox10Transform2IdEE", !13, i64 0, !14, i64 16, !14, i64 24, !14, i64 32}
!13 = !{!"_ZTSN3vox6VectorIdLm2EEE", !14, i64 0, !14, i64 8}
!14 = !{!"double", !15, i64 0}
!15 = !{!"omnipotent char", !7, i64 0}
!16 = !{!"bool", !15, i64 0}
!17 = !{!"_ZTSSt6vectorISt10shared_ptrIN3vox16ImplicitSurface2EESaIS3_EE", !18, i64 0}
!18 = !{!"_ZTSSt12_Vector_baseISt10shared_ptrIN3vox16ImplicitSurface2EESaIS3_EE", !19, i64 0}
!19 = !{!"_ZTSNSt12_Vector_baseISt10shared_ptrIN3vox16ImplicitSurface2EESaIS3_EE12_Vector_implE", !20, i64 0}
!20 = !{!"_ZTSNSt12_Vector_baseISt10shared_ptrIN3vox16ImplicitSurface2EESaIS3_EE17_Vector_impl_dataE", !21, i64 0, !21, i64 8, !21, i64 16}
!21 = !{!"any pointer", !15, i64 0}
!22 = !{!"_ZTSN3vox4Bvh2ISt10shared_ptrINS_16ImplicitSurface2EEEE", !23, i64 0, !24, i64 8, !25, i64 16, !17, i64 48, !27, i64 72, !31, i64 96}
!23 = !{!"_ZTSN3vox24IntersectionQueryEngine2ISt10shared_ptrINS_16ImplicitSurface2EEEE"}
!24 = !{!"_ZTSN3vox27NearestNeighborQueryEngine2ISt10shared_ptrINS_16ImplicitSurface2EEEE"}
!25 = !{!"_ZTSN3vox11BoundingBoxIdLm2EEE", !26, i64 0, !26, i64 16}
!26 = !{!"_ZTSN3vox5PointIdLm2EEE", !14, i64 0, !14, i64 8}
!27 = !{!"_ZTSSt6vectorIN3vox11BoundingBoxIdLm2EEESaIS2_EE", !28, i64 0}
!28 = !{!"_ZTSSt12_Vector_baseIN3vox11BoundingBoxIdLm2EEESaIS2_EE", !29, i64 0}
!29 = !{!"_ZTSNSt12_Vector_baseIN3vox11BoundingBoxIdLm2EEESaIS2_EE12_Vector_implE", !30, i64 0}
!30 = !{!"_ZTSNSt12_Vector_baseIN3vox11BoundingBoxIdLm2EEESaIS2_EE17_Vector_impl_dataE", !21, i64 0, !21, i64 8, !21, i64 16}
!31 = !{!"_ZTSSt6vectorIN3vox4Bvh2ISt10shared_ptrINS0_16ImplicitSurface2EEE4NodeESaIS6_EE", !32, i64 0}
!32 = !{!"_ZTSSt12_Vector_baseIN3vox4Bvh2ISt10shared_ptrINS0_16ImplicitSurface2EEE4NodeESaIS6_EE", !33, i64 0}
!33 = !{!"_ZTSNSt12_Vector_baseIN3vox4Bvh2ISt10shared_ptrINS0_16ImplicitSurface2EEE4NodeESaIS6_EE12_Vector_implE", !34, i64 0}
!34 = !{!"_ZTSNSt12_Vector_baseIN3vox4Bvh2ISt10shared_ptrINS0_16ImplicitSurface2EEE4NodeESaIS6_EE17_Vector_impl_dataE", !21, i64 0, !21, i64 8, !21, i64 16}


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