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

/* Forward declarations */

/* Type definitions */

/* Variables and functions */
double cos(long double);
double sin(long double);
void fft_rec(int N, int offset, int delta, double (*x)[2], double (*X)[2],
             double (*XX)[2], int rec_no) {
  int N2 = N / 2;
  int k;
  double cs, sn;
  int k00, k01, k10, k11;
  double tmp0, tmp1;
  rec_no = rec_no + 1;
  if (N != 2) {
    fft_rec(N2, offset, 2 * delta, x, XX, X, rec_no);
    fft_rec(N2, offset + delta, 2 * delta, x, XX, X, rec_no);
    for (k = 0; k < N2; k++) {
      k00 = offset + k * delta;
      k01 = k00 + N2 * delta;
      k10 = offset + 2 * k * delta;
      k11 = k10 + delta;
      cs = cos((6.2831853071795864769252867665590057683943L) * k / (double)N);
      sn = sin((6.2831853071795864769252867665590057683943L) * k / (double)N);
      tmp0 = cs * XX[k11][0] + sn * XX[k11][1];
      tmp1 = cs * XX[k11][1] - sn * XX[k11][0];
      X[k01][0] = XX[k10][0] - tmp0;
      X[k01][1] = XX[k10][1] - tmp1;
      X[k00][0] = XX[k10][0] + tmp0;
      X[k00][1] = XX[k10][1] + tmp1;
    }
  } else {
    k00 = offset;
    k01 = k00 + delta;
    X[k01][0] = x[k00][0] - x[k01][0];
    X[k01][1] = x[k00][1] - x[k01][1];
    X[k00][0] = x[k00][0] + x[k01][0];
    X[k00][1] = x[k00][1] + x[k01][1];
  }
  rec_no = rec_no - 1;
}


