; LLVM IR from ysyesilyurt/ComputerGraphics :: ForwardRenderingPipeline/Scene.ll (Z8clipLineRSt4pairI4Vec45ColorES3_)

; 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.Vec4 = type <{ double, double, double, double, i32, [4 x i8] }>
%class.Color = type { double, double, double }
%"struct.std::pair" = type { %class.Vec4, %class.Color }

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

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #1

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_Z7visibleddRdS_(double noundef, double noundef, ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(8)) #2

; Function Attrs: mustprogress uwtable
define dso_local noundef zeroext i1 @_Z8clipLineRSt4pairI4Vec45ColorES3_(ptr noundef nonnull align 8 dereferenceable(64) %0, ptr noundef nonnull align 8 dereferenceable(64) %1) #3 {
  %3 = alloca ptr, align 8
  %4 = alloca ptr, align 8
  %5 = alloca i8, align 1
  %6 = alloca %class.Vec4, align 8
  %7 = alloca %class.Vec4, align 8
  %8 = alloca %class.Color, align 8
  %9 = alloca %class.Color, align 8
  %10 = alloca double, align 8
  %11 = alloca double, align 8
  %12 = alloca double, align 8
  %13 = alloca double, align 8
  %14 = alloca double, align 8
  %15 = alloca %class.Color, align 8
  %16 = alloca double, align 8
  %17 = alloca double, align 8
  %18 = alloca double, align 8
  %19 = alloca double, align 8
  %20 = alloca double, align 8
  %21 = alloca double, align 8
  %22 = alloca %class.Color, align 8
  %23 = alloca %class.Color, align 8
  %24 = alloca %class.Color, align 8
  %25 = alloca %class.Color, align 8
  store ptr %0, ptr %3, align 8, !tbaa !5
  store ptr %1, ptr %4, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 1, ptr %5) #6
  store i8 0, ptr %5, align 1, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 40, ptr %6) #6
  %26 = load ptr, ptr %3, align 8, !tbaa !5
  %27 = getelementptr inbounds %"struct.std::pair", ptr %26, i32 0, i32 0
  call void @_ZN4Vec4C1ERKS_(ptr noundef nonnull align 8 dereferenceable(36) %6, ptr noundef nonnull align 8 dereferenceable(36) %27)
  call void @llvm.lifetime.start.p0(i64 40, ptr %7) #6
  %28 = load ptr, ptr %4, align 8, !tbaa !5
  %29 = getelementptr inbounds %"struct.std::pair", ptr %28, i32 0, i32 0
  call void @_ZN4Vec4C1ERKS_(ptr noundef nonnull align 8 dereferenceable(36) %7, ptr noundef nonnull align 8 dereferenceable(36) %29)
  call void @llvm.lifetime.start.p0(i64 24, ptr %8) #6
  %30 = load ptr, ptr %3, align 8, !tbaa !5
  %31 = getelementptr inbounds %"struct.std::pair", ptr %30, i32 0, i32 1
  call void @_ZN5ColorC1ERKS_(ptr noundef nonnull align 8 dereferenceable(24) %8, ptr noundef nonnull align 8 dereferenceable(24) %31)
  call void @llvm.lifetime.start.p0(i64 24, ptr %9) #6
  %32 = load ptr, ptr %4, align 8, !tbaa !5
  %33 = getelementptr inbounds %"struct.std::pair", ptr %32, i32 0, i32 1
  call void @_ZN5ColorC1ERKS_(ptr noundef nonnull align 8 dereferenceable(24) %9, ptr noundef nonnull align 8 dereferenceable(24) %33)
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #6
  store double 0.000000e+00, ptr %10, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #6
  store double 1.000000e+00, ptr %11, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #6
  %34 = getelementptr inbounds %class.Vec4, ptr %7, i32 0, i32 0
  %35 = load double, ptr %34, align 8, !tbaa !13
  %36 = getelementptr inbounds %class.Vec4, ptr %6, i32 0, i32 0
  %37 = load double, ptr %36, align 8, !tbaa !13
  %38 = fsub double %35, %37
  store double %38, ptr %12, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #6
  %39 = getelementptr inbounds %class.Vec4, ptr %7, i32 0, i32 1
  %40 = load double, ptr %39, align 8, !tbaa !16
  %41 = getelementptr inbounds %class.Vec4, ptr %6, i32 0, i32 1
  %42 = load double, ptr %41, align 8, !tbaa !16
  %43 = fsub double %40, %42
  store double %43, ptr %13, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #6
  %44 = getelementptr inbounds %class.Vec4, ptr %7, i32 0, i32 2
  %45 = load double, ptr %44, align 8, !tbaa !17
  %46 = getelementptr inbounds %class.Vec4, ptr %6, i32 0, i32 2
  %47 = load double, ptr %46, align 8, !tbaa !17
  %48 = fsub double %45, %47
  store double %48, ptr %14, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 24, ptr %15) #6
  call void @_ZNK5ColormiERKS_(ptr dead_on_unwind writable sret(%class.Color) align 8 %15, ptr noundef nonnull align 8 dereferenceable(24) %9, ptr noundef nonnull align 8 dereferenceable(24) %8)
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #6
  store double -1.000000e+00, ptr %16, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #6
  store double -1.000000e+00, ptr %17, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #6
  store double -1.000000e+00, ptr %18, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 8, ptr %19) #6
  store double 1.000000e+00, ptr %19, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 8, ptr %20) #6
  store double 1.000000e+00, ptr %20, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 8, ptr %21) #6
  store double 1.000000e+00, ptr %21, align 8, !tbaa !11
  %49 = load double, ptr %12, align 8, !tbaa !11
  %50 = load double, ptr %16, align 8, !tbaa !11
  %51 = getelementptr inbounds %class.Vec4, ptr %6, i32 0, i32 0
  %52 = load double, ptr %51, align 8, !tbaa !13
  %53 = fsub double %50, %52
  %54 = call noundef zeroext i1 @_Z7visibleddRdS_(double noundef %49, double noundef %53, ptr noundef nonnull align 8 dereferenceable(8) %10, ptr noundef nonnull align 8 dereferenceable(8) %11)
  br i1 %54, label %55, label %140

