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

; 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.std::vector.18" = type { %"struct.std::_Vector_base.19" }
%"struct.std::_Vector_base.19" = type { %"struct.std::_Vector_base<Maths::TAABB3<float>, std::allocator<Maths::TAABB3<float>>>::_Vector_impl" }
%"struct.std::_Vector_base<Maths::TAABB3<float>, std::allocator<Maths::TAABB3<float>>>::_Vector_impl" = type { %"struct.std::_Vector_base<Maths::TAABB3<float>, std::allocator<Maths::TAABB3<float>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<Maths::TAABB3<float>, std::allocator<Maths::TAABB3<float>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.Riemann::AABBTree" = type { ptr, i32, ptr }
%"struct.Riemann::AABBTreeBuildData" = type <{ i32, i32, ptr, ptr, ptr, ptr, i8, [7 x i8] }>
%"struct.Riemann::RayCastOption" = type { i32, [4 x i8], %"struct.Riemann::RayCastCache", i8, float, i32, %"struct.Riemann::CollisionData", ptr }
%"struct.Riemann::RayCastCache" = type <{ ptr, %"class.Riemann::StaticStack", [4 x i8] }>
%"class.Riemann::StaticStack" = type { i32, [32 x i32] }
%"struct.Riemann::CollisionData" = type { i32, i32, i32, i32 }
%"struct.Riemann::RayCastResult" = type <{ i8, [3 x i8], float, float, %"class.Maths::TVector3", %"class.Maths::TVector3", [4 x i8], ptr, %"class.std::vector.23", i32, [4 x i8] }>
%"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.Ray3 = type { %"class.Maths::TVector3", %"class.Maths::TVector3" }
%"struct.Riemann::TreeStatistics" = type { i32, i32, i32, i32, i32 }
%"class.Maths::TAABB3" = type { %"class.Maths::TVector3", %"class.Maths::TVector3" }

@.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.19 = external hidden unnamed_addr constant [22 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: inlinehint mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(12) ptr @_ZN5Maths8TVector3IfEaSERKS1_(ptr noundef nonnull align 4 dereferenceable(12), ptr noundef nonnull align 4 dereferenceable(12)) #2 align 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(...)

; 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: 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: mustprogress uwtable
define dso_local void @_Z12TestAABBTreev() #3 personality ptr @__gxx_personality_v0 {
  %1 = alloca %"class.std::vector.18", align 8
  %2 = alloca %"class.Maths::TVector3", align 4
  %3 = alloca ptr, align 8
  %4 = alloca i32, align 4
  %5 = alloca %"class.Maths::TVector3", align 4
  %6 = alloca %"class.Maths::TVector3", align 4
  %7 = alloca %"class.Maths::TVector3", align 4
  %8 = alloca %"class.Maths::TVector3", align 4
  %9 = alloca %"class.Maths::TVector3", align 4
  %10 = alloca %"class.Riemann::AABBTree", align 8
  %11 = alloca %"struct.Riemann::AABBTreeBuildData", align 8
  %12 = alloca i32, align 4
  %13 = alloca %"class.Maths::TVector3", align 4
  %14 = alloca %"class.Maths::TVector3", align 4
  %15 = alloca %"class.Maths::TVector3", align 4
  %16 = alloca %"struct.Riemann::RayCastOption", align 8
  %17 = alloca %"struct.Riemann::RayCastResult", align 8
  %18 = alloca %class.Ray3, align 4
  %19 = alloca %"class.Maths::TVector3", align 4
  %20 = alloca %"class.Maths::TVector3", align 4
  %21 = alloca i8, align 1
  %22 = alloca %"class.Maths::TVector3", align 4
  %23 = alloca i32, 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 %"class.Maths::TVector3", align 4
  %29 = alloca %"struct.Riemann::AABBTreeBuildData", align 8
  %30 = alloca %"struct.Riemann::TreeStatistics", align 4
  %31 = alloca i32, align 4
  %32 = alloca %"class.Maths::TVector3", align 4
  %33 = alloca %"class.Maths::TVector3", align 4
  %34 = alloca %"class.Maths::TAABB3", align 4
  %35 = call i32 (ptr, ...) @printf(ptr noundef @.str.19)
  call void @llvm.lifetime.start.p0(i64 24, ptr %1) #7
  call void @_ZNSt6vectorIN5Maths6TAABB3IfEESaIS2_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %1) #7
  call void @llvm.lifetime.start.p0(i64 12, ptr %2) #7
  invoke void @_ZN5Maths8TVector3IfEC2Efff(ptr noundef nonnull align 4 dereferenceable(12) %2, float noundef 0.000000e+00, float noundef 0.000000e+00, float noundef 0.000000e+00)
          to label %36 unwind label %64

36:                                               ; preds = %0
  call void @llvm.lifetime.start.p0(i64 12, ptr %5) #7
  invoke void @_ZN5Maths8TVector3IfEC2Efff(ptr noundef nonnull align 4 dereferenceable(12) %5, float noundef 1.000000e+00, float noundef 1.000000e+00, float noundef 1.000000e+00)
          to label %37 unwind label %68

37:                                               ; preds = %36
  %38 = invoke noundef nonnull align 4 dereferenceable(24) ptr @_ZNSt6vectorIN5Maths6TAABB3IfEESaIS2_EE12emplace_backIJNS0_8TVector3IfEES7_EEERS2_DpOT_(ptr noundef nonnull align 8 dereferenceable(24) %1, ptr noundef nonnull align 4 dereferenceable(12) %2, ptr noundef nonnull align 4 dereferenceable(12) %5)
          to label %39 unwind label %68

39:                                               ; preds = %37
  call void @llvm.lifetime.end.p0(i64 12, ptr %5) #7
  call void @llvm.lifetime.end.p0(i64 12, ptr %2) #7
  call void @llvm.lifetime.start.p0(i64 12, ptr %6) #7
  invoke void @_ZN5Maths8TVector3IfEC2Efff(ptr noundef nonnull align 4 dereferenceable(12) %6, float noundef 0.000000e+00, float noundef 0.000000e+00, float noundef 0.000000e+00)
          to label %40 unwind label %73

40:                                               ; preds = %39
  call void @llvm.lifetime.start.p0(i64 12, ptr %7) #7
  invoke void @_ZN5Maths8TVector3IfEC2Efff(ptr noundef nonnull align 4 dereferenceable(12) %7, float noundef 1.000000e+00, float noundef 1.000000e+00, float noundef 3.000000e+00)
          to label %41 unwind label %77

41:                                               ; preds = %40
  %42 = invoke noundef nonnull align 4 dereferenceable(24) ptr @_ZNSt6vectorIN5Maths6TAABB3IfEESaIS2_EE12emplace_backIJNS0_8TVector3IfEES7_EEERS2_DpOT_(ptr noundef nonnull align 8 dereferenceable(24) %1, ptr noundef nonnull align 4 dereferenceable(12) %6, ptr noundef nonnull align 4 dereferenceable(12) %7)
          to label %43 unwind label %77

43:                                               ; preds = %41
  call void @llvm.lifetime.end.p0(i64 12, ptr %7) #7
  call void @llvm.lifetime.end.p0(i64 12, ptr %6) #7
  call void @llvm.lifetime.start.p0(i64 12, ptr %8) #7
  invoke void @_ZN5Maths8TVector3IfEC2Efff(ptr noundef nonnull align 4 dereferenceable(12) %8, float noundef 1.000000e+00, float noundef 1.000000e+00, float noundef 1.000000e+00)
          to label %44 unwind label %82

44:                                               ; preds = %43
  call void @llvm.lifetime.start.p0(i64 12, ptr %9) #7
  invoke void @_ZN5Maths8TVector3IfEC2Efff(ptr noundef nonnull align 4 dereferenceable(12) %9, float noundef 1.000000e+00, float noundef 1.000000e+00, float noundef 2.000000e+00)
          to label %45 unwind label %86

45:                                               ; preds = %44
  %46 = invoke noundef nonnull align 4 dereferenceable(24) ptr @_ZNSt6vectorIN5Maths6TAABB3IfEESaIS2_EE12emplace_backIJNS0_8TVector3IfEES7_EEERS2_DpOT_(ptr noundef nonnull align 8 dereferenceable(24) %1, ptr noundef nonnull align 4 dereferenceable(12) %8, ptr noundef nonnull align 4 dereferenceable(12) %9)
          to label %47 unwind label %86

47:                                               ; preds = %45
  call void @llvm.lifetime.end.p0(i64 12, ptr %9) #7
  call void @llvm.lifetime.end.p0(i64 12, ptr %8) #7
  call void @llvm.lifetime.start.p0(i64 24, ptr %10) #7
  invoke void @_ZN7Riemann8AABBTreeC1Ev(ptr noundef nonnull align 8 dereferenceable(24) %10)
          to label %48 unwind label %91

48:                                               ; preds = %47
  call void @llvm.lifetime.start.p0(i64 48, ptr %11) #7
  %49 = call noundef nonnull align 4 dereferenceable(24) ptr @_ZNSt6vectorIN5Maths6TAABB3IfEESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef 0) #7
  %50 = call noundef i64 @_ZNKSt6vectorIN5Maths6TAABB3IfEESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #7
  %51 = trunc i64 %50 to i32
  invoke void @_ZN7Riemann17AABBTreeBuildDataC2EPKN5Maths6TAABB3IfEEii(ptr noundef nonnull align 8 dereferenceable(41) %11, ptr noundef %49, i32 noundef %51, i32 noundef 1)
          to label %52 unwind label %95

