; LLVM IR from 0r-gh0/NUMERICAL_ANALYSIS :: CODES (TRAPEZOIDAL)

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

@.str = external hidden unnamed_addr constant [16 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [58 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [45 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [9 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [39 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [37 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [8 x i8], align 1
@.str.8 = external hidden unnamed_addr constant [29 x i8], align 1
@.str.9 = external hidden unnamed_addr constant [14 x i8], align 1
@.str.10 = external hidden unnamed_addr constant [61 x i8], align 1
@.str.11 = external hidden unnamed_addr constant [62 x i8], align 1

; Function Attrs: nounwind uwtable
declare dso_local float @function(float noundef) #0

; Function Attrs: nounwind uwtable
define dso_local i32 @main() #0 {
  %1 = alloca i32, align 4
  %2 = alloca ptr, align 8
  %3 = alloca i32, align 4
  %4 = alloca i32, align 4
  %5 = alloca float, align 4
  %6 = alloca float, align 4
  %7 = alloca float, align 4
  %8 = alloca [20 x float], align 16
  %9 = alloca [20 x float], align 16
  %10 = alloca float, align 4
  %11 = alloca float, align 4
  store i32 0, ptr %1, align 4
  call void @llvm.lifetime.start.p0(i64 8, ptr %2) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr %3) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr %4) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr %5) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr %6) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #5
  call void @llvm.lifetime.start.p0(i64 80, ptr %8) #5
  call void @llvm.lifetime.start.p0(i64 80, ptr %9) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #5
  store float 0.000000e+00, ptr %10, align 4, !tbaa !5
  %12 = call noalias ptr @fopen(ptr noundef @.str, ptr noundef @.str.1)
  store ptr %12, ptr %2, align 8, !tbaa !9
  %13 = load ptr, ptr %2, align 8, !tbaa !9
  %14 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %13, ptr noundef @.str.2) #5
  %15 = call i32 (ptr, ...) @printf(ptr noundef @.str.3)
  %16 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str.4, ptr noundef %5, ptr noundef %6, ptr noundef %4)
  %17 = load float, ptr %6, align 4, !tbaa !5
  %18 = load float, ptr %5, align 4, !tbaa !5
  %19 = fsub float %17, %18
  %20 = load i32, ptr %4, align 4, !tbaa !11
  %21 = sitofp i32 %20 to float
  %22 = fdiv float %19, %21
  store float %22, ptr %7, align 4, !tbaa !5
  %23 = load i32, ptr %4, align 4, !tbaa !11
  %24 = load float, ptr %7, align 4, !tbaa !5
  %25 = fpext float %24 to double
  %26 = call i32 (ptr, ...) @printf(ptr noundef @.str.5, i32 noundef %23, double noundef %25)
  %27 = load ptr, ptr %2, align 8, !tbaa !9
  %28 = load float, ptr %5, align 4, !tbaa !5
  %29 = fpext float %28 to double
  %30 = load float, ptr %6, align 4, !tbaa !5
  %31 = fpext float %30 to double
  %32 = load i32, ptr %4, align 4, !tbaa !11
  %33 = load float, ptr %7, align 4, !tbaa !5
  %34 = fpext float %33 to double
  %35 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %27, ptr noundef @.str.6, double noundef %29, double noundef %31, i32 noundef %32, double noundef %34) #5
  store i32 0, ptr %3, align 4, !tbaa !11
  br label %36

36:                                               ; preds = %84, %0
  %37 = load i32, ptr %3, align 4, !tbaa !11
  %38 = load i32, ptr %4, align 4, !tbaa !11
  %39 = icmp sle i32 %37, %38
  br i1 %39, label %40, label %87

