; LLVM IR from jrouwe/JoltPhysics :: Jolt/Physics/Collision (TransformedShape)

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

%"struct.JPH::RRayCast" = type { %"struct.JPH::RayCastT.1" }
%"struct.JPH::RayCastT.1" = type { %"class.JPH::Vec3", %"class.JPH::Vec3" }
%"class.JPH::Vec3" = type { %union.anon }
%union.anon = type { <4 x float> }
%"class.JPH::Mat44" = type { [4 x %"class.JPH::Vec4"] }
%"class.JPH::Vec4" = type { %union.anon.0 }
%union.anon.0 = type { <4 x float> }
%"struct.JPH::RayCast" = type { %"struct.JPH::RayCastT" }
%"struct.JPH::RayCastT" = type { %"class.JPH::Vec3", %"class.JPH::Vec3" }
%"class.JPH::SubShapeIDCreator" = type { %"class.JPH::SubShapeID", i32 }
%"class.JPH::SubShapeID" = type { i32 }
%"class.JPH::TransformedShape" = type { %"class.JPH::Vec3", %"class.JPH::Quat", %"class.JPH::RefConst", %"class.JPH::Float3", %"class.JPH::BodyID", %"class.JPH::SubShapeIDCreator" }
%"class.JPH::Quat" = type { %"class.JPH::Vec4" }
%"class.JPH::RefConst" = type { ptr }
%"class.JPH::Float3" = type { float, float, float }
%"class.JPH::BodyID" = type { i32 }
%"class.JPH::ShapeFilter" = type <{ ptr, %"class.JPH::BodyID", [4 x i8] }>

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

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNK3JPH8RayCastTINS_4Vec3ENS_5Mat44ENS_8RRayCastEE11TransformedERKS2_(ptr dead_on_unwind noalias writable sret(%"struct.JPH::RRayCast") align 16, ptr noundef nonnull align 16 dereferenceable(32), ptr noundef nonnull align 16 dereferenceable(64)) #2 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZNK3JPH16TransformedShape31GetInverseCenterOfMassTransformEv(ptr dead_on_unwind noalias writable sret(%"class.JPH::Mat44") align 16, ptr noundef nonnull align 16 dereferenceable(64)) #3 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNK3JPH8RRayCastcvNS_7RayCastEEv(ptr dead_on_unwind noalias writable sret(%"struct.JPH::RayCast") align 16, ptr noundef nonnull align 16 dereferenceable(32)) #2 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local { double, double } @_ZNK3JPH16TransformedShape13GetShapeScaleEv(ptr noundef nonnull align 16 dereferenceable(64)) #3 align 2

; Function Attrs: alwaysinline mustprogress uwtable
declare dso_local { double, double } @_ZNK3JPH4Vec310ReciprocalEv(ptr noundef nonnull align 16 dereferenceable(16)) #4 align 2

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

; Function Attrs: alwaysinline mustprogress nounwind uwtable
declare dso_local noundef nonnull align 16 dereferenceable(16) ptr @_ZN3JPH4Vec3mLES0_(ptr noundef nonnull align 16 dereferenceable(16), double, double) #6 align 2

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZNK3JPH16TransformedShape7CastRayERKNS_8RRayCastERKNS_15RayCastSettingsERNS_18CollisionCollectorINS_13RayCastResultENS_31CollisionCollectorTraitsCastRayEEERKNS_11ShapeFilterE(ptr noundef nonnull align 16 dereferenceable(64) %0, ptr noundef nonnull align 16 dereferenceable(32) %1, ptr noundef nonnull align 1 dereferenceable(3) %2, ptr noundef nonnull align 8 dereferenceable(24) %3, ptr noundef nonnull align 8 dereferenceable(12) %4) #2 align 2 {
  %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 %"struct.JPH::RayCast", align 16
  %12 = alloca %"struct.JPH::RRayCast", align 16
  %13 = alloca %"class.JPH::Mat44", align 16
  %14 = alloca %"class.JPH::Vec3", align 16
  %15 = alloca %"class.JPH::Vec3", align 16
  %16 = alloca %"class.JPH::Vec3", align 16
  %17 = alloca %"class.JPH::Vec3", align 16
  %18 = alloca %"class.JPH::SubShapeIDCreator", align 4
  store ptr %0, ptr %6, align 8, !tbaa !5
  store ptr %1, ptr %7, align 8, !tbaa !5
  store ptr %2, ptr %8, align 8, !tbaa !5
  store ptr %3, ptr %9, align 8, !tbaa !5
  store ptr %4, ptr %10, align 8, !tbaa !5
  %19 = load ptr, ptr %6, align 8
  %20 = getelementptr inbounds %"class.JPH::TransformedShape", ptr %19, i32 0, i32 2
  %21 = call noundef zeroext i1 @_ZNK3JPH8RefConstINS_5ShapeEEneEPKS1_(ptr noundef nonnull align 8 dereferenceable(8) %20, ptr noundef null)
  br i1 %21, label %22, label %63

