; LLVM IR from atlantis13579/Riemann :: Test/Test_Collision.ll (Z10TestSAPIncv)

; 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.Maths::TVector3" = type { float, float, float }
%"class.Maths::Quaternion" = type { float, float, float, float }
%"class.std::vector.23" = type { %"struct.std::_Vector_base.24" }
%"struct.std::_Vector_base.24" = type { %"struct.std::_Vector_base<Riemann::Geometry *, std::allocator<Riemann::Geometry *>>::_Vector_impl" }
%"struct.std::_Vector_base<Riemann::Geometry *, std::allocator<Riemann::Geometry *>>::_Vector_impl" = type { %"struct.std::_Vector_base<Riemann::Geometry *, std::allocator<Riemann::Geometry *>>::_Vector_impl_data" }
%"struct.std::_Vector_base<Riemann::Geometry *, std::allocator<Riemann::Geometry *>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%class.BVProxy = type { %"class.Riemann::SAP::BoundingVolumeProxy", ptr }
%"class.Riemann::SAP::BoundingVolumeProxy" = type { ptr }
%"class.Riemann::IncrementalSAP" = type <{ %"class.Riemann::SAP", i8, [7 x i8] }>
%"class.Riemann::SAP" = type { ptr, %"class.std::vector.31", %"class.std::vector.36", i64 }
%"class.std::vector.31" = type { %"struct.std::_Vector_base.32" }
%"struct.std::_Vector_base.32" = type { %"struct.std::_Vector_base<std::vector<Riemann::SAP::SweepPoint>, std::allocator<std::vector<Riemann::SAP::SweepPoint>>>::_Vector_impl" }
%"struct.std::_Vector_base<std::vector<Riemann::SAP::SweepPoint>, std::allocator<std::vector<Riemann::SAP::SweepPoint>>>::_Vector_impl" = type { %"struct.std::_Vector_base<std::vector<Riemann::SAP::SweepPoint>, std::allocator<std::vector<Riemann::SAP::SweepPoint>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<std::vector<Riemann::SAP::SweepPoint>, std::allocator<std::vector<Riemann::SAP::SweepPoint>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::vector.36" = type { %"struct.std::_Vector_base.37" }
%"struct.std::_Vector_base.37" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::initializer_list" = type { ptr, i64 }
%"class.std::allocator.38" = type { i8 }
%"class.std::set" = type { %"class.std::_Rb_tree" }
%"class.std::_Rb_tree" = type { %"struct.std::_Rb_tree<unsigned long, unsigned long, std::_Identity<unsigned long>, std::less<unsigned long>>::_Rb_tree_impl" }
%"struct.std::_Rb_tree<unsigned long, unsigned long, std::_Identity<unsigned long>, std::less<unsigned long>>::_Rb_tree_impl" = type { [8 x i8], %"struct.std::_Rb_tree_header" }
%"struct.std::_Rb_tree_header" = type { %"struct.std::_Rb_tree_node_base", i64 }
%"struct.std::_Rb_tree_node_base" = type { i32, ptr, ptr, ptr }

@.str.1 = external hidden unnamed_addr constant [27 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [79 x i8], align 1
@.str.22 = external hidden unnamed_addr constant [20 x i8], align 1

declare i32 @printf(ptr noundef, ...) #0

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZN5Maths8TVector3IfEC2Efff(ptr noundef nonnull align 4 dereferenceable(12), float noundef, float noundef, float noundef) unnamed_addr #2 align 2

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_Z10BreakPointPKcl(ptr noundef, i64 noundef) #2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN5Maths8TVector3IfE6RandomEv(ptr dead_on_unwind noalias writable sret(%"class.Maths::TVector3") align 4) #3 align 2

declare i32 @__gxx_personality_v0(...)

declare noundef ptr @_ZN7Riemann15GeometryFactory9CreateOBBERKN5Maths8TVector3IfEES5_RKNS1_10QuaternionE(ptr noundef nonnull align 4 dereferenceable(12), ptr noundef nonnull align 4 dereferenceable(12), ptr noundef nonnull align 4 dereferenceable(16)) #0

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZNK5Maths8TVector3IfEmlEf(ptr dead_on_unwind noalias writable sret(%"class.Maths::TVector3") align 4, ptr noundef nonnull align 4 dereferenceable(12), float noundef) #4 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN5Maths10Quaternion3OneEv(ptr dead_on_unwind noalias writable sret(%"class.Maths::Quaternion") align 4) #3 align 2

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

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZN7Riemann8Geometry16SetWorldPositionERKN5Maths8TVector3IfEE(ptr noundef nonnull align 8 dereferenceable(204), ptr noundef nonnull align 4 dereferenceable(12)) #4 align 2

declare void @_ZN7Riemann8Geometry20UpdateBoundingVolumeEv(ptr noundef nonnull align 8 dereferenceable(204)) #0

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZNK5Maths8TVector3IfEplERKS1_(ptr dead_on_unwind noalias writable sret(%"class.Maths::TVector3") align 4, ptr noundef nonnull align 4 dereferenceable(12), ptr noundef nonnull align 4 dereferenceable(12)) #4 align 2

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

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

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

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

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSaIiEC2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #5 align 2

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i64 @_ZNKSt3setImSt4lessImESaImEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(48)) #5 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i64 @_ZN7Riemann3SAP14PackOverlapKeyEii(i32 noundef, i32 noundef) #5 align 2

; Function Attrs: mustprogress uwtable
declare dso_local noundef i64 @_ZNKSt3setImSt4lessImESaImEE5countERKm(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 8 dereferenceable(8)) #3 align 2

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

; Function Attrs: mustprogress uwtable
define dso_local void @_Z10TestSAPIncv() #3 personality ptr @__gxx_personality_v0 {
  %1 = alloca %"class.std::vector.23", align 8
  %2 = alloca ptr, align 8
  %3 = alloca %"class.Maths::TVector3", align 4
  %4 = alloca ptr, align 8
  %5 = alloca i32, align 4
  %6 = alloca %"class.Maths::TVector3", align 4
  %7 = alloca %"class.Maths::Quaternion", align 4
  %8 = alloca ptr, align 8
  %9 = alloca %"class.Maths::TVector3", align 4
  %10 = alloca %"class.Maths::TVector3", align 4
  %11 = alloca %"class.Maths::Quaternion", align 4
  %12 = alloca ptr, align 8
  %13 = alloca %"class.Maths::TVector3", align 4
  %14 = alloca %"class.Maths::TVector3", align 4
  %15 = alloca %"class.Maths::Quaternion", align 4
  %16 = alloca %class.BVProxy, align 8
  %17 = alloca %"class.Riemann::IncrementalSAP", align 8
  %18 = alloca %"class.std::vector.36", align 8
  %19 = alloca %"class.std::initializer_list", align 8
  %20 = alloca [3 x i32], align 4
  %21 = alloca %"class.std::allocator.38", align 1
  %22 = alloca %"class.std::set", align 8
  %23 = alloca %"class.Maths::TVector3", align 4
  %24 = alloca %"class.Maths::TVector3", align 4
  %25 = alloca %"class.Maths::TVector3", align 4
  %26 = alloca %"class.Maths::TVector3", align 4
  %27 = alloca i32, align 4
  %28 = alloca %"class.Maths::TVector3", align 4
  %29 = alloca %"class.Maths::TVector3", align 4
  %30 = alloca %"class.Maths::TVector3", align 4
  %31 = alloca %"class.Maths::TVector3", align 4
  %32 = alloca ptr, align 8
  %33 = alloca %"class.Maths::Quaternion", align 4
  %34 = alloca i32, align 4
  %35 = alloca i32, align 4
  %36 = alloca %"class.Maths::TVector3", align 4
  %37 = alloca %"class.Maths::TVector3", align 4
  %38 = alloca %"class.Maths::TVector3", align 4
  %39 = alloca i64, align 8
  %40 = alloca i64, align 8
  %41 = alloca i64, align 8
  %42 = call i32 (ptr, ...) @printf(ptr noundef @.str.22)
  call void @llvm.lifetime.start.p0(i64 24, ptr %1) #6
  call void @_ZNSt6vectorIPN7Riemann8GeometryESaIS2_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %1) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr %2) #6
  call void @llvm.lifetime.start.p0(i64 12, ptr %3) #6
  invoke void @_ZN5Maths8TVector3IfEC2Efff(ptr noundef nonnull align 4 dereferenceable(12) %3, float noundef 5.000000e-01, float noundef 5.000000e-01, float noundef 5.000000e-01)
          to label %43 unwind label %82

43:                                               ; preds = %0
  call void @llvm.lifetime.start.p0(i64 12, ptr %6) #6
  invoke void @_ZN5Maths8TVector3IfEC2Efff(ptr noundef nonnull align 4 dereferenceable(12) %6, float noundef 5.000000e-01, float noundef 5.000000e-01, float noundef 5.000000e-01)
          to label %44 unwind label %86

44:                                               ; preds = %43
  call void @llvm.lifetime.start.p0(i64 16, ptr %7) #6
  invoke void @_ZN5Maths10Quaternion3OneEv(ptr dead_on_unwind writable sret(%"class.Maths::Quaternion") align 4 %7)
          to label %45 unwind label %90

45:                                               ; preds = %44
  %46 = invoke noundef ptr @_ZN7Riemann15GeometryFactory9CreateOBBERKN5Maths8TVector3IfEES5_RKNS1_10QuaternionE(ptr noundef nonnull align 4 dereferenceable(12) %3, ptr noundef nonnull align 4 dereferenceable(12) %6, ptr noundef nonnull align 4 dereferenceable(16) %7)
          to label %47 unwind label %90

47:                                               ; preds = %45
  store ptr %46, ptr %2, align 8, !tbaa !5
  %48 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN7Riemann8GeometryESaIS2_EE12emplace_backIJS2_EEERS2_DpOT_(ptr noundef nonnull align 8 dereferenceable(24) %1, ptr noundef nonnull align 8 dereferenceable(8) %2)
          to label %49 unwind label %90

49:                                               ; preds = %47
  call void @llvm.lifetime.end.p0(i64 16, ptr %7) #6
  call void @llvm.lifetime.end.p0(i64 12, ptr %6) #6
  call void @llvm.lifetime.end.p0(i64 12, ptr %3) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %2) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr %8) #6
  call void @llvm.lifetime.start.p0(i64 12, ptr %9) #6
  invoke void @_ZN5Maths8TVector3IfEC2Efff(ptr noundef nonnull align 4 dereferenceable(12) %9, float noundef 2.500000e+00, float noundef 2.500000e+00, float noundef 2.500000e+00)
          to label %50 unwind label %96

50:                                               ; preds = %49
  call void @llvm.lifetime.start.p0(i64 12, ptr %10) #6
  invoke void @_ZN5Maths8TVector3IfEC2Efff(ptr noundef nonnull align 4 dereferenceable(12) %10, float noundef 5.000000e-01, float noundef 5.000000e-01, float noundef 5.000000e-01)
          to label %51 unwind label %100