55:                                               ; preds = %2
  %56 = load double, ptr %12, align 8, !tbaa !11
  %57 = fneg double %56
  %58 = getelementptr inbounds %class.Vec4, ptr %6, i32 0, i32 0
  %59 = load double, ptr %58, align 8, !tbaa !13
  %60 = load double, ptr %19, align 8, !tbaa !11
  %61 = fsub double %59, %60
  %62 = call noundef zeroext i1 @_Z7visibleddRdS_(double noundef %57, double noundef %61, ptr noundef nonnull align 8 dereferenceable(8) %10, ptr noundef nonnull align 8 dereferenceable(8) %11)
  br i1 %62, label %63, label %140

63:                                               ; preds = %55
  %64 = load double, ptr %13, align 8, !tbaa !11
  %65 = load double, ptr %17, align 8, !tbaa !11
  %66 = getelementptr inbounds %class.Vec4, ptr %6, i32 0, i32 1
  %67 = load double, ptr %66, align 8, !tbaa !16
  %68 = fsub double %65, %67
  %69 = call noundef zeroext i1 @_Z7visibleddRdS_(double noundef %64, double noundef %68, ptr noundef nonnull align 8 dereferenceable(8) %10, ptr noundef nonnull align 8 dereferenceable(8) %11)
  br i1 %69, label %70, label %140

70:                                               ; preds = %63
  %71 = load double, ptr %13, align 8, !tbaa !11
  %72 = fneg double %71
  %73 = getelementptr inbounds %class.Vec4, ptr %6, i32 0, i32 1
  %74 = load double, ptr %73, align 8, !tbaa !16
  %75 = load double, ptr %20, align 8, !tbaa !11
  %76 = fsub double %74, %75
  %77 = call noundef zeroext i1 @_Z7visibleddRdS_(double noundef %72, double noundef %76, ptr noundef nonnull align 8 dereferenceable(8) %10, ptr noundef nonnull align 8 dereferenceable(8) %11)
  br i1 %77, label %78, label %140

