; LLVM IR from doyubkim/fluid-engine-dev :: src/jet (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.std::shared_ptr" = type { %"class.std::__shared_ptr" }
%"class.std::__shared_ptr" = type { ptr, %"class.std::__shared_count" }
%"class.std::__shared_count" = type { ptr }
%"class.jet::ImplicitSurfaceSet2" = type <{ %"class.jet::ImplicitSurface2.base", [7 x i8], %"class.std::vector", %"class.std::vector", %"class.jet::Bvh2", i8, [7 x i8] }>
%"class.jet::ImplicitSurface2.base" = type { %"class.jet::Surface2.base" }
%"class.jet::Surface2.base" = type <{ ptr, %"class.jet::Transform2", i8 }>
%"class.jet::Transform2" = type { %"class.jet::Vector", double, double, double }
%"class.jet::Vector" = type { double, double }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<std::shared_ptr<jet::ImplicitSurface2>, std::allocator<std::shared_ptr<jet::ImplicitSurface2>>>::_Vector_impl" }
%"struct.std::_Vector_base<std::shared_ptr<jet::ImplicitSurface2>, std::allocator<std::shared_ptr<jet::ImplicitSurface2>>>::_Vector_impl" = type { %"struct.std::_Vector_base<std::shared_ptr<jet::ImplicitSurface2>, std::allocator<std::shared_ptr<jet::ImplicitSurface2>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<std::shared_ptr<jet::ImplicitSurface2>, std::allocator<std::shared_ptr<jet::ImplicitSurface2>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.jet::Bvh2" = type { %"class.jet::IntersectionQueryEngine2", %"class.jet::NearestNeighborQueryEngine2", %"class.jet::BoundingBox", %"class.std::vector", %"class.std::vector.0", %"class.std::vector.5" }
%"class.jet::IntersectionQueryEngine2" = type { ptr }
%"class.jet::NearestNeighborQueryEngine2" = type { ptr }
%"class.jet::BoundingBox" = type { %"class.jet::Vector", %"class.jet::Vector" }
%"class.std::vector.0" = type { %"struct.std::_Vector_base.1" }
%"struct.std::_Vector_base.1" = type { %"struct.std::_Vector_base<jet::BoundingBox<double, 2>, std::allocator<jet::BoundingBox<double, 2>>>::_Vector_impl" }
%"struct.std::_Vector_base<jet::BoundingBox<double, 2>, std::allocator<jet::BoundingBox<double, 2>>>::_Vector_impl" = type { %"struct.std::_Vector_base<jet::BoundingBox<double, 2>, std::allocator<jet::BoundingBox<double, 2>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<jet::BoundingBox<double, 2>, std::allocator<jet::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<jet::Bvh2<std::shared_ptr<jet::ImplicitSurface2>>::Node, std::allocator<jet::Bvh2<std::shared_ptr<jet::ImplicitSurface2>>::Node>>::_Vector_impl" }
%"struct.std::_Vector_base<jet::Bvh2<std::shared_ptr<jet::ImplicitSurface2>>::Node, std::allocator<jet::Bvh2<std::shared_ptr<jet::ImplicitSurface2>>::Node>>::_Vector_impl" = type { %"struct.std::_Vector_base<jet::Bvh2<std::shared_ptr<jet::ImplicitSurface2>>::Node, std::allocator<jet::Bvh2<std::shared_ptr<jet::ImplicitSurface2>>::Node>>::_Vector_impl_data" }
%"struct.std::_Vector_base<jet::Bvh2<std::shared_ptr<jet::ImplicitSurface2>>::Node, std::allocator<jet::Bvh2<std::shared_ptr<jet::ImplicitSurface2>>::Node>>::_Vector_impl_data" = type { ptr, ptr, ptr }

@_ZTVN3jet19ImplicitSurfaceSet2E = 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 @_ZN3jet16ImplicitSurface2C2ERKNS_10Transform2Eb(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_ptrIN3jet16ImplicitSurface2EESaIS3_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN3jet4Bvh2ISt10shared_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_ptrIN3jet16ImplicitSurface2EESaIS3_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #2 align 2

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN3jet19ImplicitSurfaceSet2C2ERKSt6vectorISt10shared_ptrINS_16ImplicitSurface2EESaIS4_EERKNS_10Transform2Eb(ptr noundef nonnull align 8 dereferenceable(232) %0, ptr noundef nonnull align 8 dereferenceable(24) %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 %"class.std::shared_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 @_ZN3jet16ImplicitSurface2C2ERKNS_10Transform2Eb(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 @_ZTVN3jet19ImplicitSurfaceSet2E, i32 0, i32 0, i32 2), ptr %16, align 8, !tbaa !13
  %20 = getelementptr inbounds %"class.jet::ImplicitSurfaceSet2", ptr %16, i32 0, i32 2
  %21 = load ptr, ptr %6, align 8, !tbaa !5
  invoke void @_ZNSt6vectorISt10shared_ptrIN3jet16ImplicitSurface2EESaIS3_EEC2ERKS5_(ptr noundef nonnull align 8 dereferenceable(24) %20, ptr noundef nonnull align 8 dereferenceable(24) %21)
          to label %22 unwind label %37

22:                                               ; preds = %4
  %23 = getelementptr inbounds %"class.jet::ImplicitSurfaceSet2", ptr %16, i32 0, i32 3
  call void @_ZNSt6vectorISt10shared_ptrIN3jet16ImplicitSurface2EESaIS3_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %23) #6
  %24 = getelementptr inbounds %"class.jet::ImplicitSurfaceSet2", ptr %16, i32 0, i32 4
  invoke void @_ZN3jet4Bvh2ISt10shared_ptrINS_16ImplicitSurface2EEEC2Ev(ptr noundef nonnull align 8 dereferenceable(120) %24)
          to label %25 unwind label %41

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

34:                                               ; preds = %61, %25
  %35 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPSt10shared_ptrIN3jet16ImplicitSurface2EESt6vectorIS4_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 %35, label %45, label %36

36:                                               ; preds = %34
  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 %63

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

41:                                               ; preds = %22
  %42 = landingpad { ptr, i32 }
          cleanup
  %43 = extractvalue { ptr, i32 } %42, 0
  store ptr %43, ptr %9, align 8
  %44 = extractvalue { ptr, i32 } %42, 1
  store i32 %44, ptr %10, align 4
  br label %70

45:                                               ; preds = %34
  call void @llvm.lifetime.start.p0(i64 16, ptr %14) #6
  %46 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPSt10shared_ptrIN3jet16ImplicitSurface2EESt6vectorIS4_SaIS4_EEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %12) #6
  call void @_ZNSt10shared_ptrIN3jet16ImplicitSurface2EEC2ERKS2_(ptr noundef nonnull align 8 dereferenceable(16) %14, ptr noundef nonnull align 8 dereferenceable(16) %46) #6
  %47 = call noundef ptr @_ZNKSt19__shared_ptr_accessIN3jet16ImplicitSurface2ELN9__gnu_cxx12_Lock_policyE2ELb0ELb0EEptEv(ptr noundef nonnull align 1 dereferenceable(1) %14) #6
  %48 = load ptr, ptr %47, align 8, !tbaa !13
  %49 = getelementptr inbounds ptr, ptr %48, i64 3
  %50 = load ptr, ptr %49, align 8
  %51 = invoke noundef zeroext i1 %50(ptr noundef nonnull align 8 dereferenceable(49) %47)
          to label %52 unwind label %56

52:                                               ; preds = %45
  br i1 %51, label %60, label %53

53:                                               ; preds = %52
  %54 = getelementptr inbounds %"class.jet::ImplicitSurfaceSet2", ptr %16, i32 0, i32 3
  invoke void @_ZNSt6vectorISt10shared_ptrIN3jet16ImplicitSurface2EESaIS3_EE9push_backERKS3_(ptr noundef nonnull align 8 dereferenceable(24) %54, ptr noundef nonnull align 8 dereferenceable(16) %14)
          to label %55 unwind label %56

55:                                               ; preds = %53
  br label %60

56:                                               ; preds = %53, %45
  %57 = landingpad { ptr, i32 }
          cleanup
  %58 = extractvalue { ptr, i32 } %57, 0
  store ptr %58, ptr %9, align 8
  %59 = extractvalue { ptr, i32 } %57, 1
  store i32 %59, ptr %10, align 4
  call void @_ZNSt12__shared_ptrIN3jet16ImplicitSurface2ELN9__gnu_cxx12_Lock_policyE2EED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %14) #6
  call void @llvm.lifetime.end.p0(i64 16, 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 %69

60:                                               ; preds = %55, %52
  call void @_ZNSt12__shared_ptrIN3jet16ImplicitSurface2ELN9__gnu_cxx12_Lock_policyE2EED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %14) #6
  call void @llvm.lifetime.end.p0(i64 16, ptr %14) #6
  br label %61

61:                                               ; preds = %60
  %62 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZN9__gnu_cxx17__normal_iteratorIPSt10shared_ptrIN3jet16ImplicitSurface2EESt6vectorIS4_SaIS4_EEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %12) #6
  br label %34

