; LLVM IR from jrouwe/JoltPhysics :: Jolt/Geometry (ConvexHullBuilder2D)

; 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 }
%union.anon = type { <4 x float> }
%"class.JPH::Array.3" = type { i64, i64, ptr }
%"class.std::initializer_list" = type { ptr, i64 }
%"class.JPH::STLAllocator.4" = type { i8 }
%"class.JPH::ConvexHullBuilder2D" = type <{ ptr, ptr, i32, [4 x i8] }>
%"class.JPH::ConvexHullBuilder2D::Edge" = type { %"class.JPH::Vec3", %"class.JPH::Vec3", %"class.JPH::Array", ptr, ptr, i32, float }
%"class.JPH::Array" = type { i64, i64, ptr }

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

declare i32 @__gxx_personality_v0(...)

; 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 void @_ZN3JPH19ConvexHullBuilder2D4Edge24CalculateNormalAndCenterEPKNS_4Vec3E(ptr noundef nonnull align 16 dereferenceable(80), ptr noundef) #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: alwaysinline mustprogress uwtable
declare dso_local { double, double } @_ZNK3JPH4Vec3miES0_(ptr noundef nonnull align 16 dereferenceable(16), double, double) #3 align 2

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

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZN3JPH19ConvexHullBuilder2D4EdgeD2Ev(ptr noundef nonnull align 16 dereferenceable(80)) unnamed_addr #6 align 2

; Function Attrs: alwaysinline mustprogress nounwind uwtable
declare dso_local void @_ZN3JPH19ConvexHullBuilder2D4EdgedlEPv(ptr noundef) #4 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNK3JPH19ConvexHullBuilder2D13ValidateEdgesEv(ptr noundef nonnull align 8 dereferenceable(20)) #1 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNK3JPH19ConvexHullBuilder2D17AssignPointToEdgeEiRKNS_5ArrayIPNS0_4EdgeENS_12STLAllocatorIS3_EEEE(ptr noundef nonnull align 8 dereferenceable(20), i32 noundef, ptr noundef nonnull align 8 dereferenceable(24)) #1 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef nonnull align 16 dereferenceable(16) ptr @_ZNK3JPH5ArrayINS_4Vec3ENS_12STLAllocatorIS1_EEEixEm(ptr noundef nonnull align 8 dereferenceable(24), i64 noundef) #7 align 2

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

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

; Function Attrs: mustprogress uwtable
define dso_local noundef i32 @_ZN3JPH19ConvexHullBuilder2D10InitializeEiiiifRNS_5ArrayIiNS_12STLAllocatorIiEEEE(ptr noundef nonnull align 8 dereferenceable(20) %0, i32 noundef %1, i32 noundef %2, i32 noundef %3, i32 noundef %4, float noundef %5, ptr noundef nonnull align 8 dereferenceable(24) %6) #1 align 2 personality ptr @__gxx_personality_v0 {
  %8 = alloca ptr, align 8
  %9 = alloca i32, align 4
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  %13 = alloca float, align 4
  %14 = alloca ptr, align 8
  %15 = alloca i32, align 4
  %16 = alloca %"class.JPH::Vec3", align 16
  %17 = alloca ptr, align 8
  %18 = alloca ptr, align 8
  %19 = alloca ptr, align 8
  %20 = alloca %"class.JPH::Vec3", align 16
  %21 = alloca %"class.JPH::Vec3", align 16
  %22 = alloca %"class.JPH::Vec3", align 16
  %23 = alloca %"class.JPH::Vec3", align 16
  %24 = alloca float, align 4
  %25 = alloca float, align 4
  %26 = alloca float, align 4
  %27 = alloca float, align 4
  %28 = alloca %"class.JPH::Vec3", align 16
  %29 = alloca %"class.JPH::Vec3", align 16
  %30 = alloca %"class.JPH::Vec3", align 16
  %31 = alloca %"class.JPH::Vec3", align 16
  %32 = alloca %"class.JPH::Vec3", align 16
  %33 = alloca ptr, align 8
  %34 = alloca ptr, align 8
  %35 = alloca i32, align 4
  %36 = alloca ptr, align 8
  %37 = alloca ptr, align 8
  %38 = alloca %"class.JPH::Array.3", align 8
  %39 = alloca %"class.std::initializer_list", align 8
  %40 = alloca [3 x ptr], align 8
  %41 = alloca %"class.JPH::STLAllocator.4", align 1
  %42 = alloca ptr, align 8
  %43 = alloca ptr, align 8
  %44 = alloca ptr, align 8
  %45 = alloca ptr, align 8
  %46 = alloca i32, align 4
  %47 = alloca ptr, align 8
  %48 = alloca float, align 4
  %49 = alloca ptr, align 8
  %50 = alloca i32, align 4
  %51 = alloca i32, align 4
  %52 = alloca %"class.JPH::Vec3", align 16
  %53 = alloca ptr, align 8
  %54 = alloca ptr, align 8
  %55 = alloca %"class.JPH::Vec3", align 16
  %56 = alloca ptr, align 8
  %57 = alloca ptr, align 8
  %58 = alloca %"class.JPH::Vec3", align 16
  %59 = alloca %"class.JPH::Array.3", align 8
  %60 = alloca %"class.std::initializer_list", align 8
  %61 = alloca [2 x ptr], align 8
  %62 = alloca %"class.JPH::STLAllocator.4", align 1
  %63 = alloca ptr, align 8
  %64 = alloca ptr, align 8
  %65 = alloca ptr, align 8
  %66 = alloca ptr, align 8
  %67 = alloca ptr, align 8
  %68 = alloca ptr, align 8
  %69 = alloca ptr, align 8
  %70 = alloca ptr, align 8
  %71 = alloca i32, align 4
  %72 = alloca ptr, align 8
  store ptr %0, ptr %8, align 8, !tbaa !5
  store i32 %1, ptr %9, align 4, !tbaa !9
  store i32 %2, ptr %10, align 4, !tbaa !9
  store i32 %3, ptr %11, align 4, !tbaa !9
  store i32 %4, ptr %12, align 4, !tbaa !9
  store float %5, ptr %13, align 4, !tbaa !11
  store ptr %6, ptr %14, align 8, !tbaa !5
  %73 = load ptr, ptr %8, align 8
  call void @_ZN3JPH19ConvexHullBuilder2D9FreeEdgesEv(ptr noundef nonnull align 8 dereferenceable(20) %73)
  %74 = load ptr, ptr %14, align 8, !tbaa !5
  call void @_ZN3JPH5ArrayIiNS_12STLAllocatorIiEEE5clearEv(ptr noundef nonnull align 8 dereferenceable(24) %74)
  call void @llvm.lifetime.start.p0(i64 4, ptr %15) #9
  store i32 0, ptr %15, align 4, !tbaa !13
  call void @llvm.lifetime.start.p0(i64 16, ptr %16) #9
  %75 = call { double, double } @_ZN3JPH4Vec35sZeroEv()
  %76 = getelementptr inbounds %"class.JPH::Vec3", ptr %16, i32 0, i32 0
  %77 = getelementptr inbounds %union.anon, ptr %76, i32 0, i32 0
  %78 = getelementptr inbounds { double, double }, ptr %77, i32 0, i32 0
  %79 = extractvalue { double, double } %75, 0
  store double %79, ptr %78, align 16
  %80 = getelementptr inbounds { double, double }, ptr %77, i32 0, i32 1
  %81 = extractvalue { double, double } %75, 1
  store double %81, ptr %80, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #9
  %82 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D", ptr %73, i32 0, i32 0
  %83 = load ptr, ptr %82, align 8, !tbaa !15
  store ptr %83, ptr %17, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #9
  %84 = load ptr, ptr %17, align 8, !tbaa !5
  %85 = call noundef ptr @_ZNK3JPH5ArrayINS_4Vec3ENS_12STLAllocatorIS1_EEE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %84)
  store ptr %85, ptr %18, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %19) #9
  %86 = load ptr, ptr %17, align 8, !tbaa !5
  %87 = call noundef ptr @_ZNK3JPH5ArrayINS_4Vec3ENS_12STLAllocatorIS1_EEE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %86)
  store ptr %87, ptr %19, align 8, !tbaa !5
  br label %88

88:                                               ; preds = %117, %7
  %89 = load ptr, ptr %18, align 8, !tbaa !5
  %90 = load ptr, ptr %19, align 8, !tbaa !5
  %91 = icmp ne ptr %89, %90
  br i1 %91, label %93, label %92

92:                                               ; preds = %88
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #9
  br label %120

93:                                               ; preds = %88
  call void @llvm.lifetime.start.p0(i64 16, ptr %20) #9
  %94 = load ptr, ptr %18, align 8, !tbaa !5
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 %20, ptr align 16 %94, i64 16, i1 false), !tbaa.struct !17
  call void @llvm.lifetime.start.p0(i64 16, ptr %21) #9
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 %22, ptr align 16 %16, i64 16, i1 false), !tbaa.struct !17
  %95 = call { double, double } @_ZNK3JPH4Vec33AbsEv(ptr noundef nonnull align 16 dereferenceable(16) %20)
  %96 = getelementptr inbounds %"class.JPH::Vec3", ptr %23, i32 0, i32 0
  %97 = getelementptr inbounds %union.anon, ptr %96, i32 0, i32 0
  %98 = getelementptr inbounds { double, double }, ptr %97, i32 0, i32 0
  %99 = extractvalue { double, double } %95, 0
  store double %99, ptr %98, align 16
  %100 = getelementptr inbounds { double, double }, ptr %97, i32 0, i32 1
  %101 = extractvalue { double, double } %95, 1
  store double %101, ptr %100, align 8
  %102 = getelementptr inbounds { double, double }, ptr %22, i32 0, i32 0
  %103 = load double, ptr %102, align 16
  %104 = getelementptr inbounds { double, double }, ptr %22, i32 0, i32 1
  %105 = load double, ptr %104, align 8
  %106 = getelementptr inbounds { double, double }, ptr %23, i32 0, i32 0
  %107 = load double, ptr %106, align 16
  %108 = getelementptr inbounds { double, double }, ptr %23, i32 0, i32 1
  %109 = load double, ptr %108, align 8
  %110 = call { double, double } @_ZN3JPH4Vec34sMaxES0_S0_(double %103, double %105, double %107, double %109)
  %111 = getelementptr inbounds %"class.JPH::Vec3", ptr %21, i32 0, i32 0
  %112 = getelementptr inbounds %union.anon, ptr %111, i32 0, i32 0
  %113 = getelementptr inbounds { double, double }, ptr %112, i32 0, i32 0
  %114 = extractvalue { double, double } %110, 0
  store double %114, ptr %113, align 16
  %115 = getelementptr inbounds { double, double }, ptr %112, i32 0, i32 1
  %116 = extractvalue { double, double } %110, 1
  store double %116, ptr %115, align 8
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 %16, ptr align 16 %21, i64 16, i1 false), !tbaa.struct !17
  call void @llvm.lifetime.end.p0(i64 16, ptr %21) #9
  call void @llvm.lifetime.end.p0(i64 16, ptr %20) #9
  br label %117

117:                                              ; preds = %93
  %118 = load ptr, ptr %18, align 8, !tbaa !5
  %119 = getelementptr inbounds %"class.JPH::Vec3", ptr %118, i32 1
  store ptr %119, ptr %18, align 8, !tbaa !5
  br label %88

