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

; 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.recombination = type { i32, i32, i32, i32, i32, i32, i32, i32, ptr, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, i16, double, double, double, double, double, double, double }
%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] }

@.str = external hidden unnamed_addr constant [18 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [13 x i8], align 1
@.str.134 = external hidden unnamed_addr constant [85 x i8], align 1
@__func__.thermodynamics_energy_injection = external hidden unnamed_addr constant [32 x i8], align 1
@.str.135 = external hidden unnamed_addr constant [84 x i8], align 1
@.str.136 = external hidden unnamed_addr constant [81 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

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

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

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

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

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

; Function Attrs: nounwind
declare double @exp(double noundef) #1

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

; Function Attrs: nounwind uwtable
define dso_local i32 @thermodynamics_energy_injection(ptr noundef %0, ptr noundef %1, ptr noundef %2, double noundef %3, ptr noundef %4, ptr noundef %5) #4 {
  %7 = alloca i32, align 4
  %8 = alloca ptr, align 8
  %9 = alloca ptr, align 8
  %10 = alloca ptr, align 8
  %11 = alloca double, align 8
  %12 = alloca ptr, align 8
  %13 = alloca ptr, 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 double, align 8
  %22 = alloca [2048 x i8], align 16
  %23 = alloca i32, align 4
  %24 = alloca [2048 x i8], align 16
  %25 = alloca [2048 x i8], align 16
  %26 = alloca [2048 x i8], align 16
  store ptr %0, ptr %8, align 8, !tbaa !5
  store ptr %1, ptr %9, align 8, !tbaa !5
  store ptr %2, ptr %10, align 8, !tbaa !5
  store double %3, ptr %11, align 8, !tbaa !9
  store ptr %4, ptr %12, align 8, !tbaa !5
  store ptr %5, ptr %13, align 8, !tbaa !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
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %19) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %20) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %21) #5
  %27 = load ptr, ptr %10, align 8, !tbaa !5
  %28 = getelementptr inbounds %struct.recombination, ptr %27, i32 0, i32 28
  %29 = load double, ptr %28, align 8, !tbaa !11
  %30 = fcmp ogt double %29, 0.000000e+00
  br i1 %30, label %31, label %197

31:                                               ; preds = %6
  %32 = load ptr, ptr %10, align 8, !tbaa !5
  %33 = getelementptr inbounds %struct.recombination, ptr %32, i32 0, i32 29
  %34 = load i16, ptr %33, align 8, !tbaa !15
  %35 = sext i16 %34 to i32
  %36 = icmp eq i32 %35, 0
  br i1 %36, label %37, label %180