63:                                               ; preds = %36
  invoke void @_ZN3jet19ImplicitSurfaceSet213invalidateBvhEv(ptr noundef nonnull align 8 dereferenceable(232) %16)
          to label %64 unwind label %65

64:                                               ; preds = %63
  ret void

65:                                               ; preds = %63
  %66 = landingpad { ptr, i32 }
          cleanup
  %67 = extractvalue { ptr, i32 } %66, 0
  store ptr %67, ptr %9, align 8
  %68 = extractvalue { ptr, i32 } %66, 1
  store i32 %68, ptr %10, align 4
  br label %69

69:                                               ; preds = %65, %56
  call void @_ZN3jet4Bvh2ISt10shared_ptrINS_16ImplicitSurface2EEED2Ev(ptr noundef nonnull align 8 dereferenceable(120) %24) #6
  br label %70

70:                                               ; preds = %69, %41
  call void @_ZNSt6vectorISt10shared_ptrIN3jet16ImplicitSurface2EESaIS3_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %23) #6
  call void @_ZNSt6vectorISt10shared_ptrIN3jet16ImplicitSurface2EESaIS3_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %20) #6
  br label %71

71:                                               ; preds = %70, %37
  call void @_ZN3jet16ImplicitSurface2D2Ev(ptr noundef nonnull align 8 dereferenceable(49) %16) #6
  br label %72