120:                                              ; preds = %92
  call void @llvm.lifetime.start.p0(i64 4, ptr %24) #9
  %121 = call noundef float @_ZNK3JPH4Vec34GetXEv(ptr noundef nonnull align 16 dereferenceable(16) %16)
  %122 = call noundef float @_ZNK3JPH4Vec34GetYEv(ptr noundef nonnull align 16 dereferenceable(16) %16)
  %123 = fadd float %121, %122
  %124 = fmul float 0x3E90000000000000, %123
  %125 = call noundef float @_ZN3JPH6SquareIfEET_S1_(float noundef %124)
  store float %125, ptr %24, align 4, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 4, ptr %25) #9
  call void @llvm.lifetime.start.p0(i64 4, ptr %26) #9
  %126 = load float, ptr %13, align 4, !tbaa !11
  %127 = call noundef float @_ZN3JPH6SquareIfEET_S1_(float noundef %126)
  store float %127, ptr %26, align 4, !tbaa !11
  %128 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3maxIfERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %24, ptr noundef nonnull align 4 dereferenceable(4) %26)
  %129 = load float, ptr %128, align 4, !tbaa !11
  call void @llvm.lifetime.end.p0(i64 4, ptr %26) #9
  store float %129, ptr %25, align 4, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 4, ptr %27) #9
  call void @llvm.lifetime.start.p0(i64 16, ptr %28) #9
  call void @llvm.lifetime.start.p0(i64 16, ptr %29) #9
  %130 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D", ptr %73, i32 0, i32 0
  %131 = load ptr, ptr %130, align 8, !tbaa !15
  %132 = load i32, ptr %10, align 4, !tbaa !9
  %133 = sext i32 %132 to i64
  %134 = call noundef nonnull align 16 dereferenceable(16) ptr @_ZNK3JPH5ArrayINS_4Vec3ENS_12STLAllocatorIS1_EEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %131, i64 noundef %133)
  %135 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D", ptr %73, i32 0, i32 0
  %136 = load ptr, ptr %135, align 8, !tbaa !15
  %137 = load i32, ptr %9, align 4, !tbaa !9
  %138 = sext i32 %137 to i64
  %139 = call noundef nonnull align 16 dereferenceable(16) ptr @_ZNK3JPH5ArrayINS_4Vec3ENS_12STLAllocatorIS1_EEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %136, i64 noundef %138)
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 %30, ptr align 16 %139, i64 16, i1 false), !tbaa.struct !17
  %140 = getelementptr inbounds { double, double }, ptr %30, i32 0, i32 0
  %141 = load double, ptr %140, align 16
  %142 = getelementptr inbounds { double, double }, ptr %30, i32 0, i32 1
  %143 = load double, ptr %142, align 8
  %144 = call { double, double } @_ZNK3JPH4Vec3miES0_(ptr noundef nonnull align 16 dereferenceable(16) %134, double %141, double %143)
  %145 = getelementptr inbounds %"class.JPH::Vec3", ptr %29, i32 0, i32 0
  %146 = getelementptr inbounds %union.anon, ptr %145, i32 0, i32 0
  %147 = getelementptr inbounds { double, double }, ptr %146, i32 0, i32 0
  %148 = extractvalue { double, double } %144, 0
  store double %148, ptr %147, align 16
  %149 = getelementptr inbounds { double, double }, ptr %146, i32 0, i32 1
  %150 = extractvalue { double, double } %144, 1
  store double %150, ptr %149, align 8
  %151 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D", ptr %73, i32 0, i32 0
  %152 = load ptr, ptr %151, align 8, !tbaa !15
  %153 = load i32, ptr %11, align 4, !tbaa !9
  %154 = sext i32 %153 to i64
  %155 = call noundef nonnull align 16 dereferenceable(16) ptr @_ZNK3JPH5ArrayINS_4Vec3ENS_12STLAllocatorIS1_EEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %152, i64 noundef %154)
  %156 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D", ptr %73, i32 0, i32 0
  %157 = load ptr, ptr %156, align 8, !tbaa !15
  %158 = load i32, ptr %9, align 4, !tbaa !9
  %159 = sext i32 %158 to i64
  %160 = call noundef nonnull align 16 dereferenceable(16) ptr @_ZNK3JPH5ArrayINS_4Vec3ENS_12STLAllocatorIS1_EEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %157, i64 noundef %159)
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 %32, ptr align 16 %160, i64 16, i1 false), !tbaa.struct !17
  %161 = getelementptr inbounds { double, double }, ptr %32, i32 0, i32 0
  %162 = load double, ptr %161, align 16
  %163 = getelementptr inbounds { double, double }, ptr %32, i32 0, i32 1
  %164 = load double, ptr %163, align 8
  %165 = call { double, double } @_ZNK3JPH4Vec3miES0_(ptr noundef nonnull align 16 dereferenceable(16) %155, double %162, double %164)
  %166 = getelementptr inbounds %"class.JPH::Vec3", ptr %31, i32 0, i32 0
  %167 = getelementptr inbounds %union.anon, ptr %166, i32 0, i32 0
  %168 = getelementptr inbounds { double, double }, ptr %167, i32 0, i32 0
  %169 = extractvalue { double, double } %165, 0
  store double %169, ptr %168, align 16
  %170 = getelementptr inbounds { double, double }, ptr %167, i32 0, i32 1
  %171 = extractvalue { double, double } %165, 1
  store double %171, ptr %170, align 8
  %172 = getelementptr inbounds { double, double }, ptr %31, i32 0, i32 0
  %173 = load double, ptr %172, align 16
  %174 = getelementptr inbounds { double, double }, ptr %31, i32 0, i32 1
  %175 = load double, ptr %174, align 8
  %176 = call { double, double } @_ZNK3JPH4Vec35CrossES0_(ptr noundef nonnull align 16 dereferenceable(16) %29, double %173, double %175)
  %177 = getelementptr inbounds %"class.JPH::Vec3", ptr %28, i32 0, i32 0
  %178 = getelementptr inbounds %union.anon, ptr %177, i32 0, i32 0
  %179 = getelementptr inbounds { double, double }, ptr %178, i32 0, i32 0
  %180 = extractvalue { double, double } %176, 0
  store double %180, ptr %179, align 16
  %181 = getelementptr inbounds { double, double }, ptr %178, i32 0, i32 1
  %182 = extractvalue { double, double } %176, 1
  store double %182, ptr %181, align 8
  %183 = call noundef float @_ZNK3JPH4Vec34GetZEv(ptr noundef nonnull align 16 dereferenceable(16) %28)
  call void @llvm.lifetime.end.p0(i64 16, ptr %29) #9
  call void @llvm.lifetime.end.p0(i64 16, ptr %28) #9
  store float %183, ptr %27, align 4, !tbaa !11
  %184 = load float, ptr %27, align 4, !tbaa !11
  %185 = fcmp olt float %184, 0.000000e+00
  br i1 %185, label %186, label %187

186:                                              ; preds = %120
  call void @_ZSt4swapIiENSt9enable_ifIXsr6__and_ISt6__not_ISt15__is_tuple_likeIT_EESt21is_move_constructibleIS3_ESt18is_move_assignableIS3_EEE5valueEvE4typeERS3_SC_(ptr noundef nonnull align 4 dereferenceable(4) %9, ptr noundef nonnull align 4 dereferenceable(4) %10) #9
  br label %187

187:                                              ; preds = %186, %120
  call void @llvm.lifetime.start.p0(i64 8, ptr %33) #9
  %188 = call noundef ptr @_ZN3JPH19ConvexHullBuilder2D4EdgenwEm(i64 noundef 80)
  %189 = load i32, ptr %9, align 4, !tbaa !9
  invoke void @_ZN3JPH19ConvexHullBuilder2D4EdgeC2Ei(ptr noundef nonnull align 16 dereferenceable(80) %188, i32 noundef %189)
          to label %190 unwind label %240

190:                                              ; preds = %187
  store ptr %188, ptr %33, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %36) #9
  %191 = call noundef ptr @_ZN3JPH19ConvexHullBuilder2D4EdgenwEm(i64 noundef 80)
  %192 = load i32, ptr %10, align 4, !tbaa !9
  invoke void @_ZN3JPH19ConvexHullBuilder2D4EdgeC2Ei(ptr noundef nonnull align 16 dereferenceable(80) %191, i32 noundef %192)
          to label %193 unwind label %244

193:                                              ; preds = %190
  store ptr %191, ptr %36, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %37) #9
  %194 = call noundef ptr @_ZN3JPH19ConvexHullBuilder2D4EdgenwEm(i64 noundef 80)
  %195 = load i32, ptr %11, align 4, !tbaa !9
  invoke void @_ZN3JPH19ConvexHullBuilder2D4EdgeC2Ei(ptr noundef nonnull align 16 dereferenceable(80) %194, i32 noundef %195)
          to label %196 unwind label %248

196:                                              ; preds = %193
  store ptr %194, ptr %37, align 8, !tbaa !5
  %197 = load ptr, ptr %36, align 8, !tbaa !5
  %198 = load ptr, ptr %33, align 8, !tbaa !5
  %199 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D::Edge", ptr %198, i32 0, i32 4
  store ptr %197, ptr %199, align 16, !tbaa !19
  %200 = load ptr, ptr %37, align 8, !tbaa !5
  %201 = load ptr, ptr %33, align 8, !tbaa !5
  %202 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D::Edge", ptr %201, i32 0, i32 3
  store ptr %200, ptr %202, align 8, !tbaa !24
  %203 = load ptr, ptr %37, align 8, !tbaa !5
  %204 = load ptr, ptr %36, align 8, !tbaa !5
  %205 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D::Edge", ptr %204, i32 0, i32 4
  store ptr %203, ptr %205, align 16, !tbaa !19
  %206 = load ptr, ptr %33, align 8, !tbaa !5
  %207 = load ptr, ptr %36, align 8, !tbaa !5
  %208 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D::Edge", ptr %207, i32 0, i32 3
  store ptr %206, ptr %208, align 8, !tbaa !24
  %209 = load ptr, ptr %33, align 8, !tbaa !5
  %210 = load ptr, ptr %37, align 8, !tbaa !5
  %211 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D::Edge", ptr %210, i32 0, i32 4
  store ptr %209, ptr %211, align 16, !tbaa !19
  %212 = load ptr, ptr %36, align 8, !tbaa !5
  %213 = load ptr, ptr %37, align 8, !tbaa !5
  %214 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D::Edge", ptr %213, i32 0, i32 3
  store ptr %212, ptr %214, align 8, !tbaa !24
  %215 = load ptr, ptr %33, align 8, !tbaa !5
  %216 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D", ptr %73, i32 0, i32 1
  store ptr %215, ptr %216, align 8, !tbaa !25
  %217 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D", ptr %73, i32 0, i32 2
  store i32 3, ptr %217, align 8, !tbaa !26
  call void @llvm.lifetime.start.p0(i64 24, ptr %38) #9
  call void @llvm.lifetime.start.p0(i64 24, ptr %40) #9
  %218 = load ptr, ptr %33, align 8, !tbaa !5
  store ptr %218, ptr %40, align 8, !tbaa !5
  %219 = getelementptr inbounds ptr, ptr %40, i64 1
  %220 = load ptr, ptr %36, align 8, !tbaa !5
  store ptr %220, ptr %219, align 8, !tbaa !5
  %221 = getelementptr inbounds ptr, ptr %40, i64 2
  %222 = load ptr, ptr %37, align 8, !tbaa !5
  store ptr %222, ptr %221, align 8, !tbaa !5
  %223 = getelementptr inbounds %"class.std::initializer_list", ptr %39, i32 0, i32 0
  store ptr %40, ptr %223, align 8, !tbaa !27
  %224 = getelementptr inbounds %"class.std::initializer_list", ptr %39, i32 0, i32 1
  store i64 3, ptr %224, align 8, !tbaa !29
  call void @llvm.lifetime.start.p0(i64 1, ptr %41) #9
  %225 = getelementptr inbounds { ptr, i64 }, ptr %39, i32 0, i32 0
  %226 = load ptr, ptr %225, align 8
  %227 = getelementptr inbounds { ptr, i64 }, ptr %39, i32 0, i32 1
  %228 = load i64, ptr %227, align 8
  call void @_ZN3JPH5ArrayIPNS_19ConvexHullBuilder2D4EdgeENS_12STLAllocatorIS3_EEEC2ESt16initializer_listIS3_ERKS5_(ptr noundef nonnull align 8 dereferenceable(24) %38, ptr %226, i64 %228, ptr noundef nonnull align 1 dereferenceable(1) %41)
  call void @llvm.lifetime.end.p0(i64 1, ptr %41) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr %40) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr %42) #9
  store ptr %38, ptr %42, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %43) #9
  %229 = load ptr, ptr %42, align 8, !tbaa !5
  %230 = invoke noundef ptr @_ZN3JPH5ArrayIPNS_19ConvexHullBuilder2D4EdgeENS_12STLAllocatorIS3_EEE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %229)
          to label %231 unwind label %252

231:                                              ; preds = %196
  store ptr %230, ptr %43, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %44) #9
  %232 = load ptr, ptr %42, align 8, !tbaa !5
  %233 = invoke noundef ptr @_ZN3JPH5ArrayIPNS_19ConvexHullBuilder2D4EdgeENS_12STLAllocatorIS3_EEE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %232)
          to label %234 unwind label %256

234:                                              ; preds = %231
  store ptr %233, ptr %44, align 8, !tbaa !5
  br label %235

235:                                              ; preds = %269, %234
  %236 = load ptr, ptr %43, align 8, !tbaa !5
  %237 = load ptr, ptr %44, align 8, !tbaa !5
  %238 = icmp ne ptr %236, %237
  br i1 %238, label %260, label %239

239:                                              ; preds = %235
  call void @llvm.lifetime.end.p0(i64 8, ptr %44) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %43) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %42) #9
  br label %278

240:                                              ; preds = %187
  %241 = landingpad { ptr, i32 }
          cleanup
  %242 = extractvalue { ptr, i32 } %241, 0
  store ptr %242, ptr %34, align 8
  %243 = extractvalue { ptr, i32 } %241, 1
  store i32 %243, ptr %35, align 4
  call void @_ZN3JPH19ConvexHullBuilder2D4EdgedlEPv(ptr noundef %188) #9
  br label %637

244:                                              ; preds = %190
  %245 = landingpad { ptr, i32 }
          cleanup
  %246 = extractvalue { ptr, i32 } %245, 0
  store ptr %246, ptr %34, align 8
  %247 = extractvalue { ptr, i32 } %245, 1
  store i32 %247, ptr %35, align 4
  call void @_ZN3JPH19ConvexHullBuilder2D4EdgedlEPv(ptr noundef %191) #9
  br label %636

248:                                              ; preds = %193
  %249 = landingpad { ptr, i32 }
          cleanup
  %250 = extractvalue { ptr, i32 } %249, 0
  store ptr %250, ptr %34, align 8
  %251 = extractvalue { ptr, i32 } %249, 1
  store i32 %251, ptr %35, align 4
  call void @_ZN3JPH19ConvexHullBuilder2D4EdgedlEPv(ptr noundef %194) #9
  br label %635

252:                                              ; preds = %196
  %253 = landingpad { ptr, i32 }
          cleanup
  %254 = extractvalue { ptr, i32 } %253, 0
  store ptr %254, ptr %34, align 8
  %255 = extractvalue { ptr, i32 } %253, 1
  store i32 %255, ptr %35, align 4
  br label %277

