; LLVM IR from zhenrong-wang/co2 :: co2_property_calc (td_ph)

; 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.co2_prop = type { double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double }

@__const.td_ph.tau_ini = external hidden unnamed_addr constant [10 x double], align 16
@__const.td_ph.del_ini = external hidden unnamed_addr constant [12 x double], align 16

; Function Attrs: nounwind uwtable
declare dso_local i32 @is_vld_prop(ptr noundef) #0

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i1 @llvm.is.fpclass.f64(double, i32 immarg) #1

; Function Attrs: nounwind uwtable
declare dso_local void @co2_prop_calc_tr(ptr noundef, double noundef, double noundef) #0

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

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

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

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

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #3

; Function Attrs: nounwind uwtable
declare dso_local void @calcfg_dfg_ph(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, double noundef, double noundef, double noundef, double noundef) #0

; Function Attrs: nounwind uwtable
define dso_local i32 @td_ph(ptr noundef %0, ptr noundef %1, double noundef %2, double noundef %3) #0 {
  %5 = alloca i32, align 4
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  %8 = alloca double, align 8
  %9 = alloca double, align 8
  %10 = alloca double, align 8
  %11 = alloca double, align 8
  %12 = alloca double, align 8
  %13 = alloca double, align 8
  %14 = alloca double, align 8
  %15 = alloca double, align 8
  %16 = alloca i32, align 4
  %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 double, align 8
  %23 = alloca i32, align 4
  %24 = alloca i32, align 4
  %25 = alloca i32, align 4
  %26 = alloca double, align 8
  %27 = alloca double, align 8
  %28 = alloca double, align 8
  %29 = alloca double, align 8
  %30 = alloca %struct.co2_prop, align 8
  %31 = alloca [10 x double], align 16
  %32 = alloca [12 x double], align 16
  %33 = alloca i32, align 4
  store ptr %0, ptr %6, align 8, !tbaa !5
  store ptr %1, ptr %7, align 8, !tbaa !5
  store double %2, ptr %8, align 8, !tbaa !9
  store double %3, ptr %9, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr %16) #4
  store i32 0, ptr %16, align 4, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %19) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %20) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %21) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %22) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr %23) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr %24) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr %25) #4
  store i32 0, ptr %25, align 4, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 8, ptr %26) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %27) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %28) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %29) #4
  call void @llvm.lifetime.start.p0(i64 128, ptr %30) #4
  call void @llvm.lifetime.start.p0(i64 80, ptr %31) #4
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 %31, ptr align 16 @__const.td_ph.tau_ini, i64 80, i1 false)
  call void @llvm.lifetime.start.p0(i64 96, ptr %32) #4
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 %32, ptr align 16 @__const.td_ph.del_ini, i64 96, i1 false)
  store i32 0, ptr %23, align 4, !tbaa !11
  br label %34

34:                                               ; preds = %234, %4
  %35 = load i32, ptr %23, align 4, !tbaa !11
  %36 = icmp slt i32 %35, 10
  br i1 %36, label %37, label %237

37:                                               ; preds = %34
  store i32 0, ptr %24, align 4, !tbaa !11
  br label %38

38:                                               ; preds = %230, %37
  %39 = load i32, ptr %24, align 4, !tbaa !11
  %40 = icmp slt i32 %39, 12
  br i1 %40, label %41, label %233

41:                                               ; preds = %38
  %42 = load i32, ptr %16, align 4, !tbaa !11
  %43 = sext i32 %42 to i64
  %44 = getelementptr inbounds [12 x double], ptr %32, i64 0, i64 %43
  %45 = load double, ptr %44, align 8, !tbaa !9
  store double %45, ptr %29, align 8, !tbaa !9
  %46 = load i32, ptr %23, align 4, !tbaa !11
  %47 = sext i32 %46 to i64
  %48 = getelementptr inbounds [10 x double], ptr %31, i64 0, i64 %47
  %49 = load double, ptr %48, align 8, !tbaa !9
  %50 = load double, ptr %29, align 8, !tbaa !9
  %51 = load double, ptr %8, align 8, !tbaa !9
  %52 = load double, ptr %9, align 8, !tbaa !9
  call void @calcfg_dfg_ph(ptr noundef %17, ptr noundef %18, ptr noundef %19, ptr noundef %21, ptr noundef %20, ptr noundef %22, double noundef %49, double noundef %50, double noundef %51, double noundef %52)
  %53 = load double, ptr %21, align 8, !tbaa !9
  %54 = load double, ptr %20, align 8, !tbaa !9
  %55 = load double, ptr %19, align 8, !tbaa !9
  %56 = load double, ptr %22, align 8, !tbaa !9
  %57 = fmul double %55, %56
  %58 = fneg double %57
  %59 = call double @llvm.fmuladd.f64(double %53, double %54, double %58)
  %60 = call double @llvm.fabs.f64(double %59)
  %61 = fcmp olt double %60, 0x3EB0C6F7A0B5ED8D
  br i1 %61, label %62, label %63

