; LLVM IR from niessner/Matterport :: code/gaps/pkgs/R3Shapes (R3Mesh)

; 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.R3Vector = type { [3 x double] }
%class.R3Point = type { [3 x double] }
%class.R3Plane = type { %class.R3Vector, double }
%struct.R3MeshIntersection = type { i32, ptr, ptr, ptr, %class.R3Point, double }

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(24) ptr @_ZNK6R3Mesh14VertexPositionEPK12R3MeshVertex(ptr noundef nonnull align 8 dereferenceable(272), ptr noundef) #1 align 2

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

declare void @_ZN7R3PointC1ERKS_(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #2

declare void @_ZmiRK7R3PointS1_(ptr dead_on_unwind writable sret(%class.R3Vector) align 8, ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(24)) #2

declare void @_ZrmRK8R3VectorS1_(ptr dead_on_unwind writable sret(%class.R3Vector) align 8, ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(24)) #2

declare void @_ZN8R3Vector9NormalizeEv(ptr noundef nonnull align 8 dereferenceable(24)) #2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZmldRK8R3Vector(ptr dead_on_unwind noalias writable sret(%class.R3Vector) align 8, double noundef, ptr noundef nonnull align 8 dereferenceable(24)) #3

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef ptr @_ZNK6R3Mesh10EdgeOnFaceEPK10R3MeshFacei(ptr noundef nonnull align 8 dereferenceable(272), ptr noundef, i32 noundef) #1 align 2

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

declare noundef nonnull align 8 dereferenceable(24) ptr @_ZN7R3PointaSERKS_(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(24)) #2

declare void @_ZmiRK7R3PointRK8R3Vector(ptr dead_on_unwind writable sret(%class.R3Point) align 8, ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(24)) #2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef ptr @_ZNK6R3Mesh12VertexOnEdgeEPK10R3MeshEdgePK10R3MeshFacei(ptr noundef nonnull align 8 dereferenceable(272), ptr noundef, ptr noundef, i32 noundef) #3 align 2

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

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

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef nonnull align 8 dereferenceable(32) ptr @_ZNK6R3Mesh9FacePlaneEPK10R3MeshFace(ptr noundef nonnull align 8 dereferenceable(272), ptr noundef) #3 align 2

declare void @_ZN7R3PlaneC1ERK7R3PointRK8R3Vector(ptr noundef nonnull align 8 dereferenceable(32), ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #2

declare noundef double @_Z16R3SignedDistanceRK7R3PlaneRK7R3Point(ptr noundef nonnull align 8 dereferenceable(32), ptr noundef nonnull align 8 dereferenceable(24)) #2

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

; Function Attrs: mustprogress uwtable
define dso_local noundef double @_Z10R3DistanceP6R3MeshP10R3MeshFaceRK7R3PointP18R3MeshIntersection(ptr noundef %0, ptr noundef %1, ptr noundef nonnull align 8 dereferenceable(24) %2, ptr noundef %3) #4 {
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  %8 = alloca ptr, align 8
  %9 = alloca ptr, align 8
  %10 = alloca ptr, align 8
  %11 = alloca double, align 8
  %12 = alloca %class.R3Point, align 8
  %13 = alloca %class.R3Vector, align 8
  %14 = alloca double, align 8
  %15 = alloca ptr, align 8
  %16 = alloca i32, align 4
  %17 = alloca ptr, align 8
  %18 = alloca ptr, align 8
  %19 = alloca ptr, align 8
  %20 = alloca %class.R3Point, align 8
  %21 = alloca %class.R3Point, align 8
  %22 = alloca %class.R3Vector, align 8
  %23 = alloca %class.R3Vector, align 8
  %24 = alloca %class.R3Plane, align 8
  %25 = alloca double, align 8
  %26 = alloca %struct.R3MeshIntersection, align 8
  %27 = alloca double, 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
  store ptr %3, ptr %8, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %9) #6
  %28 = load ptr, ptr %5, align 8, !tbaa !5
  %29 = load ptr, ptr %6, align 8, !tbaa !5
  %30 = call noundef nonnull align 8 dereferenceable(32) ptr @_ZNK6R3Mesh9FacePlaneEPK10R3MeshFace(ptr noundef nonnull align 8 dereferenceable(272) %28, ptr noundef %29)
  store ptr %30, ptr %9, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #6
  %31 = load ptr, ptr %9, align 8, !tbaa !5
  %32 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNK7R3Plane6NormalEv(ptr noundef nonnull align 8 dereferenceable(32) %31)
  store ptr %32, ptr %10, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #6
  %33 = load ptr, ptr %9, align 8, !tbaa !5
  %34 = load ptr, ptr %7, align 8, !tbaa !5
  %35 = call noundef double @_Z16R3SignedDistanceRK7R3PlaneRK7R3Point(ptr noundef nonnull align 8 dereferenceable(32) %33, ptr noundef nonnull align 8 dereferenceable(24) %34)
  store double %35, ptr %11, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 24, ptr %12) #6
  %36 = load ptr, ptr %7, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 24, ptr %13) #6
  %37 = load double, ptr %11, align 8, !tbaa !9
  %38 = load ptr, ptr %10, align 8, !tbaa !5
  call void @_ZmldRK8R3Vector(ptr dead_on_unwind writable sret(%class.R3Vector) align 8 %13, double noundef %37, ptr noundef nonnull align 8 dereferenceable(24) %38)
  call void @_ZmiRK7R3PointRK8R3Vector(ptr dead_on_unwind writable sret(%class.R3Point) align 8 %12, ptr noundef nonnull align 8 dereferenceable(24) %36, ptr noundef nonnull align 8 dereferenceable(24) %13)
  call void @llvm.lifetime.end.p0(i64 24, ptr %13) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #6
  %39 = load double, ptr %11, align 8, !tbaa !9
  %40 = call double @llvm.fabs.f64(double %39)
  store double %40, ptr %14, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #6
  store ptr null, ptr %15, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %16) #6
  store i32 0, ptr %16, align 4, !tbaa !11
  br label %41