40:                                               ; preds = %36
  %41 = load float, ptr %5, align 4, !tbaa !5
  %42 = load i32, ptr %3, align 4, !tbaa !11
  %43 = sitofp i32 %42 to float
  %44 = load float, ptr %7, align 4, !tbaa !5
  %45 = call float @llvm.fmuladd.f32(float %43, float %44, float %41)
  %46 = load i32, ptr %3, align 4, !tbaa !11
  %47 = sext i32 %46 to i64
  %48 = getelementptr inbounds [20 x float], ptr %9, i64 0, i64 %47
  store float %45, ptr %48, align 4, !tbaa !5
  %49 = load i32, ptr %3, align 4, !tbaa !11
  %50 = sext i32 %49 to i64
  %51 = getelementptr inbounds [20 x float], ptr %9, i64 0, i64 %50
  %52 = load float, ptr %51, align 4, !tbaa !5
  %53 = call float @function(float noundef %52)
  %54 = load i32, ptr %3, align 4, !tbaa !11
  %55 = sext i32 %54 to i64
  %56 = getelementptr inbounds [20 x float], ptr %8, i64 0, i64 %55
  store float %53, ptr %56, align 4, !tbaa !5
  %57 = load i32, ptr %3, align 4, !tbaa !11
  %58 = sext i32 %57 to i64
  %59 = getelementptr inbounds [20 x float], ptr %9, i64 0, i64 %58
  %60 = load float, ptr %59, align 4, !tbaa !5
  %61 = fpext float %60 to double
  %62 = load i32, ptr %3, align 4, !tbaa !11
  %63 = sext i32 %62 to i64
  %64 = getelementptr inbounds [20 x float], ptr %8, i64 0, i64 %63
  %65 = load float, ptr %64, align 4, !tbaa !5
  %66 = fpext float %65 to double
  %67 = call i32 (ptr, ...) @printf(ptr noundef @.str.7, double noundef %61, double noundef %66)
  %68 = load ptr, ptr %2, align 8, !tbaa !9
  %69 = load i32, ptr %3, align 4, !tbaa !11
  %70 = add nsw i32 %69, 1
  %71 = load i32, ptr %3, align 4, !tbaa !11
  %72 = load i32, ptr %3, align 4, !tbaa !11
  %73 = sext i32 %72 to i64
  %74 = getelementptr inbounds [20 x float], ptr %9, i64 0, i64 %73
  %75 = load float, ptr %74, align 4, !tbaa !5
  %76 = fpext float %75 to double
  %77 = load i32, ptr %3, align 4, !tbaa !11
  %78 = load i32, ptr %3, align 4, !tbaa !11
  %79 = sext i32 %78 to i64
  %80 = getelementptr inbounds [20 x float], ptr %8, i64 0, i64 %79
  %81 = load float, ptr %80, align 4, !tbaa !5
  %82 = fpext float %81 to double
  %83 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %68, ptr noundef @.str.8, i32 noundef %70, i32 noundef %71, double noundef %76, i32 noundef %77, double noundef %82) #5
  br label %84

84:                                               ; preds = %40
  %85 = load i32, ptr %3, align 4, !tbaa !11
  %86 = add nsw i32 %85, 1
  store i32 %86, ptr %3, align 4, !tbaa !11
  br label %36, !llvm.loop !13

87:                                               ; preds = %36
  store i32 1, ptr %3, align 4, !tbaa !11
  br label %88

88:                                               ; preds = %99, %87
  %89 = load i32, ptr %3, align 4, !tbaa !11
  %90 = load i32, ptr %4, align 4, !tbaa !11
  %91 = icmp slt i32 %89, %90
  br i1 %91, label %92, label %102

92:                                               ; preds = %88
  %93 = load i32, ptr %3, align 4, !tbaa !11
  %94 = sext i32 %93 to i64
  %95 = getelementptr inbounds [20 x float], ptr %8, i64 0, i64 %94
  %96 = load float, ptr %95, align 4, !tbaa !5
  %97 = load float, ptr %10, align 4, !tbaa !5
  %98 = fadd float %97, %96
  store float %98, ptr %10, align 4, !tbaa !5
  br label %99

