; LLVM IR from cselab/aphros :: src/gen (wave_lamb)

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

@a = external hidden global double, align 8
@k = external hidden global double, align 8
@h = external hidden global double, align 8
@g = external hidden global double, align 8

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

; Function Attrs: alwaysinline nounwind uwtable
declare hidden double @_ZL9__tg_tanhd(double noundef) #1

; Function Attrs: alwaysinline nounwind uwtable
declare hidden double @_ZL8__tg_powdd(double noundef, double noundef) #1

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

; Function Attrs: alwaysinline nounwind uwtable
declare hidden double @_ZL8__tg_cosd(double noundef) #1

; Function Attrs: alwaysinline nounwind uwtable
declare hidden double @_ZL9__tg_coshd(double noundef) #1

; Function Attrs: alwaysinline nounwind uwtable
declare hidden double @_ZL8__tg_sind(double noundef) #1

; Function Attrs: alwaysinline nounwind uwtable
declare hidden double @_ZL9__tg_sinhd(double noundef) #1

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

; Function Attrs: nounwind uwtable
define dso_local void @f1(double noundef %0, double noundef %1, ptr noundef %2, ptr noundef %3, ptr noundef %4) #3 {
  %6 = alloca double, align 8
  %7 = alloca double, align 8
  %8 = alloca ptr, align 8
  %9 = alloca ptr, align 8
  %10 = alloca ptr, 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 double, align 8
  store double %0, ptr %6, align 8, !tbaa !5
  store double %1, ptr %7, align 8, !tbaa !5
  store ptr %2, ptr %8, align 8, !tbaa !9
  store ptr %3, ptr %9, align 8, !tbaa !9
  store ptr %4, ptr %10, align 8, !tbaa !9
  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 8, ptr %16) #4
  %17 = load double, ptr @a, align 8, !tbaa !5
  %18 = load double, ptr @k, align 8, !tbaa !5
  %19 = fmul double %17, %18
  store double %19, ptr %11, align 8, !tbaa !5
  %20 = load double, ptr @h, align 8, !tbaa !5
  %21 = load double, ptr @k, align 8, !tbaa !5
  %22 = fmul double %20, %21
  %23 = call double @_ZL9__tg_tanhd(double noundef %22)
  %24 = fdiv double 1.000000e+00, %23
  store double %24, ptr %12, align 8, !tbaa !5
  %25 = load double, ptr @a, align 8, !tbaa !5
  %26 = fpext double %25 to x86_fp80
  %27 = fmul x86_fp80 0xK3FFD8000000000000000, %26
  %28 = load double, ptr %12, align 8, !tbaa !5
  %29 = fpext double %28 to x86_fp80
  %30 = fmul x86_fp80 %27, %29
  %31 = load double, ptr %11, align 8, !tbaa !5
  %32 = fpext double %31 to x86_fp80
  %33 = fmul x86_fp80 %30, %32
  %34 = load double, ptr %12, align 8, !tbaa !5
  %35 = call double @_ZL8__tg_powdd(double noundef %34, double noundef 2.000000e+00)
  %36 = call double @llvm.fmuladd.f64(double 3.000000e+00, double %35, double -1.000000e+00)
  %37 = fpext double %36 to x86_fp80
  %38 = fmul x86_fp80 %33, %37
  %39 = load double, ptr @k, align 8, !tbaa !5
  %40 = fmul double 2.000000e+00, %39
  %41 = load double, ptr %6, align 8, !tbaa !5
  %42 = fmul double %40, %41
  %43 = call double @_ZL8__tg_cosd(double noundef %42)
  %44 = fpext double %43 to x86_fp80
  %45 = load double, ptr @a, align 8, !tbaa !5
  %46 = load double, ptr %11, align 8, !tbaa !5
  %47 = call double @_ZL8__tg_powdd(double noundef %46, double noundef 2.000000e+00)
  %48 = fmul double %45, %47
  %49 = fpext double %48 to x86_fp80
  %50 = load double, ptr %12, align 8, !tbaa !5
  %51 = call double @_ZL8__tg_powdd(double noundef %50, double noundef 6.000000e+00)
  %52 = load double, ptr %12, align 8, !tbaa !5
  %53 = call double @_ZL8__tg_powdd(double noundef %52, double noundef 2.000000e+00)
  %54 = fsub double %53, 1.000000e+00
  %55 = call double @_ZL8__tg_powdd(double noundef %54, double noundef 2.000000e+00)
  %56 = fmul double 3.000000e+00, %55
  %57 = call double @llvm.fmuladd.f64(double 2.400000e+01, double %51, double %56)
  %58 = fpext double %57 to x86_fp80
  %59 = fmul x86_fp80 0xK3FF98000000000000000, %58
  %60 = load double, ptr @k, align 8, !tbaa !5
  %61 = fmul double 3.000000e+00, %60
  %62 = load double, ptr %6, align 8, !tbaa !5
  %63 = fmul double %61, %62
  %64 = call double @_ZL8__tg_cosd(double noundef %63)
  %65 = fpext double %64 to x86_fp80
  %66 = load double, ptr %12, align 8, !tbaa !5
  %67 = call double @_ZL8__tg_powdd(double noundef %66, double noundef 4.000000e+00)
  %68 = load double, ptr %12, align 8, !tbaa !5
  %69 = call double @_ZL8__tg_powdd(double noundef %68, double noundef 2.000000e+00)
  %70 = fmul double 9.000000e+00, %69
  %71 = call double @llvm.fmuladd.f64(double -3.000000e+00, double %67, double %70)
  %72 = fsub double %71, 9.000000e+00
  %73 = fpext double %72 to x86_fp80
  %74 = fmul x86_fp80 0xK3FFC8000000000000000, %73
  %75 = load double, ptr @k, align 8, !tbaa !5
  %76 = load double, ptr %6, align 8, !tbaa !5
  %77 = fmul double %75, %76
  %78 = call double @_ZL8__tg_cosd(double noundef %77)
  %79 = fpext double %78 to x86_fp80
  %80 = fmul x86_fp80 %74, %79
  %81 = call x86_fp80 @llvm.fmuladd.f80(x86_fp80 %59, x86_fp80 %65, x86_fp80 %80)
  %82 = fmul x86_fp80 %49, %81
  %83 = call x86_fp80 @llvm.fmuladd.f80(x86_fp80 %38, x86_fp80 %44, x86_fp80 %82)
  %84 = load double, ptr @a, align 8, !tbaa !5
  %85 = load double, ptr @k, align 8, !tbaa !5
  %86 = load double, ptr %6, align 8, !tbaa !5
  %87 = fmul double %85, %86
  %88 = call double @_ZL8__tg_cosd(double noundef %87)
  %89 = fmul double %84, %88
  %90 = fpext double %89 to x86_fp80
  %91 = fadd x86_fp80 %83, %90
  %92 = fptrunc x86_fp80 %91 to double
  store double %92, ptr %16, align 8, !tbaa !5
  %93 = load double, ptr @g, align 8, !tbaa !5
  %94 = load double, ptr @k, align 8, !tbaa !5
  %95 = fmul double %93, %94
  %96 = fpext double %95 to x86_fp80
  %97 = load double, ptr %11, align 8, !tbaa !5
  %98 = call double @_ZL8__tg_powdd(double noundef %97, double noundef 2.000000e+00)
  %99 = fpext double %98 to x86_fp80
  %100 = load double, ptr %12, align 8, !tbaa !5
  %101 = call double @_ZL8__tg_powdd(double noundef %100, double noundef 2.000000e+00)
  %102 = fpext double %101 to x86_fp80
  %103 = load double, ptr %12, align 8, !tbaa !5
  %104 = call double @_ZL8__tg_powdd(double noundef %103, double noundef 2.000000e+00)
  %105 = fsub double %104, 1.000000e+00
  %106 = call double @_ZL8__tg_powdd(double noundef %105, double noundef 2.000000e+00)
  %107 = fpext double %106 to x86_fp80
  %108 = call x86_fp80 @llvm.fmuladd.f80(x86_fp80 0xK3FFF9000000000000000, x86_fp80 %107, x86_fp80 %102)
  %109 = call x86_fp80 @llvm.fmuladd.f80(x86_fp80 %99, x86_fp80 %108, x86_fp80 0xK3FFF8000000000000000)
  %110 = fmul x86_fp80 %96, %109
  %111 = load double, ptr @h, align 8, !tbaa !5
  %112 = load double, ptr @k, align 8, !tbaa !5
  %113 = fmul double %111, %112
  %114 = call double @_ZL9__tg_tanhd(double noundef %113)
  %115 = fpext double %114 to x86_fp80
  %116 = fmul x86_fp80 %110, %115
  %117 = call x86_fp80 @_ZL9__tg_sqrte(x86_fp80 noundef %116)
  %118 = fptrunc x86_fp80 %117 to double
  store double %118, ptr %13, align 8, !tbaa !5
  %119 = load double, ptr @a, align 8, !tbaa !5
  %120 = fpext double %119 to x86_fp80
  %121 = fmul x86_fp80 0xK3FFAC000000000000000, %120
  %122 = load double, ptr %11, align 8, !tbaa !5
  %123 = call double @_ZL8__tg_powdd(double noundef %122, double noundef 2.000000e+00)
  %124 = fpext double %123 to x86_fp80
  %125 = fmul x86_fp80 %121, %124
  %126 = load double, ptr @g, align 8, !tbaa !5
  %127 = fpext double %126 to x86_fp80
  %128 = fmul x86_fp80 %125, %127
  %129 = load double, ptr @k, align 8, !tbaa !5
  %130 = fpext double %129 to x86_fp80
  %131 = fmul x86_fp80 %128, %130
  %132 = load double, ptr %12, align 8, !tbaa !5
  %133 = call double @_ZL8__tg_powdd(double noundef %132, double noundef 2.000000e+00)
  %134 = fsub double %133, 1.000000e+00
  %135 = fpext double %134 to x86_fp80
  %136 = fmul x86_fp80 %131, %135
  %137 = load double, ptr %12, align 8, !tbaa !5
  %138 = call double @_ZL8__tg_powdd(double noundef %137, double noundef 2.000000e+00)
  %139 = fadd double %138, 3.000000e+00
  %140 = fpext double %139 to x86_fp80
  %141 = fmul x86_fp80 %136, %140
  %142 = load double, ptr %12, align 8, !tbaa !5
  %143 = call double @_ZL8__tg_powdd(double noundef %142, double noundef 2.000000e+00)
  %144 = call double @llvm.fmuladd.f64(double 9.000000e+00, double %143, double -1.300000e+01)
  %145 = fpext double %144 to x86_fp80
  %146 = fmul x86_fp80 %141, %145
  %147 = load double, ptr @k, align 8, !tbaa !5
  %148 = fmul double 3.000000e+00, %147
  %149 = load double, ptr %6, align 8, !tbaa !5
  %150 = fmul double %148, %149
  %151 = call double @_ZL8__tg_cosd(double noundef %150)
  %152 = fpext double %151 to x86_fp80
  %153 = fmul x86_fp80 %146, %152
  %154 = load double, ptr @k, align 8, !tbaa !5
  %155 = fmul double 3.000000e+00, %154
  %156 = load double, ptr @h, align 8, !tbaa !5
  %157 = load double, ptr %7, align 8, !tbaa !5
  %158 = fadd double %156, %157
  %159 = fmul double %155, %158
  %160 = call double @_ZL9__tg_coshd(double noundef %159)
  %161 = fpext double %160 to x86_fp80
  %162 = fmul x86_fp80 %153, %161
  %163 = load double, ptr %13, align 8, !tbaa !5
  %164 = load double, ptr @h, align 8, !tbaa !5
  %165 = fmul double 3.000000e+00, %164
  %166 = load double, ptr @k, align 8, !tbaa !5
  %167 = fmul double %165, %166
  %168 = call double @_ZL9__tg_coshd(double noundef %167)
  %169 = fmul double %163, %168
  %170 = fpext double %169 to x86_fp80
  %171 = fdiv x86_fp80 %162, %170
  %172 = load double, ptr @a, align 8, !tbaa !5
  %173 = load double, ptr @g, align 8, !tbaa !5
  %174 = fmul double %172, %173
  %175 = load double, ptr @k, align 8, !tbaa !5
  %176 = fmul double %174, %175
  %177 = load double, ptr @k, align 8, !tbaa !5
  %178 = load double, ptr %6, align 8, !tbaa !5
  %179 = fmul double %177, %178
  %180 = call double @_ZL8__tg_cosd(double noundef %179)
  %181 = fmul double %176, %180
  %182 = load double, ptr @k, align 8, !tbaa !5
  %183 = load double, ptr @h, align 8, !tbaa !5
  %184 = load double, ptr %7, align 8, !tbaa !5
  %185 = fadd double %183, %184
  %186 = fmul double %182, %185
  %187 = call double @_ZL9__tg_coshd(double noundef %186)
  %188 = fmul double %181, %187
  %189 = load double, ptr %13, align 8, !tbaa !5
  %190 = load double, ptr @h, align 8, !tbaa !5
  %191 = load double, ptr @k, align 8, !tbaa !5
  %192 = fmul double %190, %191
  %193 = call double @_ZL9__tg_coshd(double noundef %192)
  %194 = fmul double %189, %193
  %195 = fdiv double %188, %194
  %196 = fpext double %195 to x86_fp80
  %197 = fadd x86_fp80 %171, %196
  %198 = load double, ptr @a, align 8, !tbaa !5
  %199 = fpext double %198 to x86_fp80
  %200 = fmul x86_fp80 0xK3FFEC000000000000000, %199
  %201 = load double, ptr %11, align 8, !tbaa !5
  %202 = fpext double %201 to x86_fp80
  %203 = fmul x86_fp80 %200, %202
  %204 = load double, ptr @g, align 8, !tbaa !5
  %205 = fpext double %204 to x86_fp80
  %206 = fmul x86_fp80 %203, %205
  %207 = load double, ptr @k, align 8, !tbaa !5
  %208 = fpext double %207 to x86_fp80
  %209 = fmul x86_fp80 %206, %208
  %210 = load double, ptr %12, align 8, !tbaa !5
  %211 = call double @_ZL8__tg_powdd(double noundef %210, double noundef 2.000000e+00)
  %212 = fsub double %211, 1.000000e+00
  %213 = call double @_ZL8__tg_powdd(double noundef %212, double noundef 2.000000e+00)
  %214 = fpext double %213 to x86_fp80
  %215 = fmul x86_fp80 %209, %214
  %216 = load double, ptr @k, align 8, !tbaa !5
  %217 = fmul double 2.000000e+00, %216
  %218 = load double, ptr %6, align 8, !tbaa !5
  %219 = fmul double %217, %218
  %220 = call double @_ZL8__tg_cosd(double noundef %219)
  %221 = fpext double %220 to x86_fp80
  %222 = fmul x86_fp80 %215, %221
  %223 = load double, ptr @k, align 8, !tbaa !5
  %224 = fmul double 2.000000e+00, %223
  %225 = load double, ptr @h, align 8, !tbaa !5
  %226 = load double, ptr %7, align 8, !tbaa !5
  %227 = fadd double %225, %226
  %228 = fmul double %224, %227
  %229 = call double @_ZL9__tg_coshd(double noundef %228)
  %230 = fpext double %229 to x86_fp80
  %231 = fmul x86_fp80 %222, %230
  %232 = load double, ptr %12, align 8, !tbaa !5
  %233 = load double, ptr %13, align 8, !tbaa !5
  %234 = fmul double %232, %233
  %235 = load double, ptr @h, align 8, !tbaa !5
  %236 = fmul double 2.000000e+00, %235
  %237 = load double, ptr @k, align 8, !tbaa !5
  %238 = fmul double %236, %237
  %239 = call double @_ZL9__tg_coshd(double noundef %238)
  %240 = fmul double %234, %239
  %241 = fpext double %240 to x86_fp80
  %242 = fdiv x86_fp80 %231, %241
  %243 = fadd x86_fp80 %197, %242
  %244 = fptrunc x86_fp80 %243 to double
  store double %244, ptr %14, align 8, !tbaa !5
  %245 = load double, ptr @a, align 8, !tbaa !5
  %246 = fpext double %245 to x86_fp80
  %247 = fmul x86_fp80 0xK3FFAC000000000000000, %246
  %248 = load double, ptr %11, align 8, !tbaa !5
  %249 = call double @_ZL8__tg_powdd(double noundef %248, double noundef 2.000000e+00)
  %250 = fpext double %249 to x86_fp80
  %251 = fmul x86_fp80 %247, %250
  %252 = load double, ptr @g, align 8, !tbaa !5
  %253 = fpext double %252 to x86_fp80
  %254 = fmul x86_fp80 %251, %253
  %255 = load double, ptr @k, align 8, !tbaa !5
  %256 = fpext double %255 to x86_fp80
  %257 = fmul x86_fp80 %254, %256
  %258 = load double, ptr %12, align 8, !tbaa !5
  %259 = call double @_ZL8__tg_powdd(double noundef %258, double noundef 2.000000e+00)
  %260 = fsub double %259, 1.000000e+00
  %261 = fpext double %260 to x86_fp80
  %262 = fmul x86_fp80 %257, %261
  %263 = load double, ptr %12, align 8, !tbaa !5
  %264 = call double @_ZL8__tg_powdd(double noundef %263, double noundef 2.000000e+00)
  %265 = fadd double %264, 3.000000e+00
  %266 = fpext double %265 to x86_fp80
  %267 = fmul x86_fp80 %262, %266
  %268 = load double, ptr %12, align 8, !tbaa !5
  %269 = call double @_ZL8__tg_powdd(double noundef %268, double noundef 2.000000e+00)
  %270 = call double @llvm.fmuladd.f64(double 9.000000e+00, double %269, double -1.300000e+01)
  %271 = fpext double %270 to x86_fp80
  %272 = fmul x86_fp80 %267, %271
  %273 = load double, ptr @k, align 8, !tbaa !5
  %274 = fmul double 3.000000e+00, %273
  %275 = load double, ptr %6, align 8, !tbaa !5
  %276 = fmul double %274, %275
  %277 = call double @_ZL8__tg_sind(double noundef %276)
  %278 = fpext double %277 to x86_fp80
  %279 = fmul x86_fp80 %272, %278
  %280 = load double, ptr @k, align 8, !tbaa !5
  %281 = fmul double 3.000000e+00, %280
  %282 = load double, ptr @h, align 8, !tbaa !5
  %283 = load double, ptr %7, align 8, !tbaa !5
  %284 = fadd double %282, %283
  %285 = fmul double %281, %284
  %286 = call double @_ZL9__tg_sinhd(double noundef %285)
  %287 = fpext double %286 to x86_fp80
  %288 = fmul x86_fp80 %279, %287
  %289 = load double, ptr %13, align 8, !tbaa !5
  %290 = load double, ptr @h, align 8, !tbaa !5
  %291 = fmul double 3.000000e+00, %290
  %292 = load double, ptr @k, align 8, !tbaa !5
  %293 = fmul double %291, %292
  %294 = call double @_ZL9__tg_coshd(double noundef %293)
  %295 = fmul double %289, %294
  %296 = fpext double %295 to x86_fp80
  %297 = fdiv x86_fp80 %288, %296
  %298 = load double, ptr @a, align 8, !tbaa !5
  %299 = load double, ptr @g, align 8, !tbaa !5
  %300 = fmul double %298, %299
  %301 = load double, ptr @k, align 8, !tbaa !5
  %302 = fmul double %300, %301
  %303 = load double, ptr @k, align 8, !tbaa !5
  %304 = load double, ptr %6, align 8, !tbaa !5
  %305 = fmul double %303, %304
  %306 = call double @_ZL8__tg_sind(double noundef %305)
  %307 = fmul double %302, %306
  %308 = load double, ptr @k, align 8, !tbaa !5
  %309 = load double, ptr @h, align 8, !tbaa !5
  %310 = load double, ptr %7, align 8, !tbaa !5
  %311 = fadd double %309, %310
  %312 = fmul double %308, %311
  %313 = call double @_ZL9__tg_sinhd(double noundef %312)
  %314 = fmul double %307, %313
  %315 = load double, ptr %13, align 8, !tbaa !5
  %316 = load double, ptr @h, align 8, !tbaa !5
  %317 = load double, ptr @k, align 8, !tbaa !5
  %318 = fmul double %316, %317
  %319 = call double @_ZL9__tg_coshd(double noundef %318)
  %320 = fmul double %315, %319
  %321 = fdiv double %314, %320
  %322 = fpext double %321 to x86_fp80
  %323 = fadd x86_fp80 %297, %322
  %324 = load double, ptr @a, align 8, !tbaa !5
  %325 = fpext double %324 to x86_fp80
  %326 = fmul x86_fp80 0xK3FFEC000000000000000, %325
  %327 = load double, ptr %11, align 8, !tbaa !5
  %328 = fpext double %327 to x86_fp80
  %329 = fmul x86_fp80 %326, %328
  %330 = load double, ptr @g, align 8, !tbaa !5
  %331 = fpext double %330 to x86_fp80
  %332 = fmul x86_fp80 %329, %331
  %333 = load double, ptr @k, align 8, !tbaa !5
  %334 = fpext double %333 to x86_fp80
  %335 = fmul x86_fp80 %332, %334
  %336 = load double, ptr %12, align 8, !tbaa !5
  %337 = call double @_ZL8__tg_powdd(double noundef %336, double noundef 2.000000e+00)
  %338 = fsub double %337, 1.000000e+00
  %339 = call double @_ZL8__tg_powdd(double noundef %338, double noundef 2.000000e+00)
  %340 = fpext double %339 to x86_fp80
  %341 = fmul x86_fp80 %335, %340
  %342 = load double, ptr @k, align 8, !tbaa !5
  %343 = fmul double 2.000000e+00, %342
  %344 = load double, ptr %6, align 8, !tbaa !5
  %345 = fmul double %343, %344
  %346 = call double @_ZL8__tg_sind(double noundef %345)
  %347 = fpext double %346 to x86_fp80
  %348 = fmul x86_fp80 %341, %347
  %349 = load double, ptr @k, align 8, !tbaa !5
  %350 = fmul double 2.000000e+00, %349
  %351 = load double, ptr @h, align 8, !tbaa !5
  %352 = load double, ptr %7, align 8, !tbaa !5
  %353 = fadd double %351, %352
  %354 = fmul double %350, %353
  %355 = call double @_ZL9__tg_sinhd(double noundef %354)
  %356 = fpext double %355 to x86_fp80
  %357 = fmul x86_fp80 %348, %356
  %358 = load double, ptr %12, align 8, !tbaa !5
  %359 = load double, ptr %13, align 8, !tbaa !5
  %360 = fmul double %358, %359
  %361 = load double, ptr @h, align 8, !tbaa !5
  %362 = fmul double 2.000000e+00, %361
  %363 = load double, ptr @k, align 8, !tbaa !5
  %364 = fmul double %362, %363
  %365 = call double @_ZL9__tg_coshd(double noundef %364)
  %366 = fmul double %360, %365
  %367 = fpext double %366 to x86_fp80
  %368 = fdiv x86_fp80 %357, %367
  %369 = fadd x86_fp80 %323, %368
  %370 = fptrunc x86_fp80 %369 to double
  store double %370, ptr %15, align 8, !tbaa !5
  %371 = load double, ptr %14, align 8, !tbaa !5
  %372 = load ptr, ptr %8, align 8, !tbaa !9
  store double %371, ptr %372, align 8, !tbaa !5
  %373 = load double, ptr %15, align 8, !tbaa !5
  %374 = load ptr, ptr %9, align 8, !tbaa !9
  store double %373, ptr %374, align 8, !tbaa !5
  %375 = load double, ptr %16, align 8, !tbaa !5
  %376 = load ptr, ptr %10, align 8, !tbaa !9
  store double %375, ptr %376, align 8, !tbaa !5
  call void @llvm.lifetime.end.p0(i64 8, 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
  ret void
}

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