51:                                               ; preds = %50
  call void @llvm.lifetime.start.p0(i64 16, ptr %11) #6
  invoke void @_ZN5Maths10Quaternion3OneEv(ptr dead_on_unwind writable sret(%"class.Maths::Quaternion") align 4 %11)
          to label %52 unwind label %104

52:                                               ; preds = %51
  %53 = invoke noundef ptr @_ZN7Riemann15GeometryFactory9CreateOBBERKN5Maths8TVector3IfEES5_RKNS1_10QuaternionE(ptr noundef nonnull align 4 dereferenceable(12) %9, ptr noundef nonnull align 4 dereferenceable(12) %10, ptr noundef nonnull align 4 dereferenceable(16) %11)
          to label %54 unwind label %104

54:                                               ; preds = %52
  store ptr %53, ptr %8, align 8, !tbaa !5
  %55 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN7Riemann8GeometryESaIS2_EE12emplace_backIJS2_EEERS2_DpOT_(ptr noundef nonnull align 8 dereferenceable(24) %1, ptr noundef nonnull align 8 dereferenceable(8) %8)
          to label %56 unwind label %104

56:                                               ; preds = %54
  call void @llvm.lifetime.end.p0(i64 16, ptr %11) #6
  call void @llvm.lifetime.end.p0(i64 12, ptr %10) #6
  call void @llvm.lifetime.end.p0(i64 12, ptr %9) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #6
  call void @llvm.lifetime.start.p0(i64 12, ptr %13) #6
  invoke void @_ZN5Maths8TVector3IfEC2Efff(ptr noundef nonnull align 4 dereferenceable(12) %13, float noundef 1.500000e+01, float noundef 1.500000e+01, float noundef 1.500000e+01)
          to label %57 unwind label %110

57:                                               ; preds = %56
  call void @llvm.lifetime.start.p0(i64 12, ptr %14) #6
  invoke void @_ZN5Maths8TVector3IfEC2Efff(ptr noundef nonnull align 4 dereferenceable(12) %14, float noundef 5.000000e+00, float noundef 5.000000e+00, float noundef 5.000000e+00)
          to label %58 unwind label %114

58:                                               ; preds = %57
  call void @llvm.lifetime.start.p0(i64 16, ptr %15) #6
  invoke void @_ZN5Maths10Quaternion3OneEv(ptr dead_on_unwind writable sret(%"class.Maths::Quaternion") align 4 %15)
          to label %59 unwind label %118

59:                                               ; preds = %58
  %60 = invoke noundef ptr @_ZN7Riemann15GeometryFactory9CreateOBBERKN5Maths8TVector3IfEES5_RKNS1_10QuaternionE(ptr noundef nonnull align 4 dereferenceable(12) %13, ptr noundef nonnull align 4 dereferenceable(12) %14, ptr noundef nonnull align 4 dereferenceable(16) %15)
          to label %61 unwind label %118

61:                                               ; preds = %59
  store ptr %60, ptr %12, align 8, !tbaa !5
  %62 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN7Riemann8GeometryESaIS2_EE12emplace_backIJS2_EEERS2_DpOT_(ptr noundef nonnull align 8 dereferenceable(24) %1, ptr noundef nonnull align 8 dereferenceable(8) %12)
          to label %63 unwind label %118

63:                                               ; preds = %61
  call void @llvm.lifetime.end.p0(i64 16, ptr %15) #6
  call void @llvm.lifetime.end.p0(i64 12, ptr %14) #6
  call void @llvm.lifetime.end.p0(i64 12, ptr %13) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #6
  call void @llvm.lifetime.start.p0(i64 16, ptr %16) #6
  invoke void @_ZN7BVProxyC2EPSt6vectorIPN7Riemann8GeometryESaIS3_EE(ptr noundef nonnull align 8 dereferenceable(16) %16, ptr noundef %1)
          to label %64 unwind label %124

64:                                               ; preds = %63
  call void @llvm.lifetime.start.p0(i64 72, ptr %17) #6
  call void @llvm.lifetime.start.p0(i64 24, ptr %18) #6
  call void @llvm.lifetime.start.p0(i64 12, ptr %20) #6
  store i32 0, ptr %20, align 4, !tbaa !9
  %65 = getelementptr inbounds i32, ptr %20, i64 1
  store i32 1, ptr %65, align 4, !tbaa !9
  %66 = getelementptr inbounds i32, ptr %20, i64 2
  store i32 2, ptr %66, align 4, !tbaa !9
  %67 = getelementptr inbounds %"class.std::initializer_list", ptr %19, i32 0, i32 0
  store ptr %20, ptr %67, align 8, !tbaa !11
  %68 = getelementptr inbounds %"class.std::initializer_list", ptr %19, i32 0, i32 1
  store i64 3, ptr %68, align 8, !tbaa !14
  call void @llvm.lifetime.start.p0(i64 1, ptr %21) #6
  call void @_ZNSaIiEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %21) #6
  %69 = getelementptr inbounds { ptr, i64 }, ptr %19, i32 0, i32 0
  %70 = load ptr, ptr %69, align 8
  %71 = getelementptr inbounds { ptr, i64 }, ptr %19, i32 0, i32 1
  %72 = load i64, ptr %71, align 8
  invoke void @_ZNSt6vectorIiSaIiEEC2ESt16initializer_listIiERKS0_(ptr noundef nonnull align 8 dereferenceable(24) %18, ptr %70, i64 %72, ptr noundef nonnull align 1 dereferenceable(1) %21)
          to label %73 unwind label %128

73:                                               ; preds = %64
  invoke void @_ZN7Riemann14IncrementalSAPC2EPNS_3SAP19BoundingVolumeProxyERKSt6vectorIiSaIiEE(ptr noundef nonnull align 8 dereferenceable(65) %17, ptr noundef %16, ptr noundef nonnull align 8 dereferenceable(24) %18)
          to label %74 unwind label %132

74:                                               ; preds = %73
  call void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %18) #6
  call void @_ZNSt15__new_allocatorIiED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %21) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr %21) #6
  call void @llvm.lifetime.end.p0(i64 12, ptr %20) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr %18) #6
  call void @llvm.lifetime.start.p0(i64 48, ptr %22) #6
  call void @_ZNSt3setImSt4lessImESaImEEC2Ev(ptr noundef nonnull align 8 dereferenceable(48) %22) #6
  invoke void @_ZN7Riemann14IncrementalSAP16IncrementalPruneEPSt3setImSt4lessImESaImEE(ptr noundef nonnull align 8 dereferenceable(65) %17, ptr noundef %22)
          to label %75 unwind label %137

75:                                               ; preds = %74
  %76 = call noundef i64 @_ZNKSt3setImSt4lessImESaImEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(48) %22) #6
  %77 = icmp eq i64 %76, 0
  br i1 %77, label %141, label %78

78:                                               ; preds = %75
  %79 = invoke i32 (ptr, ...) @printf(ptr noundef @.str.1, ptr noundef @.str.2, i32 noundef 787)
          to label %80 unwind label %137

80:                                               ; preds = %78
  invoke void @_Z10BreakPointPKcl(ptr noundef @.str.2, i64 noundef 787)
          to label %81 unwind label %137

81:                                               ; preds = %80
  br label %141

82:                                               ; preds = %0
  %83 = landingpad { ptr, i32 }
          cleanup
  %84 = extractvalue { ptr, i32 } %83, 0
  store ptr %84, ptr %4, align 8
  %85 = extractvalue { ptr, i32 } %83, 1
  store i32 %85, ptr %5, align 4
  br label %95

86:                                               ; preds = %43
  %87 = landingpad { ptr, i32 }
          cleanup
  %88 = extractvalue { ptr, i32 } %87, 0
  store ptr %88, ptr %4, align 8
  %89 = extractvalue { ptr, i32 } %87, 1
  store i32 %89, ptr %5, align 4
  br label %94

90:                                               ; preds = %47, %45, %44
  %91 = landingpad { ptr, i32 }
          cleanup
  %92 = extractvalue { ptr, i32 } %91, 0
  store ptr %92, ptr %4, align 8
  %93 = extractvalue { ptr, i32 } %91, 1
  store i32 %93, ptr %5, align 4
  call void @llvm.lifetime.end.p0(i64 16, ptr %7) #6
  br label %94

94:                                               ; preds = %90, %86
  call void @llvm.lifetime.end.p0(i64 12, ptr %6) #6
  br label %95

95:                                               ; preds = %94, %82
  call void @llvm.lifetime.end.p0(i64 12, ptr %3) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %2) #6
  br label %347

96:                                               ; preds = %49
  %97 = landingpad { ptr, i32 }
          cleanup
  %98 = extractvalue { ptr, i32 } %97, 0
  store ptr %98, ptr %4, align 8
  %99 = extractvalue { ptr, i32 } %97, 1
  store i32 %99, ptr %5, align 4
  br label %109

100:                                              ; preds = %50
  %101 = landingpad { ptr, i32 }
          cleanup
  %102 = extractvalue { ptr, i32 } %101, 0
  store ptr %102, ptr %4, align 8
  %103 = extractvalue { ptr, i32 } %101, 1
  store i32 %103, ptr %5, align 4
  br label %108

104:                                              ; preds = %54, %52, %51
  %105 = landingpad { ptr, i32 }
          cleanup
  %106 = extractvalue { ptr, i32 } %105, 0
  store ptr %106, ptr %4, align 8
  %107 = extractvalue { ptr, i32 } %105, 1
  store i32 %107, ptr %5, align 4
  call void @llvm.lifetime.end.p0(i64 16, ptr %11) #6
  br label %108

108:                                              ; preds = %104, %100
  call void @llvm.lifetime.end.p0(i64 12, ptr %10) #6
  br label %109

109:                                              ; preds = %108, %96
  call void @llvm.lifetime.end.p0(i64 12, ptr %9) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #6
  br label %347

110:                                              ; preds = %56
  %111 = landingpad { ptr, i32 }
          cleanup
  %112 = extractvalue { ptr, i32 } %111, 0
  store ptr %112, ptr %4, align 8
  %113 = extractvalue { ptr, i32 } %111, 1
  store i32 %113, ptr %5, align 4
  br label %123

114:                                              ; preds = %57
  %115 = landingpad { ptr, i32 }
          cleanup
  %116 = extractvalue { ptr, i32 } %115, 0
  store ptr %116, ptr %4, align 8
  %117 = extractvalue { ptr, i32 } %115, 1
  store i32 %117, ptr %5, align 4
  br label %122

118:                                              ; preds = %61, %59, %58
  %119 = landingpad { ptr, i32 }
          cleanup
  %120 = extractvalue { ptr, i32 } %119, 0
  store ptr %120, ptr %4, align 8
  %121 = extractvalue { ptr, i32 } %119, 1
  store i32 %121, ptr %5, align 4
  call void @llvm.lifetime.end.p0(i64 16, ptr %15) #6
  br label %122