99:                                               ; preds = %92
  %100 = load i32, ptr %3, align 4, !tbaa !11
  %101 = add nsw i32 %100, 1
  store i32 %101, ptr %3, align 4, !tbaa !11
  br label %88, !llvm.loop !15

102:                                              ; preds = %88
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #5
  %103 = load float, ptr %7, align 4, !tbaa !5
  %104 = fpext float %103 to double
  %105 = fmul double 5.000000e-01, %104
  %106 = getelementptr inbounds [20 x float], ptr %8, i64 0, i64 0
  %107 = load float, ptr %106, align 16, !tbaa !5
  %108 = load i32, ptr %4, align 4, !tbaa !11
  %109 = sext i32 %108 to i64
  %110 = getelementptr inbounds [20 x float], ptr %8, i64 0, i64 %109
  %111 = load float, ptr %110, align 4, !tbaa !5
  %112 = fadd float %107, %111
  %113 = load float, ptr %10, align 4, !tbaa !5
  %114 = call float @llvm.fmuladd.f32(float 2.000000e+00, float %113, float %112)
  %115 = fpext float %114 to double
  %116 = fmul double %105, %115
  %117 = fptrunc double %116 to float
  store float %117, ptr %11, align 4, !tbaa !5
  %118 = load float, ptr %11, align 4, !tbaa !5
  %119 = fpext float %118 to double
  %120 = call i32 (ptr, ...) @printf(ptr noundef @.str.9, double noundef %119)
  %121 = call i32 (ptr, ...) @printf(ptr noundef @.str.10)
  %122 = load ptr, ptr %2, align 8, !tbaa !9
  %123 = load i32, ptr %4, align 4, !tbaa !11
  %124 = load float, ptr %11, align 4, !tbaa !5
  %125 = fpext float %124 to double
  %126 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %122, ptr noundef @.str.11, i32 noundef %123, double noundef %125) #5
  %127 = load ptr, ptr %2, align 8, !tbaa !9
  %128 = call i32 @fclose(ptr noundef %127)
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #5
  call void @llvm.lifetime.end.p0(i64 80, ptr %9) #5
  call void @llvm.lifetime.end.p0(i64 80, ptr %8) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %6) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %5) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %4) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %3) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %2) #5
  ret i32 0
}

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

declare noalias ptr @fopen(ptr noundef, ptr noundef) #2

; Function Attrs: nounwind
declare i32 @fprintf(ptr noundef, ptr noundef, ...) #3

declare i32 @printf(ptr noundef, ...) #2

declare i32 @__isoc99_scanf(ptr noundef, ...) #2

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare float @llvm.fmuladd.f32(float, float, float) #4

declare i32 @fclose(ptr noundef) #2

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

attributes #0 = { 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 #1 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { "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 = { nounwind "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 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
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 = !{!"float", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"any pointer", !7, i64 0}
!11 = !{!12, !12, i64 0}
!12 = !{!"int", !7, i64 0}
!13 = distinct !{!13, !14}
!14 = !{!"llvm.loop.mustprogress"}
!15 = distinct !{!15, !14}


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

