; LLVM IR from daanx/mimalloc-bench :: bench/cfrac (pcfrac)

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

%struct.EasEntry = type { ptr, ptr }

@verbose = external global i32, align 4
@.str.4 = external hidden unnamed_addr constant [36 x i8], align 1
@stdout = external global ptr, align 8

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

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

; Function Attrs: allocsize(0)
declare ptr @malloc(i64 noundef) #1

declare i32 @fputp(ptr noundef, ptr noundef) #2

; Function Attrs: inlinehint nounwind uwtable
declare hidden ptr @pparmq(ptr noundef) #3

declare i32 @putc(i32 noundef, ptr noundef) #2

declare i32 @fflush(ptr noundef) #2

; Function Attrs: inlinehint nounwind uwtable
declare hidden void @pdestroy(ptr noundef) #3

; Function Attrs: inlinehint nounwind uwtable
declare hidden ptr @psetq(ptr noundef, ptr noundef) #3

declare ptr @pmul(ptr noundef, ptr noundef) #2

declare ptr @utop(i32 noundef) #2

; Function Attrs: nounwind uwtable
declare dso_local double @pomeranceLpow(double noundef, double noundef) #4

; Function Attrs: nounwind
declare double @sqrt(double noundef) #5

declare double @ptod(ptr noundef) #2

; Function Attrs: nounwind uwtable
define dso_local ptr @getEas(ptr noundef %0, i32 noundef %1, ptr noundef %2, i32 noundef %3, i32 noundef %4) #4 {
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  %8 = alloca i32, align 4
  %9 = alloca ptr, align 8
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  %12 = alloca double, align 8
  %13 = alloca double, align 8
  %14 = alloca double, align 8
  %15 = alloca double, align 8
  %16 = alloca double, align 8
  %17 = alloca double, align 8
  %18 = alloca double, align 8
  %19 = alloca double, align 8
  %20 = alloca double, align 8
  %21 = alloca i32, align 4
  %22 = alloca i32, align 4
  %23 = alloca i32, align 4
  %24 = alloca ptr, align 8
  %25 = alloca ptr, align 8
  %26 = alloca i32, align 4
  store ptr %0, ptr %7, align 8, !tbaa !5
  store i32 %1, ptr %8, align 4, !tbaa !9
  store ptr %2, ptr %9, align 8, !tbaa !5
  store i32 %3, ptr %10, align 4, !tbaa !9
  store i32 %4, ptr %11, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #7
  %27 = load i32, ptr %11, align 4, !tbaa !9
  %28 = uitofp i32 %27 to double
  %29 = fadd double %28, 1.000000e+00
  %30 = fdiv double 1.000000e+00, %29
  store double %30, ptr %12, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #7
  %31 = load double, ptr %12, align 8, !tbaa !11
  %32 = call double @llvm.fmuladd.f64(double 2.000000e+00, double %31, double 6.000000e+00)
  %33 = call double @sqrt(double noundef %32) #7
  %34 = fdiv double 1.000000e+00, %33
  store double %34, ptr %13, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #7
  %35 = load double, ptr %13, align 8, !tbaa !11
  %36 = load double, ptr %12, align 8, !tbaa !11
  %37 = fmul double %35, %36
  store double %37, ptr %14, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #7
  store double 1.000000e+00, ptr %15, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #7
  store double 0.000000e+00, ptr %16, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %19) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %20) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %21) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %22) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %23) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %24) #7
  store ptr null, ptr %24, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %25) #7
  %38 = load i32, ptr %11, align 4, !tbaa !9
  %39 = icmp eq i32 %38, 0
  br i1 %39, label %40, label %41

40:                                               ; preds = %5
  store ptr null, ptr %6, align 8
  store i32 1, ptr %26, align 4
  br label %176

41:                                               ; preds = %5
  %42 = load i32, ptr %11, align 4, !tbaa !9
  %43 = add i32 %42, 1
  %44 = zext i32 %43 to i64
  %45 = mul i64 %44, 16
  %46 = call ptr @malloc(i64 noundef %45) #8
  store ptr %46, ptr %25, align 8, !tbaa !5
  %47 = load ptr, ptr %25, align 8, !tbaa !5
  %48 = icmp eq ptr %47, null
  br i1 %48, label %49, label %51