37:                                               ; preds = %31
  %38 = load ptr, ptr %10, align 8, !tbaa !5
  %39 = getelementptr inbounds %struct.recombination, ptr %38, i32 0, i32 26
  %40 = load double, ptr %39, align 8, !tbaa !16
  %41 = fmul double 3.000000e+00, %40
  %42 = load ptr, ptr %10, align 8, !tbaa !5
  %43 = getelementptr inbounds %struct.recombination, ptr %42, i32 0, i32 26
  %44 = load double, ptr %43, align 8, !tbaa !16
  %45 = fmul double %41, %44
  %46 = load ptr, ptr %9, align 8, !tbaa !5
  %47 = getelementptr inbounds %struct.background, ptr %46, i32 0, i32 3
  %48 = load double, ptr %47, align 8, !tbaa !17
  %49 = fmul double %45, %48
  %50 = fdiv double %49, 0x388DDA356D683EDB
  %51 = load ptr, ptr %10, align 8, !tbaa !5
  %52 = getelementptr inbounds %struct.recombination, ptr %51, i32 0, i32 27
  %53 = load double, ptr %52, align 8, !tbaa !19
  %54 = fsub double 1.000000e+00, %53
  %55 = fmul double %50, %54
  store double %55, ptr %20, align 8, !tbaa !9
  %56 = load double, ptr %20, align 8, !tbaa !9
  %57 = fmul double 0x3A15151E37FBF236, %56
  %58 = load ptr, ptr %9, align 8, !tbaa !5
  %59 = getelementptr inbounds %struct.background, ptr %58, i32 0, i32 0
  %60 = load double, ptr %59, align 8, !tbaa !20
  %61 = fdiv double %57, %60
  %62 = fmul double %61, 0x449A22FF260E3826
  %63 = load ptr, ptr %9, align 8, !tbaa !5
  %64 = getelementptr inbounds %struct.background, ptr %63, i32 0, i32 3
  %65 = load double, ptr %64, align 8, !tbaa !17
  %66 = load ptr, ptr %9, align 8, !tbaa !5
  %67 = getelementptr inbounds %struct.background, ptr %66, i32 0, i32 4
  %68 = load double, ptr %67, align 8, !tbaa !21
  %69 = fadd double %65, %68
  %70 = load ptr, ptr %9, align 8, !tbaa !5
  %71 = getelementptr inbounds %struct.background, ptr %70, i32 0, i32 17
  %72 = load double, ptr %71, align 8, !tbaa !22
  %73 = fadd double %69, %72
  %74 = call double @sqrt(double noundef %73) #5
  %75 = fdiv double %62, %74
  store double %75, ptr %18, align 8, !tbaa !9
  store double 1.000000e+00, ptr %15, align 8, !tbaa !9
  %76 = load double, ptr %11, align 8, !tbaa !9
  store double %76, ptr %14, align 8, !tbaa !9
  %77 = load ptr, ptr %8, align 8, !tbaa !5
  %78 = load ptr, ptr %9, align 8, !tbaa !5
  %79 = load ptr, ptr %10, align 8, !tbaa !5
  %80 = load double, ptr %14, align 8, !tbaa !9
  %81 = load ptr, ptr %13, align 8, !tbaa !5
  %82 = call i32 @thermodynamics_onthespot_energy_injection(ptr noundef %77, ptr noundef %78, ptr noundef %79, double noundef %80, ptr noundef %21, ptr noundef %81)
  %83 = icmp eq i32 %82, 1
  br i1 %83, label %84, label %89

84:                                               ; preds = %37
  call void @llvm.lifetime.start.p0(i64 2048, ptr %22) #5
  %85 = getelementptr inbounds [2048 x i8], ptr %22, i64 0, i64 0
  %86 = load ptr, ptr %13, align 8, !tbaa !5
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef %85, ptr noundef @.str, ptr noundef @.str.134, ptr noundef %86)
  %87 = load ptr, ptr %13, align 8, !tbaa !5
  %88 = getelementptr inbounds [2048 x i8], ptr %22, i64 0, i64 0
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef %87, ptr noundef @.str.2, ptr noundef @__func__.thermodynamics_energy_injection, i32 noundef 1872, ptr noundef %88)
  call void @llvm.lifetime.end.p0(i64 2048, ptr %22) #5
  store i32 1, ptr %7, align 4
  store i32 1, ptr %23, align 4
  br label %200

89:                                               ; preds = %37
  %90 = load double, ptr %18, align 8, !tbaa !9
  %91 = load double, ptr %11, align 8, !tbaa !9
  %92 = fadd double 1.000000e+00, %91
  %93 = call double @pow(double noundef %92, double noundef 8.000000e+00) #5
  %94 = fmul double %90, %93
  %95 = load double, ptr %14, align 8, !tbaa !9
  %96 = fadd double 1.000000e+00, %95
  %97 = call double @pow(double noundef %96, double noundef 7.500000e+00) #5
  %98 = fdiv double %94, %97
  %99 = load double, ptr %18, align 8, !tbaa !9
  %100 = fmul double 0x3FE5555555555555, %99
  %101 = load double, ptr %11, align 8, !tbaa !9
  %102 = fadd double 1.000000e+00, %101
  %103 = call double @pow(double noundef %102, double noundef 1.500000e+00) #5
  %104 = load double, ptr %14, align 8, !tbaa !9
  %105 = fadd double 1.000000e+00, %104
  %106 = call double @pow(double noundef %105, double noundef 1.500000e+00) #5
  %107 = fsub double %103, %106
  %108 = fmul double %100, %107
  %109 = call double @exp(double noundef %108) #5
  %110 = fmul double %98, %109
  %111 = load double, ptr %21, align 8, !tbaa !9
  %112 = fmul double %110, %111
  store double %112, ptr %17, align 8, !tbaa !9
  %113 = load double, ptr %15, align 8, !tbaa !9
  %114 = fmul double 5.000000e-01, %113
  %115 = load double, ptr %17, align 8, !tbaa !9
  %116 = fmul double %114, %115
  store double %116, ptr %19, align 8, !tbaa !9
  br label %117

