; LLVM IR from ashishzero/karma :: src/modules/core/lin_maths.ll (Z17test_quad_vs_quadRK4QuadS1_)

; 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"

%union.Vec2 = type { %struct.anon.1 }
%struct.anon.1 = type { float, float }
%struct.Quad = type { [4 x %union.Vec2], [4 x %union.Vec2] }

; 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) #0

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef float @_Z8vec2_dot4Vec2S_(<2 x float>, <2 x float>) #1

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

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

; Function Attrs: mustprogress nounwind uwtable
define dso_local noundef zeroext i1 @_Z17test_quad_vs_quadRK4QuadS1_(ptr noundef nonnull align 4 dereferenceable(64) %0, ptr noundef nonnull align 4 dereferenceable(64) %1) #1 {
  %3 = alloca i1, align 1
  %4 = alloca ptr, align 8
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  %8 = alloca i32, align 4
  %9 = alloca i32, align 4
  %10 = alloca i32, align 4
  %11 = alloca float, align 4
  %12 = alloca float, align 4
  %13 = alloca float, align 4
  %14 = alloca float, align 4
  %15 = alloca float, align 4
  %16 = alloca %union.Vec2, align 4
  %17 = alloca i32, align 4
  %18 = alloca %union.Vec2, align 4
  %19 = alloca %union.Vec2, align 4
  %20 = alloca i32, align 4
  %21 = alloca %union.Vec2, align 4
  %22 = alloca %union.Vec2, align 4
  %23 = alloca ptr, align 8
  store ptr %0, ptr %4, align 8, !tbaa !5
  store ptr %1, ptr %5, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %6) #3
  %24 = load ptr, ptr %4, align 8, !tbaa !5
  store ptr %24, ptr %6, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %7) #3
  %25 = load ptr, ptr %5, align 8, !tbaa !5
  store ptr %25, ptr %7, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #3
  store i32 0, ptr %8, align 4, !tbaa !9
  br label %26

26:                                               ; preds = %136, %2
  %27 = load i32, ptr %8, align 4, !tbaa !9
  %28 = icmp slt i32 %27, 2
  br i1 %28, label %30, label %29

29:                                               ; preds = %26
  store i32 2, ptr %9, align 4
  br label %139

30:                                               ; preds = %26
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #3
  store i32 0, ptr %10, align 4, !tbaa !9
  br label %31

31:                                               ; preds = %127, %30
  %32 = load i32, ptr %10, align 4, !tbaa !9
  %33 = icmp slt i32 %32, 4
  br i1 %33, label %35, label %34

34:                                               ; preds = %31
  store i32 5, ptr %9, align 4
  br label %130

35:                                               ; preds = %31
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #3
  store float 0x7FF0000000000000, ptr %11, align 4, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #3
  store float 0xFFF0000000000000, ptr %12, align 4, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #3
  store float 0x7FF0000000000000, ptr %13, align 4, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 4, ptr %14) #3
  store float 0xFFF0000000000000, ptr %14, align 4, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 4, ptr %15) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #3
  %36 = load ptr, ptr %6, align 8, !tbaa !5
  %37 = getelementptr inbounds %struct.Quad, ptr %36, i32 0, i32 1
  %38 = load i32, ptr %10, align 4, !tbaa !9
  %39 = sext i32 %38 to i64
  %40 = getelementptr inbounds [4 x %union.Vec2], ptr %37, i64 0, i64 %39
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %16, ptr align 4 %40, i64 8, i1 false), !tbaa.struct !13
  call void @llvm.lifetime.start.p0(i64 4, ptr %17) #3
  store i32 0, ptr %17, align 4, !tbaa !9
  br label %41

41:                                               ; preds = %74, %35
  %42 = load i32, ptr %17, align 4, !tbaa !9
  %43 = icmp slt i32 %42, 4
  br i1 %43, label %45, label %44

44:                                               ; preds = %41
  store i32 8, ptr %9, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #3
  br label %77

45:                                               ; preds = %41
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %18, ptr align 4 %16, i64 8, i1 false), !tbaa.struct !13
  %46 = load ptr, ptr %6, align 8, !tbaa !5
  %47 = getelementptr inbounds %struct.Quad, ptr %46, i32 0, i32 0
  %48 = load i32, ptr %17, align 4, !tbaa !9
  %49 = sext i32 %48 to i64
  %50 = getelementptr inbounds [4 x %union.Vec2], ptr %47, i64 0, i64 %49
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %19, ptr align 4 %50, i64 8, i1 false), !tbaa.struct !13
  %51 = getelementptr inbounds %union.Vec2, ptr %18, i32 0, i32 0
  %52 = load <2 x float>, ptr %51, align 4
  %53 = getelementptr inbounds %union.Vec2, ptr %19, i32 0, i32 0
  %54 = load <2 x float>, ptr %53, align 4
  %55 = call noundef float @_Z8vec2_dot4Vec2S_(<2 x float> %52, <2 x float> %54)
  store float %55, ptr %15, align 4, !tbaa !11
  %56 = load float, ptr %11, align 4, !tbaa !11
  %57 = load float, ptr %15, align 4, !tbaa !11
  %58 = fcmp olt float %56, %57
  br i1 %58, label %59, label %61