41:                                               ; preds = %90, %4
  %42 = load i32, ptr %16, align 4, !tbaa !11
  %43 = icmp slt i32 %42, 3
  br i1 %43, label %45, label %44

44:                                               ; preds = %41
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #6
  br label %93

45:                                               ; preds = %41
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #6
  %46 = load ptr, ptr %5, align 8, !tbaa !5
  %47 = load ptr, ptr %6, align 8, !tbaa !5
  %48 = load i32, ptr %16, align 4, !tbaa !11
  %49 = call noundef ptr @_ZNK6R3Mesh10EdgeOnFaceEPK10R3MeshFacei(ptr noundef nonnull align 8 dereferenceable(272) %46, ptr noundef %47, i32 noundef %48)
  store ptr %49, ptr %17, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #6
  %50 = load ptr, ptr %5, align 8, !tbaa !5
  %51 = load ptr, ptr %17, align 8, !tbaa !5
  %52 = load ptr, ptr %6, align 8, !tbaa !5
  %53 = call noundef ptr @_ZNK6R3Mesh12VertexOnEdgeEPK10R3MeshEdgePK10R3MeshFacei(ptr noundef nonnull align 8 dereferenceable(272) %50, ptr noundef %51, ptr noundef %52, i32 noundef 1)
  store ptr %53, ptr %18, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %19) #6
  %54 = load ptr, ptr %5, align 8, !tbaa !5
  %55 = load ptr, ptr %17, align 8, !tbaa !5
  %56 = load ptr, ptr %6, align 8, !tbaa !5
  %57 = call noundef ptr @_ZNK6R3Mesh12VertexOnEdgeEPK10R3MeshEdgePK10R3MeshFacei(ptr noundef nonnull align 8 dereferenceable(272) %54, ptr noundef %55, ptr noundef %56, i32 noundef 0)
  store ptr %57, ptr %19, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 24, ptr %20) #6
  %58 = load ptr, ptr %5, align 8, !tbaa !5
  %59 = load ptr, ptr %18, align 8, !tbaa !5
  %60 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNK6R3Mesh14VertexPositionEPK12R3MeshVertex(ptr noundef nonnull align 8 dereferenceable(272) %58, ptr noundef %59)
  call void @_ZN7R3PointC1ERKS_(ptr noundef nonnull align 8 dereferenceable(24) %20, ptr noundef nonnull align 8 dereferenceable(24) %60)
  call void @llvm.lifetime.start.p0(i64 24, ptr %21) #6
  %61 = load ptr, ptr %5, align 8, !tbaa !5
  %62 = load ptr, ptr %19, align 8, !tbaa !5
  %63 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNK6R3Mesh14VertexPositionEPK12R3MeshVertex(ptr noundef nonnull align 8 dereferenceable(272) %61, ptr noundef %62)
  call void @_ZN7R3PointC1ERKS_(ptr noundef nonnull align 8 dereferenceable(24) %21, ptr noundef nonnull align 8 dereferenceable(24) %63)
  call void @llvm.lifetime.start.p0(i64 24, ptr %22) #6
  call void @_ZmiRK7R3PointS1_(ptr dead_on_unwind writable sret(%class.R3Vector) align 8 %22, ptr noundef nonnull align 8 dereferenceable(24) %21, ptr noundef nonnull align 8 dereferenceable(24) %20)
  call void @_ZN8R3Vector9NormalizeEv(ptr noundef nonnull align 8 dereferenceable(24) %22)
  call void @llvm.lifetime.start.p0(i64 24, ptr %23) #6
  %64 = load ptr, ptr %10, align 8, !tbaa !5
  call void @_ZrmRK8R3VectorS1_(ptr dead_on_unwind writable sret(%class.R3Vector) align 8 %23, ptr noundef nonnull align 8 dereferenceable(24) %64, ptr noundef nonnull align 8 dereferenceable(24) %22)
  call void @llvm.lifetime.start.p0(i64 32, ptr %24) #6
  call void @_ZN7R3PlaneC1ERK7R3PointRK8R3Vector(ptr noundef nonnull align 8 dereferenceable(32) %24, ptr noundef nonnull align 8 dereferenceable(24) %20, ptr noundef nonnull align 8 dereferenceable(24) %23)
  call void @llvm.lifetime.start.p0(i64 8, ptr %25) #6
  %65 = call noundef double @_Z16R3SignedDistanceRK7R3PlaneRK7R3Point(ptr noundef nonnull align 8 dereferenceable(32) %24, ptr noundef nonnull align 8 dereferenceable(24) %12)
  store double %65, ptr %25, align 8, !tbaa !9
  %66 = load double, ptr %25, align 8, !tbaa !9
  %67 = fcmp olt double %66, 0.000000e+00
  br i1 %67, label %68, label %89

