; LLVM IR from ravireddy07/cpp-book :: src/Knapsack/FractionalKnapsack_1.ll (Z14Fract_KnapsackiiPiS_)

; 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_ostream" = type { ptr, %"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 }
%"struct.std::_Setprecision" = type { i32 }

@_ZSt4cout = external global %"class.std::basic_ostream", align 8

; Function Attrs: mustprogress uwtable
define dso_local void @_Z14Fract_KnapsackiiPiS_(i32 noundef %0, i32 noundef %1, ptr noundef %2, ptr noundef %3) #0 {
  %5 = alloca i32, align 4
  %6 = alloca i32, align 4
  %7 = alloca ptr, align 8
  %8 = alloca ptr, align 8
  %9 = alloca i32, align 4
  %10 = alloca i32, align 4
  %11 = alloca [10 x i32], align 16
  %12 = alloca float, align 4
  %13 = alloca i32, align 4
  %14 = alloca i32, align 4
  %15 = alloca %"struct.std::_Setprecision", align 4
  store i32 %0, ptr %5, align 4, !tbaa !5
  store i32 %1, ptr %6, align 4, !tbaa !5
  store ptr %2, ptr %7, align 8, !tbaa !9
  store ptr %3, ptr %8, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #5
  call void @llvm.lifetime.start.p0(i64 40, ptr %11) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #5
  store i32 0, ptr %13, align 4, !tbaa !5
  br label %16

16:                                               ; preds = %25, %4
  %17 = load i32, ptr %13, align 4, !tbaa !5
  %18 = load i32, ptr %5, align 4, !tbaa !5
  %19 = icmp slt i32 %17, %18
  br i1 %19, label %21, label %20

20:                                               ; preds = %16
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #5
  br label %28

21:                                               ; preds = %16
  %22 = load i32, ptr %13, align 4, !tbaa !5
  %23 = sext i32 %22 to i64
  %24 = getelementptr inbounds [10 x i32], ptr %11, i64 0, i64 %23
  store i32 0, ptr %24, align 4, !tbaa !5
  br label %25

25:                                               ; preds = %21
  %26 = load i32, ptr %13, align 4, !tbaa !5
  %27 = add nsw i32 %26, 1
  store i32 %27, ptr %13, align 4, !tbaa !5
  br label %16, !llvm.loop !11

28:                                               ; preds = %20
  %29 = load i32, ptr %6, align 4, !tbaa !5
  store i32 %29, ptr %9, align 4, !tbaa !5
  br label %30

30:                                               ; preds = %130, %28
  %31 = load i32, ptr %9, align 4, !tbaa !5
  %32 = icmp sgt i32 %31, 0
  br i1 %32, label %33, label %131

33:                                               ; preds = %30
  store i32 -1, ptr %10, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %14) #5
  store i32 0, ptr %14, align 4, !tbaa !5
  br label %34

34:                                               ; preds = %79, %33
  %35 = load i32, ptr %14, align 4, !tbaa !5
  %36 = load i32, ptr %5, align 4, !tbaa !5
  %37 = icmp slt i32 %35, %36
  br i1 %37, label %39, label %38

38:                                               ; preds = %34
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #5
  br label %82

39:                                               ; preds = %34
  %40 = load i32, ptr %14, align 4, !tbaa !5
  %41 = sext i32 %40 to i64
  %42 = getelementptr inbounds [10 x i32], ptr %11, i64 0, i64 %41
  %43 = load i32, ptr %42, align 4, !tbaa !5
  %44 = icmp eq i32 %43, 0
  br i1 %44, label %45, label %78

45:                                               ; preds = %39
  %46 = load i32, ptr %10, align 4, !tbaa !5
  %47 = icmp eq i32 %46, -1
  br i1 %47, label %76, label %48