59:                                               ; preds = %45
  %60 = load float, ptr %11, align 4, !tbaa !11
  br label %63

61:                                               ; preds = %45
  %62 = load float, ptr %15, align 4, !tbaa !11
  br label %63

63:                                               ; preds = %61, %59
  %64 = phi float [ %60, %59 ], [ %62, %61 ]
  store float %64, ptr %11, align 4, !tbaa !11
  %65 = load float, ptr %12, align 4, !tbaa !11
  %66 = load float, ptr %15, align 4, !tbaa !11
  %67 = fcmp ogt float %65, %66
  br i1 %67, label %68, label %70

68:                                               ; preds = %63
  %69 = load float, ptr %12, align 4, !tbaa !11
  br label %72

70:                                               ; preds = %63
  %71 = load float, ptr %15, align 4, !tbaa !11
  br label %72

72:                                               ; preds = %70, %68
  %73 = phi float [ %69, %68 ], [ %71, %70 ]
  store float %73, ptr %12, align 4, !tbaa !11
  br label %74

74:                                               ; preds = %72
  %75 = load i32, ptr %17, align 4, !tbaa !9
  %76 = add nsw i32 %75, 1
  store i32 %76, ptr %17, align 4, !tbaa !9
  br label %41, !llvm.loop !15

77:                                               ; preds = %44
  call void @llvm.lifetime.start.p0(i64 4, ptr %20) #3
  store i32 0, ptr %20, align 4, !tbaa !9
  br label %78

78:                                               ; preds = %111, %77
  %79 = load i32, ptr %20, align 4, !tbaa !9
  %80 = icmp slt i32 %79, 4
  br i1 %80, label %82, label %81

81:                                               ; preds = %78
  store i32 11, ptr %9, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %20) #3
  br label %114

82:                                               ; preds = %78
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %21, ptr align 4 %16, i64 8, i1 false), !tbaa.struct !13
  %83 = load ptr, ptr %7, align 8, !tbaa !5
  %84 = getelementptr inbounds %struct.Quad, ptr %83, i32 0, i32 0
  %85 = load i32, ptr %20, align 4, !tbaa !9
  %86 = sext i32 %85 to i64
  %87 = getelementptr inbounds [4 x %union.Vec2], ptr %84, i64 0, i64 %86
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %22, ptr align 4 %87, i64 8, i1 false), !tbaa.struct !13
  %88 = getelementptr inbounds %union.Vec2, ptr %21, i32 0, i32 0
  %89 = load <2 x float>, ptr %88, align 4
  %90 = getelementptr inbounds %union.Vec2, ptr %22, i32 0, i32 0
  %91 = load <2 x float>, ptr %90, align 4
  %92 = call noundef float @_Z8vec2_dot4Vec2S_(<2 x float> %89, <2 x float> %91)
  store float %92, ptr %15, align 4, !tbaa !11
  %93 = load float, ptr %13, align 4, !tbaa !11
  %94 = load float, ptr %15, align 4, !tbaa !11
  %95 = fcmp olt float %93, %94
  br i1 %95, label %96, label %98

96:                                               ; preds = %82
  %97 = load float, ptr %13, align 4, !tbaa !11
  br label %100

98:                                               ; preds = %82
  %99 = load float, ptr %15, align 4, !tbaa !11
  br label %100

100:                                              ; preds = %98, %96
  %101 = phi float [ %97, %96 ], [ %99, %98 ]
  store float %101, ptr %13, align 4, !tbaa !11
  %102 = load float, ptr %14, align 4, !tbaa !11
  %103 = load float, ptr %15, align 4, !tbaa !11
  %104 = fcmp ogt float %102, %103
  br i1 %104, label %105, label %107

105:                                              ; preds = %100
  %106 = load float, ptr %14, align 4, !tbaa !11
  br label %109

107:                                              ; preds = %100
  %108 = load float, ptr %15, align 4, !tbaa !11
  br label %109

109:                                              ; preds = %107, %105
  %110 = phi float [ %106, %105 ], [ %108, %107 ]
  store float %110, ptr %14, align 4, !tbaa !11
  br label %111

111:                                              ; preds = %109
  %112 = load i32, ptr %20, align 4, !tbaa !9
  %113 = add nsw i32 %112, 1
  store i32 %113, ptr %20, align 4, !tbaa !9
  br label %78, !llvm.loop !17

114:                                              ; preds = %81
  %115 = load float, ptr %14, align 4, !tbaa !11
  %116 = load float, ptr %11, align 4, !tbaa !11
  %117 = fcmp oge float %115, %116
  br i1 %117, label %118, label %122

