; LLVM IR from AnneLivia/Competitive-Programming :: Online Judges/URI/1045 (main)

; 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::basic_istream" = type { ptr, i64, %"class.std::basic_ios" }
%"class.std::basic_ios" = type { %"class.std::ios_base", ptr, i8, i8, ptr, ptr, ptr, ptr }
%"class.std::ios_base" = type { ptr, i64, i64, i32, i32, i32, ptr, %"struct.std::ios_base::_Words", [8 x %"struct.std::ios_base::_Words"], i32, ptr, %"class.std::locale" }
%"struct.std::ios_base::_Words" = type { ptr, i64 }
%"class.std::locale" = type { ptr }
%"class.std::basic_ostream" = type { ptr, %"class.std::basic_ios" }

@_ZSt3cin = external global %"class.std::basic_istream", align 8
@_ZSt4cout = external global %"class.std::basic_ostream", align 8
@.str = external hidden unnamed_addr constant [21 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [23 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [22 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [22 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [21 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [21 x i8], align 1

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() #0 {
  %1 = alloca i32, align 4
  %2 = alloca [3 x double], align 16
  %3 = alloca i32, align 4
  %4 = alloca i32, align 4
  %5 = alloca i32, align 4
  %6 = alloca i32, align 4
  store i32 0, ptr %1, align 4
  call void @llvm.lifetime.start.p0(i64 24, ptr %2) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr %3) #5
  %7 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 0
  %8 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERd(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 8 dereferenceable(8) %7)
  %9 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 1
  %10 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERd(ptr noundef nonnull align 8 dereferenceable(16) %8, ptr noundef nonnull align 8 dereferenceable(8) %9)
  %11 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 2
  %12 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERd(ptr noundef nonnull align 8 dereferenceable(16) %10, ptr noundef nonnull align 8 dereferenceable(8) %11)
  call void @llvm.lifetime.start.p0(i64 4, ptr %4) #5
  store i32 0, ptr %4, align 4, !tbaa !5
  br label %13

13:                                               ; preds = %55, %0
  %14 = load i32, ptr %4, align 4, !tbaa !5
  %15 = icmp slt i32 %14, 2
  br i1 %15, label %17, label %16

16:                                               ; preds = %13
  store i32 2, ptr %5, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %4) #5
  br label %58

17:                                               ; preds = %13
  call void @llvm.lifetime.start.p0(i64 4, ptr %6) #5
  store i32 1, ptr %6, align 4, !tbaa !5
  br label %18

18:                                               ; preds = %51, %17
  %19 = load i32, ptr %6, align 4, !tbaa !5
  %20 = icmp slt i32 %19, 3
  br i1 %20, label %22, label %21

21:                                               ; preds = %18
  store i32 5, ptr %5, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %6) #5
  br label %54

22:                                               ; preds = %18
  %23 = load i32, ptr %4, align 4, !tbaa !5
  %24 = sext i32 %23 to i64
  %25 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 %24
  %26 = load double, ptr %25, align 8, !tbaa !9
  %27 = load i32, ptr %6, align 4, !tbaa !5
  %28 = sext i32 %27 to i64
  %29 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 %28
  %30 = load double, ptr %29, align 8, !tbaa !9
  %31 = fcmp olt double %26, %30
  br i1 %31, label %32, label %50

32:                                               ; preds = %22
  %33 = load i32, ptr %4, align 4, !tbaa !5
  %34 = sext i32 %33 to i64
  %35 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 %34
  %36 = load double, ptr %35, align 8, !tbaa !9
  %37 = fptosi double %36 to i32
  store i32 %37, ptr %3, align 4, !tbaa !5
  %38 = load i32, ptr %6, align 4, !tbaa !5
  %39 = sext i32 %38 to i64
  %40 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 %39
  %41 = load double, ptr %40, align 8, !tbaa !9
  %42 = load i32, ptr %4, align 4, !tbaa !5
  %43 = sext i32 %42 to i64
  %44 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 %43
  store double %41, ptr %44, align 8, !tbaa !9
  %45 = load i32, ptr %3, align 4, !tbaa !5
  %46 = sitofp i32 %45 to double
  %47 = load i32, ptr %6, align 4, !tbaa !5
  %48 = sext i32 %47 to i64
  %49 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 %48
  store double %46, ptr %49, align 8, !tbaa !9
  br label %50

50:                                               ; preds = %32, %22
  br label %51

51:                                               ; preds = %50
  %52 = load i32, ptr %6, align 4, !tbaa !5
  %53 = add nsw i32 %52, 1
  store i32 %53, ptr %6, align 4, !tbaa !5
  br label %18, !llvm.loop !11

54:                                               ; preds = %21
  br label %55

55:                                               ; preds = %54
  %56 = load i32, ptr %4, align 4, !tbaa !5
  %57 = add nsw i32 %56, 1
  store i32 %57, ptr %4, align 4, !tbaa !5
  br label %13, !llvm.loop !13

58:                                               ; preds = %16
  %59 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 0
  %60 = load double, ptr %59, align 16, !tbaa !9
  %61 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 1
  %62 = load double, ptr %61, align 8, !tbaa !9
  %63 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 2
  %64 = load double, ptr %63, align 16, !tbaa !9
  %65 = fadd double %62, %64
  %66 = fcmp oge double %60, %65
  br i1 %66, label %177, label %67

67:                                               ; preds = %58
  %68 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 0
  %69 = load double, ptr %68, align 16, !tbaa !9
  %70 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 0
  %71 = load double, ptr %70, align 16, !tbaa !9
  %72 = fmul double %69, %71
  %73 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 1
  %74 = load double, ptr %73, align 8, !tbaa !9
  %75 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 1
  %76 = load double, ptr %75, align 8, !tbaa !9
  %77 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 2
  %78 = load double, ptr %77, align 16, !tbaa !9
  %79 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 2
  %80 = load double, ptr %79, align 16, !tbaa !9
  %81 = fmul double %78, %80
  %82 = call double @llvm.fmuladd.f64(double %74, double %76, double %81)
  %83 = fcmp oeq double %72, %82
  br i1 %83, label %84, label %86

84:                                               ; preds = %67
  %85 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, ptr noundef @.str)
  br label %86

86:                                               ; preds = %84, %67
  %87 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 0
  %88 = load double, ptr %87, align 16, !tbaa !9
  %89 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 0
  %90 = load double, ptr %89, align 16, !tbaa !9
  %91 = fmul double %88, %90
  %92 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 1
  %93 = load double, ptr %92, align 8, !tbaa !9
  %94 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 1
  %95 = load double, ptr %94, align 8, !tbaa !9
  %96 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 2
  %97 = load double, ptr %96, align 16, !tbaa !9
  %98 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 2
  %99 = load double, ptr %98, align 16, !tbaa !9
  %100 = fmul double %97, %99
  %101 = call double @llvm.fmuladd.f64(double %93, double %95, double %100)
  %102 = fcmp ogt double %91, %101
  br i1 %102, label %103, label %105

103:                                              ; preds = %86
  %104 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, ptr noundef @.str.1)
  br label %105