48:                                               ; preds = %45
  %49 = load ptr, ptr %8, align 8, !tbaa !9
  %50 = load i32, ptr %14, align 4, !tbaa !5
  %51 = sext i32 %50 to i64
  %52 = getelementptr inbounds i32, ptr %49, i64 %51
  %53 = load i32, ptr %52, align 4, !tbaa !5
  %54 = sitofp i32 %53 to float
  %55 = load ptr, ptr %7, align 8, !tbaa !9
  %56 = load i32, ptr %14, align 4, !tbaa !5
  %57 = sext i32 %56 to i64
  %58 = getelementptr inbounds i32, ptr %55, i64 %57
  %59 = load i32, ptr %58, align 4, !tbaa !5
  %60 = sitofp i32 %59 to float
  %61 = fdiv float %54, %60
  %62 = load ptr, ptr %8, align 8, !tbaa !9
  %63 = load i32, ptr %10, align 4, !tbaa !5
  %64 = sext i32 %63 to i64
  %65 = getelementptr inbounds i32, ptr %62, i64 %64
  %66 = load i32, ptr %65, align 4, !tbaa !5
  %67 = sitofp i32 %66 to float
  %68 = load ptr, ptr %7, align 8, !tbaa !9
  %69 = load i32, ptr %10, align 4, !tbaa !5
  %70 = sext i32 %69 to i64
  %71 = getelementptr inbounds i32, ptr %68, i64 %70
  %72 = load i32, ptr %71, align 4, !tbaa !5
  %73 = sitofp i32 %72 to float
  %74 = fdiv float %67, %73
  %75 = fcmp ogt float %61, %74
  br i1 %75, label %76, label %78

76:                                               ; preds = %48, %45
  %77 = load i32, ptr %14, align 4, !tbaa !5
  store i32 %77, ptr %10, align 4, !tbaa !5
  br label %78

78:                                               ; preds = %76, %48, %39
  br label %79

79:                                               ; preds = %78
  %80 = load i32, ptr %14, align 4, !tbaa !5
  %81 = add nsw i32 %80, 1
  store i32 %81, ptr %14, align 4, !tbaa !5
  br label %34, !llvm.loop !13

82:                                               ; preds = %38
  %83 = load i32, ptr %10, align 4, !tbaa !5
  %84 = sext i32 %83 to i64
  %85 = getelementptr inbounds [10 x i32], ptr %11, i64 0, i64 %84
  store i32 1, ptr %85, align 4, !tbaa !5
  %86 = load ptr, ptr %7, align 8, !tbaa !9
  %87 = load i32, ptr %10, align 4, !tbaa !5
  %88 = sext i32 %87 to i64
  %89 = getelementptr inbounds i32, ptr %86, i64 %88
  %90 = load i32, ptr %89, align 4, !tbaa !5
  %91 = load i32, ptr %9, align 4, !tbaa !5
  %92 = sub nsw i32 %91, %90
  store i32 %92, ptr %9, align 4, !tbaa !5
  %93 = load ptr, ptr %8, align 8, !tbaa !9
  %94 = load i32, ptr %10, align 4, !tbaa !5
  %95 = sext i32 %94 to i64
  %96 = getelementptr inbounds i32, ptr %93, i64 %95
  %97 = load i32, ptr %96, align 4, !tbaa !5
  %98 = sitofp i32 %97 to float
  %99 = load float, ptr %12, align 4, !tbaa !14
  %100 = fadd float %99, %98
  store float %100, ptr %12, align 4, !tbaa !14
  %101 = load i32, ptr %9, align 4, !tbaa !5
  %102 = icmp sle i32 %101, 0
  br i1 %102, label %103, label %130