118:                                              ; preds = %114
  %119 = load float, ptr %12, align 4, !tbaa !11
  %120 = load float, ptr %13, align 4, !tbaa !11
  %121 = fcmp oge float %119, %120
  br i1 %121, label %123, label %122

122:                                              ; preds = %118, %114
  store i1 false, ptr %3, align 1
  store i32 1, ptr %9, align 4
  br label %124

123:                                              ; preds = %118
  store i32 0, ptr %9, align 4
  br label %124

124:                                              ; preds = %123, %122
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %15) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #3
  %125 = load i32, ptr %9, align 4
  switch i32 %125, label %130 [
    i32 0, label %126
  ]

126:                                              ; preds = %124
  br label %127

127:                                              ; preds = %126
  %128 = load i32, ptr %10, align 4, !tbaa !9
  %129 = add nsw i32 %128, 1
  store i32 %129, ptr %10, align 4, !tbaa !9
  br label %31, !llvm.loop !18

130:                                              ; preds = %124, %34
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #3
  %131 = load i32, ptr %9, align 4
  switch i32 %131, label %139 [
    i32 5, label %132
  ]

132:                                              ; preds = %130
  call void @llvm.lifetime.start.p0(i64 8, ptr %23) #3
  %133 = load ptr, ptr %6, align 8, !tbaa !5
  store ptr %133, ptr %23, align 8, !tbaa !5
  %134 = load ptr, ptr %7, align 8, !tbaa !5
  store ptr %134, ptr %6, align 8, !tbaa !5
  %135 = load ptr, ptr %23, align 8, !tbaa !5
  store ptr %135, ptr %7, align 8, !tbaa !5
  call void @llvm.lifetime.end.p0(i64 8, ptr %23) #3
  br label %136

136:                                              ; preds = %132
  %137 = load i32, ptr %8, align 4, !tbaa !9
  %138 = add nsw i32 %137, 1
  store i32 %138, ptr %8, align 4, !tbaa !9
  br label %26, !llvm.loop !19

139:                                              ; preds = %130, %29
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #3
  %140 = load i32, ptr %9, align 4
  switch i32 %140, label %142 [
    i32 2, label %141
  ]

141:                                              ; preds = %139
  store i1 true, ptr %3, align 1
  store i32 1, ptr %9, align 4
  br label %142

142:                                              ; preds = %141, %139
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #3
  %143 = load i1, ptr %3, align 1
  ret i1 %143
}

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

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

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


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

%union.Vec2 = type { %struct.anon.1 }
%struct.anon.1 = type { float, float }

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef float @_Z8vec2_dot4Vec2S_(<2 x float>, <2 x float>) local_unnamed_addr #0