62:                                               ; preds = %41
  br label %230

63:                                               ; preds = %41
  %64 = load double, ptr %18, align 8, !tbaa !9
  %65 = load double, ptr %19, align 8, !tbaa !9
  %66 = load double, ptr %17, align 8, !tbaa !9
  %67 = load double, ptr %20, align 8, !tbaa !9
  %68 = fmul double %66, %67
  %69 = fneg double %68
  %70 = call double @llvm.fmuladd.f64(double %64, double %65, double %69)
  %71 = load double, ptr %21, align 8, !tbaa !9
  %72 = load double, ptr %20, align 8, !tbaa !9
  %73 = load double, ptr %22, align 8, !tbaa !9
  %74 = load double, ptr %19, align 8, !tbaa !9
  %75 = fmul double %73, %74
  %76 = fneg double %75
  %77 = call double @llvm.fmuladd.f64(double %71, double %72, double %76)
  %78 = fdiv double %70, %77
  store double %78, ptr %27, align 8, !tbaa !9
  %79 = load double, ptr %18, align 8, !tbaa !9
  %80 = load double, ptr %21, align 8, !tbaa !9
  %81 = load double, ptr %17, align 8, !tbaa !9
  %82 = load double, ptr %22, align 8, !tbaa !9
  %83 = fmul double %81, %82
  %84 = fneg double %83
  %85 = call double @llvm.fmuladd.f64(double %79, double %80, double %84)
  %86 = load double, ptr %19, align 8, !tbaa !9
  %87 = load double, ptr %22, align 8, !tbaa !9
  %88 = load double, ptr %20, align 8, !tbaa !9
  %89 = load double, ptr %21, align 8, !tbaa !9
  %90 = fmul double %88, %89
  %91 = fneg double %90
  %92 = call double @llvm.fmuladd.f64(double %86, double %87, double %91)
  %93 = fdiv double %85, %92
  store double %93, ptr %26, align 8, !tbaa !9
  %94 = load i32, ptr %23, align 4, !tbaa !11
  %95 = sext i32 %94 to i64
  %96 = getelementptr inbounds [10 x double], ptr %31, i64 0, i64 %95
  %97 = load double, ptr %96, align 8, !tbaa !9
  %98 = load double, ptr %26, align 8, !tbaa !9
  %99 = fadd double %97, %98
  store double %99, ptr %11, align 8, !tbaa !9
  %100 = load i32, ptr %24, align 4, !tbaa !11
  %101 = sext i32 %100 to i64
  %102 = getelementptr inbounds [12 x double], ptr %32, i64 0, i64 %101
  %103 = load double, ptr %102, align 8, !tbaa !9
  %104 = load double, ptr %27, align 8, !tbaa !9
  %105 = fadd double %103, %104
  store double %105, ptr %13, align 8, !tbaa !9
  store i32 0, ptr %25, align 4, !tbaa !11
  store i32 0, ptr %16, align 4, !tbaa !11
  br label %106

106:                                              ; preds = %180, %63
  %107 = load double, ptr %11, align 8, !tbaa !9
  store double %107, ptr %10, align 8, !tbaa !9
  %108 = load double, ptr %13, align 8, !tbaa !9
  store double %108, ptr %12, align 8, !tbaa !9
  %109 = load double, ptr %10, align 8, !tbaa !9
  %110 = load double, ptr %12, align 8, !tbaa !9
  %111 = load double, ptr %8, align 8, !tbaa !9
  %112 = load double, ptr %9, align 8, !tbaa !9
  call void @calcfg_dfg_ph(ptr noundef %17, ptr noundef %18, ptr noundef %19, ptr noundef %21, ptr noundef %20, ptr noundef %22, double noundef %109, double noundef %110, double noundef %111, double noundef %112)
  %113 = load double, ptr %21, align 8, !tbaa !9
  %114 = load double, ptr %20, align 8, !tbaa !9
  %115 = load double, ptr %19, align 8, !tbaa !9
  %116 = load double, ptr %22, align 8, !tbaa !9
  %117 = fmul double %115, %116
  %118 = fneg double %117
  %119 = call double @llvm.fmuladd.f64(double %113, double %114, double %118)
  %120 = call double @llvm.fabs.f64(double %119)
  %121 = fcmp olt double %120, 0x3EB0C6F7A0B5ED8D
  br i1 %121, label %122, label %123