49:                                               ; preds = %41
  %50 = load ptr, ptr %25, align 8, !tbaa !5
  store ptr %50, ptr %6, align 8
  store i32 1, ptr %26, align 4
  br label %176

51:                                               ; preds = %41
  %52 = load i32, ptr %8, align 4, !tbaa !9
  %53 = call ptr @utop(i32 noundef %52)
  %54 = load ptr, ptr %7, align 8, !tbaa !5
  %55 = call ptr @pparmq(ptr noundef %54)
  %56 = call ptr @pmul(ptr noundef %53, ptr noundef %55)
  %57 = call double @ptod(ptr noundef %56)
  store double %57, ptr %17, align 8, !tbaa !11
  store i32 1, ptr %21, align 4, !tbaa !9
  br label %58

58:                                               ; preds = %157, %51
  %59 = load i32, ptr %21, align 4, !tbaa !9
  %60 = load i32, ptr %11, align 4, !tbaa !9
  %61 = icmp ule i32 %59, %60
  br i1 %61, label %62, label %160

62:                                               ; preds = %58
  %63 = load ptr, ptr %25, align 8, !tbaa !5
  %64 = load i32, ptr %21, align 4, !tbaa !9
  %65 = sub i32 %64, 1
  %66 = zext i32 %65 to i64
  %67 = getelementptr inbounds %struct.EasEntry, ptr %63, i64 %66
  %68 = getelementptr inbounds %struct.EasEntry, ptr %67, i32 0, i32 0
  store ptr null, ptr %68, align 8, !tbaa !13
  %69 = load ptr, ptr %25, align 8, !tbaa !5
  %70 = load i32, ptr %21, align 4, !tbaa !9
  %71 = sub i32 %70, 1
  %72 = zext i32 %71 to i64
  %73 = getelementptr inbounds %struct.EasEntry, ptr %69, i64 %72
  %74 = getelementptr inbounds %struct.EasEntry, ptr %73, i32 0, i32 1
  store ptr null, ptr %74, align 8, !tbaa !15
  %75 = load double, ptr %14, align 8, !tbaa !11
  %76 = load double, ptr %16, align 8, !tbaa !11
  %77 = fadd double %76, %75
  store double %77, ptr %16, align 8, !tbaa !11
  %78 = load double, ptr %16, align 8, !tbaa !11
  %79 = fmul double 4.000000e+00, %78
  %80 = load double, ptr %16, align 8, !tbaa !11
  %81 = fmul double %79, %80
  %82 = load i32, ptr %21, align 4, !tbaa !9
  %83 = uitofp i32 %82 to double
  %84 = fdiv double %81, %83
  store double %84, ptr %20, align 8, !tbaa !11
  %85 = load double, ptr %20, align 8, !tbaa !11
  %86 = load double, ptr %15, align 8, !tbaa !11
  %87 = fsub double %86, %85
  store double %87, ptr %15, align 8, !tbaa !11
  %88 = load double, ptr %17, align 8, !tbaa !11
  %89 = load double, ptr %16, align 8, !tbaa !11
  %90 = call double @pomeranceLpow(double noundef %88, double noundef %89)
  store double %90, ptr %18, align 8, !tbaa !11
  %91 = load double, ptr %17, align 8, !tbaa !11
  %92 = load double, ptr %15, align 8, !tbaa !11
  %93 = fmul double 5.000000e-01, %92
  %94 = call double @pow(double noundef %91, double noundef %93) #7
  store double %94, ptr %19, align 8, !tbaa !11
  %95 = load double, ptr %18, align 8, !tbaa !11
  %96 = fadd double %95, 5.000000e-01
  %97 = fptoui double %96 to i32
  store i32 %97, ptr %23, align 4, !tbaa !9
  %98 = load double, ptr %19, align 8, !tbaa !11
  %99 = call ptr @dtop(double noundef %98)
  %100 = call ptr @psetq(ptr noundef %24, ptr noundef %99)
  store i32 0, ptr %22, align 4, !tbaa !9
  br label %101