105:                                              ; preds = %103, %86
  %106 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 0
  %107 = load double, ptr %106, align 16, !tbaa !9
  %108 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 0
  %109 = load double, ptr %108, align 16, !tbaa !9
  %110 = fmul double %107, %109
  %111 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 1
  %112 = load double, ptr %111, align 8, !tbaa !9
  %113 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 1
  %114 = load double, ptr %113, align 8, !tbaa !9
  %115 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 2
  %116 = load double, ptr %115, align 16, !tbaa !9
  %117 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 2
  %118 = load double, ptr %117, align 16, !tbaa !9
  %119 = fmul double %116, %118
  %120 = call double @llvm.fmuladd.f64(double %112, double %114, double %119)
  %121 = fcmp olt double %110, %120
  br i1 %121, label %122, label %124

122:                                              ; preds = %105
  %123 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, ptr noundef @.str.2)
  br label %124

124:                                              ; preds = %122, %105
  %125 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 0
  %126 = load double, ptr %125, align 16, !tbaa !9
  %127 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 1
  %128 = load double, ptr %127, align 8, !tbaa !9
  %129 = fcmp oeq double %126, %128
  br i1 %129, label %130, label %138

130:                                              ; preds = %124
  %131 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 1
  %132 = load double, ptr %131, align 8, !tbaa !9
  %133 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 2
  %134 = load double, ptr %133, align 16, !tbaa !9
  %135 = fcmp oeq double %132, %134
  br i1 %135, label %136, label %138