256:                                              ; preds = %231
  %257 = landingpad { ptr, i32 }
          cleanup
  %258 = extractvalue { ptr, i32 } %257, 0
  store ptr %258, ptr %34, align 8
  %259 = extractvalue { ptr, i32 } %257, 1
  store i32 %259, ptr %35, align 4
  br label %276

260:                                              ; preds = %235
  call void @llvm.lifetime.start.p0(i64 8, ptr %45) #9
  %261 = load ptr, ptr %43, align 8, !tbaa !5
  %262 = load ptr, ptr %261, align 8, !tbaa !5
  store ptr %262, ptr %45, align 8, !tbaa !5
  %263 = load ptr, ptr %45, align 8, !tbaa !5
  %264 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D", ptr %73, i32 0, i32 0
  %265 = load ptr, ptr %264, align 8, !tbaa !15
  %266 = invoke noundef ptr @_ZNK3JPH5ArrayINS_4Vec3ENS_12STLAllocatorIS1_EEE4dataEv(ptr noundef nonnull align 8 dereferenceable(24) %265)
          to label %267 unwind label %272

267:                                              ; preds = %260
  invoke void @_ZN3JPH19ConvexHullBuilder2D4Edge24CalculateNormalAndCenterEPKNS_4Vec3E(ptr noundef nonnull align 16 dereferenceable(80) %263, ptr noundef %266)
          to label %268 unwind label %272

268:                                              ; preds = %267
  call void @llvm.lifetime.end.p0(i64 8, ptr %45) #9
  br label %269

269:                                              ; preds = %268
  %270 = load ptr, ptr %43, align 8, !tbaa !5
  %271 = getelementptr inbounds ptr, ptr %270, i32 1
  store ptr %271, ptr %43, align 8, !tbaa !5
  br label %235

272:                                              ; preds = %267, %260
  %273 = landingpad { ptr, i32 }
          cleanup
  %274 = extractvalue { ptr, i32 } %273, 0
  store ptr %274, ptr %34, align 8
  %275 = extractvalue { ptr, i32 } %273, 1
  store i32 %275, ptr %35, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %45) #9
  br label %276

276:                                              ; preds = %272, %256
  call void @llvm.lifetime.end.p0(i64 8, ptr %44) #9
  br label %277

277:                                              ; preds = %276, %252
  call void @llvm.lifetime.end.p0(i64 8, ptr %43) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %42) #9
  br label %634

278:                                              ; preds = %239
  call void @llvm.lifetime.start.p0(i64 4, ptr %46) #9
  store i32 0, ptr %46, align 4, !tbaa !9
  br label %279

279:                                              ; preds = %308, %278
  %280 = load i32, ptr %46, align 4, !tbaa !9
  %281 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D", ptr %73, i32 0, i32 0
  %282 = load ptr, ptr %281, align 8, !tbaa !15
  %283 = invoke noundef i64 @_ZNK3JPH5ArrayINS_4Vec3ENS_12STLAllocatorIS1_EEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %282)
          to label %284 unwind label %288

284:                                              ; preds = %279
  %285 = trunc i64 %283 to i32
  %286 = icmp slt i32 %280, %285
  br i1 %286, label %292, label %287

287:                                              ; preds = %284
  call void @llvm.lifetime.end.p0(i64 4, ptr %46) #9
  br label %311

288:                                              ; preds = %304, %279
  %289 = landingpad { ptr, i32 }
          cleanup
  %290 = extractvalue { ptr, i32 } %289, 0
  store ptr %290, ptr %34, align 8
  %291 = extractvalue { ptr, i32 } %289, 1
  store i32 %291, ptr %35, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %46) #9
  br label %634

292:                                              ; preds = %284
  %293 = load i32, ptr %46, align 4, !tbaa !9
  %294 = load i32, ptr %9, align 4, !tbaa !9
  %295 = icmp ne i32 %293, %294
  br i1 %295, label %296, label %307

296:                                              ; preds = %292
  %297 = load i32, ptr %46, align 4, !tbaa !9
  %298 = load i32, ptr %10, align 4, !tbaa !9
  %299 = icmp ne i32 %297, %298
  br i1 %299, label %300, label %307

300:                                              ; preds = %296
  %301 = load i32, ptr %46, align 4, !tbaa !9
  %302 = load i32, ptr %11, align 4, !tbaa !9
  %303 = icmp ne i32 %301, %302
  br i1 %303, label %304, label %307

304:                                              ; preds = %300
  %305 = load i32, ptr %46, align 4, !tbaa !9
  invoke void @_ZNK3JPH19ConvexHullBuilder2D17AssignPointToEdgeEiRKNS_5ArrayIPNS0_4EdgeENS_12STLAllocatorIS3_EEEE(ptr noundef nonnull align 8 dereferenceable(20) %73, i32 noundef %305, ptr noundef nonnull align 8 dereferenceable(24) %38)
          to label %306 unwind label %288

306:                                              ; preds = %304
  br label %307

307:                                              ; preds = %306, %300, %296, %292
  br label %308

308:                                              ; preds = %307
  %309 = load i32, ptr %46, align 4, !tbaa !9
  %310 = add nsw i32 %309, 1
  store i32 %310, ptr %46, align 4, !tbaa !9
  br label %279, !llvm.loop !30

311:                                              ; preds = %287
  invoke void @_ZNK3JPH19ConvexHullBuilder2D13ValidateEdgesEv(ptr noundef nonnull align 8 dereferenceable(20) %73)
          to label %312 unwind label %319

312:                                              ; preds = %311
  br label %313

313:                                              ; preds = %596, %312
  %314 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D", ptr %73, i32 0, i32 2
  %315 = load i32, ptr %314, align 8, !tbaa !26
  %316 = load i32, ptr %12, align 4, !tbaa !9
  %317 = icmp sge i32 %315, %316
  br i1 %317, label %318, label %323

318:                                              ; preds = %313
  store i32 1, ptr %15, align 4, !tbaa !13
  br label %607

319:                                              ; preds = %607, %311
  %320 = landingpad { ptr, i32 }
          cleanup
  %321 = extractvalue { ptr, i32 } %320, 0
  store ptr %321, ptr %34, align 8
  %322 = extractvalue { ptr, i32 } %320, 1
  store i32 %322, ptr %35, align 4
  br label %634

323:                                              ; preds = %313
  call void @llvm.lifetime.start.p0(i64 8, ptr %47) #9
  store ptr null, ptr %47, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %48) #9
  store float 0.000000e+00, ptr %48, align 4, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 8, ptr %49) #9
  %324 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D", ptr %73, i32 0, i32 1
  %325 = load ptr, ptr %324, align 8, !tbaa !25
  store ptr %325, ptr %49, align 8, !tbaa !5
  br label %326

326:                                              ; preds = %341, %323
  %327 = load ptr, ptr %49, align 8, !tbaa !5
  %328 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D::Edge", ptr %327, i32 0, i32 6
  %329 = load float, ptr %328, align 4, !tbaa !32
  %330 = load float, ptr %48, align 4, !tbaa !11
  %331 = fcmp ogt float %329, %330
  br i1 %331, label %332, label %337

332:                                              ; preds = %326
  %333 = load ptr, ptr %49, align 8, !tbaa !5
  %334 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D::Edge", ptr %333, i32 0, i32 6
  %335 = load float, ptr %334, align 4, !tbaa !32
  store float %335, ptr %48, align 4, !tbaa !11
  %336 = load ptr, ptr %49, align 8, !tbaa !5
  store ptr %336, ptr %47, align 8, !tbaa !5
  br label %337

337:                                              ; preds = %332, %326
  %338 = load ptr, ptr %49, align 8, !tbaa !5
  %339 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D::Edge", ptr %338, i32 0, i32 4
  %340 = load ptr, ptr %339, align 16, !tbaa !19
  store ptr %340, ptr %49, align 8, !tbaa !5
  br label %341

341:                                              ; preds = %337
  %342 = load ptr, ptr %49, align 8, !tbaa !5
  %343 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D", ptr %73, i32 0, i32 1
  %344 = load ptr, ptr %343, align 8, !tbaa !25
  %345 = icmp ne ptr %342, %344
  br i1 %345, label %326, label %346, !llvm.loop !33

346:                                              ; preds = %341
  %347 = load ptr, ptr %47, align 8, !tbaa !5
  %348 = icmp eq ptr %347, null
  br i1 %348, label %353, label %349

349:                                              ; preds = %346
  %350 = load float, ptr %48, align 4, !tbaa !11
  %351 = load float, ptr %25, align 4, !tbaa !11
  %352 = fcmp olt float %350, %351
  br i1 %352, label %353, label %354

353:                                              ; preds = %349, %346
  store i32 9, ptr %50, align 4
  br label %594

354:                                              ; preds = %349
  call void @llvm.lifetime.start.p0(i64 4, ptr %51) #9
  %355 = load ptr, ptr %47, align 8, !tbaa !5
  %356 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D::Edge", ptr %355, i32 0, i32 2
  %357 = invoke noundef nonnull align 4 dereferenceable(4) ptr @_ZN3JPH5ArrayIiNS_12STLAllocatorIiEEE4backEv(ptr noundef nonnull align 8 dereferenceable(24) %356)
          to label %358 unwind label %382

358:                                              ; preds = %354
  %359 = load i32, ptr %357, align 4, !tbaa !9
  store i32 %359, ptr %51, align 4, !tbaa !9
  %360 = load ptr, ptr %47, align 8, !tbaa !5
  %361 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D::Edge", ptr %360, i32 0, i32 2
  invoke void @_ZN3JPH5ArrayIiNS_12STLAllocatorIiEEE8pop_backEv(ptr noundef nonnull align 8 dereferenceable(24) %361)
          to label %362 unwind label %382

362:                                              ; preds = %358
  call void @llvm.lifetime.start.p0(i64 16, ptr %52) #9
  %363 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D", ptr %73, i32 0, i32 0
  %364 = load ptr, ptr %363, align 8, !tbaa !15
  %365 = load i32, ptr %51, align 4, !tbaa !9
  %366 = sext i32 %365 to i64
  %367 = invoke noundef nonnull align 16 dereferenceable(16) ptr @_ZNK3JPH5ArrayINS_4Vec3ENS_12STLAllocatorIS1_EEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %364, i64 noundef %366)
          to label %368 unwind label %386

368:                                              ; preds = %362
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 %52, ptr align 16 %367, i64 16, i1 false), !tbaa.struct !17
  call void @llvm.lifetime.start.p0(i64 8, ptr %53) #9
  %369 = load ptr, ptr %47, align 8, !tbaa !5
  store ptr %369, ptr %53, align 8, !tbaa !5
  br label %370

370:                                              ; preds = %399, %368
  call void @llvm.lifetime.start.p0(i64 8, ptr %54) #9
  %371 = load ptr, ptr %53, align 8, !tbaa !5
  %372 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D::Edge", ptr %371, i32 0, i32 3
  %373 = load ptr, ptr %372, align 8, !tbaa !24
  store ptr %373, ptr %54, align 8, !tbaa !5
  %374 = load ptr, ptr %54, align 8, !tbaa !5
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 %55, ptr align 16 %52, i64 16, i1 false), !tbaa.struct !17
  %375 = getelementptr inbounds { double, double }, ptr %55, i32 0, i32 0
  %376 = load double, ptr %375, align 16
  %377 = getelementptr inbounds { double, double }, ptr %55, i32 0, i32 1
  %378 = load double, ptr %377, align 8
  %379 = invoke noundef zeroext i1 @_ZNK3JPH19ConvexHullBuilder2D4Edge8IsFacingENS_4Vec3E(ptr noundef nonnull align 16 dereferenceable(80) %374, double %376, double %378)
          to label %380 unwind label %390

380:                                              ; preds = %370
  br i1 %379, label %394, label %381

381:                                              ; preds = %380
  store i32 13, ptr %50, align 4
  br label %396

382:                                              ; preds = %358, %354
  %383 = landingpad { ptr, i32 }
          cleanup
  %384 = extractvalue { ptr, i32 } %383, 0
  store ptr %384, ptr %34, align 8
  %385 = extractvalue { ptr, i32 } %383, 1
  store i32 %385, ptr %35, align 4
  br label %606

386:                                              ; preds = %362
  %387 = landingpad { ptr, i32 }
          cleanup
  %388 = extractvalue { ptr, i32 } %387, 0
  store ptr %388, ptr %34, align 8
  %389 = extractvalue { ptr, i32 } %387, 1
  store i32 %389, ptr %35, align 4
  br label %605

390:                                              ; preds = %370
  %391 = landingpad { ptr, i32 }
          cleanup
  %392 = extractvalue { ptr, i32 } %391, 0
  store ptr %392, ptr %34, align 8
  %393 = extractvalue { ptr, i32 } %391, 1
  store i32 %393, ptr %35, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %54) #9
  br label %604

394:                                              ; preds = %380
  %395 = load ptr, ptr %54, align 8, !tbaa !5
  store ptr %395, ptr %53, align 8, !tbaa !5
  store i32 0, ptr %50, align 4
  br label %396

396:                                              ; preds = %394, %381
  call void @llvm.lifetime.end.p0(i64 8, ptr %54) #9
  %397 = load i32, ptr %50, align 4
  switch i32 %397, label %643 [
    i32 0, label %398
    i32 13, label %403
  ]

398:                                              ; preds = %396
  br label %399

399:                                              ; preds = %398
  %400 = load ptr, ptr %53, align 8, !tbaa !5
  %401 = load ptr, ptr %47, align 8, !tbaa !5
  %402 = icmp ne ptr %400, %401
  br i1 %402, label %370, label %403, !llvm.loop !34