101:                                              ; preds = %115, %62
  %102 = load i32, ptr %22, align 4, !tbaa !9
  %103 = load i32, ptr %10, align 4, !tbaa !9
  %104 = icmp ult i32 %102, %103
  br i1 %104, label %105, label %118

105:                                              ; preds = %101
  %106 = load ptr, ptr %9, align 8, !tbaa !5
  %107 = load i32, ptr %22, align 4, !tbaa !9
  %108 = zext i32 %107 to i64
  %109 = getelementptr inbounds i32, ptr %106, i64 %108
  %110 = load i32, ptr %109, align 4, !tbaa !9
  %111 = load i32, ptr %23, align 4, !tbaa !9
  %112 = icmp uge i32 %110, %111
  br i1 %112, label %113, label %114

113:                                              ; preds = %105
  br label %119

114:                                              ; preds = %105
  br label %115

115:                                              ; preds = %114
  %116 = load i32, ptr %22, align 4, !tbaa !9
  %117 = add i32 %116, 1
  store i32 %117, ptr %22, align 4, !tbaa !9
  br label %101, !llvm.loop !16

118:                                              ; preds = %101
  br label %160

119:                                              ; preds = %113
  %120 = load i32, ptr @verbose, align 4, !tbaa !9
  %121 = icmp sgt i32 %120, 1
  br i1 %121, label %122, label %138

122:                                              ; preds = %119
  %123 = load i32, ptr %21, align 4, !tbaa !9
  %124 = load ptr, ptr %9, align 8, !tbaa !5
  %125 = load i32, ptr %22, align 4, !tbaa !9
  %126 = zext i32 %125 to i64
  %127 = getelementptr inbounds i32, ptr %124, i64 %126
  %128 = load i32, ptr %127, align 4, !tbaa !9
  %129 = load i32, ptr %23, align 4, !tbaa !9
  %130 = call i32 (ptr, ...) @printf(ptr noundef @.str.4, i32 noundef %123, i32 noundef %128, i32 noundef %129)
  %131 = load ptr, ptr @stdout, align 8, !tbaa !5
  %132 = load ptr, ptr %24, align 8, !tbaa !5
  %133 = call i32 @fputp(ptr noundef %131, ptr noundef %132)
  %134 = load ptr, ptr @stdout, align 8, !tbaa !5
  %135 = call i32 @putc(i32 noundef 10, ptr noundef %134)
  %136 = load ptr, ptr @stdout, align 8, !tbaa !5
  %137 = call i32 @fflush(ptr noundef %136)
  br label %138

138:                                              ; preds = %122, %119
  %139 = load ptr, ptr %9, align 8, !tbaa !5
  %140 = load i32, ptr %22, align 4, !tbaa !9
  %141 = zext i32 %140 to i64
  %142 = getelementptr inbounds i32, ptr %139, i64 %141
  %143 = load ptr, ptr %25, align 8, !tbaa !5
  %144 = load i32, ptr %21, align 4, !tbaa !9
  %145 = sub i32 %144, 1
  %146 = zext i32 %145 to i64
  %147 = getelementptr inbounds %struct.EasEntry, ptr %143, i64 %146
  %148 = getelementptr inbounds %struct.EasEntry, ptr %147, i32 0, i32 0
  store ptr %142, ptr %148, align 8, !tbaa !13
  %149 = load ptr, ptr %25, align 8, !tbaa !5
  %150 = load i32, ptr %21, align 4, !tbaa !9
  %151 = sub i32 %150, 1
  %152 = zext i32 %151 to i64
  %153 = getelementptr inbounds %struct.EasEntry, ptr %149, i64 %152
  %154 = getelementptr inbounds %struct.EasEntry, ptr %153, i32 0, i32 1
  %155 = load ptr, ptr %24, align 8, !tbaa !5
  %156 = call ptr @psetq(ptr noundef %154, ptr noundef %155)
  br label %157

157:                                              ; preds = %138
  %158 = load i32, ptr %21, align 4, !tbaa !9
  %159 = add i32 %158, 1
  store i32 %159, ptr %21, align 4, !tbaa !9
  br label %58, !llvm.loop !18

