; LLVM IR from CLASS-SZ/class_sz :: class-sz/source (nonlinear)

; 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.background = type { double, double, double, double, double, double, double, i32, double, double, double, double, i16, double, double, double, double, double, double, double, double, double, i16, double, double, ptr, i32, i32, double, i32, ptr, ptr, double, ptr, double, ptr, double, ptr, double, ptr, ptr, ptr, double, double, double, double, i32, ptr, double, double, double, double, double, double, double, double, double, double, double, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, ptr, ptr, ptr, ptr, ptr, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i16, i16, i16, i16, i16, i16, i16, i16, i16, i16, i16, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, i16, i16, i16, i16, i16, i16, [2048 x i8], i16, [2048 x i8] }
%struct.nonlinear = type { i32, i32, i32, double, double, double, i16, i32, i32, i32, ptr, i16, i16, i32, i32, i32, i32, i32, i16, i32, ptr, ptr, ptr, i32, ptr, ptr, ptr, ptr, ptr, ptr, ptr, i32, i32, ptr, ptr, ptr, i32, i32, i32, i32, i32, ptr, ptr, ptr, i16, [2048 x i8] }
%struct.nonlinear_workspace = type { ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, double }

@.str.3 = external hidden unnamed_addr constant [13 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [18 x i8], align 1
@.str.15 = external hidden unnamed_addr constant [35 x i8], align 1
@.str.79 = external hidden unnamed_addr constant [9 x i8], align 1
@__func__.nonlinear_hmcode_dark_energy_correction = external hidden unnamed_addr constant [40 x i8], align 1
@.str.203 = external hidden unnamed_addr constant [57 x i8], align 1
@.str.204 = external hidden unnamed_addr constant [88 x i8], align 1
@.str.205 = external hidden unnamed_addr constant [69 x i8], align 1
@.str.206 = external hidden unnamed_addr constant [77 x i8], align 1
@.str.207 = external hidden unnamed_addr constant [94 x i8], align 1

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

declare void @class_protect_sprintf(ptr noundef, ptr noundef, ...) #1

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

declare i32 @background_tau_of_z(ptr noundef, double noundef, ptr noundef) #1

; Function Attrs: nounwind allocsize(0)
declare noalias ptr @malloc(i64 noundef) #2

; Function Attrs: nounwind
declare void @free(ptr noundef) #3

; Function Attrs: nounwind uwtable
define dso_local i32 @nonlinear_hmcode_dark_energy_correction(ptr noundef %0, ptr noundef %1, ptr noundef %2, ptr noundef %3) #4 {
  %5 = alloca i32, align 4
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  %8 = alloca ptr, align 8
  %9 = alloca ptr, align 8
  %10 = alloca i32, align 4
  %11 = alloca ptr, align 8
  %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 i32, align 4
  %19 = alloca [2048 x i8], align 16
  %20 = alloca i32, align 4
  %21 = alloca [2048 x i8], align 16
  %22 = alloca [2048 x i8], align 16
  %23 = alloca [2048 x i8], align 16
  %24 = alloca [2048 x i8], align 16
  %25 = alloca [2048 x i8], align 16
  store ptr %0, ptr %6, align 8, !tbaa !5
  store ptr %1, ptr %7, align 8, !tbaa !5
  store ptr %2, ptr %8, align 8, !tbaa !5
  store ptr %3, ptr %9, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #5
  %26 = load ptr, ptr %7, align 8, !tbaa !5
  %27 = getelementptr inbounds %struct.background, ptr %26, i32 0, i32 125
  %28 = load i16, ptr %27, align 8, !tbaa !9
  %29 = sext i16 %28 to i32
  %30 = icmp eq i32 %29, 1
  br i1 %30, label %31, label %157

31:                                               ; preds = %4
  %32 = load ptr, ptr %7, align 8, !tbaa !5
  %33 = getelementptr inbounds %struct.background, ptr %32, i32 0, i32 99
  %34 = load i32, ptr %33, align 8, !tbaa !14
  %35 = sext i32 %34 to i64
  %36 = mul i64 %35, 8
  %37 = call noalias ptr @malloc(i64 noundef %36) #6
  store ptr %37, ptr %11, align 8, !tbaa !5
  %38 = load ptr, ptr %11, align 8, !tbaa !5
  %39 = icmp eq ptr %38, null
  br i1 %39, label %40, label %53

40:                                               ; preds = %31
  call void @llvm.lifetime.start.p0(i64 4, ptr %18) #5
  %41 = load ptr, ptr %7, align 8, !tbaa !5
  %42 = getelementptr inbounds %struct.background, ptr %41, i32 0, i32 99
  %43 = load i32, ptr %42, align 8, !tbaa !14
  %44 = sext i32 %43 to i64
  %45 = mul i64 %44, 8
  %46 = trunc i64 %45 to i32
  store i32 %46, ptr %18, align 4, !tbaa !15
  call void @llvm.lifetime.start.p0(i64 2048, ptr %19) #5
  %47 = getelementptr inbounds [2048 x i8], ptr %19, i64 0, i64 0
  %48 = load i32, ptr %18, align 4, !tbaa !15
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef %47, ptr noundef @.str.15, ptr noundef @.str.79, i32 noundef %48)
  %49 = load ptr, ptr %8, align 8, !tbaa !5
  %50 = getelementptr inbounds %struct.nonlinear, ptr %49, i32 0, i32 45
  %51 = getelementptr inbounds [2048 x i8], ptr %50, i64 0, i64 0
  %52 = getelementptr inbounds [2048 x i8], ptr %19, i64 0, i64 0
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef %51, ptr noundef @.str.3, ptr noundef @__func__.nonlinear_hmcode_dark_energy_correction, i32 noundef 3724, ptr noundef %52)
  call void @llvm.lifetime.end.p0(i64 2048, ptr %19) #5
  store i32 1, ptr %5, align 4
  store i32 1, ptr %20, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %18) #5
  br label %161