52:                                               ; preds = %48
  invoke void @_ZN7Riemann8AABBTree7ReleaseEv(ptr noundef nonnull align 8 dereferenceable(24) %10)
          to label %53 unwind label %99

53:                                               ; preds = %52
  invoke void @_ZN7Riemann8AABBTree11StaticBuildERNS_17AABBTreeBuildDataE(ptr noundef nonnull align 8 dereferenceable(24) %10, ptr noundef nonnull align 8 dereferenceable(41) %11)
          to label %54 unwind label %99

54:                                               ; preds = %53
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #7
  call void @llvm.lifetime.start.p0(i64 12, ptr %13) #7
  invoke void @_ZN5Maths8TVector3IfEC2Efff(ptr noundef nonnull align 4 dereferenceable(12) %13, float noundef -1.000000e+00, float noundef -1.000000e+00, float noundef -1.000000e+00)
          to label %55 unwind label %103

55:                                               ; preds = %54
  %56 = invoke noundef i32 @_ZNK7Riemann8AABBTree14IntersectPointERKN5Maths8TVector3IfEE(ptr noundef nonnull align 8 dereferenceable(24) %10, ptr noundef nonnull align 4 dereferenceable(12) %13)
          to label %57 unwind label %103

57:                                               ; preds = %55
  call void @llvm.lifetime.end.p0(i64 12, ptr %13) #7
  store i32 %56, ptr %12, align 4, !tbaa !5
  %58 = load i32, ptr %12, align 4, !tbaa !5
  %59 = icmp eq i32 %58, -1
  br i1 %59, label %111, label %60

60:                                               ; preds = %57
  %61 = invoke i32 (ptr, ...) @printf(ptr noundef @.str.1, ptr noundef @.str.2, i32 noundef 575)
          to label %62 unwind label %107

62:                                               ; preds = %60
  invoke void @_Z10BreakPointPKcl(ptr noundef @.str.2, i64 noundef 575)
          to label %63 unwind label %107

63:                                               ; preds = %62
  br label %111

64:                                               ; preds = %0
  %65 = landingpad { ptr, i32 }
          cleanup
  %66 = extractvalue { ptr, i32 } %65, 0
  store ptr %66, ptr %3, align 8
  %67 = extractvalue { ptr, i32 } %65, 1
  store i32 %67, ptr %4, align 4
  br label %72

68:                                               ; preds = %37, %36
  %69 = landingpad { ptr, i32 }
          cleanup
  %70 = extractvalue { ptr, i32 } %69, 0
  store ptr %70, ptr %3, align 8
  %71 = extractvalue { ptr, i32 } %69, 1
  store i32 %71, ptr %4, align 4
  call void @llvm.lifetime.end.p0(i64 12, ptr %5) #7
  br label %72

72:                                               ; preds = %68, %64
  call void @llvm.lifetime.end.p0(i64 12, ptr %2) #7
  br label %296

73:                                               ; preds = %39
  %74 = landingpad { ptr, i32 }
          cleanup
  %75 = extractvalue { ptr, i32 } %74, 0
  store ptr %75, ptr %3, align 8
  %76 = extractvalue { ptr, i32 } %74, 1
  store i32 %76, ptr %4, align 4
  br label %81

77:                                               ; preds = %41, %40
  %78 = landingpad { ptr, i32 }
          cleanup
  %79 = extractvalue { ptr, i32 } %78, 0
  store ptr %79, ptr %3, align 8
  %80 = extractvalue { ptr, i32 } %78, 1
  store i32 %80, ptr %4, align 4
  call void @llvm.lifetime.end.p0(i64 12, ptr %7) #7
  br label %81

81:                                               ; preds = %77, %73
  call void @llvm.lifetime.end.p0(i64 12, ptr %6) #7
  br label %296

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

86:                                               ; preds = %45, %44
  %87 = landingpad { ptr, i32 }
          cleanup
  %88 = extractvalue { ptr, i32 } %87, 0
  store ptr %88, ptr %3, align 8
  %89 = extractvalue { ptr, i32 } %87, 1
  store i32 %89, ptr %4, align 4
  call void @llvm.lifetime.end.p0(i64 12, ptr %9) #7
  br label %90

90:                                               ; preds = %86, %82
  call void @llvm.lifetime.end.p0(i64 12, ptr %8) #7
  br label %296

91:                                               ; preds = %47
  %92 = landingpad { ptr, i32 }
          cleanup
  %93 = extractvalue { ptr, i32 } %92, 0
  store ptr %93, ptr %3, align 8
  %94 = extractvalue { ptr, i32 } %92, 1
  store i32 %94, ptr %4, align 4
  br label %295

95:                                               ; preds = %48
  %96 = landingpad { ptr, i32 }
          cleanup
  %97 = extractvalue { ptr, i32 } %96, 0
  store ptr %97, ptr %3, align 8
  %98 = extractvalue { ptr, i32 } %96, 1
  store i32 %98, ptr %4, align 4
  br label %294

99:                                               ; preds = %53, %52
  %100 = landingpad { ptr, i32 }
          cleanup
  %101 = extractvalue { ptr, i32 } %100, 0
  store ptr %101, ptr %3, align 8
  %102 = extractvalue { ptr, i32 } %100, 1
  store i32 %102, ptr %4, align 4
  br label %293

103:                                              ; preds = %55, %54
  %104 = landingpad { ptr, i32 }
          cleanup
  %105 = extractvalue { ptr, i32 } %104, 0
  store ptr %105, ptr %3, align 8
  %106 = extractvalue { ptr, i32 } %104, 1
  store i32 %106, ptr %4, align 4
  call void @llvm.lifetime.end.p0(i64 12, ptr %13) #7
  br label %292

107:                                              ; preds = %133, %131, %119, %117, %62, %60
  %108 = landingpad { ptr, i32 }
          cleanup
  %109 = extractvalue { ptr, i32 } %108, 0
  store ptr %109, ptr %3, align 8
  %110 = extractvalue { ptr, i32 } %108, 1
  store i32 %110, ptr %4, align 4
  br label %292

111:                                              ; preds = %63, %57
  call void @llvm.lifetime.start.p0(i64 12, ptr %14) #7
  invoke void @_ZN5Maths8TVector3IfEC2Efff(ptr noundef nonnull align 4 dereferenceable(12) %14, float noundef 5.000000e-01, float noundef 5.000000e-01, float noundef 5.000000e-01)
          to label %112 unwind label %121

112:                                              ; preds = %111
  %113 = invoke noundef i32 @_ZNK7Riemann8AABBTree14IntersectPointERKN5Maths8TVector3IfEE(ptr noundef nonnull align 8 dereferenceable(24) %10, ptr noundef nonnull align 4 dereferenceable(12) %14)
          to label %114 unwind label %121

114:                                              ; preds = %112
  store i32 %113, ptr %12, align 4, !tbaa !5
  call void @llvm.lifetime.end.p0(i64 12, ptr %14) #7
  %115 = load i32, ptr %12, align 4, !tbaa !5
  %116 = icmp sge i32 %115, 0
  br i1 %116, label %125, label %117

117:                                              ; preds = %114
  %118 = invoke i32 (ptr, ...) @printf(ptr noundef @.str.1, ptr noundef @.str.2, i32 noundef 577)
          to label %119 unwind label %107

119:                                              ; preds = %117
  invoke void @_Z10BreakPointPKcl(ptr noundef @.str.2, i64 noundef 577)
          to label %120 unwind label %107

120:                                              ; preds = %119
  br label %125

121:                                              ; preds = %112, %111
  %122 = landingpad { ptr, i32 }
          cleanup
  %123 = extractvalue { ptr, i32 } %122, 0
  store ptr %123, ptr %3, align 8
  %124 = extractvalue { ptr, i32 } %122, 1
  store i32 %124, ptr %4, align 4
  call void @llvm.lifetime.end.p0(i64 12, ptr %14) #7
  br label %292

125:                                              ; preds = %120, %114
  call void @llvm.lifetime.start.p0(i64 12, ptr %15) #7
  invoke void @_ZN5Maths8TVector3IfEC2Efff(ptr noundef nonnull align 4 dereferenceable(12) %15, float noundef 5.000000e-01, float noundef 5.000000e-01, float noundef 2.500000e+00)
          to label %126 unwind label %135

126:                                              ; preds = %125
  %127 = invoke noundef i32 @_ZNK7Riemann8AABBTree14IntersectPointERKN5Maths8TVector3IfEE(ptr noundef nonnull align 8 dereferenceable(24) %10, ptr noundef nonnull align 4 dereferenceable(12) %15)
          to label %128 unwind label %135

128:                                              ; preds = %126
  store i32 %127, ptr %12, align 4, !tbaa !5
  call void @llvm.lifetime.end.p0(i64 12, ptr %15) #7
  %129 = load i32, ptr %12, align 4, !tbaa !5
  %130 = icmp eq i32 %129, 1
  br i1 %130, label %139, label %131

131:                                              ; preds = %128
  %132 = invoke i32 (ptr, ...) @printf(ptr noundef @.str.1, ptr noundef @.str.2, i32 noundef 579)
          to label %133 unwind label %107

133:                                              ; preds = %131
  invoke void @_Z10BreakPointPKcl(ptr noundef @.str.2, i64 noundef 579)
          to label %134 unwind label %107