68:                                               ; preds = %45
  call void @llvm.lifetime.start.p0(i64 64, ptr %26) #6
  call void @_ZN18R3MeshIntersectionC2Ev(ptr noundef nonnull align 8 dereferenceable(64) %26)
  call void @llvm.lifetime.start.p0(i64 8, ptr %27) #6
  %69 = load ptr, ptr %5, align 8, !tbaa !5
  %70 = load ptr, ptr %17, align 8, !tbaa !5
  %71 = load ptr, ptr %7, align 8, !tbaa !5
  %72 = call noundef double @_Z10R3DistanceP6R3MeshP10R3MeshEdgeRK7R3PointP18R3MeshIntersection(ptr noundef %69, ptr noundef %70, ptr noundef nonnull align 8 dereferenceable(24) %71, ptr noundef %26)
  store double %72, ptr %27, align 8, !tbaa !9
  %73 = load ptr, ptr %15, align 8, !tbaa !5
  %74 = icmp ne ptr %73, null
  br i1 %74, label %75, label %79

75:                                               ; preds = %68
  %76 = load double, ptr %27, align 8, !tbaa !9
  %77 = load double, ptr %14, align 8, !tbaa !9
  %78 = fcmp olt double %76, %77
  br i1 %78, label %79, label %88

79:                                               ; preds = %75, %68
  %80 = load ptr, ptr %8, align 8, !tbaa !5
  %81 = icmp ne ptr %80, null
  br i1 %81, label %82, label %85

82:                                               ; preds = %79
  %83 = load ptr, ptr %8, align 8, !tbaa !5
  %84 = call noundef nonnull align 8 dereferenceable(64) ptr @_ZN18R3MeshIntersectionaSERKS_(ptr noundef nonnull align 8 dereferenceable(64) %83, ptr noundef nonnull align 8 dereferenceable(64) %26)
  br label %85

85:                                               ; preds = %82, %79
  %86 = load double, ptr %27, align 8, !tbaa !9
  store double %86, ptr %14, align 8, !tbaa !9
  %87 = load ptr, ptr %17, align 8, !tbaa !5
  store ptr %87, ptr %15, align 8, !tbaa !5
  br label %88

88:                                               ; preds = %85, %75
  call void @llvm.lifetime.end.p0(i64 8, ptr %27) #6
  call void @llvm.lifetime.end.p0(i64 64, ptr %26) #6
  br label %89

89:                                               ; preds = %88, %45
  call void @llvm.lifetime.end.p0(i64 8, ptr %25) #6
  call void @llvm.lifetime.end.p0(i64 32, ptr %24) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr %23) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr %22) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr %21) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr %20) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #6
  br label %90

90:                                               ; preds = %89
  %91 = load i32, ptr %16, align 4, !tbaa !11
  %92 = add nsw i32 %91, 1
  store i32 %92, ptr %16, align 4, !tbaa !11
  br label %41, !llvm.loop !13

93:                                               ; preds = %44
  %94 = load ptr, ptr %8, align 8, !tbaa !5
  %95 = icmp ne ptr %94, null
  br i1 %95, label %96, label %116

