; LLVM IR from zig-gamedev/zphysics :: libs/Jolt/Physics/Collision/Shape (CapsuleShape)

; 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::Vec3" = type { %union.anon.12 }
%union.anon.12 = type { <4 x float> }
%"struct.JPH::AssertLastParam" = type { i8 }
%"class.JPH::Mat44" = type { [4 x %"class.JPH::Vec4"] }
%"class.JPH::Vec4" = type { %union.anon.14 }
%union.anon.14 = type { <4 x float> }
%"class.JPH::Plane" = type { %"class.JPH::Vec4" }
%"class.JPH::CapsuleShape" = type { %"class.JPH::ConvexShape.base", float, float, [4 x i8] }
%"class.JPH::ConvexShape.base" = type <{ %"class.JPH::Shape.base", [6 x i8], %"class.JPH::RefConst", float }>
%"class.JPH::Shape.base" = type <{ ptr, %"class.JPH::RefTarget.11", [4 x i8], i64, i8, i8 }>
%"class.JPH::RefTarget.11" = type { %"struct.std::atomic" }
%"struct.std::atomic" = type { %"struct.std::__atomic_base" }
%"struct.std::__atomic_base" = type { i32 }
%"class.JPH::RefConst" = type { ptr }
%"class.JPH::SoftBodyVertex" = type { %"class.JPH::Vec3", %"class.JPH::Vec3", %"class.JPH::Vec3", %"class.JPH::Plane", i32, i8, float, float }

@.str.6 = external hidden unnamed_addr constant [22 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [105 x i8], align 1

; 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: mustprogress uwtable
declare dso_local noundef zeroext i1 @_ZNK3JPH12CapsuleShape12IsValidScaleENS_4Vec3E(ptr noundef nonnull align 8 dereferenceable(56), double, double) unnamed_addr #1 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) #2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef zeroext i1 @_ZN3JPH23AssertFailedParamHelperEPKcS1_jNS_15AssertLastParamE(ptr noundef, ptr noundef, i32 noundef) #3

; Function Attrs: alwaysinline mustprogress nounwind uwtable
declare dso_local noundef float @_ZNK3JPH4Vec34GetXEv(ptr noundef nonnull align 16 dereferenceable(16)) #4 align 2

; Function Attrs: alwaysinline mustprogress uwtable
declare dso_local void @_ZN3JPH4Vec3C2Efff(ptr noundef nonnull align 16 dereferenceable(16), float noundef, float noundef, float noundef) unnamed_addr #5 align 2

; Function Attrs: alwaysinline mustprogress uwtable
declare dso_local noundef float @_ZNK3JPH4Vec36LengthEv(ptr noundef nonnull align 16 dereferenceable(16)) #6 align 2

; Function Attrs: alwaysinline mustprogress uwtable
declare dso_local { double, double } @_ZN3JPHmlEfNS_4Vec3E(float noundef, double, double) #5

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef float @_ZSt3absf(float noundef) #7

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

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

; Function Attrs: alwaysinline mustprogress uwtable
declare dso_local { double, double } @_ZN3JPH4Vec36sAxisXEv() #6 align 2

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZNK3JPH12CapsuleShape23CollideSoftBodyVerticesERKNS_5Mat44ENS_4Vec3EPNS_14SoftBodyVertexEjfS4_i(ptr noundef nonnull align 8 dereferenceable(56) %0, ptr noundef nonnull align 16 dereferenceable(64) %1, double %2, double %3, ptr noundef %4, i32 noundef %5, float noundef %6, double %7, double %8, i32 noundef %9) unnamed_addr #1 align 2 {
  %11 = alloca %"class.JPH::Vec3", align 16
  %12 = alloca %"class.JPH::Vec3", align 16
  %13 = alloca ptr, align 8
  %14 = alloca ptr, align 8
  %15 = alloca ptr, align 8
  %16 = alloca i32, align 4
  %17 = alloca float, align 4
  %18 = alloca i32, align 4
  %19 = alloca %"class.JPH::Vec3", align 16
  %20 = alloca %"struct.JPH::AssertLastParam", align 1
  %21 = alloca %"class.JPH::Mat44", align 16
  %22 = alloca float, align 4
  %23 = alloca float, align 4
  %24 = alloca float, align 4
  %25 = alloca ptr, align 8
  %26 = alloca ptr, align 8
  %27 = alloca %"class.JPH::Vec3", align 16
  %28 = alloca %"class.JPH::Vec3", align 16
  %29 = alloca %"class.JPH::Vec3", align 16
  %30 = alloca float, align 4
  %31 = alloca float, align 4
  %32 = alloca %"class.JPH::Vec3", align 16
  %33 = alloca %"class.JPH::Vec3", align 16
  %34 = alloca %"class.JPH::Vec3", align 16
  %35 = alloca %"class.JPH::Plane", align 16
  %36 = alloca %"class.JPH::Plane", align 16
  %37 = alloca %"class.JPH::Vec3", align 16
  %38 = alloca %"class.JPH::Vec3", align 16
  %39 = alloca %"class.JPH::Vec3", align 16
  %40 = alloca %"class.JPH::Vec3", align 16
  %41 = alloca %"class.JPH::Vec3", align 16
  %42 = alloca float, align 4
  %43 = alloca float, align 4
  %44 = alloca %"class.JPH::Vec3", align 16
  %45 = alloca %"class.JPH::Vec3", align 16
  %46 = alloca %"class.JPH::Vec3", align 16
  %47 = alloca %"class.JPH::Vec3", align 16
  %48 = alloca %"class.JPH::Plane", align 16
  %49 = alloca %"class.JPH::Plane", align 16
  %50 = alloca %"class.JPH::Vec3", align 16
  %51 = alloca %"class.JPH::Vec3", align 16
  %52 = getelementptr inbounds { double, double }, ptr %11, i32 0, i32 0
  store double %2, ptr %52, align 16
  %53 = getelementptr inbounds { double, double }, ptr %11, i32 0, i32 1
  store double %3, ptr %53, align 8
  %54 = getelementptr inbounds { double, double }, ptr %12, i32 0, i32 0
  store double %7, ptr %54, align 16
  %55 = getelementptr inbounds { double, double }, ptr %12, i32 0, i32 1
  store double %8, ptr %55, align 8
  store ptr %0, ptr %13, align 8, !tbaa !5
  store ptr %1, ptr %14, align 8, !tbaa !5
  store ptr %4, ptr %15, align 8, !tbaa !5
  store i32 %5, ptr %16, align 4, !tbaa !9
  store float %6, ptr %17, align 4, !tbaa !11
  store i32 %9, ptr %18, align 4, !tbaa !9
  %56 = load ptr, ptr %13, align 8
  br label %57

57:                                               ; preds = %10
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 %19, ptr align 16 %11, i64 16, i1 false), !tbaa.struct !13
  %58 = getelementptr inbounds { double, double }, ptr %19, i32 0, i32 0
  %59 = load double, ptr %58, align 16
  %60 = getelementptr inbounds { double, double }, ptr %19, i32 0, i32 1
  %61 = load double, ptr %60, align 8
  %62 = call noundef zeroext i1 @_ZNK3JPH12CapsuleShape12IsValidScaleENS_4Vec3E(ptr noundef nonnull align 8 dereferenceable(56) %56, double %59, double %61)
  br i1 %62, label %66, label %63