160:                                              ; preds = %118, %58
  %161 = load ptr, ptr %25, align 8, !tbaa !5
  %162 = load i32, ptr %21, align 4, !tbaa !9
  %163 = sub i32 %162, 1
  %164 = zext i32 %163 to i64
  %165 = getelementptr inbounds %struct.EasEntry, ptr %161, i64 %164
  %166 = getelementptr inbounds %struct.EasEntry, ptr %165, i32 0, i32 0
  store ptr null, ptr %166, align 8, !tbaa !13
  %167 = load ptr, ptr %25, align 8, !tbaa !5
  %168 = load i32, ptr %21, align 4, !tbaa !9
  %169 = sub i32 %168, 1
  %170 = zext i32 %169 to i64
  %171 = getelementptr inbounds %struct.EasEntry, ptr %167, i64 %170
  %172 = getelementptr inbounds %struct.EasEntry, ptr %171, i32 0, i32 1
  store ptr null, ptr %172, align 8, !tbaa !15
  %173 = load ptr, ptr %24, align 8, !tbaa !5
  call void @pdestroy(ptr noundef %173)
  %174 = load ptr, ptr %7, align 8, !tbaa !5
  call void @pdestroy(ptr noundef %174)
  %175 = load ptr, ptr %25, align 8, !tbaa !5
  store ptr %175, ptr %6, align 8
  store i32 1, ptr %26, align 4
  br label %176

176:                                              ; preds = %160, %49, %40
  call void @llvm.lifetime.end.p0(i64 8, ptr %25) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %24) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %23) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %22) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %21) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #7
  %177 = load ptr, ptr %6, align 8
  ret ptr %177
}

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

; Function Attrs: nounwind
declare double @pow(double noundef, double noundef) #5

declare ptr @dtop(double noundef) #2

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

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { allocsize(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 #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 = { inlinehint 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 #4 = { 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 "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 #6 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #7 = { nounwind }
attributes #8 = { allocsize(0) }

!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/C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"int", !7, i64 0}
!11 = !{!12, !12, i64 0}
!12 = !{!"double", !7, i64 0}
!13 = !{!14, !6, i64 0}
!14 = !{!"", !6, i64 0, !6, i64 8}
!15 = !{!14, !6, i64 8}
!16 = distinct !{!16, !17}
!17 = !{!"llvm.loop.mustprogress"}
!18 = distinct !{!18, !17}


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

%struct.EasEntry = type { ptr, ptr }

@verbose = external local_unnamed_addr global i32, align 4
@.str.4 = external hidden unnamed_addr constant [36 x i8], align 1
@stdout = external local_unnamed_addr global ptr, align 8

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

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

; Function Attrs: mustprogress nofree nounwind willreturn allockind("alloc,uninitialized") allocsize(0) memory(inaccessiblemem: readwrite)
declare noalias noundef ptr @malloc(i64 noundef) local_unnamed_addr #1

declare i32 @fputp(ptr noundef, ptr noundef) local_unnamed_addr #2

; Function Attrs: inlinehint nounwind uwtable
declare hidden ptr @pparmq(ptr noundef) local_unnamed_addr #3

; Function Attrs: nofree nounwind
declare noundef i32 @putc(i32 noundef, ptr nocapture noundef) local_unnamed_addr #4

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

; Function Attrs: inlinehint nounwind uwtable
declare hidden void @pdestroy(ptr noundef) local_unnamed_addr #3

; Function Attrs: inlinehint nounwind uwtable
declare hidden ptr @psetq(ptr noundef, ptr noundef) local_unnamed_addr #3

declare ptr @pmul(ptr noundef, ptr noundef) local_unnamed_addr #2

declare ptr @utop(i32 noundef) local_unnamed_addr #2

; Function Attrs: nounwind uwtable
declare dso_local double @pomeranceLpow(double noundef, double noundef) local_unnamed_addr #5

; Function Attrs: mustprogress nofree nounwind willreturn memory(write)
declare double @sqrt(double noundef) local_unnamed_addr #6

declare double @ptod(ptr noundef) local_unnamed_addr #2

; Function Attrs: nounwind uwtable
define dso_local noundef ptr @getEas(ptr noundef %0, i32 noundef %1, ptr noundef %2, i32 noundef %3, i32 noundef %4) local_unnamed_addr #5 {
  %6 = alloca ptr, align 8
  %7 = uitofp i32 %4 to double
  %8 = fadd double %7, 1.000000e+00
  %9 = fdiv double 1.000000e+00, %8
  %10 = tail call double @llvm.fmuladd.f64(double %9, double 2.000000e+00, double 6.000000e+00)
  %11 = tail call double @sqrt(double noundef %10) #9
  %12 = fdiv double 1.000000e+00, %11
  %13 = fmul double %9, %12
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %6) #9
  store ptr null, ptr %6, align 8, !tbaa !5
  %14 = icmp eq i32 %4, 0
  br i1 %14, label %76, label %15