96:                                               ; preds = %93
  %97 = load ptr, ptr %6, align 8, !tbaa !5
  %98 = load ptr, ptr %8, align 8, !tbaa !5
  %99 = getelementptr inbounds %struct.R3MeshIntersection, ptr %98, i32 0, i32 3
  store ptr %97, ptr %99, align 8, !tbaa !15
  %100 = load ptr, ptr %15, align 8, !tbaa !5
  %101 = icmp ne ptr %100, null
  br i1 %101, label %115, label %102

102:                                              ; preds = %96
  %103 = load ptr, ptr %8, align 8, !tbaa !5
  %104 = getelementptr inbounds %struct.R3MeshIntersection, ptr %103, i32 0, i32 0
  store i32 3, ptr %104, align 8, !tbaa !19
  %105 = load ptr, ptr %8, align 8, !tbaa !5
  %106 = getelementptr inbounds %struct.R3MeshIntersection, ptr %105, i32 0, i32 1
  store ptr null, ptr %106, align 8, !tbaa !20
  %107 = load ptr, ptr %8, align 8, !tbaa !5
  %108 = getelementptr inbounds %struct.R3MeshIntersection, ptr %107, i32 0, i32 2
  store ptr null, ptr %108, align 8, !tbaa !21
  %109 = load ptr, ptr %8, align 8, !tbaa !5
  %110 = getelementptr inbounds %struct.R3MeshIntersection, ptr %109, i32 0, i32 4
  %111 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZN7R3PointaSERKS_(ptr noundef nonnull align 8 dereferenceable(24) %110, ptr noundef nonnull align 8 dereferenceable(24) %12)
  %112 = load double, ptr %14, align 8, !tbaa !9
  %113 = load ptr, ptr %8, align 8, !tbaa !5
  %114 = getelementptr inbounds %struct.R3MeshIntersection, ptr %113, i32 0, i32 5
  store double %112, ptr %114, align 8, !tbaa !22
  br label %115

115:                                              ; preds = %102, %96
  br label %116

