#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*/ time_t;

/* Variables and functions */
long atol(char *);
int /*<<< orphan*/ exit(int);
int /*<<< orphan*/ fflush(int /*<<< orphan*/);
int /*<<< orphan*/ gethostname(char *, int);
int /*<<< orphan*/ localtime(int /*<<< orphan*/ *);
scalar_t__ malloc(size_t);
long omp_get_num_threads();
int /*<<< orphan*/ omp_set_dynamic(int /*<<< orphan*/);
int /*<<< orphan*/ omp_set_num_threads(long);
int /*<<< orphan*/ printf(char *, ...);
int /*<<< orphan*/ stdout;
int /*<<< orphan*/ strcmp(char *, char *);
int /*<<< orphan*/ strftime(char *, int, char *, int /*<<< orphan*/);
int /*<<< orphan*/ time(int /*<<< orphan*/ *);
double wtime();
int main(int argc, char *argv[]) {
  int flags = 0, sdone = 0;
  long it, nit = 128;
  long i, j, n = 1000000, dn = 1, nt = -1;
  double *a;
  double sum, t0, t1;
  time_t ts;
  char cbuf[4096];
  if (argc == 1) {
    printf("usage: %s [-scan dn | -scanx dn] [-bind]  vec_size num_threads "
           "[dobind]\n",
           argv[0]);
    exit(1);
  }
  i = 0;
  n = 0;
  gethostname(cbuf, 4096);
  printf("host         %s ", cbuf);
  time(&ts);
  strftime(cbuf, 4096, "%c", localtime(&ts));
  printf("    (%s)\n", cbuf);
  printf("cmd          \"");
  for (i = 0; i < argc; i++)
    printf("%s ", argv[i]);
  i = 0;
  printf("\"  ");
  while (--argc && argv++) {
    if (!strcmp("-v", *argv)) {
      flags |= (1 << 0);
      printf("VERBOSE ");
    } else if (!strcmp("-nit", *argv)) {
      --argc;
      argv++;
      nit = atol(*argv);
    } else if (!strcmp("-scan", *argv)) {
      flags |= (1 << 2);
      --argc;
      argv++;
      dn = atol(*argv);
      printf("SCAN ");
    } else if (!strcmp("-scanx", *argv)) {
      flags |= (1 << 3);
      --argc;
      argv++;
      dn = atol(*argv);
      printf("SCANX ");
    } else if (n == 0) {
      n = atol(*argv);
    } else if (n > 0) {
      nt = atol(*argv);
    }
  }
  printf("\n");
  sdone = 0;
  while (!sdone) {
    if (nt > 0) {
      omp_set_dynamic(0);
      omp_set_num_threads(nt);
    }
    a = (double *)malloc((size_t)n * sizeof(double));
    if (!a) {
      printf("malloc error %d\n", n);
      exit(1);
    }
    for (i = 0; i < n; i++) {
      a[i] = 1.0 * i;
    }
    sum = 0.0;
    t0 = wtime();
#pragma omp parallel shared(a, sum, nt) private(i)
    {
      nt = omp_get_num_threads();
      for (it = 0; it < nit; it++) {
#pragma omp master
        sum = 0.0;
#pragma omp barrier
#pragma omp for schedule(static) reduction(+ : sum)
        for (i = 0; i < n; i++) {
          sum += a[i] * a[i];
        }
      }
    }
    t1 = wtime();
    printf("%ld %ld %ld %.3e %.3e\n", nt, n, nit,
           sum - (2.0 * n * n * n - 3 * n * n + n) / 6.0, (t1 - t0) / nit);
    fflush(stdout);
    if (flags & (1 << 2)) {
      n += dn;
    } else if (flags & (1 << 3)) {
      n += n / dn + 1;
    } else {
      sdone = 1;
    }
  }
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x1090,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
movl   $0x0,-0x14(%rbp)
movl   $0x0,-0x18(%rbp)
movq   $0x80,-0x28(%rbp)
movq   $0xf4240,-0x40(%rbp)
movq   $0x1,-0x48(%rbp)
movq   $0xffffffffffffffff,-0x50(%rbp)
ff
cmpl   $0x1,-0x8(%rbp)
jne    1250 <main+0x70>
mov    -0x10(%rbp),%rax
mov    (%rax),%rsi
lea    0xdd9(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    $0x1,%edi
call   1100 <exit@plt>
movq   $0x0,-0x30(%rbp)
movq   $0x0,-0x40(%rbp)
lea    -0x1080(%rbp),%rdi
mov    $0x1000,%esi
call   10f0 <gethostname@plt>
lea    -0x1080(%rbp),%rsi
lea    0xde2(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
lea    -0x74(%rbp),%rdi
call   1090 <time@plt>
lea    -0x1080(%rbp),%rax
mov    %rax,-0x1088(%rbp)
lea    -0x74(%rbp),%rdi
call   1030 <localtime@plt>
mov    -0x1088(%rbp),%rdi
mov    %eax,%ecx
mov    $0x1000,%esi
lea    0xdb7(%rip),%rdx
call   10d0 <strftime@plt>
lea    -0x1080(%rbp),%rsi
lea    0xda7(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
lea    0xda3(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
movq   $0x0,-0x30(%rbp)
mov    -0x30(%rbp),%rax
movslq -0x8(%rbp),%rcx
cmp    %rcx,%rax
jge    1327 <main+0x147>
mov    -0x10(%rbp),%rax
mov    -0x30(%rbp),%rcx
mov    (%rax,%rcx,8),%rsi
lea    0xd5f(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    -0x30(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x30(%rbp)
jmp    12eb <main+0x10b>
movq   $0x0,-0x30(%rbp)
lea    0xd58(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    -0x8(%rbp),%ecx
add    $0xffffffff,%ecx
mov    %ecx,-0x8(%rbp)
xor    %eax,%eax
cmp    $0x0,%ecx
mov    %al,-0x1089(%rbp)
je     1373 <main+0x193>
mov    -0x10(%rbp),%rax
mov    %rax,%rcx
add    $0x8,%rcx
mov    %rcx,-0x10(%rbp)
cmp    $0x0,%rax
setne  %al
mov    %al,-0x1089(%rbp)
mov    -0x1089(%rbp),%al
test   $0x1,%al
jne    1386 <main+0x1a6>
jmp    1517 <main+0x337>
mov    -0x10(%rbp),%rax
mov    (%rax),%rsi
lea    0xcfe(%rip),%rdi
call   1080 <strcmp@plt>
cmp    $0x0,%eax
jne    13be <main+0x1de>
mov    -0x14(%rbp),%eax
or     $0x1,%eax
mov    %eax,-0x14(%rbp)
lea    0xce3(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
jmp    1512 <main+0x332>
mov    -0x10(%rbp),%rax
mov    (%rax),%rsi
lea    0xcd2(%rip),%rdi
call   1080 <strcmp@plt>
cmp    $0x0,%eax
jne    1404 <main+0x224>
mov    -0x8(%rbp),%eax
add    $0xffffffff,%eax
mov    %eax,-0x8(%rbp)
mov    -0x10(%rbp),%rax
add    $0x8,%rax
mov    %rax,-0x10(%rbp)
mov    -0x10(%rbp),%rax
mov    (%rax),%rdi
call   10e0 <atol@plt>
mov    %rax,-0x28(%rbp)
jmp    150d <main+0x32d>
mov    -0x10(%rbp),%rax
mov    (%rax),%rsi
lea    0xc91(%rip),%rdi
call   1080 <strcmp@plt>
cmp    $0x0,%eax
jne    1461 <main+0x281>
mov    -0x14(%rbp),%eax
or     $0x4,%eax
mov    %eax,-0x14(%rbp)
mov    -0x8(%rbp),%eax
add    $0xffffffff,%eax
mov    %eax,-0x8(%rbp)
mov    -0x10(%rbp),%rax
add    $0x8,%rax
mov    %rax,-0x10(%rbp)
mov    -0x10(%rbp),%rax
mov    (%rax),%rdi
call   10e0 <atol@plt>
mov    %rax,-0x48(%rbp)
lea    0xc54(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
jmp    1508 <main+0x328>
mov    -0x10(%rbp),%rax
mov    (%rax),%rsi
lea    0xc40(%rip),%rdi
call   1080 <strcmp@plt>
cmp    $0x0,%eax
jne    14be <main+0x2de>
mov    -0x14(%rbp),%eax
or     $0x8,%eax
mov    %eax,-0x14(%rbp)
mov    -0x8(%rbp),%eax
add    $0xffffffff,%eax
mov    %eax,-0x8(%rbp)
mov    -0x10(%rbp),%rax
add    $0x8,%rax
mov    %rax,-0x10(%rbp)
mov    -0x10(%rbp),%rax
mov    (%rax),%rdi
call   10e0 <atol@plt>
mov    %rax,-0x48(%rbp)
lea    0xc04(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
jmp    1503 <main+0x323>
cmpq   $0x0,-0x40(%rbp)
jne    14de <main+0x2fe>
mov    -0x10(%rbp),%rax
mov    (%rax),%rdi
call   10e0 <atol@plt>
mov    %rax,-0x40(%rbp)
jmp    14fe <main+0x31e>
cmpq   $0x0,-0x40(%rbp)
jle    14f9 <main+0x319>
mov    -0x10(%rbp),%rax
mov    (%rax),%rdi
call   10e0 <atol@plt>
mov    %rax,-0x50(%rbp)
jmp    14fe <main+0x31e>
jmp    1503 <main+0x323>
jmp    1508 <main+0x328>
jmp    150d <main+0x32d>
jmp    1512 <main+0x332>
jmp    133d <main+0x15d>
lea    0xb5f(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
movl   $0x0,-0x18(%rbp)
cmpl   $0x0,-0x18(%rbp)
setne  %al
xor    $0xff,%al
test   $0x1,%al
jne    1542 <main+0x362>
jmp    1793 <main+0x5b3>
cmpq   $0x0,-0x50(%rbp)
jle    155d <main+0x37d>
xor    %edi,%edi
call   1070 <omp_set_dynamic@plt>
mov    -0x50(%rbp),%rdi
call   10c0 <omp_set_num_threads@plt>
mov    -0x40(%rbp),%rdi
shl    $0x3,%rdi
call   10a0 <malloc@plt>
mov    %rax,-0x58(%rbp)
cmpq   $0x0,-0x58(%rbp)
jne    1595 <main+0x3b5>
mov    -0x40(%rbp),%rsi
lea    0xb39(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    $0x1,%edi
call   1100 <exit@plt>
movq   $0x0,-0x30(%rbp)
mov    -0x30(%rbp),%rax
cmp    -0x40(%rbp),%rax
jge    15db <main+0x3fb>
cvtsi2sdq -0x30(%rbp),%xmm1
movsd  0xa57(%rip),%xmm0
mulsd  %xmm1,%xmm0
mov    -0x58(%rbp),%rax
mov    -0x30(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x30(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x30(%rbp)
jmp    159d <main+0x3bd>
xorps  %xmm0,%xmm0
movsd  %xmm0,-0x60(%rbp)
mov    $0x0,%al
call   1050 <wtime@plt>
movsd  %xmm0,-0x68(%rbp)
mov    $0x0,%al
call   1060 <omp_get_num_threads@plt>
mov    %rax,-0x50(%rbp)
movq   $0x0,-0x20(%rbp)
mov    -0x20(%rbp),%rax
cmp    -0x28(%rbp),%rax
jge    1681 <main+0x4a1>
xorps  %xmm0,%xmm0
movsd  %xmm0,-0x60(%rbp)
movq   $0x0,-0x30(%rbp)
mov    -0x30(%rbp),%rax
cmp    -0x40(%rbp),%rax
jge    166b <main+0x48b>
mov    -0x58(%rbp),%rax
mov    -0x30(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x58(%rbp),%rax
mov    -0x30(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm2
movsd  -0x60(%rbp),%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x60(%rbp)
mov    -0x30(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x30(%rbp)
jmp    1620 <main+0x440>
jmp    1670 <main+0x490>
mov    -0x20(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x20(%rbp)
jmp    1602 <main+0x422>
mov    $0x0,%al
call   1050 <wtime@plt>
movsd  %xmm0,-0x70(%rbp)
mov    -0x50(%rbp),%rsi
mov    -0x40(%rbp),%rdx
mov    -0x28(%rbp),%rcx
movsd  -0x60(%rbp),%xmm0
cvtsi2sdq -0x40(%rbp),%xmm2
movsd  0x95c(%rip),%xmm1
mulsd  %xmm2,%xmm1
cvtsi2sdq -0x40(%rbp),%xmm2
mulsd  %xmm2,%xmm1
cvtsi2sdq -0x40(%rbp),%xmm3
imul   $0x3,-0x40(%rbp),%rax
imul   -0x40(%rbp),%rax
cvtsi2sd %rax,%xmm2
movq   %xmm2,%rax
movabs $0x8000000000000000,%rdi
xor    %rdi,%rax
movq   %rax,%xmm2
mulsd  %xmm3,%xmm1
addsd  %xmm2,%xmm1
cvtsi2sdq -0x40(%rbp),%xmm2
addsd  %xmm2,%xmm1
movsd  0x900(%rip),%xmm2
divsd  %xmm2,%xmm1
subsd  %xmm1,%xmm0
movsd  -0x70(%rbp),%xmm1
subsd  -0x68(%rbp),%xmm1
cvtsi2sdq -0x28(%rbp),%xmm2
divsd  %xmm2,%xmm1
lea    0x9ab(%rip),%rdi
mov    $0x2,%al
call   1040 <printf@plt>
mov    0x28af(%rip),%rax
mov    (%rax),%edi
call   10b0 <fflush@plt>
mov    -0x14(%rbp),%eax
and    $0x4,%eax
cmp    $0x0,%eax
je     1758 <main+0x578>
mov    -0x48(%rbp),%rax
add    -0x40(%rbp),%rax
mov    %rax,-0x40(%rbp)
jmp    178e <main+0x5ae>
mov    -0x14(%rbp),%eax
and    $0x8,%eax
cmp    $0x0,%eax
je     1782 <main+0x5a2>
mov    -0x40(%rbp),%rax
cqto
idivq  -0x48(%rbp)
add    $0x1,%rax
add    -0x40(%rbp),%rax
mov    %rax,-0x40(%rbp)
jmp    1789 <main+0x5a9>
movl   $0x1,-0x18(%rbp)
jmp    178e <main+0x5ae>
jmp    152c <main+0x34c>
mov    -0x4(%rbp),%eax
add    $0x1090,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x1038,%rsp
mov    %rsi,0x8(%rsp)
cmp    $0x1,%edi
je     1881 <main+0x691>
mov    %edi,%r15d
lea    0x30(%rsp),%r14
mov    %r14,%rdi
mov    $0x1000,%esi
call   1100 <gethostname@plt>
lea    0xe76(%rip),%rdi
mov    %r14,%rsi
xor    %eax,%eax
call   1050 <printf@plt>
lea    0x2c(%rsp),%rbx
mov    %rbx,%rdi
call   10a0 <time@plt>
mov    %rbx,%rdi
call   1040 <localtime@plt>
lea    0xe61(%rip),%rdx
mov    %r14,%rdi
mov    $0x1000,%esi
mov    %eax,%ecx
call   10e0 <strftime@plt>
lea    0xe4e(%rip),%rdi
mov    %r14,%rsi
xor    %eax,%eax
call   1050 <printf@plt>
lea    0xe47(%rip),%rdi
xor    %eax,%eax
call   1050 <printf@plt>
test   %r15d,%r15d
jle    16e4 <main+0x4f4>
movslq %r15d,%r12
lea    0xe1c(%rip),%r14
xor    %ebp,%ebp
mov    0x8(%rsp),%rbx
nopl   0x0(%rax)
mov    (%rbx,%rbp,8),%rsi
mov    %r14,%rdi
xor    %eax,%eax
call   1050 <printf@plt>
add    $0x1,%rbp
cmp    %rbp,%r12
jne    12a0 <main+0xb0>
lea    0xe10(%rip),%rdi
xor    %ebx,%ebx
xor    %eax,%eax
call   1050 <printf@plt>
mov    %r15d,%r13d
add    $0xffffffff,%r13d
jne    16f6 <main+0x506>
movq   $0xffffffffffffffff,0x20(%rsp)
ff ff
mov    $0x1,%ebp
mov    $0x80,%r14d
xor    %r12d,%r12d
mov    $0xa,%edi
call   1030 <putchar@plt>
cvtsi2sd %r14,%xmm0
movsd  %xmm0,0x18(%rsp)
jmp    1316 <main+0x126>
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax)
mov    %r13,%rbp
add    %r13,%r12
mov    %rbp,%r13
mov    %rbx,%r15
mov    0x20(%rsp),%rbx
test   %rbx,%rbx
jle    1335 <main+0x145>
xor    %edi,%edi
call   1080 <omp_set_dynamic@plt>
mov    %rbx,%rdi
call   10d0 <omp_set_num_threads@plt>
lea    0x0(,%r12,8),%rdi
call   10b0 <malloc@plt>
test   %rax,%rax
je     1866 <main+0x676>
mov    %rax,%rbp
test   %r12,%r12
movdqa 0xcb7(%rip),%xmm4
movdqa 0xcbf(%rip),%xmm5
movdqa 0xcc7(%rip),%xmm6
movdqa 0xccf(%rip),%xmm7
jle    1527 <main+0x337>
cmp    $0x4,%r12
jae    1390 <main+0x1a0>
xor    %eax,%eax
jmp    1510 <main+0x320>
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
mov    %r12,%rax
and    $0xfffffffffffffffc,%rax
lea    -0x4(%rax),%rcx
mov    %rcx,%rdx
shr    $0x2,%rdx
add    $0x1,%rdx
test   %rcx,%rcx
je     1498 <main+0x2a8>
mov    %rdx,%rsi
and    $0xfffffffffffffffe,%rsi
xor    %ecx,%ecx
movdqa 0xc40(%rip),%xmm0
movdqa %xmm0,%xmm1
paddq  %xmm4,%xmm1
movq   %xmm0,%rdi
xorps  %xmm2,%xmm2
cvtsi2sd %rdi,%xmm2
pshufd $0xee,%xmm0,%xmm3
movq   %xmm3,%rdi
xorps  %xmm3,%xmm3
cvtsi2sd %rdi,%xmm3
unpcklpd %xmm3,%xmm2
movq   %xmm1,%rdi
xorps  %xmm3,%xmm3
cvtsi2sd %rdi,%xmm3
pshufd $0xee,%xmm1,%xmm1
movq   %xmm1,%rdi
xorps  %xmm1,%xmm1
cvtsi2sd %rdi,%xmm1
unpcklpd %xmm1,%xmm3
movupd %xmm2,0x0(%rbp,%rcx,8)
movupd %xmm3,0x10(%rbp,%rcx,8)
movdqa %xmm0,%xmm1
paddq  %xmm5,%xmm1
movdqa %xmm0,%xmm2
paddq  %xmm6,%xmm2
movq   %xmm1,%rdi
xorps  %xmm3,%xmm3
cvtsi2sd %rdi,%xmm3
pshufd $0xee,%xmm1,%xmm1
movq   %xmm1,%rdi
xorps  %xmm1,%xmm1
cvtsi2sd %rdi,%xmm1
unpcklpd %xmm1,%xmm3
movq   %xmm2,%rdi
xorps  %xmm1,%xmm1
cvtsi2sd %rdi,%xmm1
pshufd $0xee,%xmm2,%xmm2
movq   %xmm2,%rdi
xorps  %xmm2,%xmm2
cvtsi2sd %rdi,%xmm2
unpcklpd %xmm2,%xmm1
movupd %xmm3,0x20(%rbp,%rcx,8)
movupd %xmm1,0x30(%rbp,%rcx,8)
add    $0x8,%rcx
paddq  %xmm7,%xmm0
add    $0xfffffffffffffffe,%rsi
jne    13c0 <main+0x1d0>
test   $0x1,%dl
jne    14a7 <main+0x2b7>
jmp    1522 <main+0x332>
xor    %ecx,%ecx
movdqa 0xb5e(%rip),%xmm0
test   $0x1,%dl
je     1522 <main+0x332>
movdqa %xmm0,%xmm1
movq   %xmm0,%rdx
xorps  %xmm2,%xmm2
cvtsi2sd %rdx,%xmm2
pshufd $0xee,%xmm0,%xmm0
movq   %xmm0,%rdx
xorps  %xmm0,%xmm0
cvtsi2sd %rdx,%xmm0
paddq  %xmm4,%xmm1
movq   %xmm1,%rdx
xorps  %xmm3,%xmm3
cvtsi2sd %rdx,%xmm3
pshufd $0xee,%xmm1,%xmm1
movq   %xmm1,%rdx
xorps  %xmm1,%xmm1
cvtsi2sd %rdx,%xmm1
unpcklpd %xmm0,%xmm2
unpcklpd %xmm1,%xmm3
movupd %xmm2,0x0(%rbp,%rcx,8)
movupd %xmm3,0x10(%rbp,%rcx,8)
jmp    1522 <main+0x332>
cs nopw 0x0(%rax,%rax,1)
nopl   (%rax)
xorps  %xmm0,%xmm0
cvtsi2sd %rax,%xmm0
movsd  %xmm0,0x0(%rbp,%rax,8)
add    $0x1,%rax
cmp    %rax,%r12
jne    1510 <main+0x320>
xor    %eax,%eax
call   1060 <wtime@plt>
movsd  %xmm0,0x8(%rsp)
xor    %eax,%eax
call   1070 <omp_get_num_threads@plt>
mov    %rax,0x20(%rsp)
test   %r14,%r14
jle    1600 <main+0x410>
lea    -0x1(%r12),%rax
mov    %r12d,%ecx
and    $0x3,%ecx
mov    %r12,%rdx
and    $0xfffffffffffffffc,%rdx
xor    %esi,%esi
jmp    156d <main+0x37d>
nop
add    $0x1,%rsi
cmp    %r14,%rsi
je     1604 <main+0x414>
xorpd  %xmm2,%xmm2
test   %r12,%r12
jle    1560 <main+0x370>
xor    %edi,%edi
cmp    $0x3,%rax
jb     15c1 <main+0x3d1>
xchg   %ax,%ax
movsd  0x0(%rbp,%rdi,8),%xmm0
movsd  0x8(%rbp,%rdi,8),%xmm1
mulsd  %xmm0,%xmm0
addsd  %xmm2,%xmm0
mulsd  %xmm1,%xmm1
addsd  %xmm0,%xmm1
movsd  0x10(%rbp,%rdi,8),%xmm0
mulsd  %xmm0,%xmm0
addsd  %xmm1,%xmm0
movsd  0x18(%rbp,%rdi,8),%xmm2
mulsd  %xmm2,%xmm2
addsd  %xmm0,%xmm2
add    $0x4,%rdi
cmp    %rdi,%rdx
jne    1580 <main+0x390>
test   %rcx,%rcx
je     1560 <main+0x370>
lea    0x0(,%rdi,8),%rdi
add    %rbp,%rdi
xor    %ebx,%ebx
cs nopw 0x0(%rax,%rax,1)
nopl   (%rax)
movsd  (%rdi,%rbx,8),%xmm0
mulsd  %xmm0,%xmm0
addsd  %xmm0,%xmm2
add    $0x1,%rbx
cmp    %rbx,%rcx
jne    15e0 <main+0x3f0>
jmp    1560 <main+0x370>
nopl   0x0(%rax,%rax,1)
xorpd  %xmm2,%xmm2
movsd  %xmm2,0x10(%rsp)
xor    %eax,%eax
call   1060 <wtime@plt>
movapd %xmm0,%xmm1
xorps  %xmm2,%xmm2
cvtsi2sd %r12,%xmm2
movapd %xmm2,%xmm0
addsd  %xmm2,%xmm0
mov    %r12,%rax
imul   %r12,%rax
lea    (%rax,%rax,2),%rax
xorps  %xmm3,%xmm3
cvtsi2sd %rax,%xmm3
mulsd  %xmm2,%xmm0
mulsd  %xmm2,%xmm0
subsd  %xmm3,%xmm0
addsd  %xmm2,%xmm0
divsd  0xa00(%rip),%xmm0
addsd  0x10(%rsp),%xmm0
subsd  0x8(%rsp),%xmm1
divsd  0x18(%rsp),%xmm1
lea    0xaa5(%rip),%rdi
mov    0x20(%rsp),%rsi
mov    %r12,%rdx
mov    %r14,%rcx
mov    $0x2,%al
call   1050 <printf@plt>
mov    0x295e(%rip),%rax
mov    (%rax),%edi
call   10c0 <fflush@plt>
mov    %r15,%rbx
test   $0x4,%bl
jne    1310 <main+0x120>
test   $0x8,%bl
je     16d0 <main+0x4e0>
mov    %r13,%rbp
mov    %r12,%rax
or     %r13,%rax
shr    $0x20,%rax
je     16bd <main+0x4cd>
mov    %r12,%rax
cqto
idiv   %rbp
add    %rax,%r12
add    $0x1,%r12
jmp    1316 <main+0x126>
mov    %r12d,%eax
xor    %edx,%edx
div    %ebp
add    %rax,%r12
add    $0x1,%r12
jmp    1316 <main+0x126>
xor    %eax,%eax
add    $0x1038,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret
lea    0x9e3(%rip),%rdi
xor    %eax,%eax
call   1050 <printf@plt>
lea    -0x1(%r15),%r13d
mov    $0x80,%r14d
mov    $0x1,%ebp
movq   $0xffffffffffffffff,0x20(%rsp)
ff ff
xor    %ebx,%ebx
xor    %r12d,%r12d
mov    0x8(%rsp),%rax
jmp    1751 <main+0x561>
cs nopw 0x0(%rax,%rax,1)
mov    0x18(%rsp),%r15
add    $0xfffffffe,%r15d
mov    0x8(%rsp),%r13
mov    0x10(%r13),%rdi
add    $0x10,%r13
call   10f0 <atol@plt>
mov    %rax,%r14
mov    %r13,%rax
mov    %r15d,%r13d
mov    %r13d,%r15d
add    $0xffffffff,%r13d
je     12eb <main+0xfb>
test   %rax,%rax
je     12eb <main+0xfb>
mov    %r15,0x18(%rsp)
mov    %rax,0x8(%rsp)
add    $0x8,%rax
mov    %rax,0x10(%rsp)
mov    (%rax),%r15
lea    0x95b(%rip),%rdi
mov    %r15,%rsi
call   1090 <strcmp@plt>
test   %eax,%eax
je     17e0 <main+0x5f0>
lea    0x954(%rip),%rdi
mov    %r15,%rsi
call   1090 <strcmp@plt>
test   %eax,%eax
je     1720 <main+0x530>
lea    0x946(%rip),%rdi
mov    %r15,%rsi
call   1090 <strcmp@plt>
test   %eax,%eax
je     17fb <main+0x60b>
lea    0x93f(%rip),%rdi
mov    %r15,%rsi
call   1090 <strcmp@plt>
test   %eax,%eax
je     1825 <main+0x635>
test   %r12,%r12
je     1859 <main+0x669>
jle    17f1 <main+0x601>
mov    %r15,%rdi
call   10f0 <atol@plt>
mov    %rax,0x20(%rsp)
jmp    17f1 <main+0x601>
cs nopw 0x0(%rax,%rax,1)
or     $0x1,%ebx
lea    0x8eb(%rip),%rdi
xor    %eax,%eax
call   1050 <printf@plt>
mov    0x10(%rsp),%rax
jmp    1744 <main+0x554>
or     $0x4,%ebx
mov    0x18(%rsp),%r15
add    $0xfffffffe,%r15d
mov    0x8(%rsp),%r13
mov    0x10(%r13),%rdi
add    $0x10,%r13
call   10f0 <atol@plt>
mov    %rax,%rbp
lea    0x8c6(%rip),%rdi
jmp    184d <main+0x65d>
or     $0x8,%ebx
mov    0x18(%rsp),%r15
add    $0xfffffffe,%r15d
mov    0x8(%rsp),%r13
mov    0x10(%r13),%rdi
add    $0x10,%r13
call   10f0 <atol@plt>
mov    %rax,%rbp
lea    0x8a9(%rip),%rdi
xor    %eax,%eax
call   1050 <printf@plt>
jmp    173e <main+0x54e>
mov    %r15,%rdi
call   10f0 <atol@plt>
mov    %rax,%r12
jmp    17f1 <main+0x601>
lea    0x890(%rip),%rdi
mov    %r12,%rsi
xor    %eax,%eax
call   1050 <printf@plt>
mov    $0x1,%edi
call   1110 <exit@plt>
mov    0x8(%rsp),%rax
mov    (%rax),%rsi
lea    0x7c8(%rip),%rdi
jmp    1870 <main+0x680>

LLVM IR (-O0):
@.str = [73 x i8] c"usage: %s [-scan dn | -scanx dn] [-bind] vec_size num_threads [dobind]\0A\00"
@.str.1 = [17 x i8] c"host %s \00"
@.str.2 = [3 x i8] c"%c\00"
@.str.3 = [10 x i8] c" (%s)\0A\00"
@.str.4 = [15 x i8] c"cmd \22\00"
@.str.5 = [4 x i8] c"%s \00"
@.str.6 = [4 x i8] c"\22 \00"
@.str.7 = [3 x i8] c"-v\00"
@.str.8 = [9 x i8] c"VERBOSE \00"
@.str.9 = [5 x i8] c"-nit\00"
@.str.10 = [6 x i8] c"-scan\00"
@.str.11 = [6 x i8] c"SCAN \00"
@.str.12 = [7 x i8] c"-scanx\00"
@.str.13 = [7 x i8] c"SCANX \00"
@.str.14 = [2 x i8] c"\0A\00"
@.str.15 = [17 x i8] c"malloc error %d\0A\00"
@.str.16 = [23 x i8] c"%ld %ld %ld %.3e %.3e\0A\00"
@stdout = global i32 0
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
%6 = alloca i32
%7 = alloca i32
%8 = alloca i64
%9 = alloca i64
%10 = alloca i64
%11 = alloca i64
%12 = alloca i64
%13 = alloca i64
%14 = alloca i64
%15 = alloca double*
%16 = alloca double
%17 = alloca double
%18 = alloca double
%19 = alloca i32
%20 = alloca [4096 x i8]
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
store i32 0, i32* %6
store i32 0, i32* %7
store i64 128, i64* %9
store i64 1000000, i64* %12
store i64 1, i64* %13
store i64 -1, i64* %14
%21 = load i32, i32* %4
%22 = icmp eq i32 %21, 1
br i1 %22, label %23, label %29
23: ; preds = %2
%24 = load i8**, i8*** %5
%25 = getelementptr inbounds i8*, i8** %24, i64 0
%26 = load i8*, i8** %25
%27 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([73 x i8], [73 x i8]* @.str, i64 0, i64 0), i8* %26)
%28 = call i32 @exit(i32 1)
unreachable
29: ; preds = %2
store i64 0, i64* %10
store i64 0, i64* %12
%30 = getelementptr inbounds [4096 x i8], [4096 x i8]* %20, i64 0, i64 0
%31 = call i32 @gethostname(i8* %30, i32 4096)
%32 = getelementptr inbounds [4096 x i8], [4096 x i8]* %20, i64 0, i64 0
%33 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.1, i64 0, i64 0), i8* %32)
%34 = call i32 @time(i32* %19)
%35 = getelementptr inbounds [4096 x i8], [4096 x i8]* %20, i64 0, i64 0
%36 = call i32 @localtime(i32* %19)
%37 = call i32 @strftime(i8* %35, i32 4096, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0), i32 %36)
%38 = getelementptr inbounds [4096 x i8], [4096 x i8]* %20, i64 0, i64 0
%39 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.3, i64 0, i64 0), i8* %38)
%40 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.4, i64 0, i64 0))
store i64 0, i64* %10
br label %41
41: ; preds = %52, %29
%42 = load i64, i64* %10
%43 = load i32, i32* %4
%44 = sext i32 %43 to i64
%45 = icmp slt i64 %42, %44
br i1 %45, label %46, label %55
46: ; preds = %41
%47 = load i8**, i8*** %5
%48 = load i64, i64* %10
%49 = getelementptr inbounds i8*, i8** %47, i64 %48
%50 = load i8*, i8** %49
%51 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.5, i64 0, i64 0), i8* %50)
br label %52
52: ; preds = %46
%53 = load i64, i64* %10
%54 = add nsw i64 %53, 1
store i64 %54, i64* %10
br label %41
55: ; preds = %41
store i64 0, i64* %10
%56 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.6, i64 0, i64 0))
br label %57
57: ; preds = %140, %55
%58 = load i32, i32* %4
%59 = add nsw i32 %58, -1
store i32 %59, i32* %4
%60 = icmp ne i32 %59, 0
br i1 %60, label %61, label %65
61: ; preds = %57
%62 = load i8**, i8*** %5
%63 = getelementptr inbounds i8*, i8** %62, i32 1
store i8** %63, i8*** %5
%64 = icmp ne i8** %62, null
br label %65
65: ; preds = %61, %57
%66 = phi i1 [ false, %57 ], [ %64, %61 ]
br i1 %66, label %67, label %141
67: ; preds = %65
%68 = load i8**, i8*** %5
%69 = load i8*, i8** %68
%70 = call i32 @strcmp(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.7, i64 0, i64 0), i8* %69)
%71 = icmp ne i32 %70, 0
br i1 %71, label %76, label %72
72: ; preds = %67
%73 = load i32, i32* %6
%74 = or i32 %73, 1
store i32 %74, i32* %6
%75 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.8, i64 0, i64 0))
br label %140
76: ; preds = %67
%77 = load i8**, i8*** %5
%78 = load i8*, i8** %77
%79 = call i32 @strcmp(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.9, i64 0, i64 0), i8* %78)
%80 = icmp ne i32 %79, 0
br i1 %80, label %89, label %81
81: ; preds = %76
%82 = load i32, i32* %4
%83 = add nsw i32 %82, -1
store i32 %83, i32* %4
%84 = load i8**, i8*** %5
%85 = getelementptr inbounds i8*, i8** %84, i32 1
store i8** %85, i8*** %5
%86 = load i8**, i8*** %5
%87 = load i8*, i8** %86
%88 = call i64 @atol(i8* %87)
store i64 %88, i64* %9
br label %139
89: ; preds = %76
%90 = load i8**, i8*** %5
%91 = load i8*, i8** %90
%92 = call i32 @strcmp(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.10, i64 0, i64 0), i8* %91)
%93 = icmp ne i32 %92, 0
br i1 %93, label %105, label %94
94: ; preds = %89
%95 = load i32, i32* %6
%96 = or i32 %95, 4
store i32 %96, i32* %6
%97 = load i32, i32* %4
%98 = add nsw i32 %97, -1
store i32 %98, i32* %4
%99 = load i8**, i8*** %5
%100 = getelementptr inbounds i8*, i8** %99, i32 1
store i8** %100, i8*** %5
%101 = load i8**, i8*** %5
%102 = load i8*, i8** %101
%103 = call i64 @atol(i8* %102)
store i64 %103, i64* %13
%104 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.11, i64 0, i64 0))
br label %138
105: ; preds = %89
%106 = load i8**, i8*** %5
%107 = load i8*, i8** %106
%108 = call i32 @strcmp(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.12, i64 0, i64 0), i8* %107)
%109 = icmp ne i32 %108, 0
br i1 %109, label %121, label %110
110: ; preds = %105
%111 = load i32, i32* %6
%112 = or i32 %111, 8
store i32 %112, i32* %6
%113 = load i32, i32* %4
%114 = add nsw i32 %113, -1
store i32 %114, i32* %4
%115 = load i8**, i8*** %5
%116 = getelementptr inbounds i8*, i8** %115, i32 1
store i8** %116, i8*** %5
%117 = load i8**, i8*** %5
%118 = load i8*, i8** %117
%119 = call i64 @atol(i8* %118)
store i64 %119, i64* %13
%120 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.13, i64 0, i64 0))
br label %137
121: ; preds = %105
%122 = load i64, i64* %12
%123 = icmp eq i64 %122, 0
br i1 %123, label %124, label %128
124: ; preds = %121
%125 = load i8**, i8*** %5
%126 = load i8*, i8** %125
%127 = call i64 @atol(i8* %126)
store i64 %127, i64* %12
br label %136
128: ; preds = %121
%129 = load i64, i64* %12
%130 = icmp sgt i64 %129, 0
br i1 %130, label %131, label %135
131: ; preds = %128
%132 = load i8**, i8*** %5
%133 = load i8*, i8** %132
%134 = call i64 @atol(i8* %133)
store i64 %134, i64* %14
br label %135
135: ; preds = %131, %128
br label %136
136: ; preds = %135, %124
br label %137
137: ; preds = %136, %110
br label %138
138: ; preds = %137, %94
br label %139
139: ; preds = %138, %81
br label %140
140: ; preds = %139, %72
br label %57
141: ; preds = %65
%142 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.14, i64 0, i64 0))
store i32 0, i32* %7
br label %143
143: ; preds = %265, %141
%144 = load i32, i32* %7
%145 = icmp ne i32 %144, 0
%146 = xor i1 %145, true
br i1 %146, label %147, label %266
147: ; preds = %143
%148 = load i64, i64* %14
%149 = icmp sgt i64 %148, 0
br i1 %149, label %150, label %154
150: ; preds = %147
%151 = call i32 @omp_set_dynamic(i32 0)
%152 = load i64, i64* %14
%153 = call i32 @omp_set_num_threads(i64 %152)
br label %154
154: ; preds = %150, %147
%155 = load i64, i64* %12
%156 = mul i64 %155, 8
%157 = call i64 @malloc(i64 %156)
%158 = inttoptr i64 %157 to double*
store double* %158, double** %15
%159 = load double*, double** %15
%160 = icmp ne double* %159, null
br i1 %160, label %165, label %161
161: ; preds = %154
%162 = load i64, i64* %12
%163 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.15, i64 0, i64 0), i64 %162)
%164 = call i32 @exit(i32 1)
unreachable
165: ; preds = %154
store i64 0, i64* %10
br label %166
166: ; preds = %177, %165
%167 = load i64, i64* %10
%168 = load i64, i64* %12
%169 = icmp slt i64 %167, %168
br i1 %169, label %170, label %180
170: ; preds = %166
%171 = load i64, i64* %10
%172 = sitofp i64 %171 to double
%173 = fmul double 1.000000e+00, %172
%174 = load double*, double** %15
%175 = load i64, i64* %10
%176 = getelementptr inbounds double, double* %174, i64 %175
store double %173, double* %176
br label %177
177: ; preds = %170
%178 = load i64, i64* %10
%179 = add nsw i64 %178, 1
store i64 %179, i64* %10
br label %166
180: ; preds = %166
store double 0.000000e+00, double* %16
%181 = call double (...) @wtime()
store double %181, double* %17
%182 = call i64 (...) @omp_get_num_threads()
store i64 %182, i64* %14
store i64 0, i64* %8
br label %183
183: ; preds = %207, %180
%184 = load i64, i64* %8
%185 = load i64, i64* %9
%186 = icmp slt i64 %184, %185
br i1 %186, label %187, label %210
187: ; preds = %183
store double 0.000000e+00, double* %16
store i64 0, i64* %10
br label %188
188: ; preds = %203, %187
%189 = load i64, i64* %10
%190 = load i64, i64* %12
%191 = icmp slt i64 %189, %190
br i1 %191, label %192, label %206
192: ; preds = %188
%193 = load double*, double** %15
%194 = load i64, i64* %10
%195 = getelementptr inbounds double, double* %193, i64 %194
%196 = load double, double* %195
%197 = load double*, double** %15
%198 = load i64, i64* %10
%199 = getelementptr inbounds double, double* %197, i64 %198
%200 = load double, double* %199
%201 = load double, double* %16
%202 = call double @llvm.fmuladd.f64(double %196, double %200, double %201)
store double %202, double* %16
br label %203
203: ; preds = %192
%204 = load i64, i64* %10
%205 = add nsw i64 %204, 1
store i64 %205, i64* %10
br label %188
206: ; preds = %188
br label %207
207: ; preds = %206
%208 = load i64, i64* %8
%209 = add nsw i64 %208, 1
store i64 %209, i64* %8
br label %183
210: ; preds = %183
%211 = call double (...) @wtime()
store double %211, double* %18
%212 = load i64, i64* %14
%213 = load i64, i64* %12
%214 = load i64, i64* %9
%215 = load double, double* %16
%216 = load i64, i64* %12
%217 = sitofp i64 %216 to double
%218 = fmul double 2.000000e+00, %217
%219 = load i64, i64* %12
%220 = sitofp i64 %219 to double
%221 = fmul double %218, %220
%222 = load i64, i64* %12
%223 = sitofp i64 %222 to double
%224 = load i64, i64* %12
%225 = mul nsw i64 3, %224
%226 = load i64, i64* %12
%227 = mul nsw i64 %225, %226
%228 = sitofp i64 %227 to double
%229 = fneg double %228
%230 = call double @llvm.fmuladd.f64(double %221, double %223, double %229)
%231 = load i64, i64* %12
%232 = sitofp i64 %231 to double
%233 = fadd double %230, %232
%234 = fdiv double %233, 6.000000e+00
%235 = fsub double %215, %234
%236 = load double, double* %18
%237 = load double, double* %17
%238 = fsub double %236, %237
%239 = load i64, i64* %9
%240 = sitofp i64 %239 to double
%241 = fdiv double %238, %240
%242 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([23 x i8], [23 x i8]* @.str.16, i64 0, i64 0), i64 %212, i64 %213, i64 %214, double %235, double %241)
%243 = load i32, i32* @stdout
%244 = call i32 @fflush(i32 %243)
%245 = load i32, i32* %6
%246 = and i32 %245, 4
%247 = icmp ne i32 %246, 0
br i1 %247, label %248, label %252
248: ; preds = %210
%249 = load i64, i64* %13
%250 = load i64, i64* %12
%251 = add nsw i64 %250, %249
store i64 %251, i64* %12
br label %265
252: ; preds = %210
%253 = load i32, i32* %6
%254 = and i32 %253, 8
%255 = icmp ne i32 %254, 0
br i1 %255, label %256, label %263
256: ; preds = %252
%257 = load i64, i64* %12
%258 = load i64, i64* %13
%259 = sdiv i64 %257, %258
%260 = add nsw i64 %259, 1
%261 = load i64, i64* %12
%262 = add nsw i64 %261, %260
store i64 %262, i64* %12
br label %264
263: ; preds = %252
store i32 1, i32* %7
br label %264
264: ; preds = %263, %256
br label %265
265: ; preds = %264, %248
br label %143
266: ; preds = %143
%267 = load i32, i32* %3
ret i32 %267
}

