; LLVM IR from sejja/3D-Software-Rasterizer :: Rasterizer/Engine/Types/Box.ll (Z4ClipR4Face)

; 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.std::vector.7" = type { %"struct.std::_Vector_base.8" }
%"struct.std::_Vector_base.8" = type { %"struct.std::_Vector_base<Point4, std::allocator<Point4>>::_Vector_impl" }
%"struct.std::_Vector_base<Point4, std::allocator<Point4>>::_Vector_impl" = type { %"struct.std::_Vector_base<Point4, std::allocator<Point4>>::_Vector_impl_data" }
%"struct.std::_Vector_base<Point4, std::allocator<Point4>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%class.Point4 = type { %union.anon }
%union.anon = type { [4 x float] }
%struct.Face = type <{ [3 x %class.Point4], %class.Point4, [3 x i8], i8 }>

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

declare i32 @__gxx_personality_v0(...)

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

; Function Attrs: mustprogress uwtable
define dso_local void @_Z4ClipR4Face(ptr dead_on_unwind noalias writable sret(%"class.std::vector.7") align 8 %0, ptr noundef nonnull align 4 dereferenceable(67) %1) #1 personality ptr @__gxx_personality_v0 {
  %3 = alloca ptr, align 8
  %4 = alloca ptr, align 8
  %5 = alloca i1, align 1
  %6 = alloca %class.Point4, align 4
  %7 = alloca ptr, align 8
  %8 = alloca i32, align 4
  %9 = alloca i32, align 4
  %10 = alloca ptr, align 8
  %11 = alloca ptr, align 8
  %12 = alloca i8, align 1
  %13 = alloca i8, align 1
  store ptr %0, ptr %3, align 8
  store ptr %1, ptr %4, align 8, !tbaa !5
  store i1 false, ptr %5, align 1
  call void @_ZNSt6vectorI6Point4SaIS0_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %0) #4
  call void @llvm.lifetime.start.p0(i64 16, ptr %6) #4
  invoke void @_ZN6Point4C1Ev(ptr noundef nonnull align 4 dereferenceable(16) %6)
          to label %14 unwind label %19

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

15:                                               ; preds = %109, %14
  %16 = load i32, ptr %9, align 4, !tbaa !9
  %17 = icmp slt i32 %16, 3
  br i1 %17, label %23, label %18

18:                                               ; preds = %15
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #4
  br label %112

19:                                               ; preds = %2
  %20 = landingpad { ptr, i32 }
          cleanup
  %21 = extractvalue { ptr, i32 } %20, 0
  store ptr %21, ptr %7, align 8
  %22 = extractvalue { ptr, i32 } %20, 1
  store i32 %22, ptr %8, align 4
  br label %114

23:                                               ; preds = %15
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #4
  %24 = load ptr, ptr %4, align 8, !tbaa !5
  %25 = getelementptr inbounds %struct.Face, ptr %24, i32 0, i32 0
  %26 = load i32, ptr %9, align 4, !tbaa !9
  %27 = sext i32 %26 to i64
  %28 = getelementptr inbounds [3 x %class.Point4], ptr %25, i64 0, i64 %27
  store ptr %28, ptr %10, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #4
  %29 = load ptr, ptr %4, align 8, !tbaa !5
  %30 = getelementptr inbounds %struct.Face, ptr %29, i32 0, i32 0
  %31 = load i32, ptr %9, align 4, !tbaa !9
  %32 = icmp eq i32 %31, 2
  br i1 %32, label %33, label %34

33:                                               ; preds = %23
  br label %37

34:                                               ; preds = %23
  %35 = load i32, ptr %9, align 4, !tbaa !9
  %36 = add nsw i32 %35, 1
  br label %37