; Function Attrs: mustprogress nounwind uwtable
define dso_local noundef zeroext i1 @_Z17test_quad_vs_quadRK4QuadS1_(ptr nocapture noundef nonnull readonly align 4 dereferenceable(64) %0, ptr nocapture noundef nonnull readonly align 4 dereferenceable(64) %1) local_unnamed_addr #0 {
.preheader66:
  %2 = getelementptr inbounds i8, ptr %0, i64 8
  %3 = getelementptr inbounds i8, ptr %0, i64 16
  %4 = getelementptr inbounds i8, ptr %0, i64 24
  %5 = getelementptr inbounds i8, ptr %1, i64 8
  %6 = getelementptr inbounds i8, ptr %1, i64 16
  %7 = getelementptr inbounds i8, ptr %1, i64 24
  %8 = getelementptr inbounds i8, ptr %0, i64 32
  %.sroa.011.0.copyload = load <2 x float>, ptr %8, align 4, !tbaa !5
  %.sroa.06.0.copyload = load <2 x float>, ptr %0, align 4, !tbaa !5
  %9 = tail call noundef float @_Z8vec2_dot4Vec2S_(<2 x float> %.sroa.011.0.copyload, <2 x float> %.sroa.06.0.copyload)
  %.sroa.06.0.copyload.1 = load <2 x float>, ptr %2, align 4, !tbaa !5
  %10 = tail call noundef float @_Z8vec2_dot4Vec2S_(<2 x float> %.sroa.011.0.copyload, <2 x float> %.sroa.06.0.copyload.1)
  %.sroa.06.0.copyload.2 = load <2 x float>, ptr %3, align 4, !tbaa !5
  %11 = tail call noundef float @_Z8vec2_dot4Vec2S_(<2 x float> %.sroa.011.0.copyload, <2 x float> %.sroa.06.0.copyload.2)
  %.sroa.06.0.copyload.3 = load <2 x float>, ptr %4, align 4, !tbaa !5
  %12 = tail call noundef float @_Z8vec2_dot4Vec2S_(<2 x float> %.sroa.011.0.copyload, <2 x float> %.sroa.06.0.copyload.3)
  %.sroa.0.0.copyload = load <2 x float>, ptr %1, align 4, !tbaa !5
  %13 = tail call noundef float @_Z8vec2_dot4Vec2S_(<2 x float> %.sroa.011.0.copyload, <2 x float> %.sroa.0.0.copyload)
  %.sroa.0.0.copyload.1 = load <2 x float>, ptr %5, align 4, !tbaa !5
  %14 = tail call noundef float @_Z8vec2_dot4Vec2S_(<2 x float> %.sroa.011.0.copyload, <2 x float> %.sroa.0.0.copyload.1)
  %.sroa.0.0.copyload.2 = load <2 x float>, ptr %6, align 4, !tbaa !5
  %15 = tail call noundef float @_Z8vec2_dot4Vec2S_(<2 x float> %.sroa.011.0.copyload, <2 x float> %.sroa.0.0.copyload.2)
  %.sroa.0.0.copyload.3 = load <2 x float>, ptr %7, align 4, !tbaa !5
  %16 = tail call noundef float @_Z8vec2_dot4Vec2S_(<2 x float> %.sroa.011.0.copyload, <2 x float> %.sroa.0.0.copyload.3)
  %17 = insertelement <2 x float> poison, float %13, i64 0
  %18 = insertelement <2 x float> %17, float %9, i64 1
  %19 = insertelement <2 x float> poison, float %14, i64 0
  %20 = insertelement <2 x float> %19, float %10, i64 1
  %21 = fcmp olt <2 x float> %18, %20
  %22 = select <2 x i1> %21, <2 x float> %18, <2 x float> %20
  %23 = shufflevector <2 x float> %22, <2 x float> poison, <2 x i32> <i32 1, i32 0>
  %24 = fcmp ogt <2 x float> %18, %20
  %25 = select <2 x i1> %24, <2 x float> %18, <2 x float> %20
  %26 = insertelement <2 x float> poison, float %11, i64 0
  %27 = insertelement <2 x float> %26, float %15, i64 1
  %28 = fcmp olt <2 x float> %23, %27
  %29 = select <2 x i1> %28, <2 x float> %23, <2 x float> %27
  %30 = shufflevector <2 x float> %27, <2 x float> poison, <2 x i32> <i32 1, i32 0>
  %31 = fcmp ogt <2 x float> %25, %30
  %32 = select <2 x i1> %31, <2 x float> %25, <2 x float> %30
  %33 = insertelement <2 x float> poison, float %12, i64 0
  %34 = insertelement <2 x float> %33, float %16, i64 1
  %35 = fcmp olt <2 x float> %29, %34
  %36 = shufflevector <2 x float> %34, <2 x float> poison, <2 x i32> <i32 1, i32 0>
  %37 = fcmp ogt <2 x float> %32, %36
  %38 = select <2 x i1> %35, <2 x float> %29, <2 x float> %34
  %39 = select <2 x i1> %37, <2 x float> %32, <2 x float> %36
  %40 = fcmp ult <2 x float> %39, %38
  %shift = shufflevector <2 x i1> %40, <2 x i1> poison, <2 x i32> <i32 1, i32 poison>
  %41 = or <2 x i1> %40, %shift
  %or.cond = extractelement <2 x i1> %41, i64 0
  br i1 %or.cond, label %.critedge65, label %.preheader.1120

