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

; 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.JPH::AABox" = type { %"class.JPH::Vec3", %"class.JPH::Vec3" }
%"class.JPH::Vec3" = type { %union.anon.7 }
%union.anon.7 = type { <4 x float> }
%"class.JPH::Mat44" = type { [4 x %"class.JPH::Vec4"] }
%"class.JPH::Vec4" = type { %union.anon.8 }
%union.anon.8 = type { <4 x float> }
%"class.JPH::CompoundShape" = type <{ %"class.JPH::Shape.base", [6 x i8], %"class.JPH::Vec3", %"class.JPH::AABox", %"class.JPH::Array.11", float, [4 x i8] }>
%"class.JPH::Shape.base" = type <{ ptr, %"class.JPH::RefTarget.10", [4 x i8], i64, i8, i8 }>
%"class.JPH::RefTarget.10" = type { %"struct.std::atomic" }
%"struct.std::atomic" = type { %"struct.std::__atomic_base" }
%"struct.std::__atomic_base" = type { i32 }
%"class.JPH::Array.11" = type { i64, i64, ptr }
%"struct.JPH::CompoundShape::SubShape" = type <{ %"class.JPH::RefConst.9", %"class.JPH::Float3", %"class.JPH::Float3", i32, i8, [3 x i8] }>
%"class.JPH::RefConst.9" = type { ptr }
%"class.JPH::Float3" = type { float, float, float }

; 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: 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) #1

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

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

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZNK3JPH13CompoundShape19GetWorldSpaceBoundsERKNS_5Mat44ENS_4Vec3E(ptr dead_on_unwind noalias writable sret(%"class.JPH::AABox") align 16 %0, ptr noundef nonnull align 16 dereferenceable(108) %1, ptr noundef nonnull align 16 dereferenceable(64) %2, double %3, double %4) unnamed_addr #3 align 2 {
  %6 = alloca %"class.JPH::Vec3", align 16
  %7 = alloca ptr, align 8
  %8 = alloca ptr, align 8
  %9 = alloca %"class.JPH::Vec3", align 16
  %10 = alloca %"class.JPH::Vec3", align 16
  %11 = alloca ptr, align 8
  %12 = alloca ptr, align 8
  %13 = alloca ptr, align 8
  %14 = alloca ptr, align 8
  %15 = alloca %"class.JPH::Mat44", align 16
  %16 = alloca %"class.JPH::Mat44", align 16
  %17 = alloca %"class.JPH::Vec3", align 16
  %18 = alloca %"class.JPH::AABox", align 16
  %19 = alloca %"class.JPH::Vec3", align 16
  %20 = alloca %"class.JPH::Vec3", align 16
  %21 = alloca %"class.JPH::Vec3", align 16
  %22 = getelementptr inbounds { double, double }, ptr %6, i32 0, i32 0
  store double %3, ptr %22, align 16
  %23 = getelementptr inbounds { double, double }, ptr %6, i32 0, i32 1
  store double %4, ptr %23, align 8
  store ptr %1, ptr %7, align 8, !tbaa !5
  store ptr %2, ptr %8, align 8, !tbaa !5
  %24 = load ptr, ptr %7, align 8
  %25 = getelementptr inbounds %"class.JPH::CompoundShape", ptr %24, i32 0, i32 4
  %26 = call noundef zeroext i1 @_ZNK3JPH5ArrayINS_13CompoundShape8SubShapeENS_12STLAllocatorIS2_EEE5emptyEv(ptr noundef nonnull align 8 dereferenceable(24) %25)
  br i1 %26, label %27, label %52

