#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 scalar_t__ clock_t;

/* Variables and functions */
scalar_t__ CLOCKS_PER_SEC;
int M_PI;
scalar_t__ RAND_MAX;
scalar_t__ clock();
int /*<<< orphan*/ csp4d_close(double **);
double csp4d_eval(double *, double **, int *, double *, double **, int *);
double **csp4d_open(double **, int *, double *);
int /*<<< orphan*/ fprintf(int /*<<< orphan*/, char *, double, int);
int /*<<< orphan*/ free(double *);
scalar_t__ malloc(int);
int /*<<< orphan*/ printf(char *, ...);
int rand();
double sin(double);
int sqrt(double);
int /*<<< orphan*/ stderr;
int testmain4d(void) {
  double *f;
  int nx, ny, nz, nt, nf;
  int i, j, k, l;
  double xx, yy, zz, tt;
  double *x, *y, *z, *t;
  double r;
  double **splines;
  int interval[4];
  double *xv[4];
  int nv[4];
  double p[4];
  nx = 12;
  ny = 12;
  nz = 12;
  nt = 12;
  x = (double *)malloc(nx * sizeof(double));
  y = (double *)malloc(ny * sizeof(double));
  z = (double *)malloc(nz * sizeof(double));
  t = (double *)malloc(nt * sizeof(double));
  xv[0] = x;
  xv[1] = y;
  xv[2] = z;
  xv[3] = t;
  x[0] = 0.;
  y[0] = 0.;
  z[0] = 0.;
  t[0] = 0.;
  x[1] = 0.1;
  y[1] = 0.1;
  z[1] = 0.1;
  t[1] = 0.1;
  for (i = 2; i < nx; i++) {
    x[i] = i - 1.;
    y[i] = i - 1.;
    z[i] = i - 1.;
    t[i] = i - 1.;
  }
  nf = nx * ny * nz * nt;
  nv[0] = nx;
  nv[1] = ny;
  nv[2] = nz;
  nv[3] = nt;
  f = (double *)malloc(nf * sizeof(double));
  nf = 0;
  for (i = 0; i < nx; i++) {
    for (j = 0; j < ny; j++) {
      for (k = 0; k < nz; k++) {
        for (l = 0; l < nt; l++) {
          r = M_PI *
              sqrt(x[i] * x[i] + y[j] * y[j] + z[k] * z[k] + t[l] * t[l]) / 2.;
          yy = (r != 0.) ? sin(r) / r : 1.;
          int m = ((i * ny + j) * nz + k) * nt + l;
          if (m != nf) {
            printf("Mismatch\n");
            return 1;
          }
          f[m] = yy;
          nf++;
        }
      }
    }
  }
  splines = csp4d_open(xv, nv, f);
  for (i = 0; i < 4; i++)
    interval[i] = 0;
  clock_t tm = clock();
  for (i = 0; i < 10000; i++) {
    double e, spl;
    double ex[4];
    if (i == 0) {
      ex[0] = 1.;
      ex[1] = 0.;
      ex[2] = 0.;
      ex[3] = 0.;
    } else if (i == 1) {
      ex[0] = 1.;
      ex[1] = 1.;
      ex[2] = 1.;
      ex[3] = 1.;
    } else {
      for (j = 0; j < 4; j++) {
        ex[j] = rand() / (double)RAND_MAX;
      }
      ex[rand() % 4] = 1.;
    }
    for (j = 0; j < 201; j++) {
      xx = j * ex[0] / 20.;
      yy = j * ex[1] / 20.;
      zz = j * ex[2] / 20.;
      tt = j * ex[3] / 20.;
      p[0] = xx;
      p[1] = yy;
      p[2] = zz;
      p[3] = tt;
      spl = csp4d_eval(p, xv, nv, f, splines, interval);
      r = M_PI * sqrt(xx * xx + yy * yy + zz * zz + tt * tt) / 2.;
      e = (r != 0.) ? sin(r) / r : 1.;
      printf("%8.5f %9.6f %9.6f\n", r, spl, e);
    }
  }
  tm = clock() - tm;
  double elapsed = (double)tm / (double)CLOCKS_PER_SEC;
  fprintf(stderr, "10000 points in %.2f seconds = %.2f points per second\n",
          elapsed, 10000. / elapsed);
  free(f);
  csp4d_close(splines);
  return 0;
}