.preheader.1120:                                  ; preds = %.preheader66
  %42 = getelementptr inbounds i8, ptr %0, i64 40
  %.sroa.011.0.copyload.1111 = load <2 x float>, ptr %42, align 4, !tbaa !5
  %.sroa.06.0.copyload.1112 = load <2 x float>, ptr %0, align 4, !tbaa !5
  %43 = tail call noundef float @_Z8vec2_dot4Vec2S_(<2 x float> %.sroa.011.0.copyload.1111, <2 x float> %.sroa.06.0.copyload.1112)
  %.sroa.06.0.copyload.1.1113 = load <2 x float>, ptr %2, align 4, !tbaa !5
  %44 = tail call noundef float @_Z8vec2_dot4Vec2S_(<2 x float> %.sroa.011.0.copyload.1111, <2 x float> %.sroa.06.0.copyload.1.1113)
  %.sroa.06.0.copyload.2.1114 = load <2 x float>, ptr %3, align 4, !tbaa !5
  %45 = tail call noundef float @_Z8vec2_dot4Vec2S_(<2 x float> %.sroa.011.0.copyload.1111, <2 x float> %.sroa.06.0.copyload.2.1114)
  %.sroa.06.0.copyload.3.1115 = load <2 x float>, ptr %4, align 4, !tbaa !5
  %46 = tail call noundef float @_Z8vec2_dot4Vec2S_(<2 x float> %.sroa.011.0.copyload.1111, <2 x float> %.sroa.06.0.copyload.3.1115)
  %.sroa.0.0.copyload.1116 = load <2 x float>, ptr %1, align 4, !tbaa !5
  %47 = tail call noundef float @_Z8vec2_dot4Vec2S_(<2 x float> %.sroa.011.0.copyload.1111, <2 x float> %.sroa.0.0.copyload.1116)
  %.sroa.0.0.copyload.1.1117 = load <2 x float>, ptr %5, align 4, !tbaa !5
  %48 = tail call noundef float @_Z8vec2_dot4Vec2S_(<2 x float> %.sroa.011.0.copyload.1111, <2 x float> %.sroa.0.0.copyload.1.1117)
  %.sroa.0.0.copyload.2.1118 = load <2 x float>, ptr %6, align 4, !tbaa !5
  %49 = tail call noundef float @_Z8vec2_dot4Vec2S_(<2 x float> %.sroa.011.0.copyload.1111, <2 x float> %.sroa.0.0.copyload.2.1118)
  %.sroa.0.0.copyload.3.1119 = load <2 x float>, ptr %7, align 4, !tbaa !5
  %50 = tail call noundef float @_Z8vec2_dot4Vec2S_(<2 x float> %.sroa.011.0.copyload.1111, <2 x float> %.sroa.0.0.copyload.3.1119)
  %51 = insertelement <2 x float> poison, float %47, i64 0
  %52 = insertelement <2 x float> %51, float %43, i64 1
  %53 = insertelement <2 x float> poison, float %48, i64 0
  %54 = insertelement <2 x float> %53, float %44, i64 1
  %55 = fcmp olt <2 x float> %52, %54
  %56 = select <2 x i1> %55, <2 x float> %52, <2 x float> %54
  %57 = shufflevector <2 x float> %56, <2 x float> poison, <2 x i32> <i32 1, i32 0>
  %58 = fcmp ogt <2 x float> %52, %54
  %59 = select <2 x i1> %58, <2 x float> %52, <2 x float> %54
  %60 = insertelement <2 x float> poison, float %45, i64 0
  %61 = insertelement <2 x float> %60, float %49, i64 1
  %62 = fcmp olt <2 x float> %57, %61
  %63 = select <2 x i1> %62, <2 x float> %57, <2 x float> %61
  %64 = shufflevector <2 x float> %61, <2 x float> poison, <2 x i32> <i32 1, i32 0>
  %65 = fcmp ogt <2 x float> %59, %64
  %66 = select <2 x i1> %65, <2 x float> %59, <2 x float> %64
  %67 = insertelement <2 x float> poison, float %46, i64 0
  %68 = insertelement <2 x float> %67, float %50, i64 1
  %69 = fcmp olt <2 x float> %63, %68
  %70 = shufflevector <2 x float> %68, <2 x float> poison, <2 x i32> <i32 1, i32 0>
  %71 = fcmp ogt <2 x float> %66, %70
  %72 = select <2 x i1> %69, <2 x float> %63, <2 x float> %68
  %73 = select <2 x i1> %71, <2 x float> %66, <2 x float> %70
  %74 = fcmp ult <2 x float> %73, %72
  %shift.1 = shufflevector <2 x i1> %74, <2 x i1> poison, <2 x i32> <i32 1, i32 poison>
  %75 = or <2 x i1> %74, %shift.1
  %or.cond.1 = extractelement <2 x i1> %75, i64 0
  br i1 %or.cond.1, label %.critedge65, label %.preheader.2