136:                                              ; preds = %130
  %137 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, ptr noundef @.str.3)
  br label %138

138:                                              ; preds = %136, %130, %124
  %139 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 0
  %140 = load double, ptr %139, align 16, !tbaa !9
  %141 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 1
  %142 = load double, ptr %141, align 8, !tbaa !9
  %143 = fcmp oeq double %140, %142
  br i1 %143, label %144, label %150

144:                                              ; preds = %138
  %145 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 1
  %146 = load double, ptr %145, align 8, !tbaa !9
  %147 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 2
  %148 = load double, ptr %147, align 16, !tbaa !9
  %149 = fcmp une double %146, %148
  br i1 %149, label %174, label %150

150:                                              ; preds = %144, %138
  %151 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 0
  %152 = load double, ptr %151, align 16, !tbaa !9
  %153 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 2
  %154 = load double, ptr %153, align 16, !tbaa !9
  %155 = fcmp oeq double %152, %154
  br i1 %155, label %156, label %162

156:                                              ; preds = %150
  %157 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 2
  %158 = load double, ptr %157, align 16, !tbaa !9
  %159 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 1
  %160 = load double, ptr %159, align 8, !tbaa !9
  %161 = fcmp une double %158, %160
  br i1 %161, label %174, label %162

162:                                              ; preds = %156, %150
  %163 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 1
  %164 = load double, ptr %163, align 8, !tbaa !9
  %165 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 2
  %166 = load double, ptr %165, align 16, !tbaa !9
  %167 = fcmp oeq double %164, %166
  br i1 %167, label %168, label %176

168:                                              ; preds = %162
  %169 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 2
  %170 = load double, ptr %169, align 16, !tbaa !9
  %171 = getelementptr inbounds [3 x double], ptr %2, i64 0, i64 0
  %172 = load double, ptr %171, align 16, !tbaa !9
  %173 = fcmp une double %170, %172
  br i1 %173, label %174, label %176

174:                                              ; preds = %168, %156, %144
  %175 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, ptr noundef @.str.4)
  br label %176

176:                                              ; preds = %174, %168, %162
  br label %179

177:                                              ; preds = %58
  %178 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, ptr noundef @.str.5)
  br label %179

179:                                              ; preds = %177, %176
  store i32 0, ptr %1, align 4
  store i32 1, ptr %5, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %3) #5
  call void @llvm.lifetime.end.p0(i64 24, ptr %2) #5
  %180 = load i32, ptr %1, align 4
  ret i32 %180
}

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

; Function Attrs: mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERd(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 8 dereferenceable(8)) #2 align 2

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

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

; Function Attrs: inlinehint mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef) #4

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

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

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


; 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::basic_istream" = type { ptr, i64, %"class.std::basic_ios" }
%"class.std::basic_ios" = type { %"class.std::ios_base", ptr, i8, i8, ptr, ptr, ptr, ptr }
%"class.std::ios_base" = type { ptr, i64, i64, i32, i32, i32, ptr, %"struct.std::ios_base::_Words", [8 x %"struct.std::ios_base::_Words"], i32, ptr, %"class.std::locale" }
%"struct.std::ios_base::_Words" = type { ptr, i64 }
%"class.std::locale" = type { ptr }
%"class.std::basic_ostream" = type { ptr, %"class.std::basic_ios" }

