#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 */
typedef int /*<<< orphan*/ FILE;

/* Variables and functions */
scalar_t__ fabs(float);
int /*<<< orphan*/ *fopen(char *, char *);
int /*<<< orphan*/ fprintf(int /*<<< orphan*/ *, char *, float, float);
int /*<<< orphan*/ printf(char *, ...);
int /*<<< orphan*/ scanf(char *, float *, float *);
int main(void) {
  float a, b, c = 0, cOld;
  FILE *fp = fopen("regula.txt", "w");
  printf("Enter a and b:\n");
  scanf("%f %f", &a, &b);
  while ((a * a - a - 6) * (b * b - b - 6) > 0) {
    printf("Enter different a and b:\n");
    scanf("%f %f", &a, &b);
  }
  printf("  a\t\t  f(a)\t\t  b\t\t  f(b)\t\t  c\t\t   f(c)\t\t  error\n");
  do {
    cOld = c;
    c = ((b * (a * a - a - 6)) - (a * (b * b - b - 6))) /
        ((a * a - a - 6) - (b * b - b - 6));
    fprintf(fp, "%f %f\n", a, (a * a - a - 6));
    fprintf(fp, "%f %f\n\n", b, (b * b - b - 6));
    printf("%f\t%f\t%f\t%f\t%f\t%f\t%f\n", a, (a * a - a - 6), b,
           (b * b - b - 6), c, (c * c - c - 6), (float)fabs(c - cOld));
    if ((c * c - c - 6) < 0.0000005 && (c * c - c - 6) > -0.0000005) {
      break;
    }
    if ((c * c - c - 6) * (a * a - a - 6) < 0)
      b = c;
    else
      a = c;
  } while ((c - cOld) > 0.0000005 || (c - cOld) < -0.0000005);
  printf("\tRoot:%f\n", c);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x60,%rsp
movl   $0x0,-0x4(%rbp)
xorps  %xmm0,%xmm0
movss  %xmm0,-0x10(%rbp)
lea    0xeaa(%rip),%rdi
lea    0xeae(%rip),%rsi
call   1070 <fopen@plt>
mov    %rax,-0x20(%rbp)
lea    0xea0(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xea2(%rip),%rdi
lea    -0x8(%rbp),%rsi
lea    -0xc(%rbp),%rdx
call   1060 <scanf@plt>
movss  -0x8(%rbp),%xmm0
movss  -0x8(%rbp),%xmm2
movss  -0x8(%rbp),%xmm1
movd   %xmm1,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm1
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  0xe34(%rip),%xmm1
subss  %xmm1,%xmm0
movss  -0xc(%rbp),%xmm1
movss  -0xc(%rbp),%xmm3
movss  -0xc(%rbp),%xmm2
movd   %xmm2,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm2
mulss  %xmm3,%xmm1
addss  %xmm2,%xmm1
movss  0xe04(%rip),%xmm2
subss  %xmm2,%xmm1
mulss  %xmm1,%xmm0
xorps  %xmm1,%xmm1
ucomiss %xmm1,%xmm0
jbe    1237 <main+0xe7>
lea    0xe24(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xe10(%rip),%rdi
lea    -0x8(%rbp),%rsi
lea    -0xc(%rbp),%rdx
call   1060 <scanf@plt>
jmp    11a0 <main+0x50>
lea    0xe17(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movss  -0x10(%rbp),%xmm0
movss  %xmm0,-0x14(%rbp)
movss  -0xc(%rbp),%xmm0
movss  -0x8(%rbp),%xmm2
movss  -0x8(%rbp),%xmm3
movss  -0x8(%rbp),%xmm1
movd   %xmm1,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm1
mulss  %xmm3,%xmm2
addss  %xmm1,%xmm2
movss  0xd80(%rip),%xmm1
subss  %xmm1,%xmm2
movss  -0x8(%rbp),%xmm1
movss  -0xc(%rbp),%xmm3
movss  -0xc(%rbp),%xmm5
movss  -0xc(%rbp),%xmm4
movd   %xmm4,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm4
mulss  %xmm5,%xmm3
addss  %xmm4,%xmm3
movss  0xd4b(%rip),%xmm4
subss  %xmm4,%xmm3
mulss  %xmm3,%xmm1
movd   %xmm1,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm1
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  -0x8(%rbp),%xmm1
movss  -0x8(%rbp),%xmm3
movss  -0x8(%rbp),%xmm2
movd   %xmm2,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm2
mulss  %xmm3,%xmm1
addss  %xmm2,%xmm1
movss  0xd02(%rip),%xmm2
subss  %xmm2,%xmm1
movss  -0xc(%rbp),%xmm2
movss  -0xc(%rbp),%xmm4
movss  -0xc(%rbp),%xmm3
movd   %xmm3,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm3
mulss  %xmm4,%xmm2
addss  %xmm3,%xmm2
movss  0xcd2(%rip),%xmm3
subss  %xmm3,%xmm2
subss  %xmm2,%xmm1
divss  %xmm1,%xmm0
movss  %xmm0,-0x10(%rbp)
mov    -0x20(%rbp),%rdi
movss  -0x8(%rbp),%xmm0
movss  -0x8(%rbp),%xmm1
movss  -0x8(%rbp),%xmm3
movss  -0x8(%rbp),%xmm2
movd   %xmm2,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm2
mulss  %xmm3,%xmm1
addss  %xmm2,%xmm1
movss  0xc8c(%rip),%xmm2
subss  %xmm2,%xmm1
lea    0xd07(%rip),%rsi
call   1050 <fprintf@plt>
mov    -0x20(%rbp),%rdi
movss  -0xc(%rbp),%xmm0
movss  -0xc(%rbp),%xmm1
movss  -0xc(%rbp),%xmm3
movss  -0xc(%rbp),%xmm2
movd   %xmm2,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm2
mulss  %xmm3,%xmm1
addss  %xmm2,%xmm1
movss  0xc47(%rip),%xmm2
subss  %xmm2,%xmm1
lea    0xcc9(%rip),%rsi
call   1050 <fprintf@plt>
movss  -0x8(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
movsd  %xmm0,-0x50(%rbp)
movss  -0x8(%rbp),%xmm0
movss  -0x8(%rbp),%xmm2
movss  -0x8(%rbp),%xmm1
movd   %xmm1,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm1
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  0xbfd(%rip),%xmm1
subss  %xmm1,%xmm0
cvtss2sd %xmm0,%xmm0
movsd  %xmm0,-0x48(%rbp)
movss  -0xc(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
movsd  %xmm0,-0x40(%rbp)
movss  -0xc(%rbp),%xmm0
movss  -0xc(%rbp),%xmm2
movss  -0xc(%rbp),%xmm1
movd   %xmm1,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm1
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  0xbb6(%rip),%xmm1
subss  %xmm1,%xmm0
cvtss2sd %xmm0,%xmm0
movsd  %xmm0,-0x38(%rbp)
movss  -0x10(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
movsd  %xmm0,-0x30(%rbp)
movss  -0x10(%rbp),%xmm0
movss  -0x10(%rbp),%xmm2
movss  -0x10(%rbp),%xmm1
movd   %xmm1,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm1
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  0xb6f(%rip),%xmm1
subss  %xmm1,%xmm0
cvtss2sd %xmm0,%xmm0
movsd  %xmm0,-0x28(%rbp)
movss  -0x10(%rbp),%xmm0
subss  -0x14(%rbp),%xmm0
call   1040 <fabs@plt>
movsd  -0x50(%rbp),%xmm0
movsd  -0x48(%rbp),%xmm1
movsd  -0x40(%rbp),%xmm2
movsd  -0x38(%rbp),%xmm3
movsd  -0x30(%rbp),%xmm4
movsd  -0x28(%rbp),%xmm5
cvtsi2ss %rax,%xmm6
cvtss2sd %xmm6,%xmm6
lea    0xbba(%rip),%rdi
mov    $0x7,%al
call   1030 <printf@plt>
movss  -0x10(%rbp),%xmm0
movss  -0x10(%rbp),%xmm2
movss  -0x10(%rbp),%xmm1
movd   %xmm1,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm1
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  0xaf2(%rip),%xmm1
subss  %xmm1,%xmm0
cvtss2sd %xmm0,%xmm1
movsd  0xaea(%rip),%xmm0
ucomisd %xmm1,%xmm0
jbe    1573 <main+0x423>
movss  -0x10(%rbp),%xmm0
movss  -0x10(%rbp),%xmm2
movss  -0x10(%rbp),%xmm1
movd   %xmm1,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm1
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  0xaac(%rip),%xmm1
subss  %xmm1,%xmm0
cvtss2sd %xmm0,%xmm0
movsd  0xaac(%rip),%xmm1
ucomisd %xmm1,%xmm0
jbe    1573 <main+0x423>
jmp    1651 <main+0x501>
movss  -0x10(%rbp),%xmm1
movss  -0x10(%rbp),%xmm2
movss  -0x10(%rbp),%xmm0
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm1
addss  %xmm0,%xmm1
movss  0xa61(%rip),%xmm0
subss  %xmm0,%xmm1
movss  -0x8(%rbp),%xmm0
movss  -0x8(%rbp),%xmm3
movss  -0x8(%rbp),%xmm2
movd   %xmm2,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm2
mulss  %xmm3,%xmm0
addss  %xmm2,%xmm0
movss  0xa31(%rip),%xmm2
subss  %xmm2,%xmm0
mulss  %xmm0,%xmm1
xorps  %xmm0,%xmm0
ucomiss %xmm1,%xmm0
jbe    15f2 <main+0x4a2>
movss  -0x10(%rbp),%xmm0
movss  %xmm0,-0xc(%rbp)
jmp    15fc <main+0x4ac>
movss  -0x10(%rbp),%xmm0
movss  %xmm0,-0x8(%rbp)
jmp    1601 <main+0x4b1>
movss  -0x10(%rbp),%xmm0
subss  -0x14(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
mov    $0x1,%al
movsd  0x9ef(%rip),%xmm1
ucomisd %xmm1,%xmm0
mov    %al,-0x51(%rbp)
ja     1646 <main+0x4f6>
movss  -0x10(%rbp),%xmm0
subss  -0x14(%rbp),%xmm0
cvtss2sd %xmm0,%xmm1
movsd  0x9d4(%rip),%xmm0
ucomisd %xmm1,%xmm0
seta   %al
mov    %al,-0x51(%rbp)
mov    -0x51(%rbp),%al
test   $0x1,%al
jne    1245 <main+0xf5>
movss  -0x10(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
lea    0xa4a(%rip),%rdi
mov    $0x1,%al
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x60,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x70,%rsp
lea    0xec4(%rip),%rdi
lea    0xec8(%rip),%rsi
call   1080 <fopen@plt>
mov    %rax,%r13
lea    0xef0(%rip),%rdi
call   1030 <puts@plt>
lea    0xeaf(%rip),%rdi
lea    0xc(%rsp),%rsi
lea    0x8(%rsp),%rdx
call   1070 <scanf@plt>
movss  0x8(%rsp),%xmm0
movss  0xc(%rsp),%xmm1
unpcklps %xmm0,%xmm1
movaps %xmm1,%xmm0
mulps  %xmm1,%xmm0
subps  %xmm1,%xmm0
addps  0xe3c(%rip),%xmm0
movaps %xmm0,%xmm1
shufps $0x55,%xmm0,%xmm1
mulss  %xmm0,%xmm1
xorps  %xmm0,%xmm0
ucomiss %xmm0,%xmm1
jbe    1239 <main+0xd9>
lea    0xedb(%rip),%r14
lea    0xe60(%rip),%r15
lea    0xc(%rsp),%r12
lea    0x8(%rsp),%rbx
nop
mov    %r14,%rdi
call   1030 <puts@plt>
mov    %r15,%rdi
mov    %r12,%rsi
mov    %rbx,%rdx
call   1070 <scanf@plt>
movss  0x8(%rsp),%xmm0
movss  0xc(%rsp),%xmm1
unpcklps %xmm0,%xmm1
movaps %xmm1,%xmm0
mulps  %xmm1,%xmm0
subps  %xmm1,%xmm0
addps  0xddb(%rip),%xmm0
movaps %xmm0,%xmm1
shufps $0x55,%xmm0,%xmm1
mulss  %xmm0,%xmm1
ucomiss 0xded(%rip),%xmm1
ja     11f0 <main+0x90>
lea    0xe49(%rip),%rdi
call   1030 <puts@plt>
movss  0xc(%rsp),%xmm0
lea    0xdf9(%rip),%r14
lea    0xdf9(%rip),%r15
lea    0xdfa(%rip),%r12
xorps  %xmm3,%xmm3
cs nopw 0x0(%rax,%rax,1)
nopl   (%rax)
movss  %xmm3,0x20(%rsp)
movss  0x8(%rsp),%xmm4
movaps %xmm0,%xmm2
unpcklps %xmm4,%xmm2
movaps %xmm0,%xmm3
xorps  0xd84(%rip),%xmm3
movaps %xmm2,%xmm1
mulps  %xmm2,%xmm1
subps  %xmm2,%xmm1
addps  0xd64(%rip),%xmm1
movaps %xmm1,%xmm2
shufps $0x55,%xmm1,%xmm2
mulss  %xmm2,%xmm3
mulss  %xmm1,%xmm4
addss  %xmm3,%xmm4
movaps %xmm1,%xmm3
subss  %xmm2,%xmm3
divss  %xmm3,%xmm4
movaps %xmm4,0x50(%rsp)
mov    %r13,%rdi
mov    %r14,%rsi
call   1060 <fprintf@plt>
movss  0x8(%rsp),%xmm0
movaps %xmm0,%xmm1
mulss  %xmm0,%xmm1
subss  %xmm0,%xmm1
movss  0xd3d(%rip),%xmm2
addss  %xmm2,%xmm1
mov    %r13,%rdi
mov    %r15,%rsi
call   1060 <fprintf@plt>
movss  0xc(%rsp),%xmm0
xorps  %xmm1,%xmm1
cvtss2sd %xmm0,%xmm1
movsd  %xmm1,0x48(%rsp)
movaps %xmm0,%xmm1
mulss  %xmm0,%xmm1
subss  %xmm0,%xmm1
movss  0xd08(%rip),%xmm2
addss  %xmm2,%xmm1
xorps  %xmm0,%xmm0
cvtss2sd %xmm1,%xmm0
movsd  %xmm0,0x40(%rsp)
movss  0x8(%rsp),%xmm0
xorps  %xmm1,%xmm1
cvtss2sd %xmm0,%xmm1
movsd  %xmm1,0x38(%rsp)
movaps %xmm0,%xmm1
mulss  %xmm0,%xmm1
subss  %xmm0,%xmm1
addss  %xmm2,%xmm1
xorps  %xmm0,%xmm0
cvtss2sd %xmm1,%xmm0
movsd  %xmm0,0x30(%rsp)
movaps 0x50(%rsp),%xmm1
xorps  %xmm0,%xmm0
cvtss2sd %xmm1,%xmm0
movsd  %xmm0,0x10(%rsp)
movaps %xmm1,%xmm0
mulss  %xmm1,%xmm0
subss  %xmm1,%xmm0
addss  %xmm2,%xmm0
movaps %xmm0,0x60(%rsp)
cvtss2sd %xmm0,%xmm0
movsd  %xmm0,0x18(%rsp)
movaps %xmm1,%xmm0
subss  0x20(%rsp),%xmm0
movaps %xmm0,0x20(%rsp)
call   1050 <fabs@plt>
xorps  %xmm0,%xmm0
cvtsi2ss %rax,%xmm0
cvtss2sd %xmm0,%xmm6
mov    %r12,%rdi
movsd  0x48(%rsp),%xmm0
movsd  0x40(%rsp),%xmm1
movsd  0x38(%rsp),%xmm2
movsd  0x30(%rsp),%xmm3
movsd  0x10(%rsp),%xmm4
movsd  0x18(%rsp),%xmm5
mov    $0x7,%al
call   1040 <printf@plt>
movsd  0x18(%rsp),%xmm0
movaps 0x50(%rsp),%xmm3
movsd  0xc40(%rip),%xmm2
ucomisd %xmm0,%xmm2
jbe    13f8 <main+0x298>
ucomisd 0xc3a(%rip),%xmm0
ja     145e <main+0x2fe>
movss  0xc(%rsp),%xmm0
movaps %xmm0,%xmm1
mulss  %xmm0,%xmm1
subss  %xmm0,%xmm1
addss  0xc0f(%rip),%xmm1
movaps 0x60(%rsp),%xmm4
mulss  %xmm1,%xmm4
xorps  %xmm1,%xmm1
ucomiss %xmm4,%xmm1
jbe    1430 <main+0x2d0>
movss  %xmm3,0x8(%rsp)
jmp    1439 <main+0x2d9>
nopw   0x0(%rax,%rax,1)
movss  %xmm3,0xc(%rsp)
movaps %xmm3,%xmm0
movaps 0x20(%rsp),%xmm1
cvtss2sd %xmm1,%xmm1
ucomisd %xmm2,%xmm1
ja     1270 <main+0x110>
movsd  0xbdc(%rip),%xmm2
ucomisd %xmm1,%xmm2
ja     1270 <main+0x110>
lea    0xc0b(%rip),%rdi
movsd  0x10(%rsp),%xmm0
mov    $0x1,%al
call   1040 <printf@plt>
xor    %eax,%eax
add    $0x70,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
ret

LLVM IR (-O0):
@.str = [11 x i8] c"regula.txt\00"
@.str.1 = [2 x i8] c"w\00"
@.str.2 = [16 x i8] c"Enter a and b:\0A\00"
@.str.3 = [6 x i8] c"%f %f\00"
@.str.4 = [26 x i8] c"Enter different a and b:\0A\00"
@.str.5 = [49 x i8] c" a\09\09 f(a)\09\09 b\09\09 f(b)\09\09 c\09\09 f(c)\09\09 error\0A\00"
@.str.6 = [7 x i8] c"%f %f\0A\00"
@.str.7 = [8 x i8] c"%f %f\0A\0A\00"
@.str.8 = [22 x i8] c"%f\09%f\09%f\09%f\09%f\09%f\09%f\0A\00"
@.str.9 = [10 x i8] c"\09Root:%f\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca float
%3 = alloca float
%4 = alloca float
%5 = alloca float
%6 = alloca i32*
store i32 0, i32* %1
store float 0.000000e+00, float* %4
%7 = call i32* @fopen(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
store i32* %7, i32** %6
%8 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str.2, i64 0, i64 0))
%9 = call i32 @scanf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.3, i64 0, i64 0), float* %2, float* %3)
br label %10
10: ; preds = %25, %0
%11 = load float, float* %2
%12 = load float, float* %2
%13 = load float, float* %2
%14 = fneg float %13
%15 = call float @llvm.fmuladd.f32(float %11, float %12, float %14)
%16 = fsub float %15, 6.000000e+00
%17 = load float, float* %3
%18 = load float, float* %3
%19 = load float, float* %3
%20 = fneg float %19
%21 = call float @llvm.fmuladd.f32(float %17, float %18, float %20)
%22 = fsub float %21, 6.000000e+00
%23 = fmul float %16, %22
%24 = fcmp ogt float %23, 0.000000e+00
br i1 %24, label %25, label %28
25: ; preds = %10
%26 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([26 x i8], [26 x i8]* @.str.4, i64 0, i64 0))
%27 = call i32 @scanf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.3, i64 0, i64 0), float* %2, float* %3)
br label %10
28: ; preds = %10
%29 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([49 x i8], [49 x i8]* @.str.5, i64 0, i64 0))
br label %30
30: ; preds = %165, %28
%31 = load float, float* %4
store float %31, float* %5
%32 = load float, float* %3
%33 = load float, float* %2
%34 = load float, float* %2
%35 = load float, float* %2
%36 = fneg float %35
%37 = call float @llvm.fmuladd.f32(float %33, float %34, float %36)
%38 = fsub float %37, 6.000000e+00
%39 = load float, float* %2
%40 = load float, float* %3
%41 = load float, float* %3
%42 = load float, float* %3
%43 = fneg float %42
%44 = call float @llvm.fmuladd.f32(float %40, float %41, float %43)
%45 = fsub float %44, 6.000000e+00
%46 = fmul float %39, %45
%47 = fneg float %46
%48 = call float @llvm.fmuladd.f32(float %32, float %38, float %47)
%49 = load float, float* %2
%50 = load float, float* %2
%51 = load float, float* %2
%52 = fneg float %51
%53 = call float @llvm.fmuladd.f32(float %49, float %50, float %52)
%54 = fsub float %53, 6.000000e+00
%55 = load float, float* %3
%56 = load float, float* %3
%57 = load float, float* %3
%58 = fneg float %57
%59 = call float @llvm.fmuladd.f32(float %55, float %56, float %58)
%60 = fsub float %59, 6.000000e+00
%61 = fsub float %54, %60
%62 = fdiv float %48, %61
store float %62, float* %4
%63 = load i32*, i32** %6
%64 = load float, float* %2
%65 = load float, float* %2
%66 = load float, float* %2
%67 = load float, float* %2
%68 = fneg float %67
%69 = call float @llvm.fmuladd.f32(float %65, float %66, float %68)
%70 = fsub float %69, 6.000000e+00
%71 = call i32 @fprintf(i32* %63, i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.6, i64 0, i64 0), float %64, float %70)
%72 = load i32*, i32** %6
%73 = load float, float* %3
%74 = load float, float* %3
%75 = load float, float* %3
%76 = load float, float* %3
%77 = fneg float %76
%78 = call float @llvm.fmuladd.f32(float %74, float %75, float %77)
%79 = fsub float %78, 6.000000e+00
%80 = call i32 @fprintf(i32* %72, i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.7, i64 0, i64 0), float %73, float %79)
%81 = load float, float* %2
%82 = fpext float %81 to double
%83 = load float, float* %2
%84 = load float, float* %2
%85 = load float, float* %2
%86 = fneg float %85
%87 = call float @llvm.fmuladd.f32(float %83, float %84, float %86)
%88 = fsub float %87, 6.000000e+00
%89 = fpext float %88 to double
%90 = load float, float* %3
%91 = fpext float %90 to double
%92 = load float, float* %3
%93 = load float, float* %3
%94 = load float, float* %3
%95 = fneg float %94
%96 = call float @llvm.fmuladd.f32(float %92, float %93, float %95)
%97 = fsub float %96, 6.000000e+00
%98 = fpext float %97 to double
%99 = load float, float* %4
%100 = fpext float %99 to double
%101 = load float, float* %4
%102 = load float, float* %4
%103 = load float, float* %4
%104 = fneg float %103
%105 = call float @llvm.fmuladd.f32(float %101, float %102, float %104)
%106 = fsub float %105, 6.000000e+00
%107 = fpext float %106 to double
%108 = load float, float* %4
%109 = load float, float* %5
%110 = fsub float %108, %109
%111 = call i64 @fabs(float %110)
%112 = sitofp i64 %111 to float
%113 = fpext float %112 to double
%114 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str.8, i64 0, i64 0), double %82, double %89, double %91, double %98, double %100, double %107, double %113)
%115 = load float, float* %4
%116 = load float, float* %4
%117 = load float, float* %4
%118 = fneg float %117
%119 = call float @llvm.fmuladd.f32(float %115, float %116, float %118)
%120 = fsub float %119, 6.000000e+00
%121 = fpext float %120 to double
%122 = fcmp olt double %121, 5.000000e-07
br i1 %122, label %123, label %133
123: ; preds = %30
%124 = load float, float* %4
%125 = load float, float* %4
%126 = load float, float* %4
%127 = fneg float %126
%128 = call float @llvm.fmuladd.f32(float %124, float %125, float %127)
%129 = fsub float %128, 6.000000e+00
%130 = fpext float %129 to double
%131 = fcmp ogt double %130, -5.000000e-07
br i1 %131, label %132, label %133
132: ; preds = %123
br label %167
133: ; preds = %123, %30
%134 = load float, float* %4
%135 = load float, float* %4
%136 = load float, float* %4
%137 = fneg float %136
%138 = call float @llvm.fmuladd.f32(float %134, float %135, float %137)
%139 = fsub float %138, 6.000000e+00
%140 = load float, float* %2
%141 = load float, float* %2
%142 = load float, float* %2
%143 = fneg float %142
%144 = call float @llvm.fmuladd.f32(float %140, float %141, float %143)
%145 = fsub float %144, 6.000000e+00
%146 = fmul float %139, %145
%147 = fcmp olt float %146, 0.000000e+00
br i1 %147, label %148, label %150
148: ; preds = %133
%149 = load float, float* %4
store float %149, float* %3
br label %152
150: ; preds = %133
%151 = load float, float* %4
store float %151, float* %2
br label %152
152: ; preds = %150, %148
br label %153
153: ; preds = %152
%154 = load float, float* %4
%155 = load float, float* %5
%156 = fsub float %154, %155
%157 = fpext float %156 to double
%158 = fcmp ogt double %157, 5.000000e-07
br i1 %158, label %165, label %159
159: ; preds = %153
%160 = load float, float* %4
%161 = load float, float* %5
%162 = fsub float %160, %161
%163 = fpext float %162 to double
%164 = fcmp olt double %163, -5.000000e-07
br label %165
165: ; preds = %159, %153
%166 = phi i1 [ true, %153 ], [ %164, %159 ]
br i1 %166, label %30, label %167
167: ; preds = %165, %132
%168 = load float, float* %4
%169 = fpext float %168 to double
%170 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.9, i64 0, i64 0), double %169)
ret i32 0
}