15:                                               ; preds = %5
  %16 = add i32 %4, 1
  %17 = zext i32 %16 to i64
  %18 = shl nuw nsw i64 %17, 4
  %19 = tail call ptr @malloc(i64 noundef %18) #10
  %20 = icmp eq ptr %19, null
  br i1 %20, label %76, label %.lr.ph73

.lr.ph73:                                         ; preds = %15
  %21 = tail call ptr @utop(i32 noundef %1) #9
  %22 = tail call ptr @pparmq(ptr noundef %0)
  %23 = tail call ptr @pmul(ptr noundef %21, ptr noundef %22) #9
  %24 = tail call double @ptod(ptr noundef %23) #9
  %.not = icmp eq i32 %3, 0
  br i1 %.not, label %.lr.ph73.split, label %.lr.ph.us.preheader

.lr.ph.us.preheader:                              ; preds = %.lr.ph73
  %wide.trip.count = zext i32 %3 to i64
  br label %.lr.ph.us

.lr.ph.us:                                        ; preds = %.lr.ph.us.preheader, %59
  %.05272.us = phi double [ %34, %59 ], [ 1.000000e+00, %.lr.ph.us.preheader ]
  %.05471.us = phi i32 [ %62, %59 ], [ 1, %.lr.ph.us.preheader ]
  %.05570.us = phi double [ %29, %59 ], [ 0.000000e+00, %.lr.ph.us.preheader ]
  %25 = add i32 %.05471.us, -1
  %26 = zext i32 %25 to i64
  %27 = getelementptr inbounds %struct.EasEntry, ptr %19, i64 %26
  %28 = getelementptr inbounds i8, ptr %27, i64 8
  %29 = fadd double %13, %.05570.us
  %30 = fmul double %29, 4.000000e+00
  %31 = fmul double %29, %30
  %32 = uitofp i32 %.05471.us to double
  %33 = fdiv double %31, %32
  %34 = fsub double %.05272.us, %33
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %27, i8 0, i64 16, i1 false)
  %35 = call double @pomeranceLpow(double noundef %24, double noundef %29)
  %36 = fmul double %34, 5.000000e-01
  %37 = call double @pow(double noundef %24, double noundef %36) #9
  %38 = fadd double %35, 5.000000e-01
  %39 = fptoui double %38 to i32
  %40 = call ptr @dtop(double noundef %37) #9
  %41 = call ptr @psetq(ptr noundef nonnull %6, ptr noundef %40)
  br label %43

42:                                               ; preds = %43
  %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 %.loopexit.loopexit, label %43, !llvm.loop !9

43:                                               ; preds = %.lr.ph.us, %42
  %indvars.iv = phi i64 [ 0, %.lr.ph.us ], [ %indvars.iv.next, %42 ]
  %44 = getelementptr inbounds i32, ptr %2, i64 %indvars.iv
  %45 = load i32, ptr %44, align 4, !tbaa !11
  %.not60.us = icmp ult i32 %45, %39
  br i1 %.not60.us, label %42, label %46

46:                                               ; preds = %43
  %47 = getelementptr inbounds i32, ptr %2, i64 %indvars.iv
  %48 = load i32, ptr @verbose, align 4, !tbaa !11
  %49 = icmp sgt i32 %48, 1
  br i1 %49, label %50, label %59