x86 assembly (clang, -O0):
<fft_rec>:
push   %rbp
mov    %rsp,%rbp
sub    $0xa0,%rsp
mov    0x10(%rbp),%eax
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    %edx,-0xc(%rbp)
mov    %rcx,-0x18(%rbp)
mov    %r8,-0x20(%rbp)
mov    %r9,-0x28(%rbp)
mov    -0x4(%rbp),%eax
mov    $0x2,%ecx
cltd
idiv   %ecx
mov    %eax,-0x2c(%rbp)
mov    0x10(%rbp),%eax
add    $0x1,%eax
mov    %eax,0x10(%rbp)
cmpl   $0x2,-0x4(%rbp)
je     13cf <fft_rec+0x29f>
mov    -0x2c(%rbp),%edi
mov    -0x8(%rbp),%esi
mov    -0xc(%rbp),%edx
shl    $0x1,%edx
mov    -0x18(%rbp),%rcx
mov    -0x28(%rbp),%r8
mov    -0x20(%rbp),%r9
mov    0x10(%rbp),%eax
mov    %eax,(%rsp)
call   1050 <fft_rec@plt>
mov    -0x2c(%rbp),%edi
mov    -0x8(%rbp),%esi
add    -0xc(%rbp),%esi
mov    -0xc(%rbp),%edx
shl    $0x1,%edx
mov    -0x18(%rbp),%rcx
mov    -0x28(%rbp),%r8
mov    -0x20(%rbp),%r9
mov    0x10(%rbp),%eax
mov    %eax,(%rsp)
call   1050 <fft_rec@plt>
movl   $0x0,-0x30(%rbp)
mov    -0x30(%rbp),%eax
cmp    -0x2c(%rbp),%eax
jge    13ca <fft_rec+0x29a>
mov    -0x8(%rbp),%eax
mov    -0x30(%rbp),%ecx
mov    -0xc(%rbp),%edx
imul   %edx,%ecx
add    %ecx,%eax
mov    %eax,-0x44(%rbp)
mov    -0x44(%rbp),%eax
mov    -0x2c(%rbp),%ecx
mov    -0xc(%rbp),%edx
imul   %edx,%ecx
add    %ecx,%eax
mov    %eax,-0x48(%rbp)
mov    -0x8(%rbp),%ecx
mov    -0x30(%rbp),%edx
mov    -0xc(%rbp),%eax
imul   %eax,%edx
mov    %ecx,%eax
mov    %edx,%ecx
lea    (%rax,%rcx,2),%eax
mov    %eax,-0x4c(%rbp)
mov    -0x4c(%rbp),%eax
mov    -0xc(%rbp),%ecx
add    %ecx,%eax
mov    %eax,-0x50(%rbp)
mov    -0x30(%rbp),%eax
mov    %eax,-0x68(%rbp)
fildl  -0x68(%rbp)
fldt   0xdde(%rip)
fld    %st(0)
fstpt  -0x84(%rbp)
fmulp  %st,%st(1)
cvtsi2sdl -0x4(%rbp),%xmm0
movsd  %xmm0,-0x70(%rbp)
fldl   -0x70(%rbp)
fdivrp %st,%st(1)
mov    %rsp,%rax
fstpt  (%rax)
call   1040 <cos@plt>
fldt   -0x84(%rbp)
movsd  %xmm0,-0x38(%rbp)
mov    -0x30(%rbp),%eax
mov    %eax,-0x64(%rbp)
fildl  -0x64(%rbp)
fmulp  %st,%st(1)
cvtsi2sdl -0x4(%rbp),%xmm0
movsd  %xmm0,-0x78(%rbp)
fldl   -0x78(%rbp)
fdivrp %st,%st(1)
mov    %rsp,%rax
fstpt  (%rax)
call   1030 <sin@plt>
movsd  %xmm0,-0x40(%rbp)
movsd  -0x38(%rbp),%xmm0
mov    -0x28(%rbp),%rax
movslq -0x50(%rbp),%rcx
shl    $0x4,%rcx
add    %rcx,%rax
movsd  (%rax),%xmm2
movsd  -0x40(%rbp),%xmm1
mov    -0x28(%rbp),%rax
movslq -0x50(%rbp),%rcx
shl    $0x4,%rcx
add    %rcx,%rax
mulsd  0x8(%rax),%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x58(%rbp)
movsd  -0x38(%rbp),%xmm0
mov    -0x28(%rbp),%rax
movslq -0x50(%rbp),%rcx
shl    $0x4,%rcx
add    %rcx,%rax
movsd  0x8(%rax),%xmm2
movsd  -0x40(%rbp),%xmm1
mov    -0x28(%rbp),%rax
movslq -0x50(%rbp),%rcx
shl    $0x4,%rcx
add    %rcx,%rax
mulsd  (%rax),%xmm1
movq   %xmm1,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x60(%rbp)
mov    -0x28(%rbp),%rax
movslq -0x4c(%rbp),%rcx
shl    $0x4,%rcx
add    %rcx,%rax
movsd  (%rax),%xmm0
subsd  -0x58(%rbp),%xmm0
mov    -0x20(%rbp),%rax
movslq -0x48(%rbp),%rcx
shl    $0x4,%rcx
add    %rcx,%rax
movsd  %xmm0,(%rax)
mov    -0x28(%rbp),%rax
movslq -0x4c(%rbp),%rcx
shl    $0x4,%rcx
add    %rcx,%rax
movsd  0x8(%rax),%xmm0
subsd  -0x60(%rbp),%xmm0
mov    -0x20(%rbp),%rax
movslq -0x48(%rbp),%rcx
shl    $0x4,%rcx
add    %rcx,%rax
movsd  %xmm0,0x8(%rax)
mov    -0x28(%rbp),%rax
movslq -0x4c(%rbp),%rcx
shl    $0x4,%rcx
add    %rcx,%rax
movsd  (%rax),%xmm0
addsd  -0x58(%rbp),%xmm0
mov    -0x20(%rbp),%rax
movslq -0x44(%rbp),%rcx
shl    $0x4,%rcx
add    %rcx,%rax
movsd  %xmm0,(%rax)
mov    -0x28(%rbp),%rax
movslq -0x4c(%rbp),%rcx
shl    $0x4,%rcx
add    %rcx,%rax
movsd  0x8(%rax),%xmm0
addsd  -0x60(%rbp),%xmm0
mov    -0x20(%rbp),%rax
movslq -0x44(%rbp),%rcx
shl    $0x4,%rcx
add    %rcx,%rax
movsd  %xmm0,0x8(%rax)
mov    -0x30(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x30(%rbp)
jmp    11c4 <fft_rec+0x94>
jmp    14c8 <fft_rec+0x398>
mov    -0x8(%rbp),%eax
mov    %eax,-0x44(%rbp)
mov    -0x44(%rbp),%eax
add    -0xc(%rbp),%eax
mov    %eax,-0x48(%rbp)
mov    -0x18(%rbp),%rax
movslq -0x44(%rbp),%rcx
shl    $0x4,%rcx
add    %rcx,%rax
movsd  (%rax),%xmm0
mov    -0x18(%rbp),%rax
movslq -0x48(%rbp),%rcx
shl    $0x4,%rcx
add    %rcx,%rax
subsd  (%rax),%xmm0
mov    -0x20(%rbp),%rax
movslq -0x48(%rbp),%rcx
shl    $0x4,%rcx
add    %rcx,%rax
movsd  %xmm0,(%rax)
mov    -0x18(%rbp),%rax
movslq -0x44(%rbp),%rcx
shl    $0x4,%rcx
add    %rcx,%rax
movsd  0x8(%rax),%xmm0
mov    -0x18(%rbp),%rax
movslq -0x48(%rbp),%rcx
shl    $0x4,%rcx
add    %rcx,%rax
subsd  0x8(%rax),%xmm0
mov    -0x20(%rbp),%rax
movslq -0x48(%rbp),%rcx
shl    $0x4,%rcx
add    %rcx,%rax
movsd  %xmm0,0x8(%rax)
mov    -0x18(%rbp),%rax
movslq -0x44(%rbp),%rcx
shl    $0x4,%rcx
add    %rcx,%rax
movsd  (%rax),%xmm0
mov    -0x18(%rbp),%rax
movslq -0x48(%rbp),%rcx
shl    $0x4,%rcx
add    %rcx,%rax
addsd  (%rax),%xmm0
mov    -0x20(%rbp),%rax
movslq -0x44(%rbp),%rcx
shl    $0x4,%rcx
add    %rcx,%rax
movsd  %xmm0,(%rax)
mov    -0x18(%rbp),%rax
movslq -0x44(%rbp),%rcx
shl    $0x4,%rcx
add    %rcx,%rax
movsd  0x8(%rax),%xmm0
mov    -0x18(%rbp),%rax
movslq -0x48(%rbp),%rcx
shl    $0x4,%rcx
add    %rcx,%rax
addsd  0x8(%rax),%xmm0
mov    -0x20(%rbp),%rax
movslq -0x44(%rbp),%rcx
shl    $0x4,%rcx
add    %rcx,%rax
movsd  %xmm0,0x8(%rax)
mov    0x10(%rbp),%eax
sub    $0x1,%eax
mov    %eax,0x10(%rbp)
add    $0xa0,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<fft_rec>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x78,%rsp
mov    %r8,%r12
mov    %rcx,%rbp
mov    %rdx,0x10(%rsp)
mov    %esi,%ebx
cmp    $0x2,%edi
jne    11b4 <fft_rec+0x84>
mov    0x10(%rsp),%rcx
add    %ebx,%ecx
movslq %ebx,%rax
shl    $0x4,%rax
movsd  0x0(%rbp,%rax,1),%xmm0
movslq %ecx,%rcx
shl    $0x4,%rcx
subsd  0x0(%rbp,%rcx,1),%xmm0
movsd  %xmm0,(%r12,%rcx,1)
movsd  0x8(%rbp,%rax,1),%xmm0
subsd  0x8(%rbp,%rcx,1),%xmm0
movsd  %xmm0,0x8(%r12,%rcx,1)
movsd  0x0(%rbp,%rax,1),%xmm0
addsd  0x0(%rbp,%rcx,1),%xmm0
movsd  %xmm0,(%r12,%rax,1)
movsd  0x8(%rbp,%rax,1),%xmm0
addsd  0x8(%rbp,%rcx,1),%xmm0
movsd  %xmm0,0x8(%r12,%rax,1)
jmp    136e <fft_rec+0x23e>
mov    %r9,%r15
mov    0xb0(%rsp),%r14d
mov    %edi,%r13d
shr    $0x1f,%r13d
add    %edi,%r13d
sar    %r13d
add    $0x1,%r14d
mov    0x10(%rsp),%rax
lea    (%rax,%rax,1),%edx
mov    %edx,0x24(%rsp)
mov    %r14d,(%rsp)
mov    %edi,0x18(%rsp)
mov    %r13d,%edi
mov    %ebx,%esi
mov    %rbp,%rcx
mov    %r9,%r8
mov    %r12,%r9
call   1050 <fft_rec@plt>
mov    0x10(%rsp),%rax
lea    (%rax,%rbx,1),%esi
mov    %r14d,(%rsp)
mov    0x24(%rsp),%r14d
mov    %r13d,%edi
mov    %r14d,%edx
mov    %rbp,%rcx
mov    %r15,%r8
mov    %r12,%r9
call   1050 <fft_rec@plt>
mov    0x18(%rsp),%ecx
cmp    $0x2,%ecx
jl     136e <fft_rec+0x23e>
mov    %r13d,%eax
mov    %rax,0x48(%rsp)
mov    0x10(%rsp),%rax
imul   %eax,%r13d
mov    %ecx,0x2c(%rsp)
fildl  0x2c(%rsp)
fstpt  0x60(%rsp)
movslq %eax,%rcx
movslq %ebx,%rdx
movslq %r13d,%rax
shl    $0x4,%rdx
shl    $0x4,%rcx
mov    %rcx,0x40(%rsp)
shl    $0x4,%rax
add    %rdx,%rax
add    $0x8,%rax
mov    %rax,0x30(%rsp)
or     $0x8,%rdx
mov    %rdx,0x38(%rsp)
xor    %ebp,%ebp
fldt   0xd83(%rip)
fstpt  0x54(%rsp)
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax,%rax,1)
mov    0x10(%rsp),%rax
mov    %r14d,%r13d
lea    (%rax,%rbx,1),%r14d
mov    %ebp,0x28(%rsp)
fldt   0x54(%rsp)
fimull 0x28(%rsp)
fldt   0x60(%rsp)
fdivrp %st,%st(1)
fld    %st(0)
fstpt  0x6c(%rsp)
fstpt  (%rsp)
call   1040 <cos@plt>
movsd  %xmm0,0x18(%rsp)
fldt   0x6c(%rsp)
fstpt  (%rsp)
call   1030 <sin@plt>
movslq %r14d,%rax
mov    %r13d,%r14d
shl    $0x4,%rax
movsd  (%r15,%rax,1),%xmm1
movsd  0x8(%r15,%rax,1),%xmm2
movsd  0x18(%rsp),%xmm4
movapd %xmm4,%xmm3
mulsd  %xmm1,%xmm3
mulsd  %xmm0,%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm0,%xmm3
mulsd  %xmm2,%xmm4
subsd  %xmm1,%xmm4
movslq %ebx,%rbx
mov    %rbx,%rax
shl    $0x4,%rax
movsd  (%r15,%rax,1),%xmm0
subsd  %xmm3,%xmm0
mov    0x30(%rsp),%rcx
movsd  %xmm0,-0x8(%r12,%rcx,1)
movsd  0x8(%r15,%rax,1),%xmm0
subsd  %xmm4,%xmm0
movsd  %xmm0,(%r12,%rcx,1)
addsd  (%r15,%rax,1),%xmm3
mov    0x38(%rsp),%rcx
movsd  %xmm3,-0x8(%r12,%rcx,1)
addsd  0x8(%r15,%rax,1),%xmm4
movsd  %xmm4,(%r12,%rcx,1)
add    $0x1,%rbp
add    0x40(%rsp),%r12
add    %r13d,%ebx
cmp    %rbp,0x48(%rsp)
jne    1290 <fft_rec+0x160>
add    $0x78,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
define void @fft_rec(i32 %0, i32 %1, i32 %2, [2 x double]* %3, [2 x double]* %4, [2 x double]* %5, i32 %6) {
%8 = alloca i32
%9 = alloca i32
%10 = alloca i32
%11 = alloca [2 x double]*
%12 = alloca [2 x double]*
%13 = alloca [2 x double]*
%14 = alloca i32
%15 = alloca i32
%16 = alloca i32
%17 = alloca double
%18 = alloca double
%19 = alloca i32
%20 = alloca i32
%21 = alloca i32
%22 = alloca i32
%23 = alloca double
%24 = alloca double
store i32 %0, i32* %8
store i32 %1, i32* %9
store i32 %2, i32* %10
store [2 x double]* %3, [2 x double]** %11
store [2 x double]* %4, [2 x double]** %12
store [2 x double]* %5, [2 x double]** %13
store i32 %6, i32* %14
%25 = load i32, i32* %8
%26 = sdiv i32 %25, 2
store i32 %26, i32* %15
%27 = load i32, i32* %14
%28 = add nsw i32 %27, 1
store i32 %28, i32* %14
%29 = load i32, i32* %8
%30 = icmp ne i32 %29, 2
br i1 %30, label %31, label %179
31: ; preds = %7
%32 = load i32, i32* %15
%33 = load i32, i32* %9
%34 = load i32, i32* %10
%35 = mul nsw i32 2, %34
%36 = load [2 x double]*, [2 x double]** %11
%37 = load [2 x double]*, [2 x double]** %13
%38 = load [2 x double]*, [2 x double]** %12
%39 = load i32, i32* %14
%40 = load i32, i32* %15
%41 = load i32, i32* %9
%42 = load i32, i32* %10
%43 = add nsw i32 %41, %42
%44 = load i32, i32* %10
%45 = mul nsw i32 2, %44
%46 = load [2 x double]*, [2 x double]** %11
%47 = load [2 x double]*, [2 x double]** %13
%48 = load [2 x double]*, [2 x double]** %12
%49 = load i32, i32* %14
store i32 0, i32* %16
br label %50
50: ; preds = %175, %31
%51 = load i32, i32* %16
%52 = load i32, i32* %15
%53 = icmp slt i32 %51, %52
br i1 %53, label %54, label %178
54: ; preds = %50
%55 = load i32, i32* %9
%56 = load i32, i32* %16
%57 = load i32, i32* %10
%58 = mul nsw i32 %56, %57
%59 = add nsw i32 %55, %58
store i32 %59, i32* %19
%60 = load i32, i32* %19
%61 = load i32, i32* %15
%62 = load i32, i32* %10
%63 = mul nsw i32 %61, %62
%64 = add nsw i32 %60, %63
store i32 %64, i32* %20
%65 = load i32, i32* %9
%66 = load i32, i32* %16
%67 = mul nsw i32 2, %66
%68 = load i32, i32* %10
%69 = mul nsw i32 %67, %68
%70 = add nsw i32 %65, %69
store i32 %70, i32* %21
%71 = load i32, i32* %21
%72 = load i32, i32* %10
%73 = add nsw i32 %71, %72
store i32 %73, i32* %22
%74 = load i32, i32* %16
%75 = sitofp i32 %74 to x86_fp80
%76 = fmul x86_fp80 0xK4001C90FDAA22168C235, %75
%77 = load i32, i32* %8
%78 = sitofp i32 %77 to double
%79 = fpext double %78 to x86_fp80
%80 = fdiv x86_fp80 %76, %79
%81 = call double @cos(x86_fp80 %80)
store double %81, double* %17
%82 = load i32, i32* %16
%83 = sitofp i32 %82 to x86_fp80
%84 = fmul x86_fp80 0xK4001C90FDAA22168C235, %83
%85 = load i32, i32* %8
%86 = sitofp i32 %85 to double
%87 = fpext double %86 to x86_fp80
%88 = fdiv x86_fp80 %84, %87
%89 = call double @sin(x86_fp80 %88)
store double %89, double* %18
%90 = load double, double* %17
%91 = load [2 x double]*, [2 x double]** %13
%92 = load i32, i32* %22
%93 = sext i32 %92 to i64
%94 = getelementptr inbounds [2 x double], [2 x double]* %91, i64 %93
%95 = getelementptr inbounds [2 x double], [2 x double]* %94, i64 0, i64 0
%96 = load double, double* %95
%97 = load double, double* %18
%98 = load [2 x double]*, [2 x double]** %13
%99 = load i32, i32* %22
%100 = sext i32 %99 to i64
%101 = getelementptr inbounds [2 x double], [2 x double]* %98, i64 %100
%102 = getelementptr inbounds [2 x double], [2 x double]* %101, i64 0, i64 1
%103 = load double, double* %102
%104 = fmul double %97, %103
%105 = call double @llvm.fmuladd.f64(double %90, double %96, double %104)
store double %105, double* %23
%106 = load double, double* %17
%107 = load [2 x double]*, [2 x double]** %13
%108 = load i32, i32* %22
%109 = sext i32 %108 to i64
%110 = getelementptr inbounds [2 x double], [2 x double]* %107, i64 %109
%111 = getelementptr inbounds [2 x double], [2 x double]* %110, i64 0, i64 1
%112 = load double, double* %111
%113 = load double, double* %18
%114 = load [2 x double]*, [2 x double]** %13
%115 = load i32, i32* %22
%116 = sext i32 %115 to i64
%117 = getelementptr inbounds [2 x double], [2 x double]* %114, i64 %116
%118 = getelementptr inbounds [2 x double], [2 x double]* %117, i64 0, i64 0
%119 = load double, double* %118
%120 = fmul double %113, %119
%121 = fneg double %120
%122 = call double @llvm.fmuladd.f64(double %106, double %112, double %121)
store double %122, double* %24
%123 = load [2 x double]*, [2 x double]** %13
%124 = load i32, i32* %21
%125 = sext i32 %124 to i64
%126 = getelementptr inbounds [2 x double], [2 x double]* %123, i64 %125
%127 = getelementptr inbounds [2 x double], [2 x double]* %126, i64 0, i64 0
%128 = load double, double* %127
%129 = load double, double* %23
%130 = fsub double %128, %129
%131 = load [2 x double]*, [2 x double]** %12
%132 = load i32, i32* %20
%133 = sext i32 %132 to i64
%134 = getelementptr inbounds [2 x double], [2 x double]* %131, i64 %133
%135 = getelementptr inbounds [2 x double], [2 x double]* %134, i64 0, i64 0
store double %130, double* %135
%136 = load [2 x double]*, [2 x double]** %13
%137 = load i32, i32* %21
%138 = sext i32 %137 to i64
%139 = getelementptr inbounds [2 x double], [2 x double]* %136, i64 %138
%140 = getelementptr inbounds [2 x double], [2 x double]* %139, i64 0, i64 1
%141 = load double, double* %140
%142 = load double, double* %24
%143 = fsub double %141, %142
%144 = load [2 x double]*, [2 x double]** %12
%145 = load i32, i32* %20
%146 = sext i32 %145 to i64
%147 = getelementptr inbounds [2 x double], [2 x double]* %144, i64 %146
%148 = getelementptr inbounds [2 x double], [2 x double]* %147, i64 0, i64 1
store double %143, double* %148
%149 = load [2 x double]*, [2 x double]** %13
%150 = load i32, i32* %21
%151 = sext i32 %150 to i64
%152 = getelementptr inbounds [2 x double], [2 x double]* %149, i64 %151
%153 = getelementptr inbounds [2 x double], [2 x double]* %152, i64 0, i64 0
%154 = load double, double* %153
%155 = load double, double* %23
%156 = fadd double %154, %155
%157 = load [2 x double]*, [2 x double]** %12
%158 = load i32, i32* %19
%159 = sext i32 %158 to i64
%160 = getelementptr inbounds [2 x double], [2 x double]* %157, i64 %159
%161 = getelementptr inbounds [2 x double], [2 x double]* %160, i64 0, i64 0
store double %156, double* %161
%162 = load [2 x double]*, [2 x double]** %13
%163 = load i32, i32* %21
%164 = sext i32 %163 to i64
%165 = getelementptr inbounds [2 x double], [2 x double]* %162, i64 %164
%166 = getelementptr inbounds [2 x double], [2 x double]* %165, i64 0, i64 1
%167 = load double, double* %166
%168 = load double, double* %24
%169 = fadd double %167, %168
%170 = load [2 x double]*, [2 x double]** %12
%171 = load i32, i32* %19
%172 = sext i32 %171 to i64
%173 = getelementptr inbounds [2 x double], [2 x double]* %170, i64 %172
%174 = getelementptr inbounds [2 x double], [2 x double]* %173, i64 0, i64 1
store double %169, double* %174
br label %175
175: ; preds = %54
%176 = load i32, i32* %16
%177 = add nsw i32 %176, 1
store i32 %177, i32* %16
br label %50
178: ; preds = %50
br label %256
179: ; preds = %7
%180 = load i32, i32* %9
store i32 %180, i32* %19
%181 = load i32, i32* %19
%182 = load i32, i32* %10
%183 = add nsw i32 %181, %182
store i32 %183, i32* %20
%184 = load [2 x double]*, [2 x double]** %11
%185 = load i32, i32* %19
%186 = sext i32 %185 to i64
%187 = getelementptr inbounds [2 x double], [2 x double]* %184, i64 %186
%188 = getelementptr inbounds [2 x double], [2 x double]* %187, i64 0, i64 0
%189 = load double, double* %188
%190 = load [2 x double]*, [2 x double]** %11
%191 = load i32, i32* %20
%192 = sext i32 %191 to i64
%193 = getelementptr inbounds [2 x double], [2 x double]* %190, i64 %192
%194 = getelementptr inbounds [2 x double], [2 x double]* %193, i64 0, i64 0
%195 = load double, double* %194
%196 = fsub double %189, %195
%197 = load [2 x double]*, [2 x double]** %12
%198 = load i32, i32* %20
%199 = sext i32 %198 to i64
%200 = getelementptr inbounds [2 x double], [2 x double]* %197, i64 %199
%201 = getelementptr inbounds [2 x double], [2 x double]* %200, i64 0, i64 0
store double %196, double* %201
%202 = load [2 x double]*, [2 x double]** %11
%203 = load i32, i32* %19
%204 = sext i32 %203 to i64
%205 = getelementptr inbounds [2 x double], [2 x double]* %202, i64 %204
%206 = getelementptr inbounds [2 x double], [2 x double]* %205, i64 0, i64 1
%207 = load double, double* %206
%208 = load [2 x double]*, [2 x double]** %11
%209 = load i32, i32* %20
%210 = sext i32 %209 to i64
%211 = getelementptr inbounds [2 x double], [2 x double]* %208, i64 %210
%212 = getelementptr inbounds [2 x double], [2 x double]* %211, i64 0, i64 1
%213 = load double, double* %212
%214 = fsub double %207, %213
%215 = load [2 x double]*, [2 x double]** %12
%216 = load i32, i32* %20
%217 = sext i32 %216 to i64
%218 = getelementptr inbounds [2 x double], [2 x double]* %215, i64 %217
%219 = getelementptr inbounds [2 x double], [2 x double]* %218, i64 0, i64 1
store double %214, double* %219
%220 = load [2 x double]*, [2 x double]** %11
%221 = load i32, i32* %19
%222 = sext i32 %221 to i64
%223 = getelementptr inbounds [2 x double], [2 x double]* %220, i64 %222
%224 = getelementptr inbounds [2 x double], [2 x double]* %223, i64 0, i64 0
%225 = load double, double* %224
%226 = load [2 x double]*, [2 x double]** %11
%227 = load i32, i32* %20
%228 = sext i32 %227 to i64
%229 = getelementptr inbounds [2 x double], [2 x double]* %226, i64 %228
%230 = getelementptr inbounds [2 x double], [2 x double]* %229, i64 0, i64 0
%231 = load double, double* %230
%232 = fadd double %225, %231
%233 = load [2 x double]*, [2 x double]** %12
%234 = load i32, i32* %19
%235 = sext i32 %234 to i64
%236 = getelementptr inbounds [2 x double], [2 x double]* %233, i64 %235
%237 = getelementptr inbounds [2 x double], [2 x double]* %236, i64 0, i64 0
store double %232, double* %237
%238 = load [2 x double]*, [2 x double]** %11
%239 = load i32, i32* %19
%240 = sext i32 %239 to i64
%241 = getelementptr inbounds [2 x double], [2 x double]* %238, i64 %240
%242 = getelementptr inbounds [2 x double], [2 x double]* %241, i64 0, i64 1
%243 = load double, double* %242
%244 = load [2 x double]*, [2 x double]** %11
%245 = load i32, i32* %20
%246 = sext i32 %245 to i64
%247 = getelementptr inbounds [2 x double], [2 x double]* %244, i64 %246
%248 = getelementptr inbounds [2 x double], [2 x double]* %247, i64 0, i64 1
%249 = load double, double* %248
%250 = fadd double %243, %249
%251 = load [2 x double]*, [2 x double]** %12
%252 = load i32, i32* %19
%253 = sext i32 %252 to i64
%254 = getelementptr inbounds [2 x double], [2 x double]* %251, i64 %253
%255 = getelementptr inbounds [2 x double], [2 x double]* %254, i64 0, i64 1
store double %250, double* %255
br label %256
256: ; preds = %179, %178
%257 = load i32, i32* %14
%258 = sub nsw i32 %257, 1
store i32 %258, i32* %14
ret void
}