22:                                               ; preds = %5
  %23 = load ptr, ptr %9, align 8, !tbaa !5
  call void @_ZN3JPH18CollisionCollectorINS_13RayCastResultENS_31CollisionCollectorTraitsCastRayEE10SetContextEPKNS_16TransformedShapeE(ptr noundef nonnull align 8 dereferenceable(24) %23, ptr noundef %19)
  %24 = getelementptr inbounds %"class.JPH::TransformedShape", ptr %19, i32 0, i32 4
  %25 = load ptr, ptr %10, align 8, !tbaa !5
  %26 = getelementptr inbounds %"class.JPH::ShapeFilter", ptr %25, i32 0, i32 1
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %26, ptr align 4 %24, i64 4, i1 false), !tbaa.struct !9
  call void @llvm.lifetime.start.p0(i64 32, ptr %11) #8
  call void @llvm.lifetime.start.p0(i64 32, ptr %12) #8
  %27 = load ptr, ptr %7, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 64, ptr %13) #8
  call void @_ZNK3JPH16TransformedShape31GetInverseCenterOfMassTransformEv(ptr dead_on_unwind writable sret(%"class.JPH::Mat44") align 16 %13, ptr noundef nonnull align 16 dereferenceable(64) %19)
  call void @_ZNK3JPH8RayCastTINS_4Vec3ENS_5Mat44ENS_8RRayCastEE11TransformedERKS2_(ptr dead_on_unwind writable sret(%"struct.JPH::RRayCast") align 16 %12, ptr noundef nonnull align 16 dereferenceable(32) %27, ptr noundef nonnull align 16 dereferenceable(64) %13)
  call void @_ZNK3JPH8RRayCastcvNS_7RayCastEEv(ptr dead_on_unwind writable sret(%"struct.JPH::RayCast") align 16 %11, ptr noundef nonnull align 16 dereferenceable(32) %12)
  call void @llvm.lifetime.end.p0(i64 64, ptr %13) #8
  call void @llvm.lifetime.end.p0(i64 32, ptr %12) #8
  call void @llvm.lifetime.start.p0(i64 16, ptr %14) #8
  call void @llvm.lifetime.start.p0(i64 16, ptr %15) #8
  %28 = call { double, double } @_ZNK3JPH16TransformedShape13GetShapeScaleEv(ptr noundef nonnull align 16 dereferenceable(64) %19)
  %29 = getelementptr inbounds %"class.JPH::Vec3", ptr %15, i32 0, i32 0
  %30 = getelementptr inbounds %union.anon, ptr %29, i32 0, i32 0
  %31 = getelementptr inbounds { double, double }, ptr %30, i32 0, i32 0
  %32 = extractvalue { double, double } %28, 0
  store double %32, ptr %31, align 16
  %33 = getelementptr inbounds { double, double }, ptr %30, i32 0, i32 1
  %34 = extractvalue { double, double } %28, 1
  store double %34, ptr %33, align 8
  %35 = call { double, double } @_ZNK3JPH4Vec310ReciprocalEv(ptr noundef nonnull align 16 dereferenceable(16) %15)
  %36 = getelementptr inbounds %"class.JPH::Vec3", ptr %14, i32 0, i32 0
  %37 = getelementptr inbounds %union.anon, ptr %36, i32 0, i32 0
  %38 = getelementptr inbounds { double, double }, ptr %37, i32 0, i32 0
  %39 = extractvalue { double, double } %35, 0
  store double %39, ptr %38, align 16
  %40 = getelementptr inbounds { double, double }, ptr %37, i32 0, i32 1
  %41 = extractvalue { double, double } %35, 1
  store double %41, ptr %40, align 8
  call void @llvm.lifetime.end.p0(i64 16, ptr %15) #8
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 %16, ptr align 16 %14, i64 16, i1 false), !tbaa.struct !12
  %42 = getelementptr inbounds %"struct.JPH::RayCastT", ptr %11, i32 0, i32 0
  %43 = getelementptr inbounds { double, double }, ptr %16, i32 0, i32 0
  %44 = load double, ptr %43, align 16
  %45 = getelementptr inbounds { double, double }, ptr %16, i32 0, i32 1
  %46 = load double, ptr %45, align 8
  %47 = call noundef nonnull align 16 dereferenceable(16) ptr @_ZN3JPH4Vec3mLES0_(ptr noundef nonnull align 16 dereferenceable(16) %42, double %44, double %46)
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 %17, ptr align 16 %14, i64 16, i1 false), !tbaa.struct !12
  %48 = getelementptr inbounds %"struct.JPH::RayCastT", ptr %11, i32 0, i32 1
  %49 = getelementptr inbounds { double, double }, ptr %17, i32 0, i32 0
  %50 = load double, ptr %49, align 16
  %51 = getelementptr inbounds { double, double }, ptr %17, i32 0, i32 1
  %52 = load double, ptr %51, align 8
  %53 = call noundef nonnull align 16 dereferenceable(16) ptr @_ZN3JPH4Vec3mLES0_(ptr noundef nonnull align 16 dereferenceable(16) %48, double %50, double %52)
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #8
  %54 = getelementptr inbounds %"class.JPH::TransformedShape", ptr %19, i32 0, i32 5
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %18, ptr align 8 %54, i64 8, i1 false), !tbaa.struct !14
  %55 = getelementptr inbounds %"class.JPH::TransformedShape", ptr %19, i32 0, i32 2
  %56 = call noundef ptr @_ZNK3JPH8RefConstINS_5ShapeEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %55)
  %57 = load ptr, ptr %8, align 8, !tbaa !5
  %58 = load ptr, ptr %9, align 8, !tbaa !5
  %59 = load ptr, ptr %10, align 8, !tbaa !5
  %60 = load ptr, ptr %56, align 8, !tbaa !15
  %61 = getelementptr inbounds ptr, ptr %60, i64 17
  %62 = load ptr, ptr %61, align 8
  call void %62(ptr noundef nonnull align 8 dereferenceable(26) %56, ptr noundef nonnull align 16 dereferenceable(32) %11, ptr noundef nonnull align 1 dereferenceable(3) %57, ptr noundef nonnull align 4 dereferenceable(8) %18, ptr noundef nonnull align 8 dereferenceable(24) %58, ptr noundef nonnull align 8 dereferenceable(12) %59)
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #8
  call void @llvm.lifetime.end.p0(i64 16, ptr %14) #8
  call void @llvm.lifetime.end.p0(i64 32, ptr %11) #8
  br label %63