; Function Attrs: alwaysinline nounwind uwtable
declare hidden x86_fp80 @_ZL9__tg_sqrte(x86_fp80 noundef) #1

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { alwaysinline 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 #2 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
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, !6, i64 0}
!6 = !{!"double", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"any pointer", !7, i64 0}


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

@a = external hidden local_unnamed_addr global double, align 8
@k = external hidden local_unnamed_addr global double, align 8
@h = external hidden local_unnamed_addr global double, align 8
@g = external hidden local_unnamed_addr global double, align 8

; Function Attrs: alwaysinline nounwind uwtable
declare hidden double @_ZL9__tg_tanhd(double noundef) local_unnamed_addr #0

; Function Attrs: alwaysinline nounwind uwtable
declare hidden double @_ZL8__tg_powdd(double noundef, double noundef) local_unnamed_addr #0

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

; Function Attrs: alwaysinline nounwind uwtable
declare hidden double @_ZL8__tg_cosd(double noundef) local_unnamed_addr #0

; Function Attrs: alwaysinline nounwind uwtable
declare hidden double @_ZL9__tg_coshd(double noundef) local_unnamed_addr #0

; Function Attrs: alwaysinline nounwind uwtable
declare hidden double @_ZL8__tg_sind(double noundef) local_unnamed_addr #0

