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

define i32 @function_0() local_unnamed_addr {
dec_label_pc_0:
  %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
  %st7.global-to-local = alloca x86_fp80, align 4
  %tmp258 = call double @__decompiler_undefined_function_1()
  %stack_var_-70 = alloca double, align 8
  %v0_3 = load i32, i32* %esi.global-to-local, align 4
  %v1_3 = add i32 %v0_3, -120
  %v2_3 = inttoptr i32 %v1_3 to i128*
  %v3_3 = load i128, i128* %v2_3, align 4
  %v4_3 = call i128 @__asm_movupd(i128 %v3_3)
  %v1_8 = add i32 %v0_3, -104
  %v2_8 = inttoptr i32 %v1_8 to i64*
  %v3_8 = load i64, i64* %v2_8, align 4
  %v4_8 = call i128 @__asm_movsd(i64 %v3_8)
  %v1_d = load i32, i32* %edi.global-to-local, align 4
  %v2_d = add i32 %v1_d, -32
  %v3_d = inttoptr i32 %v2_d to i128*
  %v4_d = load i128, i128* %v3_d, align 4
  %v5_d = call i128 @__asm_mulpd(i128 %v4_3, i128 %v4_d)
  %v2_12 = add i32 %v1_d, -32
  %v3_12 = inttoptr i32 %v2_12 to i64*
  %v4_12 = load i64, i64* %v3_12, align 4
  %v5_12 = call i128 @__asm_mulsd(i128 %v4_8, i64 %v4_12)
  %v1_17 = load i32, i32* %edi.global-to-local, align 4
  %v2_17 = add i32 %v1_17, -64
  %v3_17 = inttoptr i32 %v2_17 to i128*
  %v4_17 = load i128, i128* %v3_17, align 4
  %v5_17 = call i128 @__asm_addpd(i128 %v5_d, i128 %v4_17)
  %v2_1c = add i32 %v1_17, -48
  %v3_1c = inttoptr i32 %v2_1c to i64*
  %v4_1c = load i64, i64* %v3_1c, align 4
  %v5_1c = call i128 @__asm_addsd(i128 %v5_12, i64 %v4_1c)
  %v0_21 = load i32, i32* %edi.global-to-local, align 4
  %v1_21 = add i32 %v0_21, -76
  %v2_21 = inttoptr i32 %v1_21 to i32*
  %v3_21 = load i32, i32* %v2_21, align 4
  %v10_21 = icmp eq i32 %v3_21, 0
  br i1 %v10_21, label %dec_label_pc_40, label %dec_label_pc_27

dec_label_pc_27:                                  ; preds = %dec_label_pc_0
  %v0_27 = load i32, i32* %esi.global-to-local, align 4
  %v1_27 = add i32 %v0_27, 112
  %v2_27 = inttoptr i32 %v1_27 to i64*
  %v3_27 = load i64, i64* %v2_27, align 4
  %v4_27 = call i128 @__asm_movsd(i64 %v3_27)
  %v1_2c = load i32, i32* %edi.global-to-local, align 4
  %v2_2c = add i32 %v1_2c, -32
  %v3_2c = inttoptr i32 %v2_2c to i64*
  %v4_2c = load i64, i64* %v3_2c, align 4
  %v5_2c = call i128 @__asm_mulsd(i128 %v4_27, i64 %v4_2c)
  %v0_31 = load i32, i32* %esi.global-to-local, align 4
  %v1_31 = add i32 %v0_31, -120
  %v2_31 = inttoptr i32 %v1_31 to i128*
  %v3_31 = load i128, i128* %v2_31, align 4
  call void @__asm_movupd.1(i128 %v3_31, i128 %v5_17)
  %v1_36 = call i32 @__asm_movsd.2(i128 %v5_1c)
  %v3_36 = add i32 %v0_31, -104
  %v4_36 = sext i32 %v1_36 to i64
  %v5_36 = inttoptr i32 %v3_36 to i64*
  store i64 %v4_36, i64* %v5_36, align 4
  %v1_3b = call i32 @__asm_movsd.2(i128 %v5_2c)
  %v2_3b = load i32, i32* %esi.global-to-local, align 4
  %v3_3b = add i32 %v2_3b, 112
  %v4_3b = sext i32 %v1_3b to i64
  %v5_3b = inttoptr i32 %v3_3b to i64*
  store i64 %v4_3b, i64* %v5_3b, align 4
  br label %dec_label_pc_40

dec_label_pc_40:                                  ; preds = %dec_label_pc_27, %dec_label_pc_0
  %v2_40 = load double, double* %stack_var_-70, align 8
  %v3_40 = fptrunc double %v2_40 to float
  %v4_40 = bitcast float %v3_40 to i32
  %v5_40 = sext i32 %v4_40 to i128
  call void @__asm_movupd.1(i128 %v5_40, i128 %v5_17)
  %v1_45 = call i32 @__asm_movsd.2(i128 %v5_1c)
  %v4_45 = sext i32 %v1_45 to i64
  %v6_45 = bitcast i64 %v4_45 to double
  %v0_4b = load i3, i3* %fpu_stat_TOP.global-to-local, align 1
  %v0_55 = load i32, i32* %edi.global-to-local, align 4
  %v1_55 = add i32 %v0_55, -44
  store i32 %v1_55, i32* %edi.global-to-local, align 4
  %v7_58 = fpext double %v6_45 to x86_fp80
  store x86_fp80 %v7_58, x86_fp80* %st7.global-to-local, align 4
  %v5_5c = fpext double %tmp258 to x86_fp80
  %v3_60 = load double, double* %stack_var_-70, align 8
  %v8_60 = fpext double %v3_60 to x86_fp80
  %v3_65 = add i32 %v0_55, -104
  %v4_65 = inttoptr i32 %v3_65 to float*
  %v5_65 = load float, float* %v4_65, align 4
  %v6_65 = fpext float %v5_65 to x86_fp80
  %v7_65 = fmul x86_fp80 %v8_60, %v6_65
  %v3_6a = add i32 %v0_55, -108
  %v4_6a = inttoptr i32 %v3_6a to float*
  %v5_6a = load float, float* %v4_6a, align 4
  %v6_6a = fpext float %v5_6a to x86_fp80
  %v7_6a = fmul x86_fp80 %v5_5c, %v6_6a
  %v4_6d = fadd x86_fp80 %v7_65, %v7_6a
  %v3_71 = add i32 %v0_55, -112
  %v4_71 = inttoptr i32 %v3_71 to float*
  %v5_71 = load float, float* %v4_71, align 4
  %v6_71 = fpext float %v5_71 to x86_fp80
  %v7_71 = fmul x86_fp80 %v7_58, %v6_71
  %v4_74 = fadd x86_fp80 %v7_71, %v4_6d
  %v3_78 = add i32 %v0_55, -80
  %v4_78 = inttoptr i32 %v3_78 to float*
  %v5_78 = load float, float* %v4_78, align 4
  %v6_78 = fpext float %v5_78 to x86_fp80
  %v7_78 = fmul x86_fp80 %v8_60, %v6_78
  %v3_7d = add i32 %v0_55, -84
  %v4_7d = inttoptr i32 %v3_7d to float*
  %v5_7d = load float, float* %v4_7d, align 4
  %v6_7d = fpext float %v5_7d to x86_fp80
  %v7_7d = fmul x86_fp80 %v5_5c, %v6_7d
  %v4_80 = fadd x86_fp80 %v7_78, %v7_7d
  %v3_84 = add i32 %v0_55, -88
  %v4_84 = inttoptr i32 %v3_84 to float*
  %v5_84 = load float, float* %v4_84, align 4
  %v6_84 = fpext float %v5_84 to x86_fp80
  %v7_84 = fmul x86_fp80 %v7_58, %v6_84
  %v4_87 = fadd x86_fp80 %v4_80, %v7_84
  %v3_8b = add i32 %v0_55, -92
  %v4_8b = inttoptr i32 %v3_8b to float*
  %v5_8b = load float, float* %v4_8b, align 4
  %v6_8b = fpext float %v5_8b to x86_fp80
  %v7_8b = fmul x86_fp80 %v8_60, %v6_8b
  %v3_90 = add i32 %v0_55, -96
  %v4_90 = inttoptr i32 %v3_90 to float*
  %v5_90 = load float, float* %v4_90, align 4
  %v6_90 = fpext float %v5_90 to x86_fp80
  %v7_90 = fmul x86_fp80 %v5_5c, %v6_90
  %v4_93 = fadd x86_fp80 %v7_8b, %v7_90
  store x86_fp80 %v4_74, x86_fp80* %st7.global-to-local, align 4
  %v3_97 = add i32 %v0_55, -100
  %v4_97 = inttoptr i32 %v3_97 to float*
  %v5_97 = load float, float* %v4_97, align 4
  %v6_97 = fpext float %v5_97 to x86_fp80
  %v7_97 = fmul x86_fp80 %v7_58, %v6_97
  %v4_9a = fadd x86_fp80 %v4_93, %v7_97
  %tmp265 = fptrunc x86_fp80 %v4_87 to double
  store double %tmp265, double* %stack_var_-70, align 8
  %v6_9f = add i3 %v0_4b, -1
  store i32 %v0_55, i32* %edi.global-to-local, align 4
  %v3_ad = fmul x86_fp80 %v4_87, %v4_87
  %v3_b3 = fmul x86_fp80 %v4_9a, %v4_9a
  %v3_b9 = fmul x86_fp80 %v4_74, %v4_74
  %v4_bb = fadd x86_fp80 %v3_b9, %v3_b3
  %v4_bd = fadd x86_fp80 %v3_ad, %v4_bb
  store x86_fp80 %v4_bd, x86_fp80* %st7.global-to-local, align 4
  %v3_c4 = add i32 %v0_55, -72
  %v4_c4 = inttoptr i32 %v3_c4 to double*
  %v5_c4 = load double, double* %v4_c4, align 4
  %v6_c4 = fpext double %v5_c4 to x86_fp80
  %v7_c4 = fmul x86_fp80 %v4_bd, %v6_c4
  %v10_c7 = fmul x86_fp80 %v4_87, %v7_c4
  %v10_ca = fmul x86_fp80 %v4_87, %v10_c7
  store x86_fp80 %v10_ca, x86_fp80* %st7.global-to-local, align 4
  %v2_d1 = add i32 %v0_55, -16
  %v3_d1 = inttoptr i32 %v2_d1 to double*
  %v4_d1 = load double, double* %v3_d1, align 4
  %v5_d1 = fpext double %v4_d1 to x86_fp80
  %v2_db = fsub x86_fp80 0xK80000000000000000000, %v3_b3
  %v4_e5 = fsub x86_fp80 %v2_db, %v3_b9
  %v4_e7 = fadd x86_fp80 %v4_e5, %v5_d1
  store i3 %v6_9f, i3* %fpu_stat_TOP.global-to-local, align 1
  %v7_e9 = fmul x86_fp80 %v4_e7, %v4_9a
  %v7_ed = fmul x86_fp80 %v7_e9, %v4_9a
  store x86_fp80 %v7_ed, x86_fp80* %st7.global-to-local, align 4
  %v18_f3 = call i32 @__asm_wait(x86_fp80 %v4_87, x86_fp80 %v4_9a, x86_fp80 %v4_74, x86_fp80 %v10_ca, x86_fp80 0xK00000000000000000000, x86_fp80 %v4_bd)
  %v0_f4 = load i32, i32* %fpsw.global-to-local, align 4
  %v1_f4 = call i16 @__asm_fnstsw(i32 %v0_f4)
  %v2_f4 = sext i16 %v1_f4 to i32
  %v4_f4 = and i32 %v18_f3, -65536
  %tmp267 = udiv i32 %v2_f4, 2
  %v12_f6 = and i32 %tmp267, 32512
  %v2_f4.masked = and i32 %v2_f4, -65281
  %v13_f6 = or i32 %v4_f4, %v2_f4.masked
  %v14_f6 = or i32 %v13_f6, %v12_f6
  %v15_f67 = and i32 %v2_f4, 256
  %v16_f6 = icmp ne i32 %v15_f67, 0
  %v1_f8 = icmp eq i1 %v16_f6, false
  %v1_104 = load x86_fp80, x86_fp80* %st7.global-to-local, align 4
  br i1 %v1_f8, label %dec_label_pc_104, label %dec_label_pc_fa

dec_label_pc_fa:                                  ; preds = %dec_label_pc_40
  %v7_fa = fsub x86_fp80 %v10_ca, %v1_104
  br label %dec_label_pc_10c

dec_label_pc_104:                                 ; preds = %dec_label_pc_40
  %v7_104 = fadd x86_fp80 %v1_104, 0xK00000000000000000000
  br label %dec_label_pc_10c

dec_label_pc_10c:                                 ; preds = %dec_label_pc_104, %dec_label_pc_fa
  %storemerge = phi x86_fp80 [ %v7_fa, %dec_label_pc_fa ], [ %v7_104, %dec_label_pc_104 ]
  %v5_10c.pre-phi = phi x86_fp80 [ %v7_fa, %dec_label_pc_fa ], [ %v10_ca, %dec_label_pc_104 ]
  %stack_var_-38.0 = phi x86_fp80 [ 0xK00000000000000000000, %dec_label_pc_fa ], [ %v7_104, %dec_label_pc_104 ]
  store x86_fp80 %storemerge, x86_fp80* %st7.global-to-local, align 4
  %v2_110 = call x86_fp80 @llvm.sqrt.f80(x86_fp80 %v5_10c.pre-phi)
  %v2_112 = call x86_fp80 @llvm.sqrt.f80(x86_fp80 %v2_110)
  %v0_114 = load i3, i3* %fpu_stat_TOP.global-to-local, align 1
  %v2_118 = call x86_fp80 @llvm.sqrt.f80(x86_fp80 %stack_var_-38.0)
  %v2_11a = call x86_fp80 @llvm.sqrt.f80(x86_fp80 %v2_118)
  %v4_11e = fsub x86_fp80 %v2_112, %v2_11a
  store x86_fp80 %v4_11e, x86_fp80* %st7.global-to-local, align 4
  %v2_124 = call x86_fp80 @llvm.sqrt.f80(x86_fp80 %v4_bd)
  %v2_126 = load i32, i32* %edi.global-to-local, align 4
  %v3_126 = add i32 %v2_126, -16
  %v4_126 = inttoptr i32 %v3_126 to double*
  %v5_126 = load double, double* %v4_126, align 4
  %v6_126 = fpext double %v5_126 to x86_fp80
  %v7_126 = fsub x86_fp80 %v2_124, %v6_126
  %v2_12b = call x86_fp80 @llvm.fabs.f80(x86_fp80 %v7_126)
  %v4_12d = fadd x86_fp80 %v7_126, %v2_12b
  %v3_12f = fadd x86_fp80 %v4_12d, %v4_12d
  %v3_131 = fadd x86_fp80 %v3_12f, %v3_12f
  %v4_133 = fadd x86_fp80 %v4_11e, %v3_131
  store x86_fp80 %v4_133, x86_fp80* %st7.global-to-local, align 4
  %v3_135 = inttoptr i32 %v2_126 to double*
  %v4_135 = load double, double* %v3_135, align 4
  %v5_135 = fpext double %v4_135 to x86_fp80
  %v6_135 = fmul x86_fp80 %v4_133, %v5_135
  store x86_fp80 %v6_135, x86_fp80* %st7.global-to-local, align 4
  %v1_137 = add i32 %v2_126, -76
  %v2_137 = inttoptr i32 %v1_137 to i32*
  %v3_137 = load i32, i32* %v2_137, align 4
  %v10_137 = icmp eq i32 %v3_137, 0
  %v1_13b = icmp eq i1 %v10_137, false
  br i1 %v1_13b, label %dec_label_pc_140, label %dec_label_pc_13d

dec_label_pc_13d:                                 ; preds = %dec_label_pc_10c
  %v3_13d = add i32 %v2_126, -32
  %v4_13d = inttoptr i32 %v3_13d to double*
  %v5_13d = load double, double* %v4_13d, align 4
  %v6_13d = fpext double %v5_13d to x86_fp80
  %v7_13d = fdiv x86_fp80 %v6_135, %v6_13d
  store x86_fp80 %v7_13d, x86_fp80* %st7.global-to-local, align 4
  br label %dec_label_pc_140

dec_label_pc_140:                                 ; preds = %dec_label_pc_13d, %dec_label_pc_10c
  %v1_140 = phi x86_fp80 [ %v7_13d, %dec_label_pc_13d ], [ %v6_135, %dec_label_pc_10c ]
  %v2_140 = load i32, i32* %esi.global-to-local, align 4
  %v3_140 = add i32 %v2_140, -32
  %v4_140 = fptrunc x86_fp80 %v1_140 to double
  %v5_140 = inttoptr i32 %v3_140 to double*
  store double %v4_140, double* %v5_140, align 4
  %v6_140 = add i3 %v0_114, 1
  store i3 %v6_140, i3* %fpu_stat_TOP.global-to-local, align 1
  ret i32 %v14_f6
}

declare i128 @__asm_movupd(i128) local_unnamed_addr

declare i128 @__asm_movsd(i64) local_unnamed_addr

declare i128 @__asm_mulpd(i128, i128) local_unnamed_addr

declare i128 @__asm_mulsd(i128, i64) local_unnamed_addr

declare i128 @__asm_addpd(i128, i128) local_unnamed_addr

declare i128 @__asm_addsd(i128, i64) local_unnamed_addr

declare void @__asm_movupd.1(i128, i128) local_unnamed_addr

declare i32 @__asm_movsd.2(i128) local_unnamed_addr

declare i32 @__asm_wait(x86_fp80, x86_fp80, x86_fp80, x86_fp80, x86_fp80, x86_fp80) local_unnamed_addr

declare i16 @__asm_fnstsw(i32) local_unnamed_addr

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

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

declare double @__decompiler_undefined_function_1() local_unnamed_addr

attributes #0 = { nounwind readnone speculatable }