53:                                               ; preds = %31
  %54 = load ptr, ptr %7, align 8, !tbaa !5
  %55 = load ptr, ptr %8, align 8, !tbaa !5
  %56 = getelementptr inbounds %struct.nonlinear, ptr %55, i32 0, i32 5
  %57 = load double, ptr %56, align 8, !tbaa !16
  %58 = call i32 @background_tau_of_z(ptr noundef %54, double noundef %57, ptr noundef %12)
  %59 = icmp eq i32 %58, 1
  br i1 %59, label %60, label %69

60:                                               ; preds = %53
  call void @llvm.lifetime.start.p0(i64 2048, ptr %21) #5
  %61 = getelementptr inbounds [2048 x i8], ptr %21, i64 0, i64 0
  %62 = load ptr, ptr %7, align 8, !tbaa !5
  %63 = getelementptr inbounds %struct.background, ptr %62, i32 0, i32 149
  %64 = getelementptr inbounds [2048 x i8], ptr %63, i64 0, i64 0
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef %61, ptr noundef @.str.4, ptr noundef @.str.203, ptr noundef %64)
  %65 = load ptr, ptr %8, align 8, !tbaa !5
  %66 = getelementptr inbounds %struct.nonlinear, ptr %65, i32 0, i32 45
  %67 = getelementptr inbounds [2048 x i8], ptr %66, i64 0, i64 0
  %68 = getelementptr inbounds [2048 x i8], ptr %21, i64 0, i64 0
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef %67, ptr noundef @.str.3, ptr noundef @__func__.nonlinear_hmcode_dark_energy_correction, i32 noundef 3732, ptr noundef %68)
  call void @llvm.lifetime.end.p0(i64 2048, ptr %21) #5
  store i32 1, ptr %5, align 4
  store i32 1, ptr %20, align 4
  br label %161

69:                                               ; preds = %53
  %70 = load ptr, ptr %7, align 8, !tbaa !5
  %71 = load double, ptr %12, align 8, !tbaa !18
  %72 = load ptr, ptr %7, align 8, !tbaa !5
  %73 = getelementptr inbounds %struct.background, ptr %72, i32 0, i32 143
  %74 = load i16, ptr %73, align 4, !tbaa !19
  %75 = load ptr, ptr %7, align 8, !tbaa !5
  %76 = getelementptr inbounds %struct.background, ptr %75, i32 0, i32 144
  %77 = load i16, ptr %76, align 2, !tbaa !20
  %78 = load ptr, ptr %11, align 8, !tbaa !5
  %79 = call i32 @background_at_tau(ptr noundef %70, double noundef %71, i16 noundef signext %74, i16 noundef signext %77, ptr noundef %10, ptr noundef %78)
  %80 = icmp eq i32 %79, 1
  br i1 %80, label %81, label %90

81:                                               ; preds = %69
  call void @llvm.lifetime.start.p0(i64 2048, ptr %22) #5
  %82 = getelementptr inbounds [2048 x i8], ptr %22, i64 0, i64 0
  %83 = load ptr, ptr %7, align 8, !tbaa !5
  %84 = getelementptr inbounds %struct.background, ptr %83, i32 0, i32 149
  %85 = getelementptr inbounds [2048 x i8], ptr %84, i64 0, i64 0
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef %82, ptr noundef @.str.4, ptr noundef @.str.204, ptr noundef %85)
  %86 = load ptr, ptr %8, align 8, !tbaa !5
  %87 = getelementptr inbounds %struct.nonlinear, ptr %86, i32 0, i32 45
  %88 = getelementptr inbounds [2048 x i8], ptr %87, i64 0, i64 0
  %89 = getelementptr inbounds [2048 x i8], ptr %22, i64 0, i64 0
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef %88, ptr noundef @.str.3, ptr noundef @__func__.nonlinear_hmcode_dark_energy_correction, i32 noundef 3736, ptr noundef %89)
  call void @llvm.lifetime.end.p0(i64 2048, ptr %22) #5
  store i32 1, ptr %5, align 4
  store i32 1, ptr %20, align 4
  br label %161