117:                                              ; preds = %161, %89
  %118 = load double, ptr %15, align 8, !tbaa !9
  %119 = load double, ptr %14, align 8, !tbaa !9
  %120 = fadd double %119, %118
  store double %120, ptr %14, align 8, !tbaa !9
  %121 = load ptr, ptr %8, align 8, !tbaa !5
  %122 = load ptr, ptr %9, align 8, !tbaa !5
  %123 = load ptr, ptr %10, align 8, !tbaa !5
  %124 = load double, ptr %14, align 8, !tbaa !9
  %125 = load ptr, ptr %13, align 8, !tbaa !5
  %126 = call i32 @thermodynamics_onthespot_energy_injection(ptr noundef %121, ptr noundef %122, ptr noundef %123, double noundef %124, ptr noundef %21, ptr noundef %125)
  %127 = icmp eq i32 %126, 1
  br i1 %127, label %128, label %133

128:                                              ; preds = %117
  call void @llvm.lifetime.start.p0(i64 2048, ptr %24) #5
  %129 = getelementptr inbounds [2048 x i8], ptr %24, i64 0, i64 0
  %130 = load ptr, ptr %13, align 8, !tbaa !5
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef %129, ptr noundef @.str, ptr noundef @.str.134, ptr noundef %130)
  %131 = load ptr, ptr %13, align 8, !tbaa !5
  %132 = getelementptr inbounds [2048 x i8], ptr %24, i64 0, i64 0
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef %131, ptr noundef @.str.2, ptr noundef @__func__.thermodynamics_energy_injection, i32 noundef 1882, ptr noundef %132)
  call void @llvm.lifetime.end.p0(i64 2048, ptr %24) #5
  store i32 1, ptr %7, align 4
  store i32 1, ptr %23, align 4
  br label %200

133:                                              ; preds = %117
  %134 = load double, ptr %18, align 8, !tbaa !9
  %135 = load double, ptr %11, align 8, !tbaa !9
  %136 = fadd double 1.000000e+00, %135
  %137 = call double @pow(double noundef %136, double noundef 8.000000e+00) #5
  %138 = fmul double %134, %137
  %139 = load double, ptr %14, align 8, !tbaa !9
  %140 = fadd double 1.000000e+00, %139
  %141 = call double @pow(double noundef %140, double noundef 7.500000e+00) #5
  %142 = fdiv double %138, %141
  %143 = load double, ptr %18, align 8, !tbaa !9
  %144 = fmul double 0x3FE5555555555555, %143
  %145 = load double, ptr %11, align 8, !tbaa !9
  %146 = fadd double 1.000000e+00, %145
  %147 = call double @pow(double noundef %146, double noundef 1.500000e+00) #5
  %148 = load double, ptr %14, align 8, !tbaa !9
  %149 = fadd double 1.000000e+00, %148
  %150 = call double @pow(double noundef %149, double noundef 1.500000e+00) #5
  %151 = fsub double %147, %150
  %152 = fmul double %144, %151
  %153 = call double @exp(double noundef %152) #5
  %154 = fmul double %142, %153
  %155 = load double, ptr %21, align 8, !tbaa !9
  %156 = fmul double %154, %155
  store double %156, ptr %16, align 8, !tbaa !9
  %157 = load double, ptr %15, align 8, !tbaa !9
  %158 = load double, ptr %16, align 8, !tbaa !9
  %159 = load double, ptr %19, align 8, !tbaa !9
  %160 = call double @llvm.fmuladd.f64(double %157, double %158, double %159)
  store double %160, ptr %19, align 8, !tbaa !9
  br label %161

161:                                              ; preds = %133
  %162 = load double, ptr %16, align 8, !tbaa !9
  %163 = load double, ptr %17, align 8, !tbaa !9
  %164 = fdiv double %162, %163
  %165 = fcmp ogt double %164, 2.000000e-02
  br i1 %165, label %117, label %166, !llvm.loop !23