134:                                              ; preds = %133
  br label %139

135:                                              ; preds = %126, %125
  %136 = landingpad { ptr, i32 }
          cleanup
  %137 = extractvalue { ptr, i32 } %136, 0
  store ptr %137, ptr %3, align 8
  %138 = extractvalue { ptr, i32 } %136, 1
  store i32 %138, ptr %4, align 4
  call void @llvm.lifetime.end.p0(i64 12, ptr %15) #7
  br label %292

139:                                              ; preds = %134, %128
  call void @llvm.lifetime.start.p0(i64 192, ptr %16) #7
  invoke void @_ZN7Riemann13RayCastOptionC2Ev(ptr noundef nonnull align 8 dereferenceable(192) %16)
          to label %140 unwind label %154

140:                                              ; preds = %139
  call void @llvm.lifetime.start.p0(i64 80, ptr %17) #7
  invoke void @_ZN7Riemann13RayCastResultC2Ev(ptr noundef nonnull align 8 dereferenceable(76) %17)
          to label %141 unwind label %158

141:                                              ; preds = %140
  call void @llvm.lifetime.start.p0(i64 24, ptr %18) #7
  call void @llvm.lifetime.start.p0(i64 12, ptr %19) #7
  invoke void @_ZN5Maths8TVector3IfEC2Efff(ptr noundef nonnull align 4 dereferenceable(12) %19, float noundef 5.000000e-01, float noundef 5.000000e-01, float noundef 1.000000e+02)
          to label %142 unwind label %162

142:                                              ; preds = %141
  call void @llvm.lifetime.start.p0(i64 12, ptr %20) #7
  invoke void @_ZN5Maths8TVector3IfEC2Efff(ptr noundef nonnull align 4 dereferenceable(12) %20, float noundef 0.000000e+00, float noundef 0.000000e+00, float noundef -1.000000e+00)
          to label %143 unwind label %166

143:                                              ; preds = %142
  invoke void @_ZN4Ray3C2ERKN5Maths8TVector3IfEES4_b(ptr noundef nonnull align 4 dereferenceable(24) %18, ptr noundef nonnull align 4 dereferenceable(12) %19, ptr noundef nonnull align 4 dereferenceable(12) %20, i1 noundef zeroext false)
          to label %144 unwind label %166

144:                                              ; preds = %143
  call void @llvm.lifetime.end.p0(i64 12, ptr %20) #7
  call void @llvm.lifetime.end.p0(i64 12, ptr %19) #7
  call void @llvm.lifetime.start.p0(i64 1, ptr %21) #7
  %145 = invoke noundef zeroext i1 @_ZNK7Riemann8AABBTree18RayCastBoundingBoxERK4Ray3RKNS_13RayCastOptionEPNS_13RayCastResultE(ptr noundef nonnull align 8 dereferenceable(24) %10, ptr noundef nonnull align 4 dereferenceable(24) %18, ptr noundef nonnull align 8 dereferenceable(192) %16, ptr noundef %17)
          to label %146 unwind label %171

146:                                              ; preds = %144
  %147 = zext i1 %145 to i8
  store i8 %147, ptr %21, align 1, !tbaa !9
  %148 = load i8, ptr %21, align 1, !tbaa !9, !range !11, !noundef !12
  %149 = trunc i8 %148 to i1
  br i1 %149, label %175, label %150

150:                                              ; preds = %146
  %151 = invoke i32 (ptr, ...) @printf(ptr noundef @.str.1, ptr noundef @.str.2, i32 noundef 585)
          to label %152 unwind label %171

152:                                              ; preds = %150
  invoke void @_Z10BreakPointPKcl(ptr noundef @.str.2, i64 noundef 585)
          to label %153 unwind label %171

153:                                              ; preds = %152
  br label %175

154:                                              ; preds = %139
  %155 = landingpad { ptr, i32 }
          cleanup
  %156 = extractvalue { ptr, i32 } %155, 0
  store ptr %156, ptr %3, align 8
  %157 = extractvalue { ptr, i32 } %155, 1
  store i32 %157, ptr %4, align 4
  br label %291

158:                                              ; preds = %140
  %159 = landingpad { ptr, i32 }
          cleanup
  %160 = extractvalue { ptr, i32 } %159, 0
  store ptr %160, ptr %3, align 8
  %161 = extractvalue { ptr, i32 } %159, 1
  store i32 %161, ptr %4, align 4
  br label %290

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

166:                                              ; preds = %143, %142
  %167 = landingpad { ptr, i32 }
          cleanup
  %168 = extractvalue { ptr, i32 } %167, 0
  store ptr %168, ptr %3, align 8
  %169 = extractvalue { ptr, i32 } %167, 1
  store i32 %169, ptr %4, align 4
  call void @llvm.lifetime.end.p0(i64 12, ptr %20) #7
  br label %170

170:                                              ; preds = %166, %162
  call void @llvm.lifetime.end.p0(i64 12, ptr %19) #7
  br label %289

171:                                              ; preds = %187, %185, %179, %152, %150, %144
  %172 = landingpad { ptr, i32 }
          cleanup
  %173 = extractvalue { ptr, i32 } %172, 0
  store ptr %173, ptr %3, align 8
  %174 = extractvalue { ptr, i32 } %172, 1
  store i32 %174, ptr %4, align 4
  br label %288

175:                                              ; preds = %153, %146
  call void @llvm.lifetime.start.p0(i64 12, ptr %22) #7
  invoke void @_ZN5Maths8TVector3IfEC2Efff(ptr noundef nonnull align 4 dereferenceable(12) %22, float noundef 5.000000e-01, float noundef 5.000000e-01, float noundef 5.000000e-01)
          to label %176 unwind label %189

176:                                              ; preds = %175
  %177 = getelementptr inbounds %class.Ray3, ptr %18, i32 0, i32 0
  %178 = invoke noundef nonnull align 4 dereferenceable(12) ptr @_ZN5Maths8TVector3IfEaSERKS1_(ptr noundef nonnull align 4 dereferenceable(12) %177, ptr noundef nonnull align 4 dereferenceable(12) %22)
          to label %179 unwind label %189

179:                                              ; preds = %176
  call void @llvm.lifetime.end.p0(i64 12, ptr %22) #7
  %180 = invoke noundef zeroext i1 @_ZNK7Riemann8AABBTree18RayCastBoundingBoxERK4Ray3RKNS_13RayCastOptionEPNS_13RayCastResultE(ptr noundef nonnull align 8 dereferenceable(24) %10, ptr noundef nonnull align 4 dereferenceable(24) %18, ptr noundef nonnull align 8 dereferenceable(192) %16, ptr noundef %17)
          to label %181 unwind label %171

181:                                              ; preds = %179
  %182 = zext i1 %180 to i8
  store i8 %182, ptr %21, align 1, !tbaa !9
  %183 = load i8, ptr %21, align 1, !tbaa !9, !range !11, !noundef !12
  %184 = trunc i8 %183 to i1
  br i1 %184, label %193, label %185

185:                                              ; preds = %181
  %186 = invoke i32 (ptr, ...) @printf(ptr noundef @.str.1, ptr noundef @.str.2, i32 noundef 589)
          to label %187 unwind label %171

187:                                              ; preds = %185
  invoke void @_Z10BreakPointPKcl(ptr noundef @.str.2, i64 noundef 589)
          to label %188 unwind label %171

188:                                              ; preds = %187
  br label %193

189:                                              ; preds = %176, %175
  %190 = landingpad { ptr, i32 }
          cleanup
  %191 = extractvalue { ptr, i32 } %190, 0
  store ptr %191, ptr %3, align 8
  %192 = extractvalue { ptr, i32 } %190, 1
  store i32 %192, ptr %4, align 4
  call void @llvm.lifetime.end.p0(i64 12, ptr %22) #7
  br label %288

193:                                              ; preds = %188, %181
  call void @llvm.lifetime.start.p0(i64 4, ptr %23) #7
  store i32 0, ptr %23, align 4, !tbaa !5
  br label %194

194:                                              ; preds = %206, %193
  %195 = load i32, ptr %23, align 4, !tbaa !5
  %196 = icmp slt i32 %195, 10000
  br i1 %196, label %198, label %197

197:                                              ; preds = %194
  call void @llvm.lifetime.end.p0(i64 4, ptr %23) #7
  br label %223

198:                                              ; preds = %194
  call void @llvm.lifetime.start.p0(i64 12, ptr %24) #7
  call void @llvm.lifetime.start.p0(i64 12, ptr %25) #7
  invoke void @_ZN5Maths8TVector3IfE6RandomEv(ptr dead_on_unwind writable sret(%"class.Maths::TVector3") align 4 %25)
          to label %199 unwind label %209

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

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

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

202:                                              ; preds = %201
  call void @llvm.lifetime.end.p0(i64 12, ptr %27) #7
  call void @llvm.lifetime.start.p0(i64 12, ptr %28) #7
  invoke void @_ZNK5Maths8TVector3IfEplERKS1_(ptr dead_on_unwind writable sret(%"class.Maths::TVector3") align 4 %28, ptr noundef nonnull align 4 dereferenceable(12) %24, ptr noundef nonnull align 4 dereferenceable(12) %26)
          to label %203 unwind label %217