90:                                               ; preds = %69
  %91 = load ptr, ptr %7, align 8, !tbaa !5
  %92 = load ptr, ptr %7, align 8, !tbaa !5
  %93 = getelementptr inbounds %struct.background, ptr %92, i32 0, i32 58
  %94 = load double, ptr %93, align 8, !tbaa !21
  %95 = call i32 @background_w_fld(ptr noundef %91, double noundef %94, ptr noundef %15, ptr noundef %16, ptr noundef %17)
  %96 = icmp eq i32 %95, 1
  br i1 %96, label %97, label %106

97:                                               ; preds = %90
  call void @llvm.lifetime.start.p0(i64 2048, ptr %23) #5
  %98 = getelementptr inbounds [2048 x i8], ptr %23, i64 0, i64 0
  %99 = load ptr, ptr %7, align 8, !tbaa !5
  %100 = getelementptr inbounds %struct.background, ptr %99, i32 0, i32 149
  %101 = getelementptr inbounds [2048 x i8], ptr %100, i64 0, i64 0
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef %98, ptr noundef @.str.4, ptr noundef @.str.205, ptr noundef %101)
  %102 = load ptr, ptr %8, align 8, !tbaa !5
  %103 = getelementptr inbounds %struct.nonlinear, ptr %102, i32 0, i32 45
  %104 = getelementptr inbounds [2048 x i8], ptr %103, i64 0, i64 0
  %105 = getelementptr inbounds [2048 x i8], ptr %23, i64 0, i64 0
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef %104, ptr noundef @.str.3, ptr noundef @__func__.nonlinear_hmcode_dark_energy_correction, i32 noundef 3740, ptr noundef %105)
  call void @llvm.lifetime.end.p0(i64 2048, ptr %23) #5
  store i32 1, ptr %5, align 4
  store i32 1, ptr %20, align 4
  br label %161

106:                                              ; preds = %90
  %107 = load ptr, ptr %6, align 8, !tbaa !5
  %108 = load ptr, ptr %7, align 8, !tbaa !5
  %109 = load ptr, ptr %8, align 8, !tbaa !5
  %110 = load ptr, ptr %8, align 8, !tbaa !5
  %111 = getelementptr inbounds %struct.nonlinear, ptr %110, i32 0, i32 5
  %112 = load double, ptr %111, align 8, !tbaa !16
  %113 = fadd double 1.000000e+00, %112
  %114 = fdiv double 1.000000e+00, %113
  %115 = call i32 @nonlinear_hmcode_growint(ptr noundef %107, ptr noundef %108, ptr noundef %109, double noundef %114, double noundef -1.000000e+00, double noundef 0.000000e+00, ptr noundef %13)
  %116 = icmp eq i32 %115, 1
  br i1 %116, label %117, label %126

117:                                              ; preds = %106
  call void @llvm.lifetime.start.p0(i64 2048, ptr %24) #5
  %118 = getelementptr inbounds [2048 x i8], ptr %24, i64 0, i64 0
  %119 = load ptr, ptr %8, align 8, !tbaa !5
  %120 = getelementptr inbounds %struct.nonlinear, ptr %119, i32 0, i32 45
  %121 = getelementptr inbounds [2048 x i8], ptr %120, i64 0, i64 0
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef %118, ptr noundef @.str.4, ptr noundef @.str.206, ptr noundef %121)
  %122 = load ptr, ptr %8, align 8, !tbaa !5
  %123 = getelementptr inbounds %struct.nonlinear, ptr %122, i32 0, i32 45
  %124 = getelementptr inbounds [2048 x i8], ptr %123, i64 0, i64 0
  %125 = getelementptr inbounds [2048 x i8], ptr %24, i64 0, i64 0
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef %124, ptr noundef @.str.3, ptr noundef @__func__.nonlinear_hmcode_dark_energy_correction, i32 noundef 3743, ptr noundef %125)
  call void @llvm.lifetime.end.p0(i64 2048, ptr %24) #5
  store i32 1, ptr %5, align 4
  store i32 1, ptr %20, align 4
  br label %161

126:                                              ; preds = %106
  %127 = load ptr, ptr %6, align 8, !tbaa !5
  %128 = load ptr, ptr %7, align 8, !tbaa !5
  %129 = load ptr, ptr %8, align 8, !tbaa !5
  %130 = load ptr, ptr %8, align 8, !tbaa !5
  %131 = getelementptr inbounds %struct.nonlinear, ptr %130, i32 0, i32 5
  %132 = load double, ptr %131, align 8, !tbaa !16
  %133 = fadd double 1.000000e+00, %132
  %134 = fdiv double 1.000000e+00, %133
  %135 = load double, ptr %15, align 8, !tbaa !18
  %136 = load double, ptr %16, align 8, !tbaa !18
  %137 = fmul double %136, -1.000000e+00
  %138 = call i32 @nonlinear_hmcode_growint(ptr noundef %127, ptr noundef %128, ptr noundef %129, double noundef %134, double noundef %135, double noundef %137, ptr noundef %14)
  %139 = icmp eq i32 %138, 1
  br i1 %139, label %140, label %149