166:                                              ; preds = %161
  %167 = load ptr, ptr %8, align 8, !tbaa !5
  %168 = load ptr, ptr %9, align 8, !tbaa !5
  %169 = load ptr, ptr %10, align 8, !tbaa !5
  %170 = load double, ptr %11, align 8, !tbaa !9
  %171 = load ptr, ptr %13, align 8, !tbaa !5
  %172 = call i32 @thermodynamics_onthespot_energy_injection(ptr noundef %167, ptr noundef %168, ptr noundef %169, double noundef %170, ptr noundef %21, ptr noundef %171)
  %173 = icmp eq i32 %172, 1
  br i1 %173, label %174, label %179

174:                                              ; preds = %166
  call void @llvm.lifetime.start.p0(i64 2048, ptr %25) #5
  %175 = getelementptr inbounds [2048 x i8], ptr %25, i64 0, i64 0
  %176 = load ptr, ptr %13, align 8, !tbaa !5
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef %175, ptr noundef @.str, ptr noundef @.str.135, ptr noundef %176)
  %177 = load ptr, ptr %13, align 8, !tbaa !5
  %178 = getelementptr inbounds [2048 x i8], ptr %25, i64 0, i64 0
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef %177, ptr noundef @.str.2, ptr noundef @__func__.thermodynamics_energy_injection, i32 noundef 1891, ptr noundef %178)
  call void @llvm.lifetime.end.p0(i64 2048, ptr %25) #5
  store i32 1, ptr %7, align 4
  store i32 1, ptr %23, align 4
  br label %200

179:                                              ; preds = %166
  br label %194

180:                                              ; preds = %31
  %181 = load ptr, ptr %8, align 8, !tbaa !5
  %182 = load ptr, ptr %9, align 8, !tbaa !5
  %183 = load ptr, ptr %10, align 8, !tbaa !5
  %184 = load double, ptr %11, align 8, !tbaa !9
  %185 = load ptr, ptr %13, align 8, !tbaa !5
  %186 = call i32 @thermodynamics_onthespot_energy_injection(ptr noundef %181, ptr noundef %182, ptr noundef %183, double noundef %184, ptr noundef %19, ptr noundef %185)
  %187 = icmp eq i32 %186, 1
  br i1 %187, label %188, label %193

188:                                              ; preds = %180
  call void @llvm.lifetime.start.p0(i64 2048, ptr %26) #5
  %189 = getelementptr inbounds [2048 x i8], ptr %26, i64 0, i64 0
  %190 = load ptr, ptr %13, align 8, !tbaa !5
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef %189, ptr noundef @.str, ptr noundef @.str.136, ptr noundef %190)
  %191 = load ptr, ptr %13, align 8, !tbaa !5
  %192 = getelementptr inbounds [2048 x i8], ptr %26, i64 0, i64 0
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef %191, ptr noundef @.str.2, ptr noundef @__func__.thermodynamics_energy_injection, i32 noundef 1897, ptr noundef %192)
  call void @llvm.lifetime.end.p0(i64 2048, ptr %26) #5
  store i32 1, ptr %7, align 4
  store i32 1, ptr %23, align 4
  br label %200

193:                                              ; preds = %180
  br label %194

194:                                              ; preds = %193, %179
  %195 = load double, ptr %19, align 8, !tbaa !9
  %196 = load ptr, ptr %12, align 8, !tbaa !5
  store double %195, ptr %196, align 8, !tbaa !9
  br label %199

197:                                              ; preds = %6
  %198 = load ptr, ptr %12, align 8, !tbaa !5
  store double 0.000000e+00, ptr %198, align 8, !tbaa !9
  br label %199

199:                                              ; preds = %197, %194
  store i32 0, ptr %7, align 4
  store i32 1, ptr %23, align 4
  br label %200

200:                                              ; preds = %199, %188, %174, %128, %84
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #5
  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
  %201 = load i32, ptr %7, align 4
  ret i32 %201
}

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