203:                                              ; preds = %202
  %204 = invoke noundef nonnull align 4 dereferenceable(24) ptr @_ZNSt6vectorIN5Maths6TAABB3IfEESaIS2_EE12emplace_backIJRNS0_8TVector3IfEES7_EEERS2_DpOT_(ptr noundef nonnull align 8 dereferenceable(24) %1, ptr noundef nonnull align 4 dereferenceable(12) %24, ptr noundef nonnull align 4 dereferenceable(12) %28)
          to label %205 unwind label %217

205:                                              ; preds = %203
  call void @llvm.lifetime.end.p0(i64 12, ptr %28) #7
  call void @llvm.lifetime.end.p0(i64 12, ptr %26) #7
  call void @llvm.lifetime.end.p0(i64 12, ptr %24) #7
  br label %206

206:                                              ; preds = %205
  %207 = load i32, ptr %23, align 4, !tbaa !5
  %208 = add nsw i32 %207, 1
  store i32 %208, ptr %23, align 4, !tbaa !5
  br label %194, !llvm.loop !13

209:                                              ; preds = %199, %198
  %210 = landingpad { ptr, i32 }
          cleanup
  %211 = extractvalue { ptr, i32 } %210, 0
  store ptr %211, ptr %3, align 8
  %212 = extractvalue { ptr, i32 } %210, 1
  store i32 %212, ptr %4, align 4
  call void @llvm.lifetime.end.p0(i64 12, ptr %25) #7
  br label %222

213:                                              ; preds = %201, %200
  %214 = landingpad { ptr, i32 }
          cleanup
  %215 = extractvalue { ptr, i32 } %214, 0
  store ptr %215, ptr %3, align 8
  %216 = extractvalue { ptr, i32 } %214, 1
  store i32 %216, ptr %4, align 4
  call void @llvm.lifetime.end.p0(i64 12, ptr %27) #7
  br label %221

217:                                              ; preds = %203, %202
  %218 = landingpad { ptr, i32 }
          cleanup
  %219 = extractvalue { ptr, i32 } %218, 0
  store ptr %219, ptr %3, align 8
  %220 = extractvalue { ptr, i32 } %218, 1
  store i32 %220, ptr %4, align 4
  call void @llvm.lifetime.end.p0(i64 12, ptr %28) #7
  br label %221

221:                                              ; preds = %217, %213
  call void @llvm.lifetime.end.p0(i64 12, ptr %26) #7
  br label %222

222:                                              ; preds = %221, %209
  call void @llvm.lifetime.end.p0(i64 12, ptr %24) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %23) #7
  br label %288

223:                                              ; preds = %197
  call void @llvm.lifetime.start.p0(i64 48, ptr %29) #7
  %224 = call noundef nonnull align 4 dereferenceable(24) ptr @_ZNSt6vectorIN5Maths6TAABB3IfEESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef 0) #7
  %225 = call noundef i64 @_ZNKSt6vectorIN5Maths6TAABB3IfEESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #7
  %226 = trunc i64 %225 to i32
  invoke void @_ZN7Riemann17AABBTreeBuildDataC2EPKN5Maths6TAABB3IfEEii(ptr noundef nonnull align 8 dereferenceable(41) %29, ptr noundef %224, i32 noundef %226, i32 noundef 1)
          to label %227 unwind label %236

227:                                              ; preds = %223
  %228 = getelementptr inbounds %"struct.Riemann::AABBTreeBuildData", ptr %29, i32 0, i32 6
  store i8 1, ptr %228, align 8, !tbaa !15
  invoke void @_ZN7Riemann8AABBTree7ReleaseEv(ptr noundef nonnull align 8 dereferenceable(24) %10)
          to label %229 unwind label %240

229:                                              ; preds = %227
  invoke void @_ZN7Riemann8AABBTree11StaticBuildERNS_17AABBTreeBuildDataE(ptr noundef nonnull align 8 dereferenceable(24) %10, ptr noundef nonnull align 8 dereferenceable(41) %29)
          to label %230 unwind label %240

230:                                              ; preds = %229
  call void @llvm.lifetime.start.p0(i64 20, ptr %30) #7
  invoke void @_ZN7Riemann8AABBTree9StatisticERNS_14TreeStatisticsE(ptr noundef nonnull align 8 dereferenceable(24) %10, ptr noundef nonnull align 4 dereferenceable(20) %30)
          to label %231 unwind label %244

231:                                              ; preds = %230
  call void @llvm.lifetime.start.p0(i64 4, ptr %31) #7
  store i32 0, ptr %31, align 4, !tbaa !5
  br label %232

232:                                              ; preds = %280, %231
  %233 = load i32, ptr %31, align 4, !tbaa !5
  %234 = icmp slt i32 %233, 10000
  br i1 %234, label %248, label %235

235:                                              ; preds = %232
  call void @llvm.lifetime.end.p0(i64 4, ptr %31) #7
  br label %284

236:                                              ; preds = %223
  %237 = landingpad { ptr, i32 }
          cleanup
  %238 = extractvalue { ptr, i32 } %237, 0
  store ptr %238, ptr %3, align 8
  %239 = extractvalue { ptr, i32 } %237, 1
  store i32 %239, ptr %4, align 4
  br label %287

240:                                              ; preds = %229, %227
  %241 = landingpad { ptr, i32 }
          cleanup
  %242 = extractvalue { ptr, i32 } %241, 0
  store ptr %242, ptr %3, align 8
  %243 = extractvalue { ptr, i32 } %241, 1
  store i32 %243, ptr %4, align 4
  br label %286

244:                                              ; preds = %230
  %245 = landingpad { ptr, i32 }
          cleanup
  %246 = extractvalue { ptr, i32 } %245, 0
  store ptr %246, ptr %3, align 8
  %247 = extractvalue { ptr, i32 } %245, 1
  store i32 %247, ptr %4, align 4
  br label %285

248:                                              ; preds = %232
  call void @llvm.lifetime.start.p0(i64 12, ptr %32) #7
  call void @llvm.lifetime.start.p0(i64 12, ptr %33) #7
  invoke void @_ZN5Maths8TVector3IfE6RandomEv(ptr dead_on_unwind writable sret(%"class.Maths::TVector3") align 4 %33)
          to label %249 unwind label %267

249:                                              ; preds = %248
  invoke void @_ZNK5Maths8TVector3IfEmlEf(ptr dead_on_unwind writable sret(%"class.Maths::TVector3") align 4 %32, ptr noundef nonnull align 4 dereferenceable(12) %33, float noundef 1.000000e+02)
          to label %250 unwind label %267

250:                                              ; preds = %249
  call void @llvm.lifetime.end.p0(i64 12, ptr %33) #7
  %251 = invoke noundef i32 @_ZNK7Riemann8AABBTree14IntersectPointERKN5Maths8TVector3IfEE(ptr noundef nonnull align 8 dereferenceable(24) %10, ptr noundef nonnull align 4 dereferenceable(12) %32)
          to label %252 unwind label %271

252:                                              ; preds = %250
  store i32 %251, ptr %12, align 4, !tbaa !5
  %253 = getelementptr inbounds %class.Ray3, ptr %18, i32 0, i32 0
  %254 = invoke noundef nonnull align 4 dereferenceable(12) ptr @_ZN5Maths8TVector3IfEaSERKS1_(ptr noundef nonnull align 4 dereferenceable(12) %253, ptr noundef nonnull align 4 dereferenceable(12) %32)
          to label %255 unwind label %271

255:                                              ; preds = %252
  %256 = invoke noundef zeroext i1 @_ZNK7Riemann8AABBTree18RayCastBoundingBoxERK4Ray3RKNS_13RayCastOptionEPNS_13RayCastResultE(ptr noundef nonnull align 8 dereferenceable(24) %10, ptr noundef nonnull align 4 dereferenceable(24) %18, ptr noundef nonnull align 8 dereferenceable(192) %16, ptr noundef %17)
          to label %257 unwind label %271

257:                                              ; preds = %255
  %258 = zext i1 %256 to i8
  store i8 %258, ptr %21, align 1, !tbaa !9
  %259 = load i8, ptr %21, align 1, !tbaa !9, !range !11, !noundef !12
  %260 = trunc i8 %259 to i1
  br i1 %260, label %261, label %279

261:                                              ; preds = %257
  call void @llvm.lifetime.start.p0(i64 24, ptr %34) #7
  %262 = load i8, ptr %21, align 1, !tbaa !9, !range !11, !noundef !12
  %263 = trunc i8 %262 to i1
  %264 = zext i1 %263 to i64
  %265 = call noundef nonnull align 4 dereferenceable(24) ptr @_ZNSt6vectorIN5Maths6TAABB3IfEESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef %264) #7
  invoke void @_ZN5Maths6TAABB3IfEC2ERKS1_(ptr noundef nonnull align 4 dereferenceable(24) %34, ptr noundef nonnull align 4 dereferenceable(24) %265)
          to label %266 unwind label %275

266:                                              ; preds = %261
  call void @llvm.lifetime.end.p0(i64 24, ptr %34) #7
  br label %279

267:                                              ; preds = %249, %248
  %268 = landingpad { ptr, i32 }
          cleanup
  %269 = extractvalue { ptr, i32 } %268, 0
  store ptr %269, ptr %3, align 8
  %270 = extractvalue { ptr, i32 } %268, 1
  store i32 %270, ptr %4, align 4
  call void @llvm.lifetime.end.p0(i64 12, ptr %33) #7
  br label %283