27:                                               ; preds = %5
  %28 = load ptr, ptr %8, align 8, !tbaa !5
  %29 = call { double, double } @_ZNK3JPH5Mat4414GetTranslationEv(ptr noundef nonnull align 16 dereferenceable(64) %28)
  %30 = getelementptr inbounds %"class.JPH::Vec3", ptr %9, i32 0, i32 0
  %31 = getelementptr inbounds %union.anon.7, ptr %30, i32 0, i32 0
  %32 = getelementptr inbounds { double, double }, ptr %31, i32 0, i32 0
  %33 = extractvalue { double, double } %29, 0
  store double %33, ptr %32, align 16
  %34 = getelementptr inbounds { double, double }, ptr %31, i32 0, i32 1
  %35 = extractvalue { double, double } %29, 1
  store double %35, ptr %34, align 8
  %36 = load ptr, ptr %8, align 8, !tbaa !5
  %37 = call { double, double } @_ZNK3JPH5Mat4414GetTranslationEv(ptr noundef nonnull align 16 dereferenceable(64) %36)
  %38 = getelementptr inbounds %"class.JPH::Vec3", ptr %10, i32 0, i32 0
  %39 = getelementptr inbounds %union.anon.7, ptr %38, i32 0, i32 0
  %40 = getelementptr inbounds { double, double }, ptr %39, i32 0, i32 0
  %41 = extractvalue { double, double } %37, 0
  store double %41, ptr %40, align 16
  %42 = getelementptr inbounds { double, double }, ptr %39, i32 0, i32 1
  %43 = extractvalue { double, double } %37, 1
  store double %43, ptr %42, align 8
  %44 = getelementptr inbounds { double, double }, ptr %9, i32 0, i32 0
  %45 = load double, ptr %44, align 16
  %46 = getelementptr inbounds { double, double }, ptr %9, i32 0, i32 1
  %47 = load double, ptr %46, align 8
  %48 = getelementptr inbounds { double, double }, ptr %10, i32 0, i32 0
  %49 = load double, ptr %48, align 16
  %50 = getelementptr inbounds { double, double }, ptr %10, i32 0, i32 1
  %51 = load double, ptr %50, align 8
  call void @_ZN3JPH5AABoxC2ENS_4Vec3ES1_(ptr noundef nonnull align 16 dereferenceable(32) %0, double %45, double %47, double %49, double %51)
  br label %107

52:                                               ; preds = %5
  %53 = getelementptr inbounds %"class.JPH::CompoundShape", ptr %24, i32 0, i32 4
  %54 = call noundef i64 @_ZNK3JPH5ArrayINS_13CompoundShape8SubShapeENS_12STLAllocatorIS2_EEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %53)
  %55 = icmp ule i64 %54, 10
  br i1 %55, label %56, label %101

56:                                               ; preds = %52
  call void @_ZN3JPH5AABoxC2Ev(ptr noundef nonnull align 16 dereferenceable(32) %0)
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #8
  %57 = getelementptr inbounds %"class.JPH::CompoundShape", ptr %24, i32 0, i32 4
  store ptr %57, ptr %11, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #8
  %58 = load ptr, ptr %11, align 8, !tbaa !5
  %59 = call noundef ptr @_ZNK3JPH5ArrayINS_13CompoundShape8SubShapeENS_12STLAllocatorIS2_EEE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %58)
  store ptr %59, ptr %12, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #8
  %60 = load ptr, ptr %11, align 8, !tbaa !5
  %61 = call noundef ptr @_ZNK3JPH5ArrayINS_13CompoundShape8SubShapeENS_12STLAllocatorIS2_EEE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %60)
  store ptr %61, ptr %13, align 8, !tbaa !5
  br label %62

62:                                               ; preds = %97, %56
  %63 = load ptr, ptr %12, align 8, !tbaa !5
  %64 = load ptr, ptr %13, align 8, !tbaa !5
  %65 = icmp ne ptr %63, %64
  br i1 %65, label %67, label %66

66:                                               ; preds = %62
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #8
  br label %100