140:                                              ; preds = %126
  call void @llvm.lifetime.start.p0(i64 2048, ptr %25) #5
  %141 = getelementptr inbounds [2048 x i8], ptr %25, i64 0, i64 0
  %142 = load ptr, ptr %8, align 8, !tbaa !5
  %143 = getelementptr inbounds %struct.nonlinear, ptr %142, i32 0, i32 45
  %144 = getelementptr inbounds [2048 x i8], ptr %143, i64 0, i64 0
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef %141, ptr noundef @.str.4, ptr noundef @.str.207, ptr noundef %144)
  %145 = load ptr, ptr %8, align 8, !tbaa !5
  %146 = getelementptr inbounds %struct.nonlinear, ptr %145, i32 0, i32 45
  %147 = getelementptr inbounds [2048 x i8], ptr %146, i64 0, i64 0
  %148 = getelementptr inbounds [2048 x i8], ptr %25, i64 0, i64 0
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef %147, ptr noundef @.str.3, ptr noundef @__func__.nonlinear_hmcode_dark_energy_correction, i32 noundef 3747, ptr noundef %148)
  call void @llvm.lifetime.end.p0(i64 2048, ptr %25) #5
  store i32 1, ptr %5, align 4
  store i32 1, ptr %20, align 4
  br label %161

149:                                              ; preds = %126
  %150 = load ptr, ptr %11, align 8, !tbaa !5
  call void @free(ptr noundef %150) #5
  %151 = load double, ptr %14, align 8, !tbaa !18
  %152 = load double, ptr %13, align 8, !tbaa !18
  %153 = fdiv double %151, %152
  %154 = call double @pow(double noundef %153, double noundef 1.500000e+00) #5
  %155 = load ptr, ptr %9, align 8, !tbaa !5
  %156 = getelementptr inbounds %struct.nonlinear_workspace, ptr %155, i32 0, i32 10
  store double %154, ptr %156, align 8, !tbaa !22
  br label %160

157:                                              ; preds = %4
  %158 = load ptr, ptr %9, align 8, !tbaa !5
  %159 = getelementptr inbounds %struct.nonlinear_workspace, ptr %158, i32 0, i32 10
  store double 1.000000e+00, ptr %159, align 8, !tbaa !22
  br label %160

160:                                              ; preds = %157, %149
  store i32 0, ptr %5, align 4
  store i32 1, ptr %20, align 4
  br label %161

161:                                              ; preds = %160, %140, %117, %97, %81, %60, %40
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #5
  %162 = load i32, ptr %5, align 4
  ret i32 %162
}

declare i32 @background_at_tau(ptr noundef, double noundef, i16 noundef signext, i16 noundef signext, ptr noundef, ptr noundef) #1

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