122:                                              ; preds = %118, %114
  call void @llvm.lifetime.end.p0(i64 12, ptr %14) #6
  br label %123

123:                                              ; preds = %122, %110
  call void @llvm.lifetime.end.p0(i64 12, ptr %13) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #6
  br label %347

124:                                              ; preds = %63
  %125 = landingpad { ptr, i32 }
          cleanup
  %126 = extractvalue { ptr, i32 } %125, 0
  store ptr %126, ptr %4, align 8
  %127 = extractvalue { ptr, i32 } %125, 1
  store i32 %127, ptr %5, align 4
  br label %346

128:                                              ; preds = %64
  %129 = landingpad { ptr, i32 }
          cleanup
  %130 = extractvalue { ptr, i32 } %129, 0
  store ptr %130, ptr %4, align 8
  %131 = extractvalue { ptr, i32 } %129, 1
  store i32 %131, ptr %5, align 4
  br label %136

132:                                              ; preds = %73
  %133 = landingpad { ptr, i32 }
          cleanup
  %134 = extractvalue { ptr, i32 } %133, 0
  store ptr %134, ptr %4, align 8
  %135 = extractvalue { ptr, i32 } %133, 1
  store i32 %135, ptr %5, align 4
  call void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %18) #6
  br label %136

136:                                              ; preds = %132, %128
  call void @_ZNSt15__new_allocatorIiED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %21) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr %21) #6
  call void @llvm.lifetime.end.p0(i64 12, ptr %20) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr %18) #6
  br label %345

137:                                              ; preds = %239, %196, %194, %190, %187, %176, %174, %170, %159, %157, %153, %150, %80, %78, %74
  %138 = landingpad { ptr, i32 }
          cleanup
  %139 = extractvalue { ptr, i32 } %138, 0
  store ptr %139, ptr %4, align 8
  %140 = extractvalue { ptr, i32 } %138, 1
  store i32 %140, ptr %5, align 4
  br label %344

141:                                              ; preds = %81, %75
  %142 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN7Riemann8GeometryESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef 2) #6
  %143 = load ptr, ptr %142, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 12, ptr %23) #6
  %144 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN7Riemann8GeometryESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef 2) #6
  %145 = load ptr, ptr %144, align 8, !tbaa !5
  %146 = invoke noundef nonnull align 4 dereferenceable(12) ptr @_ZNK7Riemann8Geometry16GetWorldPositionEv(ptr noundef nonnull align 8 dereferenceable(204) %145)
          to label %147 unwind label %161

147:                                              ; preds = %141
  call void @llvm.lifetime.start.p0(i64 12, ptr %24) #6
  invoke void @_ZN5Maths8TVector3IfEC2Efff(ptr noundef nonnull align 4 dereferenceable(12) %24, float noundef -1.000000e+01, float noundef -1.000000e+01, float noundef -1.000000e+01)
          to label %148 unwind label %165

148:                                              ; preds = %147
  invoke void @_ZNK5Maths8TVector3IfEplERKS1_(ptr dead_on_unwind writable sret(%"class.Maths::TVector3") align 4 %23, ptr noundef nonnull align 4 dereferenceable(12) %146, ptr noundef nonnull align 4 dereferenceable(12) %24)
          to label %149 unwind label %165

149:                                              ; preds = %148
  invoke void @_ZN7Riemann8Geometry16SetWorldPositionERKN5Maths8TVector3IfEE(ptr noundef nonnull align 8 dereferenceable(204) %143, ptr noundef nonnull align 4 dereferenceable(12) %23)
          to label %150 unwind label %165

150:                                              ; preds = %149
  call void @llvm.lifetime.end.p0(i64 12, ptr %24) #6
  call void @llvm.lifetime.end.p0(i64 12, ptr %23) #6
  %151 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN7Riemann8GeometryESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef 2) #6
  %152 = load ptr, ptr %151, align 8, !tbaa !5
  invoke void @_ZN7Riemann8Geometry20UpdateBoundingVolumeEv(ptr noundef nonnull align 8 dereferenceable(204) %152)
          to label %153 unwind label %137

153:                                              ; preds = %150
  invoke void @_ZN7Riemann14IncrementalSAP16IncrementalPruneEPSt3setImSt4lessImESaImEE(ptr noundef nonnull align 8 dereferenceable(65) %17, ptr noundef %22)
          to label %154 unwind label %137

154:                                              ; preds = %153
  %155 = call noundef i64 @_ZNKSt3setImSt4lessImESaImEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(48) %22) #6
  %156 = icmp eq i64 %155, 2
  br i1 %156, label %170, label %157

157:                                              ; preds = %154
  %158 = invoke i32 (ptr, ...) @printf(ptr noundef @.str.1, ptr noundef @.str.2, i32 noundef 792)
          to label %159 unwind label %137

159:                                              ; preds = %157
  invoke void @_Z10BreakPointPKcl(ptr noundef @.str.2, i64 noundef 792)
          to label %160 unwind label %137

160:                                              ; preds = %159
  br label %170

161:                                              ; preds = %141
  %162 = landingpad { ptr, i32 }
          cleanup
  %163 = extractvalue { ptr, i32 } %162, 0
  store ptr %163, ptr %4, align 8
  %164 = extractvalue { ptr, i32 } %162, 1
  store i32 %164, ptr %5, align 4
  br label %169

165:                                              ; preds = %149, %148, %147
  %166 = landingpad { ptr, i32 }
          cleanup
  %167 = extractvalue { ptr, i32 } %166, 0
  store ptr %167, ptr %4, align 8
  %168 = extractvalue { ptr, i32 } %166, 1
  store i32 %168, ptr %5, align 4
  call void @llvm.lifetime.end.p0(i64 12, ptr %24) #6
  br label %169

169:                                              ; preds = %165, %161
  call void @llvm.lifetime.end.p0(i64 12, ptr %23) #6
  br label %344

170:                                              ; preds = %160, %154
  invoke void @_ZN7Riemann14IncrementalSAP16IncrementalPruneEPSt3setImSt4lessImESaImEE(ptr noundef nonnull align 8 dereferenceable(65) %17, ptr noundef %22)
          to label %171 unwind label %137

171:                                              ; preds = %170
  %172 = call noundef i64 @_ZNKSt3setImSt4lessImESaImEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(48) %22) #6
  %173 = icmp eq i64 %172, 2
  br i1 %173, label %178, label %174

174:                                              ; preds = %171
  %175 = invoke i32 (ptr, ...) @printf(ptr noundef @.str.1, ptr noundef @.str.2, i32 noundef 795)
          to label %176 unwind label %137

176:                                              ; preds = %174
  invoke void @_Z10BreakPointPKcl(ptr noundef @.str.2, i64 noundef 795)
          to label %177 unwind label %137

177:                                              ; preds = %176
  br label %178

178:                                              ; preds = %177, %171
  %179 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN7Riemann8GeometryESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef 2) #6
  %180 = load ptr, ptr %179, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 12, ptr %25) #6
  %181 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN7Riemann8GeometryESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef 2) #6
  %182 = load ptr, ptr %181, align 8, !tbaa !5
  %183 = invoke noundef nonnull align 4 dereferenceable(12) ptr @_ZNK7Riemann8Geometry16GetWorldPositionEv(ptr noundef nonnull align 8 dereferenceable(204) %182)
          to label %184 unwind label %198

184:                                              ; preds = %178
  call void @llvm.lifetime.start.p0(i64 12, ptr %26) #6
  invoke void @_ZN5Maths8TVector3IfEC2Efff(ptr noundef nonnull align 4 dereferenceable(12) %26, float noundef 1.000000e+01, float noundef 1.000000e+01, float noundef 1.000000e+01)
          to label %185 unwind label %202

185:                                              ; preds = %184
  invoke void @_ZNK5Maths8TVector3IfEplERKS1_(ptr dead_on_unwind writable sret(%"class.Maths::TVector3") align 4 %25, ptr noundef nonnull align 4 dereferenceable(12) %183, ptr noundef nonnull align 4 dereferenceable(12) %26)
          to label %186 unwind label %202

186:                                              ; preds = %185
  invoke void @_ZN7Riemann8Geometry16SetWorldPositionERKN5Maths8TVector3IfEE(ptr noundef nonnull align 8 dereferenceable(204) %180, ptr noundef nonnull align 4 dereferenceable(12) %25)
          to label %187 unwind label %202

187:                                              ; preds = %186
  call void @llvm.lifetime.end.p0(i64 12, ptr %26) #6
  call void @llvm.lifetime.end.p0(i64 12, ptr %25) #6
  %188 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN7Riemann8GeometryESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef 2) #6
  %189 = load ptr, ptr %188, align 8, !tbaa !5
  invoke void @_ZN7Riemann8Geometry20UpdateBoundingVolumeEv(ptr noundef nonnull align 8 dereferenceable(204) %189)
          to label %190 unwind label %137

190:                                              ; preds = %187
  invoke void @_ZN7Riemann14IncrementalSAP16IncrementalPruneEPSt3setImSt4lessImESaImEE(ptr noundef nonnull align 8 dereferenceable(65) %17, ptr noundef %22)
          to label %191 unwind label %137

191:                                              ; preds = %190
  %192 = call noundef i64 @_ZNKSt3setImSt4lessImESaImEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(48) %22) #6
  %193 = icmp eq i64 %192, 0
  br i1 %193, label %207, label %194

194:                                              ; preds = %191
  %195 = invoke i32 (ptr, ...) @printf(ptr noundef @.str.1, ptr noundef @.str.2, i32 noundef 800)
          to label %196 unwind label %137

196:                                              ; preds = %194
  invoke void @_Z10BreakPointPKcl(ptr noundef @.str.2, i64 noundef 800)
          to label %197 unwind label %137

197:                                              ; preds = %196
  br label %207

198:                                              ; preds = %178
  %199 = landingpad { ptr, i32 }
          cleanup
  %200 = extractvalue { ptr, i32 } %199, 0
  store ptr %200, ptr %4, align 8
  %201 = extractvalue { ptr, i32 } %199, 1
  store i32 %201, ptr %5, align 4
  br label %206

202:                                              ; preds = %186, %185, %184
  %203 = landingpad { ptr, i32 }
          cleanup
  %204 = extractvalue { ptr, i32 } %203, 0
  store ptr %204, ptr %4, align 8
  %205 = extractvalue { ptr, i32 } %203, 1
  store i32 %205, ptr %5, align 4
  call void @llvm.lifetime.end.p0(i64 12, ptr %26) #6
  br label %206

206:                                              ; preds = %202, %198
  call void @llvm.lifetime.end.p0(i64 12, ptr %25) #6
  br label %344

207:                                              ; preds = %197, %191
  call void @llvm.lifetime.start.p0(i64 4, ptr %27) #6
  store i32 0, ptr %27, align 4, !tbaa !9
  br label %208