LLVM IR (-O2):
define void @fft_rec(i32 %0, i32 %1, i32 %2, [2 x double]* %3, [2 x double]* nocapture %4, [2 x double]* nocapture %5, i32 %6) {
%8 = sdiv i32 %0, 2
%9 = add nsw i32 %6, 1
%10 = icmp eq i32 %0, 2
br i1 %10, label %63, label %11
11: ; preds = %7
%12 = shl i32 %2, 1
tail call void @fft_rec(i32 %8, i32 %1, i32 %12, [2 x double]* %3, [2 x double]* %5, [2 x double]* %4, i32 %9)
%13 = add nsw i32 %2, %1
tail call void @fft_rec(i32 %8, i32 %13, i32 %12, [2 x double]* %3, [2 x double]* %5, [2 x double]* %4, i32 %9)
%14 = icmp sgt i32 %0, 1
br i1 %14, label %15, label %87
15: ; preds = %11
%16 = mul nsw i32 %8, %2
%17 = sitofp i32 %0 to x86_fp80
%18 = sext i32 %2 to i64
%19 = sext i32 %1 to i64
%20 = sext i32 %16 to i64
%21 = zext i32 %8 to i64
br label %22
22: ; preds = %15, %22
%23 = phi i64 [ 0, %15 ], [ %61, %22 ]
%24 = mul nsw i64 %23, %18
%25 = add nsw i64 %24, %19
%26 = add nsw i64 %25, %20
%27 = trunc i64 %23 to i32
%28 = mul i32 %12, %27
%29 = add nsw i32 %28, %1
%30 = add nsw i32 %29, %2
%31 = sitofp i32 %27 to x86_fp80
%32 = fmul x86_fp80 %31, 0xK4001C90FDAA22168C235
%33 = fdiv x86_fp80 %32, %17
%34 = tail call double @cos(x86_fp80 %33)
%35 = tail call double @sin(x86_fp80 %33)
%36 = sext i32 %30 to i64
%37 = getelementptr inbounds [2 x double], [2 x double]* %5, i64 %36, i64 0
%38 = load double, double* %37
%39 = getelementptr inbounds [2 x double], [2 x double]* %5, i64 %36, i64 1
%40 = load double, double* %39
%41 = fmul double %35, %40
%42 = tail call double @llvm.fmuladd.f64(double %34, double %38, double %41)
%43 = fneg double %35
%44 = fmul double %38, %43
%45 = tail call double @llvm.fmuladd.f64(double %34, double %40, double %44)
%46 = sext i32 %29 to i64
%47 = getelementptr inbounds [2 x double], [2 x double]* %5, i64 %46, i64 0
%48 = load double, double* %47
%49 = fsub double %48, %42
%50 = getelementptr inbounds [2 x double], [2 x double]* %4, i64 %26, i64 0
store double %49, double* %50
%51 = getelementptr inbounds [2 x double], [2 x double]* %5, i64 %46, i64 1
%52 = load double, double* %51
%53 = fsub double %52, %45
%54 = getelementptr inbounds [2 x double], [2 x double]* %4, i64 %26, i64 1
store double %53, double* %54
%55 = load double, double* %47
%56 = fadd double %42, %55
%57 = getelementptr inbounds [2 x double], [2 x double]* %4, i64 %25, i64 0
store double %56, double* %57
%58 = load double, double* %51
%59 = fadd double %45, %58
%60 = getelementptr inbounds [2 x double], [2 x double]* %4, i64 %25, i64 1
store double %59, double* %60
%61 = add nuw nsw i64 %23, 1
%62 = icmp eq i64 %61, %21
br i1 %62, label %87, label %22
63: ; preds = %7
%64 = add nsw i32 %2, %1
%65 = sext i32 %1 to i64
%66 = getelementptr inbounds [2 x double], [2 x double]* %3, i64 %65, i64 0
%67 = load double, double* %66
%68 = sext i32 %64 to i64
%69 = getelementptr inbounds [2 x double], [2 x double]* %3, i64 %68, i64 0
%70 = load double, double* %69
%71 = fsub double %67, %70
%72 = getelementptr inbounds [2 x double], [2 x double]* %4, i64 %68, i64 0
store double %71, double* %72
%73 = getelementptr inbounds [2 x double], [2 x double]* %3, i64 %65, i64 1
%74 = load double, double* %73
%75 = getelementptr inbounds [2 x double], [2 x double]* %3, i64 %68, i64 1
%76 = load double, double* %75
%77 = fsub double %74, %76
%78 = getelementptr inbounds [2 x double], [2 x double]* %4, i64 %68, i64 1
store double %77, double* %78
%79 = load double, double* %66
%80 = load double, double* %69
%81 = fadd double %79, %80
%82 = getelementptr inbounds [2 x double], [2 x double]* %4, i64 %65, i64 0
store double %81, double* %82
%83 = load double, double* %73
%84 = load double, double* %75
%85 = fadd double %83, %84
%86 = getelementptr inbounds [2 x double], [2 x double]* %4, i64 %65, i64 1
store double %85, double* %86
br label %87
87: ; preds = %22, %11, %63
ret void
}