@.str = external hidden unnamed_addr constant [16 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [58 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [45 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [9 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [39 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [37 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [8 x i8], align 1
@.str.8 = external hidden unnamed_addr constant [29 x i8], align 1
@.str.9 = external hidden unnamed_addr constant [14 x i8], align 1
@.str.10 = external hidden unnamed_addr constant [61 x i8], align 1
@.str.11 = external hidden unnamed_addr constant [62 x i8], align 1

; Function Attrs: nounwind uwtable
declare dso_local float @function(float noundef) local_unnamed_addr #0

; Function Attrs: nounwind uwtable
define dso_local noundef i32 @main() local_unnamed_addr #0 {
  %1 = alloca i32, align 4
  %2 = alloca float, align 4
  %3 = alloca float, align 4
  %4 = alloca [20 x float], align 16
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %1) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %2) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %3) #4
  call void @llvm.lifetime.start.p0(i64 80, ptr nonnull %4) #4
  %5 = tail call noalias ptr @fopen(ptr noundef nonnull @.str, ptr noundef nonnull @.str.1)
  %6 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %5, ptr noundef nonnull @.str.2) #4
  %7 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.3)
  %8 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str.4, ptr noundef nonnull %2, ptr noundef nonnull %3, ptr noundef nonnull %1)
  %9 = load float, ptr %3, align 4, !tbaa !5
  %10 = load float, ptr %2, align 4, !tbaa !5
  %11 = fsub float %9, %10
  %12 = load i32, ptr %1, align 4, !tbaa !9
  %13 = sitofp i32 %12 to float
  %14 = fdiv float %11, %13
  %15 = fpext float %14 to double
  %16 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.5, i32 noundef %12, double noundef %15)
  %17 = load float, ptr %2, align 4, !tbaa !5
  %18 = fpext float %17 to double
  %19 = load float, ptr %3, align 4, !tbaa !5
  %20 = fpext float %19 to double
  %21 = load i32, ptr %1, align 4, !tbaa !9
  %22 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %5, ptr noundef nonnull @.str.6, double noundef %18, double noundef %20, i32 noundef %21, double noundef %15) #4
  %23 = load i32, ptr %1, align 4, !tbaa !9
  %.not30 = icmp slt i32 %23, 0
  br i1 %.not30, label %._crit_edge, label %.lr.ph

.preheader:                                       ; preds = %.lr.ph
  %24 = icmp sgt i32 %38, 1
  br i1 %24, label %.lr.ph34.preheader, label %._crit_edge

.lr.ph34.preheader:                               ; preds = %.preheader
  %wide.trip.count = zext nneg i32 %38 to i64
  %25 = add nsw i64 %wide.trip.count, -1
  %26 = add nsw i64 %wide.trip.count, -2
  %xtraiter = and i64 %25, 7
  %27 = icmp ult i64 %26, 7
  br i1 %27, label %._crit_edge.loopexit.unr-lcssa, label %.lr.ph34.preheader.new

.lr.ph34.preheader.new:                           ; preds = %.lr.ph34.preheader
  %unroll_iter = and i64 %25, -8
  br label %.lr.ph34

.lr.ph:                                           ; preds = %0, %.lr.ph
  %indvars.iv = phi i64 [ %indvars.iv.next, %.lr.ph ], [ 0, %0 ]
  %28 = load float, ptr %2, align 4, !tbaa !5
  %29 = trunc nuw nsw i64 %indvars.iv to i32
  %30 = uitofp nneg i32 %29 to float
  %31 = call float @llvm.fmuladd.f32(float %30, float %14, float %28)
  %32 = call float @function(float noundef %31)
  %33 = getelementptr inbounds [20 x float], ptr %4, i64 0, i64 %indvars.iv
  store float %32, ptr %33, align 4, !tbaa !5
  %34 = fpext float %31 to double
  %35 = fpext float %32 to double
  %36 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.7, double noundef %34, double noundef %35)
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %indvars = trunc i64 %indvars.iv.next to i32
  %37 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %5, ptr noundef nonnull @.str.8, i32 noundef %indvars, i32 noundef %29, double noundef %34, i32 noundef %29, double noundef %35) #4
  %38 = load i32, ptr %1, align 4, !tbaa !9
  %39 = sext i32 %38 to i64
  %.not.not = icmp slt i64 %indvars.iv, %39
  br i1 %.not.not, label %.lr.ph, label %.preheader, !llvm.loop !11