208:                                              ; preds = %222, %207
  %209 = load i32, ptr %27, align 4, !tbaa !9
  %210 = icmp slt i32 %209, 100
  br i1 %210, label %212, label %211

211:                                              ; preds = %208
  call void @llvm.lifetime.end.p0(i64 4, ptr %27) #6
  br label %239

212:                                              ; preds = %208
  call void @llvm.lifetime.start.p0(i64 12, ptr %28) #6
  call void @llvm.lifetime.start.p0(i64 12, ptr %29) #6
  invoke void @_ZN5Maths8TVector3IfE6RandomEv(ptr dead_on_unwind writable sret(%"class.Maths::TVector3") align 4 %29)
          to label %213 unwind label %225

213:                                              ; preds = %212
  invoke void @_ZNK5Maths8TVector3IfEmlEf(ptr dead_on_unwind writable sret(%"class.Maths::TVector3") align 4 %28, ptr noundef nonnull align 4 dereferenceable(12) %29, float noundef 1.000000e+02)
          to label %214 unwind label %225

214:                                              ; preds = %213
  call void @llvm.lifetime.end.p0(i64 12, ptr %29) #6
  call void @llvm.lifetime.start.p0(i64 12, ptr %30) #6
  call void @llvm.lifetime.start.p0(i64 12, ptr %31) #6
  invoke void @_ZN5Maths8TVector3IfE6RandomEv(ptr dead_on_unwind writable sret(%"class.Maths::TVector3") align 4 %31)
          to label %215 unwind label %229

215:                                              ; preds = %214
  invoke void @_ZNK5Maths8TVector3IfEmlEf(ptr dead_on_unwind writable sret(%"class.Maths::TVector3") align 4 %30, ptr noundef nonnull align 4 dereferenceable(12) %31, float noundef 1.000000e+02)
          to label %216 unwind label %229

216:                                              ; preds = %215
  call void @llvm.lifetime.end.p0(i64 12, ptr %31) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr %32) #6
  call void @llvm.lifetime.start.p0(i64 16, ptr %33) #6
  invoke void @_ZN5Maths10Quaternion3OneEv(ptr dead_on_unwind writable sret(%"class.Maths::Quaternion") align 4 %33)
          to label %217 unwind label %233

217:                                              ; preds = %216
  %218 = invoke noundef ptr @_ZN7Riemann15GeometryFactory9CreateOBBERKN5Maths8TVector3IfEES5_RKNS1_10QuaternionE(ptr noundef nonnull align 4 dereferenceable(12) %28, ptr noundef nonnull align 4 dereferenceable(12) %30, ptr noundef nonnull align 4 dereferenceable(16) %33)
          to label %219 unwind label %233

219:                                              ; preds = %217
  store ptr %218, ptr %32, align 8, !tbaa !5
  %220 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN7Riemann8GeometryESaIS2_EE12emplace_backIJS2_EEERS2_DpOT_(ptr noundef nonnull align 8 dereferenceable(24) %1, ptr noundef nonnull align 8 dereferenceable(8) %32)
          to label %221 unwind label %233

221:                                              ; preds = %219
  call void @llvm.lifetime.end.p0(i64 16, ptr %33) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %32) #6
  call void @llvm.lifetime.end.p0(i64 12, ptr %30) #6
  call void @llvm.lifetime.end.p0(i64 12, ptr %28) #6
  br label %222

222:                                              ; preds = %221
  %223 = load i32, ptr %27, align 4, !tbaa !9
  %224 = add nsw i32 %223, 1
  store i32 %224, ptr %27, align 4, !tbaa !9
  br label %208, !llvm.loop !15

225:                                              ; preds = %213, %212
  %226 = landingpad { ptr, i32 }
          cleanup
  %227 = extractvalue { ptr, i32 } %226, 0
  store ptr %227, ptr %4, align 8
  %228 = extractvalue { ptr, i32 } %226, 1
  store i32 %228, ptr %5, align 4
  call void @llvm.lifetime.end.p0(i64 12, ptr %29) #6
  br label %238

229:                                              ; preds = %215, %214
  %230 = landingpad { ptr, i32 }
          cleanup
  %231 = extractvalue { ptr, i32 } %230, 0
  store ptr %231, ptr %4, align 8
  %232 = extractvalue { ptr, i32 } %230, 1
  store i32 %232, ptr %5, align 4
  call void @llvm.lifetime.end.p0(i64 12, ptr %31) #6
  br label %237

233:                                              ; preds = %219, %217, %216
  %234 = landingpad { ptr, i32 }
          cleanup
  %235 = extractvalue { ptr, i32 } %234, 0
  store ptr %235, ptr %4, align 8
  %236 = extractvalue { ptr, i32 } %234, 1
  store i32 %236, ptr %5, align 4
  call void @llvm.lifetime.end.p0(i64 16, ptr %33) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %32) #6
  br label %237

237:                                              ; preds = %233, %229
  call void @llvm.lifetime.end.p0(i64 12, ptr %30) #6
  br label %238

238:                                              ; preds = %237, %225
  call void @llvm.lifetime.end.p0(i64 12, ptr %28) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %27) #6
  br label %344

239:                                              ; preds = %211
  invoke void @_ZN7Riemann14IncrementalSAP8SetDirtyEv(ptr noundef nonnull align 8 dereferenceable(65) %17)
          to label %240 unwind label %137

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

241:                                              ; preds = %339, %240
  %242 = load i32, ptr %34, align 4, !tbaa !9
  %243 = icmp slt i32 %242, 10
  br i1 %243, label %245, label %244

244:                                              ; preds = %241
  store i32 5, ptr %35, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %34) #6
  br label %343

245:                                              ; preds = %241
  %246 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN7Riemann8GeometryESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef 2) #6
  %247 = load ptr, ptr %246, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 12, ptr %36) #6
  %248 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN7Riemann8GeometryESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef 2) #6
  %249 = load ptr, ptr %248, align 8, !tbaa !5
  %250 = invoke noundef nonnull align 4 dereferenceable(12) ptr @_ZNK7Riemann8Geometry16GetWorldPositionEv(ptr noundef nonnull align 8 dereferenceable(204) %249)
          to label %251 unwind label %265

251:                                              ; preds = %245
  call void @llvm.lifetime.start.p0(i64 12, ptr %37) #6
  call void @llvm.lifetime.start.p0(i64 12, ptr %38) #6
  invoke void @_ZN5Maths8TVector3IfE6RandomEv(ptr dead_on_unwind writable sret(%"class.Maths::TVector3") align 4 %38)
          to label %252 unwind label %269

252:                                              ; preds = %251
  invoke void @_ZNK5Maths8TVector3IfEmlEf(ptr dead_on_unwind writable sret(%"class.Maths::TVector3") align 4 %37, ptr noundef nonnull align 4 dereferenceable(12) %38, float noundef 2.000000e+01)
          to label %253 unwind label %269

253:                                              ; preds = %252
  invoke void @_ZNK5Maths8TVector3IfEplERKS1_(ptr dead_on_unwind writable sret(%"class.Maths::TVector3") align 4 %36, ptr noundef nonnull align 4 dereferenceable(12) %250, ptr noundef nonnull align 4 dereferenceable(12) %37)
          to label %254 unwind label %269

254:                                              ; preds = %253
  invoke void @_ZN7Riemann8Geometry16SetWorldPositionERKN5Maths8TVector3IfEE(ptr noundef nonnull align 8 dereferenceable(204) %247, ptr noundef nonnull align 4 dereferenceable(12) %36)
          to label %255 unwind label %269

255:                                              ; preds = %254
  call void @llvm.lifetime.end.p0(i64 12, ptr %38) #6
  call void @llvm.lifetime.end.p0(i64 12, ptr %37) #6
  call void @llvm.lifetime.end.p0(i64 12, ptr %36) #6
  %256 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN7Riemann8GeometryESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef 2) #6
  %257 = load ptr, ptr %256, align 8, !tbaa !5
  invoke void @_ZN7Riemann8Geometry20UpdateBoundingVolumeEv(ptr noundef nonnull align 8 dereferenceable(204) %257)
          to label %258 unwind label %274

258:                                              ; preds = %255
  invoke void @_ZN7Riemann14IncrementalSAP16IncrementalPruneEPSt3setImSt4lessImESaImEE(ptr noundef nonnull align 8 dereferenceable(65) %17, ptr noundef %22)
          to label %259 unwind label %274

259:                                              ; preds = %258
  call void @llvm.lifetime.start.p0(i64 8, ptr %39) #6
  store i64 0, ptr %39, align 8, !tbaa !17
  br label %260

260:                                              ; preds = %335, %259
  %261 = load i64, ptr %39, align 8, !tbaa !17
  %262 = call noundef i64 @_ZNKSt6vectorIPN7Riemann8GeometryESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #6
  %263 = icmp ult i64 %261, %262
  br i1 %263, label %278, label %264

264:                                              ; preds = %260
  store i32 8, ptr %35, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %39) #6
  br label %338

265:                                              ; preds = %245
  %266 = landingpad { ptr, i32 }
          cleanup
  %267 = extractvalue { ptr, i32 } %266, 0
  store ptr %267, ptr %4, align 8
  %268 = extractvalue { ptr, i32 } %266, 1
  store i32 %268, ptr %5, align 4
  br label %273

269:                                              ; preds = %254, %253, %252, %251
  %270 = landingpad { ptr, i32 }
          cleanup
  %271 = extractvalue { ptr, i32 } %270, 0
  store ptr %271, ptr %4, align 8
  %272 = extractvalue { ptr, i32 } %270, 1
  store i32 %272, ptr %5, align 4
  call void @llvm.lifetime.end.p0(i64 12, ptr %38) #6
  call void @llvm.lifetime.end.p0(i64 12, ptr %37) #6
  br label %273

273:                                              ; preds = %269, %265
  call void @llvm.lifetime.end.p0(i64 12, ptr %36) #6
  br label %342

274:                                              ; preds = %258, %255
  %275 = landingpad { ptr, i32 }
          cleanup
  %276 = extractvalue { ptr, i32 } %275, 0
  store ptr %276, ptr %4, align 8
  %277 = extractvalue { ptr, i32 } %275, 1
  store i32 %277, ptr %5, align 4
  br label %342

278:                                              ; preds = %260
  call void @llvm.lifetime.start.p0(i64 8, ptr %40) #6
  store i64 0, ptr %40, align 8, !tbaa !17
  br label %279

279:                                              ; preds = %331, %278
  %280 = load i64, ptr %40, align 8, !tbaa !17
  %281 = call noundef i64 @_ZNKSt6vectorIPN7Riemann8GeometryESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #6
  %282 = icmp ult i64 %280, %281
  br i1 %282, label %284, label %283

283:                                              ; preds = %279
  store i32 11, ptr %35, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %40) #6
  br label %334

284:                                              ; preds = %279
  %285 = load i64, ptr %39, align 8, !tbaa !17
  %286 = load i64, ptr %40, align 8, !tbaa !17
  %287 = icmp eq i64 %285, %286
  br i1 %287, label %288, label %289