50:                                               ; preds = %46
  %51 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.4, i32 noundef %.05471.us, i32 noundef %45, i32 noundef %39)
  %52 = load ptr, ptr @stdout, align 8, !tbaa !5
  %53 = load ptr, ptr %6, align 8, !tbaa !5
  %54 = call i32 @fputp(ptr noundef %52, ptr noundef %53) #9
  %55 = load ptr, ptr @stdout, align 8, !tbaa !5
  %56 = call i32 @putc(i32 noundef 10, ptr noundef %55)
  %57 = load ptr, ptr @stdout, align 8, !tbaa !5
  %58 = call i32 @fflush(ptr noundef %57)
  br label %59

59:                                               ; preds = %50, %46
  store ptr %47, ptr %27, align 8, !tbaa !13
  %60 = load ptr, ptr %6, align 8, !tbaa !5
  %61 = call ptr @psetq(ptr noundef nonnull %28, ptr noundef %60)
  %62 = add i32 %.05471.us, 1
  %.not.us = icmp ugt i32 %62, %4
  br i1 %.not.us, label %.loopexit, label %.lr.ph.us, !llvm.loop !15

.lr.ph73.split:                                   ; preds = %.lr.ph73
  %63 = fadd double %13, 0.000000e+00
  %64 = fmul double %63, 4.000000e+00
  %65 = fmul double %63, %64
  %66 = fsub double 1.000000e+00, %65
  tail call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %19, i8 0, i64 16, i1 false)
  %67 = tail call double @pomeranceLpow(double noundef %24, double noundef %63)
  %68 = fmul double %66, 5.000000e-01
  %69 = tail call double @pow(double noundef %24, double noundef %68) #9
  %70 = tail call ptr @dtop(double noundef %69) #9
  %71 = call ptr @psetq(ptr noundef nonnull %6, ptr noundef %70)
  br label %.loopexit

.loopexit.loopexit:                               ; preds = %42
  %72 = add i32 %.05471.us, -1
  br label %.loopexit

.loopexit:                                        ; preds = %59, %.loopexit.loopexit, %.lr.ph73.split
  %.05464 = phi i32 [ 0, %.lr.ph73.split ], [ %72, %.loopexit.loopexit ], [ %.05471.us, %59 ]
  %73 = zext i32 %.05464 to i64
  %74 = getelementptr inbounds %struct.EasEntry, ptr %19, i64 %73
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %74, i8 0, i64 16, i1 false)
  %75 = load ptr, ptr %6, align 8, !tbaa !5
  call void @pdestroy(ptr noundef %75)
  call void @pdestroy(ptr noundef %0)
  br label %76

76:                                               ; preds = %15, %5, %.loopexit
  %.0 = phi ptr [ %19, %.loopexit ], [ null, %5 ], [ null, %15 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #9
  ret ptr %.0
}

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

; Function Attrs: mustprogress nofree nounwind willreturn memory(write)
declare double @pow(double noundef, double noundef) local_unnamed_addr #6

declare ptr @dtop(double noundef) local_unnamed_addr #2

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

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

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { mustprogress nofree nounwind willreturn allockind("alloc,uninitialized") allocsize(0) memory(inaccessiblemem: readwrite) "alloc-family"="malloc" "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 = { "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 = { inlinehint 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 #4 = { 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 #5 = { 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 #6 = { mustprogress nofree nounwind willreturn memory(write) "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 #7 = { mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #8 = { nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #9 = { nounwind }
attributes #10 = { allocsize(0) }

!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/C++ TBAA"}
!9 = distinct !{!9, !10}
!10 = !{!"llvm.loop.mustprogress"}
!11 = !{!12, !12, i64 0}
!12 = !{!"int", !7, i64 0}
!13 = !{!14, !6, i64 0}
!14 = !{!"", !6, i64 0, !6, i64 8}
!15 = distinct !{!15, !10}


; Effective O3 passes: CorrelatedValuePropagationPass,EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,JumpThreadingPass,LCSSAPass,LICMPass,LoopInstSimplifyPass,LoopRotatePass,LoopSimplifyCFGPass,LoopSimplifyPass,LoopUnrollPass,MemCpyOptPass,PostOrderFunctionAttrsPass,ReassociatePass,SCCPPass,SROAPass,SimplifyCFGPass,TailCallElimPass