67:                                               ; preds = %62
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #8
  %68 = load ptr, ptr %12, align 8, !tbaa !5
  store ptr %68, ptr %14, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 64, ptr %15) #8
  %69 = load ptr, ptr %8, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 64, ptr %16) #8
  %70 = load ptr, ptr %14, align 8, !tbaa !5
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 %17, ptr align 16 %6, i64 16, i1 false), !tbaa.struct !9
  %71 = getelementptr inbounds { double, double }, ptr %17, i32 0, i32 0
  %72 = load double, ptr %71, align 16
  %73 = getelementptr inbounds { double, double }, ptr %17, i32 0, i32 1
  %74 = load double, ptr %73, align 8
  call void @_ZNK3JPH13CompoundShape8SubShape24GetLocalTransformNoScaleENS_4Vec3E(ptr dead_on_unwind writable sret(%"class.JPH::Mat44") align 16 %16, ptr noundef nonnull align 8 dereferenceable(37) %70, double %72, double %74)
  call void @_ZNK3JPH5Mat44mlERKS0_(ptr dead_on_unwind writable sret(%"class.JPH::Mat44") align 16 %15, ptr noundef nonnull align 16 dereferenceable(64) %69, ptr noundef nonnull align 16 dereferenceable(64) %16)
  call void @llvm.lifetime.end.p0(i64 64, ptr %16) #8
  call void @llvm.lifetime.start.p0(i64 32, ptr %18) #8
  %75 = load ptr, ptr %14, align 8, !tbaa !5
  %76 = getelementptr inbounds %"struct.JPH::CompoundShape::SubShape", ptr %75, i32 0, i32 0
  %77 = call noundef ptr @_ZNK3JPH8RefConstINS_5ShapeEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %76)
  %78 = load ptr, ptr %14, align 8, !tbaa !5
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 %20, ptr align 16 %6, i64 16, i1 false), !tbaa.struct !9
  %79 = getelementptr inbounds { double, double }, ptr %20, i32 0, i32 0
  %80 = load double, ptr %79, align 16
  %81 = getelementptr inbounds { double, double }, ptr %20, i32 0, i32 1
  %82 = load double, ptr %81, align 8
  %83 = call { double, double } @_ZNK3JPH13CompoundShape8SubShape14TransformScaleENS_4Vec3E(ptr noundef nonnull align 8 dereferenceable(37) %78, double %80, double %82)
  %84 = getelementptr inbounds %"class.JPH::Vec3", ptr %19, i32 0, i32 0
  %85 = getelementptr inbounds %union.anon.7, ptr %84, i32 0, i32 0
  %86 = getelementptr inbounds { double, double }, ptr %85, i32 0, i32 0
  %87 = extractvalue { double, double } %83, 0
  store double %87, ptr %86, align 16
  %88 = getelementptr inbounds { double, double }, ptr %85, i32 0, i32 1
  %89 = extractvalue { double, double } %83, 1
  store double %89, ptr %88, align 8
  %90 = getelementptr inbounds { double, double }, ptr %19, i32 0, i32 0
  %91 = load double, ptr %90, align 16
  %92 = getelementptr inbounds { double, double }, ptr %19, i32 0, i32 1
  %93 = load double, ptr %92, align 8
  %94 = load ptr, ptr %77, align 8, !tbaa !11
  %95 = getelementptr inbounds ptr, ptr %94, i64 6
  %96 = load ptr, ptr %95, align 8
  call void %96(ptr dead_on_unwind writable sret(%"class.JPH::AABox") align 16 %18, ptr noundef nonnull align 8 dereferenceable(26) %77, ptr noundef nonnull align 16 dereferenceable(64) %15, double %91, double %93)
  call void @_ZN3JPH5AABox11EncapsulateERKS0_(ptr noundef nonnull align 16 dereferenceable(32) %0, ptr noundef nonnull align 16 dereferenceable(32) %18)
  call void @llvm.lifetime.end.p0(i64 32, ptr %18) #8
  call void @llvm.lifetime.end.p0(i64 64, ptr %15) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #8
  br label %97

97:                                               ; preds = %67
  %98 = load ptr, ptr %12, align 8, !tbaa !5
  %99 = getelementptr inbounds %"struct.JPH::CompoundShape::SubShape", ptr %98, i32 1
  store ptr %99, ptr %12, align 8, !tbaa !5
  br label %62

100:                                              ; preds = %66
  br label %107

101:                                              ; preds = %52
  %102 = load ptr, ptr %8, align 8, !tbaa !5
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 %21, ptr align 16 %6, i64 16, i1 false), !tbaa.struct !9
  %103 = getelementptr inbounds { double, double }, ptr %21, i32 0, i32 0
  %104 = load double, ptr %103, align 16
  %105 = getelementptr inbounds { double, double }, ptr %21, i32 0, i32 1
  %106 = load double, ptr %105, align 8
  call void @_ZNK3JPH5Shape19GetWorldSpaceBoundsERKNS_5Mat44ENS_4Vec3E(ptr dead_on_unwind writable sret(%"class.JPH::AABox") align 16 %0, ptr noundef nonnull align 8 dereferenceable(26) %24, ptr noundef nonnull align 16 dereferenceable(64) %102, double %104, double %106)
  br label %107

107:                                              ; preds = %101, %100, %27
  ret void
}

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN3JPH5AABoxC2ENS_4Vec3ES1_(ptr noundef nonnull align 16 dereferenceable(32), double, double, double, double) unnamed_addr #5 align 2

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN3JPH5AABoxC2Ev(ptr noundef nonnull align 16 dereferenceable(32)) unnamed_addr #3 align 2

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