271:                                              ; preds = %255, %252, %250
  %272 = landingpad { ptr, i32 }
          cleanup
  %273 = extractvalue { ptr, i32 } %272, 0
  store ptr %273, ptr %3, align 8
  %274 = extractvalue { ptr, i32 } %272, 1
  store i32 %274, ptr %4, align 4
  br label %283

275:                                              ; preds = %261
  %276 = landingpad { ptr, i32 }
          cleanup
  %277 = extractvalue { ptr, i32 } %276, 0
  store ptr %277, ptr %3, align 8
  %278 = extractvalue { ptr, i32 } %276, 1
  store i32 %278, ptr %4, align 4
  call void @llvm.lifetime.end.p0(i64 24, ptr %34) #7
  br label %283

279:                                              ; preds = %266, %257
  call void @llvm.lifetime.end.p0(i64 12, ptr %32) #7
  br label %280

280:                                              ; preds = %279
  %281 = load i32, ptr %31, align 4, !tbaa !5
  %282 = add nsw i32 %281, 1
  store i32 %282, ptr %31, align 4, !tbaa !5
  br label %232, !llvm.loop !19

283:                                              ; preds = %275, %271, %267
  call void @llvm.lifetime.end.p0(i64 12, ptr %32) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %31) #7
  br label %285

284:                                              ; preds = %235
  call void @llvm.lifetime.end.p0(i64 20, ptr %30) #7
  call void @_ZN7Riemann17AABBTreeBuildDataD2Ev(ptr noundef nonnull align 8 dereferenceable(41) %29) #7
  call void @llvm.lifetime.end.p0(i64 48, ptr %29) #7
  call void @llvm.lifetime.end.p0(i64 1, ptr %21) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr %18) #7
  call void @_ZN7Riemann13RayCastResultD2Ev(ptr noundef nonnull align 8 dereferenceable(76) %17) #7
  call void @llvm.lifetime.end.p0(i64 80, ptr %17) #7
  call void @llvm.lifetime.end.p0(i64 192, ptr %16) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #7
  call void @_ZN7Riemann17AABBTreeBuildDataD2Ev(ptr noundef nonnull align 8 dereferenceable(41) %11) #7
  call void @llvm.lifetime.end.p0(i64 48, ptr %11) #7
  call void @_ZN7Riemann8AABBTreeD1Ev(ptr noundef nonnull align 8 dereferenceable(24) %10) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr %10) #7
  call void @_ZNSt6vectorIN5Maths6TAABB3IfEESaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %1) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr %1) #7
  ret void

285:                                              ; preds = %283, %244
  call void @llvm.lifetime.end.p0(i64 20, ptr %30) #7
  br label %286

286:                                              ; preds = %285, %240
  call void @_ZN7Riemann17AABBTreeBuildDataD2Ev(ptr noundef nonnull align 8 dereferenceable(41) %29) #7
  br label %287

287:                                              ; preds = %286, %236
  call void @llvm.lifetime.end.p0(i64 48, ptr %29) #7
  br label %288

288:                                              ; preds = %287, %222, %189, %171
  call void @llvm.lifetime.end.p0(i64 1, ptr %21) #7
  br label %289

289:                                              ; preds = %288, %170
  call void @llvm.lifetime.end.p0(i64 24, ptr %18) #7
  call void @_ZN7Riemann13RayCastResultD2Ev(ptr noundef nonnull align 8 dereferenceable(76) %17) #7
  br label %290

290:                                              ; preds = %289, %158
  call void @llvm.lifetime.end.p0(i64 80, ptr %17) #7
  br label %291

291:                                              ; preds = %290, %154
  call void @llvm.lifetime.end.p0(i64 192, ptr %16) #7
  br label %292

292:                                              ; preds = %291, %135, %121, %107, %103
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #7
  br label %293

293:                                              ; preds = %292, %99
  call void @_ZN7Riemann17AABBTreeBuildDataD2Ev(ptr noundef nonnull align 8 dereferenceable(41) %11) #7
  br label %294

294:                                              ; preds = %293, %95
  call void @llvm.lifetime.end.p0(i64 48, ptr %11) #7
  call void @_ZN7Riemann8AABBTreeD1Ev(ptr noundef nonnull align 8 dereferenceable(24) %10) #7
  br label %295

295:                                              ; preds = %294, %91
  call void @llvm.lifetime.end.p0(i64 24, ptr %10) #7
  br label %296

296:                                              ; preds = %295, %90, %81, %72
  call void @_ZNSt6vectorIN5Maths6TAABB3IfEESaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %1) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr %1) #7
  br label %297

297:                                              ; preds = %296
  %298 = load ptr, ptr %3, align 8
  %299 = load i32, ptr %4, align 4
  %300 = insertvalue { ptr, i32 } poison, ptr %298, 0
  %301 = insertvalue { ptr, i32 } %300, i32 %299, 1
  resume { ptr, i32 } %301
}

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

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

declare void @_ZN7Riemann8AABBTreeC1Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #0

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

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

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

declare void @_ZN7Riemann8AABBTree7ReleaseEv(ptr noundef nonnull align 8 dereferenceable(24)) #0

declare void @_ZN7Riemann8AABBTree11StaticBuildERNS_17AABBTreeBuildDataE(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(41)) #0

declare noundef i32 @_ZNK7Riemann8AABBTree14IntersectPointERKN5Maths8TVector3IfEE(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 4 dereferenceable(12)) #0

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN7Riemann13RayCastOptionC2Ev(ptr noundef nonnull align 8 dereferenceable(192)) unnamed_addr #3 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN7Riemann13RayCastResultC2Ev(ptr noundef nonnull align 8 dereferenceable(76)) unnamed_addr #3 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN4Ray3C2ERKN5Maths8TVector3IfEES4_b(ptr noundef nonnull align 4 dereferenceable(24), ptr noundef nonnull align 4 dereferenceable(12), ptr noundef nonnull align 4 dereferenceable(12), i1 noundef zeroext) unnamed_addr #3 align 2

declare noundef zeroext i1 @_ZNK7Riemann8AABBTree18RayCastBoundingBoxERK4Ray3RKNS_13RayCastOptionEPNS_13RayCastResultE(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 4 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(192), ptr noundef) #0

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

declare void @_ZN7Riemann8AABBTree9StatisticERNS_14TreeStatisticsE(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 4 dereferenceable(20)) #0

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

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

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

; Function Attrs: nounwind
declare void @_ZN7Riemann8AABBTreeD1Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #6

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt6vectorIN5Maths6TAABB3IfEESaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24)) 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 "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #7 = { nounwind }

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"int", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"bool", !7, i64 0}
!11 = !{i8 0, i8 2}
!12 = !{}
!13 = distinct !{!13, !14}
!14 = !{!"llvm.loop.mustprogress"}
!15 = !{!16, !18, i64 40}
!16 = !{!"_ZTSN7Riemann17AABBTreeBuildDataE", !6, i64 0, !6, i64 4, !17, i64 8, !17, i64 16, !17, i64 24, !17, i64 32, !18, i64 40}
!17 = !{!"any pointer", !7, i64 0}
!18 = !{!"_ZTSN7Riemann14SplitHeuristicE", !7, i64 0}
!19 = distinct !{!19, !14}