.preheader.2:                                     ; preds = %.preheader.1120
  %76 = getelementptr inbounds i8, ptr %0, i64 48
  %.sroa.011.0.copyload.2 = load <2 x float>, ptr %76, align 4, !tbaa !5
  %.sroa.06.0.copyload.2123 = load <2 x float>, ptr %0, align 4, !tbaa !5
  %77 = tail call noundef float @_Z8vec2_dot4Vec2S_(<2 x float> %.sroa.011.0.copyload.2, <2 x float> %.sroa.06.0.copyload.2123)
  %.sroa.06.0.copyload.1.2 = load <2 x float>, ptr %2, align 4, !tbaa !5
  %78 = tail call noundef float @_Z8vec2_dot4Vec2S_(<2 x float> %.sroa.011.0.copyload.2, <2 x float> %.sroa.06.0.copyload.1.2)
  %.sroa.06.0.copyload.2.2 = load <2 x float>, ptr %3, align 4, !tbaa !5
  %79 = tail call noundef float @_Z8vec2_dot4Vec2S_(<2 x float> %.sroa.011.0.copyload.2, <2 x float> %.sroa.06.0.copyload.2.2)
  %.sroa.06.0.copyload.3.2 = load <2 x float>, ptr %4, align 4, !tbaa !5
  %80 = tail call noundef float @_Z8vec2_dot4Vec2S_(<2 x float> %.sroa.011.0.copyload.2, <2 x float> %.sroa.06.0.copyload.3.2)
  %.sroa.0.0.copyload.2124 = load <2 x float>, ptr %1, align 4, !tbaa !5
  %81 = tail call noundef float @_Z8vec2_dot4Vec2S_(<2 x float> %.sroa.011.0.copyload.2, <2 x float> %.sroa.0.0.copyload.2124)
  %.sroa.0.0.copyload.1.2 = load <2 x float>, ptr %5, align 4, !tbaa !5
  %82 = tail call noundef float @_Z8vec2_dot4Vec2S_(<2 x float> %.sroa.011.0.copyload.2, <2 x float> %.sroa.0.0.copyload.1.2)
  %.sroa.0.0.copyload.2.2 = load <2 x float>, ptr %6, align 4, !tbaa !5
  %83 = tail call noundef float @_Z8vec2_dot4Vec2S_(<2 x float> %.sroa.011.0.copyload.2, <2 x float> %.sroa.0.0.copyload.2.2)
  %.sroa.0.0.copyload.3.2 = load <2 x float>, ptr %7, align 4, !tbaa !5
  %84 = tail call noundef float @_Z8vec2_dot4Vec2S_(<2 x float> %.sroa.011.0.copyload.2, <2 x float> %.sroa.0.0.copyload.3.2)
  %85 = insertelement <2 x float> poison, float %81, i64 0
  %86 = insertelement <2 x float> %85, float %77, i64 1
  %87 = insertelement <2 x float> poison, float %82, i64 0
  %88 = insertelement <2 x float> %87, float %78, i64 1
  %89 = fcmp olt <2 x float> %86, %88
  %90 = select <2 x i1> %89, <2 x float> %86, <2 x float> %88
  %91 = shufflevector <2 x float> %90, <2 x float> poison, <2 x i32> <i32 1, i32 0>
  %92 = fcmp ogt <2 x float> %86, %88
  %93 = select <2 x i1> %92, <2 x float> %86, <2 x float> %88
  %94 = insertelement <2 x float> poison, float %79, i64 0
  %95 = insertelement <2 x float> %94, float %83, i64 1
  %96 = fcmp olt <2 x float> %91, %95
  %97 = select <2 x i1> %96, <2 x float> %91, <2 x float> %95
  %98 = shufflevector <2 x float> %95, <2 x float> poison, <2 x i32> <i32 1, i32 0>
  %99 = fcmp ogt <2 x float> %93, %98
  %100 = select <2 x i1> %99, <2 x float> %93, <2 x float> %98
  %101 = insertelement <2 x float> poison, float %80, i64 0
  %102 = insertelement <2 x float> %101, float %84, i64 1
  %103 = fcmp olt <2 x float> %97, %102
  %104 = shufflevector <2 x float> %102, <2 x float> poison, <2 x i32> <i32 1, i32 0>
  %105 = fcmp ogt <2 x float> %100, %104
  %106 = select <2 x i1> %103, <2 x float> %97, <2 x float> %102
  %107 = select <2 x i1> %105, <2 x float> %100, <2 x float> %104
  %108 = fcmp ult <2 x float> %107, %106
  %shift.2 = shufflevector <2 x i1> %108, <2 x i1> poison, <2 x i32> <i32 1, i32 poison>
  %109 = or <2 x i1> %108, %shift.2
  %or.cond.2 = extractelement <2 x i1> %109, i64 0
  br i1 %or.cond.2, label %.critedge65, label %.preheader.3