63:                                               ; preds = %57
  %64 = call noundef zeroext i1 @_ZN3JPH23AssertFailedParamHelperEPKcS1_jNS_15AssertLastParamE(ptr noundef @.str.6, ptr noundef @.str.7, i32 noundef 326)
  br i1 %64, label %65, label %66

65:                                               ; preds = %63
  call void asm sideeffect "int $$0x3", "~{dirflag},~{fpsr},~{flags}"() #9, !srcloc !15
  br label %66

66:                                               ; preds = %65, %63, %57
  br label %67

67:                                               ; preds = %66
  call void @llvm.lifetime.start.p0(i64 64, ptr %21) #9
  %68 = load ptr, ptr %14, align 8, !tbaa !5
  call void @_ZNK3JPH5Mat4427InversedRotationTranslationEv(ptr dead_on_unwind writable sret(%"class.JPH::Mat44") align 16 %21, ptr noundef nonnull align 16 dereferenceable(64) %68)
  call void @llvm.lifetime.start.p0(i64 4, ptr %22) #9
  %69 = call noundef float @_ZNK3JPH4Vec34GetXEv(ptr noundef nonnull align 16 dereferenceable(16) %11)
  %70 = call noundef float @_ZSt3absf(float noundef %69)
  store float %70, ptr %22, align 4, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 4, ptr %23) #9
  %71 = load float, ptr %22, align 4, !tbaa !11
  %72 = getelementptr inbounds %"class.JPH::CapsuleShape", ptr %56, i32 0, i32 2
  %73 = load float, ptr %72, align 8, !tbaa !16
  %74 = fmul float %71, %73
  store float %74, ptr %23, align 4, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 4, ptr %24) #9
  %75 = load float, ptr %22, align 4, !tbaa !11
  %76 = getelementptr inbounds %"class.JPH::CapsuleShape", ptr %56, i32 0, i32 1
  %77 = load float, ptr %76, align 4, !tbaa !27
  %78 = fmul float %75, %77
  store float %78, ptr %24, align 4, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 8, ptr %25) #9
  %79 = load ptr, ptr %15, align 8, !tbaa !5
  store ptr %79, ptr %25, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %26) #9
  %80 = load ptr, ptr %15, align 8, !tbaa !5
  %81 = load i32, ptr %16, align 4, !tbaa !9
  %82 = zext i32 %81 to i64
  %83 = getelementptr inbounds %"class.JPH::SoftBodyVertex", ptr %80, i64 %82
  store ptr %83, ptr %26, align 8, !tbaa !5
  br label %84

84:                                               ; preds = %282, %67
  %85 = load ptr, ptr %25, align 8, !tbaa !5
  %86 = load ptr, ptr %26, align 8, !tbaa !5
  %87 = icmp ult ptr %85, %86
  br i1 %87, label %89, label %88

88:                                               ; preds = %84
  call void @llvm.lifetime.end.p0(i64 8, ptr %26) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %25) #9
  br label %285

89:                                               ; preds = %84
  %90 = load ptr, ptr %25, align 8, !tbaa !5
  %91 = getelementptr inbounds %"class.JPH::SoftBodyVertex", ptr %90, i32 0, i32 7
  %92 = load float, ptr %91, align 4, !tbaa !28
  %93 = fcmp ogt float %92, 0.000000e+00
  br i1 %93, label %94, label %281

94:                                               ; preds = %89
  call void @llvm.lifetime.start.p0(i64 16, ptr %27) #9
  %95 = load ptr, ptr %25, align 8, !tbaa !5
  %96 = getelementptr inbounds %"class.JPH::SoftBodyVertex", ptr %95, i32 0, i32 1
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 %28, ptr align 16 %96, i64 16, i1 false), !tbaa.struct !13
  %97 = getelementptr inbounds { double, double }, ptr %28, i32 0, i32 0
  %98 = load double, ptr %97, align 16
  %99 = getelementptr inbounds { double, double }, ptr %28, i32 0, i32 1
  %100 = load double, ptr %99, align 8
  %101 = call { double, double } @_ZNK3JPH5Mat44mlENS_4Vec3E(ptr noundef nonnull align 16 dereferenceable(64) %21, double %98, double %100)
  %102 = getelementptr inbounds %"class.JPH::Vec3", ptr %27, i32 0, i32 0
  %103 = getelementptr inbounds %union.anon.12, ptr %102, i32 0, i32 0
  %104 = getelementptr inbounds { double, double }, ptr %103, i32 0, i32 0
  %105 = extractvalue { double, double } %101, 0
  store double %105, ptr %104, align 16
  %106 = getelementptr inbounds { double, double }, ptr %103, i32 0, i32 1
  %107 = extractvalue { double, double } %101, 1
  store double %107, ptr %106, align 8
  %108 = call noundef float @_ZNK3JPH4Vec34GetYEv(ptr noundef nonnull align 16 dereferenceable(16) %27)
  %109 = call noundef float @_ZSt3absf(float noundef %108)
  %110 = load float, ptr %23, align 4, !tbaa !11
  %111 = fcmp ole float %109, %110
  br i1 %111, label %112, label %189

112:                                              ; preds = %94
  call void @llvm.lifetime.start.p0(i64 16, ptr %29) #9
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 %29, ptr align 16 %27, i64 16, i1 false), !tbaa.struct !13
  call void @_ZN3JPH4Vec34SetYEf(ptr noundef nonnull align 16 dereferenceable(16) %29, float noundef 0.000000e+00)
  call void @llvm.lifetime.start.p0(i64 4, ptr %30) #9
  %113 = call noundef float @_ZNK3JPH4Vec36LengthEv(ptr noundef nonnull align 16 dereferenceable(16) %29)
  store float %113, ptr %30, align 4, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 4, ptr %31) #9
  %114 = load float, ptr %24, align 4, !tbaa !11
  %115 = load float, ptr %30, align 4, !tbaa !11
  %116 = fsub float %114, %115
  store float %116, ptr %31, align 4, !tbaa !11
  %117 = load float, ptr %31, align 4, !tbaa !11
  %118 = load ptr, ptr %25, align 8, !tbaa !5
  %119 = getelementptr inbounds %"class.JPH::SoftBodyVertex", ptr %118, i32 0, i32 6
  %120 = load float, ptr %119, align 8, !tbaa !34
  %121 = fcmp ogt float %117, %120
  br i1 %121, label %122, label %188

