#define NULL ((void *)0)
typedef unsigned long size_t; // Customize by platform.
typedef long intptr_t;
typedef unsigned long uintptr_t;
typedef long scalar_t__; // Either arithmetic or pointer type.
/* By default, we understand bool (as a convenience). */
typedef int bool;
#define false 0
#define true 1

/* Forward declarations */

/* Type definitions */

/* Variables and functions */
float cos(float);
int /*<<< orphan*/ exit(int /*<<< orphan*/);
int /*<<< orphan*/ printf(char *, ...);
int /*<<< orphan*/ scanf(char *, float *, float *);
float sin(float);
int main(void) {
  float x0 = 0, x1 = 0, x2 = 0, y0 = 0, y1 = 0, y2 = 0;
  int iter = 0;
  printf("Solution for Equation using bisection method x*sin(x)+cos(x)\n ");
  do {
    printf("Enter Range :");
    scanf("%f %f", &x0, &x1);
    y0 = (x0 * sin(x0) + cos(x0)), y1 = (x1 * sin(x1) + cos(x1));
    if (y0 == 0) {
      printf("The solution is %f", x0);
      exit(0);
    } else if (y1 == 0) {
      printf("The solution is %f", x1);
      exit(0);
    }
  } while ((y0 * y1) > 0);
  printf("Iteration  \tx0  \t x1  \t Mid  \t   f(x0) \t f(x1) \t  f(Mid)");
  do {
    x2 = (x0 + x1) / 2.0;
    y2 = (x2 * sin(x2) + cos(x2));
    printf("\n%d\t  %f   %f  %f  %f  %f   %f\n", (++iter), x0, x1, x2, y0, y1,
           y2);
    if (y0 * y2 > 0) {
      x0 = x2;
    } else {
      x1 = x2;
    }
    y0 = (x0 * sin(x0) + cos(x0)), y1 = (x1 * sin(x1) + cos(x1));
  } while (x1 - x0 >= 0.000001 || x1 - x0 <= -0.000001);
  x2 = (x1 + x0) / 2.0;
  printf("\nThe solution is %f\n ", x2);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x50,%rsp
movl   $0x0,-0x4(%rbp)
xorps  %xmm0,%xmm0
movss  %xmm0,-0x8(%rbp)
xorps  %xmm0,%xmm0
movss  %xmm0,-0xc(%rbp)
xorps  %xmm0,%xmm0
movss  %xmm0,-0x10(%rbp)
xorps  %xmm0,%xmm0
movss  %xmm0,-0x14(%rbp)
xorps  %xmm0,%xmm0
movss  %xmm0,-0x18(%rbp)
xorps  %xmm0,%xmm0
movss  %xmm0,-0x1c(%rbp)
movl   $0x0,-0x20(%rbp)
lea    0xe7b(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xeac(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xeac(%rip),%rdi
lea    -0x8(%rbp),%rsi
lea    -0xc(%rbp),%rdx
call   1050 <scanf@plt>
movss  -0x8(%rbp),%xmm0
movss  %xmm0,-0x2c(%rbp)
movss  -0x8(%rbp),%xmm0
call   1040 <sin@plt>
movss  %xmm0,-0x30(%rbp)
movss  -0x8(%rbp),%xmm0
call   1060 <cos@plt>
movss  -0x30(%rbp),%xmm2
movaps %xmm0,%xmm1
movss  -0x2c(%rbp),%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x14(%rbp)
movss  -0xc(%rbp),%xmm0
movss  %xmm0,-0x24(%rbp)
movss  -0xc(%rbp),%xmm0
call   1040 <sin@plt>
movss  %xmm0,-0x28(%rbp)
movss  -0xc(%rbp),%xmm0
call   1060 <cos@plt>
movss  -0x28(%rbp),%xmm2
movaps %xmm0,%xmm1
movss  -0x24(%rbp),%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x18(%rbp)
movss  -0x14(%rbp),%xmm0
xorps  %xmm1,%xmm1
ucomiss %xmm1,%xmm0
jne    1275 <main+0x125>
jp     1275 <main+0x125>
movss  -0x8(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
lea    0xe04(%rip),%rdi
mov    $0x1,%al
call   1030 <printf@plt>
xor    %edi,%edi
call   1070 <exit@plt>
movss  -0x18(%rbp),%xmm0
xorps  %xmm1,%xmm1
ucomiss %xmm1,%xmm0
jne    12aa <main+0x15a>
jp     12aa <main+0x15a>
movss  -0xc(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
lea    0xdcf(%rip),%rdi
mov    $0x1,%al
call   1030 <printf@plt>
xor    %edi,%edi
call   1070 <exit@plt>
jmp    12af <main+0x15f>
jmp    12b4 <main+0x164>
movss  -0x14(%rbp),%xmm0
mulss  -0x18(%rbp),%xmm0
xorps  %xmm1,%xmm1
ucomiss %xmm1,%xmm0
ja     11a4 <main+0x54>
lea    0xdad(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movss  -0x8(%rbp),%xmm0
addss  -0xc(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
movsd  0xd12(%rip),%xmm1
divsd  %xmm1,%xmm0
cvtsd2ss %xmm0,%xmm0
movss  %xmm0,-0x10(%rbp)
movss  -0x10(%rbp),%xmm0
movss  %xmm0,-0x34(%rbp)
movss  -0x10(%rbp),%xmm0
call   1040 <sin@plt>
movss  %xmm0,-0x38(%rbp)
movss  -0x10(%rbp),%xmm0
call   1060 <cos@plt>
movss  -0x38(%rbp),%xmm2
movaps %xmm0,%xmm1
movss  -0x34(%rbp),%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x1c(%rbp)
mov    -0x20(%rbp),%esi
add    $0x1,%esi
mov    %esi,-0x20(%rbp)
movss  -0x8(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
movss  -0xc(%rbp),%xmm1
cvtss2sd %xmm1,%xmm1
movss  -0x10(%rbp),%xmm2
cvtss2sd %xmm2,%xmm2
movss  -0x14(%rbp),%xmm3
cvtss2sd %xmm3,%xmm3
movss  -0x18(%rbp),%xmm4
cvtss2sd %xmm4,%xmm4
movss  -0x1c(%rbp),%xmm5
cvtss2sd %xmm5,%xmm5
lea    0xd39(%rip),%rdi
mov    $0x6,%al
call   1030 <printf@plt>
movss  -0x14(%rbp),%xmm0
mulss  -0x1c(%rbp),%xmm0
xorps  %xmm1,%xmm1
ucomiss %xmm1,%xmm0
jbe    13aa <main+0x25a>
movss  -0x10(%rbp),%xmm0
movss  %xmm0,-0x8(%rbp)
jmp    13b4 <main+0x264>
movss  -0x10(%rbp),%xmm0
movss  %xmm0,-0xc(%rbp)
movss  -0x8(%rbp),%xmm0
movss  %xmm0,-0x44(%rbp)
movss  -0x8(%rbp),%xmm0
call   1040 <sin@plt>
movss  %xmm0,-0x48(%rbp)
movss  -0x8(%rbp),%xmm0
call   1060 <cos@plt>
movss  -0x48(%rbp),%xmm2
movaps %xmm0,%xmm1
movss  -0x44(%rbp),%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x14(%rbp)
movss  -0xc(%rbp),%xmm0
movss  %xmm0,-0x3c(%rbp)
movss  -0xc(%rbp),%xmm0
call   1040 <sin@plt>
movss  %xmm0,-0x40(%rbp)
movss  -0xc(%rbp),%xmm0
call   1060 <cos@plt>
movss  -0x40(%rbp),%xmm2
movaps %xmm0,%xmm1
movss  -0x3c(%rbp),%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x18(%rbp)
movss  -0xc(%rbp),%xmm0
subss  -0x8(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
mov    $0x1,%al
movsd  0xbc2(%rip),%xmm1
ucomisd %xmm1,%xmm0
mov    %al,-0x49(%rbp)
jae    1473 <main+0x323>
movss  -0xc(%rbp),%xmm0
subss  -0x8(%rbp),%xmm0
cvtss2sd %xmm0,%xmm1
movsd  0xba7(%rip),%xmm0
ucomisd %xmm1,%xmm0
setae  %al
mov    %al,-0x49(%rbp)
mov    -0x49(%rbp),%al
test   $0x1,%al
jne    12d8 <main+0x188>
movss  -0xc(%rbp),%xmm0
addss  -0x8(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
movsd  0xb6c(%rip),%xmm1
divsd  %xmm1,%xmm0
cvtsd2ss %xmm0,%xmm0
movss  %xmm0,-0x10(%rbp)
movss  -0x10(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
lea    0xc26(%rip),%rdi
mov    $0x1,%al
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x50,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %r15
push   %r14
push   %r12
push   %rbx
sub    $0x18,%rsp
movl   $0x0,0x8(%rsp)
movl   $0x0,0x4(%rsp)
lea    0xea6(%rip),%rdi
xor    %eax,%eax
call   1030 <printf@plt>
lea    0xed7(%rip),%r14
lea    0xede(%rip),%r15
lea    0x8(%rsp),%r12
lea    0x4(%rsp),%rbx
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax,%rax,1)
mov    %r14,%rdi
xor    %eax,%eax
call   1030 <printf@plt>
mov    %r15,%rdi
mov    %r12,%rsi
mov    %rbx,%rdx
call   1050 <scanf@plt>
movss  0x8(%rsp),%xmm0
movss  %xmm0,0xc(%rsp)
call   1040 <sin@plt>
movss  %xmm0,0x10(%rsp)
movss  0x8(%rsp),%xmm0
call   1060 <cos@plt>
movss  0x10(%rsp),%xmm1
mulss  0xc(%rsp),%xmm1
addss  %xmm0,%xmm1
movss  %xmm1,0x10(%rsp)
movss  0x4(%rsp),%xmm0
movss  %xmm0,0xc(%rsp)
call   1040 <sin@plt>
movss  %xmm0,(%rsp)
movss  0x4(%rsp),%xmm0
call   1060 <cos@plt>
xorps  %xmm3,%xmm3
movss  0x10(%rsp),%xmm1
ucomiss %xmm3,%xmm1
jne    1225 <main+0xd5>
jnp    13fd <main+0x2ad>
movss  0xc(%rsp),%xmm2
mulss  (%rsp),%xmm2
addss  %xmm0,%xmm2
ucomiss %xmm3,%xmm2
jne    123f <main+0xef>
jnp    1405 <main+0x2b5>
movaps %xmm1,%xmm0
mulss  %xmm2,%xmm0
ucomiss %xmm3,%xmm0
ja     11a0 <main+0x50>
movss  %xmm2,0xc(%rsp)
lea    0xe22(%rip),%rdi
xor    %eax,%eax
call   1030 <printf@plt>
movss  0x8(%rsp),%xmm3
mov    $0x1,%ebx
movss  0x4(%rsp),%xmm0
lea    0xe3c(%rip),%r14
nopl   0x0(%rax,%rax,1)
addss  %xmm3,%xmm0
mulss  0xd74(%rip),%xmm0
movss  %xmm0,(%rsp)
call   1040 <sin@plt>
movss  %xmm0,0x14(%rsp)
movss  (%rsp),%xmm0
call   1060 <cos@plt>
movss  0x14(%rsp),%xmm1
movss  (%rsp),%xmm2
mulss  %xmm2,%xmm1
addss  %xmm0,%xmm1
movaps %xmm1,%xmm5
movss  %xmm1,0x14(%rsp)
movss  0x8(%rsp),%xmm0
cvtss2sd %xmm0,%xmm0
movss  0x4(%rsp),%xmm1
cvtss2sd %xmm1,%xmm1
cvtss2sd %xmm2,%xmm2
movss  0x10(%rsp),%xmm3
cvtss2sd %xmm3,%xmm3
movss  0xc(%rsp),%xmm4
cvtss2sd %xmm4,%xmm4
cvtss2sd %xmm5,%xmm5
mov    %r14,%rdi
mov    %ebx,%esi
mov    $0x6,%al
call   1030 <printf@plt>
movss  0x14(%rsp),%xmm0
mulss  0x10(%rsp),%xmm0
ucomiss 0xcf3(%rip),%xmm0
jbe    1320 <main+0x1d0>
movss  (%rsp),%xmm0
movss  %xmm0,0x8(%rsp)
jmp    1331 <main+0x1e1>
movss  (%rsp),%xmm0
movss  %xmm0,0x4(%rsp)
movss  0x8(%rsp),%xmm0
movss  %xmm0,(%rsp)
call   1040 <sin@plt>
movss  %xmm0,0x10(%rsp)
movss  0x8(%rsp),%xmm0
call   1060 <cos@plt>
movss  0x10(%rsp),%xmm1
mulss  (%rsp),%xmm1
addss  %xmm0,%xmm1
movss  %xmm1,0x10(%rsp)
movss  0x4(%rsp),%xmm0
movss  %xmm0,(%rsp)
call   1040 <sin@plt>
movss  %xmm0,0xc(%rsp)
movss  0x4(%rsp),%xmm0
call   1060 <cos@plt>
movss  0xc(%rsp),%xmm1
mulss  (%rsp),%xmm1
addss  %xmm0,%xmm1
movss  %xmm1,0xc(%rsp)
movss  0x4(%rsp),%xmm0
movss  0x8(%rsp),%xmm3
movaps %xmm0,%xmm1
subss  %xmm3,%xmm1
cvtss2sd %xmm1,%xmm1
add    $0x1,%ebx
ucomisd 0xc4f(%rip),%xmm1
jae    1280 <main+0x130>
movsd  0xc49(%rip),%xmm2
ucomisd %xmm1,%xmm2
jae    1280 <main+0x130>
addss  %xmm3,%xmm0
mulss  0xc23(%rip),%xmm0
cvtss2sd %xmm0,%xmm0
lea    0xcef(%rip),%rdi
mov    $0x1,%al
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x18,%rsp
pop    %rbx
pop    %r12
pop    %r14
pop    %r15
ret
movss  0x8(%rsp),%xmm0
jmp    140b <main+0x2bb>
movss  0x4(%rsp),%xmm0
cvtss2sd %xmm0,%xmm0
lea    0xc55(%rip),%rdi
mov    $0x1,%al
call   1030 <printf@plt>
xor    %edi,%edi
call   1070 <exit@plt>

LLVM IR (-O0):
@.str = [63 x i8] c"Solution for Equation using bisection method x*sin(x)+cos(x)\0A \00"
@.str.1 = [14 x i8] c"Enter Range :\00"
@.str.2 = [6 x i8] c"%f %f\00"
@.str.3 = [19 x i8] c"The solution is %f\00"
@.str.4 = [57 x i8] c"Iteration \09x0 \09 x1 \09 Mid \09 f(x0) \09 f(x1) \09 f(Mid)\00"
@.str.5 = [32 x i8] c"\0A%d\09 %f %f %f %f %f %f\0A\00"
@.str.6 = [22 x i8] c"\0AThe solution is %f\0A \00"
define i32 @main() {
%1 = alloca i32
%2 = alloca float
%3 = alloca float
%4 = alloca float
%5 = alloca float
%6 = alloca float
%7 = alloca float
%8 = alloca i32
store i32 0, i32* %1
store float 0.000000e+00, float* %2
store float 0.000000e+00, float* %3
store float 0.000000e+00, float* %4
store float 0.000000e+00, float* %5
store float 0.000000e+00, float* %6
store float 0.000000e+00, float* %7
store i32 0, i32* %8
%9 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([63 x i8], [63 x i8]* @.str, i64 0, i64 0))
br label %10
10: ; preds = %42, %0
%11 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str.1, i64 0, i64 0))
%12 = call i32 @scanf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.2, i64 0, i64 0), float* %2, float* %3)
%13 = load float, float* %2
%14 = load float, float* %2
%15 = call float @sin(float %14)
%16 = load float, float* %2
%17 = call float @cos(float %16)
%18 = call float @llvm.fmuladd.f32(float %13, float %15, float %17)
store float %18, float* %5
%19 = load float, float* %3
%20 = load float, float* %3
%21 = call float @sin(float %20)
%22 = load float, float* %3
%23 = call float @cos(float %22)
%24 = call float @llvm.fmuladd.f32(float %19, float %21, float %23)
store float %24, float* %6
%25 = load float, float* %5
%26 = fcmp oeq float %25, 0.000000e+00
br i1 %26, label %27, label %32
27: ; preds = %10
%28 = load float, float* %2
%29 = fpext float %28 to double
%30 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str.3, i64 0, i64 0), double %29)
%31 = call i32 @exit(i32 0)
unreachable
32: ; preds = %10
%33 = load float, float* %6
%34 = fcmp oeq float %33, 0.000000e+00
br i1 %34, label %35, label %40
35: ; preds = %32
%36 = load float, float* %3
%37 = fpext float %36 to double
%38 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str.3, i64 0, i64 0), double %37)
%39 = call i32 @exit(i32 0)
unreachable
40: ; preds = %32
br label %41
41: ; preds = %40
br label %42
42: ; preds = %41
%43 = load float, float* %5
%44 = load float, float* %6
%45 = fmul float %43, %44
%46 = fcmp ogt float %45, 0.000000e+00
br i1 %46, label %10, label %47
47: ; preds = %42
%48 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([57 x i8], [57 x i8]* @.str.4, i64 0, i64 0))
br label %49
49: ; preds = %110, %47
%50 = load float, float* %2
%51 = load float, float* %3
%52 = fadd float %50, %51
%53 = fpext float %52 to double
%54 = fdiv double %53, 2.000000e+00
%55 = fptrunc double %54 to float
store float %55, float* %4
%56 = load float, float* %4
%57 = load float, float* %4
%58 = call float @sin(float %57)
%59 = load float, float* %4
%60 = call float @cos(float %59)
%61 = call float @llvm.fmuladd.f32(float %56, float %58, float %60)
store float %61, float* %7
%62 = load i32, i32* %8
%63 = add nsw i32 %62, 1
store i32 %63, i32* %8
%64 = load float, float* %2
%65 = fpext float %64 to double
%66 = load float, float* %3
%67 = fpext float %66 to double
%68 = load float, float* %4
%69 = fpext float %68 to double
%70 = load float, float* %5
%71 = fpext float %70 to double
%72 = load float, float* %6
%73 = fpext float %72 to double
%74 = load float, float* %7
%75 = fpext float %74 to double
%76 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([32 x i8], [32 x i8]* @.str.5, i64 0, i64 0), i32 %63, double %65, double %67, double %69, double %71, double %73, double %75)
%77 = load float, float* %5
%78 = load float, float* %7
%79 = fmul float %77, %78
%80 = fcmp ogt float %79, 0.000000e+00
br i1 %80, label %81, label %83
81: ; preds = %49
%82 = load float, float* %4
store float %82, float* %2
br label %85
83: ; preds = %49
%84 = load float, float* %4
store float %84, float* %3
br label %85
85: ; preds = %83, %81
%86 = load float, float* %2
%87 = load float, float* %2
%88 = call float @sin(float %87)
%89 = load float, float* %2
%90 = call float @cos(float %89)
%91 = call float @llvm.fmuladd.f32(float %86, float %88, float %90)
store float %91, float* %5
%92 = load float, float* %3
%93 = load float, float* %3
%94 = call float @sin(float %93)
%95 = load float, float* %3
%96 = call float @cos(float %95)
%97 = call float @llvm.fmuladd.f32(float %92, float %94, float %96)
store float %97, float* %6
br label %98
98: ; preds = %85
%99 = load float, float* %3
%100 = load float, float* %2
%101 = fsub float %99, %100
%102 = fpext float %101 to double
%103 = fcmp oge double %102, 0x3EB0C6F7A0B5ED8D
br i1 %103, label %110, label %104
104: ; preds = %98
%105 = load float, float* %3
%106 = load float, float* %2
%107 = fsub float %105, %106
%108 = fpext float %107 to double
%109 = fcmp ole double %108, 0xBEB0C6F7A0B5ED8D
br label %110
110: ; preds = %104, %98
%111 = phi i1 [ true, %98 ], [ %109, %104 ]
br i1 %111, label %49, label %112
112: ; preds = %110
%113 = load float, float* %3
%114 = load float, float* %2
%115 = fadd float %113, %114
%116 = fpext float %115 to double
%117 = fdiv double %116, 2.000000e+00
%118 = fptrunc double %117 to float
store float %118, float* %4
%119 = load float, float* %4
%120 = fpext float %119 to double
%121 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str.6, i64 0, i64 0), double %120)
ret i32 0
}