63:                                               ; preds = %22, %5
  ret void
}

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

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 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { inlinehint mustprogress 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 = { alwaysinline mustprogress uwtable "min-legal-vector-width"="128" "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 nounwind willreturn memory(argmem: readwrite) }
attributes #6 = { alwaysinline mustprogress nounwind uwtable "min-legal-vector-width"="128" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #7 = { 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 #8 = { 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 = !{i64 0, i64 4, !10}
!10 = !{!11, !11, i64 0}
!11 = !{!"int", !7, i64 0}
!12 = !{i64 0, i64 16, !13}
!13 = !{!7, !7, i64 0}
!14 = !{i64 0, i64 4, !10, i64 4, i64 4, !10}
!15 = !{!16, !16, i64 0}
!16 = !{!"vtable pointer", !8, i64 0}


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

%"struct.JPH::RRayCast" = type { %"struct.JPH::RayCastT.1" }
%"struct.JPH::RayCastT.1" = type { %"class.JPH::Vec3", %"class.JPH::Vec3" }
%"class.JPH::Vec3" = type { %union.anon }
%union.anon = type { <4 x float> }
%"class.JPH::Mat44" = type { [4 x %"class.JPH::Vec4"] }
%"class.JPH::Vec4" = type { %union.anon.0 }
%union.anon.0 = type { <4 x float> }
%"struct.JPH::RayCast" = type { %"struct.JPH::RayCastT" }
%"struct.JPH::RayCastT" = type { %"class.JPH::Vec3", %"class.JPH::Vec3" }
%"class.JPH::SubShapeIDCreator" = type { %"class.JPH::SubShapeID", i32 }
%"class.JPH::SubShapeID" = type { i32 }

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

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNK3JPH8RayCastTINS_4Vec3ENS_5Mat44ENS_8RRayCastEE11TransformedERKS2_(ptr dead_on_unwind noalias writable sret(%"struct.JPH::RRayCast") align 16, ptr noundef nonnull align 16 dereferenceable(32), ptr noundef nonnull align 16 dereferenceable(64)) local_unnamed_addr #2 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZNK3JPH16TransformedShape31GetInverseCenterOfMassTransformEv(ptr dead_on_unwind noalias writable sret(%"class.JPH::Mat44") align 16, ptr noundef nonnull align 16 dereferenceable(64)) local_unnamed_addr #3 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNK3JPH8RRayCastcvNS_7RayCastEEv(ptr dead_on_unwind noalias writable sret(%"struct.JPH::RayCast") align 16, ptr noundef nonnull align 16 dereferenceable(32)) local_unnamed_addr #2 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local { double, double } @_ZNK3JPH16TransformedShape13GetShapeScaleEv(ptr noundef nonnull align 16 dereferenceable(64)) local_unnamed_addr #3 align 2

; Function Attrs: alwaysinline mustprogress uwtable
declare dso_local { double, double } @_ZNK3JPH4Vec310ReciprocalEv(ptr noundef nonnull align 16 dereferenceable(16)) local_unnamed_addr #4 align 2

; Function Attrs: alwaysinline mustprogress nounwind uwtable
declare dso_local noundef nonnull align 16 dereferenceable(16) ptr @_ZN3JPH4Vec3mLES0_(ptr noundef nonnull align 16 dereferenceable(16), double, double) local_unnamed_addr #5 align 2

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZNK3JPH16TransformedShape7CastRayERKNS_8RRayCastERKNS_15RayCastSettingsERNS_18CollisionCollectorINS_13RayCastResultENS_31CollisionCollectorTraitsCastRayEEERKNS_11ShapeFilterE(ptr noundef nonnull align 16 dereferenceable(64) %0, ptr noundef nonnull align 16 dereferenceable(32) %1, ptr noundef nonnull align 1 dereferenceable(3) %2, ptr noundef nonnull align 8 dereferenceable(24) %3, ptr noundef nonnull align 8 dereferenceable(12) %4) local_unnamed_addr #2 align 2 {
  %6 = alloca %"struct.JPH::RayCast", align 16
  %7 = alloca %"struct.JPH::RRayCast", align 16
  %8 = alloca %"class.JPH::Mat44", align 16
  %9 = alloca %"class.JPH::Vec3", align 16
  %10 = alloca %"class.JPH::SubShapeIDCreator", align 8
  %11 = getelementptr inbounds i8, ptr %0, i64 32
  %12 = tail call noundef zeroext i1 @_ZNK3JPH8RefConstINS_5ShapeEEneEPKS1_(ptr noundef nonnull align 8 dereferenceable(8) %11, ptr noundef null)
  br i1 %12, label %13, label %33

13:                                               ; preds = %5
  tail call void @_ZN3JPH18CollisionCollectorINS_13RayCastResultENS_31CollisionCollectorTraitsCastRayEE10SetContextEPKNS_16TransformedShapeE(ptr noundef nonnull align 8 dereferenceable(24) %3, ptr noundef nonnull %0)
  %14 = getelementptr inbounds i8, ptr %0, i64 52
  %15 = getelementptr inbounds i8, ptr %4, i64 8
  %16 = load i32, ptr %14, align 4, !tbaa !5
  store i32 %16, ptr %15, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %6) #7
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %7) #7
  call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %8) #7
  call void @_ZNK3JPH16TransformedShape31GetInverseCenterOfMassTransformEv(ptr dead_on_unwind nonnull writable sret(%"class.JPH::Mat44") align 16 %8, ptr noundef nonnull align 16 dereferenceable(64) %0)
  call void @_ZNK3JPH8RayCastTINS_4Vec3ENS_5Mat44ENS_8RRayCastEE11TransformedERKS2_(ptr dead_on_unwind nonnull writable sret(%"struct.JPH::RRayCast") align 16 %7, ptr noundef nonnull align 16 dereferenceable(32) %1, ptr noundef nonnull align 16 dereferenceable(64) %8)
  call void @_ZNK3JPH8RRayCastcvNS_7RayCastEEv(ptr dead_on_unwind nonnull writable sret(%"struct.JPH::RayCast") align 16 %6, ptr noundef nonnull align 16 dereferenceable(32) %7)
  call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %8) #7
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %7) #7
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %9) #7
  %17 = call { double, double } @_ZNK3JPH16TransformedShape13GetShapeScaleEv(ptr noundef nonnull align 16 dereferenceable(64) %0)
  %18 = extractvalue { double, double } %17, 0
  store double %18, ptr %9, align 16
  %19 = getelementptr inbounds i8, ptr %9, i64 8
  %20 = extractvalue { double, double } %17, 1
  store double %20, ptr %19, align 8
  %21 = call { double, double } @_ZNK3JPH4Vec310ReciprocalEv(ptr noundef nonnull align 16 dereferenceable(16) %9)
  %22 = extractvalue { double, double } %21, 0
  %23 = extractvalue { double, double } %21, 1
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %9) #7
  %24 = call noundef nonnull align 16 dereferenceable(16) ptr @_ZN3JPH4Vec3mLES0_(ptr noundef nonnull align 16 dereferenceable(16) %6, double %22, double %23)
  %25 = getelementptr inbounds i8, ptr %6, i64 16
  %26 = call noundef nonnull align 16 dereferenceable(16) ptr @_ZN3JPH4Vec3mLES0_(ptr noundef nonnull align 16 dereferenceable(16) %25, double %22, double %23)
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %10) #7
  %27 = getelementptr inbounds i8, ptr %0, i64 56
  %28 = load i64, ptr %27, align 8
  store i64 %28, ptr %10, align 8
  %29 = call noundef ptr @_ZNK3JPH8RefConstINS_5ShapeEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %11)
  %30 = load ptr, ptr %29, align 8, !tbaa !9
  %31 = getelementptr inbounds i8, ptr %30, i64 136
  %32 = load ptr, ptr %31, align 8
  call void %32(ptr noundef nonnull align 8 dereferenceable(26) %29, ptr noundef nonnull align 16 dereferenceable(32) %6, ptr noundef nonnull align 1 dereferenceable(3) %2, ptr noundef nonnull align 4 dereferenceable(8) %10, ptr noundef nonnull align 8 dereferenceable(24) %3, ptr noundef nonnull align 8 dereferenceable(12) %4)
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %10) #7
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %6) #7
  br label %33

33:                                               ; preds = %13, %5
  ret void
}

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

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 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { inlinehint mustprogress 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 = { alwaysinline mustprogress uwtable "min-legal-vector-width"="128" "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 = { alwaysinline mustprogress nounwind uwtable "min-legal-vector-width"="128" "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 = { mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #7 = { nounwind }

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

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


; Effective O3 passes: EarlyCSEPass,GlobalOptPass,InferAlignmentPass,InferFunctionAttrsPass,InstCombinePass,SROAPass,TailCallElimPass