.lr.ph34:                                         ; preds = %.lr.ph34, %.lr.ph34.preheader.new
  %indvars.iv39 = phi i64 [ 1, %.lr.ph34.preheader.new ], [ %indvars.iv.next40.7, %.lr.ph34 ]
  %.02832 = phi float [ 0.000000e+00, %.lr.ph34.preheader.new ], [ %63, %.lr.ph34 ]
  %niter = phi i64 [ 0, %.lr.ph34.preheader.new ], [ %niter.next.7, %.lr.ph34 ]
  %40 = getelementptr inbounds [20 x float], ptr %4, i64 0, i64 %indvars.iv39
  %41 = load float, ptr %40, align 4, !tbaa !5
  %42 = fadd float %.02832, %41
  %indvars.iv.next40 = add nuw nsw i64 %indvars.iv39, 1
  %43 = getelementptr inbounds [20 x float], ptr %4, i64 0, i64 %indvars.iv.next40
  %44 = load float, ptr %43, align 4, !tbaa !5
  %45 = fadd float %42, %44
  %indvars.iv.next40.1 = add nuw nsw i64 %indvars.iv39, 2
  %46 = getelementptr inbounds [20 x float], ptr %4, i64 0, i64 %indvars.iv.next40.1
  %47 = load float, ptr %46, align 4, !tbaa !5
  %48 = fadd float %45, %47
  %indvars.iv.next40.2 = add nuw nsw i64 %indvars.iv39, 3
  %49 = getelementptr inbounds [20 x float], ptr %4, i64 0, i64 %indvars.iv.next40.2
  %50 = load float, ptr %49, align 4, !tbaa !5
  %51 = fadd float %48, %50
  %indvars.iv.next40.3 = add nuw nsw i64 %indvars.iv39, 4
  %52 = getelementptr inbounds [20 x float], ptr %4, i64 0, i64 %indvars.iv.next40.3
  %53 = load float, ptr %52, align 4, !tbaa !5
  %54 = fadd float %51, %53
  %indvars.iv.next40.4 = add nuw nsw i64 %indvars.iv39, 5
  %55 = getelementptr inbounds [20 x float], ptr %4, i64 0, i64 %indvars.iv.next40.4
  %56 = load float, ptr %55, align 4, !tbaa !5
  %57 = fadd float %54, %56
  %indvars.iv.next40.5 = add nuw nsw i64 %indvars.iv39, 6
  %58 = getelementptr inbounds [20 x float], ptr %4, i64 0, i64 %indvars.iv.next40.5
  %59 = load float, ptr %58, align 4, !tbaa !5
  %60 = fadd float %57, %59
  %indvars.iv.next40.6 = add nuw nsw i64 %indvars.iv39, 7
  %61 = getelementptr inbounds [20 x float], ptr %4, i64 0, i64 %indvars.iv.next40.6
  %62 = load float, ptr %61, align 4, !tbaa !5
  %63 = fadd float %60, %62
  %indvars.iv.next40.7 = add nuw nsw i64 %indvars.iv39, 8
  %niter.next.7 = add i64 %niter, 8
  %niter.ncmp.7 = icmp eq i64 %niter.next.7, %unroll_iter
  br i1 %niter.ncmp.7, label %._crit_edge.loopexit.unr-lcssa, label %.lr.ph34, !llvm.loop !13

._crit_edge.loopexit.unr-lcssa:                   ; preds = %.lr.ph34, %.lr.ph34.preheader
  %.lcssa.ph = phi float [ poison, %.lr.ph34.preheader ], [ %63, %.lr.ph34 ]
  %indvars.iv39.unr = phi i64 [ 1, %.lr.ph34.preheader ], [ %indvars.iv.next40.7, %.lr.ph34 ]
  %.02832.unr = phi float [ 0.000000e+00, %.lr.ph34.preheader ], [ %63, %.lr.ph34 ]
  %lcmp.mod.not = icmp eq i64 %xtraiter, 0
  br i1 %lcmp.mod.not, label %._crit_edge, label %.lr.ph34.epil