116:                                              ; preds = %115, %93
  %117 = load double, ptr %14, align 8, !tbaa !9
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr %12) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #6
  ret double %117
}

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare double @llvm.fabs.f64(double) #5

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { 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 #2 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { inlinehint mustprogress 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 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #5 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
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 = !{!"double", !7, i64 0}
!11 = !{!12, !12, i64 0}
!12 = !{!"int", !7, i64 0}
!13 = distinct !{!13, !14}
!14 = !{!"llvm.loop.mustprogress"}
!15 = !{!16, !6, i64 24}
!16 = !{!"_ZTS18R3MeshIntersection", !17, i64 0, !6, i64 8, !6, i64 16, !6, i64 24, !18, i64 32, !10, i64 56}
!17 = !{!"_ZTS10R3MeshType", !7, i64 0}
!18 = !{!"_ZTS7R3Point", !7, i64 0}
!19 = !{!16, !17, i64 0}
!20 = !{!16, !6, i64 8}
!21 = !{!16, !6, i64 16}
!22 = !{!16, !10, i64 56}


; 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.R3Vector = type { [3 x double] }
%class.R3Point = type { [3 x double] }
%class.R3Plane = type { %class.R3Vector, double }
%struct.R3MeshIntersection = type { i32, ptr, ptr, ptr, %class.R3Point, double }

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(24) ptr @_ZNK6R3Mesh14VertexPositionEPK12R3MeshVertex(ptr noundef nonnull align 8 dereferenceable(272), ptr noundef) local_unnamed_addr #1 align 2

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

declare void @_ZN7R3PointC1ERKS_(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #2

declare void @_ZmiRK7R3PointS1_(ptr dead_on_unwind writable sret(%class.R3Vector) align 8, ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #2

declare void @_ZrmRK8R3VectorS1_(ptr dead_on_unwind writable sret(%class.R3Vector) align 8, ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #2

declare void @_ZN8R3Vector9NormalizeEv(ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZmldRK8R3Vector(ptr dead_on_unwind noalias writable sret(%class.R3Vector) align 8, double noundef, ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #3

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef ptr @_ZNK6R3Mesh10EdgeOnFaceEPK10R3MeshFacei(ptr noundef nonnull align 8 dereferenceable(272), ptr noundef, i32 noundef) local_unnamed_addr #1 align 2

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

declare noundef nonnull align 8 dereferenceable(24) ptr @_ZN7R3PointaSERKS_(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #2

declare void @_ZmiRK7R3PointRK8R3Vector(ptr dead_on_unwind writable sret(%class.R3Point) align 8, ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef ptr @_ZNK6R3Mesh12VertexOnEdgeEPK10R3MeshEdgePK10R3MeshFacei(ptr noundef nonnull align 8 dereferenceable(272), ptr noundef, ptr noundef, i32 noundef) local_unnamed_addr #3 align 2

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

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

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef nonnull align 8 dereferenceable(32) ptr @_ZNK6R3Mesh9FacePlaneEPK10R3MeshFace(ptr noundef nonnull align 8 dereferenceable(272), ptr noundef) local_unnamed_addr #3 align 2

declare void @_ZN7R3PlaneC1ERK7R3PointRK8R3Vector(ptr noundef nonnull align 8 dereferenceable(32), ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #2

declare noundef double @_Z16R3SignedDistanceRK7R3PlaneRK7R3Point(ptr noundef nonnull align 8 dereferenceable(32), ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #2

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

; Function Attrs: mustprogress uwtable
define dso_local noundef double @_Z10R3DistanceP6R3MeshP10R3MeshFaceRK7R3PointP18R3MeshIntersection(ptr noundef nonnull %0, ptr noundef %1, ptr noundef nonnull align 8 dereferenceable(24) %2, ptr noundef %3) local_unnamed_addr #4 {
  %5 = alloca %class.R3Point, align 8
  %6 = alloca %class.R3Vector, align 8
  %7 = alloca %class.R3Point, align 8
  %8 = alloca %class.R3Point, align 8
  %9 = alloca %class.R3Vector, align 8
  %10 = alloca %class.R3Vector, align 8
  %11 = alloca %class.R3Plane, align 8
  %12 = alloca %struct.R3MeshIntersection, align 8
  %13 = tail call noundef nonnull align 8 dereferenceable(32) ptr @_ZNK6R3Mesh9FacePlaneEPK10R3MeshFace(ptr noundef nonnull align 8 dereferenceable(272) %0, ptr noundef %1)
  %14 = tail call noundef nonnull align 8 dereferenceable(24) ptr @_ZNK7R3Plane6NormalEv(ptr noundef nonnull align 8 dereferenceable(32) %13)
  %15 = tail call noundef double @_Z16R3SignedDistanceRK7R3PlaneRK7R3Point(ptr noundef nonnull align 8 dereferenceable(32) %13, ptr noundef nonnull align 8 dereferenceable(24) %2)
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %5) #7
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %6) #7
  call void @_ZmldRK8R3Vector(ptr dead_on_unwind nonnull writable sret(%class.R3Vector) align 8 %6, double noundef %15, ptr noundef nonnull align 8 dereferenceable(24) %14)
  call void @_ZmiRK7R3PointRK8R3Vector(ptr dead_on_unwind nonnull writable sret(%class.R3Point) align 8 %5, ptr noundef nonnull align 8 dereferenceable(24) %2, ptr noundef nonnull align 8 dereferenceable(24) %6)
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %6) #7
  %16 = call double @llvm.fabs.f64(double %15)
  %.not54 = icmp eq ptr %3, null
  %17 = call noundef ptr @_ZNK6R3Mesh10EdgeOnFaceEPK10R3MeshFacei(ptr noundef nonnull align 8 dereferenceable(272) %0, ptr noundef %1, i32 noundef 0)
  %18 = call noundef ptr @_ZNK6R3Mesh12VertexOnEdgeEPK10R3MeshEdgePK10R3MeshFacei(ptr noundef nonnull align 8 dereferenceable(272) %0, ptr noundef %17, ptr noundef %1, i32 noundef 1)
  %19 = call noundef ptr @_ZNK6R3Mesh12VertexOnEdgeEPK10R3MeshEdgePK10R3MeshFacei(ptr noundef nonnull align 8 dereferenceable(272) %0, ptr noundef %17, ptr noundef %1, i32 noundef 0)
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %7) #7
  %20 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNK6R3Mesh14VertexPositionEPK12R3MeshVertex(ptr noundef nonnull align 8 dereferenceable(272) %0, ptr noundef %18)
  call void @_ZN7R3PointC1ERKS_(ptr noundef nonnull align 8 dereferenceable(24) %7, ptr noundef nonnull align 8 dereferenceable(24) %20)
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %8) #7
  %21 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNK6R3Mesh14VertexPositionEPK12R3MeshVertex(ptr noundef nonnull align 8 dereferenceable(272) %0, ptr noundef %19)
  call void @_ZN7R3PointC1ERKS_(ptr noundef nonnull align 8 dereferenceable(24) %8, ptr noundef nonnull align 8 dereferenceable(24) %21)
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %9) #7
  call void @_ZmiRK7R3PointS1_(ptr dead_on_unwind nonnull writable sret(%class.R3Vector) align 8 %9, ptr noundef nonnull align 8 dereferenceable(24) %8, ptr noundef nonnull align 8 dereferenceable(24) %7)
  call void @_ZN8R3Vector9NormalizeEv(ptr noundef nonnull align 8 dereferenceable(24) %9)
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %10) #7
  call void @_ZrmRK8R3VectorS1_(ptr dead_on_unwind nonnull writable sret(%class.R3Vector) align 8 %10, ptr noundef nonnull align 8 dereferenceable(24) %14, ptr noundef nonnull align 8 dereferenceable(24) %9)
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %11) #7
  call void @_ZN7R3PlaneC1ERK7R3PointRK8R3Vector(ptr noundef nonnull align 8 dereferenceable(32) %11, ptr noundef nonnull align 8 dereferenceable(24) %7, ptr noundef nonnull align 8 dereferenceable(24) %10)
  %22 = call noundef double @_Z16R3SignedDistanceRK7R3PlaneRK7R3Point(ptr noundef nonnull align 8 dereferenceable(32) %11, ptr noundef nonnull align 8 dereferenceable(24) %5)
  %23 = fcmp olt double %22, 0.000000e+00
  br i1 %23, label %24, label %29

24:                                               ; preds = %4
  call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %12) #7
  call void @_ZN18R3MeshIntersectionC2Ev(ptr noundef nonnull align 8 dereferenceable(64) %12)
  %25 = call noundef double @_Z10R3DistanceP6R3MeshP10R3MeshEdgeRK7R3PointP18R3MeshIntersection(ptr noundef nonnull %0, ptr noundef %17, ptr noundef nonnull align 8 dereferenceable(24) %2, ptr noundef nonnull %12)
  br i1 %.not54, label %28, label %26

26:                                               ; preds = %24
  %27 = call noundef nonnull align 8 dereferenceable(64) ptr @_ZN18R3MeshIntersectionaSERKS_(ptr noundef nonnull align 8 dereferenceable(64) %3, ptr noundef nonnull align 8 dereferenceable(64) %12)
  br label %28

28:                                               ; preds = %24, %26
  call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %12) #7
  br label %29

