#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 */
double fabs(double);
int /*<<< orphan*/ printf(char *);
double stub1(double, void *);
double stub2(double, void *);
double stub3(double, void *);
double uniroot(double start, double end, double (*f)(double, void *),
               double tolx, void *info) {
  double a, b, c;
  double fa, fb, fc;
  double prev;
  double currenttol;
  double p, q, new_step;
  double cb, t1, t2;
  a = start;
  b = end;
  fa = (*f)(a, info);
  fb = (*f)(b, info);
  c = a;
  fc = fa;
  if ((fa > (double)0 && fb > (double)0) ||
      (fa < (double)0 && fb < (double)0)) {
    printf("mooep!\n");
  }
  while (1) {
    prev = b - a;
    if (fabs(fc) < fabs(fb)) {
      a = b;
      b = c;
      c = a;
      fa = fb;
      fb = fc;
      fc = fa;
    }
    currenttol = 2 * 1.192092896e-06 * fabs(b) + tolx / 2;
    new_step = (c - b) / 2;
    if (fabs(new_step) <= currenttol || fb == (double)0) {
      return b;
    }
    if (fabs(prev) >= currenttol && fabs(fa) > fabs(fb)) {
      cb = c - b;
      if (a == c) {
        t1 = fb / fa;
        p = cb * t1;
        q = 1.0 - t1;
      } else {
        q = fa / fc;
        t1 = fb / fc;
        t2 = fb / fa;
        p = t2 * (cb * q * (q - t1) - (b - a) * (t1 - 1.0));
        q = (q - 1.0) * (t1 - 1.0) * (t2 - 1.0);
      }
      if (p > (double)0) {
        q = -q;
      } else {
        p = -p;
      }
      if (p < (0.75 * cb * q - fabs(currenttol * q) / 2) &&
          p < fabs(prev * q / 2)) {
        new_step = p / q;
      }
    }
    if (fabs(new_step) < currenttol) {
      if (new_step > (double)0) {
        new_step = currenttol;
      } else {
        new_step = -currenttol;
      }
    }
    a = b;
    fa = fb;
    b += new_step;
    fb = (*f)(b, info);
    if ((fb > 0 && fc > 0) || (fb < 0 && fc < 0)) {
      c = a;
      fc = fa;
    }
  }
  return 0;
}