@_ZSt3cin = external global %"class.std::basic_istream", align 8
@_ZSt4cout = external global %"class.std::basic_ostream", align 8
@.str = external hidden unnamed_addr constant [21 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [23 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [22 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [22 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [21 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [21 x i8], align 1

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() local_unnamed_addr #0 {
.preheader:
  %0 = alloca [3 x double], align 16
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %0) #5
  %1 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERd(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 8 dereferenceable(8) %0)
  %2 = getelementptr inbounds i8, ptr %0, i64 8
  %3 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERd(ptr noundef nonnull align 8 dereferenceable(16) %1, ptr noundef nonnull align 8 dereferenceable(8) %2)
  %4 = getelementptr inbounds i8, ptr %0, i64 16
  %5 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERd(ptr noundef nonnull align 8 dereferenceable(16) %3, ptr noundef nonnull align 8 dereferenceable(8) %4)
  %6 = load double, ptr %0, align 16
  %7 = load double, ptr %2, align 8
  %8 = fcmp olt double %6, %7
  br i1 %8, label %9, label %12

9:                                                ; preds = %.preheader
  %10 = fptosi double %6 to i32
  store double %7, ptr %0, align 16, !tbaa !5
  %11 = sitofp i32 %10 to double
  store double %11, ptr %2, align 8, !tbaa !5
  br label %12

12:                                               ; preds = %.preheader, %9
  %13 = phi double [ %7, %.preheader ], [ %11, %9 ]
  %14 = phi double [ %6, %.preheader ], [ %7, %9 ]
  %15 = load double, ptr %4, align 16
  %16 = fcmp olt double %14, %15
  br i1 %16, label %17, label %.preheader.1

17:                                               ; preds = %12
  %18 = fptosi double %14 to i32
  store double %15, ptr %0, align 16, !tbaa !5
  %19 = sitofp i32 %18 to double
  store double %19, ptr %4, align 16, !tbaa !5
  br label %.preheader.1

.preheader.1:                                     ; preds = %12, %17
  %20 = phi double [ %15, %17 ], [ %14, %12 ]
  %21 = phi double [ %19, %17 ], [ %15, %12 ]
  %22 = fcmp olt double %13, %21
  br i1 %22, label %23, label %26

23:                                               ; preds = %.preheader.1
  %24 = fptosi double %13 to i32
  store double %21, ptr %2, align 8, !tbaa !5
  %25 = sitofp i32 %24 to double
  store double %25, ptr %4, align 16, !tbaa !5
  br label %26

26:                                               ; preds = %23, %.preheader.1
  %27 = phi double [ %25, %23 ], [ %21, %.preheader.1 ]
  %28 = phi double [ %21, %23 ], [ %13, %.preheader.1 ]
  %29 = fadd double %28, %27
  %30 = fcmp ult double %20, %29
  br i1 %30, label %31, label %.sink.split

31:                                               ; preds = %26
  %32 = fmul double %20, %20
  %33 = fmul double %27, %27
  %34 = call double @llvm.fmuladd.f64(double %28, double %28, double %33)
  %35 = fcmp oeq double %32, %34
  br i1 %35, label %36, label %38

36:                                               ; preds = %31
  %37 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, ptr noundef nonnull @.str)
  %.pre = load double, ptr %0, align 16
  %.pre32 = load double, ptr %2, align 8
  %.pre33 = load double, ptr %4, align 16
  %.pre43 = fmul double %.pre, %.pre
  %.pre44 = fmul double %.pre33, %.pre33
  %.pre46 = call double @llvm.fmuladd.f64(double %.pre32, double %.pre32, double %.pre44)
  br label %38

38:                                               ; preds = %36, %31
  %.pre-phi47 = phi double [ %.pre46, %36 ], [ %34, %31 ]
  %.pre-phi = phi double [ %.pre43, %36 ], [ %32, %31 ]
  %39 = phi double [ %.pre33, %36 ], [ %27, %31 ]
  %40 = phi double [ %.pre32, %36 ], [ %28, %31 ]
  %41 = phi double [ %.pre, %36 ], [ %20, %31 ]
  %42 = fcmp ogt double %.pre-phi, %.pre-phi47
  br i1 %42, label %43, label %45

43:                                               ; preds = %38
  %44 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, ptr noundef nonnull @.str.1)
  %.pre34 = load double, ptr %0, align 16
  %.pre35 = load double, ptr %2, align 8
  %.pre36 = load double, ptr %4, align 16
  %.pre48 = fmul double %.pre34, %.pre34
  %.pre50 = fmul double %.pre36, %.pre36
  %.pre52 = call double @llvm.fmuladd.f64(double %.pre35, double %.pre35, double %.pre50)
  br label %45

45:                                               ; preds = %43, %38
  %.pre-phi53 = phi double [ %.pre52, %43 ], [ %.pre-phi47, %38 ]
  %.pre-phi49 = phi double [ %.pre48, %43 ], [ %.pre-phi, %38 ]
  %46 = phi double [ %.pre36, %43 ], [ %39, %38 ]
  %47 = phi double [ %.pre35, %43 ], [ %40, %38 ]
  %48 = phi double [ %.pre34, %43 ], [ %41, %38 ]
  %49 = fcmp olt double %.pre-phi49, %.pre-phi53
  br i1 %49, label %50, label %52

50:                                               ; preds = %45
  %51 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, ptr noundef nonnull @.str.2)
  %.pre37 = load double, ptr %0, align 16
  %.pre38 = load double, ptr %2, align 8
  %.pre39 = load double, ptr %4, align 16
  br label %52

52:                                               ; preds = %50, %45
  %53 = phi double [ %.pre39, %50 ], [ %46, %45 ]
  %54 = phi double [ %.pre38, %50 ], [ %47, %45 ]
  %55 = phi double [ %.pre37, %50 ], [ %48, %45 ]
  %56 = fcmp oeq double %55, %54
  %57 = fcmp oeq double %54, %53
  %or.cond = select i1 %56, i1 %57, i1 false
  br i1 %or.cond, label %58, label %60

58:                                               ; preds = %52
  %59 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, ptr noundef nonnull @.str.3)
  %.pre40 = load double, ptr %0, align 16
  %.pre41 = load double, ptr %2, align 8
  %.pre42 = load double, ptr %4, align 16
  br label %60