288:                                              ; preds = %284
  br label %331

289:                                              ; preds = %284
  call void @llvm.lifetime.start.p0(i64 8, ptr %41) #6
  %290 = load i64, ptr %39, align 8, !tbaa !17
  %291 = trunc i64 %290 to i32
  %292 = load i64, ptr %40, align 8, !tbaa !17
  %293 = trunc i64 %292 to i32
  %294 = invoke noundef i64 @_ZN7Riemann3SAP14PackOverlapKeyEii(i32 noundef %291, i32 noundef %293)
          to label %295 unwind label %316

295:                                              ; preds = %289
  store i64 %294, ptr %41, align 8, !tbaa !17
  %296 = load i64, ptr %39, align 8, !tbaa !17
  %297 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN7Riemann8GeometryESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef %296) #6
  %298 = load ptr, ptr %297, align 8, !tbaa !5
  %299 = invoke noundef nonnull align 4 dereferenceable(24) ptr @_ZNK7Riemann8Geometry28GetBoundingVolume_WorldSpaceEv(ptr noundef nonnull align 8 dereferenceable(204) %298)
          to label %300 unwind label %316

300:                                              ; preds = %295
  %301 = load i64, ptr %40, align 8, !tbaa !17
  %302 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN7Riemann8GeometryESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef %301) #6
  %303 = load ptr, ptr %302, align 8, !tbaa !5
  %304 = invoke noundef nonnull align 4 dereferenceable(24) ptr @_ZNK7Riemann8Geometry28GetBoundingVolume_WorldSpaceEv(ptr noundef nonnull align 8 dereferenceable(204) %303)
          to label %305 unwind label %316

305:                                              ; preds = %300
  %306 = invoke noundef zeroext i1 @_ZNK5Maths6TAABB3IfE9IntersectERKS1_(ptr noundef nonnull align 4 dereferenceable(24) %299, ptr noundef nonnull align 4 dereferenceable(24) %304)
          to label %307 unwind label %316

307:                                              ; preds = %305
  br i1 %306, label %308, label %321

308:                                              ; preds = %307
  %309 = invoke noundef i64 @_ZNKSt3setImSt4lessImESaImEE5countERKm(ptr noundef nonnull align 8 dereferenceable(48) %22, ptr noundef nonnull align 8 dereferenceable(8) %41)
          to label %310 unwind label %316

310:                                              ; preds = %308
  %311 = icmp eq i64 %309, 1
  br i1 %311, label %320, label %312

312:                                              ; preds = %310
  %313 = invoke i32 (ptr, ...) @printf(ptr noundef @.str.1, ptr noundef @.str.2, i32 noundef 823)
          to label %314 unwind label %316

314:                                              ; preds = %312
  invoke void @_Z10BreakPointPKcl(ptr noundef @.str.2, i64 noundef 823)
          to label %315 unwind label %316

315:                                              ; preds = %314
  br label %320

316:                                              ; preds = %327, %325, %321, %314, %312, %308, %305, %300, %295, %289
  %317 = landingpad { ptr, i32 }
          cleanup
  %318 = extractvalue { ptr, i32 } %317, 0
  store ptr %318, ptr %4, align 8
  %319 = extractvalue { ptr, i32 } %317, 1
  store i32 %319, ptr %5, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %41) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %40) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %39) #6
  br label %342

320:                                              ; preds = %315, %310
  br label %330

321:                                              ; preds = %307
  %322 = invoke noundef i64 @_ZNKSt3setImSt4lessImESaImEE5countERKm(ptr noundef nonnull align 8 dereferenceable(48) %22, ptr noundef nonnull align 8 dereferenceable(8) %41)
          to label %323 unwind label %316

323:                                              ; preds = %321
  %324 = icmp eq i64 %322, 0
  br i1 %324, label %329, label %325

325:                                              ; preds = %323
  %326 = invoke i32 (ptr, ...) @printf(ptr noundef @.str.1, ptr noundef @.str.2, i32 noundef 827)
          to label %327 unwind label %316

327:                                              ; preds = %325
  invoke void @_Z10BreakPointPKcl(ptr noundef @.str.2, i64 noundef 827)
          to label %328 unwind label %316

328:                                              ; preds = %327
  br label %329

329:                                              ; preds = %328, %323
  br label %330

330:                                              ; preds = %329, %320
  call void @llvm.lifetime.end.p0(i64 8, ptr %41) #6
  br label %331

331:                                              ; preds = %330, %288
  %332 = load i64, ptr %40, align 8, !tbaa !17
  %333 = add i64 %332, 1
  store i64 %333, ptr %40, align 8, !tbaa !17
  br label %279, !llvm.loop !18

334:                                              ; preds = %283
  br label %335

335:                                              ; preds = %334
  %336 = load i64, ptr %39, align 8, !tbaa !17
  %337 = add i64 %336, 1
  store i64 %337, ptr %39, align 8, !tbaa !17
  br label %260, !llvm.loop !19

338:                                              ; preds = %264
  br label %339

339:                                              ; preds = %338
  %340 = load i32, ptr %34, align 4, !tbaa !9
  %341 = add nsw i32 %340, 1
  store i32 %341, ptr %34, align 4, !tbaa !9
  br label %241, !llvm.loop !20

342:                                              ; preds = %316, %274, %273
  call void @llvm.lifetime.end.p0(i64 4, ptr %34) #6
  br label %344

343:                                              ; preds = %244
  store i32 1, ptr %35, align 4
  call void @_ZNSt3setImSt4lessImESaImEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %22) #6
  call void @llvm.lifetime.end.p0(i64 48, ptr %22) #6
  call void @_ZN7Riemann3SAPD2Ev(ptr noundef nonnull align 8 dereferenceable(65) %17) #6
  call void @llvm.lifetime.end.p0(i64 72, ptr %17) #6
  call void @llvm.lifetime.end.p0(i64 16, ptr %16) #6
  call void @_ZNSt6vectorIPN7Riemann8GeometryESaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %1) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr %1) #6
  ret void

344:                                              ; preds = %342, %238, %206, %169, %137
  call void @_ZNSt3setImSt4lessImESaImEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %22) #6
  call void @llvm.lifetime.end.p0(i64 48, ptr %22) #6
  call void @_ZN7Riemann3SAPD2Ev(ptr noundef nonnull align 8 dereferenceable(65) %17) #6
  br label %345

345:                                              ; preds = %344, %136
  call void @llvm.lifetime.end.p0(i64 72, ptr %17) #6
  br label %346

346:                                              ; preds = %345, %124
  call void @llvm.lifetime.end.p0(i64 16, ptr %16) #6
  br label %347

347:                                              ; preds = %346, %123, %109, %95
  call void @_ZNSt6vectorIPN7Riemann8GeometryESaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %1) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr %1) #6
  br label %348