.lr.ph34.epil:                                    ; preds = %._crit_edge.loopexit.unr-lcssa, %.lr.ph34.epil
  %indvars.iv39.epil = phi i64 [ %indvars.iv.next40.epil, %.lr.ph34.epil ], [ %indvars.iv39.unr, %._crit_edge.loopexit.unr-lcssa ]
  %.02832.epil = phi float [ %66, %.lr.ph34.epil ], [ %.02832.unr, %._crit_edge.loopexit.unr-lcssa ]
  %epil.iter = phi i64 [ %epil.iter.next, %.lr.ph34.epil ], [ 0, %._crit_edge.loopexit.unr-lcssa ]
  %64 = getelementptr inbounds [20 x float], ptr %4, i64 0, i64 %indvars.iv39.epil
  %65 = load float, ptr %64, align 4, !tbaa !5
  %66 = fadd float %.02832.epil, %65
  %indvars.iv.next40.epil = add nuw nsw i64 %indvars.iv39.epil, 1
  %epil.iter.next = add i64 %epil.iter, 1
  %epil.iter.cmp.not = icmp eq i64 %epil.iter.next, %xtraiter
  br i1 %epil.iter.cmp.not, label %._crit_edge, label %.lr.ph34.epil, !llvm.loop !14

._crit_edge:                                      ; preds = %._crit_edge.loopexit.unr-lcssa, %.lr.ph34.epil, %0, %.preheader
  %.lcssa44 = phi i32 [ %38, %.preheader ], [ %23, %0 ], [ %38, %.lr.ph34.epil ], [ %38, %._crit_edge.loopexit.unr-lcssa ]
  %.028.lcssa = phi float [ 0.000000e+00, %.preheader ], [ 0.000000e+00, %0 ], [ %.lcssa.ph, %._crit_edge.loopexit.unr-lcssa ], [ %66, %.lr.ph34.epil ]
  %67 = fmul double %15, 5.000000e-01
  %68 = load float, ptr %4, align 16, !tbaa !5
  %69 = sext i32 %.lcssa44 to i64
  %70 = getelementptr inbounds [20 x float], ptr %4, i64 0, i64 %69
  %71 = load float, ptr %70, align 4, !tbaa !5
  %72 = fadd float %68, %71
  %73 = call float @llvm.fmuladd.f32(float %.028.lcssa, float 2.000000e+00, float %72)
  %74 = fpext float %73 to double
  %75 = fmul double %67, %74
  %76 = fptrunc double %75 to float
  %77 = fpext float %76 to double
  %78 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.9, double noundef %77)
  %79 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.10)
  %80 = load i32, ptr %1, align 4, !tbaa !9
  %81 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %5, ptr noundef nonnull @.str.11, i32 noundef %80, double noundef %77) #4
  %82 = call i32 @fclose(ptr noundef %5)
  call void @llvm.lifetime.end.p0(i64 80, ptr nonnull %4) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %3) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %2) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %1) #4
  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: nofree nounwind
declare noalias noundef ptr @fopen(ptr nocapture noundef readonly, ptr nocapture noundef readonly) local_unnamed_addr #2

; Function Attrs: nofree nounwind
declare noundef i32 @fprintf(ptr nocapture noundef, ptr nocapture noundef readonly, ...) local_unnamed_addr #2

; Function Attrs: nofree nounwind
declare noundef i32 @printf(ptr nocapture noundef readonly, ...) local_unnamed_addr #2

; Function Attrs: nofree nounwind
declare noundef i32 @__isoc99_scanf(ptr nocapture noundef readonly, ...) local_unnamed_addr #2

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

; Function Attrs: nofree nounwind
declare noundef i32 @fclose(ptr nocapture noundef) local_unnamed_addr #2

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

attributes #0 = { 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 #1 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { nofree nounwind "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 = { 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 = !{!"float", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"int", !7, i64 0}
!11 = distinct !{!11, !12}
!12 = !{!"llvm.loop.mustprogress"}
!13 = distinct !{!13, !12}
!14 = distinct !{!14, !15}
!15 = !{!"llvm.loop.unroll.disable"}


; Effective O3 passes: CorrelatedValuePropagationPass,EarlyCSEPass,GVNPass,GlobalOptPass,IndVarSimplifyPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,JumpThreadingPass,LCSSAPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,PostOrderFunctionAttrsPass,SROAPass,SimplifyCFGPass,TailCallElimPass