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

@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:
  %edi.global-to-local = alloca i32, align 4
  %esi.global-to-local = alloca i32, align 4
  %fpu_stat_TOP.global-to-local = alloca i3, align 1
  %st2.global-to-local = alloca x86_fp80, align 4
  %st3.global-to-local = alloca x86_fp80, align 4
  %st4.global-to-local = alloca x86_fp80, align 4
  %st7.global-to-local = alloca x86_fp80, align 4
  %v0_3 = load i32, i32* %esi.global-to-local, align 4
  %v0_4 = load i32, i32* %edi.global-to-local, align 4
  store i32 %arg1, i32* %esi.global-to-local, align 4
  %v1_8 = add i32 %arg1, 48
  %v2_8 = inttoptr i32 %v1_8 to i32*
  %v3_8 = load i32, i32* %v2_8, align 4
  store i32 %v3_8, i32* %edi.global-to-local, align 4
  %v0_b = load i3, i3* %fpu_stat_TOP.global-to-local, align 1
  store x86_fp80 0xK3FFF8000000000000000, x86_fp80* %st7.global-to-local, align 4
  %v1_d = add i32 %v3_8, -12
  %v2_d = inttoptr i32 %v1_d to i32*
  %v3_d = load i32, i32* %v2_d, align 4
  %v6_10 = add i3 %v0_b, -2
  store i3 %v6_10, i3* %fpu_stat_TOP.global-to-local, align 1
  br label %dec_label_pc_19

dec_label_pc_19:                                  ; preds = %dec_label_pc_19, %dec_label_pc_0
  %v2_1912 = phi i32 [ %v3_d, %dec_label_pc_0 ], [ %v2_19, %dec_label_pc_19 ]
  %v2_19 = udiv i32 %v2_1912, 2
  %tmp261 = icmp ult i32 %v2_1912, 2
  %v9_19 = urem i32 %v2_1912, 2
  %v10_19 = icmp ne i32 %v9_19, 0
  %tmp257 = icmp eq i1 %v10_19, %tmp261
  br i1 %tmp257, label %dec_label_pc_21, label %dec_label_pc_19

dec_label_pc_21:                                  ; preds = %dec_label_pc_19
  store x86_fp80 0xK00000000000000000000, x86_fp80* %st7.global-to-local, align 4
  %v1_27 = load i32, i32* @edx, align 8
  %v2_27 = add i32 %v1_27, -8
  %v3_27 = inttoptr i32 %v2_27 to double*
  %v4_27 = load double, double* %v3_27, align 4
  %v5_27 = fpext double %v4_27 to x86_fp80
  %v3_2a = load double, double* bitcast (i32* @edx to double*), align 8
  %v4_2a = fpext double %v3_2a to x86_fp80
  store x86_fp80 %v4_2a, x86_fp80* %st4.global-to-local, align 4
  %v3_2c = load double, double* bitcast (i32* @ecx to double*), align 8
  %v4_2c = fpext double %v3_2c to x86_fp80
  store x86_fp80 %v4_2c, x86_fp80* %st3.global-to-local, align 4
  %v3_2e = add i3 %v0_b, 1
  %v3_30 = fmul x86_fp80 %v5_27, %v5_27
  %v3_34 = fmul x86_fp80 %v4_2a, %v4_2a
  %v4_36 = fadd x86_fp80 %v3_30, %v3_34
  store i3 %v3_2e, i3* %fpu_stat_TOP.global-to-local, align 1
  %v2_38 = call x86_fp80 @llvm.sqrt.f80(x86_fp80 %v4_36)
  store x86_fp80 %v2_38, x86_fp80* %st2.global-to-local, align 4
  %v0_3a = call i32 @__asm_fpatan()
  %v3_3c = load x86_fp80, x86_fp80* %st4.global-to-local, align 4
  store x86_fp80 %v3_3c, x86_fp80* %st2.global-to-local, align 4
  store x86_fp80 %v2_38, x86_fp80* %st4.global-to-local, align 4
  %v0_3e = call i32 @__asm_fpatan()
  %v0_40 = load i3, i3* %fpu_stat_TOP.global-to-local, align 1
  %v1_40 = load i32, i32* %edi.global-to-local, align 4
  %v2_40 = add i32 %v1_40, -16
  %v3_40 = inttoptr i32 %v2_40 to float*
  %v4_40 = load float, float* %v3_40, align 4
  %v5_40 = fpext float %v4_40 to x86_fp80
  %v2_43 = load x86_fp80, x86_fp80* %st3.global-to-local, align 4
  %v4_43 = fmul x86_fp80 %v2_43, %v5_40
  store x86_fp80 %v4_43, x86_fp80* %st3.global-to-local, align 4
  %v3_45 = load x86_fp80, x86_fp80* %st2.global-to-local, align 4
  %v4_45 = fmul x86_fp80 %v3_45, %v5_40
  store x86_fp80 %v4_45, x86_fp80* %st2.global-to-local, align 4
  %v1_47 = add i32 %v1_40, -24
  %v2_47 = inttoptr i32 %v1_47 to i32*
  %v3_47 = load i32, i32* %v2_47, align 4
  %v10_47 = icmp eq i32 %v3_47, 0
  br i1 %v10_47, label %dec_label_pc_4f, label %dec_label_pc_4d