.preheader.3:                                     ; preds = %.preheader.2
  %110 = getelementptr inbounds i8, ptr %0, i64 56
  %.sroa.011.0.copyload.3 = load <2 x float>, ptr %110, align 4, !tbaa !5
  %.sroa.06.0.copyload.3125 = load <2 x float>, ptr %0, align 4, !tbaa !5
  %111 = tail call noundef float @_Z8vec2_dot4Vec2S_(<2 x float> %.sroa.011.0.copyload.3, <2 x float> %.sroa.06.0.copyload.3125)
  %.sroa.06.0.copyload.1.3 = load <2 x float>, ptr %2, align 4, !tbaa !5
  %112 = tail call noundef float @_Z8vec2_dot4Vec2S_(<2 x float> %.sroa.011.0.copyload.3, <2 x float> %.sroa.06.0.copyload.1.3)
  %.sroa.06.0.copyload.2.3 = load <2 x float>, ptr %3, align 4, !tbaa !5
  %113 = tail call noundef float @_Z8vec2_dot4Vec2S_(<2 x float> %.sroa.011.0.copyload.3, <2 x float> %.sroa.06.0.copyload.2.3)
  %.sroa.06.0.copyload.3.3 = load <2 x float>, ptr %4, align 4, !tbaa !5
  %114 = tail call noundef float @_Z8vec2_dot4Vec2S_(<2 x float> %.sroa.011.0.copyload.3, <2 x float> %.sroa.06.0.copyload.3.3)
  %.sroa.0.0.copyload.3126 = load <2 x float>, ptr %1, align 4, !tbaa !5
  %115 = tail call noundef float @_Z8vec2_dot4Vec2S_(<2 x float> %.sroa.011.0.copyload.3, <2 x float> %.sroa.0.0.copyload.3126)
  %.sroa.0.0.copyload.1.3 = load <2 x float>, ptr %5, align 4, !tbaa !5
  %116 = tail call noundef float @_Z8vec2_dot4Vec2S_(<2 x float> %.sroa.011.0.copyload.3, <2 x float> %.sroa.0.0.copyload.1.3)
  %.sroa.0.0.copyload.2.3 = load <2 x float>, ptr %6, align 4, !tbaa !5
  %117 = tail call noundef float @_Z8vec2_dot4Vec2S_(<2 x float> %.sroa.011.0.copyload.3, <2 x float> %.sroa.0.0.copyload.2.3)
  %.sroa.0.0.copyload.3.3 = load <2 x float>, ptr %7, align 4, !tbaa !5
  %118 = tail call noundef float @_Z8vec2_dot4Vec2S_(<2 x float> %.sroa.011.0.copyload.3, <2 x float> %.sroa.0.0.copyload.3.3)
  %119 = insertelement <2 x float> poison, float %115, i64 0
  %120 = insertelement <2 x float> %119, float %111, i64 1
  %121 = insertelement <2 x float> poison, float %116, i64 0
  %122 = insertelement <2 x float> %121, float %112, i64 1
  %123 = fcmp olt <2 x float> %120, %122
  %124 = select <2 x i1> %123, <2 x float> %120, <2 x float> %122
  %125 = shufflevector <2 x float> %124, <2 x float> poison, <2 x i32> <i32 1, i32 0>
  %126 = fcmp ogt <2 x float> %120, %122
  %127 = select <2 x i1> %126, <2 x float> %120, <2 x float> %122
  %128 = insertelement <2 x float> poison, float %113, i64 0
  %129 = insertelement <2 x float> %128, float %117, i64 1
  %130 = fcmp olt <2 x float> %125, %129
  %131 = select <2 x i1> %130, <2 x float> %125, <2 x float> %129
  %132 = shufflevector <2 x float> %129, <2 x float> poison, <2 x i32> <i32 1, i32 0>
  %133 = fcmp ogt <2 x float> %127, %132
  %134 = select <2 x i1> %133, <2 x float> %127, <2 x float> %132
  %135 = insertelement <2 x float> poison, float %114, i64 0
  %136 = insertelement <2 x float> %135, float %118, i64 1
  %137 = fcmp olt <2 x float> %131, %136
  %138 = shufflevector <2 x float> %136, <2 x float> poison, <2 x i32> <i32 1, i32 0>
  %139 = fcmp ogt <2 x float> %134, %138
  %140 = select <2 x i1> %137, <2 x float> %131, <2 x float> %136
  %141 = select <2 x i1> %139, <2 x float> %134, <2 x float> %138
  %142 = fcmp ult <2 x float> %141, %140
  %shift.3 = shufflevector <2 x i1> %142, <2 x i1> poison, <2 x i32> <i32 1, i32 poison>
  %143 = or <2 x i1> %142, %shift.3
  %or.cond.3 = extractelement <2 x i1> %143, i64 0
  br i1 %or.cond.3, label %.critedge65, label %.critedge63

.critedge63:                                      ; preds = %.preheader.3
  %144 = getelementptr inbounds i8, ptr %0, i64 8
  %145 = getelementptr inbounds i8, ptr %0, i64 16
  %146 = getelementptr inbounds i8, ptr %0, i64 24
  %147 = getelementptr inbounds i8, ptr %1, i64 8
  %148 = getelementptr inbounds i8, ptr %1, i64 16
  %149 = getelementptr inbounds i8, ptr %1, i64 24
  %150 = getelementptr inbounds i8, ptr %1, i64 32
  br label %.preheader.1

