source_filename = "test"
target datalayout = "e-p:32:32-f64:32:64-f80:32-n8:16:32-S128"

@eax = internal unnamed_addr global i32 0, align 8
@ecx = internal unnamed_addr global i32 0, align 8
@edx = internal unnamed_addr global i32 0, align 8

define i32 @function_0(i32 %arg1) local_unnamed_addr {
dec_label_pc_0:
  %ebx.global-to-local = alloca i32, align 4
  %edi.global-to-local = alloca i32, align 4
  %esi.global-to-local = alloca i32, align 4
  %fpsw.global-to-local = alloca i32, align 4
  %fpu_stat_TOP.global-to-local = alloca i3, align 1
  %st5.global-to-local = alloca x86_fp80, align 4
  %st6.global-to-local = alloca x86_fp80, align 4
  %v0_6 = load i32, i32* %ebx.global-to-local, align 4
  %v0_7 = load i32, i32* %esi.global-to-local, align 4
  %v0_8 = load i32, i32* %edi.global-to-local, align 4
  %v0_9 = load i32, i32* @ecx, align 8
  store i32 %v0_9, i32* %edi.global-to-local, align 4
  %v0_b = load i32, i32* @edx, align 8
  store i32 %v0_b, i32* %esi.global-to-local, align 4
  %v0_d = load i32, i32* @eax, align 8
  store i32 %arg1, i32* @eax, align 8
  %v1_19 = add i32 %arg1, 48
  %v2_19 = inttoptr i32 %v1_19 to i32*
  %v3_19 = load i32, i32* %v2_19, align 4
  store i32 %v3_19, i32* %ebx.global-to-local, align 4
  %v0_1c = load i3, i3* %fpu_stat_TOP.global-to-local, align 1
  %v3_1e = load double, double* bitcast (i32* @edx to double*), align 8
  %v4_1e = fpext double %v3_1e to x86_fp80
  %v5_1e = add i3 %v0_1c, -2
  store i3 %v5_1e, i3* %fpu_stat_TOP.global-to-local, align 1
  store x86_fp80 %v4_1e, x86_fp80* %st6.global-to-local, align 4
  %v3_20 = call i32 @__asm_fpatan(i32 %v0_8, i32 %v0_7, i32 %v0_6)
  %v1_22 = load x86_fp80, x86_fp80* %st6.global-to-local, align 4
  %v0_28 = load i32, i32* %ebx.global-to-local, align 4
  %v1_28 = add i32 %v0_28, 32
  store i32 %v1_28, i32* @eax, align 8
  %v3_2b = inttoptr i32 %v1_28 to double*
  %v4_2b = load double, double* %v3_2b, align 4
  %v5_2b = fpext double %v4_2b to x86_fp80
  %v6_2b = fadd x86_fp80 %v1_22, %v5_2b
  store x86_fp80 %v6_2b, x86_fp80* %st6.global-to-local, align 4
  %v0_2d = load i3, i3* %fpu_stat_TOP.global-to-local, align 1
  %v6_2d = add i3 %v0_2d, 1
  store i3 %v6_2d, i3* %fpu_stat_TOP.global-to-local, align 1
  %v0_30 = call i32 @__asm_wait()
  store i32 %v0_30, i32* @eax, align 8
  br label %dec_label_pc_53

dec_label_pc_3b:                                  ; preds = %dec_label_pc_53
  store x86_fp80 %stack_var_-20.0.in, x86_fp80* %st6.global-to-local, align 4
  %v0_3e = load i32, i32* %ebx.global-to-local, align 4
  %v1_3e = add i32 %v0_3e, 8
  store i32 %v1_3e, i32* @eax, align 8
  %v3_41 = inttoptr i32 %v1_3e to double*
  %v4_41 = load double, double* %v3_41, align 4
  %v5_41 = fpext double %v4_41 to x86_fp80
  %v6_41 = fsub x86_fp80 %stack_var_-20.0.in, %v5_41
  store x86_fp80 %v6_41, x86_fp80* %st6.global-to-local, align 4
  store i3 %v0_5d, i3* %fpu_stat_TOP.global-to-local, align 1
  %v0_46 = call i32 @__asm_wait()
  store x86_fp80 %stack_var_-28.0, x86_fp80* %st6.global-to-local, align 4
  %v0_4a = load i32, i32* %ebx.global-to-local, align 4
  %v1_4a = add i32 %v0_4a, 8
  store i32 %v1_4a, i32* @eax, align 8
  %v3_4d = inttoptr i32 %v1_4a to double*
  %v4_4d = load double, double* %v3_4d, align 4
  %v5_4d = fpext double %v4_4d to x86_fp80
  %v6_4d = fsub x86_fp80 %stack_var_-28.0, %v5_4d
  store x86_fp80 %v6_4d, x86_fp80* %st6.global-to-local, align 4
  %v0_52 = call i32 @__asm_wait()
  br label %dec_label_pc_53

dec_label_pc_53:                                  ; preds = %dec_label_pc_3b, %dec_label_pc_0
  %storemerge = phi i32 [ 0, %dec_label_pc_0 ], [ %v0_52, %dec_label_pc_3b ]
  %stack_var_-28.0 = phi x86_fp80 [ 0xK00000000000000000000, %dec_label_pc_0 ], [ %v6_4d, %dec_label_pc_3b ]
  %stack_var_-20.0.in = phi x86_fp80 [ %v6_2b, %dec_label_pc_0 ], [ %v6_41, %dec_label_pc_3b ]
  store i32 %storemerge, i32* @eax, align 8
  store x86_fp80 %stack_var_-20.0.in, x86_fp80* %st6.global-to-local, align 4
  %v0_58 = load i32, i32* %fpsw.global-to-local, align 4
  %v1_58 = call i16 @__asm_fnstsw(i32 %v0_58)
  %v2_58 = sext i16 %v1_58 to i32
  %v3_58 = load i32, i32* @eax, align 8
  %v4_58 = and i32 %v3_58, -65536
  %v5_58 = or i32 %v4_58, %v2_58
  store i32 %v5_58, i32* @eax, align 8
  %tmp257 = and i32 %v2_58, 16640
  %tmp258 = icmp eq i32 %tmp257, 0
  %v0_5d = load i3, i3* %fpu_stat_TOP.global-to-local, align 1
  %v6_3b = add i3 %v0_5d, -1
  store i3 %v6_3b, i3* %fpu_stat_TOP.global-to-local, align 1
  br i1 %tmp258, label %dec_label_pc_3b, label %dec_label_pc_5d

dec_label_pc_5d:                                  ; preds = %dec_label_pc_53
  %v4_d = inttoptr i32 %v0_d to double*
  store x86_fp80 %stack_var_-28.0, x86_fp80* %st6.global-to-local, align 4
  %v2_60 = call x86_fp80 @llvm.fabs.f80(x86_fp80 %stack_var_-28.0)
  %v3_60 = fcmp olt x86_fp80 %v2_60, 0xK403E8000000000000000
  br i1 %v3_60, label %bb, label %dec_label_pc_5d._crit_edge

dec_label_pc_5d._crit_edge:                       ; preds = %dec_label_pc_5d
  %v1_62.pre = load x86_fp80, x86_fp80* %st5.global-to-local, align 4
  br label %bb259

bb:                                               ; preds = %dec_label_pc_5d
  %v4_60 = call x86_fp80 @llvm.sin.f80(x86_fp80 %stack_var_-28.0)
  store x86_fp80 %v4_60, x86_fp80* %st6.global-to-local, align 4
  %v7_60 = call x86_fp80 @llvm.cos.f80(x86_fp80 %stack_var_-28.0)
  %v8_60 = add i3 %v0_5d, -2
  store i3 %v8_60, i3* %fpu_stat_TOP.global-to-local, align 1
  store x86_fp80 %v7_60, x86_fp80* %st5.global-to-local, align 4
  br label %bb259

bb259:                                            ; preds = %dec_label_pc_5d._crit_edge, %bb
  %v1_65 = phi x86_fp80 [ %stack_var_-28.0, %dec_label_pc_5d._crit_edge ], [ %v4_60, %bb ]
  %v1_62 = phi x86_fp80 [ %v1_62.pre, %dec_label_pc_5d._crit_edge ], [ %v7_60, %bb ]
  %v0_62 = phi i3 [ %v6_3b, %dec_label_pc_5d._crit_edge ], [ %v8_60, %bb ]
  %v6_65 = add i3 %v0_62, 2
  %v3_68 = load double, double* bitcast (i32* @edx to double*), align 8
  %v4_68 = fpext double %v3_68 to x86_fp80
  %v7_6a = fmul x86_fp80 %v1_62, %v4_68
  %v3_6d = load double, double* bitcast (i32* @ecx to double*), align 8
  %v4_6d = fpext double %v3_6d to x86_fp80
  %v7_6f = fmul x86_fp80 %v1_65, %v4_6d
  store x86_fp80 %v7_6f, x86_fp80* %st5.global-to-local, align 4
  %v4_72 = fsub x86_fp80 %v7_6a, %v7_6f
  store x86_fp80 %v4_72, x86_fp80* %st6.global-to-local, align 4
  store i3 %v6_65, i3* %fpu_stat_TOP.global-to-local, align 1
  %v0_77 = call i32 @__asm_wait()
  store i32 %v0_77, i32* @eax, align 8
  %v3_78 = load double, double* bitcast (i32* @edx to double*), align 8
  %v4_78 = fpext double %v3_78 to x86_fp80
  %v7_7a = fmul x86_fp80 %v1_65, %v4_78
  %v3_7d = load double, double* bitcast (i32* @ecx to double*), align 8
  %v4_7d = fpext double %v3_7d to x86_fp80
  %v7_7f = fmul x86_fp80 %v1_62, %v4_7d
  store x86_fp80 %v7_7f, x86_fp80* %st5.global-to-local, align 4
  %v4_82 = fadd x86_fp80 %v7_7a, %v7_7f
  store x86_fp80 %v4_82, x86_fp80* %st6.global-to-local, align 4
  %v0_87 = call i32 @__asm_wait()
  %tmp260 = fptrunc x86_fp80 %v4_72 to float
  %v5_88 = bitcast float %tmp260 to i32
  %v1_8b = load i32, i32* %esi.global-to-local, align 4
  %v2_8b = inttoptr i32 %v1_8b to i32*
  store i32 %v5_88, i32* %v2_8b, align 4
  %v1_90 = load i32, i32* %esi.global-to-local, align 4
  %v2_90 = add i32 %v1_90, 4
  %v3_90 = inttoptr i32 %v2_90 to i32*
  %tmp261 = fptrunc x86_fp80 %v4_82 to float
  %v5_93 = bitcast float %tmp261 to i32
  %v1_96 = load i32, i32* %edi.global-to-local, align 4
  %v2_96 = inttoptr i32 %v1_96 to i32*
  store i32 %v5_93, i32* %v2_96, align 4
  %v1_9b = load i32, i32* %edi.global-to-local, align 4
  %v2_9b = add i32 %v1_9b, 4
  %v3_9b = inttoptr i32 %v2_9b to i32*
  %v3_9e = load double, double* bitcast (i32* @ecx to double*), align 8
  %v4_9e = fpext double %v3_9e to x86_fp80
  %v6_a0 = fmul x86_fp80 %v4_9e, %v4_9e
  store i32 %v0_d, i32* @eax, align 8
  %v3_a5 = load double, double* bitcast (i32* @eax to double*), align 8
  %v4_a5 = fpext double %v3_a5 to x86_fp80
  store i32 %v0_d, i32* @eax, align 8
  %v4_aa = load double, double* bitcast (i32* @eax to double*), align 8
  %v5_aa = fpext double %v4_aa to x86_fp80
  %v6_aa = fmul x86_fp80 %v4_a5, %v5_aa
  %v3_ac = load double, double* bitcast (i32* @edx to double*), align 8
  %v4_ac = fpext double %v3_ac to x86_fp80
  %v6_ae = fmul x86_fp80 %v4_ac, %v4_ac
  %v4_b0 = fadd x86_fp80 %v6_aa, %v6_ae
  %v4_b6 = fadd x86_fp80 %v6_a0, %v4_b0
  store x86_fp80 %v4_b6, x86_fp80* %st5.global-to-local, align 4
  %v4_b8 = fdiv x86_fp80 %v6_a0, %v4_b6
  store x86_fp80 %v4_b8, x86_fp80* %st6.global-to-local, align 4
  %v0_ba = load i32, i32* %ebx.global-to-local, align 4
  %v1_ba = add i32 %v0_ba, 16
  store i32 %v1_ba, i32* @eax, align 8
  %v3_bd = inttoptr i32 %v1_ba to double*
  %v4_bd = load double, double* %v3_bd, align 4
  %v5_bd = fpext double %v4_bd to x86_fp80
  %v6_bd = fsub x86_fp80 %v5_bd, %v4_b8
  store x86_fp80 %v6_bd, x86_fp80* %st6.global-to-local, align 4
  %v0_c2 = call i32 @__asm_wait()
  store i32 %v0_d, i32* @eax, align 8
  %v3_c6 = load double, double* bitcast (i32* @eax to double*), align 8
  %v4_c6 = fpext double %v3_c6 to x86_fp80
  store i32 %v0_d, i32* @eax, align 8
  %v4_cb = load double, double* bitcast (i32* @eax to double*), align 8
  %v5_cb = fpext double %v4_cb to x86_fp80
  %v6_cb = fmul x86_fp80 %v4_c6, %v5_cb
  %v3_cd = load double, double* bitcast (i32* @edx to double*), align 8
  %v4_cd = fpext double %v3_cd to x86_fp80
  %v6_cf = fmul x86_fp80 %v4_cd, %v4_cd
  store x86_fp80 %v6_cf, x86_fp80* %st5.global-to-local, align 4
  %v4_d1 = fsub x86_fp80 %v6_cb, %v6_cf
  %v7_d3 = fmul x86_fp80 %v4_d1, %v6_bd
  store x86_fp80 %v7_d3, x86_fp80* %st6.global-to-local, align 4
  %v0_d9 = call i32 @__asm_wait()
  %v0_da = load i32, i32* %ebx.global-to-local, align 4
  %v1_da = add i32 %v0_da, 24
  store i32 %v1_da, i32* @eax, align 8
  %v2_dd = inttoptr i32 %v1_da to double*
  %v3_dd = load double, double* %v2_dd, align 4
  %v4_dd = fpext double %v3_dd to x86_fp80
  store i32 %v0_d, i32* @eax, align 8
  %v4_e2 = load double, double* bitcast (i32* @eax to double*), align 8
  %v5_e2 = fpext double %v4_e2 to x86_fp80
  %v6_e2 = fmul x86_fp80 %v4_dd, %v5_e2
  %v4_e4 = load double, double* bitcast (i32* @edx to double*), align 8
  %v5_e4 = fpext double %v4_e4 to x86_fp80
  %v6_e4 = fmul x86_fp80 %v6_e2, %v5_e4
  %v7_e6 = fmul x86_fp80 %v6_e4, %v6_bd
  store x86_fp80 %v7_e6, x86_fp80* %st6.global-to-local, align 4
  %v0_ec = call i32 @__asm_wait()
  store i32 %v0_d, i32* @eax, align 8
  %v3_f0 = load double, double* bitcast (i32* @eax to double*), align 8
  %v4_f0 = fpext double %v3_f0 to x86_fp80
  store i32 %v0_d, i32* @eax, align 8
  %v4_f5 = load double, double* bitcast (i32* @eax to double*), align 8
  %v5_f5 = fpext double %v4_f5 to x86_fp80
  %v6_f5 = fmul x86_fp80 %v4_f0, %v5_f5
  %v3_f7 = load double, double* bitcast (i32* @edx to double*), align 8
  %v4_f7 = fpext double %v3_f7 to x86_fp80
  %v6_f9 = fmul x86_fp80 %v4_f7, %v4_f7
  store x86_fp80 %v6_f9, x86_fp80* %st5.global-to-local, align 4
  %v4_fb = fadd x86_fp80 %v6_f5, %v6_f9
  %v2_fd = call x86_fp80 @llvm.sqrt.f80(x86_fp80 %v4_fb)
  store x86_fp80 %v2_fd, x86_fp80* %st6.global-to-local, align 4
  %v0_ff = load i32, i32* %ebx.global-to-local, align 4
  %v1_ff = add i32 %v0_ff, 24
  store i32 %v1_ff, i32* %ebx.global-to-local, align 4
  %v2_102 = inttoptr i32 %v1_ff to double*
  %v3_102 = load double, double* %v2_102, align 4
  %v4_102 = fpext double %v3_102 to x86_fp80
  %v4_104 = load double, double* bitcast (i32* @ecx to double*), align 8
  %v5_104 = fpext double %v4_104 to x86_fp80
  %v6_104 = fmul x86_fp80 %v4_102, %v5_104
  store x86_fp80 %v6_104, x86_fp80* %st5.global-to-local, align 4
  %v4_106 = fmul x86_fp80 %v2_fd, %v6_104
  store x86_fp80 %v4_106, x86_fp80* %st6.global-to-local, align 4
  %v0_10b = call i32 @__asm_wait()
  store x86_fp80 %v7_d3, x86_fp80* %st6.global-to-local, align 4
  store i32 %arg1, i32* @eax, align 8
  %v3_112 = add i32 %arg1, 24
  %v4_112 = inttoptr i32 %v3_112 to double*
  %v5_112 = load double, double* %v4_112, align 4
  %v6_112 = fpext double %v5_112 to x86_fp80
  %v7_112 = fadd x86_fp80 %v7_d3, %v6_112
  store x86_fp80 %v7_112, x86_fp80* %st6.global-to-local, align 4
  store i32 %v0_d, i32* @eax, align 8
  %v3_118 = fptrunc x86_fp80 %v7_112 to double
  store double %v3_118, double* %v4_d, align 4
  %v0_11a = call i32 @__asm_wait()
  %v7_11e = fmul x86_fp80 %v1_62, %v7_e6
  %v7_124 = fmul x86_fp80 %v1_65, %v4_106
  store x86_fp80 %v7_124, x86_fp80* %st5.global-to-local, align 4
  %v4_127 = fadd x86_fp80 %v7_11e, %v7_124
  store x86_fp80 %v4_127, x86_fp80* %st6.global-to-local, align 4
  store i32 %arg1, i32* @eax, align 8
  %v3_12c = add i32 %arg1, 32
  %v4_12c = inttoptr i32 %v3_12c to double*
  %v5_12c = load double, double* %v4_12c, align 4
  %v6_12c = fpext double %v5_12c to x86_fp80
  %v7_12c = fadd x86_fp80 %v4_127, %v6_12c
  store x86_fp80 %v7_12c, x86_fp80* %st6.global-to-local, align 4
  %v2_12f = load i32, i32* %esi.global-to-local, align 4
  %v3_12f = fptrunc x86_fp80 %v7_12c to double
  %v4_12f = inttoptr i32 %v2_12f to double*
  store double %v3_12f, double* %v4_12f, align 4
  %v0_131 = call i32 @__asm_wait()
  %v7_135 = fmul x86_fp80 %v1_62, %v4_106
  %v7_13b = fmul x86_fp80 %v1_65, %v7_e6
  store x86_fp80 %v7_13b, x86_fp80* %st5.global-to-local, align 4
  %v4_13e = fsub x86_fp80 %v7_135, %v7_13b
  store x86_fp80 %v4_13e, x86_fp80* %st6.global-to-local, align 4
  store i32 %arg1, i32* @eax, align 8
  %v3_143 = add i32 %arg1, 40
  %v4_143 = inttoptr i32 %v3_143 to double*
  %v5_143 = load double, double* %v4_143, align 4
  %v6_143 = fpext double %v5_143 to x86_fp80
  %v7_143 = fadd x86_fp80 %v4_13e, %v6_143
  store x86_fp80 %v7_143, x86_fp80* %st6.global-to-local, align 4
  %v2_146 = load i32, i32* %edi.global-to-local, align 4
  %v3_146 = fptrunc x86_fp80 %v7_143 to double
  %v4_146 = inttoptr i32 %v2_146 to double*
  store double %v3_146, double* %v4_146, align 4
  %v0_148 = call i32 @__asm_wait()
  store i32 %v0_148, i32* @eax, align 8
  store i32 %v0_8, i32* %edi.global-to-local, align 4
  store i32 %v0_7, i32* %esi.global-to-local, align 4
  store i32 %v0_6, i32* %ebx.global-to-local, align 4
  ret i32 %v0_148
}

declare i32 @__asm_fpatan(i32, i32, i32) local_unnamed_addr

declare i32 @__asm_wait() local_unnamed_addr

declare i16 @__asm_fnstsw(i32) local_unnamed_addr

; Function Attrs: nounwind readnone speculatable
declare x86_fp80 @llvm.fabs.f80(x86_fp80) #0

; Function Attrs: nounwind readnone speculatable
declare x86_fp80 @llvm.sin.f80(x86_fp80) #0

; Function Attrs: nounwind readnone speculatable
declare x86_fp80 @llvm.cos.f80(x86_fp80) #0

; Function Attrs: nounwind readnone speculatable
declare x86_fp80 @llvm.sqrt.f80(x86_fp80) #0

attributes #0 = { nounwind readnone speculatable }