403:                                              ; preds = %399, %396
  call void @llvm.lifetime.start.p0(i64 8, ptr %56) #9
  %404 = load ptr, ptr %47, align 8, !tbaa !5
  store ptr %404, ptr %56, align 8, !tbaa !5
  br label %405

405:                                              ; preds = %426, %403
  call void @llvm.lifetime.start.p0(i64 8, ptr %57) #9
  %406 = load ptr, ptr %56, align 8, !tbaa !5
  %407 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D::Edge", ptr %406, i32 0, i32 4
  %408 = load ptr, ptr %407, align 16, !tbaa !19
  store ptr %408, ptr %57, align 8, !tbaa !5
  %409 = load ptr, ptr %57, align 8, !tbaa !5
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 %58, ptr align 16 %52, i64 16, i1 false), !tbaa.struct !17
  %410 = getelementptr inbounds { double, double }, ptr %58, i32 0, i32 0
  %411 = load double, ptr %410, align 16
  %412 = getelementptr inbounds { double, double }, ptr %58, i32 0, i32 1
  %413 = load double, ptr %412, align 8
  %414 = invoke noundef zeroext i1 @_ZNK3JPH19ConvexHullBuilder2D4Edge8IsFacingENS_4Vec3E(ptr noundef nonnull align 16 dereferenceable(80) %409, double %411, double %413)
          to label %415 unwind label %417

415:                                              ; preds = %405
  br i1 %414, label %421, label %416

416:                                              ; preds = %415
  store i32 15, ptr %50, align 4
  br label %423

417:                                              ; preds = %405
  %418 = landingpad { ptr, i32 }
          cleanup
  %419 = extractvalue { ptr, i32 } %418, 0
  store ptr %419, ptr %34, align 8
  %420 = extractvalue { ptr, i32 } %418, 1
  store i32 %420, ptr %35, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %57) #9
  br label %603

421:                                              ; preds = %415
  %422 = load ptr, ptr %57, align 8, !tbaa !5
  store ptr %422, ptr %56, align 8, !tbaa !5
  store i32 0, ptr %50, align 4
  br label %423

423:                                              ; preds = %421, %416
  call void @llvm.lifetime.end.p0(i64 8, ptr %57) #9
  %424 = load i32, ptr %50, align 4
  switch i32 %424, label %643 [
    i32 0, label %425
    i32 15, label %430
  ]

425:                                              ; preds = %423
  br label %426

426:                                              ; preds = %425
  %427 = load ptr, ptr %56, align 8, !tbaa !5
  %428 = load ptr, ptr %47, align 8, !tbaa !5
  %429 = icmp ne ptr %427, %428
  br i1 %429, label %405, label %430, !llvm.loop !35

430:                                              ; preds = %426, %423
  %431 = invoke noundef ptr @_ZN3JPH19ConvexHullBuilder2D4EdgenwEm(i64 noundef 80)
          to label %432 unwind label %493

432:                                              ; preds = %430
  %433 = load ptr, ptr %53, align 8, !tbaa !5
  %434 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D::Edge", ptr %433, i32 0, i32 5
  %435 = load i32, ptr %434, align 8, !tbaa !36
  invoke void @_ZN3JPH19ConvexHullBuilder2D4EdgeC2Ei(ptr noundef nonnull align 16 dereferenceable(80) %431, i32 noundef %435)
          to label %436 unwind label %497

436:                                              ; preds = %432
  store ptr %431, ptr %33, align 8, !tbaa !5
  %437 = invoke noundef ptr @_ZN3JPH19ConvexHullBuilder2D4EdgenwEm(i64 noundef 80)
          to label %438 unwind label %493

438:                                              ; preds = %436
  %439 = load i32, ptr %51, align 4, !tbaa !9
  invoke void @_ZN3JPH19ConvexHullBuilder2D4EdgeC2Ei(ptr noundef nonnull align 16 dereferenceable(80) %437, i32 noundef %439)
          to label %440 unwind label %501

440:                                              ; preds = %438
  store ptr %437, ptr %36, align 8, !tbaa !5
  %441 = load ptr, ptr %36, align 8, !tbaa !5
  %442 = load ptr, ptr %33, align 8, !tbaa !5
  %443 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D::Edge", ptr %442, i32 0, i32 4
  store ptr %441, ptr %443, align 16, !tbaa !19
  %444 = load ptr, ptr %53, align 8, !tbaa !5
  %445 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D::Edge", ptr %444, i32 0, i32 3
  %446 = load ptr, ptr %445, align 8, !tbaa !24
  %447 = load ptr, ptr %33, align 8, !tbaa !5
  %448 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D::Edge", ptr %447, i32 0, i32 3
  store ptr %446, ptr %448, align 8, !tbaa !24
  %449 = load ptr, ptr %33, align 8, !tbaa !5
  %450 = load ptr, ptr %36, align 8, !tbaa !5
  %451 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D::Edge", ptr %450, i32 0, i32 3
  store ptr %449, ptr %451, align 8, !tbaa !24
  %452 = load ptr, ptr %56, align 8, !tbaa !5
  %453 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D::Edge", ptr %452, i32 0, i32 4
  %454 = load ptr, ptr %453, align 16, !tbaa !19
  %455 = load ptr, ptr %36, align 8, !tbaa !5
  %456 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D::Edge", ptr %455, i32 0, i32 4
  store ptr %454, ptr %456, align 16, !tbaa !19
  %457 = load ptr, ptr %33, align 8, !tbaa !5
  %458 = load ptr, ptr %33, align 8, !tbaa !5
  %459 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D::Edge", ptr %458, i32 0, i32 3
  %460 = load ptr, ptr %459, align 8, !tbaa !24
  %461 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D::Edge", ptr %460, i32 0, i32 4
  store ptr %457, ptr %461, align 16, !tbaa !19
  %462 = load ptr, ptr %36, align 8, !tbaa !5
  %463 = load ptr, ptr %36, align 8, !tbaa !5
  %464 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D::Edge", ptr %463, i32 0, i32 4
  %465 = load ptr, ptr %464, align 16, !tbaa !19
  %466 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D::Edge", ptr %465, i32 0, i32 3
  store ptr %462, ptr %466, align 8, !tbaa !24
  %467 = load ptr, ptr %33, align 8, !tbaa !5
  %468 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D", ptr %73, i32 0, i32 1
  store ptr %467, ptr %468, align 8, !tbaa !25
  %469 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D", ptr %73, i32 0, i32 2
  %470 = load i32, ptr %469, align 8, !tbaa !26
  %471 = add nsw i32 %470, 2
  store i32 %471, ptr %469, align 8, !tbaa !26
  call void @llvm.lifetime.start.p0(i64 24, ptr %59) #9
  call void @llvm.lifetime.start.p0(i64 16, ptr %61) #9
  %472 = load ptr, ptr %33, align 8, !tbaa !5
  store ptr %472, ptr %61, align 8, !tbaa !5
  %473 = getelementptr inbounds ptr, ptr %61, i64 1
  %474 = load ptr, ptr %36, align 8, !tbaa !5
  store ptr %474, ptr %473, align 8, !tbaa !5
  %475 = getelementptr inbounds %"class.std::initializer_list", ptr %60, i32 0, i32 0
  store ptr %61, ptr %475, align 8, !tbaa !27
  %476 = getelementptr inbounds %"class.std::initializer_list", ptr %60, i32 0, i32 1
  store i64 2, ptr %476, align 8, !tbaa !29
  call void @llvm.lifetime.start.p0(i64 1, ptr %62) #9
  %477 = getelementptr inbounds { ptr, i64 }, ptr %60, i32 0, i32 0
  %478 = load ptr, ptr %477, align 8
  %479 = getelementptr inbounds { ptr, i64 }, ptr %60, i32 0, i32 1
  %480 = load i64, ptr %479, align 8
  invoke void @_ZN3JPH5ArrayIPNS_19ConvexHullBuilder2D4EdgeENS_12STLAllocatorIS3_EEEC2ESt16initializer_listIS3_ERKS5_(ptr noundef nonnull align 8 dereferenceable(24) %59, ptr %478, i64 %480, ptr noundef nonnull align 1 dereferenceable(1) %62)
          to label %481 unwind label %505

481:                                              ; preds = %440
  call void @llvm.lifetime.end.p0(i64 1, ptr %62) #9
  call void @llvm.lifetime.end.p0(i64 16, ptr %61) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr %63) #9
  store ptr %59, ptr %63, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %64) #9
  %482 = load ptr, ptr %63, align 8, !tbaa !5
  %483 = invoke noundef ptr @_ZN3JPH5ArrayIPNS_19ConvexHullBuilder2D4EdgeENS_12STLAllocatorIS3_EEE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %482)
          to label %484 unwind label %509

484:                                              ; preds = %481
  store ptr %483, ptr %64, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %65) #9
  %485 = load ptr, ptr %63, align 8, !tbaa !5
  %486 = invoke noundef ptr @_ZN3JPH5ArrayIPNS_19ConvexHullBuilder2D4EdgeENS_12STLAllocatorIS3_EEE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %485)
          to label %487 unwind label %513

487:                                              ; preds = %484
  store ptr %486, ptr %65, align 8, !tbaa !5
  br label %488

488:                                              ; preds = %526, %487
  %489 = load ptr, ptr %64, align 8, !tbaa !5
  %490 = load ptr, ptr %65, align 8, !tbaa !5
  %491 = icmp ne ptr %489, %490
  br i1 %491, label %517, label %492

492:                                              ; preds = %488
  store i32 17, ptr %50, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %65) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %64) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %63) #9
  br label %535

493:                                              ; preds = %436, %430
  %494 = landingpad { ptr, i32 }
          cleanup
  %495 = extractvalue { ptr, i32 } %494, 0
  store ptr %495, ptr %34, align 8
  %496 = extractvalue { ptr, i32 } %494, 1
  store i32 %496, ptr %35, align 4
  br label %603

497:                                              ; preds = %432
  %498 = landingpad { ptr, i32 }
          cleanup
  %499 = extractvalue { ptr, i32 } %498, 0
  store ptr %499, ptr %34, align 8
  %500 = extractvalue { ptr, i32 } %498, 1
  store i32 %500, ptr %35, align 4
  call void @_ZN3JPH19ConvexHullBuilder2D4EdgedlEPv(ptr noundef %431) #9
  br label %603

501:                                              ; preds = %438
  %502 = landingpad { ptr, i32 }
          cleanup
  %503 = extractvalue { ptr, i32 } %502, 0
  store ptr %503, ptr %34, align 8
  %504 = extractvalue { ptr, i32 } %502, 1
  store i32 %504, ptr %35, align 4
  call void @_ZN3JPH19ConvexHullBuilder2D4EdgedlEPv(ptr noundef %437) #9
  br label %603

505:                                              ; preds = %440
  %506 = landingpad { ptr, i32 }
          cleanup
  %507 = extractvalue { ptr, i32 } %506, 0
  store ptr %507, ptr %34, align 8
  %508 = extractvalue { ptr, i32 } %506, 1
  store i32 %508, ptr %35, align 4
  call void @llvm.lifetime.end.p0(i64 1, ptr %62) #9
  call void @llvm.lifetime.end.p0(i64 16, ptr %61) #9
  br label %602

509:                                              ; preds = %481
  %510 = landingpad { ptr, i32 }
          cleanup
  %511 = extractvalue { ptr, i32 } %510, 0
  store ptr %511, ptr %34, align 8
  %512 = extractvalue { ptr, i32 } %510, 1
  store i32 %512, ptr %35, align 4
  br label %534

513:                                              ; preds = %484
  %514 = landingpad { ptr, i32 }
          cleanup
  %515 = extractvalue { ptr, i32 } %514, 0
  store ptr %515, ptr %34, align 8
  %516 = extractvalue { ptr, i32 } %514, 1
  store i32 %516, ptr %35, align 4
  br label %533

517:                                              ; preds = %488
  call void @llvm.lifetime.start.p0(i64 8, ptr %66) #9
  %518 = load ptr, ptr %64, align 8, !tbaa !5
  %519 = load ptr, ptr %518, align 8, !tbaa !5
  store ptr %519, ptr %66, align 8, !tbaa !5
  %520 = load ptr, ptr %66, align 8, !tbaa !5
  %521 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D", ptr %73, i32 0, i32 0
  %522 = load ptr, ptr %521, align 8, !tbaa !15
  %523 = invoke noundef ptr @_ZNK3JPH5ArrayINS_4Vec3ENS_12STLAllocatorIS1_EEE4dataEv(ptr noundef nonnull align 8 dereferenceable(24) %522)
          to label %524 unwind label %529

524:                                              ; preds = %517
  invoke void @_ZN3JPH19ConvexHullBuilder2D4Edge24CalculateNormalAndCenterEPKNS_4Vec3E(ptr noundef nonnull align 16 dereferenceable(80) %520, ptr noundef %523)
          to label %525 unwind label %529

525:                                              ; preds = %524
  call void @llvm.lifetime.end.p0(i64 8, ptr %66) #9
  br label %526

526:                                              ; preds = %525
  %527 = load ptr, ptr %64, align 8, !tbaa !5
  %528 = getelementptr inbounds ptr, ptr %527, i32 1
  store ptr %528, ptr %64, align 8, !tbaa !5
  br label %488