29:                                               ; preds = %28, %4
  %.248 = phi ptr [ %17, %28 ], [ null, %4 ]
  %.2 = phi double [ %25, %28 ], [ %16, %4 ]
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %11) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %10) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %9) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %8) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %7) #7
  %30 = call noundef ptr @_ZNK6R3Mesh10EdgeOnFaceEPK10R3MeshFacei(ptr noundef nonnull align 8 dereferenceable(272) %0, ptr noundef %1, i32 noundef 1)
  %31 = call noundef ptr @_ZNK6R3Mesh12VertexOnEdgeEPK10R3MeshEdgePK10R3MeshFacei(ptr noundef nonnull align 8 dereferenceable(272) %0, ptr noundef %30, ptr noundef %1, i32 noundef 1)
  %32 = call noundef ptr @_ZNK6R3Mesh12VertexOnEdgeEPK10R3MeshEdgePK10R3MeshFacei(ptr noundef nonnull align 8 dereferenceable(272) %0, ptr noundef %30, ptr noundef %1, i32 noundef 0)
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %7) #7
  %33 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNK6R3Mesh14VertexPositionEPK12R3MeshVertex(ptr noundef nonnull align 8 dereferenceable(272) %0, ptr noundef %31)
  call void @_ZN7R3PointC1ERKS_(ptr noundef nonnull align 8 dereferenceable(24) %7, ptr noundef nonnull align 8 dereferenceable(24) %33)
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %8) #7
  %34 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNK6R3Mesh14VertexPositionEPK12R3MeshVertex(ptr noundef nonnull align 8 dereferenceable(272) %0, ptr noundef %32)
  call void @_ZN7R3PointC1ERKS_(ptr noundef nonnull align 8 dereferenceable(24) %8, ptr noundef nonnull align 8 dereferenceable(24) %34)
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %9) #7
  call void @_ZmiRK7R3PointS1_(ptr dead_on_unwind nonnull writable sret(%class.R3Vector) align 8 %9, ptr noundef nonnull align 8 dereferenceable(24) %8, ptr noundef nonnull align 8 dereferenceable(24) %7)
  call void @_ZN8R3Vector9NormalizeEv(ptr noundef nonnull align 8 dereferenceable(24) %9)
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %10) #7
  call void @_ZrmRK8R3VectorS1_(ptr dead_on_unwind nonnull writable sret(%class.R3Vector) align 8 %10, ptr noundef nonnull align 8 dereferenceable(24) %14, ptr noundef nonnull align 8 dereferenceable(24) %9)
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %11) #7
  call void @_ZN7R3PlaneC1ERK7R3PointRK8R3Vector(ptr noundef nonnull align 8 dereferenceable(32) %11, ptr noundef nonnull align 8 dereferenceable(24) %7, ptr noundef nonnull align 8 dereferenceable(24) %10)
  %35 = call noundef double @_Z16R3SignedDistanceRK7R3PlaneRK7R3Point(ptr noundef nonnull align 8 dereferenceable(32) %11, ptr noundef nonnull align 8 dereferenceable(24) %5)
  %36 = fcmp olt double %35, 0.000000e+00
  br i1 %36, label %37, label %43