348:                                              ; preds = %347
  %349 = load ptr, ptr %4, align 8
  %350 = load i32, ptr %5, align 4
  %351 = insertvalue { ptr, i32 } poison, ptr %349, 0
  %352 = insertvalue { ptr, i32 } %351, i32 %350, 1
  resume { ptr, i32 } %352
}

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN7Riemann14IncrementalSAPC2EPNS_3SAP19BoundingVolumeProxyERKSt6vectorIiSaIiEE(ptr noundef nonnull align 8 dereferenceable(65), ptr noundef, ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #3 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN7Riemann14IncrementalSAP16IncrementalPruneEPSt3setImSt4lessImESaImEE(ptr noundef nonnull align 8 dereferenceable(65), ptr noundef) #3 align 2

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

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

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt15__new_allocatorIiED2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #5 align 2

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


; 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.Maths::TVector3" = type { float, float, float }
%"class.Maths::Quaternion" = type { float, float, float, float }
%"class.std::vector.23" = type { %"struct.std::_Vector_base.24" }
%"struct.std::_Vector_base.24" = type { %"struct.std::_Vector_base<Riemann::Geometry *, std::allocator<Riemann::Geometry *>>::_Vector_impl" }
%"struct.std::_Vector_base<Riemann::Geometry *, std::allocator<Riemann::Geometry *>>::_Vector_impl" = type { %"struct.std::_Vector_base<Riemann::Geometry *, std::allocator<Riemann::Geometry *>>::_Vector_impl_data" }
%"struct.std::_Vector_base<Riemann::Geometry *, std::allocator<Riemann::Geometry *>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%class.BVProxy = type { %"class.Riemann::SAP::BoundingVolumeProxy", ptr }
%"class.Riemann::SAP::BoundingVolumeProxy" = type { ptr }
%"class.Riemann::IncrementalSAP" = type <{ %"class.Riemann::SAP", i8, [7 x i8] }>
%"class.Riemann::SAP" = type { ptr, %"class.std::vector.31", %"class.std::vector.36", i64 }
%"class.std::vector.31" = type { %"struct.std::_Vector_base.32" }
%"struct.std::_Vector_base.32" = type { %"struct.std::_Vector_base<std::vector<Riemann::SAP::SweepPoint>, std::allocator<std::vector<Riemann::SAP::SweepPoint>>>::_Vector_impl" }
%"struct.std::_Vector_base<std::vector<Riemann::SAP::SweepPoint>, std::allocator<std::vector<Riemann::SAP::SweepPoint>>>::_Vector_impl" = type { %"struct.std::_Vector_base<std::vector<Riemann::SAP::SweepPoint>, std::allocator<std::vector<Riemann::SAP::SweepPoint>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<std::vector<Riemann::SAP::SweepPoint>, std::allocator<std::vector<Riemann::SAP::SweepPoint>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::vector.36" = type { %"struct.std::_Vector_base.37" }
%"struct.std::_Vector_base.37" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::allocator.38" = type { i8 }
%"class.std::set" = type { %"class.std::_Rb_tree" }
%"class.std::_Rb_tree" = type { %"struct.std::_Rb_tree<unsigned long, unsigned long, std::_Identity<unsigned long>, std::less<unsigned long>>::_Rb_tree_impl" }
%"struct.std::_Rb_tree<unsigned long, unsigned long, std::_Identity<unsigned long>, std::less<unsigned long>>::_Rb_tree_impl" = type { [8 x i8], %"struct.std::_Rb_tree_header" }
%"struct.std::_Rb_tree_header" = type { %"struct.std::_Rb_tree_node_base", i64 }
%"struct.std::_Rb_tree_node_base" = type { i32, ptr, ptr, ptr }

@.str.1 = external hidden unnamed_addr constant [27 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [79 x i8], align 1
@.str.22 = external hidden unnamed_addr constant [20 x i8], align 1

; Function Attrs: nofree nounwind
declare noundef i32 @printf(ptr nocapture noundef readonly, ...) local_unnamed_addr #0

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZN5Maths8TVector3IfEC2Efff(ptr noundef nonnull align 4 dereferenceable(12), float noundef, float noundef, float noundef) unnamed_addr #2 align 2

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_Z10BreakPointPKcl(ptr noundef, i64 noundef) local_unnamed_addr #2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN5Maths8TVector3IfE6RandomEv(ptr dead_on_unwind noalias writable sret(%"class.Maths::TVector3") align 4) local_unnamed_addr #3 align 2

declare i32 @__gxx_personality_v0(...)

declare noundef ptr @_ZN7Riemann15GeometryFactory9CreateOBBERKN5Maths8TVector3IfEES5_RKNS1_10QuaternionE(ptr noundef nonnull align 4 dereferenceable(12), ptr noundef nonnull align 4 dereferenceable(12), ptr noundef nonnull align 4 dereferenceable(16)) local_unnamed_addr #4

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZNK5Maths8TVector3IfEmlEf(ptr dead_on_unwind noalias writable sret(%"class.Maths::TVector3") align 4, ptr noundef nonnull align 4 dereferenceable(12), float noundef) local_unnamed_addr #5 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN5Maths10Quaternion3OneEv(ptr dead_on_unwind noalias writable sret(%"class.Maths::Quaternion") align 4) local_unnamed_addr #3 align 2

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

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZN7Riemann8Geometry16SetWorldPositionERKN5Maths8TVector3IfEE(ptr noundef nonnull align 8 dereferenceable(204), ptr noundef nonnull align 4 dereferenceable(12)) local_unnamed_addr #5 align 2

declare void @_ZN7Riemann8Geometry20UpdateBoundingVolumeEv(ptr noundef nonnull align 8 dereferenceable(204)) local_unnamed_addr #4

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZNK5Maths8TVector3IfEplERKS1_(ptr dead_on_unwind noalias writable sret(%"class.Maths::TVector3") align 4, ptr noundef nonnull align 4 dereferenceable(12), ptr noundef nonnull align 4 dereferenceable(12)) local_unnamed_addr #5 align 2

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

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

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

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

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSaIiEC2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #6 align 2

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

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i64 @_ZN7Riemann3SAP14PackOverlapKeyEii(i32 noundef, i32 noundef) local_unnamed_addr #6 align 2

; Function Attrs: mustprogress uwtable
declare dso_local noundef i64 @_ZNKSt3setImSt4lessImESaImEE5countERKm(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #3 align 2

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

; Function Attrs: mustprogress uwtable
define dso_local void @_Z10TestSAPIncv() local_unnamed_addr #3 personality ptr @__gxx_personality_v0 {
  %1 = alloca %"class.std::vector.23", align 8
  %2 = alloca ptr, align 8
  %3 = alloca %"class.Maths::TVector3", align 4
  %4 = alloca %"class.Maths::TVector3", align 4
  %5 = alloca %"class.Maths::Quaternion", align 4
  %6 = alloca ptr, align 8
  %7 = alloca %"class.Maths::TVector3", align 4
  %8 = alloca %"class.Maths::TVector3", align 4
  %9 = alloca %"class.Maths::Quaternion", align 4
  %10 = alloca ptr, align 8
  %11 = alloca %"class.Maths::TVector3", align 4
  %12 = alloca %"class.Maths::TVector3", align 4
  %13 = alloca %"class.Maths::Quaternion", align 4
  %14 = alloca %class.BVProxy, align 8
  %15 = alloca %"class.Riemann::IncrementalSAP", align 8
  %16 = alloca %"class.std::vector.36", align 8
  %17 = alloca [3 x i32], align 4
  %18 = alloca %"class.std::allocator.38", align 1
  %19 = alloca %"class.std::set", align 8
  %20 = alloca %"class.Maths::TVector3", align 4
  %21 = alloca %"class.Maths::TVector3", align 4
  %22 = alloca %"class.Maths::TVector3", align 4
  %23 = alloca %"class.Maths::TVector3", align 4
  %24 = alloca %"class.Maths::TVector3", align 4
  %25 = alloca %"class.Maths::TVector3", align 4
  %26 = alloca %"class.Maths::TVector3", align 4
  %27 = alloca %"class.Maths::TVector3", align 4
  %28 = alloca ptr, align 8
  %29 = alloca %"class.Maths::Quaternion", align 4
  %30 = alloca %"class.Maths::TVector3", align 4
  %31 = alloca %"class.Maths::TVector3", align 4
  %32 = alloca %"class.Maths::TVector3", align 4
  %33 = alloca i64, align 8
  %34 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.22)
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %1) #7
  call void @_ZNSt6vectorIPN7Riemann8GeometryESaIS2_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %1) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %2) #7
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %3) #7
  call void @_ZN5Maths8TVector3IfEC2Efff(ptr noundef nonnull align 4 dereferenceable(12) %3, float noundef 5.000000e-01, float noundef 5.000000e-01, float noundef 5.000000e-01)
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %4) #7
  call void @_ZN5Maths8TVector3IfEC2Efff(ptr noundef nonnull align 4 dereferenceable(12) %4, float noundef 5.000000e-01, float noundef 5.000000e-01, float noundef 5.000000e-01)
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %5) #7
  invoke void @_ZN5Maths10Quaternion3OneEv(ptr dead_on_unwind nonnull writable sret(%"class.Maths::Quaternion") align 4 %5)
          to label %35 unwind label %59

35:                                               ; preds = %0
  %36 = invoke noundef ptr @_ZN7Riemann15GeometryFactory9CreateOBBERKN5Maths8TVector3IfEES5_RKNS1_10QuaternionE(ptr noundef nonnull align 4 dereferenceable(12) %3, ptr noundef nonnull align 4 dereferenceable(12) %4, ptr noundef nonnull align 4 dereferenceable(16) %5)
          to label %37 unwind label %59

37:                                               ; preds = %35
  store ptr %36, ptr %2, align 8, !tbaa !5
  %38 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN7Riemann8GeometryESaIS2_EE12emplace_backIJS2_EEERS2_DpOT_(ptr noundef nonnull align 8 dereferenceable(24) %1, ptr noundef nonnull align 8 dereferenceable(8) %2)
          to label %39 unwind label %59

39:                                               ; preds = %37
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %5) #7
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %4) #7
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %3) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %2) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %6) #7
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %7) #7
  call void @_ZN5Maths8TVector3IfEC2Efff(ptr noundef nonnull align 4 dereferenceable(12) %7, float noundef 2.500000e+00, float noundef 2.500000e+00, float noundef 2.500000e+00)
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %8) #7
  call void @_ZN5Maths8TVector3IfEC2Efff(ptr noundef nonnull align 4 dereferenceable(12) %8, float noundef 5.000000e-01, float noundef 5.000000e-01, float noundef 5.000000e-01)
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %9) #7
  invoke void @_ZN5Maths10Quaternion3OneEv(ptr dead_on_unwind nonnull writable sret(%"class.Maths::Quaternion") align 4 %9)
          to label %40 unwind label %61

40:                                               ; preds = %39
  %41 = invoke noundef ptr @_ZN7Riemann15GeometryFactory9CreateOBBERKN5Maths8TVector3IfEES5_RKNS1_10QuaternionE(ptr noundef nonnull align 4 dereferenceable(12) %7, ptr noundef nonnull align 4 dereferenceable(12) %8, ptr noundef nonnull align 4 dereferenceable(16) %9)
          to label %42 unwind label %61

42:                                               ; preds = %40
  store ptr %41, ptr %6, align 8, !tbaa !5
  %43 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN7Riemann8GeometryESaIS2_EE12emplace_backIJS2_EEERS2_DpOT_(ptr noundef nonnull align 8 dereferenceable(24) %1, ptr noundef nonnull align 8 dereferenceable(8) %6)
          to label %44 unwind label %61

44:                                               ; preds = %42
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %9) #7
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %8) #7
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %7) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %10) #7
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %11) #7
  call void @_ZN5Maths8TVector3IfEC2Efff(ptr noundef nonnull align 4 dereferenceable(12) %11, float noundef 1.500000e+01, float noundef 1.500000e+01, float noundef 1.500000e+01)
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %12) #7
  call void @_ZN5Maths8TVector3IfEC2Efff(ptr noundef nonnull align 4 dereferenceable(12) %12, float noundef 5.000000e+00, float noundef 5.000000e+00, float noundef 5.000000e+00)
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %13) #7
  invoke void @_ZN5Maths10Quaternion3OneEv(ptr dead_on_unwind nonnull writable sret(%"class.Maths::Quaternion") align 4 %13)
          to label %45 unwind label %63

45:                                               ; preds = %44
  %46 = invoke noundef ptr @_ZN7Riemann15GeometryFactory9CreateOBBERKN5Maths8TVector3IfEES5_RKNS1_10QuaternionE(ptr noundef nonnull align 4 dereferenceable(12) %11, ptr noundef nonnull align 4 dereferenceable(12) %12, ptr noundef nonnull align 4 dereferenceable(16) %13)
          to label %47 unwind label %63

47:                                               ; preds = %45
  store ptr %46, ptr %10, align 8, !tbaa !5
  %48 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN7Riemann8GeometryESaIS2_EE12emplace_backIJS2_EEERS2_DpOT_(ptr noundef nonnull align 8 dereferenceable(24) %1, ptr noundef nonnull align 8 dereferenceable(8) %10)
          to label %49 unwind label %63

49:                                               ; preds = %47
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %13) #7
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %12) #7
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %11) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %10) #7
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %14) #7
  call void @_ZN7BVProxyC2EPSt6vectorIPN7Riemann8GeometryESaIS3_EE(ptr noundef nonnull align 8 dereferenceable(16) %14, ptr noundef nonnull %1)
  call void @llvm.lifetime.start.p0(i64 72, ptr nonnull %15) #7
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %16) #7
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %17) #7
  store i32 0, ptr %17, align 4, !tbaa !9
  %50 = getelementptr inbounds i8, ptr %17, i64 4
  store i32 1, ptr %50, align 4, !tbaa !9
  %51 = getelementptr inbounds i8, ptr %17, i64 8
  store i32 2, ptr %51, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %18) #7
  call void @_ZNSaIiEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %18) #7
  invoke void @_ZNSt6vectorIiSaIiEEC2ESt16initializer_listIiERKS0_(ptr noundef nonnull align 8 dereferenceable(24) %16, ptr nonnull %17, i64 3, ptr noundef nonnull align 1 dereferenceable(1) %18)
          to label %52 unwind label %65

52:                                               ; preds = %49
  invoke void @_ZN7Riemann14IncrementalSAPC2EPNS_3SAP19BoundingVolumeProxyERKSt6vectorIiSaIiEE(ptr noundef nonnull align 8 dereferenceable(65) %15, ptr noundef nonnull %14, ptr noundef nonnull align 8 dereferenceable(24) %16)
          to label %53 unwind label %67