; 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.std::vector.18" = type { %"struct.std::_Vector_base.19" }
%"struct.std::_Vector_base.19" = type { %"struct.std::_Vector_base<Maths::TAABB3<float>, std::allocator<Maths::TAABB3<float>>>::_Vector_impl" }
%"struct.std::_Vector_base<Maths::TAABB3<float>, std::allocator<Maths::TAABB3<float>>>::_Vector_impl" = type { %"struct.std::_Vector_base<Maths::TAABB3<float>, std::allocator<Maths::TAABB3<float>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<Maths::TAABB3<float>, std::allocator<Maths::TAABB3<float>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.Riemann::AABBTree" = type { ptr, i32, ptr }
%"struct.Riemann::AABBTreeBuildData" = type <{ i32, i32, ptr, ptr, ptr, ptr, i8, [7 x i8] }>
%"struct.Riemann::RayCastOption" = type { i32, [4 x i8], %"struct.Riemann::RayCastCache", i8, float, i32, %"struct.Riemann::CollisionData", ptr }
%"struct.Riemann::RayCastCache" = type <{ ptr, %"class.Riemann::StaticStack", [4 x i8] }>
%"class.Riemann::StaticStack" = type { i32, [32 x i32] }
%"struct.Riemann::CollisionData" = type { i32, i32, i32, i32 }
%"struct.Riemann::RayCastResult" = type <{ i8, [3 x i8], float, float, %"class.Maths::TVector3", %"class.Maths::TVector3", [4 x i8], ptr, %"class.std::vector.23", i32, [4 x i8] }>
%"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.Ray3 = type { %"class.Maths::TVector3", %"class.Maths::TVector3" }
%"struct.Riemann::TreeStatistics" = type { i32, i32, i32, i32, i32 }
%"class.Maths::TAABB3" = type { %"class.Maths::TVector3", %"class.Maths::TVector3" }

@.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.19 = external hidden unnamed_addr constant [22 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: inlinehint mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(12) ptr @_ZN5Maths8TVector3IfEaSERKS1_(ptr noundef nonnull align 4 dereferenceable(12), ptr noundef nonnull align 4 dereferenceable(12)) local_unnamed_addr #2 align 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(...)

; 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 #4 align 2

; 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 #4 align 2

; Function Attrs: mustprogress uwtable
define dso_local void @_Z12TestAABBTreev() local_unnamed_addr #3 personality ptr @__gxx_personality_v0 {
  %1 = alloca %"class.std::vector.18", align 8
  %2 = alloca %"class.Maths::TVector3", align 4
  %3 = alloca %"class.Maths::TVector3", align 4
  %4 = alloca %"class.Maths::TVector3", align 4
  %5 = alloca %"class.Maths::TVector3", align 4
  %6 = alloca %"class.Maths::TVector3", align 4
  %7 = alloca %"class.Maths::TVector3", align 4
  %8 = alloca %"class.Riemann::AABBTree", align 8
  %9 = alloca %"struct.Riemann::AABBTreeBuildData", align 8
  %10 = alloca %"class.Maths::TVector3", align 4
  %11 = alloca %"class.Maths::TVector3", align 4
  %12 = alloca %"class.Maths::TVector3", align 4
  %13 = alloca %"struct.Riemann::RayCastOption", align 8
  %14 = alloca %"struct.Riemann::RayCastResult", align 8
  %15 = alloca %class.Ray3, align 4
  %16 = alloca %"class.Maths::TVector3", align 4
  %17 = alloca %"class.Maths::TVector3", align 4
  %18 = alloca %"class.Maths::TVector3", align 4
  %19 = alloca %"class.Maths::TVector3", align 4
  %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 %"struct.Riemann::AABBTreeBuildData", align 8
  %25 = alloca %"struct.Riemann::TreeStatistics", align 4
  %26 = alloca %"class.Maths::TVector3", align 4
  %27 = alloca %"class.Maths::TVector3", align 4
  %28 = alloca %"class.Maths::TAABB3", align 4
  %29 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.19)
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %1) #8
  call void @_ZNSt6vectorIN5Maths6TAABB3IfEESaIS2_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %1) #8
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %2) #8
  call void @_ZN5Maths8TVector3IfEC2Efff(ptr noundef nonnull align 4 dereferenceable(12) %2, float noundef 0.000000e+00, float noundef 0.000000e+00, float noundef 0.000000e+00)
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %3) #8
  call void @_ZN5Maths8TVector3IfEC2Efff(ptr noundef nonnull align 4 dereferenceable(12) %3, float noundef 1.000000e+00, float noundef 1.000000e+00, float noundef 1.000000e+00)
  %30 = invoke noundef nonnull align 4 dereferenceable(24) ptr @_ZNSt6vectorIN5Maths6TAABB3IfEESaIS2_EE12emplace_backIJNS0_8TVector3IfEES7_EEERS2_DpOT_(ptr noundef nonnull align 8 dereferenceable(24) %1, ptr noundef nonnull align 4 dereferenceable(12) %2, ptr noundef nonnull align 4 dereferenceable(12) %3)
          to label %31 unwind label %47

31:                                               ; preds = %0
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %3) #8
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %2) #8
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %4) #8
  call void @_ZN5Maths8TVector3IfEC2Efff(ptr noundef nonnull align 4 dereferenceable(12) %4, float noundef 0.000000e+00, float noundef 0.000000e+00, float noundef 0.000000e+00)
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %5) #8
  call void @_ZN5Maths8TVector3IfEC2Efff(ptr noundef nonnull align 4 dereferenceable(12) %5, float noundef 1.000000e+00, float noundef 1.000000e+00, float noundef 3.000000e+00)
  %32 = invoke noundef nonnull align 4 dereferenceable(24) ptr @_ZNSt6vectorIN5Maths6TAABB3IfEESaIS2_EE12emplace_backIJNS0_8TVector3IfEES7_EEERS2_DpOT_(ptr noundef nonnull align 8 dereferenceable(24) %1, ptr noundef nonnull align 4 dereferenceable(12) %4, ptr noundef nonnull align 4 dereferenceable(12) %5)
          to label %33 unwind label %49

33:                                               ; preds = %31
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %5) #8
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %4) #8
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %6) #8
  call void @_ZN5Maths8TVector3IfEC2Efff(ptr noundef nonnull align 4 dereferenceable(12) %6, float noundef 1.000000e+00, float noundef 1.000000e+00, float noundef 1.000000e+00)
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %7) #8
  call void @_ZN5Maths8TVector3IfEC2Efff(ptr noundef nonnull align 4 dereferenceable(12) %7, float noundef 1.000000e+00, float noundef 1.000000e+00, float noundef 2.000000e+00)
  %34 = invoke noundef nonnull align 4 dereferenceable(24) ptr @_ZNSt6vectorIN5Maths6TAABB3IfEESaIS2_EE12emplace_backIJNS0_8TVector3IfEES7_EEERS2_DpOT_(ptr noundef nonnull align 8 dereferenceable(24) %1, ptr noundef nonnull align 4 dereferenceable(12) %6, ptr noundef nonnull align 4 dereferenceable(12) %7)
          to label %35 unwind label %51

35:                                               ; preds = %33
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %7) #8
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %6) #8
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %8) #8
  invoke void @_ZN7Riemann8AABBTreeC1Ev(ptr noundef nonnull align 8 dereferenceable(24) %8)
          to label %36 unwind label %53

36:                                               ; preds = %35
  call void @llvm.lifetime.start.p0(i64 48, ptr nonnull %9) #8
  %37 = call noundef nonnull align 4 dereferenceable(24) ptr @_ZNSt6vectorIN5Maths6TAABB3IfEESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef 0) #8
  %38 = call noundef i64 @_ZNKSt6vectorIN5Maths6TAABB3IfEESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #8
  %39 = trunc i64 %38 to i32
  call void @_ZN7Riemann17AABBTreeBuildDataC2EPKN5Maths6TAABB3IfEEii(ptr noundef nonnull align 8 dereferenceable(41) %9, ptr noundef nonnull %37, i32 noundef %39, i32 noundef 1)
  invoke void @_ZN7Riemann8AABBTree7ReleaseEv(ptr noundef nonnull align 8 dereferenceable(24) %8)
          to label %40 unwind label %55

40:                                               ; preds = %36
  invoke void @_ZN7Riemann8AABBTree11StaticBuildERNS_17AABBTreeBuildDataE(ptr noundef nonnull align 8 dereferenceable(24) %8, ptr noundef nonnull align 8 dereferenceable(41) %9)
          to label %41 unwind label %55

41:                                               ; preds = %40
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %10) #8
  call void @_ZN5Maths8TVector3IfEC2Efff(ptr noundef nonnull align 4 dereferenceable(12) %10, float noundef -1.000000e+00, float noundef -1.000000e+00, float noundef -1.000000e+00)
  %42 = invoke noundef i32 @_ZNK7Riemann8AABBTree14IntersectPointERKN5Maths8TVector3IfEE(ptr noundef nonnull align 8 dereferenceable(24) %8, ptr noundef nonnull align 4 dereferenceable(12) %10)
          to label %43 unwind label %57

43:                                               ; preds = %41
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %10) #8
  %44 = icmp eq i32 %42, -1
  br i1 %44, label %59, label %45

45:                                               ; preds = %43
  %46 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.1, ptr noundef nonnull @.str.2, i32 noundef 575)
  call void @_Z10BreakPointPKcl(ptr noundef nonnull @.str.2, i64 noundef 575)
  br label %59

47:                                               ; preds = %0
  %48 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %3) #8
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %2) #8
  br label %152

49:                                               ; preds = %31
  %50 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %5) #8
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %4) #8
  br label %152

51:                                               ; preds = %33
  %52 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %7) #8
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %6) #8
  br label %152

53:                                               ; preds = %35
  %54 = landingpad { ptr, i32 }
          cleanup
  br label %151

55:                                               ; preds = %40, %36
  %56 = landingpad { ptr, i32 }
          cleanup
  br label %150

57:                                               ; preds = %41
  %58 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %10) #8
  br label %150

59:                                               ; preds = %45, %43
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %11) #8
  call void @_ZN5Maths8TVector3IfEC2Efff(ptr noundef nonnull align 4 dereferenceable(12) %11, float noundef 5.000000e-01, float noundef 5.000000e-01, float noundef 5.000000e-01)
  %60 = invoke noundef i32 @_ZNK7Riemann8AABBTree14IntersectPointERKN5Maths8TVector3IfEE(ptr noundef nonnull align 8 dereferenceable(24) %8, ptr noundef nonnull align 4 dereferenceable(12) %11)
          to label %61 unwind label %65

61:                                               ; preds = %59
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %11) #8
  %62 = icmp sgt i32 %60, -1
  br i1 %62, label %67, label %63

63:                                               ; preds = %61
  %64 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.1, ptr noundef nonnull @.str.2, i32 noundef 577)
  call void @_Z10BreakPointPKcl(ptr noundef nonnull @.str.2, i64 noundef 577)
  br label %67

65:                                               ; preds = %59
  %66 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %11) #8
  br label %150

67:                                               ; preds = %63, %61
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %12) #8
  call void @_ZN5Maths8TVector3IfEC2Efff(ptr noundef nonnull align 4 dereferenceable(12) %12, float noundef 5.000000e-01, float noundef 5.000000e-01, float noundef 2.500000e+00)
  %68 = invoke noundef i32 @_ZNK7Riemann8AABBTree14IntersectPointERKN5Maths8TVector3IfEE(ptr noundef nonnull align 8 dereferenceable(24) %8, ptr noundef nonnull align 4 dereferenceable(12) %12)
          to label %69 unwind label %73