!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 = !{!"double", !7, i64 0}
!11 = !{!12, !10, i64 192}
!12 = !{!"recombination", !13, i64 0, !13, i64 4, !13, i64 8, !13, i64 12, !13, i64 16, !13, i64 20, !13, i64 24, !13, i64 28, !6, i64 32, !10, i64 40, !10, i64 48, !10, i64 56, !10, i64 64, !10, i64 72, !10, i64 80, !10, i64 88, !10, i64 96, !10, i64 104, !10, i64 112, !10, i64 120, !10, i64 128, !10, i64 136, !10, i64 144, !10, i64 152, !10, i64 160, !10, i64 168, !10, i64 176, !10, i64 184, !10, i64 192, !14, i64 200, !10, i64 208, !10, i64 216, !10, i64 224, !10, i64 232, !10, i64 240, !10, i64 248, !10, i64 256}
!13 = !{!"int", !7, i64 0}
!14 = !{!"short", !7, i64 0}
!15 = !{!12, !14, i64 200}
!16 = !{!12, !10, i64 176}
!17 = !{!18, !10, i64 24}
!18 = !{!"background", !10, i64 0, !10, i64 8, !10, i64 16, !10, i64 24, !10, i64 32, !10, i64 40, !10, i64 48, !13, i64 56, !10, i64 64, !10, i64 72, !10, i64 80, !10, i64 88, !14, i64 96, !10, i64 104, !10, i64 112, !10, i64 120, !10, i64 128, !10, i64 136, !10, i64 144, !10, i64 152, !10, i64 160, !10, i64 168, !14, i64 176, !10, i64 184, !10, i64 192, !6, i64 200, !13, i64 208, !13, i64 212, !10, i64 216, !13, i64 224, !6, i64 232, !6, i64 240, !10, i64 248, !6, i64 256, !10, i64 264, !6, i64 272, !10, i64 280, !6, i64 288, !10, i64 296, !6, i64 304, !6, i64 312, !6, i64 320, !10, i64 328, !10, i64 336, !10, i64 344, !10, i64 352, !13, i64 360, !6, i64 368, !10, i64 376, !10, i64 384, !10, i64 392, !10, i64 400, !10, i64 408, !10, i64 416, !10, i64 424, !10, i64 432, !10, i64 440, !10, i64 448, !10, i64 456, !13, i64 464, !13, i64 468, !13, i64 472, !13, i64 476, !13, i64 480, !13, i64 484, !13, i64 488, !13, i64 492, !13, i64 496, !13, i64 500, !13, i64 504, !13, i64 508, !13, i64 512, !13, i64 516, !13, i64 520, !13, i64 524, !13, i64 528, !13, i64 532, !13, i64 536, !13, i64 540, !13, i64 544, !13, i64 548, !13, i64 552, !13, i64 556, !13, i64 560, !13, i64 564, !13, i64 568, !13, i64 572, !13, i64 576, !13, i64 580, !13, i64 584, !13, i64 588, !13, i64 592, !13, i64 596, !13, i64 600, !13, i64 604, !13, i64 608, !13, i64 612, !13, i64 616, !13, i64 620, !13, i64 624, !13, i64 628, !6, i64 632, !6, i64 640, !6, i64 648, !6, i64 656, !6, i64 664, !13, i64 672, !13, i64 676, !13, i64 680, !13, i64 684, !13, i64 688, !13, i64 692, !13, i64 696, !13, i64 700, !13, i64 704, !13, i64 708, !13, i64 712, !13, i64 716, !13, i64 720, !14, i64 724, !14, i64 726, !14, i64 728, !14, i64 730, !14, i64 732, !14, i64 734, !14, i64 736, !14, i64 738, !14, i64 740, !14, i64 742, !14, 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, !14, i64 840, !14, i64 842, !14, i64 844, !14, i64 846, !14, i64 848, !14, i64 850, !7, i64 852, !14, i64 2900, !7, i64 2902}
!19 = !{!12, !10, i64 184}
!20 = !{!18, !10, i64 0}
!21 = !{!18, !10, i64 32}
!22 = !{!18, !10, i64 136}
!23 = distinct !{!23, !24}
!24 = !{!"llvm.loop.mustprogress"}


; 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 [18 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [13 x i8], align 1
@.str.134 = external hidden unnamed_addr constant [85 x i8], align 1
@__func__.thermodynamics_energy_injection = external hidden unnamed_addr constant [32 x i8], align 1
@.str.135 = external hidden unnamed_addr constant [84 x i8], align 1
@.str.136 = external hidden unnamed_addr constant [81 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

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

declare void @class_protect_sprintf(ptr noundef, ptr 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) #0

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

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

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

; Function Attrs: nounwind uwtable
define dso_local range(i32 0, 2) i32 @thermodynamics_energy_injection(ptr noundef %0, ptr noundef %1, ptr noundef %2, double noundef %3, ptr nocapture noundef writeonly %4, ptr noundef %5) local_unnamed_addr #3 {
  %7 = alloca double, align 8
  %8 = alloca double, align 8
  %9 = alloca [2048 x i8], align 16
  %10 = alloca [2048 x i8], align 16
  %11 = alloca [2048 x i8], align 16
  %12 = alloca [2048 x i8], align 16
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %7) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %8) #4
  %13 = getelementptr inbounds i8, ptr %2, i64 192
  %14 = load double, ptr %13, align 8, !tbaa !5
  %15 = fcmp ogt double %14, 0.000000e+00
  br i1 %15, label %16, label %95

