#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 */
int /*<<< orphan*/ fftc1(double *, int, int);
int /*<<< orphan*/ free(double *);
scalar_t__ malloc(int);
int AutoPowerSpectrum(double data[], int framewidth, double dt,
                      double autopow[], double *df) {
  double *spectre;
  double *module;
  double *hmodule;
  int i, di;
  spectre = (double *)malloc((framewidth * 2) * sizeof(double));
  module = (double *)malloc(framewidth * sizeof(double));
  hmodule = (double *)malloc((framewidth / 2) * sizeof(double));
  i = 0;
  while (i < framewidth * 2) {
    spectre[i] = 0.0;
    i++;
  }
  i = 0;
  di = 0;
  while (i < framewidth * 2 - 2) {
    spectre[i] = data[di++];
    i++;
    spectre[i] = 0.0;
    i++;
  }
  fftc1(spectre, framewidth, +1);
  i = 0;
  di = 0;
  while (i < framewidth / 2) {
    module[i] = spectre[di] * spectre[di];
    di++;
    module[i] = module[i] + spectre[di] * spectre[di];
    di++;
    i++;
  }
  i = 0;
  hmodule[i] = module[i];
  i++;
  while (i < framewidth / 2) {
    hmodule[i] = 2. * module[i];
    i++;
  }
  i = 0;
  while (i < framewidth / 2) {
    autopow[i] = hmodule[i] / (framewidth * framewidth);
    i++;
  }
  free(spectre);
  free(module);
  free(hmodule);
  return (0);
}