LLVM IR (-O2):
@.str = [73 x i8] c"usage: %s [-scan dn | -scanx dn] [-bind] vec_size num_threads [dobind]\0A\00"
@.str.1 = [17 x i8] c"host %s \00"
@.str.2 = [3 x i8] c"%c\00"
@.str.3 = [10 x i8] c" (%s)\0A\00"
@.str.4 = [15 x i8] c"cmd \22\00"
@.str.5 = [4 x i8] c"%s \00"
@.str.6 = [4 x i8] c"\22 \00"
@.str.7 = [3 x i8] c"-v\00"
@.str.8 = [9 x i8] c"VERBOSE \00"
@.str.9 = [5 x i8] c"-nit\00"
@.str.10 = [6 x i8] c"-scan\00"
@.str.11 = [6 x i8] c"SCAN \00"
@.str.12 = [7 x i8] c"-scanx\00"
@.str.13 = [7 x i8] c"SCANX \00"
@.str.15 = [17 x i8] c"malloc error %d\0A\00"
@.str.16 = [23 x i8] c"%ld %ld %ld %.3e %.3e\0A\00"
@stdout = global i32 0
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca [4096 x i8]
%5 = bitcast i32* %3 to i8*
%6 = getelementptr inbounds [4096 x i8], [4096 x i8]* %4, i64 0, i64 0
%7 = icmp eq i32 %0, 1
br i1 %7, label %8, label %12
8: ; preds = %2
%9 = load i8*, i8** %1
%10 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([73 x i8], [73 x i8]* @.str, i64 0, i64 0), i8* %9)
%11 = tail call i32 @exit(i32 1)
unreachable
12: ; preds = %2
%13 = call i32 @gethostname(i8* %6, i32 4096)
%14 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([17 x i8], [17 x i8]* @.str.1, i64 0, i64 0), i8* %6)
%15 = call i32 @time(i32* %3)
%16 = call i32 @localtime(i32* %3)
%17 = call i32 @strftime(i8* %6, i32 4096, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0), i32 %16)
%18 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([10 x i8], [10 x i8]* @.str.3, i64 0, i64 0), i8* %6)
%19 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([15 x i8], [15 x i8]* @.str.4, i64 0, i64 0))
%20 = sext i32 %0 to i64
%21 = icmp sgt i32 %0, 0
br i1 %21, label %25, label %22
22: ; preds = %12
%23 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.6, i64 0, i64 0))
%24 = add nsw i32 %0, -1
br label %36
25: ; preds = %12, %25
%26 = phi i64 [ %30, %25 ], [ 0, %12 ]
%27 = getelementptr inbounds i8*, i8** %1, i64 %26
%28 = load i8*, i8** %27
%29 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.5, i64 0, i64 0), i8* %28)
%30 = add nuw nsw i64 %26, 1
%31 = icmp eq i64 %30, %20
br i1 %31, label %32, label %25
32: ; preds = %25
%33 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.6, i64 0, i64 0))
%34 = add nsw i32 %0, -1
%35 = icmp eq i32 %34, 0
br i1 %35, label %102, label %36
36: ; preds = %22, %32
%37 = phi i32 [ %34, %32 ], [ %24, %22 ]
br label %38
38: ; preds = %36, %92
%39 = phi i32 [ %100, %92 ], [ %37, %36 ]
%40 = phi i32 [ %99, %92 ], [ %0, %36 ]
%41 = phi i8** [ %98, %92 ], [ %1, %36 ]
%42 = phi i32 [ %97, %92 ], [ 0, %36 ]
%43 = phi i64 [ %96, %92 ], [ -1, %36 ]
%44 = phi i64 [ %95, %92 ], [ 1, %36 ]
%45 = phi i64 [ %94, %92 ], [ 0, %36 ]
%46 = phi i64 [ %93, %92 ], [ 128, %36 ]
%47 = getelementptr inbounds i8*, i8** %41, i64 1
%48 = icmp eq i8** %41, null
br i1 %48, label %102, label %49
49: ; preds = %38
%50 = load i8*, i8** %47
%51 = call i32 @strcmp(i8* dereferenceable(3) getelementptr inbounds ([3 x i8], [3 x i8]* @.str.7, i64 0, i64 0), i8* dereferenceable(1) %50)
%52 = icmp eq i32 %51, 0
br i1 %52, label %53, label %56
53: ; preds = %49
%54 = or i32 %42, 1
%55 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([9 x i8], [9 x i8]* @.str.8, i64 0, i64 0))
br label %92
56: ; preds = %49
%57 = call i32 @strcmp(i8* dereferenceable(5) getelementptr inbounds ([5 x i8], [5 x i8]* @.str.9, i64 0, i64 0), i8* dereferenceable(1) %50)
%58 = icmp eq i32 %57, 0
br i1 %58, label %59, label %64
59: ; preds = %56
%60 = add nsw i32 %40, -2
%61 = getelementptr inbounds i8*, i8** %41, i64 2
%62 = load i8*, i8** %61
%63 = call i64 @atol(i8* %62)
br label %92
64: ; preds = %56
%65 = call i32 @strcmp(i8* dereferenceable(6) getelementptr inbounds ([6 x i8], [6 x i8]* @.str.10, i64 0, i64 0), i8* dereferenceable(1) %50)
%66 = icmp eq i32 %65, 0
br i1 %66, label %67, label %74
67: ; preds = %64
%68 = or i32 %42, 4
%69 = add nsw i32 %40, -2
%70 = getelementptr inbounds i8*, i8** %41, i64 2
%71 = load i8*, i8** %70
%72 = call i64 @atol(i8* %71)
%73 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str.11, i64 0, i64 0))
br label %92
74: ; preds = %64
%75 = call i32 @strcmp(i8* dereferenceable(7) getelementptr inbounds ([7 x i8], [7 x i8]* @.str.12, i64 0, i64 0), i8* dereferenceable(1) %50)
%76 = icmp eq i32 %75, 0
br i1 %76, label %77, label %84
77: ; preds = %74
%78 = or i32 %42, 8
%79 = add nsw i32 %40, -2
%80 = getelementptr inbounds i8*, i8** %41, i64 2
%81 = load i8*, i8** %80
%82 = call i64 @atol(i8* %81)
%83 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([7 x i8], [7 x i8]* @.str.13, i64 0, i64 0))
br label %92
84: ; preds = %74
%85 = icmp eq i64 %45, 0
br i1 %85, label %86, label %88
86: ; preds = %84
%87 = call i64 @atol(i8* %50)
br label %92
88: ; preds = %84
%89 = icmp sgt i64 %45, 0
br i1 %89, label %90, label %92
90: ; preds = %88
%91 = call i64 @atol(i8* %50)
br label %92
92: ; preds = %59, %77, %88, %90, %86, %67, %53
%93 = phi i64 [ %46, %86 ], [ %46, %90 ], [ %46, %88 ], [ %46, %77 ], [ %46, %67 ], [ %63, %59 ], [ %46, %53 ]
%94 = phi i64 [ %87, %86 ], [ %45, %90 ], [ %45, %88 ], [ %45, %77 ], [ %45, %67 ], [ %45, %59 ], [ %45, %53 ]
%95 = phi i64 [ %44, %86 ], [ %44, %90 ], [ %44, %88 ], [ %82, %77 ], [ %72, %67 ], [ %44, %59 ], [ %44, %53 ]
%96 = phi i64 [ %43, %86 ], [ %91, %90 ], [ %43, %88 ], [ %43, %77 ], [ %43, %67 ], [ %43, %59 ], [ %43, %53 ]
%97 = phi i32 [ %42, %86 ], [ %42, %90 ], [ %42, %88 ], [ %78, %77 ], [ %68, %67 ], [ %42, %59 ], [ %54, %53 ]
%98 = phi i8** [ %47, %86 ], [ %47, %90 ], [ %47, %88 ], [ %80, %77 ], [ %70, %67 ], [ %61, %59 ], [ %47, %53 ]
%99 = phi i32 [ %39, %86 ], [ %39, %90 ], [ %39, %88 ], [ %79, %77 ], [ %69, %67 ], [ %60, %59 ], [ %39, %53 ]
%100 = add nsw i32 %99, -1
%101 = icmp eq i32 %100, 0
br i1 %101, label %102, label %38
102: ; preds = %38, %92, %32
%103 = phi i64 [ 128, %32 ], [ %93, %92 ], [ %46, %38 ]
%104 = phi i64 [ 0, %32 ], [ %94, %92 ], [ %45, %38 ]
%105 = phi i64 [ 1, %32 ], [ %95, %92 ], [ %44, %38 ]
%106 = phi i64 [ -1, %32 ], [ %96, %92 ], [ %43, %38 ]
%107 = phi i32 [ 0, %32 ], [ %97, %92 ], [ %42, %38 ]
%108 = call i32 @putchar(i32 10)
%109 = icmp sgt i64 %103, 0
%110 = sitofp i64 %103 to double
%111 = and i32 %107, 4
%112 = icmp eq i32 %111, 0
%113 = and i32 %107, 8
%114 = icmp eq i32 %113, 0
br label %115
115: ; preds = %267, %102
%116 = phi i64 [ %106, %102 ], [ %191, %267 ]
%117 = phi i64 [ %104, %102 ], [ %268, %267 ]
%118 = icmp sgt i64 %116, 0
br i1 %118, label %119, label %122
119: ; preds = %115
%120 = call i32 @omp_set_dynamic(i32 0)
%121 = call i32 @omp_set_num_threads(i64 %116)
br label %122
122: ; preds = %119, %115
%123 = shl i64 %117, 3
%124 = call i64 @malloc(i64 %123)
%125 = inttoptr i64 %124 to double*
%126 = icmp eq i64 %124, 0
br i1 %126, label %180, label %127
127: ; preds = %122
%128 = icmp sgt i64 %117, 0
br i1 %128, label %129, label %189
129: ; preds = %127
%130 = icmp ult i64 %117, 4
br i1 %130, label %178, label %131
131: ; preds = %129
%132 = and i64 %117, -4
%133 = add i64 %132, -4
%134 = lshr exact i64 %133, 2
%135 = add nuw nsw i64 %134, 1
%136 = and i64 %135, 1
%137 = icmp eq i64 %133, 0
br i1 %137, label %164, label %138
138: ; preds = %131
%139 = and i64 %135, 9223372036854775806
br label %140
140: ; preds = %140, %138
%141 = phi i64 [ 0, %138 ], [ %160, %140 ]
%142 = phi <2 x i64> [ <i64 0, i64 1>, %138 ], [ %161, %140 ]
%143 = phi i64 [ 0, %138 ], [ %162, %140 ]
%144 = add <2 x i64> %142, <i64 2, i64 2>
%145 = sitofp <2 x i64> %142 to <2 x double>
%146 = sitofp <2 x i64> %144 to <2 x double>
%147 = getelementptr inbounds double, double* %125, i64 %141
%148 = bitcast double* %147 to <2 x double>*
store <2 x double> %145, <2 x double>* %148
%149 = getelementptr inbounds double, double* %147, i64 2
%150 = bitcast double* %149 to <2 x double>*
store <2 x double> %146, <2 x double>* %150
%151 = or i64 %141, 4
%152 = add <2 x i64> %142, <i64 4, i64 4>
%153 = add <2 x i64> %142, <i64 6, i64 6>
%154 = sitofp <2 x i64> %152 to <2 x double>
%155 = sitofp <2 x i64> %153 to <2 x double>
%156 = getelementptr inbounds double, double* %125, i64 %151
%157 = bitcast double* %156 to <2 x double>*
store <2 x double> %154, <2 x double>* %157
%158 = getelementptr inbounds double, double* %156, i64 2
%159 = bitcast double* %158 to <2 x double>*
store <2 x double> %155, <2 x double>* %159
%160 = add nuw i64 %141, 8
%161 = add <2 x i64> %142, <i64 8, i64 8>
%162 = add i64 %143, 2
%163 = icmp eq i64 %162, %139
br i1 %163, label %164, label %140
164: ; preds = %140, %131
%165 = phi i64 [ 0, %131 ], [ %160, %140 ]
%166 = phi <2 x i64> [ <i64 0, i64 1>, %131 ], [ %161, %140 ]
%167 = icmp eq i64 %136, 0
br i1 %167, label %176, label %168
168: ; preds = %164
%169 = add <2 x i64> %166, <i64 2, i64 2>
%170 = sitofp <2 x i64> %166 to <2 x double>
%171 = sitofp <2 x i64> %169 to <2 x double>
%172 = getelementptr inbounds double, double* %125, i64 %165
%173 = bitcast double* %172 to <2 x double>*
store <2 x double> %170, <2 x double>* %173
%174 = getelementptr inbounds double, double* %172, i64 2
%175 = bitcast double* %174 to <2 x double>*
store <2 x double> %171, <2 x double>* %175
br label %176
176: ; preds = %164, %168
%177 = icmp eq i64 %117, %132
br i1 %177, label %189, label %178
178: ; preds = %129, %176
%179 = phi i64 [ 0, %129 ], [ %132, %176 ]
br label %183
180: ; preds = %122
%181 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([17 x i8], [17 x i8]* @.str.15, i64 0, i64 0), i64 %117)
%182 = call i32 @exit(i32 1)
unreachable
183: ; preds = %178, %183
%184 = phi i64 [ %187, %183 ], [ %179, %178 ]
%185 = sitofp i64 %184 to double
%186 = getelementptr inbounds double, double* %125, i64 %184
store double %185, double* %186
%187 = add nuw nsw i64 %184, 1
%188 = icmp eq i64 %187, %117
br i1 %188, label %189, label %183
189: ; preds = %183, %176, %127
%190 = call double (...) @wtime()
%191 = call i64 (...) @omp_get_num_threads()
br i1 %109, label %192, label %241
192: ; preds = %189
%193 = add i64 %117, -1
%194 = and i64 %117, 3
%195 = icmp ult i64 %193, 3
%196 = and i64 %117, -4
%197 = icmp eq i64 %194, 0
br label %198
198: ; preds = %192, %237
%199 = phi i64 [ %239, %237 ], [ 0, %192 ]
br i1 %128, label %200, label %237
200: ; preds = %198
br i1 %195, label %223, label %201
201: ; preds = %200, %201
%202 = phi double [ %219, %201 ], [ 0.000000e+00, %200 ]
%203 = phi i64 [ %220, %201 ], [ 0, %200 ]
%204 = phi i64 [ %221, %201 ], [ 0, %200 ]
%205 = getelementptr inbounds double, double* %125, i64 %203
%206 = load double, double* %205
%207 = call double @llvm.fmuladd.f64(double %206, double %206, double %202)
%208 = or i64 %203, 1
%209 = getelementptr inbounds double, double* %125, i64 %208
%210 = load double, double* %209
%211 = call double @llvm.fmuladd.f64(double %210, double %210, double %207)
%212 = or i64 %203, 2
%213 = getelementptr inbounds double, double* %125, i64 %212
%214 = load double, double* %213
%215 = call double @llvm.fmuladd.f64(double %214, double %214, double %211)
%216 = or i64 %203, 3
%217 = getelementptr inbounds double, double* %125, i64 %216
%218 = load double, double* %217
%219 = call double @llvm.fmuladd.f64(double %218, double %218, double %215)
%220 = add nuw nsw i64 %203, 4
%221 = add i64 %204, 4
%222 = icmp eq i64 %221, %196
br i1 %222, label %223, label %201
223: ; preds = %201, %200
%224 = phi double [ undef, %200 ], [ %219, %201 ]
%225 = phi double [ 0.000000e+00, %200 ], [ %219, %201 ]
%226 = phi i64 [ 0, %200 ], [ %220, %201 ]
br i1 %197, label %237, label %227
227: ; preds = %223, %227
%228 = phi double [ %233, %227 ], [ %225, %223 ]
%229 = phi i64 [ %234, %227 ], [ %226, %223 ]
%230 = phi i64 [ %235, %227 ], [ 0, %223 ]
%231 = getelementptr inbounds double, double* %125, i64 %229
%232 = load double, double* %231
%233 = call double @llvm.fmuladd.f64(double %232, double %232, double %228)
%234 = add nuw nsw i64 %229, 1
%235 = add i64 %230, 1
%236 = icmp eq i64 %235, %194
br i1 %236, label %237, label %227
237: ; preds = %223, %227, %198
%238 = phi double [ 0.000000e+00, %198 ], [ %224, %223 ], [ %233, %227 ]
%239 = add nuw nsw i64 %199, 1
%240 = icmp eq i64 %239, %103
br i1 %240, label %241, label %198
241: ; preds = %237, %189
%242 = phi double [ 0.000000e+00, %189 ], [ %238, %237 ]
%243 = call double (...) @wtime()
%244 = sitofp i64 %117 to double
%245 = fmul double %244, 2.000000e+00
%246 = fmul double %245, %244
%247 = mul nsw i64 %117, 3
%248 = mul nsw i64 %247, %117
%249 = sitofp i64 %248 to double
%250 = fneg double %249
%251 = call double @llvm.fmuladd.f64(double %246, double %244, double %250)
%252 = fadd double %251, %244
%253 = fdiv double %252, 6.000000e+00
%254 = fsub double %242, %253
%255 = fsub double %243, %190
%256 = fdiv double %255, %110
%257 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([23 x i8], [23 x i8]* @.str.16, i64 0, i64 0), i64 %191, i64 %117, i64 %103, double %254, double %256)
%258 = load i32, i32* @stdout
%259 = call i32 @fflush(i32 %258)
br i1 %112, label %262, label %260
260: ; preds = %241
%261 = add nsw i64 %117, %105
br label %267
262: ; preds = %241
br i1 %114, label %269, label %263
263: ; preds = %262
%264 = sdiv i64 %117, %105
%265 = add i64 %117, 1
%266 = add i64 %265, %264
br label %267
267: ; preds = %263, %260
%268 = phi i64 [ %266, %263 ], [ %261, %260 ]
br label %115
269: ; preds = %262
ret i32 0
}