72:                                               ; preds = %71
  %73 = load ptr, ptr %9, align 8
  %74 = load i32, ptr %10, align 4
  %75 = insertvalue { ptr, i32 } poison, ptr %73, 0
  %76 = insertvalue { ptr, i32 } %75, i32 %74, 1
  resume { ptr, i32 } %76
}

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local ptr @_ZNSt6vectorISt10shared_ptrIN3jet16ImplicitSurface2EESaIS3_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_ptrIN3jet16ImplicitSurface2EESt6vectorIS4_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_ptrIN3jet16ImplicitSurface2EESt6vectorIS4_SaIS4_EEEdeEv(ptr noundef nonnull align 8 dereferenceable(8)) #2 align 2

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt6vectorISt10shared_ptrIN3jet16ImplicitSurface2EESaIS3_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 void @_ZNSt12__shared_ptrIN3jet16ImplicitSurface2ELN9__gnu_cxx12_Lock_policyE2EED2Ev(ptr noundef nonnull align 8 dereferenceable(16)) unnamed_addr #2 align 2

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZN3jet4Bvh2ISt10shared_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 = !{!"_ZTSN3jet19ImplicitSurfaceSet2E", !17, i64 0, !22, i64 56, !22, i64 80, !26, i64 104, !10, i64 224}
!17 = !{!"_ZTSN3jet16ImplicitSurface2E", !18, i64 0}
!18 = !{!"_ZTSN3jet8Surface2E", !19, i64 8, !10, i64 48}
!19 = !{!"_ZTSN3jet10Transform2E", !20, i64 0, !21, i64 16, !21, i64 24, !21, i64 32}
!20 = !{!"_ZTSN3jet6VectorIdLm2EEE", !21, i64 0, !21, i64 8}
!21 = !{!"double", !7, i64 0}
!22 = !{!"_ZTSSt6vectorISt10shared_ptrIN3jet16ImplicitSurface2EESaIS3_EE", !23, i64 0}
!23 = !{!"_ZTSSt12_Vector_baseISt10shared_ptrIN3jet16ImplicitSurface2EESaIS3_EE", !24, i64 0}
!24 = !{!"_ZTSNSt12_Vector_baseISt10shared_ptrIN3jet16ImplicitSurface2EESaIS3_EE12_Vector_implE", !25, i64 0}
!25 = !{!"_ZTSNSt12_Vector_baseISt10shared_ptrIN3jet16ImplicitSurface2EESaIS3_EE17_Vector_impl_dataE", !6, i64 0, !6, i64 8, !6, i64 16}
!26 = !{!"_ZTSN3jet4Bvh2ISt10shared_ptrINS_16ImplicitSurface2EEEE", !27, i64 0, !28, i64 8, !29, i64 16, !22, i64 48, !30, i64 72, !34, i64 96}
!27 = !{!"_ZTSN3jet24IntersectionQueryEngine2ISt10shared_ptrINS_16ImplicitSurface2EEEE"}
!28 = !{!"_ZTSN3jet27NearestNeighborQueryEngine2ISt10shared_ptrINS_16ImplicitSurface2EEEE"}
!29 = !{!"_ZTSN3jet11BoundingBoxIdLm2EEE", !20, i64 0, !20, i64 16}
!30 = !{!"_ZTSSt6vectorIN3jet11BoundingBoxIdLm2EEESaIS2_EE", !31, i64 0}
!31 = !{!"_ZTSSt12_Vector_baseIN3jet11BoundingBoxIdLm2EEESaIS2_EE", !32, i64 0}
!32 = !{!"_ZTSNSt12_Vector_baseIN3jet11BoundingBoxIdLm2EEESaIS2_EE12_Vector_implE", !33, i64 0}
!33 = !{!"_ZTSNSt12_Vector_baseIN3jet11BoundingBoxIdLm2EEESaIS2_EE17_Vector_impl_dataE", !6, i64 0, !6, i64 8, !6, i64 16}
!34 = !{!"_ZTSSt6vectorIN3jet4Bvh2ISt10shared_ptrINS0_16ImplicitSurface2EEE4NodeESaIS6_EE", !35, i64 0}
!35 = !{!"_ZTSSt12_Vector_baseIN3jet4Bvh2ISt10shared_ptrINS0_16ImplicitSurface2EEE4NodeESaIS6_EE", !36, i64 0}
!36 = !{!"_ZTSNSt12_Vector_baseIN3jet4Bvh2ISt10shared_ptrINS0_16ImplicitSurface2EEE4NodeESaIS6_EE12_Vector_implE", !37, i64 0}
!37 = !{!"_ZTSNSt12_Vector_baseIN3jet4Bvh2ISt10shared_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 }
%"class.std::shared_ptr" = type { %"class.std::__shared_ptr" }
%"class.std::__shared_ptr" = type { ptr, %"class.std::__shared_count" }
%"class.std::__shared_count" = type { ptr }

@_ZTVN3jet19ImplicitSurfaceSet2E = 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 @_ZN3jet16ImplicitSurface2C2ERKNS_10Transform2Eb(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_ptrIN3jet16ImplicitSurface2EESaIS3_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN3jet4Bvh2ISt10shared_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_ptrIN3jet16ImplicitSurface2EESaIS3_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #2 align 2

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN3jet19ImplicitSurfaceSet2C2ERKSt6vectorISt10shared_ptrINS_16ImplicitSurface2EESaIS4_EERKNS_10Transform2Eb(ptr noundef nonnull align 8 dereferenceable(232) %0, ptr noundef nonnull align 8 dereferenceable(24) %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
  %7 = alloca %"class.std::shared_ptr", align 8
  tail call void @_ZN3jet16ImplicitSurface2C2ERKNS_10Transform2Eb(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 @_ZTVN3jet19ImplicitSurfaceSet2E, i64 16), ptr %0, align 8, !tbaa !5
  %8 = getelementptr inbounds i8, ptr %0, i64 56
  invoke void @_ZNSt6vectorISt10shared_ptrIN3jet16ImplicitSurface2EESaIS3_EEC2ERKS5_(ptr noundef nonnull align 8 dereferenceable(24) %8, ptr noundef nonnull align 8 dereferenceable(24) %1)
          to label %9 unwind label %17

9:                                                ; preds = %4
  %10 = getelementptr inbounds i8, ptr %0, i64 80
  tail call void @_ZNSt6vectorISt10shared_ptrIN3jet16ImplicitSurface2EESaIS3_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %10) #6
  %11 = getelementptr inbounds i8, ptr %0, i64 104
  invoke void @_ZN3jet4Bvh2ISt10shared_ptrINS_16ImplicitSurface2EEEC2Ev(ptr noundef nonnull align 8 dereferenceable(120) %11)
          to label %12 unwind label %19

12:                                               ; preds = %9
  %13 = getelementptr inbounds i8, ptr %0, i64 224
  store i8 1, ptr %13, align 8, !tbaa !8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %5) #6
  %14 = tail call ptr @_ZNSt6vectorISt10shared_ptrIN3jet16ImplicitSurface2EESaIS3_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %8) #6
  store ptr %14, ptr %5, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %6) #6
  %15 = tail call ptr @_ZNSt6vectorISt10shared_ptrIN3jet16ImplicitSurface2EESaIS3_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %8) #6
  store ptr %15, ptr %6, align 8
  %16 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPSt10shared_ptrIN3jet16ImplicitSurface2EESt6vectorIS4_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 %16, label %.lr.ph, label %._crit_edge