declare i32 @background_w_fld(ptr noundef, double noundef, ptr noundef, ptr noundef, ptr noundef) #1

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

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { "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 = { nounwind 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 #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 = { 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 }
attributes #6 = { nounwind 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, !13, i64 736}
!10 = !{!"background", !11, i64 0, !11, i64 8, !11, i64 16, !11, i64 24, !11, i64 32, !11, i64 40, !11, i64 48, !12, i64 56, !11, i64 64, !11, i64 72, !11, i64 80, !11, i64 88, !13, i64 96, !11, i64 104, !11, i64 112, !11, i64 120, !11, i64 128, !11, i64 136, !11, i64 144, !11, i64 152, !11, i64 160, !11, i64 168, !13, i64 176, !11, i64 184, !11, i64 192, !6, i64 200, !12, i64 208, !12, i64 212, !11, i64 216, !12, i64 224, !6, i64 232, !6, i64 240, !11, i64 248, !6, i64 256, !11, i64 264, !6, i64 272, !11, i64 280, !6, i64 288, !11, i64 296, !6, i64 304, !6, i64 312, !6, i64 320, !11, i64 328, !11, i64 336, !11, i64 344, !11, i64 352, !12, i64 360, !6, i64 368, !11, i64 376, !11, i64 384, !11, i64 392, !11, i64 400, !11, i64 408, !11, i64 416, !11, i64 424, !11, i64 432, !11, i64 440, !11, i64 448, !11, i64 456, !12, i64 464, !12, i64 468, !12, i64 472, !12, i64 476, !12, i64 480, !12, i64 484, !12, i64 488, !12, i64 492, !12, i64 496, !12, i64 500, !12, i64 504, !12, i64 508, !12, i64 512, !12, i64 516, !12, i64 520, !12, i64 524, !12, i64 528, !12, i64 532, !12, i64 536, !12, i64 540, !12, i64 544, !12, i64 548, !12, i64 552, !12, i64 556, !12, i64 560, !12, i64 564, !12, i64 568, !12, i64 572, !12, i64 576, !12, i64 580, !12, i64 584, !12, i64 588, !12, i64 592, !12, i64 596, !12, i64 600, !12, i64 604, !12, i64 608, !12, i64 612, !12, i64 616, !12, i64 620, !12, i64 624, !12, i64 628, !6, i64 632, !6, i64 640, !6, i64 648, !6, i64 656, !6, i64 664, !12, i64 672, !12, i64 676, !12, i64 680, !12, i64 684, !12, i64 688, !12, i64 692, !12, i64 696, !12, i64 700, !12, i64 704, !12, i64 708, !12, i64 712, !12, i64 716, !12, i64 720, !13, i64 724, !13, i64 726, !13, i64 728, !13, i64 730, !13, i64 732, !13, i64 734, !13, i64 736, !13, i64 738, !13, i64 740, !13, i64 742, !13, i64 744, !6, i64 752, !6, i64 760, !6, i64 768, !6, i64 776, !6, i64 784, !6, i64 792, !6, i64 800, !6, i64 808, !6, i64 816, !6, i64 824, !6, i64 832, !13, i64 840, !13, i64 842, !13, i64 844, !13, i64 846, !13, i64 848, !13, i64 850, !7, i64 852, !13, i64 2900, !7, i64 2902}
!11 = !{!"double", !7, i64 0}
!12 = !{!"int", !7, i64 0}
!13 = !{!"short", !7, i64 0}
!14 = !{!10, !12, i64 624}
!15 = !{!12, !12, i64 0}
!16 = !{!17, !11, i64 32}
!17 = !{!"nonlinear", !12, i64 0, !12, i64 4, !12, i64 8, !11, i64 16, !11, i64 24, !11, i64 32, !13, i64 40, !12, i64 44, !12, i64 48, !12, i64 52, !6, i64 56, !13, i64 64, !13, i64 66, !12, i64 68, !12, i64 72, !12, i64 76, !12, i64 80, !12, i64 84, !13, i64 88, !12, i64 92, !6, i64 96, !6, i64 104, !6, i64 112, !12, i64 120, !6, i64 128, !6, i64 136, !6, i64 144, !6, i64 152, !6, i64 160, !6, i64 168, !6, i64 176, !12, i64 184, !12, i64 188, !6, i64 192, !6, i64 200, !6, i64 208, !12, i64 216, !12, i64 220, !12, i64 224, !12, i64 228, !12, i64 232, !6, i64 240, !6, i64 248, !6, i64 256, !13, i64 264, !7, i64 266}
!18 = !{!11, !11, i64 0}
!19 = !{!10, !13, i64 844}
!20 = !{!10, !13, i64 846}
!21 = !{!10, !11, i64 456}
!22 = !{!23, !11, i64 80}
!23 = !{!"nonlinear_workspace", !6, i64 0, !6, i64 8, !6, i64 16, !6, i64 24, !6, i64 32, !6, i64 40, !6, i64 48, !6, i64 56, !6, i64 64, !6, i64 72, !11, i64 80}


; 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.3 = external hidden unnamed_addr constant [13 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [18 x i8], align 1
@.str.15 = external hidden unnamed_addr constant [35 x i8], align 1
@.str.79 = external hidden unnamed_addr constant [9 x i8], align 1
@__func__.nonlinear_hmcode_dark_energy_correction = external hidden unnamed_addr constant [40 x i8], align 1
@.str.203 = external hidden unnamed_addr constant [57 x i8], align 1
@.str.204 = external hidden unnamed_addr constant [88 x i8], align 1
@.str.205 = external hidden unnamed_addr constant [69 x i8], align 1
@.str.206 = external hidden unnamed_addr constant [77 x i8], align 1
@.str.207 = external hidden unnamed_addr constant [94 x i8], align 1

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

declare void @class_protect_sprintf(ptr noundef, ptr noundef, ...) local_unnamed_addr #1

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

declare i32 @background_tau_of_z(ptr noundef, double noundef, ptr noundef) local_unnamed_addr #1

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

; Function Attrs: mustprogress nounwind willreturn allockind("free") memory(argmem: readwrite, inaccessiblemem: readwrite)
declare void @free(ptr allocptr nocapture noundef) local_unnamed_addr #3

; Function Attrs: nounwind uwtable
define dso_local range(i32 0, 2) i32 @nonlinear_hmcode_dark_energy_correction(ptr noundef %0, ptr noundef %1, ptr noundef %2, ptr nocapture noundef writeonly %3) local_unnamed_addr #4 {
  %5 = alloca i32, align 4
  %6 = alloca double, align 8
  %7 = alloca double, align 8
  %8 = alloca double, align 8
  %9 = alloca double, align 8
  %10 = alloca double, align 8
  %11 = alloca double, align 8
  %12 = alloca [2048 x i8], align 16
  %13 = alloca [2048 x i8], align 16
  %14 = alloca [2048 x i8], align 16
  %15 = alloca [2048 x i8], align 16
  %16 = alloca [2048 x i8], align 16
  %17 = alloca [2048 x i8], align 16
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %5) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %6) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %7) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %8) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %9) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %10) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %11) #6
  %18 = getelementptr inbounds i8, ptr %1, i64 736
  %19 = load i16, ptr %18, align 8, !tbaa !5
  %20 = icmp eq i16 %19, 1
  br i1 %20, label %21, label %83