103:                                              ; preds = %82
  %104 = load ptr, ptr %8, align 8, !tbaa !9
  %105 = load i32, ptr %10, align 4, !tbaa !5
  %106 = sext i32 %105 to i64
  %107 = getelementptr inbounds i32, ptr %104, i64 %106
  %108 = load i32, ptr %107, align 4, !tbaa !5
  %109 = sitofp i32 %108 to float
  %110 = load float, ptr %12, align 4, !tbaa !14
  %111 = fsub float %110, %109
  store float %111, ptr %12, align 4, !tbaa !14
  %112 = load i32, ptr %9, align 4, !tbaa !5
  %113 = sitofp i32 %112 to float
  %114 = load ptr, ptr %7, align 8, !tbaa !9
  %115 = load i32, ptr %10, align 4, !tbaa !5
  %116 = sext i32 %115 to i64
  %117 = getelementptr inbounds i32, ptr %114, i64 %116
  %118 = load i32, ptr %117, align 4, !tbaa !5
  %119 = sitofp i32 %118 to float
  %120 = fdiv float %113, %119
  %121 = fadd float 1.000000e+00, %120
  %122 = load ptr, ptr %8, align 8, !tbaa !9
  %123 = load i32, ptr %10, align 4, !tbaa !5
  %124 = sext i32 %123 to i64
  %125 = getelementptr inbounds i32, ptr %122, i64 %124
  %126 = load i32, ptr %125, align 4, !tbaa !5
  %127 = sitofp i32 %126 to float
  %128 = load float, ptr %12, align 4, !tbaa !14
  %129 = call float @llvm.fmuladd.f32(float %121, float %127, float %128)
  store float %129, ptr %12, align 4, !tbaa !14
  br label %130

130:                                              ; preds = %103, %82
  br label %30, !llvm.loop !16

131:                                              ; preds = %30
  %132 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSt8ios_baseS0_E(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, ptr noundef @_ZSt5fixedRSt8ios_base)
  %133 = call i32 @_ZSt12setprecisioni(i32 noundef 1)
  %134 = getelementptr inbounds %"struct.std::_Setprecision", ptr %15, i32 0, i32 0
  store i32 %133, ptr %134, align 4
  %135 = getelementptr inbounds %"struct.std::_Setprecision", ptr %15, i32 0, i32 0
  %136 = load i32, ptr %135, align 4
  %137 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_St13_Setprecision(ptr noundef nonnull align 8 dereferenceable(8) %132, i32 %136)
  %138 = load float, ptr %12, align 4, !tbaa !14
  %139 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEf(ptr noundef nonnull align 8 dereferenceable(8) %137, float noundef %138)
  %140 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSoS_E(ptr noundef nonnull align 8 dereferenceable(8) %139, ptr noundef @_ZSt4endlIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_)
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #5
  call void @llvm.lifetime.end.p0(i64 40, ptr %11) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #5
  ret void
}

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

; 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 float @llvm.fmuladd.f32(float, float, float) #2

; Function Attrs: inlinehint mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_St13_Setprecision(ptr noundef nonnull align 8 dereferenceable(8), i32) #3

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

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef nonnull align 8 dereferenceable(216) ptr @_ZSt5fixedRSt8ios_base(ptr noundef nonnull align 8 dereferenceable(216)) #3

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local i32 @_ZSt12setprecisioni(i32 noundef) #4

; Function Attrs: mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEf(ptr noundef nonnull align 8 dereferenceable(8), float noundef) #0 align 2

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

; Function Attrs: inlinehint mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZSt4endlIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_(ptr noundef nonnull align 8 dereferenceable(8)) #3

attributes #0 = { 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 #1 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #3 = { 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 #4 = { inlinehint mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #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 = !{!"any pointer", !7, i64 0}
!11 = distinct !{!11, !12}
!12 = !{!"llvm.loop.mustprogress"}
!13 = distinct !{!13, !12}
!14 = !{!15, !15, i64 0}
!15 = !{!"float", !7, i64 0}
!16 = distinct !{!16, !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_ostream" = type { ptr, %"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 }

@_ZSt4cout = external global %"class.std::basic_ostream", align 8

; Function Attrs: mustprogress uwtable
define dso_local void @_Z14Fract_KnapsackiiPiS_(i32 noundef %0, i32 noundef %1, ptr nocapture noundef readonly %2, ptr nocapture noundef readonly %3) local_unnamed_addr #0 {
  %5 = alloca [10 x i32], align 16
  call void @llvm.lifetime.start.p0(i64 40, ptr nonnull %5) #6
  %6 = icmp sgt i32 %0, 0
  br i1 %6, label %.preheader44, label %.preheader44.thread