._crit_edge:                                      ; preds = %31, %12
  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 @_ZN3jet19ImplicitSurfaceSet213invalidateBvhEv(ptr noundef nonnull align 8 dereferenceable(232) %0)
  ret void

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

19:                                               ; preds = %9
  %20 = landingpad { ptr, i32 }
          cleanup
  br label %34

.lr.ph:                                           ; preds = %12, %31
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %7) #6
  %21 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPSt10shared_ptrIN3jet16ImplicitSurface2EESt6vectorIS4_SaIS4_EEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %5) #6
  call void @_ZNSt10shared_ptrIN3jet16ImplicitSurface2EEC2ERKS2_(ptr noundef nonnull align 8 dereferenceable(16) %7, ptr noundef nonnull align 8 dereferenceable(16) %21) #6
  %22 = call noundef ptr @_ZNKSt19__shared_ptr_accessIN3jet16ImplicitSurface2ELN9__gnu_cxx12_Lock_policyE2ELb0ELb0EEptEv(ptr noundef nonnull align 1 dereferenceable(1) %7) #6
  %23 = load ptr, ptr %22, align 8, !tbaa !5
  %24 = getelementptr inbounds i8, ptr %23, i64 24
  %25 = load ptr, ptr %24, align 8
  %26 = invoke noundef zeroext i1 %25(ptr noundef nonnull align 8 dereferenceable(49) %22)
          to label %27 unwind label %29