x86 assembly (clang, -O0):
<uniroot>:
push   %rbp
mov    %rsp,%rbp
sub    $0xa0,%rsp
movsd  %xmm0,-0x8(%rbp)
movsd  %xmm1,-0x10(%rbp)
mov    %rdi,-0x18(%rbp)
movsd  %xmm2,-0x20(%rbp)
mov    %rsi,-0x28(%rbp)
movsd  -0x8(%rbp),%xmm0
movsd  %xmm0,-0x30(%rbp)
movsd  -0x10(%rbp),%xmm0
movsd  %xmm0,-0x38(%rbp)
mov    -0x18(%rbp),%rax
movsd  -0x30(%rbp),%xmm0
mov    -0x28(%rbp),%rdi
call   *%rax
movsd  %xmm0,-0x48(%rbp)
mov    -0x18(%rbp),%rax
movsd  -0x38(%rbp),%xmm0
mov    -0x28(%rbp),%rdi
call   *%rax
movsd  %xmm0,-0x50(%rbp)
movsd  -0x30(%rbp),%xmm0
movsd  %xmm0,-0x40(%rbp)
movsd  -0x48(%rbp),%xmm0
movsd  %xmm0,-0x58(%rbp)
movsd  -0x48(%rbp),%xmm0
xorps  %xmm1,%xmm1
ucomisd %xmm1,%xmm0
jbe    11a6 <uniroot+0x96>
movsd  -0x50(%rbp),%xmm0
xorps  %xmm1,%xmm1
ucomisd %xmm1,%xmm0
ja     11c2 <uniroot+0xb2>
xorps  %xmm0,%xmm0
ucomisd -0x48(%rbp),%xmm0
jbe    11ce <uniroot+0xbe>
xorps  %xmm0,%xmm0
ucomisd -0x50(%rbp),%xmm0
jbe    11ce <uniroot+0xbe>
lea    0xe67(%rip),%rdi
call   1030 <printf@plt>
jmp    11d3 <uniroot+0xc3>
movsd  -0x38(%rbp),%xmm0
subsd  -0x30(%rbp),%xmm0
movsd  %xmm0,-0x60(%rbp)
movsd  -0x58(%rbp),%xmm1
movaps 0xe12(%rip),%xmm0
pand   %xmm0,%xmm1
movsd  -0x50(%rbp),%xmm0
movaps 0xe02(%rip),%xmm2
pand   %xmm2,%xmm0
ucomisd %xmm1,%xmm0
jbe    1248 <uniroot+0x138>
movsd  -0x38(%rbp),%xmm0
movsd  %xmm0,-0x30(%rbp)
movsd  -0x40(%rbp),%xmm0
movsd  %xmm0,-0x38(%rbp)
movsd  -0x30(%rbp),%xmm0
movsd  %xmm0,-0x40(%rbp)
movsd  -0x50(%rbp),%xmm0
movsd  %xmm0,-0x48(%rbp)
movsd  -0x58(%rbp),%xmm0
movsd  %xmm0,-0x50(%rbp)
movsd  -0x48(%rbp),%xmm0
movsd  %xmm0,-0x58(%rbp)
movsd  -0x38(%rbp),%xmm0
movaps 0xdac(%rip),%xmm1
pand   %xmm1,%xmm0
movsd  -0x20(%rbp),%xmm1
movsd  0xdab(%rip),%xmm2
divsd  %xmm2,%xmm1
movsd  0xda7(%rip),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x68(%rbp)
movsd  -0x40(%rbp),%xmm0
subsd  -0x38(%rbp),%xmm0
movsd  0xd80(%rip),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x80(%rbp)
movsd  -0x80(%rbp),%xmm1
movaps 0xd5b(%rip),%xmm0
pand   %xmm0,%xmm1
movsd  -0x68(%rbp),%xmm0
ucomisd %xmm1,%xmm0
jae    12d0 <uniroot+0x1c0>
movsd  -0x50(%rbp),%xmm0
xorps  %xmm1,%xmm1
ucomisd %xmm1,%xmm0
jne    12de <uniroot+0x1ce>
jp     12de <uniroot+0x1ce>
movsd  -0x38(%rbp),%xmm0
add    $0xa0,%rsp
pop    %rbp
ret
movsd  -0x60(%rbp),%xmm0
movaps 0xd16(%rip),%xmm1
pand   %xmm1,%xmm0
ucomisd -0x68(%rbp),%xmm0
jb     1572 <uniroot+0x462>
movsd  -0x48(%rbp),%xmm0
movaps 0xcfb(%rip),%xmm1
pand   %xmm1,%xmm0
movsd  -0x50(%rbp),%xmm1
movaps 0xceb(%rip),%xmm2
pand   %xmm2,%xmm1
ucomisd %xmm1,%xmm0
jbe    1572 <uniroot+0x462>
movsd  -0x40(%rbp),%xmm0
subsd  -0x38(%rbp),%xmm0
movsd  %xmm0,-0x88(%rbp)
ff
movsd  -0x30(%rbp),%xmm0
ucomisd -0x40(%rbp),%xmm0
jne    138c <uniroot+0x27c>
jp     138c <uniroot+0x27c>
movsd  -0x50(%rbp),%xmm0
divsd  -0x48(%rbp),%xmm0
movsd  %xmm0,-0x90(%rbp)
ff
movsd  -0x88(%rbp),%xmm0
ff
mulsd  -0x90(%rbp),%xmm0
ff
movsd  %xmm0,-0x70(%rbp)
movsd  0xca6(%rip),%xmm0
subsd  -0x90(%rbp),%xmm0
ff
movsd  %xmm0,-0x78(%rbp)
jmp    1471 <uniroot+0x361>
movsd  -0x48(%rbp),%xmm0
divsd  -0x58(%rbp),%xmm0
movsd  %xmm0,-0x78(%rbp)
movsd  -0x50(%rbp),%xmm0
divsd  -0x58(%rbp),%xmm0
movsd  %xmm0,-0x90(%rbp)
ff
movsd  -0x50(%rbp),%xmm0
divsd  -0x48(%rbp),%xmm0
movsd  %xmm0,-0x98(%rbp)
ff
movsd  -0x98(%rbp),%xmm0
ff
movsd  -0x88(%rbp),%xmm1
ff
mulsd  -0x78(%rbp),%xmm1
movsd  -0x78(%rbp),%xmm3
subsd  -0x90(%rbp),%xmm3
ff
movsd  -0x38(%rbp),%xmm2
subsd  -0x30(%rbp),%xmm2
movsd  -0x90(%rbp),%xmm4
ff
movsd  0xc25(%rip),%xmm5
subsd  %xmm5,%xmm4
mulsd  %xmm4,%xmm2
movq   %xmm2,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm2
mulsd  %xmm3,%xmm1
addsd  %xmm2,%xmm1
mulsd  %xmm1,%xmm0
movsd  %xmm0,-0x70(%rbp)
movsd  -0x78(%rbp),%xmm0
movsd  0xbe8(%rip),%xmm1
subsd  %xmm1,%xmm0
movsd  -0x90(%rbp),%xmm1
ff
movsd  0xbd4(%rip),%xmm2
subsd  %xmm2,%xmm1
mulsd  %xmm1,%xmm0
movsd  -0x98(%rbp),%xmm1
ff
movsd  0xbbc(%rip),%xmm2
subsd  %xmm2,%xmm1
mulsd  %xmm1,%xmm0
movsd  %xmm0,-0x78(%rbp)
movsd  -0x70(%rbp),%xmm0
xorps  %xmm1,%xmm1
ucomisd %xmm1,%xmm0
jbe    14a9 <uniroot+0x399>
movsd  -0x78(%rbp),%xmm0
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
movsd  %xmm0,-0x78(%rbp)
jmp    14ca <uniroot+0x3ba>
movsd  -0x70(%rbp),%xmm0
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
movsd  %xmm0,-0x70(%rbp)
movsd  -0x70(%rbp),%xmm1
movsd  0xb51(%rip),%xmm0
mulsd  -0x88(%rbp),%xmm0
ff
movsd  -0x78(%rbp),%xmm3
movsd  -0x68(%rbp),%xmm2
mulsd  -0x78(%rbp),%xmm2
movaps 0xb0b(%rip),%xmm4
pand   %xmm4,%xmm2
movsd  0xb0f(%rip),%xmm4
divsd  %xmm4,%xmm2
movq   %xmm2,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm2
mulsd  %xmm3,%xmm0
addsd  %xmm2,%xmm0
ucomisd %xmm1,%xmm0
jbe    156d <uniroot+0x45d>
movsd  -0x70(%rbp),%xmm1
movsd  -0x60(%rbp),%xmm0
mulsd  -0x78(%rbp),%xmm0
movsd  0xacb(%rip),%xmm2
divsd  %xmm2,%xmm0
movaps 0xab0(%rip),%xmm2
pand   %xmm2,%xmm0
ucomisd %xmm1,%xmm0
jbe    156d <uniroot+0x45d>
movsd  -0x70(%rbp),%xmm0
divsd  -0x78(%rbp),%xmm0
movsd  %xmm0,-0x80(%rbp)
jmp    1572 <uniroot+0x462>
movsd  -0x80(%rbp),%xmm1
movaps 0xa82(%rip),%xmm0
pand   %xmm0,%xmm1
movsd  -0x68(%rbp),%xmm0
ucomisd %xmm1,%xmm0
jbe    15d8 <uniroot+0x4c8>
movsd  -0x80(%rbp),%xmm0
xorps  %xmm1,%xmm1
ucomisd %xmm1,%xmm0
jbe    15b2 <uniroot+0x4a2>
movsd  -0x68(%rbp),%xmm0
movsd  %xmm0,-0x80(%rbp)
jmp    15d3 <uniroot+0x4c3>
movsd  -0x68(%rbp),%xmm0
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
movsd  %xmm0,-0x80(%rbp)
jmp    15d8 <uniroot+0x4c8>
movsd  -0x38(%rbp),%xmm0
movsd  %xmm0,-0x30(%rbp)
movsd  -0x50(%rbp),%xmm0
movsd  %xmm0,-0x48(%rbp)
movsd  -0x80(%rbp),%xmm0
addsd  -0x38(%rbp),%xmm0
movsd  %xmm0,-0x38(%rbp)
mov    -0x18(%rbp),%rax
movsd  -0x38(%rbp),%xmm0
mov    -0x28(%rbp),%rdi
call   *%rax
movsd  %xmm0,-0x50(%rbp)
movsd  -0x50(%rbp),%xmm0
xorps  %xmm1,%xmm1
ucomisd %xmm1,%xmm0
jbe    1633 <uniroot+0x523>
movsd  -0x58(%rbp),%xmm0
xorps  %xmm1,%xmm1
ucomisd %xmm1,%xmm0
ja     164f <uniroot+0x53f>
xorps  %xmm0,%xmm0
ucomisd -0x50(%rbp),%xmm0
jbe    1663 <uniroot+0x553>
xorps  %xmm0,%xmm0
ucomisd -0x58(%rbp),%xmm0
jbe    1663 <uniroot+0x553>
movsd  -0x30(%rbp),%xmm0
movsd  %xmm0,-0x40(%rbp)
movsd  -0x48(%rbp),%xmm0
movsd  %xmm0,-0x58(%rbp)
jmp    11d3 <uniroot+0xc3>