53:                                               ; preds = %52
  call void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %16) #7
  call void @_ZNSt15__new_allocatorIiED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %18) #7
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %18) #7
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %17) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %16) #7
  call void @llvm.lifetime.start.p0(i64 48, ptr nonnull %19) #7
  call void @_ZNSt3setImSt4lessImESaImEEC2Ev(ptr noundef nonnull align 8 dereferenceable(48) %19) #7
  invoke void @_ZN7Riemann14IncrementalSAP16IncrementalPruneEPSt3setImSt4lessImESaImEE(ptr noundef nonnull align 8 dereferenceable(65) %15, ptr noundef nonnull %19)
          to label %54 unwind label %70

54:                                               ; preds = %53
  %55 = call noundef i64 @_ZNKSt3setImSt4lessImESaImEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(48) %19) #7
  %56 = icmp eq i64 %55, 0
  br i1 %56, label %72, label %57

57:                                               ; preds = %54
  %58 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.1, ptr noundef nonnull @.str.2, i32 noundef 787)
  call void @_Z10BreakPointPKcl(ptr noundef nonnull @.str.2, i64 noundef 787)
  br label %72

59:                                               ; preds = %37, %35, %0
  %60 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %5) #7
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %4) #7
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %3) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %2) #7
  br label %189

61:                                               ; preds = %42, %40, %39
  %62 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %9) #7
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %8) #7
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %7) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #7
  br label %189

63:                                               ; preds = %47, %45, %44
  %64 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %13) #7
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %12) #7
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %11) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %10) #7
  br label %189

65:                                               ; preds = %49
  %66 = landingpad { ptr, i32 }
          cleanup
  br label %69

67:                                               ; preds = %52
  %68 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %16) #7
  br label %69

69:                                               ; preds = %67, %65
  %.pn = phi { ptr, i32 } [ %68, %67 ], [ %66, %65 ]
  call void @_ZNSt15__new_allocatorIiED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %18) #7
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %18) #7
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %17) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %16) #7
  br label %188

70:                                               ; preds = %106, %103, %90, %82, %79, %53
  %71 = landingpad { ptr, i32 }
          cleanup
  br label %187

72:                                               ; preds = %57, %54
  %73 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN7Riemann8GeometryESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef 2) #7
  %74 = load ptr, ptr %73, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %20) #7
  %75 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN7Riemann8GeometryESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef 2) #7
  %76 = load ptr, ptr %75, align 8, !tbaa !5
  %77 = call noundef nonnull align 4 dereferenceable(12) ptr @_ZNK7Riemann8Geometry16GetWorldPositionEv(ptr noundef nonnull align 8 dereferenceable(204) %76)
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %21) #7
  call void @_ZN5Maths8TVector3IfEC2Efff(ptr noundef nonnull align 4 dereferenceable(12) %21, float noundef -1.000000e+01, float noundef -1.000000e+01, float noundef -1.000000e+01)
  invoke void @_ZNK5Maths8TVector3IfEplERKS1_(ptr dead_on_unwind nonnull writable sret(%"class.Maths::TVector3") align 4 %20, ptr noundef nonnull align 4 dereferenceable(12) %77, ptr noundef nonnull align 4 dereferenceable(12) %21)
          to label %78 unwind label %88

78:                                               ; preds = %72
  invoke void @_ZN7Riemann8Geometry16SetWorldPositionERKN5Maths8TVector3IfEE(ptr noundef nonnull align 8 dereferenceable(204) %74, ptr noundef nonnull align 4 dereferenceable(12) %20)
          to label %79 unwind label %88

79:                                               ; preds = %78
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %21) #7
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %20) #7
  %80 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN7Riemann8GeometryESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef 2) #7
  %81 = load ptr, ptr %80, align 8, !tbaa !5
  invoke void @_ZN7Riemann8Geometry20UpdateBoundingVolumeEv(ptr noundef nonnull align 8 dereferenceable(204) %81)
          to label %82 unwind label %70

82:                                               ; preds = %79
  invoke void @_ZN7Riemann14IncrementalSAP16IncrementalPruneEPSt3setImSt4lessImESaImEE(ptr noundef nonnull align 8 dereferenceable(65) %15, ptr noundef nonnull %19)
          to label %83 unwind label %70

83:                                               ; preds = %82
  %84 = call noundef i64 @_ZNKSt3setImSt4lessImESaImEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(48) %19) #7
  %85 = icmp eq i64 %84, 2
  br i1 %85, label %90, label %86

86:                                               ; preds = %83
  %87 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.1, ptr noundef nonnull @.str.2, i32 noundef 792)
  call void @_Z10BreakPointPKcl(ptr noundef nonnull @.str.2, i64 noundef 792)
  br label %90

88:                                               ; preds = %78, %72
  %89 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %21) #7
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %20) #7
  br label %187

90:                                               ; preds = %86, %83
  invoke void @_ZN7Riemann14IncrementalSAP16IncrementalPruneEPSt3setImSt4lessImESaImEE(ptr noundef nonnull align 8 dereferenceable(65) %15, ptr noundef nonnull %19)
          to label %91 unwind label %70

91:                                               ; preds = %90
  %92 = call noundef i64 @_ZNKSt3setImSt4lessImESaImEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(48) %19) #7
  %93 = icmp eq i64 %92, 2
  br i1 %93, label %96, label %94

94:                                               ; preds = %91
  %95 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.1, ptr noundef nonnull @.str.2, i32 noundef 795)
  call void @_Z10BreakPointPKcl(ptr noundef nonnull @.str.2, i64 noundef 795)
  br label %96

96:                                               ; preds = %94, %91
  %97 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN7Riemann8GeometryESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef 2) #7
  %98 = load ptr, ptr %97, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %22) #7
  %99 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN7Riemann8GeometryESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef 2) #7
  %100 = load ptr, ptr %99, align 8, !tbaa !5
  %101 = call noundef nonnull align 4 dereferenceable(12) ptr @_ZNK7Riemann8Geometry16GetWorldPositionEv(ptr noundef nonnull align 8 dereferenceable(204) %100)
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %23) #7
  call void @_ZN5Maths8TVector3IfEC2Efff(ptr noundef nonnull align 4 dereferenceable(12) %23, float noundef 1.000000e+01, float noundef 1.000000e+01, float noundef 1.000000e+01)
  invoke void @_ZNK5Maths8TVector3IfEplERKS1_(ptr dead_on_unwind nonnull writable sret(%"class.Maths::TVector3") align 4 %22, ptr noundef nonnull align 4 dereferenceable(12) %101, ptr noundef nonnull align 4 dereferenceable(12) %23)
          to label %102 unwind label %112

102:                                              ; preds = %96
  invoke void @_ZN7Riemann8Geometry16SetWorldPositionERKN5Maths8TVector3IfEE(ptr noundef nonnull align 8 dereferenceable(204) %98, ptr noundef nonnull align 4 dereferenceable(12) %22)
          to label %103 unwind label %112

103:                                              ; preds = %102
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %23) #7
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %22) #7
  %104 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN7Riemann8GeometryESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef 2) #7
  %105 = load ptr, ptr %104, align 8, !tbaa !5
  invoke void @_ZN7Riemann8Geometry20UpdateBoundingVolumeEv(ptr noundef nonnull align 8 dereferenceable(204) %105)
          to label %106 unwind label %70

106:                                              ; preds = %103
  invoke void @_ZN7Riemann14IncrementalSAP16IncrementalPruneEPSt3setImSt4lessImESaImEE(ptr noundef nonnull align 8 dereferenceable(65) %15, ptr noundef nonnull %19)
          to label %107 unwind label %70

107:                                              ; preds = %106
  %108 = call noundef i64 @_ZNKSt3setImSt4lessImESaImEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(48) %19) #7
  %109 = icmp eq i64 %108, 0
  br i1 %109, label %.preheader44, label %110

.preheader44:                                     ; preds = %110, %107
  br label %115

110:                                              ; preds = %107
  %111 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.1, ptr noundef nonnull @.str.2, i32 noundef 800)
  call void @_Z10BreakPointPKcl(ptr noundef nonnull @.str.2, i64 noundef 800)
  br label %.preheader44

112:                                              ; preds = %102, %96
  %113 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %23) #7
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %22) #7
  br label %187

114:                                              ; preds = %124
  call void @_ZN7Riemann14IncrementalSAP8SetDirtyEv(ptr noundef nonnull align 8 dereferenceable(65) %15)
  br label %135

115:                                              ; preds = %.preheader44, %124
  %.01736 = phi i32 [ %125, %124 ], [ 0, %.preheader44 ]
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %24) #7
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %25) #7
  invoke void @_ZN5Maths8TVector3IfE6RandomEv(ptr dead_on_unwind nonnull writable sret(%"class.Maths::TVector3") align 4 %25)
          to label %116 unwind label %126

116:                                              ; preds = %115
  invoke void @_ZNK5Maths8TVector3IfEmlEf(ptr dead_on_unwind nonnull writable sret(%"class.Maths::TVector3") align 4 %24, ptr noundef nonnull align 4 dereferenceable(12) %25, float noundef 1.000000e+02)
          to label %117 unwind label %126

117:                                              ; preds = %116
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %25) #7
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %26) #7
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %27) #7
  invoke void @_ZN5Maths8TVector3IfE6RandomEv(ptr dead_on_unwind nonnull writable sret(%"class.Maths::TVector3") align 4 %27)
          to label %118 unwind label %128

118:                                              ; preds = %117
  invoke void @_ZNK5Maths8TVector3IfEmlEf(ptr dead_on_unwind nonnull writable sret(%"class.Maths::TVector3") align 4 %26, ptr noundef nonnull align 4 dereferenceable(12) %27, float noundef 1.000000e+02)
          to label %119 unwind label %128

119:                                              ; preds = %118
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %27) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %28) #7
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %29) #7
  invoke void @_ZN5Maths10Quaternion3OneEv(ptr dead_on_unwind nonnull writable sret(%"class.Maths::Quaternion") align 4 %29)
          to label %120 unwind label %130

120:                                              ; preds = %119
  %121 = invoke noundef ptr @_ZN7Riemann15GeometryFactory9CreateOBBERKN5Maths8TVector3IfEES5_RKNS1_10QuaternionE(ptr noundef nonnull align 4 dereferenceable(12) %24, ptr noundef nonnull align 4 dereferenceable(12) %26, ptr noundef nonnull align 4 dereferenceable(16) %29)
          to label %122 unwind label %130

122:                                              ; preds = %120
  store ptr %121, ptr %28, align 8, !tbaa !5
  %123 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN7Riemann8GeometryESaIS2_EE12emplace_backIJS2_EEERS2_DpOT_(ptr noundef nonnull align 8 dereferenceable(24) %1, ptr noundef nonnull align 8 dereferenceable(8) %28)
          to label %124 unwind label %130

124:                                              ; preds = %122
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %29) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %28) #7
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %26) #7
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %24) #7
  %125 = add nuw nsw i32 %.01736, 1
  %exitcond.not = icmp eq i32 %125, 100
  br i1 %exitcond.not, label %114, label %115, !llvm.loop !11

126:                                              ; preds = %116, %115
  %127 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %25) #7
  br label %133

128:                                              ; preds = %118, %117
  %129 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %27) #7
  br label %132