27:                                               ; preds = %.lr.ph
  br i1 %26, label %31, label %28

28:                                               ; preds = %27
  invoke void @_ZNSt6vectorISt10shared_ptrIN3jet16ImplicitSurface2EESaIS3_EE9push_backERKS3_(ptr noundef nonnull align 8 dereferenceable(24) %10, ptr noundef nonnull align 8 dereferenceable(16) %7)
          to label %31 unwind label %29

29:                                               ; preds = %28, %.lr.ph
  %30 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt12__shared_ptrIN3jet16ImplicitSurface2ELN9__gnu_cxx12_Lock_policyE2EED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %7) #6
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %7) #6
  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 @_ZN3jet4Bvh2ISt10shared_ptrINS_16ImplicitSurface2EEED2Ev(ptr noundef nonnull align 8 dereferenceable(120) %11) #6
  br label %34

31:                                               ; preds = %28, %27
  call void @_ZNSt12__shared_ptrIN3jet16ImplicitSurface2ELN9__gnu_cxx12_Lock_policyE2EED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %7) #6
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %7) #6
  %32 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZN9__gnu_cxx17__normal_iteratorIPSt10shared_ptrIN3jet16ImplicitSurface2EESt6vectorIS4_SaIS4_EEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %5) #6
  %33 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPSt10shared_ptrIN3jet16ImplicitSurface2EESt6vectorIS4_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 %33, label %.lr.ph, label %._crit_edge

34:                                               ; preds = %29, %19
  %.pn = phi { ptr, i32 } [ %30, %29 ], [ %20, %19 ]
  call void @_ZNSt6vectorISt10shared_ptrIN3jet16ImplicitSurface2EESaIS3_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %10) #6
  call void @_ZNSt6vectorISt10shared_ptrIN3jet16ImplicitSurface2EESaIS3_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %8) #6
  br label %35