21:                                               ; preds = %4
  %22 = getelementptr inbounds i8, ptr %1, i64 624
  %23 = load i32, ptr %22, align 8, !tbaa !13
  %24 = sext i32 %23 to i64
  %25 = shl nsw i64 %24, 3
  %26 = tail call noalias ptr @malloc(i64 noundef %25) #7
  %27 = icmp eq ptr %26, null
  br i1 %27, label %28, label %31

28:                                               ; preds = %21
  %29 = shl i32 %23, 3
  call void @llvm.lifetime.start.p0(i64 2048, ptr nonnull %12) #6
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef nonnull %12, ptr noundef nonnull @.str.15, ptr noundef nonnull @.str.79, i32 noundef %29) #6
  %30 = getelementptr inbounds i8, ptr %2, i64 266
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef nonnull %30, ptr noundef nonnull @.str.3, ptr noundef nonnull @__func__.nonlinear_hmcode_dark_energy_correction, i32 noundef 3724, ptr noundef nonnull %12) #6
  call void @llvm.lifetime.end.p0(i64 2048, ptr nonnull %12) #6
  br label %85

31:                                               ; preds = %21
  %32 = getelementptr inbounds i8, ptr %2, i64 32
  %33 = load double, ptr %32, align 8, !tbaa !14
  %34 = call i32 @background_tau_of_z(ptr noundef nonnull %1, double noundef %33, ptr noundef nonnull %6) #6
  %35 = icmp eq i32 %34, 1
  br i1 %35, label %36, label %39

36:                                               ; preds = %31
  call void @llvm.lifetime.start.p0(i64 2048, ptr nonnull %13) #6
  %37 = getelementptr inbounds i8, ptr %1, i64 2902
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef nonnull %13, ptr noundef nonnull @.str.4, ptr noundef nonnull @.str.203, ptr noundef nonnull %37) #6
  %38 = getelementptr inbounds i8, ptr %2, i64 266
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef nonnull %38, ptr noundef nonnull @.str.3, ptr noundef nonnull @__func__.nonlinear_hmcode_dark_energy_correction, i32 noundef 3732, ptr noundef nonnull %13) #6
  call void @llvm.lifetime.end.p0(i64 2048, ptr nonnull %13) #6
  br label %85

39:                                               ; preds = %31
  %40 = load double, ptr %6, align 8, !tbaa !16
  %41 = getelementptr inbounds i8, ptr %1, i64 844
  %42 = load i16, ptr %41, align 4, !tbaa !17
  %43 = getelementptr inbounds i8, ptr %1, i64 846
  %44 = load i16, ptr %43, align 2, !tbaa !18
  %45 = call i32 @background_at_tau(ptr noundef nonnull %1, double noundef %40, i16 noundef signext %42, i16 noundef signext %44, ptr noundef nonnull %5, ptr noundef nonnull %26) #6
  %46 = icmp eq i32 %45, 1
  br i1 %46, label %47, label %50

47:                                               ; preds = %39
  call void @llvm.lifetime.start.p0(i64 2048, ptr nonnull %14) #6
  %48 = getelementptr inbounds i8, ptr %1, i64 2902
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef nonnull %14, ptr noundef nonnull @.str.4, ptr noundef nonnull @.str.204, ptr noundef nonnull %48) #6
  %49 = getelementptr inbounds i8, ptr %2, i64 266
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef nonnull %49, ptr noundef nonnull @.str.3, ptr noundef nonnull @__func__.nonlinear_hmcode_dark_energy_correction, i32 noundef 3736, ptr noundef nonnull %14) #6
  call void @llvm.lifetime.end.p0(i64 2048, ptr nonnull %14) #6
  br label %85

50:                                               ; preds = %39
  %51 = getelementptr inbounds i8, ptr %1, i64 456
  %52 = load double, ptr %51, align 8, !tbaa !19
  %53 = call i32 @background_w_fld(ptr noundef nonnull %1, double noundef %52, ptr noundef nonnull %9, ptr noundef nonnull %10, ptr noundef nonnull %11) #6
  %54 = icmp eq i32 %53, 1
  br i1 %54, label %55, label %58