37:                                               ; preds = %29
  call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %12) #7
  call void @_ZN18R3MeshIntersectionC2Ev(ptr noundef nonnull align 8 dereferenceable(64) %12)
  %38 = call noundef double @_Z10R3DistanceP6R3MeshP10R3MeshEdgeRK7R3PointP18R3MeshIntersection(ptr noundef nonnull %0, ptr noundef %30, ptr noundef nonnull align 8 dereferenceable(24) %2, ptr noundef nonnull %12)
  %.not53.1 = icmp ne ptr %.248, null
  %39 = fcmp uge double %38, %.2
  %or.cond.not59.1 = and i1 %.not53.1, %39
  %brmerge.1 = or i1 %or.cond.not59.1, %.not54
  %.04656.mux.1 = select i1 %or.cond.not59.1, ptr %.248, ptr %30
  %.057.mux.1 = select i1 %or.cond.not59.1, double %.2, double %38
  br i1 %brmerge.1, label %42, label %40

40:                                               ; preds = %37
  %41 = call noundef nonnull align 8 dereferenceable(64) ptr @_ZN18R3MeshIntersectionaSERKS_(ptr noundef nonnull align 8 dereferenceable(64) %3, ptr noundef nonnull align 8 dereferenceable(64) %12)
  br label %42

42:                                               ; preds = %40, %37
  %.147.1 = phi ptr [ %.04656.mux.1, %37 ], [ %30, %40 ]
  %.1.1 = phi double [ %.057.mux.1, %37 ], [ %38, %40 ]
  call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %12) #7
  br label %43

43:                                               ; preds = %42, %29
  %.248.1 = phi ptr [ %.147.1, %42 ], [ %.248, %29 ]
  %.2.1 = phi double [ %.1.1, %42 ], [ %.2, %29 ]
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %11) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %10) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %9) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %8) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %7) #7
  %44 = call noundef ptr @_ZNK6R3Mesh10EdgeOnFaceEPK10R3MeshFacei(ptr noundef nonnull align 8 dereferenceable(272) %0, ptr noundef %1, i32 noundef 2)
  %45 = call noundef ptr @_ZNK6R3Mesh12VertexOnEdgeEPK10R3MeshEdgePK10R3MeshFacei(ptr noundef nonnull align 8 dereferenceable(272) %0, ptr noundef %44, ptr noundef %1, i32 noundef 1)
  %46 = call noundef ptr @_ZNK6R3Mesh12VertexOnEdgeEPK10R3MeshEdgePK10R3MeshFacei(ptr noundef nonnull align 8 dereferenceable(272) %0, ptr noundef %44, ptr noundef %1, i32 noundef 0)
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %7) #7
  %47 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNK6R3Mesh14VertexPositionEPK12R3MeshVertex(ptr noundef nonnull align 8 dereferenceable(272) %0, ptr noundef %45)
  call void @_ZN7R3PointC1ERKS_(ptr noundef nonnull align 8 dereferenceable(24) %7, ptr noundef nonnull align 8 dereferenceable(24) %47)
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %8) #7
  %48 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNK6R3Mesh14VertexPositionEPK12R3MeshVertex(ptr noundef nonnull align 8 dereferenceable(272) %0, ptr noundef %46)
  call void @_ZN7R3PointC1ERKS_(ptr noundef nonnull align 8 dereferenceable(24) %8, ptr noundef nonnull align 8 dereferenceable(24) %48)
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %9) #7
  call void @_ZmiRK7R3PointS1_(ptr dead_on_unwind nonnull writable sret(%class.R3Vector) align 8 %9, ptr noundef nonnull align 8 dereferenceable(24) %8, ptr noundef nonnull align 8 dereferenceable(24) %7)
  call void @_ZN8R3Vector9NormalizeEv(ptr noundef nonnull align 8 dereferenceable(24) %9)
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %10) #7
  call void @_ZrmRK8R3VectorS1_(ptr dead_on_unwind nonnull writable sret(%class.R3Vector) align 8 %10, ptr noundef nonnull align 8 dereferenceable(24) %14, ptr noundef nonnull align 8 dereferenceable(24) %9)
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %11) #7
  call void @_ZN7R3PlaneC1ERK7R3PointRK8R3Vector(ptr noundef nonnull align 8 dereferenceable(32) %11, ptr noundef nonnull align 8 dereferenceable(24) %7, ptr noundef nonnull align 8 dereferenceable(24) %10)
  %49 = call noundef double @_Z16R3SignedDistanceRK7R3PlaneRK7R3Point(ptr noundef nonnull align 8 dereferenceable(32) %11, ptr noundef nonnull align 8 dereferenceable(24) %5)
  %50 = fcmp olt double %49, 0.000000e+00
  br i1 %50, label %51, label %57