60:                                               ; preds = %58, %52
  %61 = phi double [ %.pre42, %58 ], [ %53, %52 ]
  %62 = phi double [ %.pre41, %58 ], [ %54, %52 ]
  %63 = phi double [ %.pre40, %58 ], [ %55, %52 ]
  %64 = fcmp oeq double %63, %62
  %65 = fcmp une double %62, %61
  %66 = fcmp oeq double %63, %61
  %67 = or i1 %64, %66
  %or.cond27 = and i1 %65, %67
  br i1 %or.cond27, label %.sink.split, label %68

68:                                               ; preds = %60
  %69 = fcmp oeq double %62, %61
  %70 = fcmp une double %61, %63
  %or.cond26 = and i1 %69, %70
  br i1 %or.cond26, label %.sink.split, label %72

.sink.split:                                      ; preds = %26, %60, %68
  %.str.4.sink = phi ptr [ @.str.4, %68 ], [ @.str.4, %60 ], [ @.str.5, %26 ]
  %71 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, ptr noundef nonnull %.str.4.sink)
  br label %72

72:                                               ; preds = %.sink.split, %68
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %0) #5
  ret i32 0
}

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

; Function Attrs: mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERd(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #2 align 2

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

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

; Function Attrs: inlinehint mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef) local_unnamed_addr #4

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


; Effective O3 passes: BDCEPass,EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferAlignmentPass,InferFunctionAttrsPass,InstCombinePass,JumpThreadingPass,LICMPass,LoopRotatePass,LoopSimplifyPass,SCCPPass,SROAPass,SimplifyCFGPass