122:                                              ; preds = %106
  store i32 -1, ptr %25, align 4, !tbaa !11
  br label %182

123:                                              ; preds = %106
  %124 = load double, ptr %18, align 8, !tbaa !9
  %125 = load double, ptr %19, align 8, !tbaa !9
  %126 = load double, ptr %17, align 8, !tbaa !9
  %127 = load double, ptr %20, align 8, !tbaa !9
  %128 = fmul double %126, %127
  %129 = fneg double %128
  %130 = call double @llvm.fmuladd.f64(double %124, double %125, double %129)
  %131 = load double, ptr %21, align 8, !tbaa !9
  %132 = load double, ptr %20, align 8, !tbaa !9
  %133 = load double, ptr %22, align 8, !tbaa !9
  %134 = load double, ptr %19, align 8, !tbaa !9
  %135 = fmul double %133, %134
  %136 = fneg double %135
  %137 = call double @llvm.fmuladd.f64(double %131, double %132, double %136)
  %138 = fdiv double %130, %137
  store double %138, ptr %27, align 8, !tbaa !9
  %139 = load double, ptr %18, align 8, !tbaa !9
  %140 = load double, ptr %21, align 8, !tbaa !9
  %141 = load double, ptr %17, align 8, !tbaa !9
  %142 = load double, ptr %22, align 8, !tbaa !9
  %143 = fmul double %141, %142
  %144 = fneg double %143
  %145 = call double @llvm.fmuladd.f64(double %139, double %140, double %144)
  %146 = load double, ptr %19, align 8, !tbaa !9
  %147 = load double, ptr %22, align 8, !tbaa !9
  %148 = load double, ptr %20, align 8, !tbaa !9
  %149 = load double, ptr %21, align 8, !tbaa !9
  %150 = fmul double %148, %149
  %151 = fneg double %150
  %152 = call double @llvm.fmuladd.f64(double %146, double %147, double %151)
  %153 = fdiv double %145, %152
  store double %153, ptr %26, align 8, !tbaa !9
  %154 = load double, ptr %10, align 8, !tbaa !9
  %155 = load double, ptr %26, align 8, !tbaa !9
  %156 = fadd double %154, %155
  store double %156, ptr %11, align 8, !tbaa !9
  %157 = load double, ptr %12, align 8, !tbaa !9
  %158 = load double, ptr %27, align 8, !tbaa !9
  %159 = fadd double %157, %158
  store double %159, ptr %13, align 8, !tbaa !9
  %160 = load double, ptr %26, align 8, !tbaa !9
  %161 = call double @llvm.fabs.f64(double %160)
  %162 = load double, ptr %27, align 8, !tbaa !9
  %163 = call double @llvm.fabs.f64(double %162)
  %164 = fcmp ogt double %161, %163
  br i1 %164, label %165, label %168

165:                                              ; preds = %123
  %166 = load double, ptr %26, align 8, !tbaa !9
  %167 = call double @llvm.fabs.f64(double %166)
  store double %167, ptr %28, align 8, !tbaa !9
  br label %171

168:                                              ; preds = %123
  %169 = load double, ptr %27, align 8, !tbaa !9
  %170 = call double @llvm.fabs.f64(double %169)
  store double %170, ptr %28, align 8, !tbaa !9
  br label %171

171:                                              ; preds = %168, %165
  %172 = load i32, ptr %16, align 4, !tbaa !11
  %173 = add nsw i32 %172, 1
  store i32 %173, ptr %16, align 4, !tbaa !11
  br label %174

174:                                              ; preds = %171
  %175 = load double, ptr %28, align 8, !tbaa !9
  %176 = fcmp ogt double %175, 0x3EB0C6F7A0B5ED8D
  br i1 %176, label %177, label %180