51:                                               ; preds = %43
  call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %12) #7
  call void @_ZN18R3MeshIntersectionC2Ev(ptr noundef nonnull align 8 dereferenceable(64) %12)
  %52 = call noundef double @_Z10R3DistanceP6R3MeshP10R3MeshEdgeRK7R3PointP18R3MeshIntersection(ptr noundef nonnull %0, ptr noundef %44, ptr noundef nonnull align 8 dereferenceable(24) %2, ptr noundef nonnull %12)
  %.not53.2 = icmp ne ptr %.248.1, null
  %53 = fcmp uge double %52, %.2.1
  %or.cond.not59.2 = and i1 %.not53.2, %53
  %brmerge.2 = or i1 %or.cond.not59.2, %.not54
  %.04656.mux.2 = select i1 %or.cond.not59.2, ptr %.248.1, ptr %44
  %.057.mux.2 = select i1 %or.cond.not59.2, double %.2.1, double %52
  br i1 %brmerge.2, label %56, label %54

54:                                               ; preds = %51
  %55 = call noundef nonnull align 8 dereferenceable(64) ptr @_ZN18R3MeshIntersectionaSERKS_(ptr noundef nonnull align 8 dereferenceable(64) %3, ptr noundef nonnull align 8 dereferenceable(64) %12)
  br label %56

56:                                               ; preds = %54, %51
  %.147.2 = phi ptr [ %.04656.mux.2, %51 ], [ %44, %54 ]
  %.1.2 = phi double [ %.057.mux.2, %51 ], [ %52, %54 ]
  call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %12) #7
  br label %57

57:                                               ; preds = %56, %43
  %.248.2 = phi ptr [ %.147.2, %56 ], [ %.248.1, %43 ]
  %.2.2 = phi double [ %.1.2, %56 ], [ %.2.1, %43 ]
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %11) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %10) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %9) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %8) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %7) #7
  br i1 %.not54, label %65, label %58

58:                                               ; preds = %57
  %59 = getelementptr inbounds i8, ptr %3, i64 24
  store ptr %1, ptr %59, align 8, !tbaa !5
  %.not52 = icmp eq ptr %.248.2, null
  br i1 %.not52, label %60, label %65

60:                                               ; preds = %58
  store i32 3, ptr %3, align 8, !tbaa !13
  %61 = getelementptr inbounds i8, ptr %3, i64 8
  %62 = getelementptr inbounds i8, ptr %3, i64 32
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %61, i8 0, i64 16, i1 false)
  %63 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZN7R3PointaSERKS_(ptr noundef nonnull align 8 dereferenceable(24) %62, ptr noundef nonnull align 8 dereferenceable(24) %5)
  %64 = getelementptr inbounds i8, ptr %3, i64 56
  store double %.2.2, ptr %64, align 8, !tbaa !14
  br label %65

65:                                               ; preds = %58, %60, %57
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %5) #7
  ret double %.2.2
}

; Function Attrs: mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare double @llvm.fabs.f64(double) #5

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

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

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !10, i64 24}
!6 = !{!"_ZTS18R3MeshIntersection", !7, i64 0, !10, i64 8, !10, i64 16, !10, i64 24, !11, i64 32, !12, i64 56}
!7 = !{!"_ZTS10R3MeshType", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C++ TBAA"}
!10 = !{!"any pointer", !8, i64 0}
!11 = !{!"_ZTS7R3Point", !8, i64 0}
!12 = !{!"double", !8, i64 0}
!13 = !{!6, !7, i64 0}
!14 = !{!6, !12, i64 56}


; Effective O3 passes: EarlyCSEPass,GVNPass,GlobalOptPass,IndVarSimplifyPass,InferFunctionAttrsPass,InstCombinePass,LCSSAPass,LICMPass,LoopRotatePass,MemCpyOptPass,PostOrderFunctionAttrsPass,SROAPass,SimplifyCFGPass,TailCallElimPass