122:                                              ; preds = %112
  %123 = load float, ptr %31, align 4, !tbaa !11
  %124 = load ptr, ptr %25, align 8, !tbaa !5
  %125 = getelementptr inbounds %"class.JPH::SoftBodyVertex", ptr %124, i32 0, i32 6
  store float %123, ptr %125, align 8, !tbaa !34
  call void @llvm.lifetime.start.p0(i64 16, ptr %32) #9
  %126 = load float, ptr %30, align 4, !tbaa !11
  %127 = fcmp ogt float %126, 0.000000e+00
  br i1 %127, label %128, label %137

128:                                              ; preds = %122
  %129 = load float, ptr %30, align 4, !tbaa !11
  %130 = call { double, double } @_ZNK3JPH4Vec3dvEf(ptr noundef nonnull align 16 dereferenceable(16) %29, float noundef %129)
  %131 = getelementptr inbounds %"class.JPH::Vec3", ptr %32, i32 0, i32 0
  %132 = getelementptr inbounds %union.anon.12, ptr %131, i32 0, i32 0
  %133 = getelementptr inbounds { double, double }, ptr %132, i32 0, i32 0
  %134 = extractvalue { double, double } %130, 0
  store double %134, ptr %133, align 16
  %135 = getelementptr inbounds { double, double }, ptr %132, i32 0, i32 1
  %136 = extractvalue { double, double } %130, 1
  store double %136, ptr %135, align 8
  br label %145

137:                                              ; preds = %122
  %138 = call { double, double } @_ZN3JPH4Vec36sAxisXEv()
  %139 = getelementptr inbounds %"class.JPH::Vec3", ptr %32, i32 0, i32 0
  %140 = getelementptr inbounds %union.anon.12, ptr %139, i32 0, i32 0
  %141 = getelementptr inbounds { double, double }, ptr %140, i32 0, i32 0
  %142 = extractvalue { double, double } %138, 0
  store double %142, ptr %141, align 16
  %143 = getelementptr inbounds { double, double }, ptr %140, i32 0, i32 1
  %144 = extractvalue { double, double } %138, 1
  store double %144, ptr %143, align 8
  br label %145

145:                                              ; preds = %137, %128
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 %29, ptr align 16 %32, i64 16, i1 false), !tbaa.struct !13
  call void @llvm.lifetime.end.p0(i64 16, ptr %32) #9
  call void @llvm.lifetime.start.p0(i64 16, ptr %33) #9
  %146 = load float, ptr %24, align 4, !tbaa !11
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 %34, ptr align 16 %29, i64 16, i1 false), !tbaa.struct !13
  %147 = getelementptr inbounds { double, double }, ptr %34, i32 0, i32 0
  %148 = load double, ptr %147, align 16
  %149 = getelementptr inbounds { double, double }, ptr %34, i32 0, i32 1
  %150 = load double, ptr %149, align 8
  %151 = call { double, double } @_ZN3JPHmlEfNS_4Vec3E(float noundef %146, double %148, double %150)
  %152 = getelementptr inbounds %"class.JPH::Vec3", ptr %33, i32 0, i32 0
  %153 = getelementptr inbounds %union.anon.12, ptr %152, i32 0, i32 0
  %154 = getelementptr inbounds { double, double }, ptr %153, i32 0, i32 0
  %155 = extractvalue { double, double } %151, 0
  store double %155, ptr %154, align 16
  %156 = getelementptr inbounds { double, double }, ptr %153, i32 0, i32 1
  %157 = extractvalue { double, double } %151, 1
  store double %157, ptr %156, align 8
  call void @llvm.lifetime.start.p0(i64 16, ptr %35) #9
  call void @llvm.lifetime.start.p0(i64 16, ptr %36) #9
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 %37, ptr align 16 %33, i64 16, i1 false), !tbaa.struct !13
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 %38, ptr align 16 %29, i64 16, i1 false), !tbaa.struct !13
  %158 = getelementptr inbounds { double, double }, ptr %37, i32 0, i32 0
  %159 = load double, ptr %158, align 16
  %160 = getelementptr inbounds { double, double }, ptr %37, i32 0, i32 1
  %161 = load double, ptr %160, align 8
  %162 = getelementptr inbounds { double, double }, ptr %38, i32 0, i32 0
  %163 = load double, ptr %162, align 16
  %164 = getelementptr inbounds { double, double }, ptr %38, i32 0, i32 1
  %165 = load double, ptr %164, align 8
  %166 = call { double, double } @_ZN3JPH5Plane19sFromPointAndNormalENS_4Vec3ES1_(double %159, double %161, double %163, double %165)
  %167 = getelementptr inbounds %"class.JPH::Plane", ptr %36, i32 0, i32 0
  %168 = getelementptr inbounds %"class.JPH::Vec4", ptr %167, i32 0, i32 0
  %169 = getelementptr inbounds %union.anon.14, ptr %168, i32 0, i32 0
  %170 = getelementptr inbounds { double, double }, ptr %169, i32 0, i32 0
  %171 = extractvalue { double, double } %166, 0
  store double %171, ptr %170, align 16
  %172 = getelementptr inbounds { double, double }, ptr %169, i32 0, i32 1
  %173 = extractvalue { double, double } %166, 1
  store double %173, ptr %172, align 8
  %174 = load ptr, ptr %14, align 8, !tbaa !5
  %175 = call { double, double } @_ZNK3JPH5Plane14GetTransformedERKNS_5Mat44E(ptr noundef nonnull align 16 dereferenceable(16) %36, ptr noundef nonnull align 16 dereferenceable(64) %174)
  %176 = getelementptr inbounds %"class.JPH::Plane", ptr %35, i32 0, i32 0
  %177 = getelementptr inbounds %"class.JPH::Vec4", ptr %176, i32 0, i32 0
  %178 = getelementptr inbounds %union.anon.14, ptr %177, i32 0, i32 0
  %179 = getelementptr inbounds { double, double }, ptr %178, i32 0, i32 0
  %180 = extractvalue { double, double } %175, 0
  store double %180, ptr %179, align 16
  %181 = getelementptr inbounds { double, double }, ptr %178, i32 0, i32 1
  %182 = extractvalue { double, double } %175, 1
  store double %182, ptr %181, align 8
  %183 = load ptr, ptr %25, align 8, !tbaa !5
  %184 = getelementptr inbounds %"class.JPH::SoftBodyVertex", ptr %183, i32 0, i32 3
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 %184, ptr align 16 %35, i64 16, i1 false), !tbaa.struct !13
  call void @llvm.lifetime.end.p0(i64 16, ptr %36) #9
  call void @llvm.lifetime.end.p0(i64 16, ptr %35) #9
  %185 = load i32, ptr %18, align 4, !tbaa !9
  %186 = load ptr, ptr %25, align 8, !tbaa !5
  %187 = getelementptr inbounds %"class.JPH::SoftBodyVertex", ptr %186, i32 0, i32 4
  store i32 %185, ptr %187, align 16, !tbaa !35
  call void @llvm.lifetime.end.p0(i64 16, ptr %33) #9
  br label %188