78:                                               ; preds = %70
  %79 = load double, ptr %14, align 8, !tbaa !11
  %80 = load double, ptr %18, align 8, !tbaa !11
  %81 = getelementptr inbounds %class.Vec4, ptr %6, i32 0, i32 2
  %82 = load double, ptr %81, align 8, !tbaa !17
  %83 = fsub double %80, %82
  %84 = call noundef zeroext i1 @_Z7visibleddRdS_(double noundef %79, double noundef %83, ptr noundef nonnull align 8 dereferenceable(8) %10, ptr noundef nonnull align 8 dereferenceable(8) %11)
  br i1 %84, label %85, label %140

85:                                               ; preds = %78
  %86 = load double, ptr %14, align 8, !tbaa !11
  %87 = fneg double %86
  %88 = getelementptr inbounds %class.Vec4, ptr %6, i32 0, i32 2
  %89 = load double, ptr %88, align 8, !tbaa !17
  %90 = load double, ptr %21, align 8, !tbaa !11
  %91 = fsub double %89, %90
  %92 = call noundef zeroext i1 @_Z7visibleddRdS_(double noundef %87, double noundef %91, ptr noundef nonnull align 8 dereferenceable(8) %10, ptr noundef nonnull align 8 dereferenceable(8) %11)
  br i1 %92, label %93, label %140

93:                                               ; preds = %85
  store i8 1, ptr %5, align 1, !tbaa !9
  %94 = load double, ptr %11, align 8, !tbaa !11
  %95 = fcmp olt double %94, 1.000000e+00
  br i1 %95, label %96, label %116

96:                                               ; preds = %93
  %97 = getelementptr inbounds %class.Vec4, ptr %6, i32 0, i32 0
  %98 = load double, ptr %97, align 8, !tbaa !13
  %99 = load double, ptr %12, align 8, !tbaa !11
  %100 = load double, ptr %11, align 8, !tbaa !11
  %101 = call double @llvm.fmuladd.f64(double %99, double %100, double %98)
  %102 = getelementptr inbounds %class.Vec4, ptr %7, i32 0, i32 0
  store double %101, ptr %102, align 8, !tbaa !13
  %103 = getelementptr inbounds %class.Vec4, ptr %6, i32 0, i32 1
  %104 = load double, ptr %103, align 8, !tbaa !16
  %105 = load double, ptr %13, align 8, !tbaa !11
  %106 = load double, ptr %11, align 8, !tbaa !11
  %107 = call double @llvm.fmuladd.f64(double %105, double %106, double %104)
  %108 = getelementptr inbounds %class.Vec4, ptr %7, i32 0, i32 1
  store double %107, ptr %108, align 8, !tbaa !16
  %109 = getelementptr inbounds %class.Vec4, ptr %6, i32 0, i32 2
  %110 = load double, ptr %109, align 8, !tbaa !17
  %111 = load double, ptr %14, align 8, !tbaa !11
  %112 = load double, ptr %11, align 8, !tbaa !11
  %113 = call double @llvm.fmuladd.f64(double %111, double %112, double %110)
  %114 = getelementptr inbounds %class.Vec4, ptr %7, i32 0, i32 2
  store double %113, ptr %114, align 8, !tbaa !17
  call void @llvm.lifetime.start.p0(i64 24, ptr %22) #6
  call void @llvm.lifetime.start.p0(i64 24, ptr %23) #6
  %115 = load double, ptr %11, align 8, !tbaa !11
  call void @_ZNK5ColormlEd(ptr dead_on_unwind writable sret(%class.Color) align 8 %23, ptr noundef nonnull align 8 dereferenceable(24) %15, double noundef %115)
  call void @_ZNK5ColorplERKS_(ptr dead_on_unwind writable sret(%class.Color) align 8 %22, ptr noundef nonnull align 8 dereferenceable(24) %8, ptr noundef nonnull align 8 dereferenceable(24) %23)
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %9, ptr align 8 %22, i64 24, i1 false), !tbaa.struct !18
  call void @llvm.lifetime.end.p0(i64 24, ptr %23) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr %22) #6
  br label %116

116:                                              ; preds = %96, %93
  %117 = load double, ptr %10, align 8, !tbaa !11
  %118 = fcmp ogt double %117, 0.000000e+00
  br i1 %118, label %119, label %139