37:                                               ; preds = %34, %33
  %38 = phi i32 [ 0, %33 ], [ %36, %34 ]
  %39 = sext i32 %38 to i64
  %40 = getelementptr inbounds [3 x %class.Point4], ptr %30, i64 0, i64 %39
  store ptr %40, ptr %11, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 1, ptr %12) #4
  %41 = load ptr, ptr %4, align 8, !tbaa !5
  %42 = getelementptr inbounds %struct.Face, ptr %41, i32 0, i32 2
  %43 = load i32, ptr %9, align 4, !tbaa !9
  %44 = sext i32 %43 to i64
  %45 = getelementptr inbounds [3 x i8], ptr %42, i64 0, i64 %44
  %46 = load i8, ptr %45, align 1, !tbaa !11, !range !13, !noundef !14
  %47 = trunc i8 %46 to i1
  %48 = zext i1 %47 to i8
  store i8 %48, ptr %12, align 1, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 1, ptr %13) #4
  %49 = load ptr, ptr %4, align 8, !tbaa !5
  %50 = getelementptr inbounds %struct.Face, ptr %49, i32 0, i32 2
  %51 = load i32, ptr %9, align 4, !tbaa !9
  %52 = icmp eq i32 %51, 2
  br i1 %52, label %53, label %54

53:                                               ; preds = %37
  br label %57

54:                                               ; preds = %37
  %55 = load i32, ptr %9, align 4, !tbaa !9
  %56 = add nsw i32 %55, 1
  br label %57

57:                                               ; preds = %54, %53
  %58 = phi i32 [ 0, %53 ], [ %56, %54 ]
  %59 = sext i32 %58 to i64
  %60 = getelementptr inbounds [3 x i8], ptr %50, i64 0, i64 %59
  %61 = load i8, ptr %60, align 1, !tbaa !11, !range !13, !noundef !14
  %62 = trunc i8 %61 to i1
  %63 = zext i1 %62 to i8
  store i8 %63, ptr %13, align 1, !tbaa !11
  %64 = load i8, ptr %12, align 1, !tbaa !11, !range !13, !noundef !14
  %65 = trunc i8 %64 to i1
  br i1 %65, label %66, label %76

66:                                               ; preds = %57
  %67 = load i8, ptr %13, align 1, !tbaa !11, !range !13, !noundef !14
  %68 = trunc i8 %67 to i1
  br i1 %68, label %69, label %76

69:                                               ; preds = %66
  %70 = load ptr, ptr %11, align 8, !tbaa !5
  invoke void @_ZNSt6vectorI6Point4SaIS0_EE9push_backERKS0_(ptr noundef nonnull align 8 dereferenceable(24) %0, ptr noundef nonnull align 4 dereferenceable(16) %70)
          to label %71 unwind label %72

71:                                               ; preds = %69
  br label %108

72:                                               ; preds = %103, %101, %96, %87, %82, %69
  %73 = landingpad { ptr, i32 }
          cleanup
  %74 = extractvalue { ptr, i32 } %73, 0
  store ptr %74, ptr %7, align 8
  %75 = extractvalue { ptr, i32 } %73, 1
  store i32 %75, ptr %8, align 4
  call void @llvm.lifetime.end.p0(i64 1, ptr %13) #4
  call void @llvm.lifetime.end.p0(i64 1, ptr %12) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #4
  br label %114

76:                                               ; preds = %66, %57
  %77 = load i8, ptr %12, align 1, !tbaa !11, !range !13, !noundef !14
  %78 = trunc i8 %77 to i1
  br i1 %78, label %79, label %90

79:                                               ; preds = %76
  %80 = load i8, ptr %13, align 1, !tbaa !11, !range !13, !noundef !14
  %81 = trunc i8 %80 to i1
  br i1 %81, label %90, label %82

82:                                               ; preds = %79
  %83 = load ptr, ptr %10, align 8, !tbaa !5
  %84 = load ptr, ptr %11, align 8, !tbaa !5
  %85 = invoke noundef zeroext i1 @_Z28FindIntersectionWithFrustrumRK6Point4S1_RS_(ptr noundef nonnull align 4 dereferenceable(16) %83, ptr noundef nonnull align 4 dereferenceable(16) %84, ptr noundef nonnull align 4 dereferenceable(16) %6)
          to label %86 unwind label %72