188:                                              ; preds = %145, %112
  call void @llvm.lifetime.end.p0(i64 4, ptr %31) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %30) #9
  call void @llvm.lifetime.end.p0(i64 16, ptr %29) #9
  br label %280

189:                                              ; preds = %94
  call void @llvm.lifetime.start.p0(i64 16, ptr %39) #9
  %190 = call noundef float @_ZNK3JPH4Vec34GetYEv(ptr noundef nonnull align 16 dereferenceable(16) %27)
  %191 = call noundef float @_ZN3JPH4SignIfEET_S1_(float noundef %190)
  %192 = load float, ptr %23, align 4, !tbaa !11
  %193 = fmul float %191, %192
  call void @_ZN3JPH4Vec3C2Efff(ptr noundef nonnull align 16 dereferenceable(16) %39, float noundef 0.000000e+00, float noundef %193, float noundef 0.000000e+00)
  call void @llvm.lifetime.start.p0(i64 16, ptr %40) #9
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 %41, ptr align 16 %39, i64 16, i1 false), !tbaa.struct !13
  %194 = getelementptr inbounds { double, double }, ptr %41, i32 0, i32 0
  %195 = load double, ptr %194, align 16
  %196 = getelementptr inbounds { double, double }, ptr %41, i32 0, i32 1
  %197 = load double, ptr %196, align 8
  %198 = call { double, double } @_ZNK3JPH4Vec3miES0_(ptr noundef nonnull align 16 dereferenceable(16) %27, double %195, double %197)
  %199 = getelementptr inbounds %"class.JPH::Vec3", ptr %40, i32 0, i32 0
  %200 = getelementptr inbounds %union.anon.12, ptr %199, i32 0, i32 0
  %201 = getelementptr inbounds { double, double }, ptr %200, i32 0, i32 0
  %202 = extractvalue { double, double } %198, 0
  store double %202, ptr %201, align 16
  %203 = getelementptr inbounds { double, double }, ptr %200, i32 0, i32 1
  %204 = extractvalue { double, double } %198, 1
  store double %204, ptr %203, align 8
  call void @llvm.lifetime.start.p0(i64 4, ptr %42) #9
  %205 = call noundef float @_ZNK3JPH4Vec36LengthEv(ptr noundef nonnull align 16 dereferenceable(16) %40)
  store float %205, ptr %42, align 4, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 4, ptr %43) #9
  %206 = load float, ptr %24, align 4, !tbaa !11
  %207 = load float, ptr %42, align 4, !tbaa !11
  %208 = fsub float %206, %207
  store float %208, ptr %43, align 4, !tbaa !11
  %209 = load float, ptr %43, align 4, !tbaa !11
  %210 = load ptr, ptr %25, align 8, !tbaa !5
  %211 = getelementptr inbounds %"class.JPH::SoftBodyVertex", ptr %210, i32 0, i32 6
  %212 = load float, ptr %211, align 8, !tbaa !34
  %213 = fcmp ogt float %209, %212
  br i1 %213, label %214, label %279