16:                                               ; preds = %6
  %17 = getelementptr inbounds i8, ptr %2, i64 200
  %18 = load i16, ptr %17, align 8, !tbaa !13
  %19 = icmp eq i16 %18, 0
  br i1 %19, label %20, label %91

20:                                               ; preds = %16
  %21 = getelementptr inbounds i8, ptr %2, i64 176
  %22 = load double, ptr %21, align 8, !tbaa !14
  %23 = fmul double %22, 3.000000e+00
  %24 = fmul double %22, %23
  %25 = getelementptr inbounds i8, ptr %1, i64 24
  %26 = load double, ptr %25, align 8, !tbaa !15
  %27 = fmul double %26, %24
  %28 = fdiv double %27, 0x388DDA356D683EDB
  %29 = getelementptr inbounds i8, ptr %2, i64 184
  %30 = load double, ptr %29, align 8, !tbaa !17
  %31 = fsub double 1.000000e+00, %30
  %32 = fmul double %31, %28
  %33 = fmul double %32, 0x3A15151E37FBF236
  %34 = load double, ptr %1, align 8, !tbaa !18
  %35 = fdiv double %33, %34
  %36 = fmul double %35, 0x449A22FF260E3826
  %37 = getelementptr inbounds i8, ptr %1, i64 32
  %38 = load double, ptr %37, align 8, !tbaa !19
  %39 = fadd double %26, %38
  %40 = getelementptr inbounds i8, ptr %1, i64 136
  %41 = load double, ptr %40, align 8, !tbaa !20
  %42 = fadd double %39, %41
  %43 = tail call double @sqrt(double noundef %42) #4
  %44 = fdiv double %36, %43
  %45 = call i32 @thermodynamics_onthespot_energy_injection(ptr noundef %0, ptr noundef nonnull %1, ptr noundef nonnull %2, double noundef %3, ptr noundef nonnull %8, ptr noundef %5)
  %46 = icmp eq i32 %45, 1
  br i1 %46, label %47, label %48

47:                                               ; preds = %20
  call void @llvm.lifetime.start.p0(i64 2048, ptr nonnull %9) #4
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef nonnull %9, ptr noundef nonnull @.str, ptr noundef nonnull @.str.134, ptr noundef %5) #4
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef %5, ptr noundef nonnull @.str.2, ptr noundef nonnull @__func__.thermodynamics_energy_injection, i32 noundef 1872, ptr noundef nonnull %9) #4
  call void @llvm.lifetime.end.p0(i64 2048, ptr nonnull %9) #4
  br label %96

48:                                               ; preds = %20
  %49 = fadd double %3, 1.000000e+00
  %50 = call double @pow(double noundef %49, double noundef 8.000000e+00) #4
  %51 = fmul double %44, %50
  %52 = call double @pow(double noundef %49, double noundef 7.500000e+00) #4
  %53 = fdiv double %51, %52
  %54 = fmul double %44, 0x3FE5555555555555
  %55 = call double @pow(double noundef %49, double noundef 1.500000e+00) #4
  %56 = call double @pow(double noundef %49, double noundef 1.500000e+00) #4
  %57 = fsub double %55, %56
  %58 = fmul double %54, %57
  %59 = call double @exp(double noundef %58) #4
  %60 = fmul double %53, %59
  %61 = load double, ptr %8, align 8, !tbaa !21
  %62 = fmul double %60, %61
  %63 = fmul double %62, 5.000000e-01
  br label %64