dec_label_pc_4d:                                  ; preds = %dec_label_pc_21
  store x86_fp80 %v4_43, x86_fp80* %st2.global-to-local, align 4
  store x86_fp80 %v4_45, x86_fp80* %st3.global-to-local, align 4
  br label %dec_label_pc_4f

dec_label_pc_4f:                                  ; preds = %dec_label_pc_4d, %dec_label_pc_21
  %v2_66 = phi x86_fp80 [ %v4_45, %dec_label_pc_4d ], [ %v4_43, %dec_label_pc_21 ]
  %v3_68 = phi x86_fp80 [ %v4_43, %dec_label_pc_4d ], [ %v4_45, %dec_label_pc_21 ]
  %v1_4f = add i32 %v1_40, -32
  %v2_4f = inttoptr i32 %v1_4f to i32*
  %v3_4f = load i32, i32* %v2_4f, align 4
  %v10_4f = icmp eq i32 %v3_4f, 0
  br i1 %v10_4f, label %dec_label_pc_6a, label %dec_label_pc_55

dec_label_pc_55:                                  ; preds = %dec_label_pc_4f
  %v3_57 = fmul x86_fp80 %v2_66, %v2_66
  %v3_5b = fmul x86_fp80 %v3_68, %v3_68
  %v4_5d = fadd x86_fp80 %v3_5b, %v3_57
  %v3_5f = add i32 %v1_40, -36
  %v4_5f = inttoptr i32 %v3_5f to float*
  %v5_5f = load float, float* %v4_5f, align 4
  %v6_5f = fpext float %v5_5f to x86_fp80
  %v7_5f = fadd x86_fp80 %v4_5d, %v6_5f
  %v4_64 = fdiv x86_fp80 0xK3FFF8000000000000000, %v7_5f
  %v4_66 = fmul x86_fp80 %v2_66, %v4_64
  store x86_fp80 %v4_66, x86_fp80* %st3.global-to-local, align 4
  %v4_68 = fmul x86_fp80 %v3_68, %v4_64
  store x86_fp80 %v4_68, x86_fp80* %st2.global-to-local, align 4
  br label %dec_label_pc_6a

dec_label_pc_6a:                                  ; preds = %dec_label_pc_55, %dec_label_pc_4f
  %v1_6a = add i32 %v1_40, -28
  %v2_6a = inttoptr i32 %v1_6a to i32*
  %v3_6a = load i32, i32* %v2_6a, align 4
  %st7.promoted = load x86_fp80, x86_fp80* %st7.global-to-local, align 4
  br label %dec_label_pc_7f

dec_label_pc_6f:                                  ; preds = %dec_label_pc_83, %dec_label_pc_7f
  %v4_959 = phi x86_fp80 [ %v4_95, %dec_label_pc_83 ], [ %v4_958, %dec_label_pc_7f ]
  %v4_71 = fmul x86_fp80 %v4_959, %v4_959
  %v3_73 = fadd x86_fp80 %v4_71, %v4_71
  %v3_77 = fmul x86_fp80 %v3_73, %v3_73
  %v3_7b = fmul x86_fp80 %v3_77, %v3_77
  %v4_7d = fsub x86_fp80 %v3_7b, %v3_7b
  br label %dec_label_pc_7f