x86 assembly (clang, -O2):
<uniroot>:
push   %r14
push   %rbx
sub    $0x78,%rsp
mov    %rsi,%r14
movsd  %xmm2,0x8(%rsp)
mov    %rdi,%rbx
movapd %xmm1,0x40(%rsp)
movsd  %xmm0,0x10(%rsp)
mov    %rsi,%rdi
call   *%rbx
movaps %xmm0,0x20(%rsp)
movapd 0x40(%rsp),%xmm0
mov    %r14,%rdi
call   *%rbx
movapd 0x20(%rsp),%xmm12
movapd %xmm0,%xmm6
xorpd  %xmm0,%xmm0
ucomisd %xmm0,%xmm12
jbe    1160 <uniroot+0x50>
ucomisd %xmm0,%xmm6
ja     1171 <uniroot+0x61>
ucomisd %xmm12,%xmm0
jbe    1190 <uniroot+0x80>
xorpd  %xmm0,%xmm0
ucomisd %xmm6,%xmm0
jbe    1190 <uniroot+0x80>
lea    0xee8(%rip),%rdi
movapd %xmm6,0x30(%rsp)
call   1030 <puts@plt>
movapd 0x30(%rsp),%xmm6
movapd 0x20(%rsp),%xmm12
movsd  0x8(%rsp),%xmm0
mulsd  0xe62(%rip),%xmm0
movsd  %xmm0,0x8(%rsp)
unpcklpd %xmm12,%xmm12
movapd 0xe7f(%rip),%xmm5
xorpd  %xmm13,%xmm13
movapd 0xe71(%rip),%xmm8
movsd  0x10(%rsp),%xmm9
movapd %xmm9,%xmm4
jmp    11e2 <uniroot+0xd2>
nopl   (%rax)
unpcklpd %xmm0,%xmm0
movapd %xmm1,%xmm9
movapd %xmm1,%xmm4
movapd %xmm0,%xmm12
movapd %xmm12,%xmm15
unpckhpd %xmm12,%xmm15
movapd %xmm15,%xmm0
andpd  %xmm5,%xmm0
movapd %xmm6,%xmm1
andpd  %xmm5,%xmm1
ucomisd %xmm0,%xmm1
movapd 0x40(%rsp),%xmm10
jbe    1220 <uniroot+0x110>
unpcklpd %xmm6,%xmm6
movapd %xmm10,%xmm7
movapd %xmm10,%xmm14
movapd %xmm6,%xmm12
jmp    1234 <uniroot+0x124>
nop
movapd %xmm6,%xmm15
movapd %xmm9,%xmm7
movapd %xmm10,%xmm9
movapd %xmm4,%xmm14
movapd %xmm9,%xmm0
andpd  %xmm5,%xmm0
mulsd  0xdc3(%rip),%xmm0
addsd  0x8(%rsp),%xmm0
movapd %xmm7,%xmm3
subsd  %xmm9,%xmm3
movapd %xmm3,%xmm1
mulsd  0xda0(%rip),%xmm1
movapd %xmm1,%xmm2
andpd  %xmm5,%xmm2
ucomisd %xmm2,%xmm0
jae    14e8 <uniroot+0x3d8>
ucomisd %xmm13,%xmm15
jne    127f <uniroot+0x16f>
jnp    14e8 <uniroot+0x3d8>
subsd  %xmm4,%xmm10
movapd %xmm10,%xmm4
andpd  %xmm8,%xmm4
ucomisd %xmm0,%xmm4
movapd %xmm12,%xmm4
unpckhpd %xmm12,%xmm4
movapd %xmm9,0x10(%rsp)
movsd  %xmm7,0x58(%rsp)
movapd %xmm4,0x30(%rsp)
jb     1430 <uniroot+0x320>
movapd %xmm12,%xmm4
andpd  %xmm5,%xmm4
movapd %xmm15,%xmm6
andpd  %xmm5,%xmm6
ucomisd %xmm6,%xmm4
jbe    1430 <uniroot+0x320>
ucomisd %xmm7,%xmm14
movapd 0xd72(%rip),%xmm4
jne    1303 <uniroot+0x1f3>
jp     1303 <uniroot+0x1f3>
movapd %xmm15,%xmm6
divsd  %xmm12,%xmm6
movsd  0xd23(%rip),%xmm11
subsd  %xmm6,%xmm11
mulsd  %xmm3,%xmm6
jmp    139d <uniroot+0x28d>
movapd %xmm12,%xmm11
divsd  0x30(%rsp),%xmm11
movapd %xmm15,%xmm4
unpcklpd %xmm15,%xmm4
divpd  %xmm12,%xmm4
movapd %xmm8,%xmm7
movapd %xmm11,%xmm8
mulsd  %xmm3,%xmm8
movapd %xmm4,%xmm9
unpckhpd %xmm4,%xmm9
movapd %xmm11,%xmm6
subsd  %xmm9,%xmm6
mulsd  %xmm8,%xmm6
movapd 0x10(%rsp),%xmm5
subsd  %xmm14,%xmm5
movapd %xmm4,%xmm8
addpd  0xce1(%rip),%xmm8
movapd %xmm8,%xmm9
unpckhpd %xmm8,%xmm9
mulsd  %xmm9,%xmm5
subsd  %xmm5,%xmm6
mulsd  %xmm4,%xmm6
movapd 0xcd2(%rip),%xmm4
addsd  0xc89(%rip),%xmm11
mulsd  %xmm9,%xmm11
movapd 0x10(%rsp),%xmm9
mulsd  %xmm8,%xmm11
movapd %xmm7,%xmm8
movapd %xmm8,%xmm7
ucomisd %xmm13,%xmm6
jbe    13ae <uniroot+0x29e>
xorpd  %xmm4,%xmm11
movapd %xmm6,%xmm8
xorpd  %xmm4,%xmm8
xorpd  %xmm5,%xmm5
cmpltsd %xmm6,%xmm5
movapd %xmm5,%xmm4
andnpd %xmm8,%xmm4
andpd  %xmm6,%xmm5
orpd   %xmm4,%xmm5
mulsd  0xc46(%rip),%xmm3
movapd %xmm0,%xmm4
mulsd  %xmm11,%xmm4
andpd  %xmm7,%xmm4
mulsd  0xc39(%rip),%xmm4
mulsd  %xmm11,%xmm3
addsd  %xmm4,%xmm3
ucomisd %xmm5,%xmm3
jbe    1430 <uniroot+0x320>
movapd %xmm7,%xmm6
mulsd  %xmm11,%xmm10
mulsd  0xbf0(%rip),%xmm10
andpd  %xmm7,%xmm10
ucomisd %xmm5,%xmm10
jbe    1430 <uniroot+0x320>
divsd  %xmm11,%xmm5
movapd %xmm5,%xmm2
andpd  %xmm6,%xmm2
movapd %xmm5,%xmm1
nopl   (%rax)
ucomisd %xmm2,%xmm0
movapd %xmm12,0x20(%rsp)
movapd %xmm15,0x60(%rsp)
jbe    1457 <uniroot+0x347>
ucomisd %xmm13,%xmm1
ja     1453 <uniroot+0x343>
xorpd  0xbfd(%rip),%xmm0
movapd %xmm0,%xmm1
movapd %xmm1,%xmm0
addsd  %xmm9,%xmm0
movapd %xmm0,0x40(%rsp)
mov    %r14,%rdi
call   *%rbx
movapd 0x10(%rsp),%xmm1
movapd %xmm0,%xmm6
xorpd  %xmm13,%xmm13
ucomisd %xmm13,%xmm0
movapd 0x20(%rsp),%xmm12
movapd 0xba2(%rip),%xmm5
movapd 0xb99(%rip),%xmm8
movapd 0x60(%rsp),%xmm0
movsd  0x58(%rsp),%xmm2
movapd 0x30(%rsp),%xmm3
jbe    14b6 <uniroot+0x3a6>
ucomisd %xmm13,%xmm3
ja     11d0 <uniroot+0xc0>
ucomisd %xmm6,%xmm13
movsd  %xmm0,%xmm12
movapd %xmm2,%xmm9
movapd %xmm1,%xmm4
jbe    11e2 <uniroot+0xd2>
ucomisd %xmm3,%xmm13
movapd %xmm2,%xmm9
movapd %xmm1,%xmm4
ja     11d0 <uniroot+0xc0>
jmp    11e2 <uniroot+0xd2>
movapd %xmm9,%xmm0
add    $0x78,%rsp
pop    %rbx
pop    %r14
ret