64:                                               ; preds = %70, %48
  %65 = phi double [ %63, %48 ], [ %84, %70 ]
  %.062 = phi double [ %3, %48 ], [ %66, %70 ]
  %66 = fadd double %.062, 1.000000e+00
  %67 = call i32 @thermodynamics_onthespot_energy_injection(ptr noundef %0, ptr noundef nonnull %1, ptr noundef %2, double noundef %66, ptr noundef nonnull %8, ptr noundef %5)
  %68 = icmp eq i32 %67, 1
  br i1 %68, label %69, label %70

69:                                               ; preds = %64
  call void @llvm.lifetime.start.p0(i64 2048, ptr nonnull %10) #4
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef nonnull %10, ptr noundef nonnull @.str, ptr noundef nonnull @.str.134, ptr noundef %5) #4
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef %5, ptr noundef nonnull @.str.2, ptr noundef nonnull @__func__.thermodynamics_energy_injection, i32 noundef 1882, ptr noundef nonnull %10) #4
  call void @llvm.lifetime.end.p0(i64 2048, ptr nonnull %10) #4
  br label %96

70:                                               ; preds = %64
  %71 = call double @pow(double noundef %49, double noundef 8.000000e+00) #4
  %72 = fmul double %44, %71
  %73 = fadd double %66, 1.000000e+00
  %74 = call double @pow(double noundef %73, double noundef 7.500000e+00) #4
  %75 = fdiv double %72, %74
  %76 = call double @pow(double noundef %49, double noundef 1.500000e+00) #4
  %77 = call double @pow(double noundef %73, double noundef 1.500000e+00) #4
  %78 = fsub double %76, %77
  %79 = fmul double %54, %78
  %80 = call double @exp(double noundef %79) #4
  %81 = fmul double %75, %80
  %82 = load double, ptr %8, align 8, !tbaa !21
  %83 = fmul double %81, %82
  %84 = fadd double %83, %65
  %85 = fdiv double %83, %62
  %86 = fcmp ogt double %85, 2.000000e-02
  br i1 %86, label %64, label %87, !llvm.loop !22

87:                                               ; preds = %70
  %88 = call i32 @thermodynamics_onthespot_energy_injection(ptr noundef %0, ptr noundef nonnull %1, ptr noundef %2, double noundef %3, ptr noundef nonnull %8, ptr noundef %5)
  %89 = icmp eq i32 %88, 1
  br i1 %89, label %90, label %95

90:                                               ; preds = %87
  call void @llvm.lifetime.start.p0(i64 2048, ptr nonnull %11) #4
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef nonnull %11, ptr noundef nonnull @.str, ptr noundef nonnull @.str.135, ptr noundef %5) #4
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef %5, ptr noundef nonnull @.str.2, ptr noundef nonnull @__func__.thermodynamics_energy_injection, i32 noundef 1891, ptr noundef nonnull %11) #4
  call void @llvm.lifetime.end.p0(i64 2048, ptr nonnull %11) #4
  br label %96

91:                                               ; preds = %16
  %92 = call i32 @thermodynamics_onthespot_energy_injection(ptr noundef %0, ptr noundef %1, ptr noundef nonnull %2, double noundef %3, ptr noundef nonnull %7, ptr noundef %5)
  %93 = icmp eq i32 %92, 1
  br i1 %93, label %94, label %._crit_edge

._crit_edge:                                      ; preds = %91
  %.pre = load double, ptr %7, align 8, !tbaa !21
  br label %95

94:                                               ; preds = %91
  call void @llvm.lifetime.start.p0(i64 2048, ptr nonnull %12) #4
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef nonnull %12, ptr noundef nonnull @.str, ptr noundef nonnull @.str.136, ptr noundef %5) #4
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef %5, ptr noundef nonnull @.str.2, ptr noundef nonnull @__func__.thermodynamics_energy_injection, i32 noundef 1897, ptr noundef nonnull %12) #4
  call void @llvm.lifetime.end.p0(i64 2048, ptr nonnull %12) #4
  br label %96

95:                                               ; preds = %87, %._crit_edge, %6
  %storemerge = phi double [ 0.000000e+00, %6 ], [ %.pre, %._crit_edge ], [ %84, %87 ]
  store double %storemerge, ptr %4, align 8, !tbaa !21
  br label %96