177:                                              ; preds = %174
  %178 = load i32, ptr %16, align 4, !tbaa !11
  %179 = icmp slt i32 %178, 100
  br label %180

180:                                              ; preds = %177, %174
  %181 = phi i1 [ false, %174 ], [ %179, %177 ]
  br i1 %181, label %106, label %182, !llvm.loop !13

182:                                              ; preds = %180, %122
  %183 = load i32, ptr %16, align 4, !tbaa !11
  %184 = icmp eq i32 %183, 100
  br i1 %184, label %188, label %185

185:                                              ; preds = %182
  %186 = load i32, ptr %25, align 4, !tbaa !11
  %187 = icmp eq i32 %186, -1
  br i1 %187, label %188, label %189

188:                                              ; preds = %185, %182
  br label %230

189:                                              ; preds = %185
  %190 = load double, ptr %11, align 8, !tbaa !9
  %191 = call i1 @llvm.is.fpclass.f64(double %190, i32 3)
  br i1 %191, label %228, label %192

192:                                              ; preds = %189
  %193 = load double, ptr %13, align 8, !tbaa !9
  %194 = call i1 @llvm.is.fpclass.f64(double %193, i32 3)
  br i1 %194, label %228, label %195

195:                                              ; preds = %192
  %196 = load double, ptr %11, align 8, !tbaa !9
  %197 = fdiv double 0x4073020D1B71758E, %196
  store double %197, ptr %14, align 8, !tbaa !9
  %198 = load double, ptr %13, align 8, !tbaa !9
  %199 = fmul double 4.676000e+02, %198
  store double %199, ptr %15, align 8, !tbaa !9
  %200 = load double, ptr %14, align 8, !tbaa !9
  %201 = load double, ptr %15, align 8, !tbaa !9
  call void @co2_prop_calc_tr(ptr noundef %30, double noundef %200, double noundef %201)
  %202 = call i32 @is_vld_prop(ptr noundef %30)
  %203 = icmp eq i32 %202, 0
  br i1 %203, label %204, label %227

204:                                              ; preds = %195
  %205 = load double, ptr %8, align 8, !tbaa !9
  %206 = getelementptr inbounds %struct.co2_prop, ptr %30, i32 0, i32 0
  %207 = load double, ptr %206, align 8, !tbaa !15
  %208 = fsub double %205, %207
  %209 = call double @llvm.fabs.f64(double %208)
  %210 = load double, ptr %8, align 8, !tbaa !9
  %211 = fdiv double %209, %210
  %212 = fcmp olt double %211, 1.000000e-04
  br i1 %212, label %213, label %227

213:                                              ; preds = %204
  %214 = load double, ptr %9, align 8, !tbaa !9
  %215 = getelementptr inbounds %struct.co2_prop, ptr %30, i32 0, i32 7
  %216 = load double, ptr %215, align 8, !tbaa !17
  %217 = fsub double %214, %216
  %218 = load double, ptr %9, align 8, !tbaa !9
  %219 = fdiv double %217, %218
  %220 = call double @llvm.fabs.f64(double %219)
  %221 = fcmp olt double %220, 1.000000e-04
  br i1 %221, label %222, label %227

222:                                              ; preds = %213
  %223 = load double, ptr %14, align 8, !tbaa !9
  %224 = load ptr, ptr %6, align 8, !tbaa !5
  store double %223, ptr %224, align 8, !tbaa !9
  %225 = load double, ptr %15, align 8, !tbaa !9
  %226 = load ptr, ptr %7, align 8, !tbaa !5
  store double %225, ptr %226, align 8, !tbaa !9
  store i32 0, ptr %5, align 4
  store i32 1, ptr %33, align 4
  br label %238

227:                                              ; preds = %213, %204, %195
  br label %230

228:                                              ; preds = %192, %189
  br label %229

229:                                              ; preds = %228
  br label %230

230:                                              ; preds = %229, %227, %188, %62
  %231 = load i32, ptr %24, align 4, !tbaa !11
  %232 = add nsw i32 %231, 1
  store i32 %232, ptr %24, align 4, !tbaa !11
  br label %38, !llvm.loop !18

233:                                              ; preds = %38
  br label %234

234:                                              ; preds = %233
  %235 = load i32, ptr %23, align 4, !tbaa !11
  %236 = add nsw i32 %235, 1
  store i32 %236, ptr %23, align 4, !tbaa !11
  br label %34, !llvm.loop !19