69:                                               ; preds = %67
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %12) #8
  %70 = icmp eq i32 %68, 1
  br i1 %70, label %75, label %71

71:                                               ; preds = %69
  %72 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.1, ptr noundef nonnull @.str.2, i32 noundef 579)
  call void @_Z10BreakPointPKcl(ptr noundef nonnull @.str.2, i64 noundef 579)
  br label %75

73:                                               ; preds = %67
  %74 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %12) #8
  br label %150

75:                                               ; preds = %71, %69
  call void @llvm.lifetime.start.p0(i64 192, ptr nonnull %13) #8
  invoke void @_ZN7Riemann13RayCastOptionC2Ev(ptr noundef nonnull align 8 dereferenceable(192) %13)
          to label %76 unwind label %83

76:                                               ; preds = %75
  call void @llvm.lifetime.start.p0(i64 80, ptr nonnull %14) #8
  invoke void @_ZN7Riemann13RayCastResultC2Ev(ptr noundef nonnull align 8 dereferenceable(76) %14)
          to label %77 unwind label %85

77:                                               ; preds = %76
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %15) #8
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %16) #8
  call void @_ZN5Maths8TVector3IfEC2Efff(ptr noundef nonnull align 4 dereferenceable(12) %16, float noundef 5.000000e-01, float noundef 5.000000e-01, float noundef 1.000000e+02)
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %17) #8
  call void @_ZN5Maths8TVector3IfEC2Efff(ptr noundef nonnull align 4 dereferenceable(12) %17, float noundef 0.000000e+00, float noundef 0.000000e+00, float noundef -1.000000e+00)
  invoke void @_ZN4Ray3C2ERKN5Maths8TVector3IfEES4_b(ptr noundef nonnull align 4 dereferenceable(24) %15, ptr noundef nonnull align 4 dereferenceable(12) %16, ptr noundef nonnull align 4 dereferenceable(12) %17, i1 noundef zeroext false)
          to label %78 unwind label %87

78:                                               ; preds = %77
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %17) #8
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %16) #8
  %79 = invoke noundef zeroext i1 @_ZNK7Riemann8AABBTree18RayCastBoundingBoxERK4Ray3RKNS_13RayCastOptionEPNS_13RayCastResultE(ptr noundef nonnull align 8 dereferenceable(24) %8, ptr noundef nonnull align 4 dereferenceable(24) %15, ptr noundef nonnull align 8 dereferenceable(192) %13, ptr noundef nonnull %14)
          to label %80 unwind label %89

80:                                               ; preds = %78
  br i1 %79, label %91, label %81

81:                                               ; preds = %80
  %82 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.1, ptr noundef nonnull @.str.2, i32 noundef 585)
  call void @_Z10BreakPointPKcl(ptr noundef nonnull @.str.2, i64 noundef 585)
  br label %91

83:                                               ; preds = %75
  %84 = landingpad { ptr, i32 }
          cleanup
  br label %149

85:                                               ; preds = %76
  %86 = landingpad { ptr, i32 }
          cleanup
  br label %148

87:                                               ; preds = %77
  %88 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %17) #8
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %16) #8
  br label %147

89:                                               ; preds = %91, %78
  %90 = landingpad { ptr, i32 }
          cleanup
  br label %147

91:                                               ; preds = %81, %80
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %18) #8
  call void @_ZN5Maths8TVector3IfEC2Efff(ptr noundef nonnull align 4 dereferenceable(12) %18, float noundef 5.000000e-01, float noundef 5.000000e-01, float noundef 5.000000e-01)
  %92 = call noundef nonnull align 4 dereferenceable(12) ptr @_ZN5Maths8TVector3IfEaSERKS1_(ptr noundef nonnull align 4 dereferenceable(12) %15, ptr noundef nonnull align 4 dereferenceable(12) %18)
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %18) #8
  %93 = invoke noundef zeroext i1 @_ZNK7Riemann8AABBTree18RayCastBoundingBoxERK4Ray3RKNS_13RayCastOptionEPNS_13RayCastResultE(ptr noundef nonnull align 8 dereferenceable(24) %8, ptr noundef nonnull align 4 dereferenceable(24) %15, ptr noundef nonnull align 8 dereferenceable(192) %13, ptr noundef nonnull %14)
          to label %94 unwind label %89

94:                                               ; preds = %91
  br i1 %93, label %.preheader45, label %95

.preheader45:                                     ; preds = %95, %94
  br label %102

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

97:                                               ; preds = %109
  call void @llvm.lifetime.start.p0(i64 48, ptr nonnull %24) #8
  %98 = call noundef nonnull align 4 dereferenceable(24) ptr @_ZNSt6vectorIN5Maths6TAABB3IfEESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef 0) #8
  %99 = call noundef i64 @_ZNKSt6vectorIN5Maths6TAABB3IfEESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #8
  %100 = trunc i64 %99 to i32
  call void @_ZN7Riemann17AABBTreeBuildDataC2EPKN5Maths6TAABB3IfEEii(ptr noundef nonnull align 8 dereferenceable(41) %24, ptr noundef nonnull %98, i32 noundef %100, i32 noundef 1)
  %101 = getelementptr inbounds i8, ptr %24, i64 40
  store i8 1, ptr %101, align 8, !tbaa !5
  invoke void @_ZN7Riemann8AABBTree7ReleaseEv(ptr noundef nonnull align 8 dereferenceable(24) %8)
          to label %119 unwind label %122

102:                                              ; preds = %.preheader45, %109
  %.01242 = phi i32 [ %110, %109 ], [ 0, %.preheader45 ]
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %19) #8
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %20) #8
  invoke void @_ZN5Maths8TVector3IfE6RandomEv(ptr dead_on_unwind nonnull writable sret(%"class.Maths::TVector3") align 4 %20)
          to label %103 unwind label %111

103:                                              ; preds = %102
  invoke void @_ZNK5Maths8TVector3IfEmlEf(ptr dead_on_unwind nonnull writable sret(%"class.Maths::TVector3") align 4 %19, ptr noundef nonnull align 4 dereferenceable(12) %20, float noundef 1.000000e+02)
          to label %104 unwind label %111

104:                                              ; preds = %103
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %20) #8
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %21) #8
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %22) #8
  invoke void @_ZN5Maths8TVector3IfE6RandomEv(ptr dead_on_unwind nonnull writable sret(%"class.Maths::TVector3") align 4 %22)
          to label %105 unwind label %113

105:                                              ; preds = %104
  invoke void @_ZNK5Maths8TVector3IfEmlEf(ptr dead_on_unwind nonnull writable sret(%"class.Maths::TVector3") align 4 %21, ptr noundef nonnull align 4 dereferenceable(12) %22, float noundef 1.000000e+02)
          to label %106 unwind label %113

106:                                              ; preds = %105
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %22) #8
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %23) #8
  invoke void @_ZNK5Maths8TVector3IfEplERKS1_(ptr dead_on_unwind nonnull writable sret(%"class.Maths::TVector3") align 4 %23, ptr noundef nonnull align 4 dereferenceable(12) %19, ptr noundef nonnull align 4 dereferenceable(12) %21)
          to label %107 unwind label %115

107:                                              ; preds = %106
  %108 = invoke noundef nonnull align 4 dereferenceable(24) ptr @_ZNSt6vectorIN5Maths6TAABB3IfEESaIS2_EE12emplace_backIJRNS0_8TVector3IfEES7_EEERS2_DpOT_(ptr noundef nonnull align 8 dereferenceable(24) %1, ptr noundef nonnull align 4 dereferenceable(12) %19, ptr noundef nonnull align 4 dereferenceable(12) %23)
          to label %109 unwind label %115

109:                                              ; preds = %107
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %23) #8
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %21) #8
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %19) #8
  %110 = add nuw nsw i32 %.01242, 1
  %exitcond.not = icmp eq i32 %110, 10000
  br i1 %exitcond.not, label %97, label %102, !llvm.loop !12

111:                                              ; preds = %103, %102
  %112 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %20) #8
  br label %118

113:                                              ; preds = %105, %104
  %114 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %22) #8
  br label %117

115:                                              ; preds = %107, %106
  %116 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %23) #8
  br label %117

117:                                              ; preds = %115, %113
  %.pn31 = phi { ptr, i32 } [ %116, %115 ], [ %114, %113 ]
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %21) #8
  br label %118

118:                                              ; preds = %117, %111
  %.pn31.pn = phi { ptr, i32 } [ %.pn31, %117 ], [ %112, %111 ]
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %19) #8
  br label %147

119:                                              ; preds = %97
  invoke void @_ZN7Riemann8AABBTree11StaticBuildERNS_17AABBTreeBuildDataE(ptr noundef nonnull align 8 dereferenceable(24) %8, ptr noundef nonnull align 8 dereferenceable(41) %24)
          to label %120 unwind label %122

120:                                              ; preds = %119
  call void @llvm.lifetime.start.p0(i64 20, ptr nonnull %25) #8
  invoke void @_ZN7Riemann8AABBTree9StatisticERNS_14TreeStatisticsE(ptr noundef nonnull align 8 dereferenceable(24) %8, ptr noundef nonnull align 4 dereferenceable(20) %25)
          to label %.preheader unwind label %124