214:                                              ; preds = %189
  %215 = load float, ptr %43, align 4, !tbaa !11
  %216 = load ptr, ptr %25, align 8, !tbaa !5
  %217 = getelementptr inbounds %"class.JPH::SoftBodyVertex", ptr %216, i32 0, i32 6
  store float %215, ptr %217, align 8, !tbaa !34
  call void @llvm.lifetime.start.p0(i64 16, ptr %44) #9
  %218 = load float, ptr %42, align 4, !tbaa !11
  %219 = call { double, double } @_ZNK3JPH4Vec3dvEf(ptr noundef nonnull align 16 dereferenceable(16) %40, float noundef %218)
  %220 = getelementptr inbounds %"class.JPH::Vec3", ptr %44, i32 0, i32 0
  %221 = getelementptr inbounds %union.anon.12, ptr %220, i32 0, i32 0
  %222 = getelementptr inbounds { double, double }, ptr %221, i32 0, i32 0
  %223 = extractvalue { double, double } %219, 0
  store double %223, ptr %222, align 16
  %224 = getelementptr inbounds { double, double }, ptr %221, i32 0, i32 1
  %225 = extractvalue { double, double } %219, 1
  store double %225, ptr %224, align 8
  call void @llvm.lifetime.start.p0(i64 16, ptr %45) #9
  %226 = load float, ptr %24, align 4, !tbaa !11
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 %47, ptr align 16 %44, i64 16, i1 false), !tbaa.struct !13
  %227 = getelementptr inbounds { double, double }, ptr %47, i32 0, i32 0
  %228 = load double, ptr %227, align 16
  %229 = getelementptr inbounds { double, double }, ptr %47, i32 0, i32 1
  %230 = load double, ptr %229, align 8
  %231 = call { double, double } @_ZN3JPHmlEfNS_4Vec3E(float noundef %226, double %228, double %230)
  %232 = getelementptr inbounds %"class.JPH::Vec3", ptr %46, i32 0, i32 0
  %233 = getelementptr inbounds %union.anon.12, ptr %232, i32 0, i32 0
  %234 = getelementptr inbounds { double, double }, ptr %233, i32 0, i32 0
  %235 = extractvalue { double, double } %231, 0
  store double %235, ptr %234, align 16
  %236 = getelementptr inbounds { double, double }, ptr %233, i32 0, i32 1
  %237 = extractvalue { double, double } %231, 1
  store double %237, ptr %236, align 8
  %238 = getelementptr inbounds { double, double }, ptr %46, i32 0, i32 0
  %239 = load double, ptr %238, align 16
  %240 = getelementptr inbounds { double, double }, ptr %46, i32 0, i32 1
  %241 = load double, ptr %240, align 8
  %242 = call { double, double } @_ZNK3JPH4Vec3plES0_(ptr noundef nonnull align 16 dereferenceable(16) %39, double %239, double %241)
  %243 = getelementptr inbounds %"class.JPH::Vec3", ptr %45, i32 0, i32 0
  %244 = getelementptr inbounds %union.anon.12, ptr %243, i32 0, i32 0
  %245 = getelementptr inbounds { double, double }, ptr %244, i32 0, i32 0
  %246 = extractvalue { double, double } %242, 0
  store double %246, ptr %245, align 16
  %247 = getelementptr inbounds { double, double }, ptr %244, i32 0, i32 1
  %248 = extractvalue { double, double } %242, 1
  store double %248, ptr %247, align 8
  call void @llvm.lifetime.start.p0(i64 16, ptr %48) #9
  call void @llvm.lifetime.start.p0(i64 16, ptr %49) #9
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 %50, ptr align 16 %45, i64 16, i1 false), !tbaa.struct !13
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 %51, ptr align 16 %44, i64 16, i1 false), !tbaa.struct !13
  %249 = getelementptr inbounds { double, double }, ptr %50, i32 0, i32 0
  %250 = load double, ptr %249, align 16
  %251 = getelementptr inbounds { double, double }, ptr %50, i32 0, i32 1
  %252 = load double, ptr %251, align 8
  %253 = getelementptr inbounds { double, double }, ptr %51, i32 0, i32 0
  %254 = load double, ptr %253, align 16
  %255 = getelementptr inbounds { double, double }, ptr %51, i32 0, i32 1
  %256 = load double, ptr %255, align 8
  %257 = call { double, double } @_ZN3JPH5Plane19sFromPointAndNormalENS_4Vec3ES1_(double %250, double %252, double %254, double %256)
  %258 = getelementptr inbounds %"class.JPH::Plane", ptr %49, i32 0, i32 0
  %259 = getelementptr inbounds %"class.JPH::Vec4", ptr %258, i32 0, i32 0
  %260 = getelementptr inbounds %union.anon.14, ptr %259, i32 0, i32 0
  %261 = getelementptr inbounds { double, double }, ptr %260, i32 0, i32 0
  %262 = extractvalue { double, double } %257, 0
  store double %262, ptr %261, align 16
  %263 = getelementptr inbounds { double, double }, ptr %260, i32 0, i32 1
  %264 = extractvalue { double, double } %257, 1
  store double %264, ptr %263, align 8
  %265 = load ptr, ptr %14, align 8, !tbaa !5
  %266 = call { double, double } @_ZNK3JPH5Plane14GetTransformedERKNS_5Mat44E(ptr noundef nonnull align 16 dereferenceable(16) %49, ptr noundef nonnull align 16 dereferenceable(64) %265)
  %267 = getelementptr inbounds %"class.JPH::Plane", ptr %48, i32 0, i32 0
  %268 = getelementptr inbounds %"class.JPH::Vec4", ptr %267, i32 0, i32 0
  %269 = getelementptr inbounds %union.anon.14, ptr %268, i32 0, i32 0
  %270 = getelementptr inbounds { double, double }, ptr %269, i32 0, i32 0
  %271 = extractvalue { double, double } %266, 0
  store double %271, ptr %270, align 16
  %272 = getelementptr inbounds { double, double }, ptr %269, i32 0, i32 1
  %273 = extractvalue { double, double } %266, 1
  store double %273, ptr %272, align 8
  %274 = load ptr, ptr %25, align 8, !tbaa !5
  %275 = getelementptr inbounds %"class.JPH::SoftBodyVertex", ptr %274, i32 0, i32 3
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 %275, ptr align 16 %48, i64 16, i1 false), !tbaa.struct !13
  call void @llvm.lifetime.end.p0(i64 16, ptr %49) #9
  call void @llvm.lifetime.end.p0(i64 16, ptr %48) #9
  %276 = load i32, ptr %18, align 4, !tbaa !9
  %277 = load ptr, ptr %25, align 8, !tbaa !5
  %278 = getelementptr inbounds %"class.JPH::SoftBodyVertex", ptr %277, i32 0, i32 4
  store i32 %276, ptr %278, align 16, !tbaa !35
  call void @llvm.lifetime.end.p0(i64 16, ptr %45) #9
  call void @llvm.lifetime.end.p0(i64 16, ptr %44) #9
  br label %279

279:                                              ; preds = %214, %189
  call void @llvm.lifetime.end.p0(i64 4, ptr %43) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %42) #9
  call void @llvm.lifetime.end.p0(i64 16, ptr %40) #9
  call void @llvm.lifetime.end.p0(i64 16, ptr %39) #9
  br label %280

280:                                              ; preds = %279, %188
  call void @llvm.lifetime.end.p0(i64 16, ptr %27) #9
  br label %281

281:                                              ; preds = %280, %89
  br label %282

282:                                              ; preds = %281
  %283 = load ptr, ptr %25, align 8, !tbaa !5
  %284 = getelementptr inbounds %"class.JPH::SoftBodyVertex", ptr %283, i32 1
  store ptr %284, ptr %25, align 8, !tbaa !5
  br label %84, !llvm.loop !36

285:                                              ; preds = %88
  call void @llvm.lifetime.end.p0(i64 4, ptr %24) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %23) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %22) #9
  call void @llvm.lifetime.end.p0(i64 64, ptr %21) #9
  ret void
}

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

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

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

; Function Attrs: mustprogress uwtable
declare dso_local { double, double } @_ZN3JPH5Plane19sFromPointAndNormalENS_4Vec3ES1_(double, double, double, double) #1 align 2

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