LLVM IR (-O0):
@.str = [8 x i8] c"mooep!\0A\00"
define double @uniroot(double %0, double %1, double (double, i8*)* %2, double %3, i8* %4) {
%6 = alloca double
%7 = alloca double
%8 = alloca double (double, i8*)*
%9 = alloca double
%10 = alloca i8*
%11 = alloca double
%12 = alloca double
%13 = alloca double
%14 = alloca double
%15 = alloca double
%16 = alloca double
%17 = alloca double
%18 = alloca double
%19 = alloca double
%20 = alloca double
%21 = alloca double
%22 = alloca double
%23 = alloca double
%24 = alloca double
store double %0, double* %6
store double %1, double* %7
store double (double, i8*)* %2, double (double, i8*)** %8
store double %3, double* %9
store i8* %4, i8** %10
%25 = load double, double* %6
store double %25, double* %11
%26 = load double, double* %7
store double %26, double* %12
%27 = load double (double, i8*)*, double (double, i8*)** %8
%28 = load double, double* %11
%29 = load i8*, i8** %10
%30 = call double %27(double %28, i8* %29)
store double %30, double* %14
%31 = load double (double, i8*)*, double (double, i8*)** %8
%32 = load double, double* %12
%33 = load i8*, i8** %10
%34 = call double %31(double %32, i8* %33)
store double %34, double* %15
%35 = load double, double* %11
store double %35, double* %13
%36 = load double, double* %14
store double %36, double* %16
%37 = load double, double* %14
%38 = fcmp ogt double %37, 0.000000e+00
br i1 %38, label %39, label %42
39: ; preds = %5
%40 = load double, double* %15
%41 = fcmp ogt double %40, 0.000000e+00
br i1 %41, label %48, label %42
42: ; preds = %39, %5
%43 = load double, double* %14
%44 = fcmp olt double %43, 0.000000e+00
br i1 %44, label %45, label %50
45: ; preds = %42
%46 = load double, double* %15
%47 = fcmp olt double %46, 0.000000e+00
br i1 %47, label %48, label %50
48: ; preds = %45, %39
%49 = call i32 @printf(i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str, i64 0, i64 0))
br label %50
50: ; preds = %48, %45, %42
br label %51
51: ; preds = %50, %220
%52 = load double, double* %12
%53 = load double, double* %11
%54 = fsub double %52, %53
store double %54, double* %17
%55 = load double, double* %16
%56 = call double @llvm.fabs.f64(double %55)
%57 = load double, double* %15
%58 = call double @llvm.fabs.f64(double %57)
%59 = fcmp olt double %56, %58
br i1 %59, label %60, label %67
60: ; preds = %51
%61 = load double, double* %12
store double %61, double* %11
%62 = load double, double* %13
store double %62, double* %12
%63 = load double, double* %11
store double %63, double* %13
%64 = load double, double* %15
store double %64, double* %14
%65 = load double, double* %16
store double %65, double* %15
%66 = load double, double* %14
store double %66, double* %16
br label %67
67: ; preds = %60, %51
%68 = load double, double* %12
%69 = call double @llvm.fabs.f64(double %68)
%70 = load double, double* %9
%71 = fdiv double %70, 2.000000e+00
%72 = call double @llvm.fmuladd.f64(double 0x3EC4000000237742, double %69, double %71)
store double %72, double* %18
%73 = load double, double* %13
%74 = load double, double* %12
%75 = fsub double %73, %74
%76 = fdiv double %75, 2.000000e+00
store double %76, double* %21
%77 = load double, double* %21
%78 = call double @llvm.fabs.f64(double %77)
%79 = load double, double* %18
%80 = fcmp ole double %78, %79
br i1 %80, label %84, label %81
81: ; preds = %67
%82 = load double, double* %15
%83 = fcmp oeq double %82, 0.000000e+00
br i1 %83, label %84, label %86
84: ; preds = %81, %67
%85 = load double, double* %12
ret double %85
86: ; preds = %81
%87 = load double, double* %17
%88 = call double @llvm.fabs.f64(double %87)
%89 = load double, double* %18
%90 = fcmp oge double %88, %89
br i1 %90, label %91, label %182
91: ; preds = %86
%92 = load double, double* %14
%93 = call double @llvm.fabs.f64(double %92)
%94 = load double, double* %15
%95 = call double @llvm.fabs.f64(double %94)
%96 = fcmp ogt double %93, %95
br i1 %96, label %97, label %182
97: ; preds = %91
%98 = load double, double* %13
%99 = load double, double* %12
%100 = fsub double %98, %99
store double %100, double* %22
%101 = load double, double* %11
%102 = load double, double* %13
%103 = fcmp oeq double %101, %102
br i1 %103, label %104, label %113
104: ; preds = %97
%105 = load double, double* %15
%106 = load double, double* %14
%107 = fdiv double %105, %106
store double %107, double* %23
%108 = load double, double* %22
%109 = load double, double* %23
%110 = fmul double %108, %109
store double %110, double* %19
%111 = load double, double* %23
%112 = fsub double 1.000000e+00, %111
store double %112, double* %20
br label %147
113: ; preds = %97
%114 = load double, double* %14
%115 = load double, double* %16
%116 = fdiv double %114, %115
store double %116, double* %20
%117 = load double, double* %15
%118 = load double, double* %16
%119 = fdiv double %117, %118
store double %119, double* %23
%120 = load double, double* %15
%121 = load double, double* %14
%122 = fdiv double %120, %121
store double %122, double* %24
%123 = load double, double* %24
%124 = load double, double* %22
%125 = load double, double* %20
%126 = fmul double %124, %125
%127 = load double, double* %20
%128 = load double, double* %23
%129 = fsub double %127, %128
%130 = load double, double* %12
%131 = load double, double* %11
%132 = fsub double %130, %131
%133 = load double, double* %23
%134 = fsub double %133, 1.000000e+00
%135 = fmul double %132, %134
%136 = fneg double %135
%137 = call double @llvm.fmuladd.f64(double %126, double %129, double %136)
%138 = fmul double %123, %137
store double %138, double* %19
%139 = load double, double* %20
%140 = fsub double %139, 1.000000e+00
%141 = load double, double* %23
%142 = fsub double %141, 1.000000e+00
%143 = fmul double %140, %142
%144 = load double, double* %24
%145 = fsub double %144, 1.000000e+00
%146 = fmul double %143, %145
store double %146, double* %20
br label %147
147: ; preds = %113, %104
%148 = load double, double* %19
%149 = fcmp ogt double %148, 0.000000e+00
br i1 %149, label %150, label %153
150: ; preds = %147
%151 = load double, double* %20
%152 = fneg double %151
store double %152, double* %20
br label %156
153: ; preds = %147
%154 = load double, double* %19
%155 = fneg double %154
store double %155, double* %19
br label %156
156: ; preds = %153, %150
%157 = load double, double* %19
%158 = load double, double* %22
%159 = fmul double 7.500000e-01, %158
%160 = load double, double* %20
%161 = load double, double* %18
%162 = load double, double* %20
%163 = fmul double %161, %162
%164 = call double @llvm.fabs.f64(double %163)
%165 = fdiv double %164, 2.000000e+00
%166 = fneg double %165
%167 = call double @llvm.fmuladd.f64(double %159, double %160, double %166)
%168 = fcmp olt double %157, %167
br i1 %168, label %169, label %181
169: ; preds = %156
%170 = load double, double* %19
%171 = load double, double* %17
%172 = load double, double* %20
%173 = fmul double %171, %172
%174 = fdiv double %173, 2.000000e+00
%175 = call double @llvm.fabs.f64(double %174)
%176 = fcmp olt double %170, %175
br i1 %176, label %177, label %181
177: ; preds = %169
%178 = load double, double* %19
%179 = load double, double* %20
%180 = fdiv double %178, %179
store double %180, double* %21
br label %181
181: ; preds = %177, %169, %156
br label %182
182: ; preds = %181, %91, %86
%183 = load double, double* %21
%184 = call double @llvm.fabs.f64(double %183)
%185 = load double, double* %18
%186 = fcmp olt double %184, %185
br i1 %186, label %187, label %196
187: ; preds = %182
%188 = load double, double* %21
%189 = fcmp ogt double %188, 0.000000e+00
br i1 %189, label %190, label %192
190: ; preds = %187
%191 = load double, double* %18
store double %191, double* %21
br label %195
192: ; preds = %187
%193 = load double, double* %18
%194 = fneg double %193
store double %194, double* %21
br label %195
195: ; preds = %192, %190
br label %196
196: ; preds = %195, %182
%197 = load double, double* %12
store double %197, double* %11
%198 = load double, double* %15
store double %198, double* %14
%199 = load double, double* %21
%200 = load double, double* %12
%201 = fadd double %200, %199
store double %201, double* %12
%202 = load double (double, i8*)*, double (double, i8*)** %8
%203 = load double, double* %12
%204 = load i8*, i8** %10
%205 = call double %202(double %203, i8* %204)
store double %205, double* %15
%206 = load double, double* %15
%207 = fcmp ogt double %206, 0.000000e+00
br i1 %207, label %208, label %211
208: ; preds = %196
%209 = load double, double* %16
%210 = fcmp ogt double %209, 0.000000e+00
br i1 %210, label %217, label %211
211: ; preds = %208, %196
%212 = load double, double* %15
%213 = fcmp olt double %212, 0.000000e+00
br i1 %213, label %214, label %220
214: ; preds = %211
%215 = load double, double* %16
%216 = fcmp olt double %215, 0.000000e+00
br i1 %216, label %217, label %220
217: ; preds = %214, %208
%218 = load double, double* %11
store double %218, double* %13
%219 = load double, double* %14
store double %219, double* %16
br label %220
220: ; preds = %217, %214, %211
br label %51
}