; Function Attrs: alwaysinline nounwind uwtable
declare hidden double @_ZL9__tg_sinhd(double noundef) local_unnamed_addr #0

; Function Attrs: nounwind uwtable
define dso_local void @f1(double noundef %0, double noundef %1, ptr nocapture noundef writeonly %2, ptr nocapture noundef writeonly %3, ptr nocapture noundef writeonly %4) local_unnamed_addr #2 {
  %6 = load double, ptr @a, align 8, !tbaa !5
  %7 = load double, ptr @k, align 8, !tbaa !5
  %8 = fmul double %6, %7
  %9 = load double, ptr @h, align 8, !tbaa !5
  %10 = fmul double %7, %9
  %11 = tail call double @_ZL9__tg_tanhd(double noundef %10)
  %12 = fdiv double 1.000000e+00, %11
  %13 = load double, ptr @a, align 8, !tbaa !5
  %14 = fpext double %13 to x86_fp80
  %15 = fmul x86_fp80 %14, 0xK3FFD8000000000000000
  %16 = fpext double %12 to x86_fp80
  %17 = fmul x86_fp80 %15, %16
  %18 = fpext double %8 to x86_fp80
  %19 = fmul x86_fp80 %17, %18
  %20 = tail call double @_ZL8__tg_powdd(double noundef %12, double noundef 2.000000e+00)
  %21 = tail call double @llvm.fmuladd.f64(double %20, double 3.000000e+00, double -1.000000e+00)
  %22 = fpext double %21 to x86_fp80
  %23 = fmul x86_fp80 %19, %22
  %24 = load double, ptr @k, align 8, !tbaa !5
  %25 = fmul double %24, 2.000000e+00
  %26 = fmul double %25, %0
  %27 = tail call double @_ZL8__tg_cosd(double noundef %26)
  %28 = fpext double %27 to x86_fp80
  %29 = load double, ptr @a, align 8, !tbaa !5
  %30 = tail call double @_ZL8__tg_powdd(double noundef %8, double noundef 2.000000e+00)
  %31 = fmul double %29, %30
  %32 = fpext double %31 to x86_fp80
  %33 = tail call double @_ZL8__tg_powdd(double noundef %12, double noundef 6.000000e+00)
  %34 = tail call double @_ZL8__tg_powdd(double noundef %12, double noundef 2.000000e+00)
  %35 = fadd double %34, -1.000000e+00
  %36 = tail call double @_ZL8__tg_powdd(double noundef %35, double noundef 2.000000e+00)
  %37 = fmul double %36, 3.000000e+00
  %38 = tail call double @llvm.fmuladd.f64(double %33, double 2.400000e+01, double %37)
  %39 = fpext double %38 to x86_fp80
  %40 = fmul x86_fp80 %39, 0xK3FF98000000000000000
  %41 = load double, ptr @k, align 8, !tbaa !5
  %42 = fmul double %41, 3.000000e+00
  %43 = fmul double %42, %0
  %44 = tail call double @_ZL8__tg_cosd(double noundef %43)
  %45 = fpext double %44 to x86_fp80
  %46 = tail call double @_ZL8__tg_powdd(double noundef %12, double noundef 4.000000e+00)
  %47 = tail call double @_ZL8__tg_powdd(double noundef %12, double noundef 2.000000e+00)
  %48 = fmul double %47, 9.000000e+00
  %49 = tail call double @llvm.fmuladd.f64(double %46, double -3.000000e+00, double %48)
  %50 = fadd double %49, -9.000000e+00
  %51 = fpext double %50 to x86_fp80
  %52 = fmul x86_fp80 %51, 0xK3FFC8000000000000000
  %53 = load double, ptr @k, align 8, !tbaa !5
  %54 = fmul double %53, %0
  %55 = tail call double @_ZL8__tg_cosd(double noundef %54)
  %56 = fpext double %55 to x86_fp80
  %57 = fmul x86_fp80 %52, %56
  %58 = tail call x86_fp80 @llvm.fmuladd.f80(x86_fp80 %40, x86_fp80 %45, x86_fp80 %57)
  %59 = fmul x86_fp80 %58, %32
  %60 = tail call x86_fp80 @llvm.fmuladd.f80(x86_fp80 %23, x86_fp80 %28, x86_fp80 %59)
  %61 = load double, ptr @a, align 8, !tbaa !5
  %62 = load double, ptr @k, align 8, !tbaa !5
  %63 = fmul double %62, %0
  %64 = tail call double @_ZL8__tg_cosd(double noundef %63)
  %65 = fmul double %61, %64
  %66 = fpext double %65 to x86_fp80
  %67 = fadd x86_fp80 %60, %66
  %68 = fptrunc x86_fp80 %67 to double
  %69 = load double, ptr @g, align 8, !tbaa !5
  %70 = load double, ptr @k, align 8, !tbaa !5
  %71 = fmul double %69, %70
  %72 = fpext double %71 to x86_fp80
  %73 = tail call double @_ZL8__tg_powdd(double noundef %8, double noundef 2.000000e+00)
  %74 = fpext double %73 to x86_fp80
  %75 = tail call double @_ZL8__tg_powdd(double noundef %12, double noundef 2.000000e+00)
  %76 = fpext double %75 to x86_fp80
  %77 = tail call double @_ZL8__tg_powdd(double noundef %12, double noundef 2.000000e+00)
  %78 = fadd double %77, -1.000000e+00
  %79 = tail call double @_ZL8__tg_powdd(double noundef %78, double noundef 2.000000e+00)
  %80 = fpext double %79 to x86_fp80
  %81 = tail call x86_fp80 @llvm.fmuladd.f80(x86_fp80 %80, x86_fp80 0xK3FFF9000000000000000, x86_fp80 %76)
  %82 = tail call x86_fp80 @llvm.fmuladd.f80(x86_fp80 %74, x86_fp80 %81, x86_fp80 0xK3FFF8000000000000000)
  %83 = fmul x86_fp80 %82, %72
  %84 = load double, ptr @h, align 8, !tbaa !5
  %85 = load double, ptr @k, align 8, !tbaa !5
  %86 = fmul double %84, %85
  %87 = tail call double @_ZL9__tg_tanhd(double noundef %86)
  %88 = fpext double %87 to x86_fp80
  %89 = fmul x86_fp80 %83, %88
  %90 = tail call x86_fp80 @_ZL9__tg_sqrte(x86_fp80 noundef %89)
  %91 = fptrunc x86_fp80 %90 to double
  %92 = load double, ptr @a, align 8, !tbaa !5
  %93 = fpext double %92 to x86_fp80
  %94 = fmul x86_fp80 %93, 0xK3FFAC000000000000000
  %95 = tail call double @_ZL8__tg_powdd(double noundef %8, double noundef 2.000000e+00)
  %96 = fpext double %95 to x86_fp80
  %97 = fmul x86_fp80 %94, %96
  %98 = load double, ptr @g, align 8, !tbaa !5
  %99 = fpext double %98 to x86_fp80
  %100 = fmul x86_fp80 %97, %99
  %101 = load double, ptr @k, align 8, !tbaa !5
  %102 = fpext double %101 to x86_fp80
  %103 = fmul x86_fp80 %100, %102
  %104 = tail call double @_ZL8__tg_powdd(double noundef %12, double noundef 2.000000e+00)
  %105 = fadd double %104, -1.000000e+00
  %106 = fpext double %105 to x86_fp80
  %107 = fmul x86_fp80 %103, %106
  %108 = tail call double @_ZL8__tg_powdd(double noundef %12, double noundef 2.000000e+00)
  %109 = fadd double %108, 3.000000e+00
  %110 = fpext double %109 to x86_fp80
  %111 = fmul x86_fp80 %107, %110
  %112 = tail call double @_ZL8__tg_powdd(double noundef %12, double noundef 2.000000e+00)
  %113 = tail call double @llvm.fmuladd.f64(double %112, double 9.000000e+00, double -1.300000e+01)
  %114 = fpext double %113 to x86_fp80
  %115 = fmul x86_fp80 %111, %114
  %116 = load double, ptr @k, align 8, !tbaa !5
  %117 = fmul double %116, 3.000000e+00
  %118 = fmul double %117, %0
  %119 = tail call double @_ZL8__tg_cosd(double noundef %118)
  %120 = fpext double %119 to x86_fp80
  %121 = fmul x86_fp80 %115, %120
  %122 = load double, ptr @k, align 8, !tbaa !5
  %123 = fmul double %122, 3.000000e+00
  %124 = load double, ptr @h, align 8, !tbaa !5
  %125 = fadd double %124, %1
  %126 = fmul double %123, %125
  %127 = tail call double @_ZL9__tg_coshd(double noundef %126)
  %128 = fpext double %127 to x86_fp80
  %129 = fmul x86_fp80 %121, %128
  %130 = load double, ptr @h, align 8, !tbaa !5
  %131 = fmul double %130, 3.000000e+00
  %132 = load double, ptr @k, align 8, !tbaa !5
  %133 = fmul double %131, %132
  %134 = tail call double @_ZL9__tg_coshd(double noundef %133)
  %135 = fmul double %134, %91
  %136 = fpext double %135 to x86_fp80
  %137 = fdiv x86_fp80 %129, %136
  %138 = load double, ptr @a, align 8, !tbaa !5
  %139 = load double, ptr @g, align 8, !tbaa !5
  %140 = fmul double %138, %139
  %141 = load double, ptr @k, align 8, !tbaa !5
  %142 = fmul double %140, %141
  %143 = fmul double %141, %0
  %144 = tail call double @_ZL8__tg_cosd(double noundef %143)
  %145 = fmul double %142, %144
  %146 = load double, ptr @k, align 8, !tbaa !5
  %147 = load double, ptr @h, align 8, !tbaa !5
  %148 = fadd double %147, %1
  %149 = fmul double %146, %148
  %150 = tail call double @_ZL9__tg_coshd(double noundef %149)
  %151 = fmul double %145, %150
  %152 = load double, ptr @h, align 8, !tbaa !5
  %153 = load double, ptr @k, align 8, !tbaa !5
  %154 = fmul double %152, %153
  %155 = tail call double @_ZL9__tg_coshd(double noundef %154)
  %156 = fmul double %155, %91
  %157 = fdiv double %151, %156
  %158 = fpext double %157 to x86_fp80
  %159 = fadd x86_fp80 %137, %158
  %160 = load double, ptr @a, align 8, !tbaa !5
  %161 = fpext double %160 to x86_fp80
  %162 = fmul x86_fp80 %161, 0xK3FFEC000000000000000
  %163 = fmul x86_fp80 %162, %18
  %164 = load double, ptr @g, align 8, !tbaa !5
  %165 = fpext double %164 to x86_fp80
  %166 = fmul x86_fp80 %163, %165
  %167 = load double, ptr @k, align 8, !tbaa !5
  %168 = fpext double %167 to x86_fp80
  %169 = fmul x86_fp80 %166, %168
  %170 = tail call double @_ZL8__tg_powdd(double noundef %12, double noundef 2.000000e+00)
  %171 = fadd double %170, -1.000000e+00
  %172 = tail call double @_ZL8__tg_powdd(double noundef %171, double noundef 2.000000e+00)
  %173 = fpext double %172 to x86_fp80
  %174 = fmul x86_fp80 %169, %173
  %175 = load double, ptr @k, align 8, !tbaa !5
  %176 = fmul double %175, 2.000000e+00
  %177 = fmul double %176, %0
  %178 = tail call double @_ZL8__tg_cosd(double noundef %177)
  %179 = fpext double %178 to x86_fp80
  %180 = fmul x86_fp80 %174, %179
  %181 = load double, ptr @k, align 8, !tbaa !5
  %182 = fmul double %181, 2.000000e+00
  %183 = load double, ptr @h, align 8, !tbaa !5
  %184 = fadd double %183, %1
  %185 = fmul double %182, %184
  %186 = tail call double @_ZL9__tg_coshd(double noundef %185)
  %187 = fpext double %186 to x86_fp80
  %188 = fmul x86_fp80 %180, %187
  %189 = fmul double %12, %91
  %190 = load double, ptr @h, align 8, !tbaa !5
  %191 = fmul double %190, 2.000000e+00
  %192 = load double, ptr @k, align 8, !tbaa !5
  %193 = fmul double %191, %192
  %194 = tail call double @_ZL9__tg_coshd(double noundef %193)
  %195 = fmul double %189, %194
  %196 = fpext double %195 to x86_fp80
  %197 = fdiv x86_fp80 %188, %196
  %198 = fadd x86_fp80 %159, %197
  %199 = fptrunc x86_fp80 %198 to double
  %200 = load double, ptr @a, align 8, !tbaa !5
  %201 = fpext double %200 to x86_fp80
  %202 = fmul x86_fp80 %201, 0xK3FFAC000000000000000
  %203 = tail call double @_ZL8__tg_powdd(double noundef %8, double noundef 2.000000e+00)
  %204 = fpext double %203 to x86_fp80
  %205 = fmul x86_fp80 %202, %204
  %206 = load double, ptr @g, align 8, !tbaa !5
  %207 = fpext double %206 to x86_fp80
  %208 = fmul x86_fp80 %205, %207
  %209 = load double, ptr @k, align 8, !tbaa !5
  %210 = fpext double %209 to x86_fp80
  %211 = fmul x86_fp80 %208, %210
  %212 = tail call double @_ZL8__tg_powdd(double noundef %12, double noundef 2.000000e+00)
  %213 = fadd double %212, -1.000000e+00
  %214 = fpext double %213 to x86_fp80
  %215 = fmul x86_fp80 %211, %214
  %216 = tail call double @_ZL8__tg_powdd(double noundef %12, double noundef 2.000000e+00)
  %217 = fadd double %216, 3.000000e+00
  %218 = fpext double %217 to x86_fp80
  %219 = fmul x86_fp80 %215, %218
  %220 = tail call double @_ZL8__tg_powdd(double noundef %12, double noundef 2.000000e+00)
  %221 = tail call double @llvm.fmuladd.f64(double %220, double 9.000000e+00, double -1.300000e+01)
  %222 = fpext double %221 to x86_fp80
  %223 = fmul x86_fp80 %219, %222
  %224 = load double, ptr @k, align 8, !tbaa !5
  %225 = fmul double %224, 3.000000e+00
  %226 = fmul double %225, %0
  %227 = tail call double @_ZL8__tg_sind(double noundef %226)
  %228 = fpext double %227 to x86_fp80
  %229 = fmul x86_fp80 %223, %228
  %230 = load double, ptr @k, align 8, !tbaa !5
  %231 = fmul double %230, 3.000000e+00
  %232 = load double, ptr @h, align 8, !tbaa !5
  %233 = fadd double %232, %1
  %234 = fmul double %231, %233
  %235 = tail call double @_ZL9__tg_sinhd(double noundef %234)
  %236 = fpext double %235 to x86_fp80
  %237 = fmul x86_fp80 %229, %236
  %238 = load double, ptr @h, align 8, !tbaa !5
  %239 = fmul double %238, 3.000000e+00
  %240 = load double, ptr @k, align 8, !tbaa !5
  %241 = fmul double %239, %240
  %242 = tail call double @_ZL9__tg_coshd(double noundef %241)
  %243 = fmul double %242, %91
  %244 = fpext double %243 to x86_fp80
  %245 = fdiv x86_fp80 %237, %244
  %246 = load double, ptr @a, align 8, !tbaa !5
  %247 = load double, ptr @g, align 8, !tbaa !5
  %248 = fmul double %246, %247
  %249 = load double, ptr @k, align 8, !tbaa !5
  %250 = fmul double %248, %249
  %251 = fmul double %249, %0
  %252 = tail call double @_ZL8__tg_sind(double noundef %251)
  %253 = fmul double %250, %252
  %254 = load double, ptr @k, align 8, !tbaa !5
  %255 = load double, ptr @h, align 8, !tbaa !5
  %256 = fadd double %255, %1
  %257 = fmul double %254, %256
  %258 = tail call double @_ZL9__tg_sinhd(double noundef %257)
  %259 = fmul double %253, %258
  %260 = load double, ptr @h, align 8, !tbaa !5
  %261 = load double, ptr @k, align 8, !tbaa !5
  %262 = fmul double %260, %261
  %263 = tail call double @_ZL9__tg_coshd(double noundef %262)
  %264 = fmul double %263, %91
  %265 = fdiv double %259, %264
  %266 = fpext double %265 to x86_fp80
  %267 = fadd x86_fp80 %245, %266
  %268 = load double, ptr @a, align 8, !tbaa !5
  %269 = fpext double %268 to x86_fp80
  %270 = fmul x86_fp80 %269, 0xK3FFEC000000000000000
  %271 = fmul x86_fp80 %270, %18
  %272 = load double, ptr @g, align 8, !tbaa !5
  %273 = fpext double %272 to x86_fp80
  %274 = fmul x86_fp80 %271, %273
  %275 = load double, ptr @k, align 8, !tbaa !5
  %276 = fpext double %275 to x86_fp80
  %277 = fmul x86_fp80 %274, %276
  %278 = tail call double @_ZL8__tg_powdd(double noundef %12, double noundef 2.000000e+00)
  %279 = fadd double %278, -1.000000e+00
  %280 = tail call double @_ZL8__tg_powdd(double noundef %279, double noundef 2.000000e+00)
  %281 = fpext double %280 to x86_fp80
  %282 = fmul x86_fp80 %277, %281
  %283 = load double, ptr @k, align 8, !tbaa !5
  %284 = fmul double %283, 2.000000e+00
  %285 = fmul double %284, %0
  %286 = tail call double @_ZL8__tg_sind(double noundef %285)
  %287 = fpext double %286 to x86_fp80
  %288 = fmul x86_fp80 %282, %287
  %289 = load double, ptr @k, align 8, !tbaa !5
  %290 = fmul double %289, 2.000000e+00
  %291 = load double, ptr @h, align 8, !tbaa !5
  %292 = fadd double %291, %1
  %293 = fmul double %290, %292
  %294 = tail call double @_ZL9__tg_sinhd(double noundef %293)
  %295 = fpext double %294 to x86_fp80
  %296 = fmul x86_fp80 %288, %295
  %297 = load double, ptr @h, align 8, !tbaa !5
  %298 = fmul double %297, 2.000000e+00
  %299 = load double, ptr @k, align 8, !tbaa !5
  %300 = fmul double %298, %299
  %301 = tail call double @_ZL9__tg_coshd(double noundef %300)
  %302 = fmul double %189, %301
  %303 = fpext double %302 to x86_fp80
  %304 = fdiv x86_fp80 %296, %303
  %305 = fadd x86_fp80 %267, %304
  %306 = fptrunc x86_fp80 %305 to double
  store double %199, ptr %2, align 8, !tbaa !5
  store double %306, ptr %3, align 8, !tbaa !5
  store double %68, ptr %4, align 8, !tbaa !5
  ret void
}

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

; Function Attrs: alwaysinline nounwind uwtable
declare hidden x86_fp80 @_ZL9__tg_sqrte(x86_fp80 noundef) local_unnamed_addr #0

attributes #0 = { alwaysinline 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 speculatable willreturn memory(none) }
attributes #2 = { 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" }

!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"}


; Effective O3 passes: EarlyCSEPass,GlobalOptPass,InferFunctionAttrsPass,InstCombinePass,PostOrderFunctionAttrsPass,ReassociatePass,SROAPass,TailCallElimPass