96:                                               ; preds = %95, %94, %90, %69, %47
  %.0 = phi i32 [ 1, %47 ], [ 1, %69 ], [ 1, %90 ], [ 0, %95 ], [ 1, %94 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #4
  ret i32 %.0
}

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { 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 #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 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 }

!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 192}
!6 = !{!"recombination", !7, i64 0, !7, i64 4, !7, i64 8, !7, i64 12, !7, i64 16, !7, i64 20, !7, i64 24, !7, i64 28, !10, i64 32, !11, i64 40, !11, i64 48, !11, i64 56, !11, i64 64, !11, i64 72, !11, i64 80, !11, i64 88, !11, 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, !11, i64 176, !11, i64 184, !11, i64 192, !12, i64 200, !11, i64 208, !11, i64 216, !11, i64 224, !11, i64 232, !11, i64 240, !11, i64 248, !11, i64 256}
!7 = !{!"int", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C/C++ TBAA"}
!10 = !{!"any pointer", !8, i64 0}
!11 = !{!"double", !8, i64 0}
!12 = !{!"short", !8, i64 0}
!13 = !{!6, !12, i64 200}
!14 = !{!6, !11, i64 176}
!15 = !{!16, !11, i64 24}
!16 = !{!"background", !11, i64 0, !11, i64 8, !11, i64 16, !11, i64 24, !11, i64 32, !11, i64 40, !11, i64 48, !7, i64 56, !11, i64 64, !11, i64 72, !11, i64 80, !11, i64 88, !12, 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, !12, i64 176, !11, i64 184, !11, i64 192, !10, i64 200, !7, i64 208, !7, i64 212, !11, i64 216, !7, i64 224, !10, i64 232, !10, i64 240, !11, i64 248, !10, i64 256, !11, i64 264, !10, i64 272, !11, i64 280, !10, i64 288, !11, i64 296, !10, i64 304, !10, i64 312, !10, i64 320, !11, i64 328, !11, i64 336, !11, i64 344, !11, i64 352, !7, i64 360, !10, 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, !7, i64 464, !7, i64 468, !7, i64 472, !7, i64 476, !7, i64 480, !7, i64 484, !7, i64 488, !7, i64 492, !7, i64 496, !7, i64 500, !7, i64 504, !7, i64 508, !7, i64 512, !7, i64 516, !7, i64 520, !7, i64 524, !7, i64 528, !7, i64 532, !7, i64 536, !7, i64 540, !7, i64 544, !7, i64 548, !7, i64 552, !7, i64 556, !7, i64 560, !7, i64 564, !7, i64 568, !7, i64 572, !7, i64 576, !7, i64 580, !7, i64 584, !7, i64 588, !7, i64 592, !7, i64 596, !7, i64 600, !7, i64 604, !7, i64 608, !7, i64 612, !7, i64 616, !7, i64 620, !7, i64 624, !7, i64 628, !10, i64 632, !10, i64 640, !10, i64 648, !10, i64 656, !10, i64 664, !7, i64 672, !7, i64 676, !7, i64 680, !7, i64 684, !7, i64 688, !7, i64 692, !7, i64 696, !7, i64 700, !7, i64 704, !7, i64 708, !7, i64 712, !7, i64 716, !7, i64 720, !12, i64 724, !12, i64 726, !12, i64 728, !12, i64 730, !12, i64 732, !12, i64 734, !12, i64 736, !12, i64 738, !12, i64 740, !12, i64 742, !12, i64 744, !10, i64 752, !10, i64 760, !10, i64 768, !10, i64 776, !10, i64 784, !10, i64 792, !10, i64 800, !10, i64 808, !10, i64 816, !10, i64 824, !10, i64 832, !12, i64 840, !12, i64 842, !12, i64 844, !12, i64 846, !12, i64 848, !12, i64 850, !8, i64 852, !12, i64 2900, !8, i64 2902}
!17 = !{!6, !11, i64 184}
!18 = !{!16, !11, i64 0}
!19 = !{!16, !11, i64 32}
!20 = !{!16, !11, i64 136}
!21 = !{!11, !11, i64 0}
!22 = distinct !{!22, !23}
!23 = !{!"llvm.loop.mustprogress"}


; Effective O3 passes: CorrelatedValuePropagationPass,DSEPass,EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,JumpThreadingPass,LCSSAPass,LoopUnrollPass,PostOrderFunctionAttrsPass,ReassociatePass,SROAPass,SimplifyCFGPass,TailCallElimPass