.preheader44:                                     ; preds = %4
  %7 = zext nneg i32 %0 to i64
  %8 = shl nuw nsw i64 %7, 2
  call void @llvm.memset.p0.i64(ptr nonnull align 16 %5, i8 0, i64 %8, i1 false), !tbaa !5
  %9 = icmp sgt i32 %1, 0
  br i1 %9, label %.preheader.us.preheader, label %._crit_edge51

.preheader44.thread:                              ; preds = %4
  %10 = icmp sgt i32 %1, 0
  br i1 %10, label %.preheader.lr.ph.split, label %._crit_edge51

.preheader.us.preheader:                          ; preds = %.preheader44
  %wide.trip.count = zext nneg i32 %0 to i64
  br label %.preheader.us

.preheader.us:                                    ; preds = %._crit_edge.us, %.preheader.us.preheader
  %.050.us = phi i32 [ %1, %.preheader.us.preheader ], [ %44, %._crit_edge.us ]
  %.03949.us = phi float [ undef, %.preheader.us.preheader ], [ %48, %._crit_edge.us ]
  br label %11

11:                                               ; preds = %.preheader.us, %39
  %indvars.iv = phi i64 [ 0, %.preheader.us ], [ %indvars.iv.next, %39 ]
  %.04046.us = phi i32 [ -1, %.preheader.us ], [ %.141.us, %39 ]
  %12 = getelementptr inbounds [10 x i32], ptr %5, i64 0, i64 %indvars.iv
  %13 = load i32, ptr %12, align 4, !tbaa !5
  %14 = icmp eq i32 %13, 0
  br i1 %14, label %15, label %39

15:                                               ; preds = %11
  %16 = icmp eq i32 %.04046.us, -1
  br i1 %16, label %37, label %17

17:                                               ; preds = %15
  %18 = getelementptr inbounds i32, ptr %3, i64 %indvars.iv
  %19 = load i32, ptr %18, align 4, !tbaa !5
  %20 = getelementptr inbounds i32, ptr %2, i64 %indvars.iv
  %21 = load i32, ptr %20, align 4, !tbaa !5
  %22 = sext i32 %.04046.us to i64
  %23 = getelementptr inbounds i32, ptr %3, i64 %22
  %24 = load i32, ptr %23, align 4, !tbaa !5
  %25 = getelementptr inbounds i32, ptr %2, i64 %22
  %26 = load i32, ptr %25, align 4, !tbaa !5
  %27 = insertelement <2 x i32> poison, i32 %19, i64 0
  %28 = insertelement <2 x i32> %27, i32 %24, i64 1
  %29 = sitofp <2 x i32> %28 to <2 x float>
  %30 = insertelement <2 x i32> poison, i32 %21, i64 0
  %31 = insertelement <2 x i32> %30, i32 %26, i64 1
  %32 = sitofp <2 x i32> %31 to <2 x float>
  %33 = fdiv <2 x float> %29, %32
  %34 = extractelement <2 x float> %33, i64 0
  %35 = extractelement <2 x float> %33, i64 1
  %36 = fcmp ogt float %34, %35
  br i1 %36, label %37, label %39

37:                                               ; preds = %17, %15
  %38 = trunc nuw nsw i64 %indvars.iv to i32
  br label %39

39:                                               ; preds = %37, %17, %11
  %.141.us = phi i32 [ %38, %37 ], [ %.04046.us, %17 ], [ %.04046.us, %11 ]
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %exitcond.not = icmp eq i64 %indvars.iv.next, %wide.trip.count
  br i1 %exitcond.not, label %._crit_edge.us, label %11, !llvm.loop !9