86:                                               ; preds = %82
  br i1 %85, label %87, label %89

87:                                               ; preds = %86
  invoke void @_ZNSt6vectorI6Point4SaIS0_EE9push_backERKS0_(ptr noundef nonnull align 8 dereferenceable(24) %0, ptr noundef nonnull align 4 dereferenceable(16) %6)
          to label %88 unwind label %72

88:                                               ; preds = %87
  br label %89

89:                                               ; preds = %88, %86
  br label %107

90:                                               ; preds = %79, %76
  %91 = load i8, ptr %12, align 1, !tbaa !11, !range !13, !noundef !14
  %92 = trunc i8 %91 to i1
  br i1 %92, label %106, label %93

93:                                               ; preds = %90
  %94 = load i8, ptr %13, align 1, !tbaa !11, !range !13, !noundef !14
  %95 = trunc i8 %94 to i1
  br i1 %95, label %96, label %106

96:                                               ; preds = %93
  %97 = load ptr, ptr %10, align 8, !tbaa !5
  %98 = load ptr, ptr %11, align 8, !tbaa !5
  %99 = invoke noundef zeroext i1 @_Z28FindIntersectionWithFrustrumRK6Point4S1_RS_(ptr noundef nonnull align 4 dereferenceable(16) %97, ptr noundef nonnull align 4 dereferenceable(16) %98, ptr noundef nonnull align 4 dereferenceable(16) %6)
          to label %100 unwind label %72

100:                                              ; preds = %96
  br i1 %99, label %101, label %103

101:                                              ; preds = %100
  invoke void @_ZNSt6vectorI6Point4SaIS0_EE9push_backERKS0_(ptr noundef nonnull align 8 dereferenceable(24) %0, ptr noundef nonnull align 4 dereferenceable(16) %6)
          to label %102 unwind label %72

102:                                              ; preds = %101
  br label %103

103:                                              ; preds = %102, %100
  %104 = load ptr, ptr %11, align 8, !tbaa !5
  invoke void @_ZNSt6vectorI6Point4SaIS0_EE9push_backERKS0_(ptr noundef nonnull align 8 dereferenceable(24) %0, ptr noundef nonnull align 4 dereferenceable(16) %104)
          to label %105 unwind label %72

105:                                              ; preds = %103
  br label %106

106:                                              ; preds = %105, %93, %90
  br label %107

107:                                              ; preds = %106, %89
  br label %108

108:                                              ; preds = %107, %71
  call void @llvm.lifetime.end.p0(i64 1, ptr %13) #4
  call void @llvm.lifetime.end.p0(i64 1, ptr %12) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #4
  br label %109

109:                                              ; preds = %108
  %110 = load i32, ptr %9, align 4, !tbaa !9
  %111 = add nsw i32 %110, 1
  store i32 %111, ptr %9, align 4, !tbaa !9
  br label %15, !llvm.loop !15

112:                                              ; preds = %18
  store i1 true, ptr %5, align 1
  call void @llvm.lifetime.end.p0(i64 16, ptr %6) #4
  %113 = load i1, ptr %5, align 1
  br i1 %113, label %116, label %115

114:                                              ; preds = %72, %19
  call void @llvm.lifetime.end.p0(i64 16, ptr %6) #4
  call void @_ZNSt6vectorI6Point4SaIS0_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %0) #4
  br label %117

115:                                              ; preds = %112
  call void @_ZNSt6vectorI6Point4SaIS0_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %0) #4
  br label %116

116:                                              ; preds = %115, %112
  ret void