529:                                              ; preds = %524, %517
  %530 = landingpad { ptr, i32 }
          cleanup
  %531 = extractvalue { ptr, i32 } %530, 0
  store ptr %531, ptr %34, align 8
  %532 = extractvalue { ptr, i32 } %530, 1
  store i32 %532, ptr %35, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %66) #9
  br label %533

533:                                              ; preds = %529, %513
  call void @llvm.lifetime.end.p0(i64 8, ptr %65) #9
  br label %534

534:                                              ; preds = %533, %509
  call void @llvm.lifetime.end.p0(i64 8, ptr %64) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %63) #9
  br label %601

535:                                              ; preds = %492
  br label %536

536:                                              ; preds = %591, %535
  call void @llvm.lifetime.start.p0(i64 8, ptr %67) #9
  %537 = load ptr, ptr %53, align 8, !tbaa !5
  %538 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D::Edge", ptr %537, i32 0, i32 4
  %539 = load ptr, ptr %538, align 16, !tbaa !19
  store ptr %539, ptr %67, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %68) #9
  %540 = load ptr, ptr %53, align 8, !tbaa !5
  %541 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D::Edge", ptr %540, i32 0, i32 2
  store ptr %541, ptr %68, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %69) #9
  %542 = load ptr, ptr %68, align 8, !tbaa !5
  %543 = invoke noundef ptr @_ZN3JPH5ArrayIiNS_12STLAllocatorIiEEE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %542)
          to label %544 unwind label %553

544:                                              ; preds = %536
  store ptr %543, ptr %69, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %70) #9
  %545 = load ptr, ptr %68, align 8, !tbaa !5
  %546 = invoke noundef ptr @_ZN3JPH5ArrayIiNS_12STLAllocatorIiEEE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %545)
          to label %547 unwind label %557

547:                                              ; preds = %544
  store ptr %546, ptr %70, align 8, !tbaa !5
  br label %548

548:                                              ; preds = %566, %547
  %549 = load ptr, ptr %69, align 8, !tbaa !5
  %550 = load ptr, ptr %70, align 8, !tbaa !5
  %551 = icmp ne ptr %549, %550
  br i1 %551, label %561, label %552

552:                                              ; preds = %548
  store i32 21, ptr %50, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %70) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %69) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %68) #9
  br label %575

553:                                              ; preds = %536
  %554 = landingpad { ptr, i32 }
          cleanup
  %555 = extractvalue { ptr, i32 } %554, 0
  store ptr %555, ptr %34, align 8
  %556 = extractvalue { ptr, i32 } %554, 1
  store i32 %556, ptr %35, align 4
  br label %574

557:                                              ; preds = %544
  %558 = landingpad { ptr, i32 }
          cleanup
  %559 = extractvalue { ptr, i32 } %558, 0
  store ptr %559, ptr %34, align 8
  %560 = extractvalue { ptr, i32 } %558, 1
  store i32 %560, ptr %35, align 4
  br label %573

561:                                              ; preds = %548
  call void @llvm.lifetime.start.p0(i64 4, ptr %71) #9
  %562 = load ptr, ptr %69, align 8, !tbaa !5
  %563 = load i32, ptr %562, align 4, !tbaa !9
  store i32 %563, ptr %71, align 4, !tbaa !9
  %564 = load i32, ptr %71, align 4, !tbaa !9
  invoke void @_ZNK3JPH19ConvexHullBuilder2D17AssignPointToEdgeEiRKNS_5ArrayIPNS0_4EdgeENS_12STLAllocatorIS3_EEEE(ptr noundef nonnull align 8 dereferenceable(20) %73, i32 noundef %564, ptr noundef nonnull align 8 dereferenceable(24) %59)
          to label %565 unwind label %569

565:                                              ; preds = %561
  call void @llvm.lifetime.end.p0(i64 4, ptr %71) #9
  br label %566

566:                                              ; preds = %565
  %567 = load ptr, ptr %69, align 8, !tbaa !5
  %568 = getelementptr inbounds i32, ptr %567, i32 1
  store ptr %568, ptr %69, align 8, !tbaa !5
  br label %548

569:                                              ; preds = %561
  %570 = landingpad { ptr, i32 }
          cleanup
  %571 = extractvalue { ptr, i32 } %570, 0
  store ptr %571, ptr %34, align 8
  %572 = extractvalue { ptr, i32 } %570, 1
  store i32 %572, ptr %35, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %71) #9
  br label %573

573:                                              ; preds = %569, %557
  call void @llvm.lifetime.end.p0(i64 8, ptr %70) #9
  br label %574

574:                                              ; preds = %573, %553
  call void @llvm.lifetime.end.p0(i64 8, ptr %69) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %68) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %67) #9
  br label %601

575:                                              ; preds = %552
  %576 = load ptr, ptr %53, align 8, !tbaa !5
  %577 = icmp eq ptr %576, null
  br i1 %577, label %579, label %578

578:                                              ; preds = %575
  call void @_ZN3JPH19ConvexHullBuilder2D4EdgeD2Ev(ptr noundef nonnull align 16 dereferenceable(80) %576) #9
  call void @_ZN3JPH19ConvexHullBuilder2D4EdgedlEPv(ptr noundef %576) #9
  br label %579

579:                                              ; preds = %578, %575
  %580 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D", ptr %73, i32 0, i32 2
  %581 = load i32, ptr %580, align 8, !tbaa !26
  %582 = add nsw i32 %581, -1
  store i32 %582, ptr %580, align 8, !tbaa !26
  %583 = load ptr, ptr %53, align 8, !tbaa !5
  %584 = load ptr, ptr %56, align 8, !tbaa !5
  %585 = icmp eq ptr %583, %584
  br i1 %585, label %586, label %587

586:                                              ; preds = %579
  store i32 19, ptr %50, align 4
  br label %589

587:                                              ; preds = %579
  %588 = load ptr, ptr %67, align 8, !tbaa !5
  store ptr %588, ptr %53, align 8, !tbaa !5
  store i32 0, ptr %50, align 4
  br label %589

589:                                              ; preds = %587, %586
  call void @llvm.lifetime.end.p0(i64 8, ptr %67) #9
  %590 = load i32, ptr %50, align 4
  switch i32 %590, label %643 [
    i32 0, label %591
    i32 19, label %592
  ]

591:                                              ; preds = %589
  br label %536, !llvm.loop !37

592:                                              ; preds = %589
  invoke void @_ZNK3JPH19ConvexHullBuilder2D13ValidateEdgesEv(ptr noundef nonnull align 8 dereferenceable(20) %73)
          to label %593 unwind label %597

593:                                              ; preds = %592
  call void @_ZN3JPH5ArrayIPNS_19ConvexHullBuilder2D4EdgeENS_12STLAllocatorIS3_EEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %59) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr %59) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %56) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %53) #9
  call void @llvm.lifetime.end.p0(i64 16, ptr %52) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %51) #9
  store i32 0, ptr %50, align 4
  br label %594

594:                                              ; preds = %593, %353
  call void @llvm.lifetime.end.p0(i64 8, ptr %49) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %48) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %47) #9
  %595 = load i32, ptr %50, align 4
  switch i32 %595, label %643 [
    i32 0, label %596
    i32 9, label %607
  ]

596:                                              ; preds = %594
  br label %313, !llvm.loop !38

597:                                              ; preds = %592
  %598 = landingpad { ptr, i32 }
          cleanup
  %599 = extractvalue { ptr, i32 } %598, 0
  store ptr %599, ptr %34, align 8
  %600 = extractvalue { ptr, i32 } %598, 1
  store i32 %600, ptr %35, align 4
  br label %601

601:                                              ; preds = %597, %574, %534
  call void @_ZN3JPH5ArrayIPNS_19ConvexHullBuilder2D4EdgeENS_12STLAllocatorIS3_EEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %59) #9
  br label %602

602:                                              ; preds = %601, %505
  call void @llvm.lifetime.end.p0(i64 24, ptr %59) #9
  br label %603

603:                                              ; preds = %602, %501, %497, %493, %417
  call void @llvm.lifetime.end.p0(i64 8, ptr %56) #9
  br label %604

604:                                              ; preds = %603, %390
  call void @llvm.lifetime.end.p0(i64 8, ptr %53) #9
  br label %605

605:                                              ; preds = %604, %386
  call void @llvm.lifetime.end.p0(i64 16, ptr %52) #9
  br label %606

606:                                              ; preds = %605, %382
  call void @llvm.lifetime.end.p0(i64 4, ptr %51) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %49) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %48) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %47) #9
  br label %634

607:                                              ; preds = %594, %318
  %608 = load ptr, ptr %14, align 8, !tbaa !5
  %609 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D", ptr %73, i32 0, i32 2
  %610 = load i32, ptr %609, align 8, !tbaa !26
  %611 = sext i32 %610 to i64
  invoke void @_ZN3JPH5ArrayIiNS_12STLAllocatorIiEEE7reserveEm(ptr noundef nonnull align 8 dereferenceable(24) %608, i64 noundef %611)
          to label %612 unwind label %319

612:                                              ; preds = %607
  call void @llvm.lifetime.start.p0(i64 8, ptr %72) #9
  %613 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D", ptr %73, i32 0, i32 1
  %614 = load ptr, ptr %613, align 8, !tbaa !25
  store ptr %614, ptr %72, align 8, !tbaa !5
  br label %615

615:                                              ; preds = %623, %612
  %616 = load ptr, ptr %14, align 8, !tbaa !5
  %617 = load ptr, ptr %72, align 8, !tbaa !5
  %618 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D::Edge", ptr %617, i32 0, i32 5
  invoke void @_ZN3JPH5ArrayIiNS_12STLAllocatorIiEEE9push_backERKi(ptr noundef nonnull align 8 dereferenceable(24) %616, ptr noundef nonnull align 4 dereferenceable(4) %618)
          to label %619 unwind label %630

619:                                              ; preds = %615
  %620 = load ptr, ptr %72, align 8, !tbaa !5
  %621 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D::Edge", ptr %620, i32 0, i32 4
  %622 = load ptr, ptr %621, align 16, !tbaa !19
  store ptr %622, ptr %72, align 8, !tbaa !5
  br label %623

623:                                              ; preds = %619
  %624 = load ptr, ptr %72, align 8, !tbaa !5
  %625 = getelementptr inbounds %"class.JPH::ConvexHullBuilder2D", ptr %73, i32 0, i32 1
  %626 = load ptr, ptr %625, align 8, !tbaa !25
  %627 = icmp ne ptr %624, %626
  br i1 %627, label %615, label %628, !llvm.loop !39

628:                                              ; preds = %623
  %629 = load i32, ptr %15, align 4, !tbaa !13
  store i32 1, ptr %50, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %72) #9
  call void @_ZN3JPH5ArrayIPNS_19ConvexHullBuilder2D4EdgeENS_12STLAllocatorIS3_EEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %38) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr %38) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %37) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %36) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %33) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %27) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %25) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %24) #9
  call void @llvm.lifetime.end.p0(i64 16, ptr %16) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %15) #9
  ret i32 %629

630:                                              ; preds = %615
  %631 = landingpad { ptr, i32 }
          cleanup
  %632 = extractvalue { ptr, i32 } %631, 0
  store ptr %632, ptr %34, align 8
  %633 = extractvalue { ptr, i32 } %631, 1
  store i32 %633, ptr %35, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %72) #9
  br label %634

634:                                              ; preds = %630, %606, %319, %288, %277
  call void @_ZN3JPH5ArrayIPNS_19ConvexHullBuilder2D4EdgeENS_12STLAllocatorIS3_EEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %38) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr %38) #9
  br label %635

635:                                              ; preds = %634, %248
  call void @llvm.lifetime.end.p0(i64 8, ptr %37) #9
  br label %636

636:                                              ; preds = %635, %244
  call void @llvm.lifetime.end.p0(i64 8, ptr %36) #9
  br label %637

637:                                              ; preds = %636, %240
  call void @llvm.lifetime.end.p0(i64 8, ptr %33) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %27) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %25) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %24) #9
  call void @llvm.lifetime.end.p0(i64 16, ptr %16) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %15) #9
  br label %638

638:                                              ; preds = %637
  %639 = load ptr, ptr %34, align 8
  %640 = load i32, ptr %35, align 4
  %641 = insertvalue { ptr, i32 } poison, ptr %639, 0
  %642 = insertvalue { ptr, i32 } %641, i32 %640, 1
  resume { ptr, i32 } %642

643:                                              ; preds = %594, %589, %423, %396
  unreachable
}

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

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

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

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

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

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3maxIfERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4), ptr noundef nonnull align 4 dereferenceable(4)) #6

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZSt4swapIiENSt9enable_ifIXsr6__and_ISt6__not_ISt15__is_tuple_likeIT_EESt21is_move_constructibleIS3_ESt18is_move_assignableIS3_EEE5valueEvE4typeERS3_SC_(ptr noundef nonnull align 4 dereferenceable(4), ptr noundef nonnull align 4 dereferenceable(4)) #6