35:                                               ; preds = %34, %17
  %.pn.pn = phi { ptr, i32 } [ %.pn, %34 ], [ %18, %17 ]
  call void @_ZN3jet16ImplicitSurface2D2Ev(ptr noundef nonnull align 8 dereferenceable(49) %0) #6
  resume { ptr, i32 } %.pn.pn
}

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local ptr @_ZNSt6vectorISt10shared_ptrIN3jet16ImplicitSurface2EESaIS3_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_ptrIN3jet16ImplicitSurface2EESt6vectorIS4_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_ptrIN3jet16ImplicitSurface2EESt6vectorIS4_SaIS4_EEEdeEv(ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #2 align 2

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef ptr @_ZNKSt19__shared_ptr_accessIN3jet16ImplicitSurface2ELN9__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_ptrIN3jet16ImplicitSurface2EESaIS3_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 void @_ZNSt12__shared_ptrIN3jet16ImplicitSurface2ELN9__gnu_cxx12_Lock_policyE2EED2Ev(ptr noundef nonnull align 8 dereferenceable(16)) unnamed_addr #2 align 2

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZN3jet4Bvh2ISt10shared_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 = !{!"_ZTSN3jet19ImplicitSurfaceSet2E", !10, i64 0, !17, i64 56, !17, i64 80, !22, i64 104, !16, i64 224}
!10 = !{!"_ZTSN3jet16ImplicitSurface2E", !11, i64 0}
!11 = !{!"_ZTSN3jet8Surface2E", !12, i64 8, !16, i64 48}
!12 = !{!"_ZTSN3jet10Transform2E", !13, i64 0, !14, i64 16, !14, i64 24, !14, i64 32}
!13 = !{!"_ZTSN3jet6VectorIdLm2EEE", !14, i64 0, !14, i64 8}
!14 = !{!"double", !15, i64 0}
!15 = !{!"omnipotent char", !7, i64 0}
!16 = !{!"bool", !15, i64 0}
!17 = !{!"_ZTSSt6vectorISt10shared_ptrIN3jet16ImplicitSurface2EESaIS3_EE", !18, i64 0}
!18 = !{!"_ZTSSt12_Vector_baseISt10shared_ptrIN3jet16ImplicitSurface2EESaIS3_EE", !19, i64 0}
!19 = !{!"_ZTSNSt12_Vector_baseISt10shared_ptrIN3jet16ImplicitSurface2EESaIS3_EE12_Vector_implE", !20, i64 0}
!20 = !{!"_ZTSNSt12_Vector_baseISt10shared_ptrIN3jet16ImplicitSurface2EESaIS3_EE17_Vector_impl_dataE", !21, i64 0, !21, i64 8, !21, i64 16}
!21 = !{!"any pointer", !15, i64 0}
!22 = !{!"_ZTSN3jet4Bvh2ISt10shared_ptrINS_16ImplicitSurface2EEEE", !23, i64 0, !24, i64 8, !25, i64 16, !17, i64 48, !26, i64 72, !30, i64 96}
!23 = !{!"_ZTSN3jet24IntersectionQueryEngine2ISt10shared_ptrINS_16ImplicitSurface2EEEE"}
!24 = !{!"_ZTSN3jet27NearestNeighborQueryEngine2ISt10shared_ptrINS_16ImplicitSurface2EEEE"}
!25 = !{!"_ZTSN3jet11BoundingBoxIdLm2EEE", !13, i64 0, !13, i64 16}
!26 = !{!"_ZTSSt6vectorIN3jet11BoundingBoxIdLm2EEESaIS2_EE", !27, i64 0}
!27 = !{!"_ZTSSt12_Vector_baseIN3jet11BoundingBoxIdLm2EEESaIS2_EE", !28, i64 0}
!28 = !{!"_ZTSNSt12_Vector_baseIN3jet11BoundingBoxIdLm2EEESaIS2_EE12_Vector_implE", !29, i64 0}
!29 = !{!"_ZTSNSt12_Vector_baseIN3jet11BoundingBoxIdLm2EEESaIS2_EE17_Vector_impl_dataE", !21, i64 0, !21, i64 8, !21, i64 16}
!30 = !{!"_ZTSSt6vectorIN3jet4Bvh2ISt10shared_ptrINS0_16ImplicitSurface2EEE4NodeESaIS6_EE", !31, i64 0}
!31 = !{!"_ZTSSt12_Vector_baseIN3jet4Bvh2ISt10shared_ptrINS0_16ImplicitSurface2EEE4NodeESaIS6_EE", !32, i64 0}
!32 = !{!"_ZTSNSt12_Vector_baseIN3jet4Bvh2ISt10shared_ptrINS0_16ImplicitSurface2EEE4NodeESaIS6_EE12_Vector_implE", !33, i64 0}
!33 = !{!"_ZTSNSt12_Vector_baseIN3jet4Bvh2ISt10shared_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