LLVM IR (-O2):
@str = [7 x i8] c"mooep!\00"
define double @uniroot(double %0, double %1, double (double, i8*)* nocapture %2, double %3, i8* %4) {
%6 = tail call double %2(double %0, i8* %4)
%7 = tail call double %2(double %1, i8* %4)
%8 = fcmp ogt double %6, 0.000000e+00
%9 = fcmp ogt double %7, 0.000000e+00
%10 = select i1 %8, i1 %9, i1 false
br i1 %10, label %15, label %11
11: ; preds = %5
%12 = fcmp olt double %6, 0.000000e+00
%13 = fcmp olt double %7, 0.000000e+00
%14 = select i1 %12, i1 %13, i1 false
br i1 %14, label %15, label %17
15: ; preds = %11, %5
%16 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([7 x i8], [7 x i8]* @str, i64 0, i64 0))
br label %17
17: ; preds = %15, %11
%18 = fmul double %3, 5.000000e-01
%19 = insertelement <2 x double> poison, double %6, i64 0
%20 = shufflevector <2 x double> %19, <2 x double> poison, <2 x i32> zeroinitializer
br label %21
21: ; preds = %131, %17
%22 = phi double [ %7, %17 ], [ %118, %131 ]
%23 = phi double [ %0, %17 ], [ %132, %131 ]
%24 = phi double [ %1, %17 ], [ %117, %131 ]
%25 = phi double [ %0, %17 ], [ %38, %131 ]
%26 = phi <2 x double> [ %20, %17 ], [ %133, %131 ]
%27 = fsub double %24, %25
%28 = extractelement <2 x double> %26, i64 1
%29 = tail call double @llvm.fabs.f64(double %28)
%30 = tail call double @llvm.fabs.f64(double %22)
%31 = fcmp olt double %29, %30
br i1 %31, label %32, label %35
32: ; preds = %21
%33 = insertelement <2 x double> poison, double %22, i64 0
%34 = shufflevector <2 x double> %33, <2 x double> poison, <2 x i32> zeroinitializer
br label %35
35: ; preds = %32, %21
%36 = phi double [ %28, %32 ], [ %22, %21 ]
%37 = phi double [ %24, %32 ], [ %23, %21 ]
%38 = phi double [ %23, %32 ], [ %24, %21 ]
%39 = phi double [ %24, %32 ], [ %25, %21 ]
%40 = phi <2 x double> [ %34, %32 ], [ %26, %21 ]
%41 = tail call double @llvm.fabs.f64(double %38)
%42 = tail call double @llvm.fmuladd.f64(double %41, double 0x3EC4000000237742, double %18)
%43 = fsub double %37, %38
%44 = fmul double %43, 5.000000e-01
%45 = tail call double @llvm.fabs.f64(double %44)
%46 = fcmp ole double %45, %42
%47 = fcmp oeq double %36, 0.000000e+00
%48 = select i1 %46, i1 true, i1 %47
br i1 %48, label %49, label %50
49: ; preds = %35
ret double %38
50: ; preds = %35
%51 = tail call double @llvm.fabs.f64(double %27)
%52 = fcmp ult double %51, %42
br i1 %52, label %107, label %53
53: ; preds = %50
%54 = extractelement <2 x double> %40, i64 0
%55 = tail call double @llvm.fabs.f64(double %54)
%56 = tail call double @llvm.fabs.f64(double %36)
%57 = fcmp ogt double %55, %56
br i1 %57, label %58, label %107
58: ; preds = %53
%59 = fcmp oeq double %39, %37
br i1 %59, label %60, label %64
60: ; preds = %58
%61 = fdiv double %36, %54
%62 = fmul double %61, %43
%63 = fsub double 1.000000e+00, %61
br label %85
64: ; preds = %58
%65 = extractelement <2 x double> %40, i64 1
%66 = fdiv double %54, %65
%67 = insertelement <2 x double> poison, double %36, i64 0
%68 = shufflevector <2 x double> %67, <2 x double> poison, <2 x i32> zeroinitializer
%69 = fdiv <2 x double> %68, %40
%70 = fmul double %66, %43
%71 = extractelement <2 x double> %69, i64 1
%72 = fsub double %66, %71
%73 = fsub double %38, %39
%74 = fneg double %73
%75 = fadd <2 x double> %69, <double -1.000000e+00, double -1.000000e+00>
%76 = extractelement <2 x double> %75, i64 1
%77 = fmul double %76, %74
%78 = tail call double @llvm.fmuladd.f64(double %70, double %72, double %77)
%79 = extractelement <2 x double> %69, i64 0
%80 = fmul double %79, %78
%81 = fadd double %66, -1.000000e+00
%82 = fmul double %76, %81
%83 = extractelement <2 x double> %75, i64 0
%84 = fmul double %83, %82
br label %85
85: ; preds = %64, %60
%86 = phi double [ %62, %60 ], [ %80, %64 ]
%87 = phi double [ %63, %60 ], [ %84, %64 ]
%88 = fcmp ogt double %86, 0.000000e+00
%89 = fneg double %87
%90 = fneg double %86
%91 = select i1 %88, double %86, double %90
%92 = select i1 %88, double %89, double %87
%93 = fmul double %43, 7.500000e-01
%94 = fmul double %42, %92
%95 = tail call double @llvm.fabs.f64(double %94)
%96 = fmul double %95, -5.000000e-01
%97 = tail call double @llvm.fmuladd.f64(double %93, double %92, double %96)
%98 = fcmp olt double %91, %97
br i1 %98, label %99, label %107
99: ; preds = %85
%100 = fmul double %27, %92
%101 = fmul double %100, 5.000000e-01
%102 = tail call double @llvm.fabs.f64(double %101)
%103 = fcmp olt double %91, %102
br i1 %103, label %104, label %107
104: ; preds = %99
%105 = fdiv double %91, %92
%106 = tail call double @llvm.fabs.f64(double %105)
br label %107
107: ; preds = %85, %99, %104, %53, %50
%108 = phi double [ %45, %85 ], [ %45, %99 ], [ %106, %104 ], [ %45, %53 ], [ %45, %50 ]
%109 = phi double [ %44, %85 ], [ %44, %99 ], [ %105, %104 ], [ %44, %53 ], [ %44, %50 ]
%110 = fcmp olt double %108, %42
br i1 %110, label %111, label %115
111: ; preds = %107
%112 = fcmp ogt double %109, 0.000000e+00
br i1 %112, label %115, label %113
113: ; preds = %111
%114 = fneg double %42
br label %115
115: ; preds = %111, %113, %107
%116 = phi double [ %114, %113 ], [ %109, %107 ], [ %42, %111 ]
%117 = fadd double %38, %116
%118 = tail call double %2(double %117, i8* %4)
%119 = fcmp ogt double %118, 0.000000e+00
%120 = extractelement <2 x double> %40, i64 1
%121 = fcmp ogt double %120, 0.000000e+00
%122 = select i1 %119, i1 %121, i1 false
br i1 %122, label %128, label %123
123: ; preds = %115
%124 = fcmp olt double %118, 0.000000e+00
%125 = fcmp olt double %120, 0.000000e+00
%126 = select i1 %124, i1 %125, i1 false
%127 = insertelement <2 x double> %40, double %36, i64 0
br i1 %126, label %128, label %131
128: ; preds = %123, %115
%129 = insertelement <2 x double> poison, double %36, i64 0
%130 = shufflevector <2 x double> %129, <2 x double> poison, <2 x i32> zeroinitializer
br label %131
131: ; preds = %128, %123
%132 = phi double [ %38, %128 ], [ %37, %123 ]
%133 = phi <2 x double> [ %130, %128 ], [ %127, %123 ]
br label %21
}