117:                                              ; preds = %114
  %118 = load ptr, ptr %7, align 8
  %119 = load i32, ptr %8, align 4
  %120 = insertvalue { ptr, i32 } poison, ptr %118, 0
  %121 = insertvalue { ptr, i32 } %120, i32 %119, 1
  resume { ptr, i32 } %121
}

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef zeroext i1 @_Z28FindIntersectionWithFrustrumRK6Point4S1_RS_(ptr noundef nonnull align 4 dereferenceable(16), ptr noundef nonnull align 4 dereferenceable(16), ptr noundef nonnull align 4 dereferenceable(16)) #1

declare void @_ZN6Point4C1Ev(ptr noundef nonnull align 4 dereferenceable(16)) unnamed_addr #3

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt6vectorI6Point4SaIS0_EE9push_backERKS0_(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 4 dereferenceable(16)) #1 align 2

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

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

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


; Optimized IR (opt -passes='default<O3>'):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

%"class.std::vector.7" = type { %"struct.std::_Vector_base.8" }
%"struct.std::_Vector_base.8" = type { %"struct.std::_Vector_base<Point4, std::allocator<Point4>>::_Vector_impl" }
%"struct.std::_Vector_base<Point4, std::allocator<Point4>>::_Vector_impl" = type { %"struct.std::_Vector_base<Point4, std::allocator<Point4>>::_Vector_impl_data" }
%"struct.std::_Vector_base<Point4, std::allocator<Point4>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%class.Point4 = type { %union.anon }
%union.anon = type { [4 x float] }

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

declare i32 @__gxx_personality_v0(...)

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

; Function Attrs: mustprogress uwtable
define dso_local void @_Z4ClipR4Face(ptr dead_on_unwind noalias nonnull writable sret(%"class.std::vector.7") align 8 %0, ptr noundef nonnull align 4 dereferenceable(67) %1) local_unnamed_addr #1 personality ptr @__gxx_personality_v0 {
  %3 = alloca %class.Point4, align 4
  tail call void @_ZNSt6vectorI6Point4SaIS0_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %0) #4
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %3) #4
  invoke void @_ZN6Point4C1Ev(ptr noundef nonnull align 4 dereferenceable(16) %3)
          to label %.preheader unwind label %11

.preheader:                                       ; preds = %2
  %4 = getelementptr inbounds i8, ptr %1, i64 64
  %5 = getelementptr inbounds i8, ptr %1, i64 16
  %6 = load i8, ptr %4, align 4, !tbaa !5, !range !9, !noundef !10
  %7 = trunc nuw i8 %6 to i1
  %8 = getelementptr inbounds i8, ptr %1, i64 65
  %9 = load i8, ptr %8, align 1, !tbaa !5, !range !9, !noundef !10
  %10 = trunc nuw i8 %9 to i1
  %.not = xor i1 %7, true
  %.not29 = xor i1 %10, true
  %brmerge = select i1 %.not, i1 true, i1 %.not29
  br i1 %brmerge, label %15, label %.invoke37

11:                                               ; preds = %2
  %12 = landingpad { ptr, i32 }
          cleanup
  br label %58

13:                                               ; preds = %.invoke37, %.invoke36, %.invoke, %55, %52, %48, %40, %37, %33, %23, %20, %16
  %14 = landingpad { ptr, i32 }
          cleanup
  br label %58

15:                                               ; preds = %.preheader
  %brmerge31 = select i1 %.not, i1 true, i1 %10
  br i1 %brmerge31, label %19, label %16

16:                                               ; preds = %15
  %17 = invoke noundef zeroext i1 @_Z28FindIntersectionWithFrustrumRK6Point4S1_RS_(ptr noundef nonnull align 4 dereferenceable(16) %1, ptr noundef nonnull align 4 dereferenceable(16) %5, ptr noundef nonnull align 4 dereferenceable(16) %3)
          to label %18 unwind label %13

18:                                               ; preds = %16
  br i1 %17, label %.invoke37, label %25

19:                                               ; preds = %15
  %brmerge33 = select i1 %7, i1 true, i1 %.not29
  br i1 %brmerge33, label %25, label %20