119:                                              ; preds = %116
  %120 = getelementptr inbounds %class.Vec4, ptr %6, i32 0, i32 0
  %121 = load double, ptr %120, align 8, !tbaa !13
  %122 = load double, ptr %12, align 8, !tbaa !11
  %123 = load double, ptr %10, align 8, !tbaa !11
  %124 = call double @llvm.fmuladd.f64(double %122, double %123, double %121)
  %125 = getelementptr inbounds %class.Vec4, ptr %6, i32 0, i32 0
  store double %124, ptr %125, align 8, !tbaa !13
  %126 = getelementptr inbounds %class.Vec4, ptr %6, i32 0, i32 1
  %127 = load double, ptr %126, align 8, !tbaa !16
  %128 = load double, ptr %13, align 8, !tbaa !11
  %129 = load double, ptr %10, align 8, !tbaa !11
  %130 = call double @llvm.fmuladd.f64(double %128, double %129, double %127)
  %131 = getelementptr inbounds %class.Vec4, ptr %6, i32 0, i32 1
  store double %130, ptr %131, align 8, !tbaa !16
  %132 = getelementptr inbounds %class.Vec4, ptr %6, i32 0, i32 2
  %133 = load double, ptr %132, align 8, !tbaa !17
  %134 = load double, ptr %14, align 8, !tbaa !11
  %135 = load double, ptr %10, align 8, !tbaa !11
  %136 = call double @llvm.fmuladd.f64(double %134, double %135, double %133)
  %137 = getelementptr inbounds %class.Vec4, ptr %6, i32 0, i32 2
  store double %136, ptr %137, align 8, !tbaa !17
  call void @llvm.lifetime.start.p0(i64 24, ptr %24) #6
  call void @llvm.lifetime.start.p0(i64 24, ptr %25) #6
  %138 = load double, ptr %10, align 8, !tbaa !11
  call void @_ZNK5ColormlEd(ptr dead_on_unwind writable sret(%class.Color) align 8 %25, ptr noundef nonnull align 8 dereferenceable(24) %15, double noundef %138)
  call void @_ZNK5ColorplERKS_(ptr dead_on_unwind writable sret(%class.Color) align 8 %24, ptr noundef nonnull align 8 dereferenceable(24) %8, ptr noundef nonnull align 8 dereferenceable(24) %25)
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %8, ptr align 8 %24, i64 24, i1 false), !tbaa.struct !18
  call void @llvm.lifetime.end.p0(i64 24, ptr %25) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr %24) #6
  br label %139

139:                                              ; preds = %119, %116
  br label %140

140:                                              ; preds = %139, %85, %78, %70, %63, %55, %2
  %141 = load ptr, ptr %3, align 8, !tbaa !5
  %142 = getelementptr inbounds %"struct.std::pair", ptr %141, i32 0, i32 0
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %142, ptr align 8 %6, i64 36, i1 false), !tbaa.struct !19
  %143 = load ptr, ptr %3, align 8, !tbaa !5
  %144 = getelementptr inbounds %"struct.std::pair", ptr %143, i32 0, i32 1
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %144, ptr align 8 %8, i64 24, i1 false), !tbaa.struct !18
  %145 = load ptr, ptr %4, align 8, !tbaa !5
  %146 = getelementptr inbounds %"struct.std::pair", ptr %145, i32 0, i32 0
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %146, ptr align 8 %7, i64 36, i1 false), !tbaa.struct !19
  %147 = load ptr, ptr %4, align 8, !tbaa !5
  %148 = getelementptr inbounds %"struct.std::pair", ptr %147, i32 0, i32 1
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %148, ptr align 8 %9, i64 24, i1 false), !tbaa.struct !18
  %149 = load i8, ptr %5, align 1, !tbaa !9, !range !21, !noundef !22
  %150 = trunc i8 %149 to i1
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr %15) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr %9) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr %8) #6
  call void @llvm.lifetime.end.p0(i64 40, ptr %7) #6
  call void @llvm.lifetime.end.p0(i64 40, ptr %6) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr %5) #6
  ret i1 %150
}

declare void @_ZN4Vec4C1ERKS_(ptr noundef nonnull align 8 dereferenceable(36), ptr noundef nonnull align 8 dereferenceable(36)) unnamed_addr #4