; Function Attrs: alwaysinline mustprogress uwtable
declare dso_local void @_ZNK3JPH13CompoundShape8SubShape24GetLocalTransformNoScaleENS_4Vec3E(ptr dead_on_unwind noalias writable sret(%"class.JPH::Mat44") align 16, ptr noundef nonnull align 8 dereferenceable(37), double, double) #4 align 2

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

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local { double, double } @_ZNK3JPH13CompoundShape8SubShape14TransformScaleENS_4Vec3E(ptr noundef nonnull align 8 dereferenceable(37), double, double) #7 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNK3JPH5Shape19GetWorldSpaceBoundsERKNS_5Mat44ENS_4Vec3E(ptr dead_on_unwind noalias writable sret(%"class.JPH::AABox") align 16, ptr noundef nonnull align 8 dereferenceable(26), ptr noundef nonnull align 16 dereferenceable(64), double, double) unnamed_addr #3 align 2

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { 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 #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 = { alwaysinline 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 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 = { 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 #7 = { 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 #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 16, !10}
!10 = !{!7, !7, i64 0}
!11 = !{!12, !12, i64 0}
!12 = !{!"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"

%"class.JPH::AABox" = type { %"class.JPH::Vec3", %"class.JPH::Vec3" }
%"class.JPH::Vec3" = type { %union.anon.7 }
%union.anon.7 = type { <4 x float> }
%"class.JPH::Mat44" = type { [4 x %"class.JPH::Vec4"] }
%"class.JPH::Vec4" = type { %union.anon.8 }
%union.anon.8 = type { <4 x float> }

; 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 ptr @_ZNK3JPH5ArrayINS_13CompoundShape8SubShapeENS_12STLAllocatorIS2_EEE5beginEv(ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #1 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef ptr @_ZNK3JPH5ArrayINS_13CompoundShape8SubShapeENS_12STLAllocatorIS2_EEE3endEv(ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #1 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 @_ZNK3JPH13CompoundShape19GetWorldSpaceBoundsERKNS_5Mat44ENS_4Vec3E(ptr dead_on_unwind noalias writable sret(%"class.JPH::AABox") align 16 %0, ptr noundef nonnull align 16 dereferenceable(108) %1, ptr noundef nonnull align 16 dereferenceable(64) %2, double %3, double %4) unnamed_addr #2 align 2 {
  %6 = alloca %"class.JPH::Mat44", align 16
  %7 = alloca %"class.JPH::Mat44", align 16
  %8 = alloca %"class.JPH::AABox", align 16
  %9 = getelementptr inbounds i8, ptr %1, i64 80
  %10 = tail call noundef zeroext i1 @_ZNK3JPH5ArrayINS_13CompoundShape8SubShapeENS_12STLAllocatorIS2_EEE5emptyEv(ptr noundef nonnull align 8 dereferenceable(24) %9)
  br i1 %10, label %11, label %18

11:                                               ; preds = %5
  %12 = tail call { double, double } @_ZNK3JPH5Mat4414GetTranslationEv(ptr noundef nonnull align 16 dereferenceable(64) %2)
  %13 = extractvalue { double, double } %12, 0
  %14 = extractvalue { double, double } %12, 1
  %15 = tail call { double, double } @_ZNK3JPH5Mat4414GetTranslationEv(ptr noundef nonnull align 16 dereferenceable(64) %2)
  %16 = extractvalue { double, double } %15, 0
  %17 = extractvalue { double, double } %15, 1
  tail call void @_ZN3JPH5AABoxC2ENS_4Vec3ES1_(ptr noundef nonnull align 16 dereferenceable(32) %0, double %13, double %14, double %16, double %17)
  br label %.loopexit

18:                                               ; preds = %5
  %19 = tail call noundef i64 @_ZNK3JPH5ArrayINS_13CompoundShape8SubShapeENS_12STLAllocatorIS2_EEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %9)
  %20 = icmp ult i64 %19, 11
  br i1 %20, label %21, label %32

21:                                               ; preds = %18
  tail call void @_ZN3JPH5AABoxC2Ev(ptr noundef nonnull align 16 dereferenceable(32) %0)
  %22 = tail call noundef ptr @_ZNK3JPH5ArrayINS_13CompoundShape8SubShapeENS_12STLAllocatorIS2_EEE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %9)
  %23 = tail call noundef ptr @_ZNK3JPH5ArrayINS_13CompoundShape8SubShapeENS_12STLAllocatorIS2_EEE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %9)
  %.not25 = icmp eq ptr %22, %23
  br i1 %.not25, label %.loopexit, label %.lr.ph