; Function Attrs: alwaysinline mustprogress uwtable
declare dso_local noundef ptr @_ZN3JPH19ConvexHullBuilder2D4EdgenwEm(i64 noundef) #8 align 2

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

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZN3JPH5ArrayIPNS_19ConvexHullBuilder2D4EdgeENS_12STLAllocatorIS3_EEEC2ESt16initializer_listIS3_ERKS5_(ptr noundef nonnull align 8 dereferenceable(24), ptr, i64, ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #7 align 2

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

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

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

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

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

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

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef zeroext i1 @_ZNK3JPH19ConvexHullBuilder2D4Edge8IsFacingENS_4Vec3E(ptr noundef nonnull align 16 dereferenceable(80), double, double) #7 align 2

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

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

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

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 = { 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 #4 = { 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 #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 = { 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 #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 = { 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 #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 = !{!14, !14, i64 0}
!14 = !{!"_ZTSN3JPH19ConvexHullBuilder2D7EResultE", !7, i64 0}
!15 = !{!16, !6, i64 0}
!16 = !{!"_ZTSN3JPH19ConvexHullBuilder2DE", !6, i64 0, !6, i64 8, !10, i64 16}
!17 = !{i64 0, i64 16, !18}
!18 = !{!7, !7, i64 0}
!19 = !{!20, !6, i64 64}
!20 = !{!"_ZTSN3JPH19ConvexHullBuilder2D4EdgeE", !21, i64 0, !21, i64 16, !22, i64 32, !6, i64 56, !6, i64 64, !10, i64 72, !12, i64 76}
!21 = !{!"_ZTSN3JPH4Vec3E", !7, i64 0}
!22 = !{!"_ZTSN3JPH5ArrayIiNS_12STLAllocatorIiEEEE", !23, i64 0, !23, i64 8, !6, i64 16}
!23 = !{!"long", !7, i64 0}
!24 = !{!20, !6, i64 56}
!25 = !{!16, !6, i64 8}
!26 = !{!16, !10, i64 16}
!27 = !{!28, !6, i64 0}
!28 = !{!"_ZTSSt16initializer_listIPN3JPH19ConvexHullBuilder2D4EdgeEE", !6, i64 0, !23, i64 8}
!29 = !{!28, !23, i64 8}
!30 = distinct !{!30, !31}
!31 = !{!"llvm.loop.mustprogress"}
!32 = !{!20, !12, i64 76}
!33 = distinct !{!33, !31}
!34 = distinct !{!34, !31}
!35 = distinct !{!35, !31}
!36 = !{!20, !10, i64 72}
!37 = distinct !{!37, !31}
!38 = distinct !{!38, !31}
!39 = distinct !{!39, !31}


; 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 }
%union.anon = type { <4 x float> }
%"class.JPH::Array.3" = type { i64, i64, ptr }
%"class.JPH::STLAllocator.4" = type { i8 }

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

declare i32 @__gxx_personality_v0(...)

; 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 void @_ZN3JPH19ConvexHullBuilder2D4Edge24CalculateNormalAndCenterEPKNS_4Vec3E(ptr noundef nonnull align 16 dereferenceable(80), ptr noundef) local_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: alwaysinline mustprogress uwtable
declare dso_local { double, double } @_ZNK3JPH4Vec3miES0_(ptr noundef nonnull align 16 dereferenceable(16), double, double) local_unnamed_addr #3 align 2

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

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZN3JPH19ConvexHullBuilder2D4EdgeD2Ev(ptr noundef nonnull align 16 dereferenceable(80)) unnamed_addr #6 align 2

; Function Attrs: alwaysinline mustprogress nounwind uwtable
declare dso_local void @_ZN3JPH19ConvexHullBuilder2D4EdgedlEPv(ptr noundef) local_unnamed_addr #4 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNK3JPH19ConvexHullBuilder2D13ValidateEdgesEv(ptr noundef nonnull align 8 dereferenceable(20)) local_unnamed_addr #1 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNK3JPH19ConvexHullBuilder2D17AssignPointToEdgeEiRKNS_5ArrayIPNS0_4EdgeENS_12STLAllocatorIS3_EEEE(ptr noundef nonnull align 8 dereferenceable(20), i32 noundef, ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #1 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef nonnull align 16 dereferenceable(16) ptr @_ZNK3JPH5ArrayINS_4Vec3ENS_12STLAllocatorIS1_EEEixEm(ptr noundef nonnull align 8 dereferenceable(24), i64 noundef) local_unnamed_addr #7 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZN3JPH5ArrayIiNS_12STLAllocatorIiEEE9push_backERKi(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 4 dereferenceable(4)) local_unnamed_addr #7 align 2

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

; Function Attrs: mustprogress uwtable
define dso_local noundef range(i32 0, 2) i32 @_ZN3JPH19ConvexHullBuilder2D10InitializeEiiiifRNS_5ArrayIiNS_12STLAllocatorIiEEEE(ptr noundef nonnull align 8 dereferenceable(20) %0, i32 noundef %1, i32 noundef %2, i32 noundef %3, i32 noundef %4, float noundef %5, ptr noundef nonnull align 8 dereferenceable(24) %6) local_unnamed_addr #1 align 2 personality ptr @__gxx_personality_v0 {
  %8 = alloca i32, align 4
  %9 = alloca i32, align 4
  %10 = alloca %"class.JPH::Vec3", align 16
  %11 = alloca %"class.JPH::Vec3", align 16
  %12 = alloca float, align 4
  %13 = alloca float, align 4
  %14 = alloca %"class.JPH::Vec3", align 16
  %15 = alloca %"class.JPH::Vec3", align 16
  %16 = alloca %"class.JPH::Array.3", align 8
  %17 = alloca [3 x ptr], align 8
  %18 = alloca %"class.JPH::STLAllocator.4", align 1
  %19 = alloca %"class.JPH::Array.3", align 8
  %20 = alloca [2 x ptr], align 8
  %21 = alloca %"class.JPH::STLAllocator.4", align 1
  store i32 %1, ptr %8, align 4, !tbaa !5
  store i32 %2, ptr %9, align 4, !tbaa !5
  tail call void @_ZN3JPH19ConvexHullBuilder2D9FreeEdgesEv(ptr noundef nonnull align 8 dereferenceable(20) %0)
  tail call void @_ZN3JPH5ArrayIiNS_12STLAllocatorIiEEE5clearEv(ptr noundef nonnull align 8 dereferenceable(24) %6)
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %10) #9
  %22 = tail call { double, double } @_ZN3JPH4Vec35sZeroEv()
  %23 = extractvalue { double, double } %22, 0
  store double %23, ptr %10, align 16
  %24 = getelementptr inbounds i8, ptr %10, i64 8
  %25 = extractvalue { double, double } %22, 1
  store double %25, ptr %24, align 8
  %26 = load ptr, ptr %0, align 8, !tbaa !9
  %27 = tail call noundef ptr @_ZNK3JPH5ArrayINS_4Vec3ENS_12STLAllocatorIS1_EEE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %26)
  %28 = tail call noundef ptr @_ZNK3JPH5ArrayINS_4Vec3ENS_12STLAllocatorIS1_EEE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %26)
  %.not197 = icmp eq ptr %27, %28
  br i1 %.not197, label %._crit_edge, label %.lr.ph

._crit_edge:                                      ; preds = %.lr.ph, %7
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %12) #9
  %29 = call noundef float @_ZNK3JPH4Vec34GetXEv(ptr noundef nonnull align 16 dereferenceable(16) %10)
  %30 = call noundef float @_ZNK3JPH4Vec34GetYEv(ptr noundef nonnull align 16 dereferenceable(16) %10)
  %31 = fadd float %29, %30
  %32 = fmul float %31, 0x3E90000000000000
  %33 = call noundef float @_ZN3JPH6SquareIfEET_S1_(float noundef %32)
  store float %33, ptr %12, align 4, !tbaa !12
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %13) #9
  %34 = call noundef float @_ZN3JPH6SquareIfEET_S1_(float noundef %5)
  store float %34, ptr %13, align 4, !tbaa !12
  %35 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3maxIfERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %12, ptr noundef nonnull align 4 dereferenceable(4) %13)
  %36 = load float, ptr %35, align 4, !tbaa !12
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %13) #9
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %14) #9
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %15) #9
  %37 = load ptr, ptr %0, align 8, !tbaa !9
  %38 = load i32, ptr %9, align 4, !tbaa !5
  %39 = sext i32 %38 to i64
  %40 = call noundef nonnull align 16 dereferenceable(16) ptr @_ZNK3JPH5ArrayINS_4Vec3ENS_12STLAllocatorIS1_EEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %37, i64 noundef %39)
  %41 = load ptr, ptr %0, align 8, !tbaa !9
  %42 = load i32, ptr %8, align 4, !tbaa !5
  %43 = sext i32 %42 to i64
  %44 = call noundef nonnull align 16 dereferenceable(16) ptr @_ZNK3JPH5ArrayINS_4Vec3ENS_12STLAllocatorIS1_EEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %41, i64 noundef %43)
  %.sroa.0108.0.copyload = load double, ptr %44, align 16
  %.sroa.2109.0..sroa_idx = getelementptr inbounds i8, ptr %44, i64 8
  %.sroa.2109.0.copyload = load double, ptr %.sroa.2109.0..sroa_idx, align 8, !tbaa !14
  %45 = call { double, double } @_ZNK3JPH4Vec3miES0_(ptr noundef nonnull align 16 dereferenceable(16) %40, double %.sroa.0108.0.copyload, double %.sroa.2109.0.copyload)
  %46 = extractvalue { double, double } %45, 0
  store double %46, ptr %15, align 16
  %47 = getelementptr inbounds i8, ptr %15, i64 8
  %48 = extractvalue { double, double } %45, 1
  store double %48, ptr %47, align 8
  %49 = load ptr, ptr %0, align 8, !tbaa !9
  %50 = sext i32 %3 to i64
  %51 = call noundef nonnull align 16 dereferenceable(16) ptr @_ZNK3JPH5ArrayINS_4Vec3ENS_12STLAllocatorIS1_EEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %49, i64 noundef %50)
  %52 = load ptr, ptr %0, align 8, !tbaa !9
  %53 = load i32, ptr %8, align 4, !tbaa !5
  %54 = sext i32 %53 to i64
  %55 = call noundef nonnull align 16 dereferenceable(16) ptr @_ZNK3JPH5ArrayINS_4Vec3ENS_12STLAllocatorIS1_EEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %52, i64 noundef %54)
  %.sroa.0104.0.copyload = load double, ptr %55, align 16
  %.sroa.2105.0..sroa_idx = getelementptr inbounds i8, ptr %55, i64 8
  %.sroa.2105.0.copyload = load double, ptr %.sroa.2105.0..sroa_idx, align 8, !tbaa !14
  %56 = call { double, double } @_ZNK3JPH4Vec3miES0_(ptr noundef nonnull align 16 dereferenceable(16) %51, double %.sroa.0104.0.copyload, double %.sroa.2105.0.copyload)
  %57 = extractvalue { double, double } %56, 0
  %58 = extractvalue { double, double } %56, 1
  %59 = call { double, double } @_ZNK3JPH4Vec35CrossES0_(ptr noundef nonnull align 16 dereferenceable(16) %15, double %57, double %58)
  %60 = extractvalue { double, double } %59, 0
  store double %60, ptr %14, align 16
  %61 = getelementptr inbounds i8, ptr %14, i64 8
  %62 = extractvalue { double, double } %59, 1
  store double %62, ptr %61, align 8
  %63 = call noundef float @_ZNK3JPH4Vec34GetZEv(ptr noundef nonnull align 16 dereferenceable(16) %14)
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %15) #9
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %14) #9
  %64 = fcmp olt float %63, 0.000000e+00
  br i1 %64, label %72, label %73

.lr.ph:                                           ; preds = %7, %.lr.ph
  %.sroa.2115.0.copyload = phi double [ %70, %.lr.ph ], [ %25, %7 ]
  %.sroa.0114.0.copyload = phi double [ %69, %.lr.ph ], [ %23, %7 ]
  %.0134198 = phi ptr [ %71, %.lr.ph ], [ %27, %7 ]
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %11) #9
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(16) %11, ptr noundef nonnull align 16 dereferenceable(16) %.0134198, i64 16, i1 false), !tbaa.struct !15
  %65 = call { double, double } @_ZNK3JPH4Vec33AbsEv(ptr noundef nonnull align 16 dereferenceable(16) %11)
  %66 = extractvalue { double, double } %65, 0
  %67 = extractvalue { double, double } %65, 1
  %68 = call { double, double } @_ZN3JPH4Vec34sMaxES0_S0_(double %.sroa.0114.0.copyload, double %.sroa.2115.0.copyload, double %66, double %67)
  %69 = extractvalue { double, double } %68, 0
  %70 = extractvalue { double, double } %68, 1
  store double %69, ptr %10, align 16
  store double %70, ptr %24, align 8, !tbaa !14
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %11) #9
  %71 = getelementptr inbounds i8, ptr %.0134198, i64 16
  %.not = icmp eq ptr %71, %28
  br i1 %.not, label %._crit_edge, label %.lr.ph

72:                                               ; preds = %._crit_edge
  call void @_ZSt4swapIiENSt9enable_ifIXsr6__and_ISt6__not_ISt15__is_tuple_likeIT_EESt21is_move_constructibleIS3_ESt18is_move_assignableIS3_EEE5valueEvE4typeERS3_SC_(ptr noundef nonnull align 4 dereferenceable(4) %8, ptr noundef nonnull align 4 dereferenceable(4) %9) #9
  br label %73