; Function Attrs: alwaysinline mustprogress nounwind uwtable
declare dso_local noundef float @_ZN3JPH4SignIfEET_S1_(float noundef) #8

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { 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 #2 = { nocallback nofree nounwind willreturn memory(argmem: readwrite) }
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 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 #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 = { 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 #7 = { 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 #8 = { alwaysinline 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 #9 = { 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 = !{!"int", !7, i64 0}
!11 = !{!12, !12, i64 0}
!12 = !{!"float", !7, i64 0}
!13 = !{i64 0, i64 16, !14}
!14 = !{!7, !7, i64 0}
!15 = !{i64 2157798098}
!16 = !{!17, !12, i64 48}
!17 = !{!"_ZTSN3JPH12CapsuleShapeE", !18, i64 0, !12, i64 44, !12, i64 48}
!18 = !{!"_ZTSN3JPH11ConvexShapeE", !19, i64 0, !26, i64 32, !12, i64 40}
!19 = !{!"_ZTSN3JPH5ShapeE", !20, i64 8, !23, i64 16, !24, i64 24, !25, i64 25}
!20 = !{!"_ZTSN3JPH9RefTargetINS_5ShapeEEE", !21, i64 0}
!21 = !{!"_ZTSSt6atomicIjE", !22, i64 0}
!22 = !{!"_ZTSSt13__atomic_baseIjE", !10, i64 0}
!23 = !{!"long", !7, i64 0}
!24 = !{!"_ZTSN3JPH10EShapeTypeE", !7, i64 0}
!25 = !{!"_ZTSN3JPH13EShapeSubTypeE", !7, i64 0}
!26 = !{!"_ZTSN3JPH8RefConstINS_15PhysicsMaterialEEE", !6, i64 0}
!27 = !{!17, !12, i64 44}
!28 = !{!29, !12, i64 76}
!29 = !{!"_ZTSN3JPH14SoftBodyVertexE", !30, i64 0, !30, i64 16, !30, i64 32, !31, i64 48, !10, i64 64, !33, i64 68, !12, i64 72, !12, i64 76}
!30 = !{!"_ZTSN3JPH4Vec3E", !7, i64 0}
!31 = !{!"_ZTSN3JPH5PlaneE", !32, i64 0}
!32 = !{!"_ZTSN3JPH4Vec4E", !7, i64 0}
!33 = !{!"bool", !7, i64 0}
!34 = !{!29, !12, i64 72}
!35 = !{!29, !10, i64 64}
!36 = distinct !{!36, !37}
!37 = !{!"llvm.loop.mustprogress"}


; 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::Vec3" = type { %union.anon.12 }
%union.anon.12 = type { <4 x float> }
%"class.JPH::Mat44" = type { [4 x %"class.JPH::Vec4"] }
%"class.JPH::Vec4" = type { %union.anon.14 }
%union.anon.14 = type { <4 x float> }
%"class.JPH::Plane" = type { %"class.JPH::Vec4" }
%"class.JPH::SoftBodyVertex" = type { %"class.JPH::Vec3", %"class.JPH::Vec3", %"class.JPH::Vec3", %"class.JPH::Plane", i32, i8, float, float }

@.str.6 = external hidden unnamed_addr constant [22 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [105 x i8], align 1

; 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: mustprogress uwtable
declare dso_local noundef zeroext i1 @_ZNK3JPH12CapsuleShape12IsValidScaleENS_4Vec3E(ptr noundef nonnull align 8 dereferenceable(56), double, double) unnamed_addr #1 align 2

; Function Attrs: mustprogress 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) #2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef zeroext i1 @_ZN3JPH23AssertFailedParamHelperEPKcS1_jNS_15AssertLastParamE(ptr noundef, ptr noundef, i32 noundef) local_unnamed_addr #3

; Function Attrs: alwaysinline mustprogress nounwind uwtable
declare dso_local noundef float @_ZNK3JPH4Vec34GetXEv(ptr noundef nonnull align 16 dereferenceable(16)) local_unnamed_addr #4 align 2

; Function Attrs: alwaysinline mustprogress uwtable
declare dso_local void @_ZN3JPH4Vec3C2Efff(ptr noundef nonnull align 16 dereferenceable(16), float noundef, float noundef, float noundef) unnamed_addr #5 align 2

; Function Attrs: alwaysinline mustprogress uwtable
declare dso_local noundef float @_ZNK3JPH4Vec36LengthEv(ptr noundef nonnull align 16 dereferenceable(16)) local_unnamed_addr #6 align 2

; Function Attrs: alwaysinline mustprogress uwtable
declare dso_local { double, double } @_ZN3JPHmlEfNS_4Vec3E(float noundef, double, double) local_unnamed_addr #5

; Function Attrs: alwaysinline mustprogress uwtable
declare dso_local { double, double } @_ZNK3JPH4Vec3miES0_(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 float @_ZSt3absf(float noundef) local_unnamed_addr #7

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

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

; Function Attrs: alwaysinline mustprogress uwtable
declare dso_local { double, double } @_ZN3JPH4Vec36sAxisXEv() local_unnamed_addr #6 align 2

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZNK3JPH12CapsuleShape23CollideSoftBodyVerticesERKNS_5Mat44ENS_4Vec3EPNS_14SoftBodyVertexEjfS4_i(ptr noundef nonnull align 8 dereferenceable(56) %0, ptr noundef nonnull align 16 dereferenceable(64) %1, double %2, double %3, ptr noundef %4, i32 noundef %5, float noundef %6, double %7, double %8, i32 noundef %9) unnamed_addr #1 align 2 {
  %11 = alloca %"class.JPH::Vec3", align 16
  %12 = alloca %"class.JPH::Mat44", align 16
  %13 = alloca %"class.JPH::Vec3", align 16
  %14 = alloca %"class.JPH::Vec3", align 16
  %15 = alloca %"class.JPH::Plane", align 16
  %16 = alloca %"class.JPH::Vec3", align 16
  %17 = alloca %"class.JPH::Vec3", align 16
  %18 = alloca %"class.JPH::Plane", align 16
  store double %2, ptr %11, align 16
  %19 = getelementptr inbounds i8, ptr %11, i64 8
  store double %3, ptr %19, align 8
  %20 = tail call noundef zeroext i1 @_ZNK3JPH12CapsuleShape12IsValidScaleENS_4Vec3E(ptr noundef nonnull align 8 dereferenceable(56) %0, double %2, double %3)
  br i1 %20, label %24, label %21

21:                                               ; preds = %10
  %22 = tail call noundef zeroext i1 @_ZN3JPH23AssertFailedParamHelperEPKcS1_jNS_15AssertLastParamE(ptr noundef nonnull @.str.6, ptr noundef nonnull @.str.7, i32 noundef 326)
  br i1 %22, label %23, label %24

23:                                               ; preds = %21
  tail call void asm sideeffect "int $$0x3", "~{dirflag},~{fpsr},~{flags}"() #9, !srcloc !5
  br label %24

24:                                               ; preds = %10, %21, %23
  call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %12) #9
  call void @_ZNK3JPH5Mat4427InversedRotationTranslationEv(ptr dead_on_unwind nonnull writable sret(%"class.JPH::Mat44") align 16 %12, ptr noundef nonnull align 16 dereferenceable(64) %1)
  %25 = call noundef float @_ZNK3JPH4Vec34GetXEv(ptr noundef nonnull align 16 dereferenceable(16) %11)
  %26 = call noundef float @_ZSt3absf(float noundef %25)
  %27 = getelementptr inbounds i8, ptr %0, i64 48
  %28 = load float, ptr %27, align 8, !tbaa !6
  %29 = fmul float %26, %28
  %30 = getelementptr inbounds i8, ptr %0, i64 44
  %31 = load float, ptr %30, align 4, !tbaa !22
  %32 = fmul float %26, %31
  %33 = zext i32 %5 to i64
  %34 = getelementptr inbounds %"class.JPH::SoftBodyVertex", ptr %4, i64 %33
  %.not = icmp eq i32 %5, 0
  br i1 %.not, label %._crit_edge, label %.lr.ph

.lr.ph:                                           ; preds = %24
  %35 = getelementptr inbounds i8, ptr %13, i64 8
  %.sroa.527.0..sroa_idx = getelementptr inbounds i8, ptr %14, i64 8
  %36 = getelementptr inbounds i8, ptr %15, i64 8
  %.sroa.215.0..sroa_idx = getelementptr inbounds i8, ptr %16, i64 8
  %37 = getelementptr inbounds i8, ptr %17, i64 8
  %38 = getelementptr inbounds i8, ptr %18, i64 8
  br label %39

._crit_edge:                                      ; preds = %108, %24
  call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %12) #9
  ret void