237:                                              ; preds = %34
  store i32 -1, ptr %5, align 4
  store i32 1, ptr %33, align 4
  br label %238

238:                                              ; preds = %237, %222
  call void @llvm.lifetime.end.p0(i64 96, ptr %32) #4
  call void @llvm.lifetime.end.p0(i64 80, ptr %31) #4
  call void @llvm.lifetime.end.p0(i64 128, ptr %30) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %29) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %28) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %27) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %26) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %25) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %24) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %23) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #4
  %239 = load i32, ptr %5, align 4
  ret i32 %239
}

attributes #0 = { nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #2 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #3 = { nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #4 = { nounwind }

!llvm.module.flags = !{!0, !1, !2, !3}
!llvm.ident = !{!4}

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"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, !12, i64 0}
!12 = !{!"int", !7, i64 0}
!13 = distinct !{!13, !14}
!14 = !{!"llvm.loop.mustprogress"}
!15 = !{!16, !10, i64 0}
!16 = !{!"", !10, i64 0, !10, i64 8, !10, i64 16, !10, i64 24, !10, 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}
!17 = !{!16, !10, i64 56}
!18 = distinct !{!18, !14}
!19 = distinct !{!19, !14}


; Optimized IR (opt -passes='default<O3>'):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

%struct.co2_prop = type { double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double }

@__const.td_ph.tau_ini = external hidden unnamed_addr constant [10 x double], align 16
@__const.td_ph.del_ini = external hidden unnamed_addr constant [12 x double], align 16

; Function Attrs: nounwind uwtable
declare dso_local i32 @is_vld_prop(ptr noundef) local_unnamed_addr #0

; Function Attrs: nounwind uwtable
declare dso_local void @co2_prop_calc_tr(ptr noundef, double noundef, double noundef) local_unnamed_addr #0

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

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

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

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

; Function Attrs: nounwind uwtable
declare dso_local void @calcfg_dfg_ph(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, double noundef, double noundef, double noundef, double noundef) local_unnamed_addr #0

; Function Attrs: nounwind uwtable
define dso_local range(i32 -1, 1) i32 @td_ph(ptr nocapture noundef writeonly %0, ptr nocapture noundef writeonly %1, double noundef %2, double noundef %3) local_unnamed_addr #0 {
  %5 = alloca double, align 8
  %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 %struct.co2_prop, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %5) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %6) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %7) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %8) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %9) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %10) #4
  call void @llvm.lifetime.start.p0(i64 128, ptr nonnull %11) #4
  %12 = getelementptr inbounds i8, ptr %11, i64 56
  br label %.preheader

.preheader:                                       ; preds = %4, %120
  %indvars.iv85 = phi i64 [ 0, %4 ], [ %indvars.iv.next86, %120 ]
  %.05176 = phi i32 [ 0, %4 ], [ %.4, %120 ]
  %13 = getelementptr inbounds [10 x double], ptr @__const.td_ph.tau_ini, i64 0, i64 %indvars.iv85
  %14 = load double, ptr %13, align 8, !tbaa !5
  br label %15

15:                                               ; preds = %.preheader, %.thread
  %indvars.iv = phi i64 [ 0, %.preheader ], [ %indvars.iv.next, %.thread ]
  %.174 = phi i32 [ %.05176, %.preheader ], [ %.4, %.thread ]
  %16 = sext i32 %.174 to i64
  %17 = getelementptr inbounds [12 x double], ptr @__const.td_ph.del_ini, i64 0, i64 %16
  %18 = load double, ptr %17, align 8, !tbaa !5
  call void @calcfg_dfg_ph(ptr noundef nonnull %5, ptr noundef nonnull %6, ptr noundef nonnull %7, ptr noundef nonnull %9, ptr noundef nonnull %8, ptr noundef nonnull %10, double noundef %14, double noundef %18, double noundef %2, double noundef %3)
  %19 = load double, ptr %9, align 8, !tbaa !5
  %20 = load double, ptr %8, align 8, !tbaa !5
  %21 = load double, ptr %7, align 8, !tbaa !5
  %22 = load double, ptr %10, align 8, !tbaa !5
  %23 = fneg double %21
  %24 = fmul double %22, %23
  %25 = call double @llvm.fmuladd.f64(double %19, double %20, double %24)
  %26 = call double @llvm.fabs.f64(double %25)
  %27 = fcmp olt double %26, 0x3EB0C6F7A0B5ED8D
  br i1 %27, label %.thread, label %28