.preheader.1:                                     ; preds = %.preheader.1, %.critedge63
  %indvars.iv.1 = phi i64 [ 0, %.critedge63 ], [ %indvars.iv.next.1, %.preheader.1 ]
  %151 = getelementptr inbounds [4 x %union.Vec2], ptr %150, i64 0, i64 %indvars.iv.1
  %.sroa.011.0.copyload.1 = load <2 x float>, ptr %151, align 4, !tbaa !5
  %.sroa.06.0.copyload.189 = load <2 x float>, ptr %1, align 4, !tbaa !5
  %152 = tail call noundef float @_Z8vec2_dot4Vec2S_(<2 x float> %.sroa.011.0.copyload.1, <2 x float> %.sroa.06.0.copyload.189)
  %.sroa.06.0.copyload.1.1 = load <2 x float>, ptr %147, align 4, !tbaa !5
  %153 = tail call noundef float @_Z8vec2_dot4Vec2S_(<2 x float> %.sroa.011.0.copyload.1, <2 x float> %.sroa.06.0.copyload.1.1)
  %.sroa.06.0.copyload.2.1 = load <2 x float>, ptr %148, align 4, !tbaa !5
  %154 = tail call noundef float @_Z8vec2_dot4Vec2S_(<2 x float> %.sroa.011.0.copyload.1, <2 x float> %.sroa.06.0.copyload.2.1)
  %.sroa.06.0.copyload.3.1 = load <2 x float>, ptr %149, align 4, !tbaa !5
  %155 = tail call noundef float @_Z8vec2_dot4Vec2S_(<2 x float> %.sroa.011.0.copyload.1, <2 x float> %.sroa.06.0.copyload.3.1)
  %.sroa.0.0.copyload.190 = load <2 x float>, ptr %0, align 4, !tbaa !5
  %156 = tail call noundef float @_Z8vec2_dot4Vec2S_(<2 x float> %.sroa.011.0.copyload.1, <2 x float> %.sroa.0.0.copyload.190)
  %.sroa.0.0.copyload.1.1 = load <2 x float>, ptr %144, align 4, !tbaa !5
  %157 = tail call noundef float @_Z8vec2_dot4Vec2S_(<2 x float> %.sroa.011.0.copyload.1, <2 x float> %.sroa.0.0.copyload.1.1)
  %.sroa.0.0.copyload.2.1 = load <2 x float>, ptr %145, align 4, !tbaa !5
  %158 = tail call noundef float @_Z8vec2_dot4Vec2S_(<2 x float> %.sroa.011.0.copyload.1, <2 x float> %.sroa.0.0.copyload.2.1)
  %.sroa.0.0.copyload.3.1 = load <2 x float>, ptr %146, align 4, !tbaa !5
  %159 = tail call noundef float @_Z8vec2_dot4Vec2S_(<2 x float> %.sroa.011.0.copyload.1, <2 x float> %.sroa.0.0.copyload.3.1)
  %160 = insertelement <2 x float> poison, float %156, i64 0
  %161 = insertelement <2 x float> %160, float %152, i64 1
  %162 = insertelement <2 x float> poison, float %157, i64 0
  %163 = insertelement <2 x float> %162, float %153, i64 1
  %164 = fcmp olt <2 x float> %161, %163
  %165 = select <2 x i1> %164, <2 x float> %161, <2 x float> %163
  %166 = shufflevector <2 x float> %165, <2 x float> poison, <2 x i32> <i32 1, i32 0>
  %167 = fcmp ogt <2 x float> %161, %163
  %168 = select <2 x i1> %167, <2 x float> %161, <2 x float> %163
  %169 = insertelement <2 x float> poison, float %154, i64 0
  %170 = insertelement <2 x float> %169, float %158, i64 1
  %171 = fcmp olt <2 x float> %166, %170
  %172 = select <2 x i1> %171, <2 x float> %166, <2 x float> %170
  %173 = shufflevector <2 x float> %170, <2 x float> poison, <2 x i32> <i32 1, i32 0>
  %174 = fcmp ogt <2 x float> %168, %173
  %175 = select <2 x i1> %174, <2 x float> %168, <2 x float> %173
  %176 = insertelement <2 x float> poison, float %155, i64 0
  %177 = insertelement <2 x float> %176, float %159, i64 1
  %178 = fcmp olt <2 x float> %172, %177
  %179 = shufflevector <2 x float> %177, <2 x float> poison, <2 x i32> <i32 1, i32 0>
  %180 = fcmp ogt <2 x float> %175, %179
  %181 = select <2 x i1> %178, <2 x float> %172, <2 x float> %177
  %182 = select <2 x i1> %180, <2 x float> %175, <2 x float> %179
  %183 = fcmp oge <2 x float> %182, %181
  %shift108 = shufflevector <2 x i1> %183, <2 x i1> poison, <2 x i32> <i32 1, i32 poison>
  %184 = and <2 x i1> %183, %shift108
  %or.cond.1.not = extractelement <2 x i1> %184, i64 0
  %indvars.iv.next.1 = add nuw nsw i64 %indvars.iv.1, 1
  %exitcond.1 = icmp ne i64 %indvars.iv.next.1, 4
  %or.cond107.not = select i1 %or.cond.1.not, i1 %exitcond.1, i1 false
  br i1 %or.cond107.not, label %.preheader.1, label %.critedge65, !llvm.loop !8

.critedge65:                                      ; preds = %.preheader66, %.preheader.1120, %.preheader.2, %.preheader.3, %.preheader.1
  %185 = phi i1 [ %or.cond.1.not, %.preheader.1 ], [ false, %.preheader.3 ], [ false, %.preheader.2 ], [ false, %.preheader.1120 ], [ false, %.preheader66 ]
  ret i1 %185
}

attributes #0 = { mustprogress nounwind uwtable "min-legal-vector-width"="64" "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" }

!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 = !{!"omnipotent char", !7, i64 0}
!7 = !{!"Simple C++ TBAA"}
!8 = distinct !{!8, !9}
!9 = !{!"llvm.loop.mustprogress"}


; Effective O3 passes: EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,JumpThreadingPass,LCSSAPass,LICMPass,LoopInstSimplifyPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,PostOrderFunctionAttrsPass,SLPVectorizerPass,SROAPass,SimplifyCFGPass,TailCallElimPass,VectorCombinePass