121:                                              ; preds = %142
  call void @llvm.lifetime.end.p0(i64 20, ptr nonnull %25) #8
  call void @_ZN7Riemann17AABBTreeBuildDataD2Ev(ptr noundef nonnull align 8 dereferenceable(41) %24) #8
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %24) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %15) #8
  call void @_ZN7Riemann13RayCastResultD2Ev(ptr noundef nonnull align 8 dereferenceable(76) %14) #8
  call void @llvm.lifetime.end.p0(i64 80, ptr nonnull %14) #8
  call void @llvm.lifetime.end.p0(i64 192, ptr nonnull %13) #8
  call void @_ZN7Riemann17AABBTreeBuildDataD2Ev(ptr noundef nonnull align 8 dereferenceable(41) %9) #8
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %9) #8
  call void @_ZN7Riemann8AABBTreeD1Ev(ptr noundef nonnull align 8 dereferenceable(24) %8) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %8) #8
  call void @_ZNSt6vectorIN5Maths6TAABB3IfEESaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %1) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %1) #8
  ret void

122:                                              ; preds = %119, %97
  %123 = landingpad { ptr, i32 }
          cleanup
  br label %146

124:                                              ; preds = %120
  %125 = landingpad { ptr, i32 }
          cleanup
  br label %145

.preheader:                                       ; preds = %120, %142
  %.043 = phi i32 [ %143, %142 ], [ 0, %120 ]
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %26) #8
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %27) #8
  invoke void @_ZN5Maths8TVector3IfE6RandomEv(ptr dead_on_unwind nonnull writable sret(%"class.Maths::TVector3") align 4 %27)
          to label %126 unwind label %136

126:                                              ; preds = %.preheader
  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 %127 unwind label %136

127:                                              ; preds = %126
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %27) #8
  %128 = invoke noundef i32 @_ZNK7Riemann8AABBTree14IntersectPointERKN5Maths8TVector3IfEE(ptr noundef nonnull align 8 dereferenceable(24) %8, ptr noundef nonnull align 4 dereferenceable(12) %26)
          to label %129 unwind label %138

129:                                              ; preds = %127
  %130 = call noundef nonnull align 4 dereferenceable(12) ptr @_ZN5Maths8TVector3IfEaSERKS1_(ptr noundef nonnull align 4 dereferenceable(12) %15, ptr noundef nonnull align 4 dereferenceable(12) %26)
  %131 = invoke noundef zeroext i1 @_ZNK7Riemann8AABBTree18RayCastBoundingBoxERK4Ray3RKNS_13RayCastOptionEPNS_13RayCastResultE(ptr noundef nonnull align 8 dereferenceable(24) %8, ptr noundef nonnull align 4 dereferenceable(24) %15, ptr noundef nonnull align 8 dereferenceable(192) %13, ptr noundef nonnull %14)
          to label %132 unwind label %138

132:                                              ; preds = %129
  br i1 %131, label %133, label %142

133:                                              ; preds = %132
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %28) #8
  %134 = call noundef nonnull align 4 dereferenceable(24) ptr @_ZNSt6vectorIN5Maths6TAABB3IfEESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef 1) #8
  invoke void @_ZN5Maths6TAABB3IfEC2ERKS1_(ptr noundef nonnull align 4 dereferenceable(24) %28, ptr noundef nonnull align 4 dereferenceable(24) %134)
          to label %135 unwind label %140

135:                                              ; preds = %133
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %28) #8
  br label %142

136:                                              ; preds = %126, %.preheader
  %137 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %27) #8
  br label %144

138:                                              ; preds = %129, %127
  %139 = landingpad { ptr, i32 }
          cleanup
  br label %144

140:                                              ; preds = %133
  %141 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %28) #8
  br label %144

142:                                              ; preds = %135, %132
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %26) #8
  %143 = add nuw nsw i32 %.043, 1
  %exitcond44.not = icmp eq i32 %143, 10000
  br i1 %exitcond44.not, label %121, label %.preheader, !llvm.loop !14

144:                                              ; preds = %140, %138, %136
  %.pn = phi { ptr, i32 } [ %141, %140 ], [ %139, %138 ], [ %137, %136 ]
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %26) #8
  br label %145

145:                                              ; preds = %144, %124
  %.pn.pn = phi { ptr, i32 } [ %.pn, %144 ], [ %125, %124 ]
  call void @llvm.lifetime.end.p0(i64 20, ptr nonnull %25) #8
  br label %146

146:                                              ; preds = %145, %122
  %.pn.pn.pn = phi { ptr, i32 } [ %.pn.pn, %145 ], [ %123, %122 ]
  call void @_ZN7Riemann17AABBTreeBuildDataD2Ev(ptr noundef nonnull align 8 dereferenceable(41) %24) #8
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %24) #8
  br label %147

147:                                              ; preds = %89, %118, %146, %87
  %.pn31.pn.pn.pn = phi { ptr, i32 } [ %88, %87 ], [ %.pn31.pn, %118 ], [ %.pn.pn.pn, %146 ], [ %90, %89 ]
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %15) #8
  call void @_ZN7Riemann13RayCastResultD2Ev(ptr noundef nonnull align 8 dereferenceable(76) %14) #8
  br label %148

148:                                              ; preds = %147, %85
  %.pn31.pn.pn.pn.pn = phi { ptr, i32 } [ %.pn31.pn.pn.pn, %147 ], [ %86, %85 ]
  call void @llvm.lifetime.end.p0(i64 80, ptr nonnull %14) #8
  br label %149

149:                                              ; preds = %148, %83
  %.pn31.pn.pn.pn.pn.pn = phi { ptr, i32 } [ %.pn31.pn.pn.pn.pn, %148 ], [ %84, %83 ]
  call void @llvm.lifetime.end.p0(i64 192, ptr nonnull %13) #8
  br label %150

150:                                              ; preds = %57, %65, %73, %149, %55
  %.pn31.pn.pn.pn.pn.pn.pn.pn = phi { ptr, i32 } [ %56, %55 ], [ %.pn31.pn.pn.pn.pn.pn, %149 ], [ %74, %73 ], [ %66, %65 ], [ %58, %57 ]
  call void @_ZN7Riemann17AABBTreeBuildDataD2Ev(ptr noundef nonnull align 8 dereferenceable(41) %9) #8
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %9) #8
  call void @_ZN7Riemann8AABBTreeD1Ev(ptr noundef nonnull align 8 dereferenceable(24) %8) #8
  br label %151

151:                                              ; preds = %150, %53
  %.pn31.pn.pn.pn.pn.pn.pn.pn.pn = phi { ptr, i32 } [ %.pn31.pn.pn.pn.pn.pn.pn.pn, %150 ], [ %54, %53 ]
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %8) #8
  br label %152

152:                                              ; preds = %151, %51, %49, %47
  %.pn31.pn.pn.pn.pn.pn.pn.pn.pn.pn = phi { ptr, i32 } [ %.pn31.pn.pn.pn.pn.pn.pn.pn.pn, %151 ], [ %52, %51 ], [ %50, %49 ], [ %48, %47 ]
  call void @_ZNSt6vectorIN5Maths6TAABB3IfEESaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %1) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %1) #8
  resume { ptr, i32 } %.pn31.pn.pn.pn.pn.pn.pn.pn.pn.pn
}

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

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

declare void @_ZN7Riemann8AABBTreeC1Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #6

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

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

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

declare void @_ZN7Riemann8AABBTree7ReleaseEv(ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #6

declare void @_ZN7Riemann8AABBTree11StaticBuildERNS_17AABBTreeBuildDataE(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(41)) local_unnamed_addr #6

declare noundef i32 @_ZNK7Riemann8AABBTree14IntersectPointERKN5Maths8TVector3IfEE(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 4 dereferenceable(12)) local_unnamed_addr #6

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN7Riemann13RayCastOptionC2Ev(ptr noundef nonnull align 8 dereferenceable(192)) unnamed_addr #3 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN7Riemann13RayCastResultC2Ev(ptr noundef nonnull align 8 dereferenceable(76)) unnamed_addr #3 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN4Ray3C2ERKN5Maths8TVector3IfEES4_b(ptr noundef nonnull align 4 dereferenceable(24), ptr noundef nonnull align 4 dereferenceable(12), ptr noundef nonnull align 4 dereferenceable(12), i1 noundef zeroext) unnamed_addr #3 align 2

declare noundef zeroext i1 @_ZNK7Riemann8AABBTree18RayCastBoundingBoxERK4Ray3RKNS_13RayCastOptionEPNS_13RayCastResultE(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 4 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(192), ptr noundef) local_unnamed_addr #6

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

declare void @_ZN7Riemann8AABBTree9StatisticERNS_14TreeStatisticsE(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 4 dereferenceable(20)) local_unnamed_addr #6

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

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

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

; Function Attrs: nounwind
declare void @_ZN7Riemann8AABBTreeD1Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #7

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt6vectorIN5Maths6TAABB3IfEESaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #5 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 = { 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 = { "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 "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #8 = { nounwind }

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !11, i64 40}
!6 = !{!"_ZTSN7Riemann17AABBTreeBuildDataE", !7, i64 0, !7, i64 4, !10, i64 8, !10, i64 16, !10, i64 24, !10, i64 32, !11, i64 40}
!7 = !{!"int", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C++ TBAA"}
!10 = !{!"any pointer", !8, i64 0}
!11 = !{!"_ZTSN7Riemann14SplitHeuristicE", !8, i64 0}
!12 = distinct !{!12, !13}
!13 = !{!"llvm.loop.mustprogress"}
!14 = distinct !{!14, !13}


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