28:                                               ; preds = %15
  %29 = load double, ptr %6, align 8, !tbaa !5
  %30 = load double, ptr %5, align 8, !tbaa !5
  %31 = fneg double %30
  %32 = fneg double %20
  %33 = fmul double %19, %32
  %34 = call double @llvm.fmuladd.f64(double %21, double %22, double %33)
  %35 = insertelement <2 x double> poison, double %20, i64 0
  %36 = insertelement <2 x double> %35, double %22, i64 1
  %37 = insertelement <2 x double> poison, double %31, i64 0
  %38 = shufflevector <2 x double> %37, <2 x double> poison, <2 x i32> zeroinitializer
  %39 = fmul <2 x double> %36, %38
  %40 = insertelement <2 x double> poison, double %29, i64 0
  %41 = shufflevector <2 x double> %40, <2 x double> poison, <2 x i32> zeroinitializer
  %42 = insertelement <2 x double> poison, double %21, i64 0
  %43 = insertelement <2 x double> %42, double %19, i64 1
  %44 = call <2 x double> @llvm.fmuladd.v2f64(<2 x double> %41, <2 x double> %43, <2 x double> %39)
  %45 = insertelement <2 x double> poison, double %25, i64 0
  %46 = insertelement <2 x double> %45, double %34, i64 1
  %47 = fdiv <2 x double> %44, %46
  %48 = getelementptr inbounds [12 x double], ptr @__const.td_ph.del_ini, i64 0, i64 %indvars.iv
  %49 = load double, ptr %48, align 8, !tbaa !5
  %50 = insertelement <2 x double> poison, double %49, i64 0
  %51 = insertelement <2 x double> %50, double %14, i64 1
  %52 = fadd <2 x double> %51, %47
  br label %53

53:                                               ; preds = %66, %28
  %.2 = phi i32 [ 0, %28 ], [ %91, %66 ]
  %54 = phi <2 x double> [ %52, %28 ], [ %86, %66 ]
  %55 = extractelement <2 x double> %54, i64 0
  %56 = extractelement <2 x double> %54, i64 1
  call void @calcfg_dfg_ph(ptr noundef nonnull %5, ptr noundef nonnull %6, ptr noundef nonnull %7, ptr noundef nonnull %9, ptr noundef nonnull %8, ptr noundef nonnull %10, double noundef %56, double noundef %55, double noundef %2, double noundef %3)
  %57 = load double, ptr %9, align 8, !tbaa !5
  %58 = load double, ptr %8, align 8, !tbaa !5
  %59 = load double, ptr %7, align 8, !tbaa !5
  %60 = load double, ptr %10, align 8, !tbaa !5
  %61 = fneg double %59
  %62 = fmul double %60, %61
  %63 = call double @llvm.fmuladd.f64(double %57, double %58, double %62)
  %64 = call double @llvm.fabs.f64(double %63)
  %65 = fcmp olt double %64, 0x3EB0C6F7A0B5ED8D
  br i1 %65, label %.thread, label %66

66:                                               ; preds = %53
  %67 = load double, ptr %6, align 8, !tbaa !5
  %68 = load double, ptr %5, align 8, !tbaa !5
  %69 = fneg double %68
  %70 = fneg double %58
  %71 = fmul double %57, %70
  %72 = call double @llvm.fmuladd.f64(double %59, double %60, double %71)
  %73 = insertelement <2 x double> poison, double %58, i64 0
  %74 = insertelement <2 x double> %73, double %60, i64 1
  %75 = insertelement <2 x double> poison, double %69, i64 0
  %76 = shufflevector <2 x double> %75, <2 x double> poison, <2 x i32> zeroinitializer
  %77 = fmul <2 x double> %74, %76
  %78 = insertelement <2 x double> poison, double %67, i64 0
  %79 = shufflevector <2 x double> %78, <2 x double> poison, <2 x i32> zeroinitializer
  %80 = insertelement <2 x double> poison, double %59, i64 0
  %81 = insertelement <2 x double> %80, double %57, i64 1
  %82 = call <2 x double> @llvm.fmuladd.v2f64(<2 x double> %79, <2 x double> %81, <2 x double> %77)
  %83 = insertelement <2 x double> poison, double %63, i64 0
  %84 = insertelement <2 x double> %83, double %72, i64 1
  %85 = fdiv <2 x double> %82, %84
  %86 = fadd <2 x double> %54, %85
  %87 = call <2 x double> @llvm.fabs.v2f64(<2 x double> %85)
  %88 = extractelement <2 x double> %87, i64 0
  %89 = extractelement <2 x double> %87, i64 1
  %90 = fcmp ogt double %89, %88
  %. = select i1 %90, double %89, double %88
  %91 = add nuw nsw i32 %.2, 1
  %92 = fcmp ogt double %., 0x3EB0C6F7A0B5ED8D
  %93 = icmp ult i32 %.2, 99
  %94 = select i1 %92, i1 %93, i1 false
  br i1 %94, label %53, label %95, !llvm.loop !9