x86 assembly (clang, -O0):
<testmain4d>:
push   %rbp
mov    %rsp,%rbp
sub    $0x160,%rsp
movl   $0xc,-0x14(%rbp)
movl   $0xc,-0x18(%rbp)
movl   $0xc,-0x1c(%rbp)
movl   $0xc,-0x20(%rbp)
movslq -0x14(%rbp),%rax
shl    $0x3,%rax
mov    %eax,%edi
call   10a0 <malloc@plt>
mov    %rax,-0x60(%rbp)
movslq -0x18(%rbp),%rax
shl    $0x3,%rax
mov    %eax,%edi
call   10a0 <malloc@plt>
mov    %rax,-0x68(%rbp)
movslq -0x1c(%rbp),%rax
shl    $0x3,%rax
mov    %eax,%edi
call   10a0 <malloc@plt>
mov    %rax,-0x70(%rbp)
movslq -0x20(%rbp),%rax
shl    $0x3,%rax
mov    %eax,%edi
call   10a0 <malloc@plt>
mov    %rax,-0x78(%rbp)
mov    -0x60(%rbp),%rax
mov    %rax,-0xc0(%rbp)
mov    -0x68(%rbp),%rax
mov    %rax,-0xb8(%rbp)
mov    -0x70(%rbp),%rax
mov    %rax,-0xb0(%rbp)
mov    -0x78(%rbp),%rax
mov    %rax,-0xa8(%rbp)
mov    -0x60(%rbp),%rax
xorps  %xmm0,%xmm0
movsd  %xmm0,(%rax)
mov    -0x68(%rbp),%rax
xorps  %xmm0,%xmm0
movsd  %xmm0,(%rax)
mov    -0x70(%rbp),%rax
xorps  %xmm0,%xmm0
movsd  %xmm0,(%rax)
mov    -0x78(%rbp),%rax
xorps  %xmm0,%xmm0
movsd  %xmm0,(%rax)
mov    -0x60(%rbp),%rax
movsd  0xd79(%rip),%xmm0
movsd  %xmm0,0x8(%rax)
mov    -0x68(%rbp),%rax
movsd  0xd68(%rip),%xmm0
movsd  %xmm0,0x8(%rax)
mov    -0x70(%rbp),%rax
movsd  0xd57(%rip),%xmm0
movsd  %xmm0,0x8(%rax)
mov    -0x78(%rbp),%rax
movsd  0xd46(%rip),%xmm0
movsd  %xmm0,0x8(%rax)
movl   $0x2,-0x28(%rbp)
mov    -0x28(%rbp),%eax
cmp    -0x14(%rbp),%eax
jge    1358 <testmain4d+0x1a8>
cvtsi2sdl -0x28(%rbp),%xmm0
movsd  0xd31(%rip),%xmm1
subsd  %xmm1,%xmm0
mov    -0x60(%rbp),%rax
movslq -0x28(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
cvtsi2sdl -0x28(%rbp),%xmm0
movsd  0xd13(%rip),%xmm1
subsd  %xmm1,%xmm0
mov    -0x68(%rbp),%rax
movslq -0x28(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
cvtsi2sdl -0x28(%rbp),%xmm0
movsd  0xcf5(%rip),%xmm1
subsd  %xmm1,%xmm0
mov    -0x70(%rbp),%rax
movslq -0x28(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
cvtsi2sdl -0x28(%rbp),%xmm0
movsd  0xcd7(%rip),%xmm1
subsd  %xmm1,%xmm0
mov    -0x78(%rbp),%rax
movslq -0x28(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x28(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x28(%rbp)
jmp    12c6 <testmain4d+0x116>
mov    -0x14(%rbp),%eax
imul   -0x18(%rbp),%eax
imul   -0x1c(%rbp),%eax
imul   -0x20(%rbp),%eax
mov    %eax,-0x24(%rbp)
mov    -0x14(%rbp),%eax
mov    %eax,-0xd0(%rbp)
mov    -0x18(%rbp),%eax
mov    %eax,-0xcc(%rbp)
mov    -0x1c(%rbp),%eax
mov    %eax,-0xc8(%rbp)
mov    -0x20(%rbp),%eax
mov    %eax,-0xc4(%rbp)
movslq -0x24(%rbp),%rax
shl    $0x3,%rax
mov    %eax,%edi
call   10a0 <malloc@plt>
mov    %rax,-0x10(%rbp)
movl   $0x0,-0x24(%rbp)
movl   $0x0,-0x28(%rbp)
mov    -0x28(%rbp),%eax
cmp    -0x14(%rbp),%eax
jge    15af <testmain4d+0x3ff>
movl   $0x0,-0x2c(%rbp)
mov    -0x2c(%rbp),%eax
cmp    -0x18(%rbp),%eax
jge    159c <testmain4d+0x3ec>
movl   $0x0,-0x30(%rbp)
mov    -0x30(%rbp),%eax
cmp    -0x1c(%rbp),%eax
jge    1589 <testmain4d+0x3d9>
movl   $0x0,-0x34(%rbp)
mov    -0x34(%rbp),%eax
cmp    -0x20(%rbp),%eax
jge    1576 <testmain4d+0x3c6>
mov    0x2bed(%rip),%rax
mov    (%rax),%eax
mov    %eax,-0x13c(%rbp)
mov    -0x60(%rbp),%rax
movslq -0x28(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x60(%rbp),%rax
movslq -0x28(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm2
mov    -0x68(%rbp),%rax
movslq -0x2c(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm1
mov    -0x68(%rbp),%rax
movslq -0x2c(%rbp),%rcx
mulsd  (%rax,%rcx,8),%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
mov    -0x70(%rbp),%rax
movslq -0x30(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm1
mov    -0x70(%rbp),%rax
movslq -0x30(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm2
mulsd  %xmm2,%xmm1
addsd  %xmm0,%xmm1
mov    -0x78(%rbp),%rax
movslq -0x34(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x78(%rbp),%rax
movslq -0x34(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
call   10c0 <sqrt@plt>
mov    %eax,%ecx
mov    -0x13c(%rbp),%eax
imul   %ecx,%eax
cvtsi2sd %eax,%xmm0
movsd  0xb79(%rip),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x80(%rbp)
movsd  -0x80(%rbp),%xmm0
xorps  %xmm1,%xmm1
ucomisd %xmm1,%xmm0
jne    14c5 <testmain4d+0x315>
jp     14c5 <testmain4d+0x315>
jmp    14e1 <testmain4d+0x331>
movsd  -0x80(%rbp),%xmm0
call   1080 <sin@plt>
divsd  -0x80(%rbp),%xmm0
movsd  %xmm0,-0x148(%rbp)
ff
jmp    14f6 <testmain4d+0x346>
movsd  0xb27(%rip),%xmm0
movsd  %xmm0,-0x148(%rbp)
ff
jmp    14f6 <testmain4d+0x346>
movsd  -0x148(%rbp),%xmm0
ff
movsd  %xmm0,-0x48(%rbp)
mov    -0x28(%rbp),%eax
imul   -0x18(%rbp),%eax
add    -0x2c(%rbp),%eax
imul   -0x1c(%rbp),%eax
add    -0x30(%rbp),%eax
imul   -0x20(%rbp),%eax
add    -0x34(%rbp),%eax
mov    %eax,-0xf4(%rbp)
mov    -0xf4(%rbp),%eax
cmp    -0x24(%rbp),%eax
je     154a <testmain4d+0x39a>
lea    0xaf1(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
movl   $0x1,-0x4(%rbp)
jmp    19a8 <testmain4d+0x7f8>
movsd  -0x48(%rbp),%xmm0
mov    -0x10(%rbp),%rax
movslq -0xf4(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x24(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x24(%rbp)
mov    -0x34(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x34(%rbp)
jmp    13e8 <testmain4d+0x238>
jmp    157b <testmain4d+0x3cb>
mov    -0x30(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x30(%rbp)
jmp    13d5 <testmain4d+0x225>
jmp    158e <testmain4d+0x3de>
mov    -0x2c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x2c(%rbp)
jmp    13c2 <testmain4d+0x212>
jmp    15a1 <testmain4d+0x3f1>
mov    -0x28(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x28(%rbp)
jmp    13af <testmain4d+0x1ff>
lea    -0xc0(%rbp),%rdi
lea    -0xd0(%rbp),%rsi
mov    -0x10(%rbp),%rdx
call   10b0 <csp4d_open@plt>
mov    %rax,-0x88(%rbp)
movl   $0x0,-0x28(%rbp)
cmpl   $0x4,-0x28(%rbp)
jge    15fb <testmain4d+0x44b>
movslq -0x28(%rbp),%rax
movl   $0x0,-0xa0(%rbp,%rax,4)
mov    -0x28(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x28(%rbp)
jmp    15d4 <testmain4d+0x424>
mov    $0x0,%al
call   1050 <clock@plt>
mov    %rax,-0x100(%rbp)
movl   $0x0,-0x28(%rbp)
cmpl   $0x2710,-0x28(%rbp)
jge    1925 <testmain4d+0x775>
cmpl   $0x0,-0x28(%rbp)
jne    165d <testmain4d+0x4ad>
movsd  0x9e1(%rip),%xmm0
movsd  %xmm0,-0x130(%rbp)
ff
xorps  %xmm0,%xmm0
movsd  %xmm0,-0x128(%rbp)
ff
xorps  %xmm0,%xmm0
movsd  %xmm0,-0x120(%rbp)
ff
xorps  %xmm0,%xmm0
movsd  %xmm0,-0x118(%rbp)
ff
jmp    171b <testmain4d+0x56b>
cmpl   $0x1,-0x28(%rbp)
jne    16ac <testmain4d+0x4fc>
movsd  0x9a1(%rip),%xmm0
movsd  %xmm0,-0x130(%rbp)
ff
movsd  0x991(%rip),%xmm0
movsd  %xmm0,-0x128(%rbp)
ff
movsd  0x981(%rip),%xmm0
movsd  %xmm0,-0x120(%rbp)
ff
movsd  0x971(%rip),%xmm0
movsd  %xmm0,-0x118(%rbp)
ff
jmp    1716 <testmain4d+0x566>
movl   $0x0,-0x2c(%rbp)
cmpl   $0x4,-0x2c(%rbp)
jge    16f3 <testmain4d+0x543>
mov    $0x0,%al
call   10d0 <rand@plt>
cvtsi2sd %eax,%xmm0
mov    0x2909(%rip),%rax
cvtsi2sdq (%rax),%xmm1
divsd  %xmm1,%xmm0
movslq -0x2c(%rbp),%rax
movsd  %xmm0,-0x130(%rbp,%rax,8)
ff ff
mov    -0x2c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x2c(%rbp)
jmp    16b3 <testmain4d+0x503>
mov    $0x0,%al
call   10d0 <rand@plt>
mov    $0x4,%ecx
cltd
idiv   %ecx
movslq %edx,%rax
movsd  0x903(%rip),%xmm0
movsd  %xmm0,-0x130(%rbp,%rax,8)
ff ff
jmp    171b <testmain4d+0x56b>
movl   $0x0,-0x2c(%rbp)
cmpl   $0xc9,-0x2c(%rbp)
jge    1912 <testmain4d+0x762>
cvtsi2sdl -0x2c(%rbp),%xmm0
mulsd  -0x130(%rbp),%xmm0
ff
movsd  0x8dc(%rip),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x40(%rbp)
cvtsi2sdl -0x2c(%rbp),%xmm0
mulsd  -0x128(%rbp),%xmm0
ff
movsd  0x8be(%rip),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x48(%rbp)
cvtsi2sdl -0x2c(%rbp),%xmm0
mulsd  -0x120(%rbp),%xmm0
ff
movsd  0x8a0(%rip),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x50(%rbp)
cvtsi2sdl -0x2c(%rbp),%xmm0
mulsd  -0x118(%rbp),%xmm0
ff
movsd  0x882(%rip),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x58(%rbp)
movsd  -0x40(%rbp),%xmm0
movsd  %xmm0,-0xf0(%rbp)
ff
movsd  -0x48(%rbp),%xmm0
movsd  %xmm0,-0xe8(%rbp)
ff
movsd  -0x50(%rbp),%xmm0
movsd  %xmm0,-0xe0(%rbp)
ff
movsd  -0x58(%rbp),%xmm0
movsd  %xmm0,-0xd8(%rbp)
ff
lea    -0xf0(%rbp),%rdi
lea    -0xc0(%rbp),%rsi
lea    -0xd0(%rbp),%rdx
mov    -0x10(%rbp),%rcx
mov    -0x88(%rbp),%r8
lea    -0xa0(%rbp),%r9
call   1040 <csp4d_eval@plt>
movsd  %xmm0,-0x110(%rbp)
ff
mov    0x27d2(%rip),%rax
mov    (%rax),%eax
mov    %eax,-0x14c(%rbp)
movsd  -0x40(%rbp),%xmm0
movsd  -0x40(%rbp),%xmm2
movsd  -0x48(%rbp),%xmm1
mulsd  -0x48(%rbp),%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  -0x50(%rbp),%xmm1
movsd  -0x50(%rbp),%xmm2
mulsd  %xmm2,%xmm1
addsd  %xmm0,%xmm1
movsd  -0x58(%rbp),%xmm0
movsd  -0x58(%rbp),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
call   10c0 <sqrt@plt>
mov    %eax,%ecx
mov    -0x14c(%rbp),%eax
imul   %ecx,%eax
cvtsi2sd %eax,%xmm0
movsd  0x79e(%rip),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x80(%rbp)
movsd  -0x80(%rbp),%xmm0
xorps  %xmm1,%xmm1
ucomisd %xmm1,%xmm0
jne    18a0 <testmain4d+0x6f0>
jp     18a0 <testmain4d+0x6f0>
jmp    18bc <testmain4d+0x70c>
movsd  -0x80(%rbp),%xmm0
call   1080 <sin@plt>
divsd  -0x80(%rbp),%xmm0
movsd  %xmm0,-0x158(%rbp)
ff
jmp    18d1 <testmain4d+0x721>
movsd  0x74c(%rip),%xmm0
movsd  %xmm0,-0x158(%rbp)
ff
jmp    18d1 <testmain4d+0x721>
movsd  -0x158(%rbp),%xmm0
ff
movsd  %xmm0,-0x108(%rbp)
ff
movsd  -0x80(%rbp),%xmm0
movsd  -0x110(%rbp),%xmm1
ff
movsd  -0x108(%rbp),%xmm2
ff
lea    0x735(%rip),%rdi
mov    $0x3,%al
call   1060 <printf@plt>
mov    -0x2c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x2c(%rbp)
jmp    1722 <testmain4d+0x572>
jmp    1917 <testmain4d+0x767>
mov    -0x28(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x28(%rbp)
jmp    1610 <testmain4d+0x460>
mov    $0x0,%al
call   1050 <clock@plt>
sub    -0x100(%rbp),%rax
mov    %rax,-0x100(%rbp)
cvtsi2sdq -0x100(%rbp),%xmm0
ff ff
mov    0x2696(%rip),%rax
cvtsi2sdq (%rax),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x138(%rbp)
ff
mov    0x2666(%rip),%rax
mov    (%rax),%edi
movsd  -0x138(%rbp),%xmm0
ff
movsd  0x694(%rip),%xmm1
divsd  -0x138(%rbp),%xmm1
ff
cvttsd2si %xmm1,%edx
lea    0x6be(%rip),%rsi
call   1070 <fprintf@plt>
mov    -0x10(%rbp),%rdi
call   1030 <free@plt>
mov    -0x88(%rbp),%rdi
call   1090 <csp4d_close@plt>
movl   $0x0,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x160,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<testmain4d>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x128,%rsp
mov    $0x60,%edi
call   10b0 <malloc@plt>
mov    %rax,%r14
mov    $0x60,%edi
call   10b0 <malloc@plt>
mov    %rax,%rbp
mov    $0x60,%edi
call   10b0 <malloc@plt>
mov    %rax,%rbx
mov    $0x60,%edi
call   10b0 <malloc@plt>
mov    %rax,%rcx
mov    %r14,0xd0(%rsp)
mov    %rbp,0xd8(%rsp)
mov    %rbx,0xe0(%rsp)
mov    %rax,0xe8(%rsp)
movq   $0x0,(%r14)
movq   $0x0,0x0(%rbp)
movq   $0x0,(%rbx)
movq   $0x0,(%rax)
movabs $0x3fb999999999999a,%rax
99 b9 3f
mov    %rax,0x8(%r14)
mov    %rax,0x8(%rbp)
mov    %rax,0x8(%rbx)
mov    %rax,0x8(%rcx)
movabs $0x3ff0000000000000,%rax
mov    %rax,0x10(%r14)
mov    %rax,0x10(%rbp)
mov    %rax,0x10(%rbx)
mov    %rax,0x10(%rcx)
movabs $0x4000000000000000,%rax
mov    %rax,0x18(%r14)
mov    %rax,0x18(%rbp)
mov    %rax,0x18(%rbx)
mov    %rax,0x18(%rcx)
movabs $0x4008000000000000,%rax
mov    %rax,0x20(%r14)
mov    %rax,0x20(%rbp)
mov    %rax,0x20(%rbx)
mov    %rax,0x20(%rcx)
movabs $0x4010000000000000,%rax
mov    %rax,0x28(%r14)
mov    %rax,0x28(%rbp)
mov    %rax,0x28(%rbx)
mov    %rax,0x28(%rcx)
movabs $0x4014000000000000,%rax
mov    %rax,0x30(%r14)
mov    %rax,0x30(%rbp)
mov    %rax,0x30(%rbx)
mov    %rax,0x30(%rcx)
movabs $0x4018000000000000,%rax
mov    %rax,0x38(%r14)
mov    %rax,0x38(%rbp)
mov    %rax,0x38(%rbx)
mov    %rax,0x38(%rcx)
movabs $0x401c000000000000,%rax
mov    %rax,0x40(%r14)
mov    %rax,0x40(%rbp)
mov    %rax,0x40(%rbx)
mov    %rax,0x40(%rcx)
movabs $0x4020000000000000,%rax
mov    %rax,0x48(%r14)
mov    %rax,0x48(%rbp)
mov    %rax,0x48(%rbx)
mov    %rax,0x48(%rcx)
movabs $0x4022000000000000,%rax
mov    %rax,0x50(%r14)
mov    %rax,0x50(%rbp)
mov    %rax,0x50(%rbx)
mov    %rax,0x50(%rcx)
movabs $0x4024000000000000,%rax
mov    %r14,0x40(%rsp)
mov    %rax,0x58(%r14)
mov    %rbp,0x90(%rsp)
mov    %rax,0x58(%rbp)
mov    %rbx,0x60(%rsp)
mov    %rax,0x58(%rbx)
mov    %rcx,0x50(%rsp)
mov    %rax,0x58(%rcx)
movapd 0xc81(%rip),%xmm0
movapd %xmm0,0xc0(%rsp)
mov    $0x28800,%edi
call   10b0 <malloc@plt>
mov    %rax,%r14
xor    %r13d,%r13d
mov    %rax,0x28(%rsp)
xor    %edx,%edx
mov    %rdx,0x8(%rsp)
mov    %r13,0xb0(%rsp)
mov    %r14,0xa8(%rsp)
xor    %r15d,%r15d
mov    %r13,0x30(%rsp)
mov    %r14,0xb8(%rsp)
xor    %r12d,%r12d
mov    %r13,0x38(%rsp)
xor    %ebx,%ebx
xchg   %ax,%ax
mov    0x2c11(%rip),%rax
mov    (%rax),%ebp
mov    0x40(%rsp),%rax
mov    0x8(%rsp),%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    0x90(%rsp),%rax
movsd  (%rax,%r15,8),%xmm1
mulsd  %xmm1,%xmm1
mulsd  %xmm0,%xmm0
addsd  %xmm1,%xmm0
mov    0x60(%rsp),%rax
movsd  (%rax,%r12,8),%xmm1
mulsd  %xmm1,%xmm1
addsd  %xmm0,%xmm1
mov    0x50(%rsp),%rax
movsd  (%rax,%rbx,1),%xmm0
mulsd  %xmm0,%xmm0
addsd  %xmm1,%xmm0
call   10d0 <sqrt@plt>
imul   %ebp,%eax
xorps  %xmm1,%xmm1
cvtsi2sd %eax,%xmm1
mulsd  0xc02(%rip),%xmm1
ucomisd 0xc12(%rip),%xmm1
movsd  0xbfa(%rip),%xmm0
jne    1452 <testmain4d+0x292>
jnp    1467 <testmain4d+0x2a7>
movapd %xmm1,%xmm0
movsd  %xmm1,0x10(%rsp)
call   1090 <sin@plt>
divsd  0x10(%rsp),%xmm0
mov    %r13,%rax
shr    $0x20,%rax
jne    155a <testmain4d+0x39a>
movsd  %xmm0,(%r14,%rbx,1)
add    $0x8,%rbx
add    $0x1,%r13
cmp    $0x60,%rbx
jne    13d0 <testmain4d+0x210>
add    $0x1,%r12
add    $0x60,%r14
mov    0x38(%rsp),%r13
add    $0xc,%r13
cmp    $0xc,%r12
jne    13c7 <testmain4d+0x207>
add    $0x1,%r15
mov    0xb8(%rsp),%r14
add    $0x480,%r14
mov    0x30(%rsp),%r13
add    $0x90,%r13
cmp    $0xc,%r15
jne    13b7 <testmain4d+0x1f7>
mov    0x8(%rsp),%rsi
add    $0x1,%rsi
mov    0xa8(%rsp),%r14
add    $0x3600,%r14
mov    0xb0(%rsp),%r13
add    $0x6c0,%r13
mov    %rsi,%rdx
mov    %rsi,0x8(%rsp)
cmp    $0xc,%rsi
jne    13a4 <testmain4d+0x1e4>
lea    0xd0(%rsp),%rdi
lea    0xc0(%rsp),%rsi
mov    0x28(%rsp),%rdx
call   10c0 <csp4d_open@plt>
mov    %rax,%r14
xorpd  %xmm0,%xmm0
movapd %xmm0,0xf0(%rsp)
xor    %eax,%eax
call   1060 <clock@plt>
mov    %rax,0x30(%rsp)
lea    0x100(%rsp),%r15
lea    0xf0(%rsp),%r13
lea    0xb0a(%rip),%r12
xor    %eax,%eax
jmp    1591 <testmain4d+0x3d1>
lea    0xb49(%rip),%rdi
call   1040 <puts@plt>
mov    $0x1,%ebx
mov    %ebx,%eax
add    $0x128,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret
mov    0x38(%rsp),%eax
add    $0x1,%eax
cmp    $0x2710,%eax
je     181b <testmain4d+0x65b>
test   %eax,%eax
mov    %eax,0x38(%rsp)
je     15bc <testmain4d+0x3fc>
cmp    $0x1,%eax
jne    15fc <testmain4d+0x43c>
movaps 0xa6b(%rip),%xmm0
movaps %xmm0,0x70(%rsp)
movaps %xmm0,0x80(%rsp)
movaps %xmm0,0x60(%rsp)
jmp    16d1 <testmain4d+0x511>
movabs $0x3ff0000000000000,%rax
mov    %rax,0x70(%rsp)
xorpd  %xmm0,%xmm0
lea    0x78(%rsp),%rax
movupd %xmm0,(%rax)
movq   $0x0,0x10(%rax)
xorpd  %xmm0,%xmm0
movapd %xmm0,0x50(%rsp)
movsd  0xa56(%rip),%xmm0
movaps %xmm0,0x60(%rsp)
jmp    16d6 <testmain4d+0x516>
xor    %eax,%eax
call   10e0 <rand@plt>
mov    %eax,%ebp
mov    0x29cc(%rip),%rbx
xorps  %xmm0,%xmm0
cvtsi2sdq (%rbx),%xmm0
movapd %xmm0,0x10(%rsp)
xor    %eax,%eax
call   10e0 <rand@plt>
movd   %ebp,%xmm0
movd   %eax,%xmm1
punpckldq %xmm1,%xmm0
cvtdq2pd %xmm0,%xmm0
xorps  %xmm1,%xmm1
cvtsi2sdq (%rbx),%xmm1
movapd 0x10(%rsp),%xmm2
unpcklpd %xmm1,%xmm2
divpd  %xmm2,%xmm0
movapd %xmm0,0x70(%rsp)
xor    %eax,%eax
call   10e0 <rand@plt>
mov    %eax,%ebp
xorps  %xmm0,%xmm0
cvtsi2sdq (%rbx),%xmm0
movapd %xmm0,0x10(%rsp)
xor    %eax,%eax
call   10e0 <rand@plt>
movd   %ebp,%xmm0
movd   %eax,%xmm1
punpckldq %xmm1,%xmm0
cvtdq2pd %xmm0,%xmm0
xorps  %xmm1,%xmm1
cvtsi2sdq (%rbx),%xmm1
movapd 0x10(%rsp),%xmm2
unpcklpd %xmm1,%xmm2
divpd  %xmm2,%xmm0
movapd %xmm0,0x80(%rsp)
xor    %eax,%eax
call   10e0 <rand@plt>
lea    0x3(%rax),%ecx
test   %eax,%eax
cmovns %eax,%ecx
and    $0xfffffffc,%ecx
sub    %ecx,%eax
cltq
movabs $0x3ff0000000000000,%rcx
mov    %rcx,0x70(%rsp,%rax,8)
movaps 0x70(%rsp),%xmm0
movaps %xmm0,0x60(%rsp)
movaps 0x80(%rsp),%xmm0
movaps %xmm0,0x50(%rsp)
xorpd  %xmm1,%xmm1
mov    $0xc9,%ebp
jmp    170c <testmain4d+0x54c>
mov    %r12,%rdi
movsd  0x8(%rsp),%xmm1
mov    $0x3,%al
call   1070 <printf@plt>
movsd  0x94f(%rip),%xmm0
movapd 0x10(%rsp),%xmm1
addsd  %xmm0,%xmm1
add    $0xffffffff,%ebp
je     157f <testmain4d+0x3bf>
movapd %xmm1,0x10(%rsp)
unpcklpd %xmm1,%xmm1
movapd 0x60(%rsp),%xmm2
mulpd  %xmm1,%xmm2
movapd 0x8f8(%rip),%xmm0
divpd  %xmm0,%xmm2
movapd %xmm2,0x90(%rsp)
mulpd  0x50(%rsp),%xmm1
divpd  %xmm0,%xmm1
movapd %xmm1,0x40(%rsp)
movapd %xmm2,0x100(%rsp)
movapd %xmm1,0x110(%rsp)
mov    %r15,%rdi
lea    0xd0(%rsp),%rsi
lea    0xc0(%rsp),%rdx
mov    0x28(%rsp),%rcx
mov    %r14,%r8
mov    %r13,%r9
call   1050 <csp4d_eval@plt>
movsd  %xmm0,0x8(%rsp)
mov    0x2861(%rip),%rax
mov    (%rax),%ebx
movapd 0x90(%rsp),%xmm1
movapd %xmm1,%xmm0
mulpd  %xmm1,%xmm0
unpckhpd %xmm0,%xmm0
mulsd  %xmm1,%xmm1
addsd  %xmm0,%xmm1
movapd 0x40(%rsp),%xmm2
movapd %xmm2,%xmm0
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
unpckhpd %xmm2,%xmm2
mulsd  %xmm2,%xmm2
addsd  %xmm0,%xmm2
movapd %xmm2,%xmm0
call   10d0 <sqrt@plt>
imul   %ebx,%eax
xorps  %xmm0,%xmm0
cvtsi2sd %eax,%xmm0
mulsd  0x861(%rip),%xmm0
ucomisd 0x871(%rip),%xmm0
movsd  0x859(%rip),%xmm2
jne    17f7 <testmain4d+0x637>
jnp    16e1 <testmain4d+0x521>
movsd  %xmm0,0x40(%rsp)
movsd  0x40(%rsp),%xmm0
call   1090 <sin@plt>
movapd %xmm0,%xmm2
movsd  0x40(%rsp),%xmm0
divsd  %xmm0,%xmm2
jmp    16e1 <testmain4d+0x521>
xor    %ebx,%ebx
xor    %eax,%eax
call   1060 <clock@plt>
sub    0x30(%rsp),%rax
xorps  %xmm0,%xmm0
cvtsi2sd %rax,%xmm0
mov    0x27a8(%rip),%rax
xorps  %xmm1,%xmm1
cvtsi2sdq (%rax),%xmm1
divsd  %xmm1,%xmm0
mov    0x277d(%rip),%rax
mov    (%rax),%edi
movsd  0x7fb(%rip),%xmm1
divsd  %xmm0,%xmm1
cvttsd2si %xmm1,%edx
lea    0x80f(%rip),%rsi
call   1080 <fprintf@plt>
mov    0x28(%rsp),%rdi
call   1030 <free@plt>
mov    %r14,%rdi
call   10a0 <csp4d_close@plt>
jmp    156b <testmain4d+0x3ab>

LLVM IR (-O0):
@M_PI = global i32 0
@.str = [10 x i8] c"Mismatch\0A\00"
@RAND_MAX = global i64 0
@.str.1 = [19 x i8] c"%8.5f %9.6f %9.6f\0A\00"
@CLOCKS_PER_SEC = global i64 0
@stderr = global i32 0
@.str.2 = [55 x i8] c"10000 points in %.2f seconds = %.2f points per second\0A\00"
define i32 @testmain4d() {
%1 = alloca i32
%2 = alloca double*
%3 = alloca i32
%4 = alloca i32
%5 = alloca i32
%6 = alloca i32
%7 = alloca i32
%8 = alloca i32
%9 = alloca i32
%10 = alloca i32
%11 = alloca i32
%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 [4 x i32]
%23 = alloca [4 x double*]
%24 = alloca [4 x i32]
%25 = alloca [4 x double]
%26 = alloca i32
%27 = alloca i64
%28 = alloca double
%29 = alloca double
%30 = alloca [4 x double]
%31 = alloca double
store i32 12, i32* %3
store i32 12, i32* %4
store i32 12, i32* %5
store i32 12, i32* %6
%32 = load i32, i32* %3
%33 = sext i32 %32 to i64
%34 = mul i64 %33, 8
%35 = trunc i64 %34 to i32
%36 = call i64 @malloc(i32 %35)
%37 = inttoptr i64 %36 to double*
store double* %37, double** %16
%38 = load i32, i32* %4
%39 = sext i32 %38 to i64
%40 = mul i64 %39, 8
%41 = trunc i64 %40 to i32
%42 = call i64 @malloc(i32 %41)
%43 = inttoptr i64 %42 to double*
store double* %43, double** %17
%44 = load i32, i32* %5
%45 = sext i32 %44 to i64
%46 = mul i64 %45, 8
%47 = trunc i64 %46 to i32
%48 = call i64 @malloc(i32 %47)
%49 = inttoptr i64 %48 to double*
store double* %49, double** %18
%50 = load i32, i32* %6
%51 = sext i32 %50 to i64
%52 = mul i64 %51, 8
%53 = trunc i64 %52 to i32
%54 = call i64 @malloc(i32 %53)
%55 = inttoptr i64 %54 to double*
store double* %55, double** %19
%56 = load double*, double** %16
%57 = getelementptr inbounds [4 x double*], [4 x double*]* %23, i64 0, i64 0
store double* %56, double** %57
%58 = load double*, double** %17
%59 = getelementptr inbounds [4 x double*], [4 x double*]* %23, i64 0, i64 1
store double* %58, double** %59
%60 = load double*, double** %18
%61 = getelementptr inbounds [4 x double*], [4 x double*]* %23, i64 0, i64 2
store double* %60, double** %61
%62 = load double*, double** %19
%63 = getelementptr inbounds [4 x double*], [4 x double*]* %23, i64 0, i64 3
store double* %62, double** %63
%64 = load double*, double** %16
%65 = getelementptr inbounds double, double* %64, i64 0
store double 0.000000e+00, double* %65
%66 = load double*, double** %17
%67 = getelementptr inbounds double, double* %66, i64 0
store double 0.000000e+00, double* %67
%68 = load double*, double** %18
%69 = getelementptr inbounds double, double* %68, i64 0
store double 0.000000e+00, double* %69
%70 = load double*, double** %19
%71 = getelementptr inbounds double, double* %70, i64 0
store double 0.000000e+00, double* %71
%72 = load double*, double** %16
%73 = getelementptr inbounds double, double* %72, i64 1
store double 1.000000e-01, double* %73
%74 = load double*, double** %17
%75 = getelementptr inbounds double, double* %74, i64 1
store double 1.000000e-01, double* %75
%76 = load double*, double** %18
%77 = getelementptr inbounds double, double* %76, i64 1
store double 1.000000e-01, double* %77
%78 = load double*, double** %19
%79 = getelementptr inbounds double, double* %78, i64 1
store double 1.000000e-01, double* %79
store i32 2, i32* %8
br label %80
80: ; preds = %113, %0
%81 = load i32, i32* %8
%82 = load i32, i32* %3
%83 = icmp slt i32 %81, %82
br i1 %83, label %84, label %116
84: ; preds = %80
%85 = load i32, i32* %8
%86 = sitofp i32 %85 to double
%87 = fsub double %86, 1.000000e+00
%88 = load double*, double** %16
%89 = load i32, i32* %8
%90 = sext i32 %89 to i64
%91 = getelementptr inbounds double, double* %88, i64 %90
store double %87, double* %91
%92 = load i32, i32* %8
%93 = sitofp i32 %92 to double
%94 = fsub double %93, 1.000000e+00
%95 = load double*, double** %17
%96 = load i32, i32* %8
%97 = sext i32 %96 to i64
%98 = getelementptr inbounds double, double* %95, i64 %97
store double %94, double* %98
%99 = load i32, i32* %8
%100 = sitofp i32 %99 to double
%101 = fsub double %100, 1.000000e+00
%102 = load double*, double** %18
%103 = load i32, i32* %8
%104 = sext i32 %103 to i64
%105 = getelementptr inbounds double, double* %102, i64 %104
store double %101, double* %105
%106 = load i32, i32* %8
%107 = sitofp i32 %106 to double
%108 = fsub double %107, 1.000000e+00
%109 = load double*, double** %19
%110 = load i32, i32* %8
%111 = sext i32 %110 to i64
%112 = getelementptr inbounds double, double* %109, i64 %111
store double %108, double* %112
br label %113
113: ; preds = %84
%114 = load i32, i32* %8
%115 = add nsw i32 %114, 1
store i32 %115, i32* %8
br label %80
116: ; preds = %80
%117 = load i32, i32* %3
%118 = load i32, i32* %4
%119 = mul nsw i32 %117, %118
%120 = load i32, i32* %5
%121 = mul nsw i32 %119, %120
%122 = load i32, i32* %6
%123 = mul nsw i32 %121, %122
store i32 %123, i32* %7
%124 = load i32, i32* %3
%125 = getelementptr inbounds [4 x i32], [4 x i32]* %24, i64 0, i64 0
store i32 %124, i32* %125
%126 = load i32, i32* %4
%127 = getelementptr inbounds [4 x i32], [4 x i32]* %24, i64 0, i64 1
store i32 %126, i32* %127
%128 = load i32, i32* %5
%129 = getelementptr inbounds [4 x i32], [4 x i32]* %24, i64 0, i64 2
store i32 %128, i32* %129
%130 = load i32, i32* %6
%131 = getelementptr inbounds [4 x i32], [4 x i32]* %24, i64 0, i64 3
store i32 %130, i32* %131
%132 = load i32, i32* %7
%133 = sext i32 %132 to i64
%134 = mul i64 %133, 8
%135 = trunc i64 %134 to i32
%136 = call i64 @malloc(i32 %135)
%137 = inttoptr i64 %136 to double*
store double* %137, double** %2
store i32 0, i32* %7
store i32 0, i32* %8
br label %138
138: ; preds = %255, %116
%139 = load i32, i32* %8
%140 = load i32, i32* %3
%141 = icmp slt i32 %139, %140
br i1 %141, label %142, label %258
142: ; preds = %138
store i32 0, i32* %9
br label %143
143: ; preds = %251, %142
%144 = load i32, i32* %9
%145 = load i32, i32* %4
%146 = icmp slt i32 %144, %145
br i1 %146, label %147, label %254
147: ; preds = %143
store i32 0, i32* %10
br label %148
148: ; preds = %247, %147
%149 = load i32, i32* %10
%150 = load i32, i32* %5
%151 = icmp slt i32 %149, %150
br i1 %151, label %152, label %250
152: ; preds = %148
store i32 0, i32* %11
br label %153
153: ; preds = %243, %152
%154 = load i32, i32* %11
%155 = load i32, i32* %6
%156 = icmp slt i32 %154, %155
br i1 %156, label %157, label %246
157: ; preds = %153
%158 = load i32, i32* @M_PI
%159 = load double*, double** %16
%160 = load i32, i32* %8
%161 = sext i32 %160 to i64
%162 = getelementptr inbounds double, double* %159, i64 %161
%163 = load double, double* %162
%164 = load double*, double** %16
%165 = load i32, i32* %8
%166 = sext i32 %165 to i64
%167 = getelementptr inbounds double, double* %164, i64 %166
%168 = load double, double* %167
%169 = load double*, double** %17
%170 = load i32, i32* %9
%171 = sext i32 %170 to i64
%172 = getelementptr inbounds double, double* %169, i64 %171
%173 = load double, double* %172
%174 = load double*, double** %17
%175 = load i32, i32* %9
%176 = sext i32 %175 to i64
%177 = getelementptr inbounds double, double* %174, i64 %176
%178 = load double, double* %177
%179 = fmul double %173, %178
%180 = call double @llvm.fmuladd.f64(double %163, double %168, double %179)
%181 = load double*, double** %18
%182 = load i32, i32* %10
%183 = sext i32 %182 to i64
%184 = getelementptr inbounds double, double* %181, i64 %183
%185 = load double, double* %184
%186 = load double*, double** %18
%187 = load i32, i32* %10
%188 = sext i32 %187 to i64
%189 = getelementptr inbounds double, double* %186, i64 %188
%190 = load double, double* %189
%191 = call double @llvm.fmuladd.f64(double %185, double %190, double %180)
%192 = load double*, double** %19
%193 = load i32, i32* %11
%194 = sext i32 %193 to i64
%195 = getelementptr inbounds double, double* %192, i64 %194
%196 = load double, double* %195
%197 = load double*, double** %19
%198 = load i32, i32* %11
%199 = sext i32 %198 to i64
%200 = getelementptr inbounds double, double* %197, i64 %199
%201 = load double, double* %200
%202 = call double @llvm.fmuladd.f64(double %196, double %201, double %191)
%203 = call i32 @sqrt(double %202)
%204 = mul nsw i32 %158, %203
%205 = sitofp i32 %204 to double
%206 = fdiv double %205, 2.000000e+00
store double %206, double* %20
%207 = load double, double* %20
%208 = fcmp une double %207, 0.000000e+00
br i1 %208, label %209, label %214
209: ; preds = %157
%210 = load double, double* %20
%211 = call double @sin(double %210)
%212 = load double, double* %20
%213 = fdiv double %211, %212
br label %215
214: ; preds = %157
br label %215
215: ; preds = %214, %209
%216 = phi double [ %213, %209 ], [ 1.000000e+00, %214 ]
store double %216, double* %13
%217 = load i32, i32* %8
%218 = load i32, i32* %4
%219 = mul nsw i32 %217, %218
%220 = load i32, i32* %9
%221 = add nsw i32 %219, %220
%222 = load i32, i32* %5
%223 = mul nsw i32 %221, %222
%224 = load i32, i32* %10
%225 = add nsw i32 %223, %224
%226 = load i32, i32* %6
%227 = mul nsw i32 %225, %226
%228 = load i32, i32* %11
%229 = add nsw i32 %227, %228
store i32 %229, i32* %26
%230 = load i32, i32* %26
%231 = load i32, i32* %7
%232 = icmp ne i32 %230, %231
br i1 %232, label %233, label %235
233: ; preds = %215
%234 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str, i64 0, i64 0))
store i32 1, i32* %1
br label %417
235: ; preds = %215
%236 = load double, double* %13
%237 = load double*, double** %2
%238 = load i32, i32* %26
%239 = sext i32 %238 to i64
%240 = getelementptr inbounds double, double* %237, i64 %239
store double %236, double* %240
%241 = load i32, i32* %7
%242 = add nsw i32 %241, 1
store i32 %242, i32* %7
br label %243
243: ; preds = %235
%244 = load i32, i32* %11
%245 = add nsw i32 %244, 1
store i32 %245, i32* %11
br label %153
246: ; preds = %153
br label %247
247: ; preds = %246
%248 = load i32, i32* %10
%249 = add nsw i32 %248, 1
store i32 %249, i32* %10
br label %148
250: ; preds = %148
br label %251
251: ; preds = %250
%252 = load i32, i32* %9
%253 = add nsw i32 %252, 1
store i32 %253, i32* %9
br label %143
254: ; preds = %143
br label %255
255: ; preds = %254
%256 = load i32, i32* %8
%257 = add nsw i32 %256, 1
store i32 %257, i32* %8
br label %138
258: ; preds = %138
%259 = getelementptr inbounds [4 x double*], [4 x double*]* %23, i64 0, i64 0
%260 = getelementptr inbounds [4 x i32], [4 x i32]* %24, i64 0, i64 0
%261 = load double*, double** %2
%262 = call double** @csp4d_open(double** %259, i32* %260, double* %261)
store double** %262, double*** %21
store i32 0, i32* %8
br label %263
263: ; preds = %270, %258
%264 = load i32, i32* %8
%265 = icmp slt i32 %264, 4
br i1 %265, label %266, label %273
266: ; preds = %263
%267 = load i32, i32* %8
%268 = sext i32 %267 to i64
%269 = getelementptr inbounds [4 x i32], [4 x i32]* %22, i64 0, i64 %268
store i32 0, i32* %269
br label %270
270: ; preds = %266
%271 = load i32, i32* %8
%272 = add nsw i32 %271, 1
store i32 %272, i32* %8
br label %263
273: ; preds = %263
%274 = call i64 (...) @clock()
store i64 %274, i64* %27
store i32 0, i32* %8
br label %275
275: ; preds = %395, %273
%276 = load i32, i32* %8
%277 = icmp slt i32 %276, 10000
br i1 %277, label %278, label %398
278: ; preds = %275
%279 = load i32, i32* %8
%280 = icmp eq i32 %279, 0
br i1 %280, label %281, label %286
281: ; preds = %278
%282 = getelementptr inbounds [4 x double], [4 x double]* %30, i64 0, i64 0
store double 1.000000e+00, double* %282
%283 = getelementptr inbounds [4 x double], [4 x double]* %30, i64 0, i64 1
store double 0.000000e+00, double* %283
%284 = getelementptr inbounds [4 x double], [4 x double]* %30, i64 0, i64 2
store double 0.000000e+00, double* %284
%285 = getelementptr inbounds [4 x double], [4 x double]* %30, i64 0, i64 3
store double 0.000000e+00, double* %285
br label %316
286: ; preds = %278
%287 = load i32, i32* %8
%288 = icmp eq i32 %287, 1
br i1 %288, label %289, label %294
289: ; preds = %286
%290 = getelementptr inbounds [4 x double], [4 x double]* %30, i64 0, i64 0
store double 1.000000e+00, double* %290
%291 = getelementptr inbounds [4 x double], [4 x double]* %30, i64 0, i64 1
store double 1.000000e+00, double* %291
%292 = getelementptr inbounds [4 x double], [4 x double]* %30, i64 0, i64 2
store double 1.000000e+00, double* %292
%293 = getelementptr inbounds [4 x double], [4 x double]* %30, i64 0, i64 3
store double 1.000000e+00, double* %293
br label %315
294: ; preds = %286
store i32 0, i32* %9
br label %295
295: ; preds = %307, %294
%296 = load i32, i32* %9
%297 = icmp slt i32 %296, 4
br i1 %297, label %298, label %310
298: ; preds = %295
%299 = call i32 (...) @rand()
%300 = sitofp i32 %299 to double
%301 = load i64, i64* @RAND_MAX
%302 = sitofp i64 %301 to double
%303 = fdiv double %300, %302
%304 = load i32, i32* %9
%305 = sext i32 %304 to i64
%306 = getelementptr inbounds [4 x double], [4 x double]* %30, i64 0, i64 %305
store double %303, double* %306
br label %307
307: ; preds = %298
%308 = load i32, i32* %9
%309 = add nsw i32 %308, 1
store i32 %309, i32* %9
br label %295
310: ; preds = %295
%311 = call i32 (...) @rand()
%312 = srem i32 %311, 4
%313 = sext i32 %312 to i64
%314 = getelementptr inbounds [4 x double], [4 x double]* %30, i64 0, i64 %313
store double 1.000000e+00, double* %314
br label %315
315: ; preds = %310, %289
br label %316
316: ; preds = %315, %281
store i32 0, i32* %9
br label %317
317: ; preds = %391, %316
%318 = load i32, i32* %9
%319 = icmp slt i32 %318, 201
br i1 %319, label %320, label %394
320: ; preds = %317
%321 = load i32, i32* %9
%322 = sitofp i32 %321 to double
%323 = getelementptr inbounds [4 x double], [4 x double]* %30, i64 0, i64 0
%324 = load double, double* %323
%325 = fmul double %322, %324
%326 = fdiv double %325, 2.000000e+01
store double %326, double* %12
%327 = load i32, i32* %9
%328 = sitofp i32 %327 to double
%329 = getelementptr inbounds [4 x double], [4 x double]* %30, i64 0, i64 1
%330 = load double, double* %329
%331 = fmul double %328, %330
%332 = fdiv double %331, 2.000000e+01
store double %332, double* %13
%333 = load i32, i32* %9
%334 = sitofp i32 %333 to double
%335 = getelementptr inbounds [4 x double], [4 x double]* %30, i64 0, i64 2
%336 = load double, double* %335
%337 = fmul double %334, %336
%338 = fdiv double %337, 2.000000e+01
store double %338, double* %14
%339 = load i32, i32* %9
%340 = sitofp i32 %339 to double
%341 = getelementptr inbounds [4 x double], [4 x double]* %30, i64 0, i64 3
%342 = load double, double* %341
%343 = fmul double %340, %342
%344 = fdiv double %343, 2.000000e+01
store double %344, double* %15
%345 = load double, double* %12
%346 = getelementptr inbounds [4 x double], [4 x double]* %25, i64 0, i64 0
store double %345, double* %346
%347 = load double, double* %13
%348 = getelementptr inbounds [4 x double], [4 x double]* %25, i64 0, i64 1
store double %347, double* %348
%349 = load double, double* %14
%350 = getelementptr inbounds [4 x double], [4 x double]* %25, i64 0, i64 2
store double %349, double* %350
%351 = load double, double* %15
%352 = getelementptr inbounds [4 x double], [4 x double]* %25, i64 0, i64 3
store double %351, double* %352
%353 = getelementptr inbounds [4 x double], [4 x double]* %25, i64 0, i64 0
%354 = getelementptr inbounds [4 x double*], [4 x double*]* %23, i64 0, i64 0
%355 = getelementptr inbounds [4 x i32], [4 x i32]* %24, i64 0, i64 0
%356 = load double*, double** %2
%357 = load double**, double*** %21
%358 = getelementptr inbounds [4 x i32], [4 x i32]* %22, i64 0, i64 0
%359 = call double @csp4d_eval(double* %353, double** %354, i32* %355, double* %356, double** %357, i32* %358)
store double %359, double* %29
%360 = load i32, i32* @M_PI
%361 = load double, double* %12
%362 = load double, double* %12
%363 = load double, double* %13
%364 = load double, double* %13
%365 = fmul double %363, %364
%366 = call double @llvm.fmuladd.f64(double %361, double %362, double %365)
%367 = load double, double* %14
%368 = load double, double* %14
%369 = call double @llvm.fmuladd.f64(double %367, double %368, double %366)
%370 = load double, double* %15
%371 = load double, double* %15
%372 = call double @llvm.fmuladd.f64(double %370, double %371, double %369)
%373 = call i32 @sqrt(double %372)
%374 = mul nsw i32 %360, %373
%375 = sitofp i32 %374 to double
%376 = fdiv double %375, 2.000000e+00
store double %376, double* %20
%377 = load double, double* %20
%378 = fcmp une double %377, 0.000000e+00
br i1 %378, label %379, label %384
379: ; preds = %320
%380 = load double, double* %20
%381 = call double @sin(double %380)
%382 = load double, double* %20
%383 = fdiv double %381, %382
br label %385
384: ; preds = %320
br label %385
385: ; preds = %384, %379
%386 = phi double [ %383, %379 ], [ 1.000000e+00, %384 ]
store double %386, double* %28
%387 = load double, double* %20
%388 = load double, double* %29
%389 = load double, double* %28
%390 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str.1, i64 0, i64 0), double %387, double %388, double %389)
br label %391
391: ; preds = %385
%392 = load i32, i32* %9
%393 = add nsw i32 %392, 1
store i32 %393, i32* %9
br label %317
394: ; preds = %317
br label %395
395: ; preds = %394
%396 = load i32, i32* %8
%397 = add nsw i32 %396, 1
store i32 %397, i32* %8
br label %275
398: ; preds = %275
%399 = call i64 (...) @clock()
%400 = load i64, i64* %27
%401 = sub nsw i64 %399, %400
store i64 %401, i64* %27
%402 = load i64, i64* %27
%403 = sitofp i64 %402 to double
%404 = load i64, i64* @CLOCKS_PER_SEC
%405 = sitofp i64 %404 to double
%406 = fdiv double %403, %405
store double %406, double* %31
%407 = load i32, i32* @stderr
%408 = load double, double* %31
%409 = load double, double* %31
%410 = fdiv double 1.000000e+04, %409
%411 = fptosi double %410 to i32
%412 = call i32 @fprintf(i32 %407, i8* getelementptr inbounds ([55 x i8], [55 x i8]* @.str.2, i64 0, i64 0), double %408, i32 %411)
%413 = load double*, double** %2
%414 = call i32 @free(double* %413)
%415 = load double**, double*** %21
%416 = call i32 @csp4d_close(double** %415)
store i32 0, i32* %1
br label %417
417: ; preds = %398, %233
%418 = load i32, i32* %1
ret i32 %418
}

LLVM IR (-O2):
@M_PI = global i32 0
@RAND_MAX = global i64 0
@.str.1 = [19 x i8] c"%8.5f %9.6f %9.6f\0A\00"
@CLOCKS_PER_SEC = global i64 0
@stderr = global i32 0
@.str.2 = [55 x i8] c"10000 points in %.2f seconds = %.2f points per second\0A\00"
@str = [9 x i8] c"Mismatch\00"
define i32 @testmain4d() {
%1 = alloca [4 x i32]
%2 = bitcast [4 x i32]* %1 to i8*
%3 = alloca [4 x double*]
%4 = alloca <4 x i32>
%5 = alloca [4 x double]
%6 = alloca [4 x double]
%7 = bitcast [4 x double*]* %3 to i8*
%8 = bitcast <4 x i32>* %4 to i8*
%9 = bitcast [4 x double]* %5 to i8*
%10 = tail call i64 @malloc(i32 96)
%11 = inttoptr i64 %10 to double*
%12 = tail call i64 @malloc(i32 96)
%13 = inttoptr i64 %12 to double*
%14 = tail call i64 @malloc(i32 96)
%15 = inttoptr i64 %14 to double*
%16 = tail call i64 @malloc(i32 96)
%17 = inttoptr i64 %16 to double*
%18 = getelementptr inbounds [4 x double*], [4 x double*]* %3, i64 0, i64 0
store double* %11, double** %18
%19 = getelementptr inbounds [4 x double*], [4 x double*]* %3, i64 0, i64 1
store double* %13, double** %19
%20 = getelementptr inbounds [4 x double*], [4 x double*]* %3, i64 0, i64 2
store double* %15, double** %20
%21 = getelementptr inbounds [4 x double*], [4 x double*]* %3, i64 0, i64 3
store double* %17, double** %21
store double 0.000000e+00, double* %11
store double 0.000000e+00, double* %13
store double 0.000000e+00, double* %15
store double 0.000000e+00, double* %17
%22 = getelementptr inbounds double, double* %11, i64 1
store double 1.000000e-01, double* %22
%23 = getelementptr inbounds double, double* %13, i64 1
store double 1.000000e-01, double* %23
%24 = getelementptr inbounds double, double* %15, i64 1
store double 1.000000e-01, double* %24
%25 = getelementptr inbounds double, double* %17, i64 1
store double 1.000000e-01, double* %25
%26 = getelementptr inbounds double, double* %11, i64 2
store double 1.000000e+00, double* %26
%27 = getelementptr inbounds double, double* %13, i64 2
store double 1.000000e+00, double* %27
%28 = getelementptr inbounds double, double* %15, i64 2
store double 1.000000e+00, double* %28
%29 = getelementptr inbounds double, double* %17, i64 2
store double 1.000000e+00, double* %29
%30 = getelementptr inbounds double, double* %11, i64 3
store double 2.000000e+00, double* %30
%31 = getelementptr inbounds double, double* %13, i64 3
store double 2.000000e+00, double* %31
%32 = getelementptr inbounds double, double* %15, i64 3
store double 2.000000e+00, double* %32
%33 = getelementptr inbounds double, double* %17, i64 3
store double 2.000000e+00, double* %33
%34 = getelementptr inbounds double, double* %11, i64 4
store double 3.000000e+00, double* %34
%35 = getelementptr inbounds double, double* %13, i64 4
store double 3.000000e+00, double* %35
%36 = getelementptr inbounds double, double* %15, i64 4
store double 3.000000e+00, double* %36
%37 = getelementptr inbounds double, double* %17, i64 4
store double 3.000000e+00, double* %37
%38 = getelementptr inbounds double, double* %11, i64 5
store double 4.000000e+00, double* %38
%39 = getelementptr inbounds double, double* %13, i64 5
store double 4.000000e+00, double* %39
%40 = getelementptr inbounds double, double* %15, i64 5
store double 4.000000e+00, double* %40
%41 = getelementptr inbounds double, double* %17, i64 5
store double 4.000000e+00, double* %41
%42 = getelementptr inbounds double, double* %11, i64 6
store double 5.000000e+00, double* %42
%43 = getelementptr inbounds double, double* %13, i64 6
store double 5.000000e+00, double* %43
%44 = getelementptr inbounds double, double* %15, i64 6
store double 5.000000e+00, double* %44
%45 = getelementptr inbounds double, double* %17, i64 6
store double 5.000000e+00, double* %45
%46 = getelementptr inbounds double, double* %11, i64 7
store double 6.000000e+00, double* %46
%47 = getelementptr inbounds double, double* %13, i64 7
store double 6.000000e+00, double* %47
%48 = getelementptr inbounds double, double* %15, i64 7
store double 6.000000e+00, double* %48
%49 = getelementptr inbounds double, double* %17, i64 7
store double 6.000000e+00, double* %49
%50 = getelementptr inbounds double, double* %11, i64 8
store double 7.000000e+00, double* %50
%51 = getelementptr inbounds double, double* %13, i64 8
store double 7.000000e+00, double* %51
%52 = getelementptr inbounds double, double* %15, i64 8
store double 7.000000e+00, double* %52
%53 = getelementptr inbounds double, double* %17, i64 8
store double 7.000000e+00, double* %53
%54 = getelementptr inbounds double, double* %11, i64 9
store double 8.000000e+00, double* %54
%55 = getelementptr inbounds double, double* %13, i64 9
store double 8.000000e+00, double* %55
%56 = getelementptr inbounds double, double* %15, i64 9
store double 8.000000e+00, double* %56
%57 = getelementptr inbounds double, double* %17, i64 9
store double 8.000000e+00, double* %57
%58 = getelementptr inbounds double, double* %11, i64 10
store double 9.000000e+00, double* %58
%59 = getelementptr inbounds double, double* %13, i64 10
store double 9.000000e+00, double* %59
%60 = getelementptr inbounds double, double* %15, i64 10
store double 9.000000e+00, double* %60
%61 = getelementptr inbounds double, double* %17, i64 10
store double 9.000000e+00, double* %61
%62 = getelementptr inbounds double, double* %11, i64 11
store double 1.000000e+01, double* %62
%63 = getelementptr inbounds double, double* %13, i64 11
store double 1.000000e+01, double* %63
%64 = getelementptr inbounds double, double* %15, i64 11
store double 1.000000e+01, double* %64
%65 = getelementptr inbounds double, double* %17, i64 11
store double 1.000000e+01, double* %65
%66 = getelementptr inbounds <4 x i32>, <4 x i32>* %4, i64 0, i64 0
store <4 x i32> <i32 12, i32 12, i32 12, i32 12>, <4 x i32>* %4
%67 = tail call i64 @malloc(i32 165888)
%68 = inttoptr i64 %67 to double*
br label %69
69: ; preds = %0, %128
%70 = phi i64 [ 0, %0 ], [ %129, %128 ]
%71 = phi i32 [ 0, %0 ], [ %74, %128 ]
%72 = getelementptr inbounds double, double* %11, i64 %70
%73 = mul nuw nsw i64 %70, 12
%74 = add nuw nsw i32 %71, 1728
br label %75
75: ; preds = %69, %125
%76 = phi i64 [ 0, %69 ], [ %126, %125 ]
%77 = phi i32 [ %71, %69 ], [ %81, %125 ]
%78 = getelementptr inbounds double, double* %13, i64 %76
%79 = add nuw nsw i64 %76, %73
%80 = mul nuw nsw i64 %79, 12
%81 = add i32 %77, 144
br label %82
82: ; preds = %75, %122
%83 = phi i64 [ 0, %75 ], [ %123, %122 ]
%84 = phi i32 [ %77, %75 ], [ %88, %122 ]
%85 = getelementptr inbounds double, double* %15, i64 %83
%86 = add nuw nsw i64 %83, %80
%87 = mul nuw nsw i64 %86, 12
%88 = add i32 %84, 12
br label %89
89: ; preds = %82, %117
%90 = phi i64 [ 0, %82 ], [ %120, %117 ]
%91 = phi i32 [ %84, %82 ], [ %119, %117 ]
%92 = load i32, i32* @M_PI
%93 = load double, double* %72
%94 = load double, double* %78
%95 = fmul double %94, %94
%96 = tail call double @llvm.fmuladd.f64(double %93, double %93, double %95)
%97 = load double, double* %85
%98 = tail call double @llvm.fmuladd.f64(double %97, double %97, double %96)
%99 = getelementptr inbounds double, double* %17, i64 %90
%100 = load double, double* %99
%101 = tail call double @llvm.fmuladd.f64(double %100, double %100, double %98)
%102 = tail call i32 @sqrt(double %101)
%103 = mul nsw i32 %102, %92
%104 = sitofp i32 %103 to double
%105 = fmul double %104, 5.000000e-01
%106 = fcmp une double %105, 0.000000e+00
br i1 %106, label %107, label %110
107: ; preds = %89
%108 = tail call double @sin(double %105)
%109 = fdiv double %108, %105
br label %110
110: ; preds = %89, %107
%111 = phi double [ %109, %107 ], [ 1.000000e+00, %89 ]
%112 = add nuw nsw i64 %90, %87
%113 = zext i32 %91 to i64
%114 = icmp eq i64 %112, %113
br i1 %114, label %117, label %115
115: ; preds = %110
%116 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([9 x i8], [9 x i8]* @str, i64 0, i64 0))
br label %234
117: ; preds = %110
%118 = getelementptr inbounds double, double* %68, i64 %112
store double %111, double* %118
%119 = add nsw i32 %91, 1
%120 = add nuw nsw i64 %90, 1
%121 = icmp eq i64 %120, 12
br i1 %121, label %122, label %89
122: ; preds = %117
%123 = add nuw nsw i64 %83, 1
%124 = icmp eq i64 %123, 12
br i1 %124, label %125, label %82
125: ; preds = %122
%126 = add nuw nsw i64 %76, 1
%127 = icmp eq i64 %126, 12
br i1 %127, label %128, label %75
128: ; preds = %125
%129 = add nuw nsw i64 %70, 1
%130 = icmp eq i64 %129, 12
br i1 %130, label %131, label %69
131: ; preds = %128
%132 = call double** @csp4d_open(double** %18, i32* %66, double* %68)
%133 = call i64 (...) @clock()
%134 = bitcast [4 x double]* %6 to i8*
%135 = getelementptr inbounds [4 x double], [4 x double]* %6, i64 0, i64 0
%136 = getelementptr inbounds [4 x double], [4 x double]* %6, i64 0, i64 1
%137 = getelementptr inbounds [4 x double], [4 x double]* %6, i64 0, i64 2
%138 = getelementptr inbounds [4 x double], [4 x double]* %5, i64 0, i64 0
%139 = getelementptr inbounds [4 x double], [4 x double]* %5, i64 0, i64 2
%140 = getelementptr inbounds [4 x i32], [4 x i32]* %1, i64 0, i64 0
%141 = bitcast double* %136 to i8*
%142 = bitcast [4 x double]* %6 to <2 x double>*
%143 = bitcast double* %137 to <2 x double>*
%144 = bitcast [4 x double]* %6 to <2 x double>*
%145 = bitcast double* %137 to <2 x double>*
%146 = bitcast [4 x double]* %6 to <2 x double>*
%147 = bitcast double* %137 to <2 x double>*
%148 = bitcast [4 x double]* %5 to <2 x double>*
%149 = bitcast double* %139 to <2 x double>*
br label %150
150: ; preds = %131, %218
%151 = phi i32 [ 0, %131 ], [ %219, %218 ]
switch i32 %151, label %152 [
i32 0, label %181
i32 1, label %182
]
152: ; preds = %150
%153 = call i32 (...) @rand()
%154 = load i64, i64* @RAND_MAX
%155 = call i32 (...) @rand()
%156 = insertelement <2 x i32> poison, i32 %153, i64 0
%157 = insertelement <2 x i32> %156, i32 %155, i64 1
%158 = sitofp <2 x i32> %157 to <2 x double>
%159 = load i64, i64* @RAND_MAX
%160 = insertelement <2 x i64> poison, i64 %154, i64 0
%161 = insertelement <2 x i64> %160, i64 %159, i64 1
%162 = sitofp <2 x i64> %161 to <2 x double>
%163 = fdiv <2 x double> %158, %162
store <2 x double> %163, <2 x double>* %144
%164 = call i32 (...) @rand()
%165 = load i64, i64* @RAND_MAX
%166 = call i32 (...) @rand()
%167 = insertelement <2 x i32> poison, i32 %164, i64 0
%168 = insertelement <2 x i32> %167, i32 %166, i64 1
%169 = sitofp <2 x i32> %168 to <2 x double>
%170 = load i64, i64* @RAND_MAX
%171 = insertelement <2 x i64> poison, i64 %165, i64 0
%172 = insertelement <2 x i64> %171, i64 %170, i64 1
%173 = sitofp <2 x i64> %172 to <2 x double>
%174 = fdiv <2 x double> %169, %173
store <2 x double> %174, <2 x double>* %145
%175 = call i32 (...) @rand()
%176 = srem i32 %175, 4
%177 = sext i32 %176 to i64
%178 = getelementptr inbounds [4 x double], [4 x double]* %6, i64 0, i64 %177
store double 1.000000e+00, double* %178
%179 = load <2 x double>, <2 x double>* %146
%180 = load <2 x double>, <2 x double>* %147
br label %183
181: ; preds = %150
store double 1.000000e+00, double* %135
br label %183
182: ; preds = %150
store <2 x double> <double 1.000000e+00, double 1.000000e+00>, <2 x double>* %142
store <2 x double> <double 1.000000e+00, double 1.000000e+00>, <2 x double>* %143
br label %183
183: ; preds = %182, %152, %181
%184 = phi <2 x double> [ <double 1.000000e+00, double 1.000000e+00>, %182 ], [ %179, %152 ], [ <double 1.000000e+00, double 0.000000e+00>, %181 ]
%185 = phi <2 x double> [ <double 1.000000e+00, double 1.000000e+00>, %182 ], [ %180, %152 ], [ zeroinitializer, %181 ]
br label %186
186: ; preds = %183, %213
%187 = phi i32 [ 0, %183 ], [ %216, %213 ]
%188 = sitofp i32 %187 to double
%189 = insertelement <2 x double> poison, double %188, i64 0
%190 = shufflevector <2 x double> %189, <2 x double> poison, <2 x i32> zeroinitializer
%191 = fmul <2 x double> %184, %190
%192 = fdiv <2 x double> %191, <double 2.000000e+01, double 2.000000e+01>
%193 = fmul <2 x double> %185, %190
%194 = fdiv <2 x double> %193, <double 2.000000e+01, double 2.000000e+01>
store <2 x double> %192, <2 x double>* %148
store <2 x double> %194, <2 x double>* %149
%195 = call double @csp4d_eval(double* %138, double** %18, i32* %66, double* %68, double** %132, i32* %140)
%196 = load i32, i32* @M_PI
%197 = fmul <2 x double> %192, %192
%198 = extractelement <2 x double> %197, i64 1
%199 = extractelement <2 x double> %192, i64 0
%200 = call double @llvm.fmuladd.f64(double %199, double %199, double %198)
%201 = extractelement <2 x double> %194, i64 0
%202 = call double @llvm.fmuladd.f64(double %201, double %201, double %200)
%203 = extractelement <2 x double> %194, i64 1
%204 = call double @llvm.fmuladd.f64(double %203, double %203, double %202)
%205 = call i32 @sqrt(double %204)
%206 = mul nsw i32 %205, %196
%207 = sitofp i32 %206 to double
%208 = fmul double %207, 5.000000e-01
%209 = fcmp une double %208, 0.000000e+00
br i1 %209, label %210, label %213
210: ; preds = %186
%211 = call double @sin(double %208)
%212 = fdiv double %211, %208
br label %213
213: ; preds = %186, %210
%214 = phi double [ %212, %210 ], [ 1.000000e+00, %186 ]
%215 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([19 x i8], [19 x i8]* @.str.1, i64 0, i64 0), double %208, double %195, double %214)
%216 = add nuw nsw i32 %187, 1
%217 = icmp eq i32 %216, 201
br i1 %217, label %218, label %186
218: ; preds = %213
%219 = add nuw nsw i32 %151, 1
%220 = icmp eq i32 %219, 10000
br i1 %220, label %221, label %150
221: ; preds = %218
%222 = call i64 (...) @clock()
%223 = sub nsw i64 %222, %133
%224 = sitofp i64 %223 to double
%225 = load i64, i64* @CLOCKS_PER_SEC
%226 = sitofp i64 %225 to double
%227 = fdiv double %224, %226
%228 = load i32, i32* @stderr
%229 = fdiv double 1.000000e+04, %227
%230 = fptosi double %229 to i32
%231 = call i32 @fprintf(i32 %228, i8* getelementptr inbounds ([55 x i8], [55 x i8]* @.str.2, i64 0, i64 0), double %227, i32 %230)
%232 = call i32 @free(double* %68)
%233 = call i32 @csp4d_close(double** %132)
br label %234
234: ; preds = %115, %221
%235 = phi i32 [ 1, %115 ], [ 0, %221 ]
ret i32 %235
}