declare void @_ZN5ColorC1ERKS_(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #4

declare void @_ZNK5ColormiERKS_(ptr dead_on_unwind writable sret(%class.Color) align 8, ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(24)) #4

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare double @llvm.fmuladd.f64(double, double, double) #5

declare void @_ZNK5ColorplERKS_(ptr dead_on_unwind writable sret(%class.Color) align 8, ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(24)) #4

declare void @_ZNK5ColormlEd(ptr dead_on_unwind writable sret(%class.Color) align 8, ptr noundef nonnull align 8 dereferenceable(24), double noundef) #4

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

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

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


; 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.Vec4 = type <{ double, double, double, double, i32, [4 x i8] }>
%class.Color = type { double, double, double }

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

; Function Attrs: mustprogress nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #1

; 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 nounwind uwtable
declare dso_local noundef zeroext i1 @_Z7visibleddRdS_(double noundef, double noundef, ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #2

; Function Attrs: mustprogress uwtable
define dso_local noundef zeroext i1 @_Z8clipLineRSt4pairI4Vec45ColorES3_(ptr noundef nonnull align 8 dereferenceable(64) %0, ptr noundef nonnull align 8 dereferenceable(64) %1) local_unnamed_addr #3 {
  %3 = alloca %class.Vec4, align 16
  %4 = alloca %class.Vec4, align 16
  %5 = alloca %class.Color, align 8
  %6 = alloca %class.Color, align 8
  %7 = alloca double, align 8
  %8 = alloca double, align 8
  %9 = alloca %class.Color, align 8
  %10 = alloca %class.Color, align 8
  %11 = alloca %class.Color, align 8
  %12 = alloca %class.Color, align 8
  %13 = alloca %class.Color, align 8
  call void @llvm.lifetime.start.p0(i64 40, ptr nonnull %3) #7
  call void @_ZN4Vec4C1ERKS_(ptr noundef nonnull align 8 dereferenceable(36) %3, ptr noundef nonnull align 8 dereferenceable(36) %0)
  call void @llvm.lifetime.start.p0(i64 40, ptr nonnull %4) #7
  call void @_ZN4Vec4C1ERKS_(ptr noundef nonnull align 8 dereferenceable(36) %4, ptr noundef nonnull align 8 dereferenceable(36) %1)
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %5) #7
  %14 = getelementptr inbounds i8, ptr %0, i64 40
  call void @_ZN5ColorC1ERKS_(ptr noundef nonnull align 8 dereferenceable(24) %5, ptr noundef nonnull align 8 dereferenceable(24) %14)
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %6) #7
  %15 = getelementptr inbounds i8, ptr %1, i64 40
  call void @_ZN5ColorC1ERKS_(ptr noundef nonnull align 8 dereferenceable(24) %6, ptr noundef nonnull align 8 dereferenceable(24) %15)
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %7) #7
  store double 0.000000e+00, ptr %7, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %8) #7
  store double 1.000000e+00, ptr %8, align 8, !tbaa !5
  %16 = getelementptr inbounds i8, ptr %3, i64 8
  %17 = load <2 x double>, ptr %4, align 16, !tbaa !5
  %18 = load <2 x double>, ptr %3, align 16, !tbaa !5
  %19 = fsub <2 x double> %17, %18
  %20 = getelementptr inbounds i8, ptr %4, i64 16
  %21 = load double, ptr %20, align 16, !tbaa !9
  %22 = getelementptr inbounds i8, ptr %3, i64 16
  %23 = load double, ptr %22, align 16, !tbaa !9
  %24 = fsub double %21, %23
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %9) #7
  call void @_ZNK5ColormiERKS_(ptr dead_on_unwind nonnull writable sret(%class.Color) align 8 %9, ptr noundef nonnull align 8 dereferenceable(24) %6, ptr noundef nonnull align 8 dereferenceable(24) %5)
  %25 = load double, ptr %3, align 16, !tbaa !12
  %26 = fsub double -1.000000e+00, %25
  %27 = extractelement <2 x double> %19, i64 0
  %28 = call noundef zeroext i1 @_Z7visibleddRdS_(double noundef %27, double noundef %26, ptr noundef nonnull align 8 dereferenceable(8) %7, ptr noundef nonnull align 8 dereferenceable(8) %8)
  br i1 %28, label %29, label %73