dec_label_pc_7f:                                  ; preds = %dec_label_pc_6f, %dec_label_pc_6a
  %v4_958 = phi x86_fp80 [ %v4_7d, %dec_label_pc_6f ], [ %st7.promoted, %dec_label_pc_6a ]
  %v2_7f4 = phi i32 [ %v2_7f, %dec_label_pc_6f ], [ %v3_6a, %dec_label_pc_6a ]
  %v2_7f = udiv i32 %v2_7f4, 2
  %v9_7f = urem i32 %v2_7f4, 2
  %v10_7f = icmp ne i32 %v9_7f, 0
  %v1_81 = icmp eq i1 %v10_7f, false
  br i1 %v1_81, label %dec_label_pc_6f, label %dec_label_pc_83

dec_label_pc_83:                                  ; preds = %dec_label_pc_7f
  %tmp262 = icmp ult i32 %v2_7f4, 2
  %v4_85 = fmul x86_fp80 %v4_958, %v4_958
  %v4_8b = fsub x86_fp80 %v4_85, %v4_85
  %v4_8f = fmul x86_fp80 %v4_8b, %v4_8b
  %v4_93 = fmul x86_fp80 %v4_8f, %v4_8f
  %v4_95 = fadd x86_fp80 %v4_93, %v4_93
  %v1_97 = icmp eq i1 %tmp262, false
  br i1 %v1_97, label %dec_label_pc_6f, label %dec_label_pc_99

dec_label_pc_99:                                  ; preds = %dec_label_pc_83
  store x86_fp80 %v4_95, x86_fp80* %st7.global-to-local, align 4
  %v7_99 = add i3 %v0_40, 1
  %v8_99 = add i3 %v0_40, 2
  %v2_9b = add i32 %v1_40, -20
  %v3_9b = inttoptr i32 %v2_9b to float*
  %v4_9b = load float, float* %v3_9b, align 4
  %v5_9b = fpext float %v4_9b to x86_fp80
  %v4_9e = fmul x86_fp80 %v5_9b, %v5_9b
  %v4_a0 = fmul x86_fp80 %v4_9e, %v4_9e
  store x86_fp80 %v4_a0, x86_fp80* %st7.global-to-local, align 4
  store i3 %v8_99, i3* %fpu_stat_TOP.global-to-local, align 1
  %v2_a2 = call x86_fp80 @llvm.fabs.f80(x86_fp80 %v4_a0)
  %v3_a2 = fcmp olt x86_fp80 %v2_a2, 0xK403E8000000000000000
  br i1 %v3_a2, label %bb, label %bb258

bb:                                               ; preds = %dec_label_pc_99
  %v7_a2 = call x86_fp80 @llvm.cos.f80(x86_fp80 %v4_a0)
  store i3 %v7_99, i3* %fpu_stat_TOP.global-to-local, align 1
  store x86_fp80 %v7_a2, x86_fp80* %st7.global-to-local, align 4
  %.pre = call x86_fp80 @llvm.fabs.f80(x86_fp80 %v7_a2)
  br label %bb258

bb258:                                            ; preds = %dec_label_pc_99, %bb
  %v2_a6.pre-phi = phi x86_fp80 [ %v2_a2, %dec_label_pc_99 ], [ %.pre, %bb ]
  %v0_a6 = phi i3 [ %v8_99, %dec_label_pc_99 ], [ %v7_99, %bb ]
  %v2_a4 = phi x86_fp80 [ %v4_a0, %dec_label_pc_99 ], [ %v7_a2, %bb ]
  %v3_a6 = fcmp olt x86_fp80 %v2_a6.pre-phi, 0xK403E8000000000000000
  br i1 %v3_a6, label %bb259, label %bb260

bb259:                                            ; preds = %bb258
  %v4_a6 = call x86_fp80 @llvm.sin.f80(x86_fp80 %v2_a4)
  store x86_fp80 %v4_a6, x86_fp80* %st7.global-to-local, align 4
  %v8_a6 = add i3 %v0_a6, -1
  store i3 %v8_a6, i3* %fpu_stat_TOP.global-to-local, align 1
  br label %bb260