.lr.ph:                                           ; preds = %21, %.lr.ph
  %.026 = phi ptr [ %31, %.lr.ph ], [ %22, %21 ]
  call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %6) #7
  call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %7) #7
  call void @_ZNK3JPH13CompoundShape8SubShape24GetLocalTransformNoScaleENS_4Vec3E(ptr dead_on_unwind nonnull writable sret(%"class.JPH::Mat44") align 16 %7, ptr noundef nonnull align 8 dereferenceable(37) %.026, double %3, double %4)
  call void @_ZNK3JPH5Mat44mlERKS0_(ptr dead_on_unwind nonnull writable sret(%"class.JPH::Mat44") align 16 %6, ptr noundef nonnull align 16 dereferenceable(64) %2, ptr noundef nonnull align 16 dereferenceable(64) %7)
  call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %7) #7
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %8) #7
  %24 = call noundef ptr @_ZNK3JPH8RefConstINS_5ShapeEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %.026)
  %25 = call { double, double } @_ZNK3JPH13CompoundShape8SubShape14TransformScaleENS_4Vec3E(ptr noundef nonnull align 8 dereferenceable(37) %.026, double %3, double %4)
  %26 = extractvalue { double, double } %25, 0
  %27 = extractvalue { double, double } %25, 1
  %28 = load ptr, ptr %24, align 8, !tbaa !5
  %29 = getelementptr inbounds i8, ptr %28, i64 48
  %30 = load ptr, ptr %29, align 8
  call void %30(ptr dead_on_unwind nonnull writable sret(%"class.JPH::AABox") align 16 %8, ptr noundef nonnull align 8 dereferenceable(26) %24, ptr noundef nonnull align 16 dereferenceable(64) %6, double %26, double %27)
  call void @_ZN3JPH5AABox11EncapsulateERKS0_(ptr noundef nonnull align 16 dereferenceable(32) %0, ptr noundef nonnull align 16 dereferenceable(32) %8)
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %8) #7
  call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %6) #7
  %31 = getelementptr inbounds i8, ptr %.026, i64 40
  %.not = icmp eq ptr %31, %23
  br i1 %.not, label %.loopexit, label %.lr.ph

32:                                               ; preds = %18
  tail call void @_ZNK3JPH5Shape19GetWorldSpaceBoundsERKNS_5Mat44ENS_4Vec3E(ptr dead_on_unwind writable sret(%"class.JPH::AABox") align 16 %0, ptr noundef nonnull align 8 dereferenceable(26) %1, ptr noundef nonnull align 16 dereferenceable(64) %2, double %3, double %4)
  br label %.loopexit

.loopexit:                                        ; preds = %.lr.ph, %21, %32, %11
  ret void
}

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN3JPH5AABoxC2ENS_4Vec3ES1_(ptr noundef nonnull align 16 dereferenceable(32), double, double, double, double) unnamed_addr #4 align 2

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN3JPH5AABoxC2Ev(ptr noundef nonnull align 16 dereferenceable(32)) unnamed_addr #2 align 2

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN3JPH5AABox11EncapsulateERKS0_(ptr noundef nonnull align 16 dereferenceable(32), ptr noundef nonnull align 16 dereferenceable(32)) local_unnamed_addr #2 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local { double, double } @_ZNK3JPH13CompoundShape8SubShape14TransformScaleENS_4Vec3E(ptr noundef nonnull align 8 dereferenceable(37), double, double) local_unnamed_addr #6 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNK3JPH5Shape19GetWorldSpaceBoundsERKNS_5Mat44ENS_4Vec3E(ptr dead_on_unwind noalias writable sret(%"class.JPH::AABox") align 16, ptr noundef nonnull align 8 dereferenceable(26), ptr noundef nonnull align 16 dereferenceable(64), double, double) unnamed_addr #2 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 = { alwaysinline 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 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 #5 = { 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 #6 = { 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 #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 = !{!"vtable pointer", !7, i64 0}
!7 = !{!"Simple C++ TBAA"}


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