130:                                              ; preds = %122, %120, %119
  %131 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %29) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %28) #7
  br label %132

132:                                              ; preds = %130, %128
  %.pn29 = phi { ptr, i32 } [ %131, %130 ], [ %129, %128 ]
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %26) #7
  br label %133

133:                                              ; preds = %132, %126
  %.pn29.pn = phi { ptr, i32 } [ %.pn29, %132 ], [ %127, %126 ]
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %24) #7
  br label %187

134:                                              ; preds = %._crit_edge39
  call void @_ZNSt3setImSt4lessImESaImEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %19) #7
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %19) #7
  call void @_ZN7Riemann3SAPD2Ev(ptr noundef nonnull align 8 dereferenceable(65) %15) #7
  call void @llvm.lifetime.end.p0(i64 72, ptr nonnull %15) #7
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %14) #7
  call void @_ZNSt6vectorIPN7Riemann8GeometryESaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %1) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %1) #7
  ret void

135:                                              ; preds = %114, %._crit_edge39
  %.01640 = phi i32 [ 0, %114 ], [ %151, %._crit_edge39 ]
  %136 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN7Riemann8GeometryESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef 2) #7
  %137 = load ptr, ptr %136, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %30) #7
  %138 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN7Riemann8GeometryESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef 2) #7
  %139 = load ptr, ptr %138, align 8, !tbaa !5
  %140 = call noundef nonnull align 4 dereferenceable(12) ptr @_ZNK7Riemann8Geometry16GetWorldPositionEv(ptr noundef nonnull align 8 dereferenceable(204) %139)
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %31) #7
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %32) #7
  invoke void @_ZN5Maths8TVector3IfE6RandomEv(ptr dead_on_unwind nonnull writable sret(%"class.Maths::TVector3") align 4 %32)
          to label %141 unwind label %152

141:                                              ; preds = %135
  invoke void @_ZNK5Maths8TVector3IfEmlEf(ptr dead_on_unwind nonnull writable sret(%"class.Maths::TVector3") align 4 %31, ptr noundef nonnull align 4 dereferenceable(12) %32, float noundef 2.000000e+01)
          to label %142 unwind label %152

142:                                              ; preds = %141
  invoke void @_ZNK5Maths8TVector3IfEplERKS1_(ptr dead_on_unwind nonnull writable sret(%"class.Maths::TVector3") align 4 %30, ptr noundef nonnull align 4 dereferenceable(12) %140, ptr noundef nonnull align 4 dereferenceable(12) %31)
          to label %143 unwind label %152

143:                                              ; preds = %142
  invoke void @_ZN7Riemann8Geometry16SetWorldPositionERKN5Maths8TVector3IfEE(ptr noundef nonnull align 8 dereferenceable(204) %137, ptr noundef nonnull align 4 dereferenceable(12) %30)
          to label %144 unwind label %152

144:                                              ; preds = %143
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %32) #7
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %31) #7
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %30) #7
  %145 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN7Riemann8GeometryESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef 2) #7
  %146 = load ptr, ptr %145, align 8, !tbaa !5
  invoke void @_ZN7Riemann8Geometry20UpdateBoundingVolumeEv(ptr noundef nonnull align 8 dereferenceable(204) %146)
          to label %147 unwind label %154

147:                                              ; preds = %144
  invoke void @_ZN7Riemann14IncrementalSAP16IncrementalPruneEPSt3setImSt4lessImESaImEE(ptr noundef nonnull align 8 dereferenceable(65) %15, ptr noundef nonnull %19)
          to label %.preheader35 unwind label %154

.preheader35:                                     ; preds = %147
  %148 = call noundef i64 @_ZNKSt6vectorIPN7Riemann8GeometryESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #7
  %.not = icmp eq i64 %148, 0
  br i1 %.not, label %._crit_edge39, label %.preheader

.preheader:                                       ; preds = %.preheader35, %._crit_edge
  %.01538 = phi i64 [ %156, %._crit_edge ], [ 0, %.preheader35 ]
  %149 = call noundef i64 @_ZNKSt6vectorIPN7Riemann8GeometryESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #7
  %.not41 = icmp eq i64 %149, 0
  br i1 %.not41, label %._crit_edge, label %.lr.ph

.lr.ph:                                           ; preds = %.preheader
  %150 = trunc i64 %.01538 to i32
  br label %159

._crit_edge39:                                    ; preds = %._crit_edge, %.preheader35
  %151 = add nuw nsw i32 %.01640, 1
  %exitcond42.not = icmp eq i32 %151, 10
  br i1 %exitcond42.not, label %134, label %135, !llvm.loop !13

152:                                              ; preds = %143, %142, %141, %135
  %153 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %32) #7
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %31) #7
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %30) #7
  br label %187

154:                                              ; preds = %147, %144
  %155 = landingpad { ptr, i32 }
          cleanup
  br label %187

._crit_edge:                                      ; preds = %183, %.preheader
  %156 = add nuw i64 %.01538, 1
  %157 = call noundef i64 @_ZNKSt6vectorIPN7Riemann8GeometryESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #7
  %158 = icmp ult i64 %156, %157
  br i1 %158, label %.preheader, label %._crit_edge39, !llvm.loop !14

159:                                              ; preds = %.lr.ph, %183
  %.037 = phi i64 [ 0, %.lr.ph ], [ %184, %183 ]
  %160 = icmp eq i64 %.01538, %.037
  br i1 %160, label %183, label %161

161:                                              ; preds = %159
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %33) #7
  %162 = trunc i64 %.037 to i32
  %163 = call noundef i64 @_ZN7Riemann3SAP14PackOverlapKeyEii(i32 noundef %150, i32 noundef %162)
  store i64 %163, ptr %33, align 8, !tbaa !15
  %164 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN7Riemann8GeometryESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef %.01538) #7
  %165 = load ptr, ptr %164, align 8, !tbaa !5
  %166 = call noundef nonnull align 4 dereferenceable(24) ptr @_ZNK7Riemann8Geometry28GetBoundingVolume_WorldSpaceEv(ptr noundef nonnull align 8 dereferenceable(204) %165)
  %167 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN7Riemann8GeometryESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef %.037) #7
  %168 = load ptr, ptr %167, align 8, !tbaa !5
  %169 = call noundef nonnull align 4 dereferenceable(24) ptr @_ZNK7Riemann8Geometry28GetBoundingVolume_WorldSpaceEv(ptr noundef nonnull align 8 dereferenceable(204) %168)
  %170 = call noundef zeroext i1 @_ZNK5Maths6TAABB3IfE9IntersectERKS1_(ptr noundef nonnull align 4 dereferenceable(24) %166, ptr noundef nonnull align 4 dereferenceable(24) %169)
  br i1 %170, label %171, label %177

171:                                              ; preds = %161
  %172 = invoke noundef i64 @_ZNKSt3setImSt4lessImESaImEE5countERKm(ptr noundef nonnull align 8 dereferenceable(48) %19, ptr noundef nonnull align 8 dereferenceable(8) %33)
          to label %173 unwind label %175

173:                                              ; preds = %171
  %174 = icmp eq i64 %172, 1
  br i1 %174, label %182, label %.sink.split

175:                                              ; preds = %177, %171
  %176 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %33) #7
  br label %187

177:                                              ; preds = %161
  %178 = invoke noundef i64 @_ZNKSt3setImSt4lessImESaImEE5countERKm(ptr noundef nonnull align 8 dereferenceable(48) %19, ptr noundef nonnull align 8 dereferenceable(8) %33)
          to label %179 unwind label %175

179:                                              ; preds = %177
  %180 = icmp eq i64 %178, 0
  br i1 %180, label %182, label %.sink.split

.sink.split:                                      ; preds = %179, %173
  %.sink43 = phi i32 [ 823, %173 ], [ 827, %179 ]
  %.sink = phi i64 [ 823, %173 ], [ 827, %179 ]
  %181 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.1, ptr noundef nonnull @.str.2, i32 noundef %.sink43)
  call void @_Z10BreakPointPKcl(ptr noundef nonnull @.str.2, i64 noundef %.sink)
  br label %182

182:                                              ; preds = %.sink.split, %179, %173
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %33) #7
  br label %183

183:                                              ; preds = %159, %182
  %184 = add nuw i64 %.037, 1
  %185 = call noundef i64 @_ZNKSt6vectorIPN7Riemann8GeometryESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #7
  %186 = icmp ult i64 %184, %185
  br i1 %186, label %159, label %._crit_edge, !llvm.loop !17

187:                                              ; preds = %152, %154, %175, %133, %112, %88, %70
  %.pn29.pn.pn = phi { ptr, i32 } [ %.pn29.pn, %133 ], [ %71, %70 ], [ %113, %112 ], [ %89, %88 ], [ %176, %175 ], [ %155, %154 ], [ %153, %152 ]
  call void @_ZNSt3setImSt4lessImESaImEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %19) #7
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %19) #7
  call void @_ZN7Riemann3SAPD2Ev(ptr noundef nonnull align 8 dereferenceable(65) %15) #7
  br label %188

188:                                              ; preds = %187, %69
  %.pn29.pn.pn.pn = phi { ptr, i32 } [ %.pn29.pn.pn, %187 ], [ %.pn, %69 ]
  call void @llvm.lifetime.end.p0(i64 72, ptr nonnull %15) #7
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %14) #7
  br label %189

189:                                              ; preds = %188, %63, %61, %59
  %.pn29.pn.pn.pn.pn = phi { ptr, i32 } [ %.pn29.pn.pn.pn, %188 ], [ %64, %63 ], [ %62, %61 ], [ %60, %59 ]
  call void @_ZNSt6vectorIPN7Riemann8GeometryESaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %1) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %1) #7
  resume { ptr, i32 } %.pn29.pn.pn.pn.pn
}

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN7BVProxyC2EPSt6vectorIPN7Riemann8GeometryESaIS3_EE(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef) unnamed_addr #6 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN7Riemann14IncrementalSAPC2EPNS_3SAP19BoundingVolumeProxyERKSt6vectorIiSaIiEE(ptr noundef nonnull align 8 dereferenceable(65), ptr noundef, ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #3 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN7Riemann14IncrementalSAP16IncrementalPruneEPSt3setImSt4lessImESaImEE(ptr noundef nonnull align 8 dereferenceable(65), ptr noundef) local_unnamed_addr #3 align 2

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(12) ptr @_ZNK7Riemann8Geometry16GetWorldPositionEv(ptr noundef nonnull align 8 dereferenceable(204)) local_unnamed_addr #2 align 2

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt15__new_allocatorIiED2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #6 align 2

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

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"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 = distinct !{!11, !12}
!12 = !{!"llvm.loop.mustprogress"}
!13 = distinct !{!13, !12}
!14 = distinct !{!14, !12}
!15 = !{!16, !16, i64 0}
!16 = !{!"long", !7, i64 0}
!17 = distinct !{!17, !12}


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