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

/* Forward declarations */

/* Type definitions */

/* Variables and functions */
scalar_t__ malloc(int);
int /*<<< orphan*/ printf(char *, double, double, double, double, double,
                          double);
int main(int argc, char **argv) {
  int i, j, k;
  int n = 1000;
  double *y = (double *)malloc(1000 * 1000 * sizeof(double));
  double *sum = (double *)malloc(1000 * 1000 * sizeof(double));
  double *alpha = (double *)malloc(1000 * sizeof(double));
  double *beta = (double *)malloc(1000 * sizeof(double));
  double *r = (double *)malloc(1000 * sizeof(double));
  double *out = (double *)malloc(1000 * sizeof(double));
  for (i = 0; i < n; i++) {
    alpha[i] = i;
    beta[i] = (i + 1) / n / 2.0;
    r[i] = (i + 1) / n / 4.0;
    for (j = 0; j < n; j++) {
      y[i * n + j] = ((double)i * j) / n;
      sum[i * n + j] = ((double)i * j) / n;
    }
  }
#pragma scop
  y[0] = r[0];
  beta[0] = 1;
  alpha[0] = r[0];
  for (k = 1; k < 1000; k++) {
    beta[k] = beta[k - 1] - alpha[k - 1] * alpha[k - 1] * beta[k - 1];
    sum[k] = r[k];
    for (i = 0; i <= k - 1; i++)
      sum[(i + 1) * n + k] = sum[i * n + k] + r[k - i - 1] * y[i * n + k - 1];
    alpha[k] = -sum[k * n + k] * beta[k];
    for (i = 0; i <= k - 1; i++)
      y[i * n + k] = y[i * n + k - 1] + alpha[k] * y[(k - i - 1) * n + k - 1];
    y[k * n + k] = alpha[k];
  }
  for (i = 0; i < 1000; i++)
    out[i] = y[i * n + 1000 - 1];
#pragma endscop
  printf("%f %f %f %f %f %f\n", y[11], sum[11], out[11], alpha[11], r[11],
         beta[11]);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x50,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
movl   $0x3e8,-0x20(%rbp)
mov    $0x7a1200,%edi
call   1040 <malloc@plt>
mov    %rax,-0x28(%rbp)
mov    $0x7a1200,%edi
call   1040 <malloc@plt>
mov    %rax,-0x30(%rbp)
mov    $0x1f40,%edi
call   1040 <malloc@plt>
mov    %rax,-0x38(%rbp)
mov    $0x1f40,%edi
call   1040 <malloc@plt>
mov    %rax,-0x40(%rbp)
mov    $0x1f40,%edi
call   1040 <malloc@plt>
mov    %rax,-0x48(%rbp)
mov    $0x1f40,%edi
call   1040 <malloc@plt>
mov    %rax,-0x50(%rbp)
movl   $0x0,-0x14(%rbp)
mov    -0x14(%rbp),%eax
cmp    -0x20(%rbp),%eax
jge    1292 <main+0x172>
cvtsi2sdl -0x14(%rbp),%xmm0
mov    -0x38(%rbp),%rax
movslq -0x14(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x14(%rbp),%eax
add    $0x1,%eax
cltd
idivl  -0x20(%rbp)
cvtsi2sd %eax,%xmm0
movsd  0xe44(%rip),%xmm1
divsd  %xmm1,%xmm0
mov    -0x40(%rbp),%rax
movslq -0x14(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x14(%rbp),%eax
add    $0x1,%eax
cltd
idivl  -0x20(%rbp)
cvtsi2sd %eax,%xmm0
movsd  0xe15(%rip),%xmm1
divsd  %xmm1,%xmm0
mov    -0x48(%rbp),%rax
movslq -0x14(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
movl   $0x0,-0x18(%rbp)
mov    -0x18(%rbp),%eax
cmp    -0x20(%rbp),%eax
jge    127f <main+0x15f>
cvtsi2sdl -0x14(%rbp),%xmm0
cvtsi2sdl -0x18(%rbp),%xmm1
mulsd  %xmm1,%xmm0
cvtsi2sdl -0x20(%rbp),%xmm1
divsd  %xmm1,%xmm0
mov    -0x28(%rbp),%rax
mov    -0x14(%rbp),%ecx
imul   -0x20(%rbp),%ecx
add    -0x18(%rbp),%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
cvtsi2sdl -0x14(%rbp),%xmm0
cvtsi2sdl -0x18(%rbp),%xmm1
mulsd  %xmm1,%xmm0
cvtsi2sdl -0x20(%rbp),%xmm1
divsd  %xmm1,%xmm0
mov    -0x30(%rbp),%rax
mov    -0x14(%rbp),%ecx
imul   -0x20(%rbp),%ecx
add    -0x18(%rbp),%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x18(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x18(%rbp)
jmp    120b <main+0xeb>
jmp    1284 <main+0x164>
mov    -0x14(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x14(%rbp)
jmp    1198 <main+0x78>
mov    -0x48(%rbp),%rax
movsd  (%rax),%xmm0
mov    -0x28(%rbp),%rax
movsd  %xmm0,(%rax)
mov    -0x40(%rbp),%rax
movsd  0xd52(%rip),%xmm0
movsd  %xmm0,(%rax)
mov    -0x48(%rbp),%rax
movsd  (%rax),%xmm0
mov    -0x38(%rbp),%rax
movsd  %xmm0,(%rax)
movl   $0x1,-0x1c(%rbp)
cmpl   $0x3e8,-0x1c(%rbp)
jge    14f0 <main+0x3d0>
mov    -0x40(%rbp),%rax
mov    -0x1c(%rbp),%ecx
sub    $0x1,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm1
mov    -0x38(%rbp),%rax
mov    -0x1c(%rbp),%ecx
sub    $0x1,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x38(%rbp),%rax
mov    -0x1c(%rbp),%ecx
sub    $0x1,%ecx
movslq %ecx,%rcx
mulsd  (%rax,%rcx,8),%xmm0
mov    -0x40(%rbp),%rax
mov    -0x1c(%rbp),%ecx
sub    $0x1,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm2
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
mov    -0x40(%rbp),%rax
movslq -0x1c(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x48(%rbp),%rax
movslq -0x1c(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x30(%rbp),%rax
movslq -0x1c(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
movl   $0x0,-0x14(%rbp)
mov    -0x14(%rbp),%eax
mov    -0x1c(%rbp),%ecx
sub    $0x1,%ecx
cmp    %ecx,%eax
jg     13ef <main+0x2cf>
mov    -0x30(%rbp),%rax
mov    -0x14(%rbp),%ecx
imul   -0x20(%rbp),%ecx
add    -0x1c(%rbp),%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm1
mov    -0x48(%rbp),%rax
mov    -0x1c(%rbp),%ecx
sub    -0x14(%rbp),%ecx
sub    $0x1,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x28(%rbp),%rax
mov    -0x14(%rbp),%ecx
imul   -0x20(%rbp),%ecx
add    -0x1c(%rbp),%ecx
sub    $0x1,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
mov    -0x30(%rbp),%rax
mov    -0x14(%rbp),%ecx
add    $0x1,%ecx
imul   -0x20(%rbp),%ecx
add    -0x1c(%rbp),%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x14(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x14(%rbp)
jmp    136b <main+0x24b>
mov    -0x30(%rbp),%rax
mov    -0x1c(%rbp),%ecx
imul   -0x20(%rbp),%ecx
add    -0x1c(%rbp),%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
mov    -0x40(%rbp),%rax
movslq -0x1c(%rbp),%rcx
mulsd  (%rax,%rcx,8),%xmm0
mov    -0x38(%rbp),%rax
movslq -0x1c(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
movl   $0x0,-0x14(%rbp)
mov    -0x14(%rbp),%eax
mov    -0x1c(%rbp),%ecx
sub    $0x1,%ecx
cmp    %ecx,%eax
jg     14bf <main+0x39f>
mov    -0x28(%rbp),%rax
mov    -0x14(%rbp),%ecx
imul   -0x20(%rbp),%ecx
add    -0x1c(%rbp),%ecx
sub    $0x1,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm1
mov    -0x38(%rbp),%rax
movslq -0x1c(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x28(%rbp),%rax
mov    -0x1c(%rbp),%ecx
sub    -0x14(%rbp),%ecx
sub    $0x1,%ecx
imul   -0x20(%rbp),%ecx
add    -0x1c(%rbp),%ecx
sub    $0x1,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
mov    -0x28(%rbp),%rax
mov    -0x14(%rbp),%ecx
imul   -0x20(%rbp),%ecx
add    -0x1c(%rbp),%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x14(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x14(%rbp)
jmp    143d <main+0x31d>
mov    -0x38(%rbp),%rax
movslq -0x1c(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x28(%rbp),%rax
mov    -0x1c(%rbp),%ecx
imul   -0x20(%rbp),%ecx
add    -0x1c(%rbp),%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x1c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x1c(%rbp)
jmp    12c9 <main+0x1a9>
movl   $0x0,-0x14(%rbp)
cmpl   $0x3e8,-0x14(%rbp)
jge    153b <main+0x41b>
mov    -0x28(%rbp),%rax
mov    -0x14(%rbp),%ecx
imul   -0x20(%rbp),%ecx
add    $0x3e8,%ecx
sub    $0x1,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x50(%rbp),%rax
movslq -0x14(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x14(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x14(%rbp)
jmp    14f7 <main+0x3d7>
mov    -0x28(%rbp),%rax
movsd  0x58(%rax),%xmm0
mov    -0x30(%rbp),%rax
movsd  0x58(%rax),%xmm1
mov    -0x50(%rbp),%rax
movsd  0x58(%rax),%xmm2
mov    -0x38(%rbp),%rax
movsd  0x58(%rax),%xmm3
mov    -0x48(%rbp),%rax
movsd  0x58(%rax),%xmm4
mov    -0x40(%rbp),%rax
movsd  0x58(%rax),%xmm5
lea    0xaa0(%rip),%rdi
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x50,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
push   %rax
mov    $0x7a1200,%edi
call   1040 <malloc@plt>
mov    %rax,%r14
mov    $0x7a1200,%edi
call   1040 <malloc@plt>
mov    %rax,%r15
mov    $0x1f40,%edi
call   1040 <malloc@plt>
mov    %rax,%r13
mov    $0x1f40,%edi
call   1040 <malloc@plt>
mov    %rax,%r12
mov    $0x1f40,%edi
call   1040 <malloc@plt>
mov    %rax,%rbx
mov    $0x1f40,%edi
call   1040 <malloc@plt>
mov    %rbx,%r11
lea    0x10(%r15),%rcx
lea    0x10(%r14),%rdx
lea    0x8(%r15),%rsi
lea    0x8(%r14),%rdi
xor    %r8d,%r8d
movsd  0xe6b(%rip),%xmm9
movsd  0xe6a(%rip),%xmm10
movsd  0xe6a(%rip),%xmm2
movdqa 0xe71(%rip),%xmm8
movapd 0xe79(%rip),%xmm4
movdqa 0xe81(%rip),%xmm5
movdqa 0xe89(%rip),%xmm6
jmp    11f9 <main+0xd9>
nopl   0x0(%rax)
add    $0x1f40,%rcx
add    $0x1f40,%rdx
add    $0x1f40,%rsi
add    $0x1f40,%rdi
cmp    $0x3e8,%r8
je     131c <main+0x1fc>
mov    %r8,%rbp
xorps  %xmm7,%xmm7
cvtsi2sd %ebp,%xmm7
movsd  %xmm7,0x0(%r13,%r8,8)
add    $0x1,%r8
movzwl %r8w,%ebx
shr    $0x3,%ebx
imul   $0x20c5,%ebx,%ebx
shr    $0x14,%ebx
xorps  %xmm0,%xmm0
cvtsi2sd %ebx,%xmm0
movapd %xmm0,%xmm3
mulsd  %xmm9,%xmm3
movsd  %xmm3,(%r12,%rbp,8)
mulsd  %xmm10,%xmm0
movsd  %xmm0,(%r11,%rbp,8)
imul   $0x1f40,%rbp,%rbp
lea    (%r15,%rbp,1),%r9
add    $0x1f40,%r9
lea    (%r14,%rbp,1),%rbx
cmp    %r9,%rbx
jae    12c0 <main+0x1a0>
lea    (%r15,%rbp,1),%rbx
add    %r14,%rbp
add    $0x1f40,%rbp
cmp    %rbp,%rbx
jae    12c0 <main+0x1a0>
xor    %ebx,%ebx
nop
xorps  %xmm0,%xmm0
cvtsi2sd %ebx,%xmm0
mulsd  %xmm7,%xmm0
divsd  %xmm2,%xmm0
movsd  %xmm0,-0x8(%rdi,%rbx,8)
movsd  %xmm0,-0x8(%rsi,%rbx,8)
lea    0x1(%rbx),%ebp
xorps  %xmm0,%xmm0
cvtsi2sd %ebp,%xmm0
mulsd  %xmm7,%xmm0
divsd  %xmm2,%xmm0
movsd  %xmm0,(%rdi,%rbx,8)
movsd  %xmm0,(%rsi,%rbx,8)
add    $0x2,%rbx
cmp    $0x3e8,%rbx
jne    1270 <main+0x150>
jmp    11d0 <main+0xb0>
nopl   0x0(%rax)
unpcklpd %xmm7,%xmm7
xor    %ebx,%ebx
movdqa %xmm8,%xmm1
nopl   0x0(%rax,%rax,1)
cvtdq2pd %xmm1,%xmm0
mulpd  %xmm7,%xmm0
divpd  %xmm4,%xmm0
movupd %xmm0,-0x10(%rdx,%rbx,8)
movdqa %xmm1,%xmm3
paddd  %xmm5,%xmm3
cvtdq2pd %xmm3,%xmm3
movupd %xmm0,-0x10(%rcx,%rbx,8)
mulpd  %xmm7,%xmm3
divpd  %xmm4,%xmm3
movupd %xmm3,(%rdx,%rbx,8)
movupd %xmm3,(%rcx,%rbx,8)
add    $0x4,%rbx
paddd  %xmm6,%xmm1
cmp    $0x3e8,%rbx
jne    12d0 <main+0x1b0>
jmp    11d0 <main+0xb0>
movsd  (%r11),%xmm0
movsd  %xmm0,(%r14)
movabs $0x3ff0000000000000,%rcx
mov    %rcx,(%r12)
movsd  (%r11),%xmm1
movsd  %xmm1,0x0(%r13)
mov    %r15,%rcx
add    $0x8,%rcx
mov    $0x1,%edi
mov    $0x1f40,%edx
movapd 0xd08(%rip),%xmm0
mov    %r14,%r8
mov    %r11,%r9
mov    %r14,%rsi
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax,%rax,1)
movsd  -0x8(%r12,%rdi,8),%xmm2
mulsd  %xmm1,%xmm1
mulsd  %xmm2,%xmm1
subsd  %xmm1,%xmm2
movsd  %xmm2,(%r12,%rdi,8)
movsd  (%r11,%rdi,8),%xmm1
movsd  %xmm1,(%r15,%rdi,8)
mov    %r9,%rbp
xor    %ebx,%ebx
nopw   0x0(%rax,%rax,1)
movsd  0x0(%rbp),%xmm1
mulsd  (%rsi,%rbx,1),%xmm1
addsd  (%rcx,%rbx,1),%xmm1
movsd  %xmm1,0x1f40(%rcx,%rbx,1)
add    $0x1f40,%rbx
add    $0xfffffffffffffff8,%rbp
cmp    %rbx,%rdx
jne    13a0 <main+0x280>
imul   $0x3e9,%rdi,%r10
movsd  (%r15,%r10,8),%xmm1
xorpd  %xmm0,%xmm1
mulsd  (%r12,%rdi,8),%xmm1
movsd  %xmm1,0x0(%r13,%rdi,8)
mov    %r8,%rbx
xor    %ebp,%ebp
nopl   0x0(%rax,%rax,1)
mulsd  (%rbx),%xmm1
addsd  (%rsi,%rbp,1),%xmm1
movsd  %xmm1,0x8(%rsi,%rbp,1)
movsd  0x0(%r13,%rdi,8),%xmm1
add    $0x1f40,%rbp
add    $0xffffffffffffe0c0,%rbx
cmp    %rbp,%rdx
jne    13f0 <main+0x2d0>
movsd  %xmm1,(%r14,%r10,8)
lea    0x1(%rdi),%rbx
cmp    $0x3e8,%rbx
je     1455 <main+0x335>
movsd  0x0(%r13,%rdi,8),%xmm1
add    $0x8,%rsi
add    $0x8,%rcx
add    $0x8,%r9
add    $0x1f40,%rdx
add    $0x1f48,%r8
mov    %rbx,%rdi
jmp    1370 <main+0x250>
mov    %r14,%rcx
add    $0x1f38,%rcx
mov    $0x3,%edx
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
movsd  (%rcx),%xmm0
movsd  %xmm0,-0x18(%rax,%rdx,8)
movsd  0x1f40(%rcx),%xmm0
movsd  %xmm0,-0x10(%rax,%rdx,8)
movsd  0x3e80(%rcx),%xmm0
movsd  %xmm0,-0x8(%rax,%rdx,8)
movsd  0x5dc0(%rcx),%xmm0
movsd  %xmm0,(%rax,%rdx,8)
add    $0x7d00,%rcx
add    $0x4,%rdx
cmp    $0x3eb,%rdx
jne    1470 <main+0x350>
movsd  0x58(%r14),%xmm0
movsd  0x58(%r15),%xmm1
movsd  0x58(%rax),%xmm2
movsd  0x58(%r13),%xmm3
movsd  0x58(%r11),%xmm4
movsd  0x58(%r12),%xmm5
lea    0xb8e(%rip),%rdi
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x8,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@.str = [19 x i8] c"%f %f %f %f %f %f\0A\00"
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
%6 = alloca i32
%7 = alloca i32
%8 = alloca i32
%9 = alloca i32
%10 = alloca double*
%11 = alloca double*
%12 = alloca double*
%13 = alloca double*
%14 = alloca double*
%15 = alloca double*
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
store i32 1000, i32* %9
%16 = call i64 @malloc(i32 8000000)
%17 = inttoptr i64 %16 to double*
store double* %17, double** %10
%18 = call i64 @malloc(i32 8000000)
%19 = inttoptr i64 %18 to double*
store double* %19, double** %11
%20 = call i64 @malloc(i32 8000)
%21 = inttoptr i64 %20 to double*
store double* %21, double** %12
%22 = call i64 @malloc(i32 8000)
%23 = inttoptr i64 %22 to double*
store double* %23, double** %13
%24 = call i64 @malloc(i32 8000)
%25 = inttoptr i64 %24 to double*
store double* %25, double** %14
%26 = call i64 @malloc(i32 8000)
%27 = inttoptr i64 %26 to double*
store double* %27, double** %15
store i32 0, i32* %6
br label %28
28: ; preds = %100, %2
%29 = load i32, i32* %6
%30 = load i32, i32* %9
%31 = icmp slt i32 %29, %30
br i1 %31, label %32, label %103
32: ; preds = %28
%33 = load i32, i32* %6
%34 = sitofp i32 %33 to double
%35 = load double*, double** %12
%36 = load i32, i32* %6
%37 = sext i32 %36 to i64
%38 = getelementptr inbounds double, double* %35, i64 %37
store double %34, double* %38
%39 = load i32, i32* %6
%40 = add nsw i32 %39, 1
%41 = load i32, i32* %9
%42 = sdiv i32 %40, %41
%43 = sitofp i32 %42 to double
%44 = fdiv double %43, 2.000000e+00
%45 = load double*, double** %13
%46 = load i32, i32* %6
%47 = sext i32 %46 to i64
%48 = getelementptr inbounds double, double* %45, i64 %47
store double %44, double* %48
%49 = load i32, i32* %6
%50 = add nsw i32 %49, 1
%51 = load i32, i32* %9
%52 = sdiv i32 %50, %51
%53 = sitofp i32 %52 to double
%54 = fdiv double %53, 4.000000e+00
%55 = load double*, double** %14
%56 = load i32, i32* %6
%57 = sext i32 %56 to i64
%58 = getelementptr inbounds double, double* %55, i64 %57
store double %54, double* %58
store i32 0, i32* %7
br label %59
59: ; preds = %96, %32
%60 = load i32, i32* %7
%61 = load i32, i32* %9
%62 = icmp slt i32 %60, %61
br i1 %62, label %63, label %99
63: ; preds = %59
%64 = load i32, i32* %6
%65 = sitofp i32 %64 to double
%66 = load i32, i32* %7
%67 = sitofp i32 %66 to double
%68 = fmul double %65, %67
%69 = load i32, i32* %9
%70 = sitofp i32 %69 to double
%71 = fdiv double %68, %70
%72 = load double*, double** %10
%73 = load i32, i32* %6
%74 = load i32, i32* %9
%75 = mul nsw i32 %73, %74
%76 = load i32, i32* %7
%77 = add nsw i32 %75, %76
%78 = sext i32 %77 to i64
%79 = getelementptr inbounds double, double* %72, i64 %78
store double %71, double* %79
%80 = load i32, i32* %6
%81 = sitofp i32 %80 to double
%82 = load i32, i32* %7
%83 = sitofp i32 %82 to double
%84 = fmul double %81, %83
%85 = load i32, i32* %9
%86 = sitofp i32 %85 to double
%87 = fdiv double %84, %86
%88 = load double*, double** %11
%89 = load i32, i32* %6
%90 = load i32, i32* %9
%91 = mul nsw i32 %89, %90
%92 = load i32, i32* %7
%93 = add nsw i32 %91, %92
%94 = sext i32 %93 to i64
%95 = getelementptr inbounds double, double* %88, i64 %94
store double %87, double* %95
br label %96
96: ; preds = %63
%97 = load i32, i32* %7
%98 = add nsw i32 %97, 1
store i32 %98, i32* %7
br label %59
99: ; preds = %59
br label %100
100: ; preds = %99
%101 = load i32, i32* %6
%102 = add nsw i32 %101, 1
store i32 %102, i32* %6
br label %28
103: ; preds = %28
%104 = load double*, double** %14
%105 = getelementptr inbounds double, double* %104, i64 0
%106 = load double, double* %105
%107 = load double*, double** %10
%108 = getelementptr inbounds double, double* %107, i64 0
store double %106, double* %108
%109 = load double*, double** %13
%110 = getelementptr inbounds double, double* %109, i64 0
store double 1.000000e+00, double* %110
%111 = load double*, double** %14
%112 = getelementptr inbounds double, double* %111, i64 0
%113 = load double, double* %112
%114 = load double*, double** %12
%115 = getelementptr inbounds double, double* %114, i64 0
store double %113, double* %115
store i32 1, i32* %8
br label %116
116: ; preds = %287, %103
%117 = load i32, i32* %8
%118 = icmp slt i32 %117, 1000
br i1 %118, label %119, label %290
119: ; preds = %116
%120 = load double*, double** %13
%121 = load i32, i32* %8
%122 = sub nsw i32 %121, 1
%123 = sext i32 %122 to i64
%124 = getelementptr inbounds double, double* %120, i64 %123
%125 = load double, double* %124
%126 = load double*, double** %12
%127 = load i32, i32* %8
%128 = sub nsw i32 %127, 1
%129 = sext i32 %128 to i64
%130 = getelementptr inbounds double, double* %126, i64 %129
%131 = load double, double* %130
%132 = load double*, double** %12
%133 = load i32, i32* %8
%134 = sub nsw i32 %133, 1
%135 = sext i32 %134 to i64
%136 = getelementptr inbounds double, double* %132, i64 %135
%137 = load double, double* %136
%138 = fmul double %131, %137
%139 = load double*, double** %13
%140 = load i32, i32* %8
%141 = sub nsw i32 %140, 1
%142 = sext i32 %141 to i64
%143 = getelementptr inbounds double, double* %139, i64 %142
%144 = load double, double* %143
%145 = fneg double %138
%146 = call double @llvm.fmuladd.f64(double %145, double %144, double %125)
%147 = load double*, double** %13
%148 = load i32, i32* %8
%149 = sext i32 %148 to i64
%150 = getelementptr inbounds double, double* %147, i64 %149
store double %146, double* %150
%151 = load double*, double** %14
%152 = load i32, i32* %8
%153 = sext i32 %152 to i64
%154 = getelementptr inbounds double, double* %151, i64 %153
%155 = load double, double* %154
%156 = load double*, double** %11
%157 = load i32, i32* %8
%158 = sext i32 %157 to i64
%159 = getelementptr inbounds double, double* %156, i64 %158
store double %155, double* %159
store i32 0, i32* %6
br label %160
160: ; preds = %203, %119
%161 = load i32, i32* %6
%162 = load i32, i32* %8
%163 = sub nsw i32 %162, 1
%164 = icmp sle i32 %161, %163
br i1 %164, label %165, label %206
165: ; preds = %160
%166 = load double*, double** %11
%167 = load i32, i32* %6
%168 = load i32, i32* %9
%169 = mul nsw i32 %167, %168
%170 = load i32, i32* %8
%171 = add nsw i32 %169, %170
%172 = sext i32 %171 to i64
%173 = getelementptr inbounds double, double* %166, i64 %172
%174 = load double, double* %173
%175 = load double*, double** %14
%176 = load i32, i32* %8
%177 = load i32, i32* %6
%178 = sub nsw i32 %176, %177
%179 = sub nsw i32 %178, 1
%180 = sext i32 %179 to i64
%181 = getelementptr inbounds double, double* %175, i64 %180
%182 = load double, double* %181
%183 = load double*, double** %10
%184 = load i32, i32* %6
%185 = load i32, i32* %9
%186 = mul nsw i32 %184, %185
%187 = load i32, i32* %8
%188 = add nsw i32 %186, %187
%189 = sub nsw i32 %188, 1
%190 = sext i32 %189 to i64
%191 = getelementptr inbounds double, double* %183, i64 %190
%192 = load double, double* %191
%193 = call double @llvm.fmuladd.f64(double %182, double %192, double %174)
%194 = load double*, double** %11
%195 = load i32, i32* %6
%196 = add nsw i32 %195, 1
%197 = load i32, i32* %9
%198 = mul nsw i32 %196, %197
%199 = load i32, i32* %8
%200 = add nsw i32 %198, %199
%201 = sext i32 %200 to i64
%202 = getelementptr inbounds double, double* %194, i64 %201
store double %193, double* %202
br label %203
203: ; preds = %165
%204 = load i32, i32* %6
%205 = add nsw i32 %204, 1
store i32 %205, i32* %6
br label %160
206: ; preds = %160
%207 = load double*, double** %11
%208 = load i32, i32* %8
%209 = load i32, i32* %9
%210 = mul nsw i32 %208, %209
%211 = load i32, i32* %8
%212 = add nsw i32 %210, %211
%213 = sext i32 %212 to i64
%214 = getelementptr inbounds double, double* %207, i64 %213
%215 = load double, double* %214
%216 = fneg double %215
%217 = load double*, double** %13
%218 = load i32, i32* %8
%219 = sext i32 %218 to i64
%220 = getelementptr inbounds double, double* %217, i64 %219
%221 = load double, double* %220
%222 = fmul double %216, %221
%223 = load double*, double** %12
%224 = load i32, i32* %8
%225 = sext i32 %224 to i64
%226 = getelementptr inbounds double, double* %223, i64 %225
store double %222, double* %226
store i32 0, i32* %6
br label %227
227: ; preds = %270, %206
%228 = load i32, i32* %6
%229 = load i32, i32* %8
%230 = sub nsw i32 %229, 1
%231 = icmp sle i32 %228, %230
br i1 %231, label %232, label %273
232: ; preds = %227
%233 = load double*, double** %10
%234 = load i32, i32* %6
%235 = load i32, i32* %9
%236 = mul nsw i32 %234, %235
%237 = load i32, i32* %8
%238 = add nsw i32 %236, %237
%239 = sub nsw i32 %238, 1
%240 = sext i32 %239 to i64
%241 = getelementptr inbounds double, double* %233, i64 %240
%242 = load double, double* %241
%243 = load double*, double** %12
%244 = load i32, i32* %8
%245 = sext i32 %244 to i64
%246 = getelementptr inbounds double, double* %243, i64 %245
%247 = load double, double* %246
%248 = load double*, double** %10
%249 = load i32, i32* %8
%250 = load i32, i32* %6
%251 = sub nsw i32 %249, %250
%252 = sub nsw i32 %251, 1
%253 = load i32, i32* %9
%254 = mul nsw i32 %252, %253
%255 = load i32, i32* %8
%256 = add nsw i32 %254, %255
%257 = sub nsw i32 %256, 1
%258 = sext i32 %257 to i64
%259 = getelementptr inbounds double, double* %248, i64 %258
%260 = load double, double* %259
%261 = call double @llvm.fmuladd.f64(double %247, double %260, double %242)
%262 = load double*, double** %10
%263 = load i32, i32* %6
%264 = load i32, i32* %9
%265 = mul nsw i32 %263, %264
%266 = load i32, i32* %8
%267 = add nsw i32 %265, %266
%268 = sext i32 %267 to i64
%269 = getelementptr inbounds double, double* %262, i64 %268
store double %261, double* %269
br label %270
270: ; preds = %232
%271 = load i32, i32* %6
%272 = add nsw i32 %271, 1
store i32 %272, i32* %6
br label %227
273: ; preds = %227
%274 = load double*, double** %12
%275 = load i32, i32* %8
%276 = sext i32 %275 to i64
%277 = getelementptr inbounds double, double* %274, i64 %276
%278 = load double, double* %277
%279 = load double*, double** %10
%280 = load i32, i32* %8
%281 = load i32, i32* %9
%282 = mul nsw i32 %280, %281
%283 = load i32, i32* %8
%284 = add nsw i32 %282, %283
%285 = sext i32 %284 to i64
%286 = getelementptr inbounds double, double* %279, i64 %285
store double %278, double* %286
br label %287
287: ; preds = %273
%288 = load i32, i32* %8
%289 = add nsw i32 %288, 1
store i32 %289, i32* %8
br label %116
290: ; preds = %116
store i32 0, i32* %6
br label %291
291: ; preds = %308, %290
%292 = load i32, i32* %6
%293 = icmp slt i32 %292, 1000
br i1 %293, label %294, label %311
294: ; preds = %291
%295 = load double*, double** %10
%296 = load i32, i32* %6
%297 = load i32, i32* %9
%298 = mul nsw i32 %296, %297
%299 = add nsw i32 %298, 1000
%300 = sub nsw i32 %299, 1
%301 = sext i32 %300 to i64
%302 = getelementptr inbounds double, double* %295, i64 %301
%303 = load double, double* %302
%304 = load double*, double** %15
%305 = load i32, i32* %6
%306 = sext i32 %305 to i64
%307 = getelementptr inbounds double, double* %304, i64 %306
store double %303, double* %307
br label %308
308: ; preds = %294
%309 = load i32, i32* %6
%310 = add nsw i32 %309, 1
store i32 %310, i32* %6
br label %291
311: ; preds = %291
%312 = load double*, double** %10
%313 = getelementptr inbounds double, double* %312, i64 11
%314 = load double, double* %313
%315 = load double*, double** %11
%316 = getelementptr inbounds double, double* %315, i64 11
%317 = load double, double* %316
%318 = load double*, double** %15
%319 = getelementptr inbounds double, double* %318, i64 11
%320 = load double, double* %319
%321 = load double*, double** %12
%322 = getelementptr inbounds double, double* %321, i64 11
%323 = load double, double* %322
%324 = load double*, double** %14
%325 = getelementptr inbounds double, double* %324, i64 11
%326 = load double, double* %325
%327 = load double*, double** %13
%328 = getelementptr inbounds double, double* %327, i64 11
%329 = load double, double* %328
%330 = call i32 @printf(i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str, i64 0, i64 0), double %314, double %317, double %320, double %323, double %326, double %329)
ret i32 0
}

LLVM IR (-O2):
@.str = [19 x i8] c"%f %f %f %f %f %f\0A\00"
define i32 @main(i32 %0, i8** nocapture readnone %1) {
%3 = tail call i64 @malloc(i32 8000000)
%4 = inttoptr i64 %3 to double*
%5 = tail call i64 @malloc(i32 8000000)
%6 = inttoptr i64 %5 to double*
%7 = tail call i64 @malloc(i32 8000)
%8 = inttoptr i64 %7 to double*
%9 = tail call i64 @malloc(i32 8000)
%10 = inttoptr i64 %9 to double*
%11 = tail call i64 @malloc(i32 8000)
%12 = inttoptr i64 %11 to double*
%13 = tail call i64 @malloc(i32 8000)
br label %16
14: ; preds = %42, %66
%15 = icmp eq i64 %23, 1000
br i1 %15, label %85, label %16
16: ; preds = %2, %14
%17 = phi i64 [ 0, %2 ], [ %23, %14 ]
%18 = mul nuw nsw i64 %17, 1000
%19 = add nuw i64 %18, 1000
%20 = trunc i64 %17 to i32
%21 = sitofp i32 %20 to double
%22 = getelementptr inbounds double, double* %8, i64 %17
store double %21, double* %22
%23 = add nuw nsw i64 %17, 1
%24 = trunc i64 %23 to i16
%25 = udiv i16 %24, 1000
%26 = uitofp i16 %25 to double
%27 = fmul double %26, 5.000000e-01
%28 = getelementptr inbounds double, double* %10, i64 %17
store double %27, double* %28
%29 = fmul double %26, 2.500000e-01
%30 = getelementptr inbounds double, double* %12, i64 %17
store double %29, double* %30
%31 = mul nuw nsw i64 %17, 1000
%32 = getelementptr double, double* %6, i64 %19
%33 = getelementptr double, double* %6, i64 %18
%34 = getelementptr double, double* %4, i64 %19
%35 = getelementptr double, double* %4, i64 %18
%36 = icmp ult double* %35, %32
%37 = icmp ult double* %33, %34
%38 = and i1 %36, %37
br i1 %38, label %66, label %39
39: ; preds = %16
%40 = insertelement <2 x double> poison, double %21, i64 0
%41 = shufflevector <2 x double> %40, <2 x double> poison, <2 x i32> zeroinitializer
br label %42
42: ; preds = %42, %39
%43 = phi i64 [ 0, %39 ], [ %63, %42 ]
%44 = phi <2 x i32> [ <i32 0, i32 1>, %39 ], [ %64, %42 ]
%45 = sitofp <2 x i32> %44 to <2 x double>
%46 = fmul <2 x double> %41, %45
%47 = fdiv <2 x double> %46, <double 1.000000e+03, double 1.000000e+03>
%48 = add nuw nsw i64 %43, %31
%49 = getelementptr inbounds double, double* %4, i64 %48
%50 = bitcast double* %49 to <2 x double>*
store <2 x double> %47, <2 x double>* %50
%51 = getelementptr inbounds double, double* %6, i64 %48
%52 = bitcast double* %51 to <2 x double>*
store <2 x double> %47, <2 x double>* %52
%53 = or i64 %43, 2
%54 = add <2 x i32> %44, <i32 2, i32 2>
%55 = sitofp <2 x i32> %54 to <2 x double>
%56 = fmul <2 x double> %41, %55
%57 = fdiv <2 x double> %56, <double 1.000000e+03, double 1.000000e+03>
%58 = add nuw nsw i64 %53, %31
%59 = getelementptr inbounds double, double* %4, i64 %58
%60 = bitcast double* %59 to <2 x double>*
store <2 x double> %57, <2 x double>* %60
%61 = getelementptr inbounds double, double* %6, i64 %58
%62 = bitcast double* %61 to <2 x double>*
store <2 x double> %57, <2 x double>* %62
%63 = add nuw nsw i64 %43, 4
%64 = add <2 x i32> %44, <i32 4, i32 4>
%65 = icmp eq i64 %63, 1000
br i1 %65, label %14, label %42
66: ; preds = %16, %66
%67 = phi i64 [ %83, %66 ], [ 0, %16 ]
%68 = trunc i64 %67 to i32
%69 = sitofp i32 %68 to double
%70 = fmul double %21, %69
%71 = fdiv double %70, 1.000000e+03
%72 = add nuw nsw i64 %67, %31
%73 = getelementptr inbounds double, double* %4, i64 %72
store double %71, double* %73
%74 = getelementptr inbounds double, double* %6, i64 %72
store double %71, double* %74
%75 = or i64 %67, 1
%76 = trunc i64 %75 to i32
%77 = sitofp i32 %76 to double
%78 = fmul double %21, %77
%79 = fdiv double %78, 1.000000e+03
%80 = add nuw nsw i64 %75, %31
%81 = getelementptr inbounds double, double* %4, i64 %80
store double %79, double* %81
%82 = getelementptr inbounds double, double* %6, i64 %80
store double %79, double* %82
%83 = add nuw nsw i64 %67, 2
%84 = icmp eq i64 %83, 1000
br i1 %84, label %14, label %66
85: ; preds = %14
%86 = load double, double* %12
store double %86, double* %4
store double 1.000000e+00, double* %10
%87 = load double, double* %12
store double %87, double* %8
br label %88
88: ; preds = %151, %85
%89 = phi double [ %87, %85 ], [ %152, %151 ]
%90 = phi i64 [ 1, %85 ], [ %149, %151 ]
%91 = add nsw i64 %90, -1
%92 = getelementptr inbounds double, double* %10, i64 %91
%93 = load double, double* %92
%94 = fneg double %89
%95 = fmul double %89, %94
%96 = tail call double @llvm.fmuladd.f64(double %95, double %93, double %93)
%97 = getelementptr inbounds double, double* %10, i64 %90
store double %96, double* %97
%98 = getelementptr inbounds double, double* %12, i64 %90
%99 = load double, double* %98
%100 = getelementptr inbounds double, double* %6, i64 %90
store double %99, double* %100
br label %101
101: ; preds = %88, %101
%102 = phi i64 [ 0, %88 ], [ %115, %101 ]
%103 = mul nuw nsw i64 %102, 1000
%104 = add nuw nsw i64 %103, %90
%105 = getelementptr inbounds double, double* %6, i64 %104
%106 = load double, double* %105
%107 = xor i64 %102, -1
%108 = add nsw i64 %90, %107
%109 = getelementptr inbounds double, double* %12, i64 %108
%110 = load double, double* %109
%111 = add nsw i64 %104, -1
%112 = getelementptr inbounds double, double* %4, i64 %111
%113 = load double, double* %112
%114 = tail call double @llvm.fmuladd.f64(double %110, double %113, double %106)
%115 = add nuw nsw i64 %102, 1
%116 = mul nuw nsw i64 %115, 1000
%117 = add nuw nsw i64 %116, %90
%118 = getelementptr inbounds double, double* %6, i64 %117
store double %114, double* %118
%119 = icmp eq i64 %115, %90
br i1 %119, label %120, label %101
120: ; preds = %101
%121 = mul nuw nsw i64 %90, 1001
%122 = getelementptr inbounds double, double* %6, i64 %121
%123 = load double, double* %122
%124 = fneg double %123
%125 = load double, double* %97
%126 = fmul double %125, %124
%127 = getelementptr inbounds double, double* %8, i64 %90
store double %126, double* %127
br label %128
128: ; preds = %128, %120
%129 = phi double [ %126, %120 ], [ %146, %128 ]
%130 = phi i64 [ 0, %120 ], [ %144, %128 ]
%131 = mul nuw nsw i64 %130, 1000
%132 = add nuw nsw i64 %131, %90
%133 = add nsw i64 %132, -1
%134 = getelementptr inbounds double, double* %4, i64 %133
%135 = load double, double* %134
%136 = xor i64 %130, -1
%137 = add nsw i64 %90, %136
%138 = mul nsw i64 %137, 1000
%139 = add nsw i64 %91, %138
%140 = getelementptr inbounds double, double* %4, i64 %139
%141 = load double, double* %140
%142 = tail call double @llvm.fmuladd.f64(double %129, double %141, double %135)
%143 = getelementptr inbounds double, double* %4, i64 %132
store double %142, double* %143
%144 = add nuw nsw i64 %130, 1
%145 = icmp eq i64 %144, %90
%146 = load double, double* %127
br i1 %145, label %147, label %128
147: ; preds = %128
%148 = getelementptr inbounds double, double* %4, i64 %121
store double %146, double* %148
%149 = add nuw nsw i64 %90, 1
%150 = icmp eq i64 %149, 1000
br i1 %150, label %153, label %151
151: ; preds = %147
%152 = load double, double* %127
br label %88
153: ; preds = %147
%154 = inttoptr i64 %13 to double*
br label %155
155: ; preds = %155, %153
%156 = phi i64 [ 0, %153 ], [ %180, %155 ]
%157 = mul nuw nsw i64 %156, 1000
%158 = add nuw nsw i64 %157, 999
%159 = getelementptr inbounds double, double* %4, i64 %158
%160 = load double, double* %159
%161 = getelementptr inbounds double, double* %154, i64 %156
store double %160, double* %161
%162 = or i64 %156, 1
%163 = mul nuw nsw i64 %162, 1000
%164 = add nuw nsw i64 %163, 999
%165 = getelementptr inbounds double, double* %4, i64 %164
%166 = load double, double* %165
%167 = getelementptr inbounds double, double* %154, i64 %162
store double %166, double* %167
%168 = or i64 %156, 2
%169 = mul nuw nsw i64 %168, 1000
%170 = add nuw nsw i64 %169, 999
%171 = getelementptr inbounds double, double* %4, i64 %170
%172 = load double, double* %171
%173 = getelementptr inbounds double, double* %154, i64 %168
store double %172, double* %173
%174 = or i64 %156, 3
%175 = mul nuw nsw i64 %174, 1000
%176 = add nuw nsw i64 %175, 999
%177 = getelementptr inbounds double, double* %4, i64 %176
%178 = load double, double* %177
%179 = getelementptr inbounds double, double* %154, i64 %174
store double %178, double* %179
%180 = add nuw nsw i64 %156, 4
%181 = icmp eq i64 %180, 1000
br i1 %181, label %182, label %155
182: ; preds = %155
%183 = getelementptr inbounds double, double* %4, i64 11
%184 = load double, double* %183
%185 = getelementptr inbounds double, double* %6, i64 11
%186 = load double, double* %185
%187 = getelementptr inbounds double, double* %154, i64 11
%188 = load double, double* %187
%189 = getelementptr inbounds double, double* %8, i64 11
%190 = load double, double* %189
%191 = getelementptr inbounds double, double* %12, i64 11
%192 = load double, double* %191
%193 = getelementptr inbounds double, double* %10, i64 11
%194 = load double, double* %193
%195 = tail call i32 @printf(i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str, i64 0, i64 0), double %184, double %186, double %188, double %190, double %192, double %194)
ret i32 0
}