LLVM IR (-O2):
@.str = [63 x i8] c"Solution for Equation using bisection method x*sin(x)+cos(x)\0A \00"
@.str.1 = [14 x i8] c"Enter Range :\00"
@.str.2 = [6 x i8] c"%f %f\00"
@.str.3 = [19 x i8] c"The solution is %f\00"
@.str.4 = [57 x i8] c"Iteration \09x0 \09 x1 \09 Mid \09 f(x0) \09 f(x1) \09 f(Mid)\00"
@.str.5 = [32 x i8] c"\0A%d\09 %f %f %f %f %f %f\0A\00"
@.str.6 = [22 x i8] c"\0AThe solution is %f\0A \00"
define i32 @main() {
%1 = alloca float
%2 = alloca float
%3 = bitcast float* %1 to i8*
store float 0.000000e+00, float* %1
%4 = bitcast float* %2 to i8*
store float 0.000000e+00, float* %2
%5 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([63 x i8], [63 x i8]* @.str, i64 0, i64 0))
br label %6
6: ; preds = %32, %0
%7 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([14 x i8], [14 x i8]* @.str.1, i64 0, i64 0))
%8 = call i32 @scanf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.2, i64 0, i64 0), float* %1, float* %2)
%9 = load float, float* %1
%10 = call float @sin(float %9)
%11 = load float, float* %1
%12 = call float @cos(float %11)
%13 = call float @llvm.fmuladd.f32(float %9, float %10, float %12)
%14 = load float, float* %2
%15 = call float @sin(float %14)
%16 = load float, float* %2
%17 = call float @cos(float %16)
%18 = call float @llvm.fmuladd.f32(float %14, float %15, float %17)
%19 = fcmp oeq float %13, 0.000000e+00
br i1 %19, label %20, label %25
20: ; preds = %6
%21 = load float, float* %1
%22 = fpext float %21 to double
%23 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([19 x i8], [19 x i8]* @.str.3, i64 0, i64 0), double %22)
%24 = call i32 @exit(i32 0)
unreachable
25: ; preds = %6
%26 = fcmp oeq float %18, 0.000000e+00
br i1 %26, label %27, label %32
27: ; preds = %25
%28 = load float, float* %2
%29 = fpext float %28 to double
%30 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([19 x i8], [19 x i8]* @.str.3, i64 0, i64 0), double %29)
%31 = call i32 @exit(i32 0)
unreachable
32: ; preds = %25
%33 = fmul float %13, %18
%34 = fcmp ogt float %33, 0.000000e+00
br i1 %34, label %6, label %35
35: ; preds = %32
%36 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([57 x i8], [57 x i8]* @.str.4, i64 0, i64 0))
%37 = load float, float* %1
%38 = load float, float* %2
br label %39
39: ; preds = %65, %35
%40 = phi float [ %38, %35 ], [ %76, %65 ]
%41 = phi float [ %37, %35 ], [ %77, %65 ]
%42 = phi float [ %13, %35 ], [ %70, %65 ]
%43 = phi float [ %18, %35 ], [ %75, %65 ]
%44 = phi i32 [ 0, %35 ], [ %50, %65 ]
%45 = fadd float %41, %40
%46 = fmul float %45, 5.000000e-01
%47 = call float @sin(float %46)
%48 = call float @cos(float %46)
%49 = call float @llvm.fmuladd.f32(float %46, float %47, float %48)
%50 = add nuw nsw i32 %44, 1
%51 = load float, float* %1
%52 = fpext float %51 to double
%53 = load float, float* %2
%54 = fpext float %53 to double
%55 = fpext float %46 to double
%56 = fpext float %42 to double
%57 = fpext float %43 to double
%58 = fpext float %49 to double
%59 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([32 x i8], [32 x i8]* @.str.5, i64 0, i64 0), i32 %50, double %52, double %54, double %55, double %56, double %57, double %58)
%60 = fmul float %42, %49
%61 = fcmp ogt float %60, 0.000000e+00
br i1 %61, label %62, label %63
62: ; preds = %39
store float %46, float* %1
br label %65
63: ; preds = %39
store float %46, float* %2
%64 = load float, float* %1
br label %65
65: ; preds = %63, %62
%66 = phi float [ %64, %63 ], [ %46, %62 ]
%67 = call float @sin(float %66)
%68 = load float, float* %1
%69 = call float @cos(float %68)
%70 = call float @llvm.fmuladd.f32(float %66, float %67, float %69)
%71 = load float, float* %2
%72 = call float @sin(float %71)
%73 = load float, float* %2
%74 = call float @cos(float %73)
%75 = call float @llvm.fmuladd.f32(float %71, float %72, float %74)
%76 = load float, float* %2
%77 = load float, float* %1
%78 = fsub float %76, %77
%79 = fpext float %78 to double
%80 = fcmp ult double %79, 0x3EB0C6F7A0B5ED8D
%81 = fcmp ugt double %79, 0xBEB0C6F7A0B5ED8D
%82 = and i1 %80, %81
br i1 %82, label %83, label %39
83: ; preds = %65
%84 = fadd float %76, %77
%85 = fmul float %84, 5.000000e-01
%86 = fpext float %85 to double
%87 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([22 x i8], [22 x i8]* @.str.6, i64 0, i64 0), double %86)
ret i32 0
}