39:                                               ; preds = %.lr.ph, %108
  %.072 = phi ptr [ %4, %.lr.ph ], [ %109, %108 ]
  %40 = getelementptr inbounds i8, ptr %.072, i64 76
  %41 = load float, ptr %40, align 4, !tbaa !23
  %42 = fcmp ogt float %41, 0.000000e+00
  br i1 %42, label %43, label %108

43:                                               ; preds = %39
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %13) #9
  %44 = getelementptr inbounds i8, ptr %.072, i64 16
  %.sroa.033.0.copyload = load double, ptr %44, align 16
  %.sroa.234.0..sroa_idx = getelementptr inbounds i8, ptr %.072, i64 24
  %.sroa.234.0.copyload = load double, ptr %.sroa.234.0..sroa_idx, align 8, !tbaa !29
  %45 = call { double, double } @_ZNK3JPH5Mat44mlENS_4Vec3E(ptr noundef nonnull align 16 dereferenceable(64) %12, double %.sroa.033.0.copyload, double %.sroa.234.0.copyload)
  %46 = extractvalue { double, double } %45, 0
  store double %46, ptr %13, align 16
  %47 = extractvalue { double, double } %45, 1
  store double %47, ptr %35, align 8
  %48 = call noundef float @_ZNK3JPH4Vec34GetYEv(ptr noundef nonnull align 16 dereferenceable(16) %13)
  %49 = call noundef float @_ZSt3absf(float noundef %48)
  %50 = fcmp ugt float %49, %29
  br i1 %50, label %76, label %51

51:                                               ; preds = %43
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %14) #9
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(16) %14, ptr noundef nonnull align 16 dereferenceable(16) %13, i64 16, i1 false), !tbaa.struct !30
  call void @_ZN3JPH4Vec34SetYEf(ptr noundef nonnull align 16 dereferenceable(16) %14, float noundef 0.000000e+00)
  %52 = call noundef float @_ZNK3JPH4Vec36LengthEv(ptr noundef nonnull align 16 dereferenceable(16) %14)
  %53 = fsub float %32, %52
  %54 = getelementptr inbounds i8, ptr %.072, i64 72
  %55 = load float, ptr %54, align 8, !tbaa !31
  %56 = fcmp ogt float %53, %55
  br i1 %56, label %57, label %75

57:                                               ; preds = %51
  store float %53, ptr %54, align 8, !tbaa !31
  %58 = fcmp ogt float %52, 0.000000e+00
  br i1 %58, label %59, label %61

59:                                               ; preds = %57
  %60 = call { double, double } @_ZNK3JPH4Vec3dvEf(ptr noundef nonnull align 16 dereferenceable(16) %14, float noundef %52)
  br label %63

61:                                               ; preds = %57
  %62 = call { double, double } @_ZN3JPH4Vec36sAxisXEv()
  br label %63

63:                                               ; preds = %61, %59
  %.pn = phi { double, double } [ %60, %59 ], [ %62, %61 ]
  %.sroa.527.0 = extractvalue { double, double } %.pn, 1
  %.sroa.026.0 = extractvalue { double, double } %.pn, 0
  store double %.sroa.026.0, ptr %14, align 16
  store double %.sroa.527.0, ptr %.sroa.527.0..sroa_idx, align 8, !tbaa !29
  %64 = call { double, double } @_ZN3JPHmlEfNS_4Vec3E(float noundef %32, double %.sroa.026.0, double %.sroa.527.0)
  %65 = extractvalue { double, double } %64, 0
  %66 = extractvalue { double, double } %64, 1
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %15) #9
  %.sroa.016.0.copyload = load double, ptr %14, align 16
  %.sroa.217.0.copyload = load double, ptr %.sroa.527.0..sroa_idx, align 8, !tbaa !29
  %67 = call { double, double } @_ZN3JPH5Plane19sFromPointAndNormalENS_4Vec3ES1_(double %65, double %66, double %.sroa.016.0.copyload, double %.sroa.217.0.copyload)
  %68 = extractvalue { double, double } %67, 0
  store double %68, ptr %15, align 16
  %69 = extractvalue { double, double } %67, 1
  store double %69, ptr %36, align 8
  %70 = call { double, double } @_ZNK3JPH5Plane14GetTransformedERKNS_5Mat44E(ptr noundef nonnull align 16 dereferenceable(16) %15, ptr noundef nonnull align 16 dereferenceable(64) %1)
  %71 = extractvalue { double, double } %70, 0
  %72 = extractvalue { double, double } %70, 1
  %73 = getelementptr inbounds i8, ptr %.072, i64 48
  store double %71, ptr %73, align 16
  %.sroa.421.0..sroa_idx = getelementptr inbounds i8, ptr %.072, i64 56
  store double %72, ptr %.sroa.421.0..sroa_idx, align 8, !tbaa !29
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %15) #9
  %74 = getelementptr inbounds i8, ptr %.072, i64 64
  store i32 %9, ptr %74, align 16, !tbaa !32
  br label %75

75:                                               ; preds = %63, %51
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %14) #9
  br label %107