20:                                               ; preds = %19
  %21 = invoke noundef zeroext i1 @_Z28FindIntersectionWithFrustrumRK6Point4S1_RS_(ptr noundef nonnull align 4 dereferenceable(16) %1, ptr noundef nonnull align 4 dereferenceable(16) %5, ptr noundef nonnull align 4 dereferenceable(16) %3)
          to label %22 unwind label %13

22:                                               ; preds = %20
  br i1 %21, label %23, label %.invoke37

23:                                               ; preds = %22
  invoke void @_ZNSt6vectorI6Point4SaIS0_EE9push_backERKS0_(ptr noundef nonnull align 8 dereferenceable(24) %0, ptr noundef nonnull align 4 dereferenceable(16) %3)
          to label %.invoke37 unwind label %13

.invoke37:                                        ; preds = %.preheader, %22, %23, %18
  %24 = phi ptr [ %3, %18 ], [ %5, %23 ], [ %5, %22 ], [ %5, %.preheader ]
  invoke void @_ZNSt6vectorI6Point4SaIS0_EE9push_backERKS0_(ptr noundef nonnull align 8 dereferenceable(24) %0, ptr noundef nonnull align 4 dereferenceable(16) %24)
          to label %25 unwind label %13

25:                                               ; preds = %.invoke37, %19, %18
  %26 = getelementptr inbounds i8, ptr %1, i64 32
  %27 = load i8, ptr %8, align 1, !tbaa !5, !range !9, !noundef !10
  %28 = trunc nuw i8 %27 to i1
  %29 = getelementptr inbounds i8, ptr %1, i64 66
  %30 = load i8, ptr %29, align 2, !tbaa !5, !range !9, !noundef !10
  %31 = trunc nuw i8 %30 to i1
  %.not.1 = xor i1 %28, true
  %.not29.1 = xor i1 %31, true
  %brmerge.1 = select i1 %.not.1, i1 true, i1 %.not29.1
  br i1 %brmerge.1, label %32, label %.invoke36

32:                                               ; preds = %25
  %brmerge31.1 = select i1 %.not.1, i1 true, i1 %31
  br i1 %brmerge31.1, label %36, label %33

33:                                               ; preds = %32
  %34 = invoke noundef zeroext i1 @_Z28FindIntersectionWithFrustrumRK6Point4S1_RS_(ptr noundef nonnull align 4 dereferenceable(16) %5, ptr noundef nonnull align 4 dereferenceable(16) %26, ptr noundef nonnull align 4 dereferenceable(16) %3)
          to label %35 unwind label %13

35:                                               ; preds = %33
  br i1 %34, label %.invoke36, label %42

36:                                               ; preds = %32
  %brmerge33.1 = select i1 %28, i1 true, i1 %.not29.1
  br i1 %brmerge33.1, label %42, label %37

37:                                               ; preds = %36
  %38 = invoke noundef zeroext i1 @_Z28FindIntersectionWithFrustrumRK6Point4S1_RS_(ptr noundef nonnull align 4 dereferenceable(16) %5, ptr noundef nonnull align 4 dereferenceable(16) %26, ptr noundef nonnull align 4 dereferenceable(16) %3)
          to label %39 unwind label %13

39:                                               ; preds = %37
  br i1 %38, label %40, label %.invoke36

40:                                               ; preds = %39
  invoke void @_ZNSt6vectorI6Point4SaIS0_EE9push_backERKS0_(ptr noundef nonnull align 8 dereferenceable(24) %0, ptr noundef nonnull align 4 dereferenceable(16) %3)
          to label %.invoke36 unwind label %13

.invoke36:                                        ; preds = %39, %40, %35, %25
  %41 = phi ptr [ %26, %25 ], [ %3, %35 ], [ %26, %40 ], [ %26, %39 ]
  invoke void @_ZNSt6vectorI6Point4SaIS0_EE9push_backERKS0_(ptr noundef nonnull align 8 dereferenceable(24) %0, ptr noundef nonnull align 4 dereferenceable(16) %41)
          to label %42 unwind label %13