73:                                               ; preds = %72, %._crit_edge
  %74 = call noundef ptr @_ZN3JPH19ConvexHullBuilder2D4EdgenwEm(i64 noundef 80)
  %75 = load i32, ptr %8, align 4, !tbaa !5
  call void @_ZN3JPH19ConvexHullBuilder2D4EdgeC2Ei(ptr noundef nonnull align 16 dereferenceable(80) %74, i32 noundef %75)
  %76 = call noundef ptr @_ZN3JPH19ConvexHullBuilder2D4EdgenwEm(i64 noundef 80)
  %77 = load i32, ptr %9, align 4, !tbaa !5
  call void @_ZN3JPH19ConvexHullBuilder2D4EdgeC2Ei(ptr noundef nonnull align 16 dereferenceable(80) %76, i32 noundef %77)
  %78 = call noundef ptr @_ZN3JPH19ConvexHullBuilder2D4EdgenwEm(i64 noundef 80)
  call void @_ZN3JPH19ConvexHullBuilder2D4EdgeC2Ei(ptr noundef nonnull align 16 dereferenceable(80) %78, i32 noundef %3)
  %79 = getelementptr inbounds i8, ptr %74, i64 64
  store ptr %76, ptr %79, align 16, !tbaa !16
  %80 = getelementptr inbounds i8, ptr %74, i64 56
  store ptr %78, ptr %80, align 8, !tbaa !21
  %81 = getelementptr inbounds i8, ptr %76, i64 64
  store ptr %78, ptr %81, align 16, !tbaa !16
  %82 = getelementptr inbounds i8, ptr %76, i64 56
  store ptr %74, ptr %82, align 8, !tbaa !21
  %83 = getelementptr inbounds i8, ptr %78, i64 64
  store ptr %74, ptr %83, align 16, !tbaa !16
  %84 = getelementptr inbounds i8, ptr %78, i64 56
  store ptr %76, ptr %84, align 8, !tbaa !21
  %85 = getelementptr inbounds i8, ptr %0, i64 8
  store ptr %74, ptr %85, align 8, !tbaa !22
  %86 = getelementptr inbounds i8, ptr %0, i64 16
  store i32 3, ptr %86, align 8, !tbaa !23
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %16) #9
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %17) #9
  store ptr %74, ptr %17, align 8, !tbaa !24
  %87 = getelementptr inbounds i8, ptr %17, i64 8
  store ptr %76, ptr %87, align 8, !tbaa !24
  %88 = getelementptr inbounds i8, ptr %17, i64 16
  store ptr %78, ptr %88, align 8, !tbaa !24
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %18) #9
  call void @_ZN3JPH5ArrayIPNS_19ConvexHullBuilder2D4EdgeENS_12STLAllocatorIS3_EEEC2ESt16initializer_listIS3_ERKS5_(ptr noundef nonnull align 8 dereferenceable(24) %16, ptr nonnull %17, i64 3, ptr noundef nonnull align 1 dereferenceable(1) %18)
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %18) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %17) #9
  %89 = call noundef ptr @_ZN3JPH5ArrayIPNS_19ConvexHullBuilder2D4EdgeENS_12STLAllocatorIS3_EEE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %16)
  %90 = call noundef ptr @_ZN3JPH5ArrayIPNS_19ConvexHullBuilder2D4EdgeENS_12STLAllocatorIS3_EEE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %16)
  %.not165199 = icmp eq ptr %89, %90
  br i1 %.not165199, label %.preheader196, label %.lr.ph202

.preheader196:                                    ; preds = %98, %73
  %91 = load ptr, ptr %0, align 8, !tbaa !9
  %92 = call noundef i64 @_ZNK3JPH5ArrayINS_4Vec3ENS_12STLAllocatorIS1_EEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %91)
  %93 = trunc i64 %92 to i32
  %94 = icmp sgt i32 %93, 0
  br i1 %94, label %.lr.ph204, label %._crit_edge205

.lr.ph202:                                        ; preds = %73, %98
  %.0145200 = phi ptr [ %99, %98 ], [ %89, %73 ]
  %95 = load ptr, ptr %.0145200, align 8, !tbaa !24
  %96 = load ptr, ptr %0, align 8, !tbaa !9
  %97 = call noundef ptr @_ZNK3JPH5ArrayINS_4Vec3ENS_12STLAllocatorIS1_EEE4dataEv(ptr noundef nonnull align 8 dereferenceable(24) %96)
  invoke void @_ZN3JPH19ConvexHullBuilder2D4Edge24CalculateNormalAndCenterEPKNS_4Vec3E(ptr noundef nonnull align 16 dereferenceable(80) %95, ptr noundef %97)
          to label %98 unwind label %100

98:                                               ; preds = %.lr.ph202
  %99 = getelementptr inbounds i8, ptr %.0145200, i64 8
  %.not165 = icmp eq ptr %99, %90
  br i1 %.not165, label %.preheader196, label %.lr.ph202

100:                                              ; preds = %.lr.ph202
  %101 = landingpad { ptr, i32 }
          cleanup
  br label %226

._crit_edge205:                                   ; preds = %109, %.preheader196
  invoke void @_ZNK3JPH19ConvexHullBuilder2D13ValidateEdgesEv(ptr noundef nonnull align 8 dereferenceable(20) %0)
          to label %.preheader195 unwind label %115

.preheader195:                                    ; preds = %._crit_edge205
  %102 = load i32, ptr %86, align 8, !tbaa !23
  %.not166215 = icmp slt i32 %102, %4
  br i1 %.not166215, label %.lr.ph216, label %.thread

.lr.ph216:                                        ; preds = %.preheader195
  %103 = getelementptr inbounds i8, ptr %20, i64 8
  br label %117

104:                                              ; preds = %108
  %105 = landingpad { ptr, i32 }
          cleanup
  br label %226

.lr.ph204:                                        ; preds = %.preheader196, %109
  %.0146203 = phi i32 [ %110, %109 ], [ 0, %.preheader196 ]
  %106 = load i32, ptr %8, align 4, !tbaa !5
  %.not179 = icmp eq i32 %.0146203, %106
  %107 = load i32, ptr %9, align 4
  %.not180 = icmp eq i32 %.0146203, %107
  %or.cond = select i1 %.not179, i1 true, i1 %.not180
  %.not181 = icmp eq i32 %.0146203, %3
  %or.cond184 = or i1 %.not181, %or.cond
  br i1 %or.cond184, label %109, label %108

108:                                              ; preds = %.lr.ph204
  invoke void @_ZNK3JPH19ConvexHullBuilder2D17AssignPointToEdgeEiRKNS_5ArrayIPNS0_4EdgeENS_12STLAllocatorIS3_EEEE(ptr noundef nonnull align 8 dereferenceable(20) %0, i32 noundef %.0146203, ptr noundef nonnull align 8 dereferenceable(24) %16)
          to label %109 unwind label %104

109:                                              ; preds = %.lr.ph204, %108
  %110 = add nuw nsw i32 %.0146203, 1
  %111 = load ptr, ptr %0, align 8, !tbaa !9
  %112 = call noundef i64 @_ZNK3JPH5ArrayINS_4Vec3ENS_12STLAllocatorIS1_EEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %111)
  %113 = trunc i64 %112 to i32
  %114 = icmp slt i32 %110, %113
  br i1 %114, label %.lr.ph204, label %._crit_edge205, !llvm.loop !25

115:                                              ; preds = %.thread, %._crit_edge205
  %116 = landingpad { ptr, i32 }
          cleanup
  br label %226

117:                                              ; preds = %.lr.ph216, %207
  %118 = phi i32 [ %102, %.lr.ph216 ], [ %208, %207 ]
  %119 = load ptr, ptr %85, align 8, !tbaa !22
  br label %120

120:                                              ; preds = %120, %117
  %.0151 = phi ptr [ %119, %117 ], [ %125, %120 ]
  %.0149 = phi float [ 0.000000e+00, %117 ], [ %.1150, %120 ]
  %.0147 = phi ptr [ null, %117 ], [ %.1148, %120 ]
  %121 = getelementptr inbounds i8, ptr %.0151, i64 76
  %122 = load float, ptr %121, align 4, !tbaa !27
  %123 = fcmp ogt float %122, %.0149
  %.1150 = select i1 %123, float %122, float %.0149
  %.1148 = select i1 %123, ptr %.0151, ptr %.0147
  %124 = getelementptr inbounds i8, ptr %.0151, i64 64
  %125 = load ptr, ptr %124, align 16, !tbaa !16
  %.not167 = icmp eq ptr %125, %119
  br i1 %.not167, label %126, label %120, !llvm.loop !28

126:                                              ; preds = %120
  %127 = icmp eq ptr %.1148, null
  %128 = fcmp olt float %.1150, %36
  %or.cond185 = select i1 %127, i1 true, i1 %128
  br i1 %or.cond185, label %.thread, label %129

129:                                              ; preds = %126
  %130 = getelementptr inbounds i8, ptr %.1148, i64 32
  %131 = invoke noundef nonnull align 4 dereferenceable(4) ptr @_ZN3JPH5ArrayIiNS_12STLAllocatorIiEEE4backEv(ptr noundef nonnull align 8 dereferenceable(24) %130)
          to label %132 unwind label %144

132:                                              ; preds = %129
  %133 = load i32, ptr %131, align 4, !tbaa !5
  invoke void @_ZN3JPH5ArrayIiNS_12STLAllocatorIiEEE8pop_backEv(ptr noundef nonnull align 8 dereferenceable(24) %130)
          to label %134 unwind label %144

134:                                              ; preds = %132
  %135 = load ptr, ptr %0, align 8, !tbaa !9
  %136 = sext i32 %133 to i64
  %137 = invoke noundef nonnull align 16 dereferenceable(16) ptr @_ZNK3JPH5ArrayINS_4Vec3ENS_12STLAllocatorIS1_EEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %135, i64 noundef %136)
          to label %138 unwind label %146

138:                                              ; preds = %134
  %.sroa.037.0.copyload = load double, ptr %137, align 16
  %.sroa.6.0..sroa_idx = getelementptr inbounds i8, ptr %137, i64 8
  %.sroa.6.0.copyload = load double, ptr %.sroa.6.0..sroa_idx, align 8, !tbaa !14
  br label %139

139:                                              ; preds = %143, %138
  %.0158 = phi ptr [ %.1148, %138 ], [ %..0158, %143 ]
  %140 = getelementptr inbounds i8, ptr %.0158, i64 56
  %141 = load ptr, ptr %140, align 8, !tbaa !21
  %142 = invoke noundef zeroext i1 @_ZNK3JPH19ConvexHullBuilder2D4Edge8IsFacingENS_4Vec3E(ptr noundef nonnull align 16 dereferenceable(80) %141, double %.sroa.037.0.copyload, double %.sroa.6.0.copyload)
          to label %143 unwind label %148

143:                                              ; preds = %139
  %..0158 = select i1 %142, ptr %141, ptr %.0158
  %.not168 = icmp ne ptr %..0158, %.1148
  %or.cond189.not = select i1 %142, i1 %.not168, i1 false
  br i1 %or.cond189.not, label %139, label %.preheader194, !llvm.loop !29

144:                                              ; preds = %132, %129
  %145 = landingpad { ptr, i32 }
          cleanup
  br label %226

146:                                              ; preds = %134
  %147 = landingpad { ptr, i32 }
          cleanup
  br label %226

148:                                              ; preds = %139
  %149 = landingpad { ptr, i32 }
          cleanup
  br label %226

.preheader194:                                    ; preds = %143, %153
  %.0156 = phi ptr [ %..0156, %153 ], [ %.1148, %143 ]
  %150 = getelementptr inbounds i8, ptr %.0156, i64 64
  %151 = load ptr, ptr %150, align 16, !tbaa !16
  %152 = invoke noundef zeroext i1 @_ZNK3JPH19ConvexHullBuilder2D4Edge8IsFacingENS_4Vec3E(ptr noundef nonnull align 16 dereferenceable(80) %151, double %.sroa.037.0.copyload, double %.sroa.6.0.copyload)
          to label %153 unwind label %154

153:                                              ; preds = %.preheader194
  %..0156 = select i1 %152, ptr %151, ptr %.0156
  %.not169 = icmp ne ptr %..0156, %.1148
  %or.cond191.not = select i1 %152, i1 %.not169, i1 false
  br i1 %or.cond191.not, label %.preheader194, label %156, !llvm.loop !30

154:                                              ; preds = %.preheader194
  %155 = landingpad { ptr, i32 }
          cleanup
  br label %226

156:                                              ; preds = %153
  %157 = invoke noundef ptr @_ZN3JPH19ConvexHullBuilder2D4EdgenwEm(i64 noundef 80)
          to label %158 unwind label %180

158:                                              ; preds = %156
  %159 = getelementptr inbounds i8, ptr %..0158, i64 72
  %160 = load i32, ptr %159, align 8, !tbaa !31
  call void @_ZN3JPH19ConvexHullBuilder2D4EdgeC2Ei(ptr noundef nonnull align 16 dereferenceable(80) %157, i32 noundef %160)
  %161 = invoke noundef ptr @_ZN3JPH19ConvexHullBuilder2D4EdgenwEm(i64 noundef 80)
          to label %162 unwind label %180