76:                                               ; preds = %43
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %16) #9
  %77 = call noundef float @_ZNK3JPH4Vec34GetYEv(ptr noundef nonnull align 16 dereferenceable(16) %13)
  %78 = call noundef float @_ZN3JPH4SignIfEET_S1_(float noundef %77)
  %79 = fmul float %29, %78
  call void @_ZN3JPH4Vec3C2Efff(ptr noundef nonnull align 16 dereferenceable(16) %16, float noundef 0.000000e+00, float noundef %79, float noundef 0.000000e+00)
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %17) #9
  %.sroa.014.0.copyload = load double, ptr %16, align 16
  %.sroa.215.0.copyload = load double, ptr %.sroa.215.0..sroa_idx, align 8, !tbaa !29
  %80 = call { double, double } @_ZNK3JPH4Vec3miES0_(ptr noundef nonnull align 16 dereferenceable(16) %13, double %.sroa.014.0.copyload, double %.sroa.215.0.copyload)
  %81 = extractvalue { double, double } %80, 0
  store double %81, ptr %17, align 16
  %82 = extractvalue { double, double } %80, 1
  store double %82, ptr %37, align 8
  %83 = call noundef float @_ZNK3JPH4Vec36LengthEv(ptr noundef nonnull align 16 dereferenceable(16) %17)
  %84 = fsub float %32, %83
  %85 = getelementptr inbounds i8, ptr %.072, i64 72
  %86 = load float, ptr %85, align 8, !tbaa !31
  %87 = fcmp ogt float %84, %86
  br i1 %87, label %88, label %106

88:                                               ; preds = %76
  store float %84, ptr %85, align 8, !tbaa !31
  %89 = call { double, double } @_ZNK3JPH4Vec3dvEf(ptr noundef nonnull align 16 dereferenceable(16) %17, float noundef %83)
  %90 = extractvalue { double, double } %89, 0
  %91 = extractvalue { double, double } %89, 1
  %92 = call { double, double } @_ZN3JPHmlEfNS_4Vec3E(float noundef %32, double %90, double %91)
  %93 = extractvalue { double, double } %92, 0
  %94 = extractvalue { double, double } %92, 1
  %95 = call { double, double } @_ZNK3JPH4Vec3plES0_(ptr noundef nonnull align 16 dereferenceable(16) %16, double %93, double %94)
  %96 = extractvalue { double, double } %95, 0
  %97 = extractvalue { double, double } %95, 1
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %18) #9
  %98 = call { double, double } @_ZN3JPH5Plane19sFromPointAndNormalENS_4Vec3ES1_(double %96, double %97, double %90, double %91)
  %99 = extractvalue { double, double } %98, 0
  store double %99, ptr %18, align 16
  %100 = extractvalue { double, double } %98, 1
  store double %100, ptr %38, align 8
  %101 = call { double, double } @_ZNK3JPH5Plane14GetTransformedERKNS_5Mat44E(ptr noundef nonnull align 16 dereferenceable(16) %18, ptr noundef nonnull align 16 dereferenceable(64) %1)
  %102 = extractvalue { double, double } %101, 0
  %103 = extractvalue { double, double } %101, 1
  %104 = getelementptr inbounds i8, ptr %.072, i64 48
  store double %102, ptr %104, align 16
  %.sroa.4.0..sroa_idx = getelementptr inbounds i8, ptr %.072, i64 56
  store double %103, ptr %.sroa.4.0..sroa_idx, align 8, !tbaa !29
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %18) #9
  %105 = getelementptr inbounds i8, ptr %.072, i64 64
  store i32 %9, ptr %105, align 16, !tbaa !32
  br label %106

106:                                              ; preds = %88, %76
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %17) #9
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %16) #9
  br label %107

107:                                              ; preds = %106, %75
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %13) #9
  br label %108

108:                                              ; preds = %39, %107
  %109 = getelementptr inbounds i8, ptr %.072, i64 80
  %110 = icmp ult ptr %109, %34
  br i1 %110, label %39, label %._crit_edge, !llvm.loop !33
}

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

; Function Attrs: alwaysinline mustprogress nounwind uwtable
declare dso_local void @_ZN3JPH4Vec34SetYEf(ptr noundef nonnull align 16 dereferenceable(16), float noundef) local_unnamed_addr #8 align 2

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

; Function Attrs: mustprogress uwtable
declare dso_local { double, double } @_ZN3JPH5Plane19sFromPointAndNormalENS_4Vec3ES1_(double, double, double, double) local_unnamed_addr #1 align 2

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

; Function Attrs: alwaysinline mustprogress nounwind uwtable
declare dso_local noundef float @_ZN3JPH4SignIfEET_S1_(float noundef) local_unnamed_addr #8

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { 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 #2 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: readwrite) }
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 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 #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 = { 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 #7 = { 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 #8 = { alwaysinline 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 #9 = { 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 = !{i64 2157798098}
!6 = !{!7, !21, i64 48}
!7 = !{!"_ZTSN3JPH12CapsuleShapeE", !8, i64 0, !21, i64 44, !21, i64 48}
!8 = !{!"_ZTSN3JPH11ConvexShapeE", !9, i64 0, !19, i64 32, !21, i64 40}
!9 = !{!"_ZTSN3JPH5ShapeE", !10, i64 8, !16, i64 16, !17, i64 24, !18, i64 25}
!10 = !{!"_ZTSN3JPH9RefTargetINS_5ShapeEEE", !11, i64 0}
!11 = !{!"_ZTSSt6atomicIjE", !12, i64 0}
!12 = !{!"_ZTSSt13__atomic_baseIjE", !13, i64 0}
!13 = !{!"int", !14, i64 0}
!14 = !{!"omnipotent char", !15, i64 0}
!15 = !{!"Simple C++ TBAA"}
!16 = !{!"long", !14, i64 0}
!17 = !{!"_ZTSN3JPH10EShapeTypeE", !14, i64 0}
!18 = !{!"_ZTSN3JPH13EShapeSubTypeE", !14, i64 0}
!19 = !{!"_ZTSN3JPH8RefConstINS_15PhysicsMaterialEEE", !20, i64 0}
!20 = !{!"any pointer", !14, i64 0}
!21 = !{!"float", !14, i64 0}
!22 = !{!7, !21, i64 44}
!23 = !{!24, !21, i64 76}
!24 = !{!"_ZTSN3JPH14SoftBodyVertexE", !25, i64 0, !25, i64 16, !25, i64 32, !26, i64 48, !13, i64 64, !28, i64 68, !21, i64 72, !21, i64 76}
!25 = !{!"_ZTSN3JPH4Vec3E", !14, i64 0}
!26 = !{!"_ZTSN3JPH5PlaneE", !27, i64 0}
!27 = !{!"_ZTSN3JPH4Vec4E", !14, i64 0}
!28 = !{!"bool", !14, i64 0}
!29 = !{!14, !14, i64 0}
!30 = !{i64 0, i64 16, !29}
!31 = !{!24, !21, i64 72}
!32 = !{!24, !13, i64 64}
!33 = distinct !{!33, !34}
!34 = !{!"llvm.loop.mustprogress"}


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