._crit_edge.us:                                   ; preds = %39
  %40 = sext i32 %.141.us to i64
  %41 = getelementptr inbounds [10 x i32], ptr %5, i64 0, i64 %40
  store i32 1, ptr %41, align 4, !tbaa !5
  %42 = getelementptr inbounds i32, ptr %2, i64 %40
  %43 = load i32, ptr %42, align 4, !tbaa !5
  %44 = sub nsw i32 %.050.us, %43
  %45 = getelementptr inbounds i32, ptr %3, i64 %40
  %46 = load i32, ptr %45, align 4, !tbaa !5
  %47 = sitofp i32 %46 to float
  %48 = fadd float %.03949.us, %47
  %49 = icmp slt i32 %44, 1
  br i1 %49, label %._crit_edge51.loopexit, label %.preheader.us, !llvm.loop !11

.preheader.lr.ph.split:                           ; preds = %.preheader44.thread
  %50 = getelementptr inbounds i8, ptr %2, i64 -4
  %51 = load i32, ptr %50, align 4, !tbaa !5
  %52 = getelementptr inbounds i8, ptr %3, i64 -4
  %53 = load i32, ptr %52, align 4, !tbaa !5
  %54 = sitofp i32 %53 to float
  %55 = sitofp i32 %51 to float
  br label %.preheader

.preheader:                                       ; preds = %.preheader, %.preheader.lr.ph.split
  %.050 = phi i32 [ %1, %.preheader.lr.ph.split ], [ %56, %.preheader ]
  %.03949 = phi float [ undef, %.preheader.lr.ph.split ], [ %57, %.preheader ]
  %56 = sub nsw i32 %.050, %51
  %57 = fadd float %.03949, %54
  %58 = icmp slt i32 %56, 1
  br i1 %58, label %._crit_edge51.loopexit53, label %.preheader, !llvm.loop !11

._crit_edge51.loopexit:                           ; preds = %._crit_edge.us
  %59 = fsub float %48, %47
  %60 = sitofp i32 %44 to float
  %61 = sitofp i32 %43 to float
  %62 = fdiv float %60, %61
  %63 = fadd float %62, 1.000000e+00
  %64 = tail call float @llvm.fmuladd.f32(float %63, float %47, float %59)
  br label %._crit_edge51

._crit_edge51.loopexit53:                         ; preds = %.preheader
  %65 = fsub float %57, %54
  %66 = sitofp i32 %56 to float
  %67 = fdiv float %66, %55
  %68 = fadd float %67, 1.000000e+00
  %69 = tail call float @llvm.fmuladd.f32(float %68, float %54, float %65)
  br label %._crit_edge51

._crit_edge51:                                    ; preds = %.preheader44.thread, %._crit_edge51.loopexit53, %._crit_edge51.loopexit, %.preheader44
  %.039.lcssa = phi float [ undef, %.preheader44 ], [ %64, %._crit_edge51.loopexit ], [ %69, %._crit_edge51.loopexit53 ], [ undef, %.preheader44.thread ]
  %70 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSt8ios_baseS0_E(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, ptr noundef nonnull @_ZSt5fixedRSt8ios_base)
  %71 = tail call i32 @_ZSt12setprecisioni(i32 noundef 1)
  %72 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_St13_Setprecision(ptr noundef nonnull align 8 dereferenceable(8) %70, i32 %71)
  %73 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEf(ptr noundef nonnull align 8 dereferenceable(8) %72, float noundef %.039.lcssa)
  %74 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSoS_E(ptr noundef nonnull align 8 dereferenceable(8) %73, ptr noundef nonnull @_ZSt4endlIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_)
  call void @llvm.lifetime.end.p0(i64 40, ptr nonnull %5) #6
  ret void
}

; 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 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 float @llvm.fmuladd.f32(float, float, float) #2

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

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

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef nonnull align 8 dereferenceable(216) ptr @_ZSt5fixedRSt8ios_base(ptr noundef nonnull align 8 dereferenceable(216)) #3

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local i32 @_ZSt12setprecisioni(i32 noundef) local_unnamed_addr #4

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

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

; Function Attrs: inlinehint mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZSt4endlIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_(ptr noundef nonnull align 8 dereferenceable(8)) #3

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: write)
declare void @llvm.memset.p0.i64(ptr nocapture writeonly, i8, i64, i1 immarg) #5

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


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