x86 assembly (clang, -O0):
<AutoPowerSpectrum>:
push   %rbp
mov    %rsp,%rbp
sub    $0x60,%rsp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
movsd  %xmm0,-0x18(%rbp)
mov    %rdx,-0x20(%rbp)
mov    %rcx,-0x28(%rbp)
mov    -0xc(%rbp),%eax
shl    $0x1,%eax
cltq
shl    $0x3,%rax
mov    %eax,%edi
call   1050 <malloc@plt>
mov    %rax,-0x30(%rbp)
movslq -0xc(%rbp),%rax
shl    $0x3,%rax
mov    %eax,%edi
call   1050 <malloc@plt>
mov    %rax,-0x38(%rbp)
mov    -0xc(%rbp),%eax
mov    $0x2,%ecx
cltd
idiv   %ecx
cltq
shl    $0x3,%rax
mov    %eax,%edi
call   1050 <malloc@plt>
mov    %rax,-0x40(%rbp)
movl   $0x0,-0x44(%rbp)
mov    -0x44(%rbp),%eax
mov    -0xc(%rbp),%ecx
shl    $0x1,%ecx
cmp    %ecx,%eax
jge    11c8 <AutoPowerSpectrum+0x98>
mov    -0x30(%rbp),%rax
movslq -0x44(%rbp),%rcx
xorps  %xmm0,%xmm0
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x44(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x44(%rbp)
jmp    1199 <AutoPowerSpectrum+0x69>
movl   $0x0,-0x44(%rbp)
movl   $0x0,-0x48(%rbp)
mov    -0x44(%rbp),%eax
mov    -0xc(%rbp),%ecx
shl    $0x1,%ecx
sub    $0x2,%ecx
cmp    %ecx,%eax
jge    1235 <AutoPowerSpectrum+0x105>
mov    -0x8(%rbp),%rax
mov    -0x48(%rbp),%ecx
mov    %ecx,%edx
add    $0x1,%edx
mov    %edx,-0x48(%rbp)
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x30(%rbp),%rax
movslq -0x44(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x44(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x44(%rbp)
mov    -0x30(%rbp),%rax
movslq -0x44(%rbp),%rcx
xorps  %xmm0,%xmm0
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x44(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x44(%rbp)
jmp    11d6 <AutoPowerSpectrum+0xa6>
mov    -0x30(%rbp),%rdi
mov    -0xc(%rbp),%esi
mov    $0x1,%edx
call   1040 <fftc1@plt>
movl   $0x0,-0x44(%rbp)
movl   $0x0,-0x48(%rbp)
mov    -0x44(%rbp),%eax
mov    %eax,-0x4c(%rbp)
mov    -0xc(%rbp),%eax
mov    $0x2,%ecx
cltd
idiv   %ecx
mov    %eax,%ecx
mov    -0x4c(%rbp),%eax
cmp    %ecx,%eax
jge    12f5 <AutoPowerSpectrum+0x1c5>
mov    -0x30(%rbp),%rax
movslq -0x48(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x30(%rbp),%rax
movslq -0x48(%rbp),%rcx
mulsd  (%rax,%rcx,8),%xmm0
mov    -0x38(%rbp),%rax
movslq -0x44(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x48(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x48(%rbp)
mov    -0x38(%rbp),%rax
movslq -0x44(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm1
mov    -0x30(%rbp),%rax
movslq -0x48(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x30(%rbp),%rax
movslq -0x48(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
mov    -0x38(%rbp),%rax
movslq -0x44(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x48(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x48(%rbp)
mov    -0x44(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x44(%rbp)
jmp    1254 <AutoPowerSpectrum+0x124>
movl   $0x0,-0x44(%rbp)
mov    -0x38(%rbp),%rax
movslq -0x44(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x40(%rbp),%rax
movslq -0x44(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x44(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x44(%rbp)
mov    -0x44(%rbp),%eax
mov    %eax,-0x50(%rbp)
mov    -0xc(%rbp),%eax
mov    $0x2,%ecx
cltd
idiv   %ecx
mov    %eax,%ecx
mov    -0x50(%rbp),%eax
cmp    %ecx,%eax
jge    136d <AutoPowerSpectrum+0x23d>
mov    -0x38(%rbp),%rax
movslq -0x44(%rbp),%rcx
movsd  0xcb3(%rip),%xmm0
mulsd  (%rax,%rcx,8),%xmm0
mov    -0x40(%rbp),%rax
movslq -0x44(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x44(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x44(%rbp)
jmp    131f <AutoPowerSpectrum+0x1ef>
movl   $0x0,-0x44(%rbp)
mov    -0x44(%rbp),%eax
mov    %eax,-0x54(%rbp)
mov    -0xc(%rbp),%eax
mov    $0x2,%ecx
cltd
idiv   %ecx
mov    %eax,%ecx
mov    -0x54(%rbp),%eax
cmp    %ecx,%eax
jge    13c9 <AutoPowerSpectrum+0x299>
mov    -0x40(%rbp),%rax
movslq -0x44(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0xc(%rbp),%eax
imul   -0xc(%rbp),%eax
cvtsi2sd %eax,%xmm1
divsd  %xmm1,%xmm0
mov    -0x20(%rbp),%rax
movslq -0x44(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x44(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x44(%rbp)
jmp    1374 <AutoPowerSpectrum+0x244>
mov    -0x30(%rbp),%rdi
call   1030 <free@plt>
mov    -0x38(%rbp),%rdi
call   1030 <free@plt>
mov    -0x40(%rbp),%rdi
call   1030 <free@plt>
xor    %eax,%eax
add    $0x60,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<AutoPowerSpectrum>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x18,%rsp
mov    %rdx,0x10(%rsp)
mov    %esi,%r13d
mov    %rdi,%rbp
mov    %esi,%edi
shl    $0x4,%edi
call   1060 <malloc@plt>
mov    %rax,%r15
lea    0x0(,%r13,8),%edi
call   1060 <malloc@plt>
mov    %rax,%r14
mov    %r13d,%eax
shr    $0x1f,%eax
add    %r13d,%eax
sar    %eax
mov    %rax,0x8(%rsp)
lea    0x0(,%rax,8),%edi
call   1060 <malloc@plt>
mov    %rax,%r12
test   %r13d,%r13d
jle    11be <AutoPowerSpectrum+0x7e>
lea    0x0(%r13,%r13,1),%ebx
cmp    $0x2,%ebx
mov    $0x1,%edx
cmovge %ebx,%edx
shl    $0x3,%rdx
mov    %r15,%rdi
xor    %esi,%esi
call   1040 <memset@plt>
cmp    $0x1,%r13d
jne    1202 <AutoPowerSpectrum+0xc2>
mov    %r15,%rdi
mov    %r13d,%esi
mov    $0x1,%edx
call   1050 <fftc1@plt>
movsd  (%r14),%xmm0
movsd  %xmm0,(%r12)
mov    %r15,%rdi
call   1030 <free@plt>
mov    %r14,%rdi
call   1030 <free@plt>
mov    %r12,%rdi
call   1030 <free@plt>
xor    %eax,%eax
add    $0x18,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret
add    $0xfffffffe,%ebx
cmp    $0x3,%ebx
mov    $0x2,%ecx
cmovge %ebx,%ecx
add    $0xffffffff,%ecx
mov    %ecx,%eax
shr    %eax
add    $0x1,%eax
cmp    $0x6,%ecx
jb     1246 <AutoPowerSpectrum+0x106>
lea    0x0(,%rax,8),%rcx
add    %rbp,%rcx
cmp    %rcx,%r15
jae    12e3 <AutoPowerSpectrum+0x1a3>
mov    %rax,%rcx
shl    $0x4,%rcx
add    %r15,%rcx
cmp    %rbp,%rcx
jbe    12e3 <AutoPowerSpectrum+0x1a3>
xor    %edx,%edx
xor    %ecx,%ecx
mov    %rcx,%rsi
not    %rsi
test   $0x1,%al
je     127c <AutoPowerSpectrum+0x13c>
movq   0x0(%rbp,%rcx,8),%xmm0
or     $0x1,%rcx
lea    0x0(,%rdx,8),%rdi
movq   %xmm0,(%r15,%rdx,8)
or     $0x8,%rdi
movq   $0x0,(%r15,%rdi,1)
add    $0x2,%rdx
add    %rax,%rsi
je     13e2 <AutoPowerSpectrum+0x2a2>
cs nopw 0x0(%rax,%rax,1)
nop
movsd  0x0(%rbp,%rcx,8),%xmm0
movsd  %xmm0,(%r15,%rdx,8)
lea    0x0(,%rdx,8),%rsi
or     $0x8,%rsi
movq   $0x0,(%r15,%rsi,1)
movq   0x8(%rbp,%rcx,8),%xmm0
add    $0x2,%rcx
movq   %xmm0,0x10(%r15,%rdx,8)
lea    0x10(,%rdx,8),%rsi
or     $0x8,%rsi
movq   $0x0,(%r15,%rsi,1)
add    $0x4,%rdx
cmp    %rcx,%rax
jne    1290 <AutoPowerSpectrum+0x150>
jmp    13e2 <AutoPowerSpectrum+0x2a2>
mov    %eax,%ecx
and    $0x7ffffffc,%ecx
lea    -0x4(%rcx),%rdx
mov    %rdx,%rsi
shr    $0x2,%rsi
add    $0x1,%rsi
test   %rdx,%rdx
je     1590 <AutoPowerSpectrum+0x450>
mov    %rsi,%rdi
and    $0xfffffffffffffffe,%rdi
lea    0x60(%r15),%rbx
xor    %edx,%edx
pxor   %xmm0,%xmm0
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
movdqu 0x0(%rbp,%rdx,8),%xmm1
movdqu 0x10(%rbp,%rdx,8),%xmm2
movq   %xmm1,%xmm3
punpckhqdq %xmm0,%xmm1
movdqu %xmm1,-0x50(%rbx)
movdqu %xmm3,-0x60(%rbx)
movq   %xmm2,%xmm1
punpckhqdq %xmm0,%xmm2
movdqu %xmm2,-0x30(%rbx)
movdqu %xmm1,-0x40(%rbx)
movdqu 0x20(%rbp,%rdx,8),%xmm1
movdqu 0x30(%rbp,%rdx,8),%xmm2
movq   %xmm1,%xmm3
punpckhqdq %xmm0,%xmm1
movdqu %xmm1,-0x10(%rbx)
movdqu %xmm3,-0x20(%rbx)
movq   %xmm2,%xmm1
punpckhqdq %xmm0,%xmm2
movdqu %xmm2,0x10(%rbx)
movdqu %xmm1,(%rbx)
add    $0x8,%rdx
sub    $0xffffffffffffff80,%rbx
add    $0xfffffffffffffffe,%rdi
jne    1320 <AutoPowerSpectrum+0x1e0>
test   $0x1,%sil
je     13d9 <AutoPowerSpectrum+0x299>
movdqu 0x0(%rbp,%rdx,8),%xmm0
movdqu 0x10(%rbp,%rdx,8),%xmm1
shl    $0x4,%rdx
mov    %rdx,%rsi
or     $0x28,%rsi
movq   %xmm0,%xmm2
pxor   %xmm3,%xmm3
punpckhqdq %xmm3,%xmm0
movdqu %xmm0,0x10(%r15,%rdx,1)
movdqu %xmm2,(%r15,%rdx,1)
movq   %xmm1,%xmm0
punpckhqdq %xmm3,%xmm1
movdqu %xmm1,0x8(%r15,%rsi,1)
movdqu %xmm0,-0x8(%r15,%rsi,1)
cmp    %rax,%rcx
jne    14f5 <AutoPowerSpectrum+0x3b5>
mov    %r15,%rdi
mov    %r13d,%esi
mov    $0x1,%edx
call   1050 <fftc1@plt>
cmp    $0x1,%r13d
mov    0x10(%rsp),%rbp
mov    0x8(%rsp),%r8
je     15e4 <AutoPowerSpectrum+0x4a4>
mov    %r8d,%eax
cmp    $0x2,%r8d
jb     142f <AutoPowerSpectrum+0x2ef>
mov    %rax,%rcx
shl    $0x4,%rcx
add    %r15,%rcx
cmp    %rcx,%r14
jae    14fe <AutoPowerSpectrum+0x3be>
lea    (%r14,%rax,8),%rcx
cmp    %rcx,%r15
jae    14fe <AutoPowerSpectrum+0x3be>
xor    %ecx,%ecx
xor    %edx,%edx
mov    %rcx,%rsi
not    %rsi
test   $0x1,%al
je     1475 <AutoPowerSpectrum+0x335>
lea    0x0(,%rdx,8),%rdi
movsd  (%r15,%rdx,8),%xmm0
mulsd  %xmm0,%xmm0
movsd  %xmm0,(%r14,%rcx,8)
or     $0x8,%rdi
movsd  (%r15,%rdi,1),%xmm1
mulsd  %xmm1,%xmm1
addsd  %xmm0,%xmm1
movsd  %xmm1,(%r14,%rcx,8)
add    $0x2,%rdx
or     $0x1,%rcx
add    %rax,%rsi
je     15e4 <AutoPowerSpectrum+0x4a4>
xchg   %ax,%ax
movsd  (%r15,%rdx,8),%xmm0
mulsd  %xmm0,%xmm0
movsd  %xmm0,(%r14,%rcx,8)
lea    0x0(,%rdx,8),%rsi
or     $0x8,%rsi
movsd  (%r15,%rsi,1),%xmm1
mulsd  %xmm1,%xmm1
addsd  %xmm0,%xmm1
movsd  %xmm1,(%r14,%rcx,8)
movsd  0x10(%r15,%rdx,8),%xmm0
mulsd  %xmm0,%xmm0
movsd  %xmm0,0x8(%r14,%rcx,8)
lea    0x10(,%rdx,8),%rsi
or     $0x8,%rsi
movsd  (%r15,%rsi,1),%xmm1
mulsd  %xmm1,%xmm1
addsd  %xmm0,%xmm1
movsd  %xmm1,0x8(%r14,%rcx,8)
add    $0x2,%rcx
add    $0x4,%rdx
cmp    %rcx,%rax
jne    1480 <AutoPowerSpectrum+0x340>
jmp    15e4 <AutoPowerSpectrum+0x4a4>
lea    (%rcx,%rcx,1),%rdx
jmp    124a <AutoPowerSpectrum+0x10a>
mov    %eax,%ecx
and    $0xfffffffe,%ecx
lea    -0x2(%rcx),%rdx
mov    %rdx,%rsi
shr    %rsi
add    $0x1,%rsi
test   %rdx,%rdx
je     15a1 <AutoPowerSpectrum+0x461>
mov    %rsi,%rdi
and    $0xfffffffffffffffe,%rdi
mov    %r15,%rbx
add    $0x20,%rbx
xor    %edx,%edx
nopw   0x0(%rax,%rax,1)
movupd -0x20(%rbx),%xmm0
movupd -0x10(%rbx),%xmm1
movapd %xmm0,%xmm2
unpckhpd %xmm1,%xmm2
unpcklpd %xmm1,%xmm0
mulpd  %xmm0,%xmm0
mulpd  %xmm2,%xmm2
addpd  %xmm0,%xmm2
movupd %xmm2,(%r14,%rdx,8)
movupd (%rbx),%xmm0
movupd 0x10(%rbx),%xmm1
movapd %xmm0,%xmm2
unpckhpd %xmm1,%xmm2
unpcklpd %xmm1,%xmm0
mulpd  %xmm0,%xmm0
mulpd  %xmm2,%xmm2
addpd  %xmm0,%xmm2
movupd %xmm2,0x10(%r14,%rdx,8)
add    $0x4,%rdx
add    $0x40,%rbx
add    $0xfffffffffffffffe,%rdi
jne    1530 <AutoPowerSpectrum+0x3f0>
jmp    15a3 <AutoPowerSpectrum+0x463>
xor    %edx,%edx
test   $0x1,%sil
jne    1393 <AutoPowerSpectrum+0x253>
jmp    13d9 <AutoPowerSpectrum+0x299>
xor    %edx,%edx
test   $0x1,%sil
je     15db <AutoPowerSpectrum+0x49b>
mov    %rdx,%rsi
shl    $0x4,%rsi
movupd (%r15,%rsi,1),%xmm0
movupd 0x10(%r15,%rsi,1),%xmm1
movapd %xmm0,%xmm2
unpckhpd %xmm1,%xmm2
unpcklpd %xmm1,%xmm0
mulpd  %xmm0,%xmm0
mulpd  %xmm2,%xmm2
addpd  %xmm0,%xmm2
movupd %xmm2,(%r14,%rdx,8)
cmp    %rax,%rcx
jne    16b4 <AutoPowerSpectrum+0x574>
movsd  (%r14),%xmm0
movsd  %xmm0,(%r12)
cmp    $0x4,%r13d
jl     177f <AutoPowerSpectrum+0x63f>
cmp    $0x3,%r8d
mov    $0x2,%eax
cmovge %r8d,%eax
lea    -0x1(%rax),%rdx
mov    $0x1,%ecx
cmp    $0x4,%rdx
jb     16fb <AutoPowerSpectrum+0x5bb>
lea    0x8(%r12),%rsi
lea    (%r14,%rax,8),%rdi
cmp    %rdi,%rsi
jae    163b <AutoPowerSpectrum+0x4fb>
lea    (%r12,%rax,8),%rsi
mov    %r14,%rdi
add    $0x8,%rdi
cmp    %rsi,%rdi
jb     16fb <AutoPowerSpectrum+0x5bb>
mov    %rdx,%rcx
and    $0xfffffffffffffffc,%rcx
lea    -0x4(%rcx),%rsi
mov    %rsi,%rbx
shr    $0x2,%rbx
add    $0x1,%rbx
test   %rsi,%rsi
je     16bd <AutoPowerSpectrum+0x57d>
mov    %rbx,%rdi
and    $0xfffffffffffffffe,%rdi
xor    %esi,%esi
nop
movupd 0x8(%r14,%rsi,8),%xmm1
movupd 0x18(%r14,%rsi,8),%xmm2
addpd  %xmm1,%xmm1
addpd  %xmm2,%xmm2
movupd %xmm1,0x8(%r12,%rsi,8)
movupd %xmm2,0x18(%r12,%rsi,8)
movupd 0x28(%r14,%rsi,8),%xmm1
movupd 0x38(%r14,%rsi,8),%xmm2
addpd  %xmm1,%xmm1
addpd  %xmm2,%xmm2
movupd %xmm1,0x28(%r12,%rsi,8)
movupd %xmm2,0x38(%r12,%rsi,8)
add    $0x8,%rsi
add    $0xfffffffffffffffe,%rdi
jne    1660 <AutoPowerSpectrum+0x520>
jmp    16bf <AutoPowerSpectrum+0x57f>
lea    (%rcx,%rcx,1),%rdx
jmp    1433 <AutoPowerSpectrum+0x2f3>
xor    %esi,%esi
test   $0x1,%bl
je     16ee <AutoPowerSpectrum+0x5ae>
shl    $0x3,%rsi
or     $0x8,%rsi
movupd (%r14,%rsi,1),%xmm1
movupd 0x10(%r14,%rsi,1),%xmm2
addpd  %xmm1,%xmm1
addpd  %xmm2,%xmm2
movupd %xmm1,(%r12,%rsi,1)
movupd %xmm2,0x10(%r12,%rsi,1)
cmp    %rcx,%rdx
je     177f <AutoPowerSpectrum+0x63f>
or     $0x1,%rcx
mov    %eax,%esi
sub    %ecx,%esi
mov    %rcx,%rdx
not    %rdx
add    %rax,%rdx
and    $0x3,%rsi
je     172a <AutoPowerSpectrum+0x5ea>
xchg   %ax,%ax
movsd  (%r14,%rcx,8),%xmm1
addsd  %xmm1,%xmm1
movsd  %xmm1,(%r12,%rcx,8)
add    $0x1,%rcx
add    $0xffffffffffffffff,%rsi
jne    1710 <AutoPowerSpectrum+0x5d0>
cmp    $0x3,%rdx
jb     177f <AutoPowerSpectrum+0x63f>
movsd  (%r14,%rcx,8),%xmm1
addsd  %xmm1,%xmm1
movsd  %xmm1,(%r12,%rcx,8)
movsd  0x8(%r14,%rcx,8),%xmm1
addsd  %xmm1,%xmm1
movsd  %xmm1,0x8(%r12,%rcx,8)
movsd  0x10(%r14,%rcx,8),%xmm1
addsd  %xmm1,%xmm1
movsd  %xmm1,0x10(%r12,%rcx,8)
movsd  0x18(%r14,%rcx,8),%xmm1
addsd  %xmm1,%xmm1
movsd  %xmm1,0x18(%r12,%rcx,8)
add    $0x4,%rcx
cmp    %rcx,%rax
jne    1730 <AutoPowerSpectrum+0x5f0>
cmp    $0x1,%r13d
je     11d9 <AutoPowerSpectrum+0x99>
mov    %r13d,%eax
imul   %r13d,%eax
xorps  %xmm1,%xmm1
cvtsi2sd %eax,%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,0x0(%rbp)
and    $0xfffffffe,%r13d
cmp    $0x2,%r13d
je     11d9 <AutoPowerSpectrum+0x99>
mov    %r8d,%eax
lea    -0x1(%rax),%rcx
mov    $0x1,%edx
cmp    $0x2,%rcx
jb     1877 <AutoPowerSpectrum+0x737>
lea    0x8(%rbp),%rsi
lea    (%r12,%rax,8),%rdi
cmp    %rdi,%rsi
jae    17ec <AutoPowerSpectrum+0x6ac>
lea    0x0(,%rax,8),%rsi
add    %rbp,%rsi
mov    %r12,%rdi
add    $0x8,%rdi
cmp    %rsi,%rdi
jb     1877 <AutoPowerSpectrum+0x737>
mov    %rcx,%rdx
and    $0xfffffffffffffffe,%rdx
movapd %xmm1,%xmm0
unpcklpd %xmm1,%xmm0
lea    -0x2(%rdx),%rsi
mov    %rsi,%rbx
shr    %rbx
add    $0x1,%rbx
test   %rsi,%rsi
je     184d <AutoPowerSpectrum+0x70d>
mov    %rbx,%rsi
and    $0xfffffffffffffffe,%rsi
mov    $0x1,%edi
nopw   0x0(%rax,%rax,1)
movupd (%r12,%rdi,8),%xmm2
divpd  %xmm0,%xmm2
movupd %xmm2,0x0(%rbp,%rdi,8)
movupd 0x10(%r12,%rdi,8),%xmm2
divpd  %xmm0,%xmm2
movupd %xmm2,0x10(%rbp,%rdi,8)
add    $0x4,%rdi
add    $0xfffffffffffffffe,%rsi
jne    1820 <AutoPowerSpectrum+0x6e0>
jmp    1852 <AutoPowerSpectrum+0x712>
mov    $0x1,%edi
test   $0x1,%bl
je     1867 <AutoPowerSpectrum+0x727>
movupd (%r12,%rdi,8),%xmm2
divpd  %xmm0,%xmm2
movupd %xmm2,0x0(%rbp,%rdi,8)
cmp    %rdx,%rcx
je     11d9 <AutoPowerSpectrum+0x99>
or     $0x1,%rcx
mov    %rcx,%rdx
mov    %rdx,%rcx
not    %rcx
test   $0x1,%al
jne    1895 <AutoPowerSpectrum+0x755>
movsd  (%r12,%rdx,8),%xmm0
divsd  %xmm1,%xmm0
movsd  %xmm0,0x0(%rbp,%rdx,8)
add    $0x1,%rdx
add    %rax,%rcx
je     11d9 <AutoPowerSpectrum+0x99>
xchg   %ax,%ax
movsd  (%r12,%rdx,8),%xmm0
divsd  %xmm1,%xmm0
movsd  %xmm0,0x0(%rbp,%rdx,8)
movsd  0x8(%r12,%rdx,8),%xmm0
divsd  %xmm1,%xmm0
movsd  %xmm0,0x8(%rbp,%rdx,8)
add    $0x2,%rdx
cmp    %rdx,%rax
jne    18a0 <AutoPowerSpectrum+0x760>
jmp    11d9 <AutoPowerSpectrum+0x99>

LLVM IR (-O0):
define i32 @AutoPowerSpectrum(double* %0, i32 %1, double %2, double* %3, double* %4) {
%6 = alloca double*
%7 = alloca i32
%8 = alloca double
%9 = alloca double*
%10 = alloca double*
%11 = alloca double*
%12 = alloca double*
%13 = alloca double*
%14 = alloca i32
%15 = alloca i32
store double* %0, double** %6
store i32 %1, i32* %7
store double %2, double* %8
store double* %3, double** %9
store double* %4, double** %10
%16 = load i32, i32* %7
%17 = mul nsw i32 %16, 2
%18 = sext i32 %17 to i64
%19 = mul i64 %18, 8
%20 = trunc i64 %19 to i32
%21 = call i64 @malloc(i32 %20)
%22 = inttoptr i64 %21 to double*
store double* %22, double** %11
%23 = load i32, i32* %7
%24 = sext i32 %23 to i64
%25 = mul i64 %24, 8
%26 = trunc i64 %25 to i32
%27 = call i64 @malloc(i32 %26)
%28 = inttoptr i64 %27 to double*
store double* %28, double** %12
%29 = load i32, i32* %7
%30 = sdiv i32 %29, 2
%31 = sext i32 %30 to i64
%32 = mul i64 %31, 8
%33 = trunc i64 %32 to i32
%34 = call i64 @malloc(i32 %33)
%35 = inttoptr i64 %34 to double*
store double* %35, double** %13
store i32 0, i32* %14
br label %36
36: ; preds = %41, %5
%37 = load i32, i32* %14
%38 = load i32, i32* %7
%39 = mul nsw i32 %38, 2
%40 = icmp slt i32 %37, %39
br i1 %40, label %41, label %48
41: ; preds = %36
%42 = load double*, double** %11
%43 = load i32, i32* %14
%44 = sext i32 %43 to i64
%45 = getelementptr inbounds double, double* %42, i64 %44
store double 0.000000e+00, double* %45
%46 = load i32, i32* %14
%47 = add nsw i32 %46, 1
store i32 %47, i32* %14
br label %36
48: ; preds = %36
store i32 0, i32* %14
store i32 0, i32* %15
br label %49
49: ; preds = %55, %48
%50 = load i32, i32* %14
%51 = load i32, i32* %7
%52 = mul nsw i32 %51, 2
%53 = sub nsw i32 %52, 2
%54 = icmp slt i32 %50, %53
br i1 %54, label %55, label %74
55: ; preds = %49
%56 = load double*, double** %6
%57 = load i32, i32* %15
%58 = add nsw i32 %57, 1
store i32 %58, i32* %15
%59 = sext i32 %57 to i64
%60 = getelementptr inbounds double, double* %56, i64 %59
%61 = load double, double* %60
%62 = load double*, double** %11
%63 = load i32, i32* %14
%64 = sext i32 %63 to i64
%65 = getelementptr inbounds double, double* %62, i64 %64
store double %61, double* %65
%66 = load i32, i32* %14
%67 = add nsw i32 %66, 1
store i32 %67, i32* %14
%68 = load double*, double** %11
%69 = load i32, i32* %14
%70 = sext i32 %69 to i64
%71 = getelementptr inbounds double, double* %68, i64 %70
store double 0.000000e+00, double* %71
%72 = load i32, i32* %14
%73 = add nsw i32 %72, 1
store i32 %73, i32* %14
br label %49
74: ; preds = %49
%75 = load double*, double** %11
%76 = load i32, i32* %7
%77 = call i32 @fftc1(double* %75, i32 %76, i32 1)
store i32 0, i32* %14
store i32 0, i32* %15
br label %78
78: ; preds = %83, %74
%79 = load i32, i32* %14
%80 = load i32, i32* %7
%81 = sdiv i32 %80, 2
%82 = icmp slt i32 %79, %81
br i1 %82, label %83, label %125
83: ; preds = %78
%84 = load double*, double** %11
%85 = load i32, i32* %15
%86 = sext i32 %85 to i64
%87 = getelementptr inbounds double, double* %84, i64 %86
%88 = load double, double* %87
%89 = load double*, double** %11
%90 = load i32, i32* %15
%91 = sext i32 %90 to i64
%92 = getelementptr inbounds double, double* %89, i64 %91
%93 = load double, double* %92
%94 = fmul double %88, %93
%95 = load double*, double** %12
%96 = load i32, i32* %14
%97 = sext i32 %96 to i64
%98 = getelementptr inbounds double, double* %95, i64 %97
store double %94, double* %98
%99 = load i32, i32* %15
%100 = add nsw i32 %99, 1
store i32 %100, i32* %15
%101 = load double*, double** %12
%102 = load i32, i32* %14
%103 = sext i32 %102 to i64
%104 = getelementptr inbounds double, double* %101, i64 %103
%105 = load double, double* %104
%106 = load double*, double** %11
%107 = load i32, i32* %15
%108 = sext i32 %107 to i64
%109 = getelementptr inbounds double, double* %106, i64 %108
%110 = load double, double* %109
%111 = load double*, double** %11
%112 = load i32, i32* %15
%113 = sext i32 %112 to i64
%114 = getelementptr inbounds double, double* %111, i64 %113
%115 = load double, double* %114
%116 = call double @llvm.fmuladd.f64(double %110, double %115, double %105)
%117 = load double*, double** %12
%118 = load i32, i32* %14
%119 = sext i32 %118 to i64
%120 = getelementptr inbounds double, double* %117, i64 %119
store double %116, double* %120
%121 = load i32, i32* %15
%122 = add nsw i32 %121, 1
store i32 %122, i32* %15
%123 = load i32, i32* %14
%124 = add nsw i32 %123, 1
store i32 %124, i32* %14
br label %78
125: ; preds = %78
store i32 0, i32* %14
%126 = load double*, double** %12
%127 = load i32, i32* %14
%128 = sext i32 %127 to i64
%129 = getelementptr inbounds double, double* %126, i64 %128
%130 = load double, double* %129
%131 = load double*, double** %13
%132 = load i32, i32* %14
%133 = sext i32 %132 to i64
%134 = getelementptr inbounds double, double* %131, i64 %133
store double %130, double* %134
%135 = load i32, i32* %14
%136 = add nsw i32 %135, 1
store i32 %136, i32* %14
br label %137
137: ; preds = %142, %125
%138 = load i32, i32* %14
%139 = load i32, i32* %7
%140 = sdiv i32 %139, 2
%141 = icmp slt i32 %138, %140
br i1 %141, label %142, label %155
142: ; preds = %137
%143 = load double*, double** %12
%144 = load i32, i32* %14
%145 = sext i32 %144 to i64
%146 = getelementptr inbounds double, double* %143, i64 %145
%147 = load double, double* %146
%148 = fmul double 2.000000e+00, %147
%149 = load double*, double** %13
%150 = load i32, i32* %14
%151 = sext i32 %150 to i64
%152 = getelementptr inbounds double, double* %149, i64 %151
store double %148, double* %152
%153 = load i32, i32* %14
%154 = add nsw i32 %153, 1
store i32 %154, i32* %14
br label %137
155: ; preds = %137
store i32 0, i32* %14
br label %156
156: ; preds = %161, %155
%157 = load i32, i32* %14
%158 = load i32, i32* %7
%159 = sdiv i32 %158, 2
%160 = icmp slt i32 %157, %159
br i1 %160, label %161, label %178
161: ; preds = %156
%162 = load double*, double** %13
%163 = load i32, i32* %14
%164 = sext i32 %163 to i64
%165 = getelementptr inbounds double, double* %162, i64 %164
%166 = load double, double* %165
%167 = load i32, i32* %7
%168 = load i32, i32* %7
%169 = mul nsw i32 %167, %168
%170 = sitofp i32 %169 to double
%171 = fdiv double %166, %170
%172 = load double*, double** %9
%173 = load i32, i32* %14
%174 = sext i32 %173 to i64
%175 = getelementptr inbounds double, double* %172, i64 %174
store double %171, double* %175
%176 = load i32, i32* %14
%177 = add nsw i32 %176, 1
store i32 %177, i32* %14
br label %156
178: ; preds = %156
%179 = load double*, double** %11
%180 = call i32 @free(double* %179)
%181 = load double*, double** %12
%182 = call i32 @free(double* %181)
%183 = load double*, double** %13
%184 = call i32 @free(double* %183)
ret i32 0
}

LLVM IR (-O2):
define i32 @AutoPowerSpectrum(double* nocapture %0, i32 %1, double %2, double* nocapture writeonly %3, double* nocapture readnone %4) {
%6 = shl i32 %1, 1
%7 = shl i32 %1, 4
%8 = tail call i64 @malloc(i32 %7)
%9 = inttoptr i64 %8 to double*
%10 = inttoptr i64 %8 to i8*
%11 = shl i32 %1, 3
%12 = tail call i64 @malloc(i32 %11)
%13 = inttoptr i64 %12 to double*
%14 = inttoptr i64 %12 to i8*
%15 = sdiv i32 %1, 2
%16 = shl i32 %15, 3
%17 = tail call i64 @malloc(i32 %16)
%18 = inttoptr i64 %17 to double*
%19 = icmp sgt i32 %1, 0
br i1 %19, label %20, label %266
20: ; preds = %5
%21 = inttoptr i64 %8 to i8*
%22 = call i32 @llvm.smax.i32(i32 %6, i32 1)
%23 = zext i32 %22 to i64
%24 = shl nuw nsw i64 %23, 3
%25 = icmp eq i32 %1, 1
br i1 %25, label %266, label %26
26: ; preds = %20
%27 = add i32 %6, -2
%28 = call i32 @llvm.smax.i32(i32 %27, i32 2)
%29 = add nsw i32 %28, -1
%30 = lshr i32 %29, 1
%31 = add nuw nsw i32 %30, 1
%32 = zext i32 %31 to i64
%33 = icmp ult i32 %29, 6
br i1 %33, label %116, label %34
34: ; preds = %26
%35 = shl nuw nsw i64 %32, 1
%36 = getelementptr double, double* %9, i64 %35
%37 = getelementptr double, double* %0, i64 %32
%38 = bitcast double* %37 to i8*
%39 = icmp ult i8* %10, %38
%40 = icmp ugt double* %36, %0
%41 = and i1 %39, %40
br i1 %41, label %116, label %42
42: ; preds = %34
%43 = and i64 %32, 2147483644
%44 = shl nuw nsw i64 %43, 1
%45 = add nsw i64 %43, -4
%46 = lshr exact i64 %45, 2
%47 = add nuw nsw i64 %46, 1
%48 = and i64 %47, 1
%49 = icmp eq i64 %45, 0
br i1 %49, label %93, label %50
50: ; preds = %42
%51 = and i64 %47, 9223372036854775806
%52 = getelementptr inbounds double, double* %9, i64 -1
%53 = getelementptr inbounds double, double* %9, i64 -1
%54 = getelementptr inbounds double, double* %9, i64 -1
%55 = getelementptr inbounds double, double* %9, i64 -1
br label %56
56: ; preds = %56, %50
%57 = phi i64 [ 0, %50 ], [ %90, %56 ]
%58 = phi i64 [ 0, %50 ], [ %91, %56 ]
%59 = shl i64 %57, 1
%60 = getelementptr inbounds double, double* %0, i64 %57
%61 = bitcast double* %60 to <2 x double>*
%62 = load <2 x double>, <2 x double>* %61
%63 = getelementptr inbounds double, double* %60, i64 2
%64 = bitcast double* %63 to <2 x double>*
%65 = load <2 x double>, <2 x double>* %64
%66 = or i64 %59, 1
%67 = or i64 %59, 5
%68 = getelementptr inbounds double, double* %52, i64 %66
%69 = bitcast double* %68 to <4 x double>*
%70 = getelementptr inbounds double, double* %53, i64 %67
%71 = bitcast double* %70 to <4 x double>*
%72 = shufflevector <2 x double> %62, <2 x double> zeroinitializer, <4 x i32> <i32 0, i32 2, i32 1, i32 3>
store <4 x double> %72, <4 x double>* %69
%73 = shufflevector <2 x double> %65, <2 x double> zeroinitializer, <4 x i32> <i32 0, i32 2, i32 1, i32 3>
store <4 x double> %73, <4 x double>* %71
%74 = or i64 %57, 4
%75 = shl i64 %74, 1
%76 = getelementptr inbounds double, double* %0, i64 %74
%77 = bitcast double* %76 to <2 x double>*
%78 = load <2 x double>, <2 x double>* %77
%79 = getelementptr inbounds double, double* %76, i64 2
%80 = bitcast double* %79 to <2 x double>*
%81 = load <2 x double>, <2 x double>* %80
%82 = or i64 %75, 1
%83 = or i64 %75, 5
%84 = getelementptr inbounds double, double* %54, i64 %82
%85 = bitcast double* %84 to <4 x double>*
%86 = getelementptr inbounds double, double* %55, i64 %83
%87 = bitcast double* %86 to <4 x double>*
%88 = shufflevector <2 x double> %78, <2 x double> zeroinitializer, <4 x i32> <i32 0, i32 2, i32 1, i32 3>
store <4 x double> %88, <4 x double>* %85
%89 = shufflevector <2 x double> %81, <2 x double> zeroinitializer, <4 x i32> <i32 0, i32 2, i32 1, i32 3>
store <4 x double> %89, <4 x double>* %87
%90 = add nuw i64 %57, 8
%91 = add i64 %58, 2
%92 = icmp eq i64 %91, %51
br i1 %92, label %93, label %56
93: ; preds = %56, %42
%94 = phi i64 [ 0, %42 ], [ %90, %56 ]
%95 = icmp eq i64 %48, 0
br i1 %95, label %114, label %96
96: ; preds = %93
%97 = shl i64 %94, 1
%98 = getelementptr inbounds double, double* %0, i64 %94
%99 = bitcast double* %98 to <2 x double>*
%100 = load <2 x double>, <2 x double>* %99
%101 = getelementptr inbounds double, double* %98, i64 2
%102 = bitcast double* %101 to <2 x double>*
%103 = load <2 x double>, <2 x double>* %102
%104 = or i64 %97, 1
%105 = or i64 %97, 5
%106 = getelementptr inbounds double, double* %9, i64 -1
%107 = getelementptr inbounds double, double* %9, i64 -1
%108 = getelementptr inbounds double, double* %106, i64 %104
%109 = bitcast double* %108 to <4 x double>*
%110 = getelementptr inbounds double, double* %107, i64 %105
%111 = bitcast double* %110 to <4 x double>*
%112 = shufflevector <2 x double> %100, <2 x double> zeroinitializer, <4 x i32> <i32 0, i32 2, i32 1, i32 3>
store <4 x double> %112, <4 x double>* %109
%113 = shufflevector <2 x double> %103, <2 x double> zeroinitializer, <4 x i32> <i32 0, i32 2, i32 1, i32 3>
store <4 x double> %113, <4 x double>* %111
br label %114
114: ; preds = %93, %96
%115 = icmp eq i64 %43, %32
br i1 %115, label %153, label %116
116: ; preds = %34, %26, %114
%117 = phi i64 [ 0, %34 ], [ 0, %26 ], [ %44, %114 ]
%118 = phi i64 [ 0, %34 ], [ 0, %26 ], [ %43, %114 ]
%119 = xor i64 %118, -1
%120 = and i64 %32, 1
%121 = icmp eq i64 %120, 0
br i1 %121, label %130, label %122
122: ; preds = %116
%123 = or i64 %118, 1
%124 = getelementptr inbounds double, double* %0, i64 %118
%125 = load double, double* %124
%126 = getelementptr inbounds double, double* %9, i64 %117
store double %125, double* %126
%127 = or i64 %117, 1
%128 = getelementptr inbounds double, double* %9, i64 %127
store double 0.000000e+00, double* %128
%129 = add nuw nsw i64 %117, 2
br label %130
130: ; preds = %122, %116
%131 = phi i64 [ %117, %116 ], [ %129, %122 ]
%132 = phi i64 [ %118, %116 ], [ %123, %122 ]
%133 = sub nsw i64 0, %32
%134 = icmp eq i64 %119, %133
br i1 %134, label %153, label %135
135: ; preds = %130, %135
%136 = phi i64 [ %151, %135 ], [ %131, %130 ]
%137 = phi i64 [ %145, %135 ], [ %132, %130 ]
%138 = add nuw nsw i64 %137, 1
%139 = getelementptr inbounds double, double* %0, i64 %137
%140 = load double, double* %139
%141 = getelementptr inbounds double, double* %9, i64 %136
store double %140, double* %141
%142 = or i64 %136, 1
%143 = getelementptr inbounds double, double* %9, i64 %142
store double 0.000000e+00, double* %143
%144 = add nuw nsw i64 %136, 2
%145 = add nuw nsw i64 %137, 2
%146 = getelementptr inbounds double, double* %0, i64 %138
%147 = load double, double* %146
%148 = getelementptr inbounds double, double* %9, i64 %144
store double %147, double* %148
%149 = or i64 %144, 1
%150 = getelementptr inbounds double, double* %9, i64 %149
store double 0.000000e+00, double* %150
%151 = add nuw nsw i64 %136, 4
%152 = icmp eq i64 %145, %32
br i1 %152, label %153, label %135
153: ; preds = %130, %135, %114
%154 = tail call i32 @fftc1(double* %9, i32 %1, i32 1)
br i1 %25, label %269, label %155
155: ; preds = %153
%156 = zext i32 %15 to i64
%157 = icmp ult i32 %15, 2
br i1 %157, label %220, label %158
158: ; preds = %155
%159 = getelementptr double, double* %13, i64 %156
%160 = bitcast double* %159 to i8*
%161 = shl nuw nsw i64 %156, 1
%162 = getelementptr double, double* %9, i64 %161
%163 = bitcast double* %162 to i8*
%164 = icmp ult i8* %14, %163
%165 = icmp ult i8* %10, %160
%166 = and i1 %164, %165
br i1 %166, label %220, label %167
167: ; preds = %158
%168 = and i64 %156, 4294967294
%169 = shl nuw nsw i64 %168, 1
%170 = add nsw i64 %168, -2
%171 = lshr exact i64 %170, 1
%172 = add nuw i64 %171, 1
%173 = and i64 %172, 1
%174 = icmp eq i64 %170, 0
br i1 %174, label %204, label %175
175: ; preds = %167
%176 = and i64 %172, -2
br label %177
177: ; preds = %177, %175
%178 = phi i64 [ 0, %175 ], [ %201, %177 ]
%179 = phi i64 [ 0, %175 ], [ %202, %177 ]
%180 = shl i64 %178, 1
%181 = getelementptr inbounds double, double* %9, i64 %180
%182 = bitcast double* %181 to <4 x double>*
%183 = load <4 x double>, <4 x double>* %182
%184 = shufflevector <4 x double> %183, <4 x double> poison, <2 x i32> <i32 1, i32 3>
%185 = fmul <4 x double> %183, %183
%186 = shufflevector <4 x double> %185, <4 x double> poison, <2 x i32> <i32 0, i32 2>
%187 = getelementptr inbounds double, double* %13, i64 %178
%188 = call <2 x double> @llvm.fmuladd.v2f64(<2 x double> %184, <2 x double> %184, <2 x double> %186)
%189 = bitcast double* %187 to <2 x double>*
store <2 x double> %188, <2 x double>* %189
%190 = or i64 %178, 2
%191 = shl i64 %190, 1
%192 = getelementptr inbounds double, double* %9, i64 %191
%193 = bitcast double* %192 to <4 x double>*
%194 = load <4 x double>, <4 x double>* %193
%195 = shufflevector <4 x double> %194, <4 x double> poison, <2 x i32> <i32 1, i32 3>
%196 = fmul <4 x double> %194, %194
%197 = shufflevector <4 x double> %196, <4 x double> poison, <2 x i32> <i32 0, i32 2>
%198 = getelementptr inbounds double, double* %13, i64 %190
%199 = call <2 x double> @llvm.fmuladd.v2f64(<2 x double> %195, <2 x double> %195, <2 x double> %197)
%200 = bitcast double* %198 to <2 x double>*
store <2 x double> %199, <2 x double>* %200
%201 = add nuw i64 %178, 4
%202 = add nuw i64 %179, 2
%203 = icmp eq i64 %202, %176
br i1 %203, label %204, label %177
204: ; preds = %177, %167
%205 = phi i64 [ 0, %167 ], [ %201, %177 ]
%206 = icmp eq i64 %173, 0
br i1 %206, label %218, label %207
207: ; preds = %204
%208 = shl i64 %205, 1
%209 = getelementptr inbounds double, double* %9, i64 %208
%210 = bitcast double* %209 to <4 x double>*
%211 = load <4 x double>, <4 x double>* %210
%212 = shufflevector <4 x double> %211, <4 x double> poison, <2 x i32> <i32 1, i32 3>
%213 = fmul <4 x double> %211, %211
%214 = shufflevector <4 x double> %213, <4 x double> poison, <2 x i32> <i32 0, i32 2>
%215 = getelementptr inbounds double, double* %13, i64 %205
%216 = call <2 x double> @llvm.fmuladd.v2f64(<2 x double> %212, <2 x double> %212, <2 x double> %214)
%217 = bitcast double* %215 to <2 x double>*
store <2 x double> %216, <2 x double>* %217
br label %218
218: ; preds = %204, %207
%219 = icmp eq i64 %168, %156
br i1 %219, label %269, label %220
220: ; preds = %158, %155, %218
%221 = phi i64 [ 0, %158 ], [ 0, %155 ], [ %168, %218 ]
%222 = phi i64 [ 0, %158 ], [ 0, %155 ], [ %169, %218 ]
%223 = xor i64 %221, -1
%224 = and i64 %156, 1
%225 = icmp eq i64 %224, 0
br i1 %225, label %237, label %226
226: ; preds = %220
%227 = getelementptr inbounds double, double* %9, i64 %222
%228 = load double, double* %227
%229 = fmul double %228, %228
%230 = getelementptr inbounds double, double* %13, i64 %221
store double %229, double* %230
%231 = or i64 %222, 1
%232 = getelementptr inbounds double, double* %9, i64 %231
%233 = load double, double* %232
%234 = tail call double @llvm.fmuladd.f64(double %233, double %233, double %229)
store double %234, double* %230
%235 = add nuw nsw i64 %222, 2
%236 = or i64 %221, 1
br label %237
237: ; preds = %226, %220
%238 = phi i64 [ %221, %220 ], [ %236, %226 ]
%239 = phi i64 [ %222, %220 ], [ %235, %226 ]
%240 = sub nsw i64 0, %156
%241 = icmp eq i64 %223, %240
br i1 %241, label %269, label %242
242: ; preds = %237, %242
%243 = phi i64 [ %264, %242 ], [ %238, %237 ]
%244 = phi i64 [ %263, %242 ], [ %239, %237 ]
%245 = getelementptr inbounds double, double* %9, i64 %244
%246 = load double, double* %245
%247 = fmul double %246, %246
%248 = getelementptr inbounds double, double* %13, i64 %243
store double %247, double* %248
%249 = or i64 %244, 1
%250 = getelementptr inbounds double, double* %9, i64 %249
%251 = load double, double* %250
%252 = tail call double @llvm.fmuladd.f64(double %251, double %251, double %247)
store double %252, double* %248
%253 = add nuw nsw i64 %244, 2
%254 = add nuw nsw i64 %243, 1
%255 = getelementptr inbounds double, double* %9, i64 %253
%256 = load double, double* %255
%257 = fmul double %256, %256
%258 = getelementptr inbounds double, double* %13, i64 %254
store double %257, double* %258
%259 = or i64 %253, 1
%260 = getelementptr inbounds double, double* %9, i64 %259
%261 = load double, double* %260
%262 = tail call double @llvm.fmuladd.f64(double %261, double %261, double %257)
store double %262, double* %258
%263 = add nuw nsw i64 %244, 4
%264 = add nuw nsw i64 %243, 2
%265 = icmp eq i64 %264, %156
br i1 %265, label %269, label %242
266: ; preds = %20, %5
%267 = tail call i32 @fftc1(double* %9, i32 %1, i32 1)
%268 = load double, double* %13
store double %268, double* %18
br label %482
269: ; preds = %237, %242, %218, %153
%270 = load double, double* %13
store double %270, double* %18
%271 = icmp sgt i32 %1, 3
br i1 %271, label %272, label %366
272: ; preds = %269
%273 = call i32 @llvm.smax.i32(i32 %15, i32 2)
%274 = zext i32 %273 to i64
%275 = add nsw i64 %274, -1
%276 = icmp ult i64 %275, 4
br i1 %276, label %346, label %277
277: ; preds = %272
%278 = getelementptr double, double* %18, i64 1
%279 = getelementptr double, double* %18, i64 %274
%280 = getelementptr double, double* %13, i64 1
%281 = getelementptr double, double* %13, i64 %274
%282 = icmp ult double* %278, %281
%283 = icmp ult double* %280, %279
%284 = and i1 %282, %283
br i1 %284, label %346, label %285
285: ; preds = %277
%286 = and i64 %275, -4
%287 = or i64 %286, 1
%288 = add nsw i64 %286, -4
%289 = lshr exact i64 %288, 2
%290 = add nuw nsw i64 %289, 1
%291 = and i64 %290, 1
%292 = icmp eq i64 %288, 0
br i1 %292, label %327, label %293
293: ; preds = %285
%294 = and i64 %290, 9223372036854775806
br label %295
295: ; preds = %295, %293
%296 = phi i64 [ 0, %293 ], [ %324, %295 ]
%297 = phi i64 [ 0, %293 ], [ %325, %295 ]
%298 = or i64 %296, 1
%299 = getelementptr inbounds double, double* %13, i64 %298
%300 = bitcast double* %299 to <2 x double>*
%301 = load <2 x double>, <2 x double>* %300
%302 = getelementptr inbounds double, double* %299, i64 2
%303 = bitcast double* %302 to <2 x double>*
%304 = load <2 x double>, <2 x double>* %303
%305 = fmul <2 x double> %301, <double 2.000000e+00, double 2.000000e+00>
%306 = fmul <2 x double> %304, <double 2.000000e+00, double 2.000000e+00>
%307 = getelementptr inbounds double, double* %18, i64 %298
%308 = bitcast double* %307 to <2 x double>*
store <2 x double> %305, <2 x double>* %308
%309 = getelementptr inbounds double, double* %307, i64 2
%310 = bitcast double* %309 to <2 x double>*
store <2 x double> %306, <2 x double>* %310
%311 = or i64 %296, 5
%312 = getelementptr inbounds double, double* %13, i64 %311
%313 = bitcast double* %312 to <2 x double>*
%314 = load <2 x double>, <2 x double>* %313
%315 = getelementptr inbounds double, double* %312, i64 2
%316 = bitcast double* %315 to <2 x double>*
%317 = load <2 x double>, <2 x double>* %316
%318 = fmul <2 x double> %314, <double 2.000000e+00, double 2.000000e+00>
%319 = fmul <2 x double> %317, <double 2.000000e+00, double 2.000000e+00>
%320 = getelementptr inbounds double, double* %18, i64 %311
%321 = bitcast double* %320 to <2 x double>*
store <2 x double> %318, <2 x double>* %321
%322 = getelementptr inbounds double, double* %320, i64 2
%323 = bitcast double* %322 to <2 x double>*
store <2 x double> %319, <2 x double>* %323
%324 = add nuw i64 %296, 8
%325 = add i64 %297, 2
%326 = icmp eq i64 %325, %294
br i1 %326, label %327, label %295
327: ; preds = %295, %285
%328 = phi i64 [ 0, %285 ], [ %324, %295 ]
%329 = icmp eq i64 %291, 0
br i1 %329, label %344, label %330
330: ; preds = %327
%331 = or i64 %328, 1
%332 = getelementptr inbounds double, double* %13, i64 %331
%333 = bitcast double* %332 to <2 x double>*
%334 = load <2 x double>, <2 x double>* %333
%335 = getelementptr inbounds double, double* %332, i64 2
%336 = bitcast double* %335 to <2 x double>*
%337 = load <2 x double>, <2 x double>* %336
%338 = fmul <2 x double> %334, <double 2.000000e+00, double 2.000000e+00>
%339 = fmul <2 x double> %337, <double 2.000000e+00, double 2.000000e+00>
%340 = getelementptr inbounds double, double* %18, i64 %331
%341 = bitcast double* %340 to <2 x double>*
store <2 x double> %338, <2 x double>* %341
%342 = getelementptr inbounds double, double* %340, i64 2
%343 = bitcast double* %342 to <2 x double>*
store <2 x double> %339, <2 x double>* %343
br label %344
344: ; preds = %327, %330
%345 = icmp eq i64 %275, %286
br i1 %345, label %366, label %346
346: ; preds = %277, %272, %344
%347 = phi i64 [ 1, %277 ], [ 1, %272 ], [ %287, %344 ]
%348 = sub nsw i64 %274, %347
%349 = xor i64 %347, -1
%350 = add nsw i64 %349, %274
%351 = and i64 %348, 3
%352 = icmp eq i64 %351, 0
br i1 %352, label %363, label %353
353: ; preds = %346, %353
%354 = phi i64 [ %360, %353 ], [ %347, %346 ]
%355 = phi i64 [ %361, %353 ], [ 0, %346 ]
%356 = getelementptr inbounds double, double* %13, i64 %354
%357 = load double, double* %356
%358 = fmul double %357, 2.000000e+00
%359 = getelementptr inbounds double, double* %18, i64 %354
store double %358, double* %359
%360 = add nuw nsw i64 %354, 1
%361 = add i64 %355, 1
%362 = icmp eq i64 %361, %351
br i1 %362, label %363, label %353
363: ; preds = %353, %346
%364 = phi i64 [ %347, %346 ], [ %360, %353 ]
%365 = icmp ult i64 %350, 3
br i1 %365, label %366, label %446
366: ; preds = %363, %446, %344, %269
br i1 %25, label %482, label %367
367: ; preds = %366
%368 = mul nsw i32 %1, %1
%369 = sitofp i32 %368 to double
%370 = zext i32 %15 to i64
%371 = fdiv double %270, %369
store double %371, double* %3
%372 = and i32 %1, -2
%373 = icmp eq i32 %372, 2
br i1 %373, label %482, label %374
374: ; preds = %367
%375 = add nsw i64 %370, -1
%376 = icmp ult i64 %375, 2
br i1 %376, label %431, label %377
377: ; preds = %374
%378 = getelementptr double, double* %3, i64 1
%379 = getelementptr double, double* %3, i64 %370
%380 = getelementptr double, double* %18, i64 1
%381 = getelementptr double, double* %18, i64 %370
%382 = icmp ult double* %378, %381
%383 = icmp ult double* %380, %379
%384 = and i1 %382, %383
br i1 %384, label %431, label %385
385: ; preds = %377
%386 = and i64 %375, -2
%387 = or i64 %375, 1
%388 = insertelement <2 x double> poison, double %369, i64 0
%389 = shufflevector <2 x double> %388, <2 x double> poison, <2 x i32> zeroinitializer
%390 = add nsw i64 %386, -2
%391 = lshr exact i64 %390, 1
%392 = add nuw i64 %391, 1
%393 = and i64 %392, 1
%394 = icmp eq i64 %390, 0
br i1 %394, label %419, label %395
395: ; preds = %385
%396 = and i64 %392, -2
br label %397
397: ; preds = %397, %395
%398 = phi i64 [ 0, %395 ], [ %414, %397 ]
%399 = phi i64 [ 0, %395 ], [ %415, %397 ]
%400 = or i64 %398, 1
%401 = getelementptr inbounds double, double* %18, i64 %400
%402 = bitcast double* %401 to <2 x double>*
%403 = load <2 x double>, <2 x double>* %402
%404 = fdiv <2 x double> %403, %389
%405 = getelementptr inbounds double, double* %3, i64 %400
%406 = bitcast double* %405 to <2 x double>*
store <2 x double> %404, <2 x double>* %406
%407 = or i64 %398, 3
%408 = getelementptr inbounds double, double* %18, i64 %407
%409 = bitcast double* %408 to <2 x double>*
%410 = load <2 x double>, <2 x double>* %409
%411 = fdiv <2 x double> %410, %389
%412 = getelementptr inbounds double, double* %3, i64 %407
%413 = bitcast double* %412 to <2 x double>*
store <2 x double> %411, <2 x double>* %413
%414 = add nuw i64 %398, 4
%415 = add nuw i64 %399, 2
%416 = icmp eq i64 %415, %396
br i1 %416, label %417, label %397
417: ; preds = %397
%418 = or i64 %414, 1
br label %419
419: ; preds = %417, %385
%420 = phi i64 [ 1, %385 ], [ %418, %417 ]
%421 = icmp eq i64 %393, 0
br i1 %421, label %429, label %422
422: ; preds = %419
%423 = getelementptr inbounds double, double* %18, i64 %420
%424 = bitcast double* %423 to <2 x double>*
%425 = load <2 x double>, <2 x double>* %424
%426 = fdiv <2 x double> %425, %389
%427 = getelementptr inbounds double, double* %3, i64 %420
%428 = bitcast double* %427 to <2 x double>*
store <2 x double> %426, <2 x double>* %428
br label %429
429: ; preds = %419, %422
%430 = icmp eq i64 %375, %386
br i1 %430, label %482, label %431
431: ; preds = %377, %374, %429
%432 = phi i64 [ 1, %377 ], [ 1, %374 ], [ %387, %429 ]
%433 = xor i64 %432, -1
%434 = and i64 %370, 1
%435 = icmp eq i64 %434, 0
br i1 %435, label %436, label %442
436: ; preds = %431
%437 = getelementptr inbounds double, double* %18, i64 %432
%438 = load double, double* %437
%439 = fdiv double %438, %369
%440 = getelementptr inbounds double, double* %3, i64 %432
store double %439, double* %440
%441 = add nuw nsw i64 %432, 1
br label %442
442: ; preds = %436, %431
%443 = phi i64 [ %432, %431 ], [ %441, %436 ]
%444 = sub nsw i64 0, %370
%445 = icmp eq i64 %433, %444
br i1 %445, label %482, label %469
446: ; preds = %363, %446
%447 = phi i64 [ %467, %446 ], [ %364, %363 ]
%448 = getelementptr inbounds double, double* %13, i64 %447
%449 = load double, double* %448
%450 = fmul double %449, 2.000000e+00
%451 = getelementptr inbounds double, double* %18, i64 %447
store double %450, double* %451
%452 = add nuw nsw i64 %447, 1
%453 = getelementptr inbounds double, double* %13, i64 %452
%454 = load double, double* %453
%455 = fmul double %454, 2.000000e+00
%456 = getelementptr inbounds double, double* %18, i64 %452
store double %455, double* %456
%457 = add nuw nsw i64 %447, 2
%458 = getelementptr inbounds double, double* %13, i64 %457
%459 = load double, double* %458
%460 = fmul double %459, 2.000000e+00
%461 = getelementptr inbounds double, double* %18, i64 %457
store double %460, double* %461
%462 = add nuw nsw i64 %447, 3
%463 = getelementptr inbounds double, double* %13, i64 %462
%464 = load double, double* %463
%465 = fmul double %464, 2.000000e+00
%466 = getelementptr inbounds double, double* %18, i64 %462
store double %465, double* %466
%467 = add nuw nsw i64 %447, 4
%468 = icmp eq i64 %467, %274
br i1 %468, label %366, label %446
469: ; preds = %442, %469
%470 = phi i64 [ %480, %469 ], [ %443, %442 ]
%471 = getelementptr inbounds double, double* %18, i64 %470
%472 = load double, double* %471
%473 = fdiv double %472, %369
%474 = getelementptr inbounds double, double* %3, i64 %470
store double %473, double* %474
%475 = add nuw nsw i64 %470, 1
%476 = getelementptr inbounds double, double* %18, i64 %475
%477 = load double, double* %476
%478 = fdiv double %477, %369
%479 = getelementptr inbounds double, double* %3, i64 %475
store double %478, double* %479
%480 = add nuw nsw i64 %470, 2
%481 = icmp eq i64 %480, %370
br i1 %481, label %482, label %469
482: ; preds = %442, %469, %367, %429, %266, %366
%483 = tail call i32 @free(double* %9)
%484 = tail call i32 @free(double* %13)
%485 = tail call i32 @free(double* %18)
ret i32 0
}