29:                                               ; preds = %2
  %30 = fneg double %27
  %31 = load double, ptr %3, align 16, !tbaa !12
  %32 = fadd double %31, -1.000000e+00
  %33 = call noundef zeroext i1 @_Z7visibleddRdS_(double noundef %30, double noundef %32, ptr noundef nonnull align 8 dereferenceable(8) %7, ptr noundef nonnull align 8 dereferenceable(8) %8)
  br i1 %33, label %34, label %73

34:                                               ; preds = %29
  %35 = load double, ptr %16, align 8, !tbaa !13
  %36 = fsub double -1.000000e+00, %35
  %37 = extractelement <2 x double> %19, i64 1
  %38 = call noundef zeroext i1 @_Z7visibleddRdS_(double noundef %37, double noundef %36, ptr noundef nonnull align 8 dereferenceable(8) %7, ptr noundef nonnull align 8 dereferenceable(8) %8)
  br i1 %38, label %39, label %73

39:                                               ; preds = %34
  %40 = fneg double %37
  %41 = load double, ptr %16, align 8, !tbaa !13
  %42 = fadd double %41, -1.000000e+00
  %43 = call noundef zeroext i1 @_Z7visibleddRdS_(double noundef %40, double noundef %42, ptr noundef nonnull align 8 dereferenceable(8) %7, ptr noundef nonnull align 8 dereferenceable(8) %8)
  br i1 %43, label %44, label %73

44:                                               ; preds = %39
  %45 = load double, ptr %22, align 16, !tbaa !9
  %46 = fsub double -1.000000e+00, %45
  %47 = call noundef zeroext i1 @_Z7visibleddRdS_(double noundef %24, double noundef %46, ptr noundef nonnull align 8 dereferenceable(8) %7, ptr noundef nonnull align 8 dereferenceable(8) %8)
  br i1 %47, label %48, label %73

48:                                               ; preds = %44
  %49 = fneg double %24
  %50 = load double, ptr %22, align 16, !tbaa !9
  %51 = fadd double %50, -1.000000e+00
  %52 = call noundef zeroext i1 @_Z7visibleddRdS_(double noundef %49, double noundef %51, ptr noundef nonnull align 8 dereferenceable(8) %7, ptr noundef nonnull align 8 dereferenceable(8) %8)
  br i1 %52, label %53, label %73

53:                                               ; preds = %48
  %54 = load double, ptr %8, align 8, !tbaa !5
  %55 = fcmp olt double %54, 1.000000e+00
  br i1 %55, label %56, label %63

56:                                               ; preds = %53
  %57 = load <2 x double>, ptr %3, align 16, !tbaa !5
  %58 = insertelement <2 x double> poison, double %54, i64 0
  %59 = shufflevector <2 x double> %58, <2 x double> poison, <2 x i32> zeroinitializer
  %60 = call <2 x double> @llvm.fmuladd.v2f64(<2 x double> %19, <2 x double> %59, <2 x double> %57)
  store <2 x double> %60, ptr %4, align 16, !tbaa !5
  %61 = load double, ptr %22, align 16, !tbaa !9
  %62 = call double @llvm.fmuladd.f64(double %24, double %54, double %61)
  store double %62, ptr %20, align 16, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %10) #7
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %11) #7
  call void @_ZNK5ColormlEd(ptr dead_on_unwind nonnull writable sret(%class.Color) align 8 %11, ptr noundef nonnull align 8 dereferenceable(24) %9, double noundef %54)
  call void @_ZNK5ColorplERKS_(ptr dead_on_unwind nonnull writable sret(%class.Color) align 8 %10, ptr noundef nonnull align 8 dereferenceable(24) %5, ptr noundef nonnull align 8 dereferenceable(24) %11)
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(24) %6, ptr noundef nonnull align 8 dereferenceable(24) %10, i64 24, i1 false), !tbaa.struct !14
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %11) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %10) #7
  br label %63

63:                                               ; preds = %56, %53
  %64 = load double, ptr %7, align 8, !tbaa !5
  %65 = fcmp ogt double %64, 0.000000e+00
  br i1 %65, label %66, label %73