LLVM IR (-O2):
@.str = [11 x i8] c"regula.txt\00"
@.str.1 = [2 x i8] c"w\00"
@.str.3 = [6 x i8] c"%f %f\00"
@.str.6 = [7 x i8] c"%f %f\0A\00"
@.str.7 = [8 x i8] c"%f %f\0A\0A\00"
@.str.8 = [22 x i8] c"%f\09%f\09%f\09%f\09%f\09%f\09%f\0A\00"
@.str.9 = [10 x i8] c"\09Root:%f\0A\00"
@str = [15 x i8] c"Enter a and b:\00"
@str.10 = [48 x i8] c" a\09\09 f(a)\09\09 b\09\09 f(b)\09\09 c\09\09 f(c)\09\09 error\00"
@str.11 = [25 x i8] c"Enter different a and b:\00"
define i32 @main() {
%1 = alloca float
%2 = alloca float
%3 = bitcast float* %1 to i8*
%4 = bitcast float* %2 to i8*
%5 = tail call i32* @fopen(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
%6 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([15 x i8], [15 x i8]* @str, i64 0, i64 0))
%7 = call i32 @scanf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.3, i64 0, i64 0), float* %1, float* %2)
%8 = load float, float* %1
%9 = load float, float* %2
%10 = insertelement <2 x float> poison, float %8, i64 0
%11 = insertelement <2 x float> %10, float %9, i64 1
%12 = fneg <2 x float> %11
%13 = call <2 x float> @llvm.fmuladd.v2f32(<2 x float> %11, <2 x float> %11, <2 x float> %12)
%14 = fadd <2 x float> %13, <float -6.000000e+00, float -6.000000e+00>
%15 = shufflevector <2 x float> %14, <2 x float> poison, <2 x i32> <i32 1, i32 undef>
%16 = fmul <2 x float> %14, %15
%17 = extractelement <2 x float> %16, i64 0
%18 = fcmp ogt float %17, 0.000000e+00
br i1 %18, label %19, label %33
19: ; preds = %0, %19
%20 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([25 x i8], [25 x i8]* @str.11, i64 0, i64 0))
%21 = call i32 @scanf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.3, i64 0, i64 0), float* %1, float* %2)
%22 = load float, float* %1
%23 = load float, float* %2
%24 = insertelement <2 x float> poison, float %22, i64 0
%25 = insertelement <2 x float> %24, float %23, i64 1
%26 = fneg <2 x float> %25
%27 = call <2 x float> @llvm.fmuladd.v2f32(<2 x float> %25, <2 x float> %25, <2 x float> %26)
%28 = fadd <2 x float> %27, <float -6.000000e+00, float -6.000000e+00>
%29 = shufflevector <2 x float> %28, <2 x float> poison, <2 x i32> <i32 1, i32 undef>
%30 = fmul <2 x float> %28, %29
%31 = extractelement <2 x float> %30, i64 0
%32 = fcmp ogt float %31, 0.000000e+00
br i1 %32, label %19, label %33
33: ; preds = %19, %0
%34 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([48 x i8], [48 x i8]* @str.10, i64 0, i64 0))
%35 = load float, float* %1
br label %36
36: ; preds = %92, %33
%37 = phi float [ %35, %33 ], [ %93, %92 ]
%38 = phi float [ 0.000000e+00, %33 ], [ %51, %92 ]
%39 = load float, float* %2
%40 = insertelement <2 x float> poison, float %37, i64 0
%41 = insertelement <2 x float> %40, float %39, i64 1
%42 = fneg <2 x float> %41
%43 = call <2 x float> @llvm.fmuladd.v2f32(<2 x float> %41, <2 x float> %41, <2 x float> %42)
%44 = fadd <2 x float> %43, <float -6.000000e+00, float -6.000000e+00>
%45 = extractelement <2 x float> %44, i64 1
%46 = extractelement <2 x float> %42, i64 0
%47 = fmul float %45, %46
%48 = extractelement <2 x float> %44, i64 0
%49 = call float @llvm.fmuladd.f32(float %39, float %48, float %47)
%50 = fsub float %48, %45
%51 = fdiv float %49, %50
%52 = call i32 @fprintf(i32* %5, i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.6, i64 0, i64 0), float %37, float %48)
%53 = load float, float* %2
%54 = fneg float %53
%55 = call float @llvm.fmuladd.f32(float %53, float %53, float %54)
%56 = fadd float %55, -6.000000e+00
%57 = call i32 @fprintf(i32* %5, i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.7, i64 0, i64 0), float %53, float %56)
%58 = load float, float* %1
%59 = fpext float %58 to double
%60 = fneg float %58
%61 = call float @llvm.fmuladd.f32(float %58, float %58, float %60)
%62 = fadd float %61, -6.000000e+00
%63 = fpext float %62 to double
%64 = load float, float* %2
%65 = fpext float %64 to double
%66 = fneg float %64
%67 = call float @llvm.fmuladd.f32(float %64, float %64, float %66)
%68 = fadd float %67, -6.000000e+00
%69 = fpext float %68 to double
%70 = fpext float %51 to double
%71 = fneg float %51
%72 = call float @llvm.fmuladd.f32(float %51, float %51, float %71)
%73 = fadd float %72, -6.000000e+00
%74 = fpext float %73 to double
%75 = fsub float %51, %38
%76 = call i64 @fabs(float %75)
%77 = sitofp i64 %76 to float
%78 = fpext float %77 to double
%79 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([22 x i8], [22 x i8]* @.str.8, i64 0, i64 0), double %59, double %63, double %65, double %69, double %70, double %74, double %78)
%80 = fcmp olt double %74, 5.000000e-07
%81 = fcmp ogt double %74, -5.000000e-07
%82 = and i1 %80, %81
br i1 %82, label %98, label %83
83: ; preds = %36
%84 = load float, float* %1
%85 = fneg float %84
%86 = call float @llvm.fmuladd.f32(float %84, float %84, float %85)
%87 = fadd float %86, -6.000000e+00
%88 = fmul float %73, %87
%89 = fcmp olt float %88, 0.000000e+00
br i1 %89, label %90, label %91
90: ; preds = %83
store float %51, float* %2
br label %92
91: ; preds = %83
store float %51, float* %1
br label %92
92: ; preds = %90, %91
%93 = phi float [ %84, %90 ], [ %51, %91 ]
%94 = fpext float %75 to double
%95 = fcmp ogt double %94, 5.000000e-07
%96 = fcmp olt double %94, -5.000000e-07
%97 = or i1 %95, %96
br i1 %97, label %36, label %98
98: ; preds = %92, %36
%99 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([10 x i8], [10 x i8]* @.str.9, i64 0, i64 0), double %70)
ret i32 0
}