95:                                               ; preds = %66
  %96 = icmp eq i32 %91, 100
  %97 = fcmp uno <2 x double> %86, zeroinitializer
  %98 = extractelement <2 x i1> %97, i64 1
  %or.cond59 = select i1 %96, i1 true, i1 %98
  %99 = extractelement <2 x i1> %97, i64 0
  %or.cond60 = select i1 %or.cond59, i1 true, i1 %99
  br i1 %or.cond60, label %.thread, label %100

100:                                              ; preds = %95
  %101 = extractelement <2 x double> %86, i64 1
  %102 = fdiv double 0x4073020D1B71758E, %101
  %103 = extractelement <2 x double> %86, i64 0
  %104 = fmul double %103, 4.676000e+02
  call void @co2_prop_calc_tr(ptr noundef nonnull %11, double noundef %102, double noundef %104)
  %105 = call i32 @is_vld_prop(ptr noundef nonnull %11)
  %106 = icmp eq i32 %105, 0
  br i1 %106, label %107, label %.thread

107:                                              ; preds = %100
  %108 = load double, ptr %11, align 8, !tbaa !11
  %109 = fsub double %2, %108
  %110 = call double @llvm.fabs.f64(double %109)
  %111 = fdiv double %110, %2
  %112 = fcmp olt double %111, 1.000000e-04
  br i1 %112, label %113, label %.thread

113:                                              ; preds = %107
  %114 = load double, ptr %12, align 8, !tbaa !13
  %115 = fsub double %3, %114
  %116 = fdiv double %115, %3
  %117 = call double @llvm.fabs.f64(double %116)
  %118 = fcmp olt double %117, 1.000000e-04
  br i1 %118, label %119, label %.thread

119:                                              ; preds = %113
  store double %102, ptr %0, align 8, !tbaa !5
  store double %104, ptr %1, align 8, !tbaa !5
  br label %.loopexit

.thread:                                          ; preds = %53, %100, %107, %113, %95, %15
  %.4 = phi i32 [ %.174, %15 ], [ %91, %95 ], [ %91, %113 ], [ %91, %107 ], [ %91, %100 ], [ %.2, %53 ]
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %exitcond.not = icmp eq i64 %indvars.iv.next, 12
  br i1 %exitcond.not, label %120, label %15, !llvm.loop !14

120:                                              ; preds = %.thread
  %indvars.iv.next86 = add nuw nsw i64 %indvars.iv85, 1
  %exitcond88.not = icmp eq i64 %indvars.iv.next86, 10
  br i1 %exitcond88.not, label %.loopexit, label %.preheader, !llvm.loop !15

.loopexit:                                        ; preds = %120, %119
  %.0 = phi i32 [ 0, %119 ], [ -1, %120 ]
  call void @llvm.lifetime.end.p0(i64 128, ptr nonnull %11) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %10) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %9) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %5) #4
  ret i32 %.0
}

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare <2 x double> @llvm.fmuladd.v2f64(<2 x double>, <2 x double>, <2 x double>) #3

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare <2 x double> @llvm.fabs.v2f64(<2 x double>) #3

attributes #0 = { nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #3 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #4 = { nounwind }

!llvm.module.flags = !{!0, !1, !2, !3}
!llvm.ident = !{!4}

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"double", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/C++ TBAA"}
!9 = distinct !{!9, !10}
!10 = !{!"llvm.loop.mustprogress"}
!11 = !{!12, !6, i64 0}
!12 = !{!"", !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, !6, i64 80, !6, i64 88, !6, i64 96, !6, i64 104, !6, i64 112, !6, i64 120}
!13 = !{!12, !6, i64 56}
!14 = distinct !{!14, !10}
!15 = distinct !{!15, !10}


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