66:                                               ; preds = %63
  %67 = load <2 x double>, ptr %3, align 16, !tbaa !5
  %68 = insertelement <2 x double> poison, double %64, i64 0
  %69 = shufflevector <2 x double> %68, <2 x double> poison, <2 x i32> zeroinitializer
  %70 = call <2 x double> @llvm.fmuladd.v2f64(<2 x double> %19, <2 x double> %69, <2 x double> %67)
  store <2 x double> %70, ptr %3, align 16, !tbaa !5
  %71 = load double, ptr %22, align 16, !tbaa !9
  %72 = call double @llvm.fmuladd.f64(double %24, double %64, double %71)
  store double %72, ptr %22, align 16, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %12) #7
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %13) #7
  call void @_ZNK5ColormlEd(ptr dead_on_unwind nonnull writable sret(%class.Color) align 8 %13, ptr noundef nonnull align 8 dereferenceable(24) %9, double noundef %64)
  call void @_ZNK5ColorplERKS_(ptr dead_on_unwind nonnull writable sret(%class.Color) align 8 %12, ptr noundef nonnull align 8 dereferenceable(24) %5, ptr noundef nonnull align 8 dereferenceable(24) %13)
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(24) %5, ptr noundef nonnull align 8 dereferenceable(24) %12, i64 24, i1 false), !tbaa.struct !14
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %13) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %12) #7
  br label %73

73:                                               ; preds = %63, %66, %48, %44, %39, %34, %29, %2
  %.0 = phi i1 [ true, %66 ], [ true, %63 ], [ false, %48 ], [ false, %44 ], [ false, %39 ], [ false, %34 ], [ false, %29 ], [ false, %2 ]
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(36) %0, ptr noundef nonnull align 16 dereferenceable(36) %3, i64 36, i1 false), !tbaa.struct !15
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(24) %14, ptr noundef nonnull align 8 dereferenceable(24) %5, i64 24, i1 false), !tbaa.struct !14
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(36) %1, ptr noundef nonnull align 16 dereferenceable(36) %4, i64 36, i1 false), !tbaa.struct !15
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(24) %15, ptr noundef nonnull align 8 dereferenceable(24) %6, i64 24, i1 false), !tbaa.struct !14
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %9) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %6) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %5) #7
  call void @llvm.lifetime.end.p0(i64 40, ptr nonnull %4) #7
  call void @llvm.lifetime.end.p0(i64 40, ptr nonnull %3) #7
  ret i1 %.0
}

declare void @_ZN4Vec4C1ERKS_(ptr noundef nonnull align 8 dereferenceable(36), ptr noundef nonnull align 8 dereferenceable(36)) unnamed_addr #4

declare void @_ZN5ColorC1ERKS_(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #4

declare void @_ZNK5ColormiERKS_(ptr dead_on_unwind writable sret(%class.Color) align 8, ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #4

; Function Attrs: mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare double @llvm.fmuladd.f64(double, double, double) #5

declare void @_ZNK5ColorplERKS_(ptr dead_on_unwind writable sret(%class.Color) align 8, ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #4

declare void @_ZNK5ColormlEd(ptr dead_on_unwind writable sret(%class.Color) align 8, ptr noundef nonnull align 8 dereferenceable(24), double noundef) local_unnamed_addr #4

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare <2 x double> @llvm.fmuladd.v2f64(<2 x double>, <2 x double>, <2 x double>) #6

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: readwrite) }
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 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #4 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #5 = { mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #6 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
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 = !{!"double", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !6, i64 16}
!10 = !{!"_ZTS4Vec4", !6, i64 0, !6, i64 8, !6, i64 16, !6, i64 24, !11, i64 32}
!11 = !{!"int", !7, i64 0}
!12 = !{!10, !6, i64 0}
!13 = !{!10, !6, i64 8}
!14 = !{i64 0, i64 8, !5, i64 8, i64 8, !5, i64 16, i64 8, !5}
!15 = !{i64 0, i64 8, !5, i64 8, i64 8, !5, i64 16, i64 8, !5, i64 24, i64 8, !5, i64 32, i64 4, !16}
!16 = !{!11, !11, i64 0}


; Effective O3 passes: EarlyCSEPass,GlobalOptPass,IPSCCPPass,InferAlignmentPass,InferFunctionAttrsPass,InstCombinePass,SLPVectorizerPass,SROAPass,SimplifyCFGPass