55:                                               ; preds = %50
  call void @llvm.lifetime.start.p0(i64 2048, ptr nonnull %15) #6
  %56 = getelementptr inbounds i8, ptr %1, i64 2902
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef nonnull %15, ptr noundef nonnull @.str.4, ptr noundef nonnull @.str.205, ptr noundef nonnull %56) #6
  %57 = getelementptr inbounds i8, ptr %2, i64 266
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef nonnull %57, ptr noundef nonnull @.str.3, ptr noundef nonnull @__func__.nonlinear_hmcode_dark_energy_correction, i32 noundef 3740, ptr noundef nonnull %15) #6
  call void @llvm.lifetime.end.p0(i64 2048, ptr nonnull %15) #6
  br label %85

58:                                               ; preds = %50
  %59 = load double, ptr %32, align 8, !tbaa !14
  %60 = fadd double %59, 1.000000e+00
  %61 = fdiv double 1.000000e+00, %60
  %62 = call i32 @nonlinear_hmcode_growint(ptr noundef %0, ptr noundef nonnull %1, ptr noundef nonnull %2, double noundef %61, double noundef -1.000000e+00, double noundef 0.000000e+00, ptr noundef nonnull %7)
  %63 = icmp eq i32 %62, 1
  br i1 %63, label %64, label %66

64:                                               ; preds = %58
  call void @llvm.lifetime.start.p0(i64 2048, ptr nonnull %16) #6
  %65 = getelementptr inbounds i8, ptr %2, i64 266
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef nonnull %16, ptr noundef nonnull @.str.4, ptr noundef nonnull @.str.206, ptr noundef nonnull %65) #6
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef nonnull %65, ptr noundef nonnull @.str.3, ptr noundef nonnull @__func__.nonlinear_hmcode_dark_energy_correction, i32 noundef 3743, ptr noundef nonnull %16) #6
  call void @llvm.lifetime.end.p0(i64 2048, ptr nonnull %16) #6
  br label %85

66:                                               ; preds = %58
  %67 = load double, ptr %32, align 8, !tbaa !14
  %68 = fadd double %67, 1.000000e+00
  %69 = fdiv double 1.000000e+00, %68
  %70 = load double, ptr %9, align 8, !tbaa !16
  %71 = load double, ptr %10, align 8, !tbaa !16
  %72 = fneg double %71
  %73 = call i32 @nonlinear_hmcode_growint(ptr noundef %0, ptr noundef nonnull %1, ptr noundef nonnull %2, double noundef %69, double noundef %70, double noundef %72, ptr noundef nonnull %8)
  %74 = icmp eq i32 %73, 1
  br i1 %74, label %75, label %77

75:                                               ; preds = %66
  call void @llvm.lifetime.start.p0(i64 2048, ptr nonnull %17) #6
  %76 = getelementptr inbounds i8, ptr %2, i64 266
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef nonnull %17, ptr noundef nonnull @.str.4, ptr noundef nonnull @.str.207, ptr noundef nonnull %76) #6
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef nonnull %76, ptr noundef nonnull @.str.3, ptr noundef nonnull @__func__.nonlinear_hmcode_dark_energy_correction, i32 noundef 3747, ptr noundef nonnull %17) #6
  call void @llvm.lifetime.end.p0(i64 2048, ptr nonnull %17) #6
  br label %85

77:                                               ; preds = %66
  call void @free(ptr noundef nonnull %26) #6
  %78 = load double, ptr %8, align 8, !tbaa !16
  %79 = load double, ptr %7, align 8, !tbaa !16
  %80 = fdiv double %78, %79
  %81 = call double @pow(double noundef %80, double noundef 1.500000e+00) #6
  %82 = getelementptr inbounds i8, ptr %3, i64 80
  store double %81, ptr %82, align 8, !tbaa !20
  br label %85

83:                                               ; preds = %4
  %84 = getelementptr inbounds i8, ptr %3, i64 80
  store double 1.000000e+00, ptr %84, align 8, !tbaa !20
  br label %85

85:                                               ; preds = %77, %83, %75, %64, %55, %47, %36, %28
  %.0 = phi i32 [ 1, %28 ], [ 1, %36 ], [ 1, %47 ], [ 1, %55 ], [ 1, %64 ], [ 1, %75 ], [ 0, %83 ], [ 0, %77 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %11) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %10) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %9) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %5) #6
  ret i32 %.0
}

declare i32 @background_at_tau(ptr noundef, double noundef, i16 noundef signext, i16 noundef signext, ptr noundef, ptr noundef) local_unnamed_addr #1

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