bb260:                                            ; preds = %bb258, %bb259
  %v0_af = phi i3 [ %v0_a6, %bb258 ], [ %v8_a6, %bb259 ]
  %v3_a8 = phi x86_fp80 [ %v2_a4, %bb258 ], [ %v4_a6, %bb259 ]
  %v4_aa = fmul x86_fp80 %v3_a8, %v3_a8
  store x86_fp80 %v4_aa, x86_fp80* %st7.global-to-local, align 4
  %v2_ac = load i32, i32* %esi.global-to-local, align 4
  %v3_ac = add i32 %v2_ac, 24
  %v4_ac = inttoptr i32 %v3_ac to double*
  %v5_ac = load double, double* %v4_ac, align 4
  %v6_ac = fpext double %v5_ac to x86_fp80
  %v7_ac = fadd x86_fp80 %v4_aa, %v6_ac
  store x86_fp80 %v7_ac, x86_fp80* %st7.global-to-local, align 4
  %v2_af = load i32, i32* @edx, align 8
  %v3_af = add i32 %v2_af, -8
  %v4_af = fptrunc x86_fp80 %v7_ac to double
  %v5_af = inttoptr i32 %v3_af to double*
  store double %v4_af, double* %v5_af, align 4
  %v2_b2 = load x86_fp80, x86_fp80* %st7.global-to-local, align 4
  %v4_b2 = fmul x86_fp80 %v2_b2, %v2_b2
  %v4_b4 = fmul x86_fp80 %v4_b2, %v4_b2
  store x86_fp80 %v4_b4, x86_fp80* %st7.global-to-local, align 4
  %v3_b6 = add i32 %v1_40, -40
  %v4_b6 = inttoptr i32 %v3_b6 to float*
  %v5_b6 = load float, float* %v4_b6, align 4
  %v6_b6 = fpext float %v5_b6 to x86_fp80
  %v7_b6 = fmul x86_fp80 %v4_b4, %v6_b6
  store x86_fp80 %v7_b6, x86_fp80* %st7.global-to-local, align 4
  %v3_b9 = add i32 %v2_ac, 40
  %v4_b9 = inttoptr i32 %v3_b9 to double*
  %v5_b9 = load double, double* %v4_b9, align 4
  %v6_b9 = fpext double %v5_b9 to x86_fp80
  %v7_b9 = fadd x86_fp80 %v7_b6, %v6_b9
  store x86_fp80 %v7_b9, x86_fp80* %st7.global-to-local, align 4
  %v2_bc = load i32, i32* @ecx, align 8
  %v3_bc = fptrunc x86_fp80 %v7_b9 to double
  %v4_bc = inttoptr i32 %v2_bc to double*
  store double %v3_bc, double* %v4_bc, align 4
  %v2_be = load x86_fp80, x86_fp80* %st7.global-to-local, align 4
  %v4_be = fmul x86_fp80 %v2_be, %v2_be
  store x86_fp80 %v4_be, x86_fp80* %st7.global-to-local, align 4
  %v3_c0 = add i32 %v2_ac, 32
  %v4_c0 = inttoptr i32 %v3_c0 to double*
  %v5_c0 = load double, double* %v4_c0, align 4
  %v6_c0 = fpext double %v5_c0 to x86_fp80
  %v7_c0 = fadd x86_fp80 %v4_be, %v6_c0
  store x86_fp80 %v7_c0, x86_fp80* %st7.global-to-local, align 4
  %v2_c3 = load i32, i32* @edx, align 8
  %v3_c3 = fptrunc x86_fp80 %v7_c0 to double
  %v4_c3 = inttoptr i32 %v2_c3 to double*
  store double %v3_c3, double* %v4_c3, align 4
  %v5_c3 = add i3 %v0_af, -3
  store i3 %v5_c3, i3* %fpu_stat_TOP.global-to-local, align 1
  store i32 %v0_4, i32* %edi.global-to-local, align 4
  store i32 %v0_3, i32* %esi.global-to-local, align 4
  ret i32 %v2_7f
}

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

declare i32 @__asm_fpatan() 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

attributes #0 = { nounwind readnone speculatable }