162:                                              ; preds = %158
  call void @_ZN3JPH19ConvexHullBuilder2D4EdgeC2Ei(ptr noundef nonnull align 16 dereferenceable(80) %161, i32 noundef %133)
  %163 = getelementptr inbounds i8, ptr %157, i64 64
  store ptr %161, ptr %163, align 16, !tbaa !16
  %164 = getelementptr inbounds i8, ptr %..0158, i64 56
  %165 = load ptr, ptr %164, align 8, !tbaa !21
  %166 = getelementptr inbounds i8, ptr %157, i64 56
  store ptr %165, ptr %166, align 8, !tbaa !21
  %167 = getelementptr inbounds i8, ptr %161, i64 56
  store ptr %157, ptr %167, align 8, !tbaa !21
  %168 = getelementptr inbounds i8, ptr %..0156, i64 64
  %169 = load ptr, ptr %168, align 16, !tbaa !16
  %170 = getelementptr inbounds i8, ptr %161, i64 64
  store ptr %169, ptr %170, align 16, !tbaa !16
  %171 = load ptr, ptr %166, align 8, !tbaa !21
  %172 = getelementptr inbounds i8, ptr %171, i64 64
  store ptr %157, ptr %172, align 16, !tbaa !16
  %173 = load ptr, ptr %170, align 16, !tbaa !16
  %174 = getelementptr inbounds i8, ptr %173, i64 56
  store ptr %161, ptr %174, align 8, !tbaa !21
  store ptr %157, ptr %85, align 8, !tbaa !22
  %175 = load i32, ptr %86, align 8, !tbaa !23
  %176 = add nsw i32 %175, 2
  store i32 %176, ptr %86, align 8, !tbaa !23
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %19) #9
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %20) #9
  store ptr %157, ptr %20, align 8, !tbaa !24
  store ptr %161, ptr %103, align 8, !tbaa !24
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %21) #9
  invoke void @_ZN3JPH5ArrayIPNS_19ConvexHullBuilder2D4EdgeENS_12STLAllocatorIS3_EEEC2ESt16initializer_listIS3_ERKS5_(ptr noundef nonnull align 8 dereferenceable(24) %19, ptr nonnull %20, i64 2, ptr noundef nonnull align 1 dereferenceable(1) %21)
          to label %177 unwind label %182

177:                                              ; preds = %162
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %21) #9
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %20) #9
  %178 = call noundef ptr @_ZN3JPH5ArrayIPNS_19ConvexHullBuilder2D4EdgeENS_12STLAllocatorIS3_EEE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %19)
  %179 = call noundef ptr @_ZN3JPH5ArrayIPNS_19ConvexHullBuilder2D4EdgeENS_12STLAllocatorIS3_EEE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %19)
  %.not170206 = icmp eq ptr %178, %179
  br i1 %.not170206, label %.preheader.preheader, label %.lr.ph209

.preheader.preheader:                             ; preds = %187, %177
  br label %.preheader

180:                                              ; preds = %158, %156
  %181 = landingpad { ptr, i32 }
          cleanup
  br label %226

182:                                              ; preds = %162
  %183 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %21) #9
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %20) #9
  br label %212

.lr.ph209:                                        ; preds = %177, %187
  %.0144207 = phi ptr [ %188, %187 ], [ %178, %177 ]
  %184 = load ptr, ptr %.0144207, align 8, !tbaa !24
  %185 = load ptr, ptr %0, align 8, !tbaa !9
  %186 = call noundef ptr @_ZNK3JPH5ArrayINS_4Vec3ENS_12STLAllocatorIS1_EEE4dataEv(ptr noundef nonnull align 8 dereferenceable(24) %185)
  invoke void @_ZN3JPH19ConvexHullBuilder2D4Edge24CalculateNormalAndCenterEPKNS_4Vec3E(ptr noundef nonnull align 16 dereferenceable(80) %184, ptr noundef %186)
          to label %187 unwind label %189

187:                                              ; preds = %.lr.ph209
  %188 = getelementptr inbounds i8, ptr %.0144207, i64 8
  %.not170 = icmp eq ptr %188, %179
  br i1 %.not170, label %.preheader.preheader, label %.lr.ph209

189:                                              ; preds = %.lr.ph209
  %190 = landingpad { ptr, i32 }
          cleanup
  br label %211

.preheader:                                       ; preds = %.preheader.preheader, %202
  %.2160 = phi ptr [ %192, %202 ], [ %..0158, %.preheader.preheader ]
  %191 = getelementptr inbounds i8, ptr %.2160, i64 64
  %192 = load ptr, ptr %191, align 16, !tbaa !16
  %193 = getelementptr inbounds i8, ptr %.2160, i64 32
  %194 = call noundef ptr @_ZN3JPH5ArrayIiNS_12STLAllocatorIiEEE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %193)
  %195 = call noundef ptr @_ZN3JPH5ArrayIiNS_12STLAllocatorIiEEE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %193)
  %.not171210 = icmp eq ptr %194, %195
  br i1 %.not171210, label %._crit_edge214.thread, label %.lr.ph213

._crit_edge214:                                   ; preds = %198
  %196 = icmp eq ptr %.2160, null
  br i1 %196, label %202, label %._crit_edge214.thread

.lr.ph213:                                        ; preds = %.preheader, %198
  %.0135211 = phi ptr [ %199, %198 ], [ %194, %.preheader ]
  %197 = load i32, ptr %.0135211, align 4, !tbaa !5
  invoke void @_ZNK3JPH19ConvexHullBuilder2D17AssignPointToEdgeEiRKNS_5ArrayIPNS0_4EdgeENS_12STLAllocatorIS3_EEEE(ptr noundef nonnull align 8 dereferenceable(20) %0, i32 noundef %197, ptr noundef nonnull align 8 dereferenceable(24) %19)
          to label %198 unwind label %200

198:                                              ; preds = %.lr.ph213
  %199 = getelementptr inbounds i8, ptr %.0135211, i64 4
  %.not171 = icmp eq ptr %199, %195
  br i1 %.not171, label %._crit_edge214, label %.lr.ph213

200:                                              ; preds = %.lr.ph213
  %201 = landingpad { ptr, i32 }
          cleanup
  br label %211

._crit_edge214.thread:                            ; preds = %.preheader, %._crit_edge214
  call void @_ZN3JPH19ConvexHullBuilder2D4EdgeD2Ev(ptr noundef nonnull align 16 dereferenceable(80) %.2160) #9
  call void @_ZN3JPH19ConvexHullBuilder2D4EdgedlEPv(ptr noundef nonnull %.2160) #9
  br label %202

202:                                              ; preds = %._crit_edge214.thread, %._crit_edge214
  %203 = load i32, ptr %86, align 8, !tbaa !23
  %204 = add nsw i32 %203, -1
  store i32 %204, ptr %86, align 8, !tbaa !23
  %205 = icmp eq ptr %.2160, %..0156
  br i1 %205, label %206, label %.preheader

206:                                              ; preds = %202
  invoke void @_ZNK3JPH19ConvexHullBuilder2D13ValidateEdgesEv(ptr noundef nonnull align 8 dereferenceable(20) %0)
          to label %207 unwind label %209

207:                                              ; preds = %206
  call void @_ZN3JPH5ArrayIPNS_19ConvexHullBuilder2D4EdgeENS_12STLAllocatorIS3_EEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %19) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %19) #9
  %208 = load i32, ptr %86, align 8, !tbaa !23
  %.not166 = icmp slt i32 %208, %4
  br i1 %.not166, label %117, label %.thread

209:                                              ; preds = %206
  %210 = landingpad { ptr, i32 }
          cleanup
  br label %211

211:                                              ; preds = %209, %200, %189
  %.pn = phi { ptr, i32 } [ %190, %189 ], [ %201, %200 ], [ %210, %209 ]
  call void @_ZN3JPH5ArrayIPNS_19ConvexHullBuilder2D4EdgeENS_12STLAllocatorIS3_EEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %19) #9
  br label %212

212:                                              ; preds = %211, %182
  %.pn.pn = phi { ptr, i32 } [ %.pn, %211 ], [ %183, %182 ]
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %19) #9
  br label %226

.thread:                                          ; preds = %207, %126, %.preheader195
  %213 = phi i32 [ %102, %.preheader195 ], [ %118, %126 ], [ %208, %207 ]
  %.0133 = phi i32 [ 1, %.preheader195 ], [ 0, %126 ], [ 1, %207 ]
  %214 = sext i32 %213 to i64
  invoke void @_ZN3JPH5ArrayIiNS_12STLAllocatorIiEEE7reserveEm(ptr noundef nonnull align 8 dereferenceable(24) %6, i64 noundef %214)
          to label %215 unwind label %115

215:                                              ; preds = %.thread
  %216 = load ptr, ptr %85, align 8, !tbaa !22
  br label %217

217:                                              ; preds = %219, %215
  %.0 = phi ptr [ %216, %215 ], [ %221, %219 ]
  %218 = getelementptr inbounds i8, ptr %.0, i64 72
  invoke void @_ZN3JPH5ArrayIiNS_12STLAllocatorIiEEE9push_backERKi(ptr noundef nonnull align 8 dereferenceable(24) %6, ptr noundef nonnull align 4 dereferenceable(4) %218)
          to label %219 unwind label %224

219:                                              ; preds = %217
  %220 = getelementptr inbounds i8, ptr %.0, i64 64
  %221 = load ptr, ptr %220, align 16, !tbaa !16
  %222 = load ptr, ptr %85, align 8, !tbaa !22
  %.not178 = icmp eq ptr %221, %222
  br i1 %.not178, label %223, label %217, !llvm.loop !32

223:                                              ; preds = %219
  call void @_ZN3JPH5ArrayIPNS_19ConvexHullBuilder2D4EdgeENS_12STLAllocatorIS3_EEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %16) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %16) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %12) #9
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %10) #9
  ret i32 %.0133

224:                                              ; preds = %217
  %225 = landingpad { ptr, i32 }
          cleanup
  br label %226

226:                                              ; preds = %144, %148, %212, %180, %154, %146, %224, %115, %104, %100
  %.pn182 = phi { ptr, i32 } [ %101, %100 ], [ %105, %104 ], [ %225, %224 ], [ %116, %115 ], [ %145, %144 ], [ %147, %146 ], [ %149, %148 ], [ %.pn.pn, %212 ], [ %181, %180 ], [ %155, %154 ]
  call void @_ZN3JPH5ArrayIPNS_19ConvexHullBuilder2D4EdgeENS_12STLAllocatorIS3_EEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %16) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %16) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %12) #9
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %10) #9
  resume { ptr, i32 } %.pn182
}

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZN3JPH5ArrayIiNS_12STLAllocatorIiEEE5clearEv(ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #7 align 2

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

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

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

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

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3maxIfERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4), ptr noundef nonnull align 4 dereferenceable(4)) local_unnamed_addr #6

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZSt4swapIiENSt9enable_ifIXsr6__and_ISt6__not_ISt15__is_tuple_likeIT_EESt21is_move_constructibleIS3_ESt18is_move_assignableIS3_EEE5valueEvE4typeERS3_SC_(ptr noundef nonnull align 4 dereferenceable(4), ptr noundef nonnull align 4 dereferenceable(4)) local_unnamed_addr #6

; Function Attrs: alwaysinline mustprogress uwtable
declare dso_local noundef ptr @_ZN3JPH19ConvexHullBuilder2D4EdgenwEm(i64 noundef) local_unnamed_addr #8 align 2

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

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZN3JPH5ArrayIPNS_19ConvexHullBuilder2D4EdgeENS_12STLAllocatorIS3_EEEC2ESt16initializer_listIS3_ERKS5_(ptr noundef nonnull align 8 dereferenceable(24), ptr, i64, ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #7 align 2

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

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

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

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

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZN3JPH5ArrayIiNS_12STLAllocatorIiEEE4backEv(ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #7 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZN3JPH5ArrayIiNS_12STLAllocatorIiEEE8pop_backEv(ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #7 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef zeroext i1 @_ZNK3JPH19ConvexHullBuilder2D4Edge8IsFacingENS_4Vec3E(ptr noundef nonnull align 16 dereferenceable(80), double, double) local_unnamed_addr #7 align 2

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

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

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZN3JPH5ArrayIiNS_12STLAllocatorIiEEE7reserveEm(ptr noundef nonnull align 8 dereferenceable(24), i64 noundef) local_unnamed_addr #7 align 2

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 = { 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 #4 = { 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 #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 = { 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 #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 = { 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 #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 = !{!"int", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !11, i64 0}
!10 = !{!"_ZTSN3JPH19ConvexHullBuilder2DE", !11, i64 0, !11, i64 8, !6, i64 16}
!11 = !{!"any pointer", !7, i64 0}
!12 = !{!13, !13, i64 0}
!13 = !{!"float", !7, i64 0}
!14 = !{!7, !7, i64 0}
!15 = !{i64 0, i64 16, !14}
!16 = !{!17, !11, i64 64}
!17 = !{!"_ZTSN3JPH19ConvexHullBuilder2D4EdgeE", !18, i64 0, !18, i64 16, !19, i64 32, !11, i64 56, !11, i64 64, !6, i64 72, !13, i64 76}
!18 = !{!"_ZTSN3JPH4Vec3E", !7, i64 0}
!19 = !{!"_ZTSN3JPH5ArrayIiNS_12STLAllocatorIiEEEE", !20, i64 0, !20, i64 8, !11, i64 16}
!20 = !{!"long", !7, i64 0}
!21 = !{!17, !11, i64 56}
!22 = !{!10, !11, i64 8}
!23 = !{!10, !6, i64 16}
!24 = !{!11, !11, i64 0}
!25 = distinct !{!25, !26}
!26 = !{!"llvm.loop.mustprogress"}
!27 = !{!17, !13, i64 76}
!28 = distinct !{!28, !26}
!29 = distinct !{!29, !26}
!30 = distinct !{!30, !26}
!31 = !{!17, !6, i64 72}
!32 = distinct !{!32, !26}


; Effective O3 passes: CorrelatedValuePropagationPass,EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,JumpThreadingPass,LCSSAPass,LICMPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,ReassociatePass,SROAPass,SimplifyCFGPass,TailCallElimPass