declare i32 @background_w_fld(ptr noundef, double noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #1

; Function Attrs: nounwind uwtable
declare dso_local i32 @nonlinear_hmcode_growint(ptr noundef, ptr noundef, ptr noundef, double noundef, double noundef, double noundef, ptr noundef) local_unnamed_addr #4

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { "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 = { 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 #3 = { mustprogress nounwind willreturn allockind("free") memory(argmem: readwrite, 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 #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 = { 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 #6 = { nounwind }
attributes #7 = { nounwind 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, !11, i64 736}
!6 = !{!"background", !7, i64 0, !7, i64 8, !7, i64 16, !7, i64 24, !7, i64 32, !7, i64 40, !7, i64 48, !10, i64 56, !7, i64 64, !7, i64 72, !7, i64 80, !7, i64 88, !11, i64 96, !7, i64 104, !7, i64 112, !7, i64 120, !7, i64 128, !7, i64 136, !7, i64 144, !7, i64 152, !7, i64 160, !7, i64 168, !11, i64 176, !7, i64 184, !7, i64 192, !12, i64 200, !10, i64 208, !10, i64 212, !7, i64 216, !10, i64 224, !12, i64 232, !12, i64 240, !7, i64 248, !12, i64 256, !7, i64 264, !12, i64 272, !7, i64 280, !12, i64 288, !7, i64 296, !12, i64 304, !12, i64 312, !12, i64 320, !7, i64 328, !7, i64 336, !7, i64 344, !7, i64 352, !10, i64 360, !12, i64 368, !7, i64 376, !7, i64 384, !7, i64 392, !7, i64 400, !7, i64 408, !7, i64 416, !7, i64 424, !7, i64 432, !7, i64 440, !7, i64 448, !7, i64 456, !10, i64 464, !10, i64 468, !10, i64 472, !10, i64 476, !10, i64 480, !10, i64 484, !10, i64 488, !10, i64 492, !10, i64 496, !10, i64 500, !10, i64 504, !10, i64 508, !10, i64 512, !10, i64 516, !10, i64 520, !10, i64 524, !10, i64 528, !10, i64 532, !10, i64 536, !10, i64 540, !10, i64 544, !10, i64 548, !10, i64 552, !10, i64 556, !10, i64 560, !10, i64 564, !10, i64 568, !10, i64 572, !10, i64 576, !10, i64 580, !10, i64 584, !10, i64 588, !10, i64 592, !10, i64 596, !10, i64 600, !10, i64 604, !10, i64 608, !10, i64 612, !10, i64 616, !10, i64 620, !10, i64 624, !10, i64 628, !12, i64 632, !12, i64 640, !12, i64 648, !12, i64 656, !12, i64 664, !10, i64 672, !10, i64 676, !10, i64 680, !10, i64 684, !10, i64 688, !10, i64 692, !10, i64 696, !10, i64 700, !10, i64 704, !10, i64 708, !10, i64 712, !10, i64 716, !10, i64 720, !11, i64 724, !11, i64 726, !11, i64 728, !11, i64 730, !11, i64 732, !11, i64 734, !11, i64 736, !11, i64 738, !11, i64 740, !11, i64 742, !11, i64 744, !12, i64 752, !12, i64 760, !12, i64 768, !12, i64 776, !12, i64 784, !12, i64 792, !12, i64 800, !12, i64 808, !12, i64 816, !12, i64 824, !12, i64 832, !11, i64 840, !11, i64 842, !11, i64 844, !11, i64 846, !11, i64 848, !11, i64 850, !8, i64 852, !11, i64 2900, !8, i64 2902}
!7 = !{!"double", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C/C++ TBAA"}
!10 = !{!"int", !8, i64 0}
!11 = !{!"short", !8, i64 0}
!12 = !{!"any pointer", !8, i64 0}
!13 = !{!6, !10, i64 624}
!14 = !{!15, !7, i64 32}
!15 = !{!"nonlinear", !10, i64 0, !10, i64 4, !10, i64 8, !7, i64 16, !7, i64 24, !7, i64 32, !11, i64 40, !10, i64 44, !10, i64 48, !10, i64 52, !12, i64 56, !11, i64 64, !11, i64 66, !10, i64 68, !10, i64 72, !10, i64 76, !10, i64 80, !10, i64 84, !11, i64 88, !10, i64 92, !12, i64 96, !12, i64 104, !12, i64 112, !10, i64 120, !12, i64 128, !12, i64 136, !12, i64 144, !12, i64 152, !12, i64 160, !12, i64 168, !12, i64 176, !10, i64 184, !10, i64 188, !12, i64 192, !12, i64 200, !12, i64 208, !10, i64 216, !10, i64 220, !10, i64 224, !10, i64 228, !10, i64 232, !12, i64 240, !12, i64 248, !12, i64 256, !11, i64 264, !8, i64 266}
!16 = !{!7, !7, i64 0}
!17 = !{!6, !11, i64 844}
!18 = !{!6, !11, i64 846}
!19 = !{!6, !7, i64 456}
!20 = !{!21, !7, i64 80}
!21 = !{!"nonlinear_workspace", !12, i64 0, !12, i64 8, !12, i64 16, !12, i64 24, !12, i64 32, !12, i64 40, !12, i64 48, !12, i64 56, !12, i64 64, !12, i64 72, !7, i64 80}


; Effective O3 passes: CorrelatedValuePropagationPass,EarlyCSEPass,GlobalOptPass,IPSCCPPass,InferFunctionAttrsPass,InstCombinePass,PostOrderFunctionAttrsPass,SROAPass,SimplifyCFGPass,TailCallElimPass