42:                                               ; preds = %.invoke36, %36, %35
  %43 = load i8, ptr %29, align 2, !tbaa !5, !range !9, !noundef !10
  %44 = trunc nuw i8 %43 to i1
  %45 = load i8, ptr %4, align 4, !tbaa !5, !range !9, !noundef !10
  %46 = trunc nuw i8 %45 to i1
  %.not.2 = xor i1 %44, true
  %.not29.2 = xor i1 %46, true
  %brmerge.2 = select i1 %.not.2, i1 true, i1 %.not29.2
  br i1 %brmerge.2, label %47, label %.invoke

47:                                               ; preds = %42
  %brmerge31.2 = select i1 %.not.2, i1 true, i1 %46
  br i1 %brmerge31.2, label %51, label %48

48:                                               ; preds = %47
  %49 = invoke noundef zeroext i1 @_Z28FindIntersectionWithFrustrumRK6Point4S1_RS_(ptr noundef nonnull align 4 dereferenceable(16) %26, ptr noundef nonnull align 4 dereferenceable(16) %1, ptr noundef nonnull align 4 dereferenceable(16) %3)
          to label %50 unwind label %13

50:                                               ; preds = %48
  br i1 %49, label %.invoke, label %57

51:                                               ; preds = %47
  %brmerge33.2 = select i1 %44, i1 true, i1 %.not29.2
  br i1 %brmerge33.2, label %57, label %52

52:                                               ; preds = %51
  %53 = invoke noundef zeroext i1 @_Z28FindIntersectionWithFrustrumRK6Point4S1_RS_(ptr noundef nonnull align 4 dereferenceable(16) %26, ptr noundef nonnull align 4 dereferenceable(16) %1, ptr noundef nonnull align 4 dereferenceable(16) %3)
          to label %54 unwind label %13

54:                                               ; preds = %52
  br i1 %53, label %55, label %.invoke

55:                                               ; preds = %54
  invoke void @_ZNSt6vectorI6Point4SaIS0_EE9push_backERKS0_(ptr noundef nonnull align 8 dereferenceable(24) %0, ptr noundef nonnull align 4 dereferenceable(16) %3)
          to label %.invoke unwind label %13

.invoke:                                          ; preds = %54, %55, %50, %42
  %56 = phi ptr [ %1, %42 ], [ %3, %50 ], [ %1, %55 ], [ %1, %54 ]
  invoke void @_ZNSt6vectorI6Point4SaIS0_EE9push_backERKS0_(ptr noundef nonnull align 8 dereferenceable(24) %0, ptr noundef nonnull align 4 dereferenceable(16) %56)
          to label %57 unwind label %13

57:                                               ; preds = %.invoke, %51, %50
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %3) #4
  ret void

58:                                               ; preds = %13, %11
  %.pn = phi { ptr, i32 } [ %14, %13 ], [ %12, %11 ]
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %3) #4
  call void @_ZNSt6vectorI6Point4SaIS0_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %0) #4
  resume { ptr, i32 } %.pn
}

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef zeroext i1 @_Z28FindIntersectionWithFrustrumRK6Point4S1_RS_(ptr noundef nonnull align 4 dereferenceable(16), ptr noundef nonnull align 4 dereferenceable(16), ptr noundef nonnull align 4 dereferenceable(16)) local_unnamed_addr #1

declare void @_ZN6Point4C1Ev(ptr noundef nonnull align 4 dereferenceable(16)) unnamed_addr #3

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

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

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { mustprogress 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 = { "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 = { 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 = !{!"bool", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{i8 0, i8 2}
!10 = !{}


; Effective O3 passes: EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferAlignmentPass,InferFunctionAttrsPass,InstCombinePass,LICMPass,LoopRotatePass,LoopSimplifyPass,PostOrderFunctionAttrsPass,SROAPass,SimplifyCFGPass,TailCallElimPass