void interp2_table0_complex_per(const double *r_ck, const double *i_ck,
                                const int K1, const int K2, const double *r_h1,
                                const double *i_h1, const double *r_h2,
                                const double *i_h2, const int J1, const int J2,
                                const int L1, const int L2, const double *p_tm,
                                const int M, double *r_fm, double *i_fm) {
  int mm;
  {
    const int ncenter1 = floor(J1 * L1 / 2);
    r_h1 += ncenter1;
    i_h1 += ncenter1;
  }
  {
    const int ncenter2 = floor(J2 * L2 / 2);
    r_h2 += ncenter2;
    i_h2 += ncenter2;
  }
  for (mm = 0; mm < M; mm++) {
    int jj1, jj2;
    const double t2 = p_tm[M];
    const double t1 = *p_tm++;
    double sum2r = 0;
    double sum2i = 0;
    const int koff1 = 1 + floor(t1 - J1 / 2.);
    int k2 = 1 + floor(t2 - J2 / 2.);
    for (jj2 = 0; jj2 < J2; jj2++, k2++) {
      const double p2 = (t2 - k2) * L2;
      const int n2 = floor(p2 + 0.5);
      const double coef2r = r_h2[n2];
      const double coef2i = i_h2[n2];
      const int k2mod = ((k2) - (K2)*floor((k2) / (double)(K2)));
      const int k12mod = k2mod * K1;
      register double sum1r = 0;
      register double sum1i = 0;
      int k1 = koff1;
      for (jj1 = 0; jj1 < J1; jj1++, k1++) {
        const double p1 = (t1 - k1) * L1;
        const int n1 = floor(p1 + 0.5);
        register const double coef1r = r_h1[n1];
        register const double coef1i = i_h1[n1];
        const int k1mod = ((k1) - (K1)*floor((k1) / (double)(K1)));
        const int kk = k12mod + k1mod;
        sum1r += coef1r * r_ck[kk] - coef1i * i_ck[kk];
        sum1i += coef1r * i_ck[kk] + coef1i * r_ck[kk];
      }
      sum2r += coef2r * sum1r - coef2i * sum1i;
      sum2i += coef2r * sum1i + coef2i * sum1r;
    }
    *r_fm++ = sum2r;
    *i_fm++ = sum2i;
  }
}


x86 assembly (clang, -O0):
<interp2_table0_complex_per>:
push   %rbp
mov    %rsp,%rbp
sub    $0xf0,%rsp
mov    0x58(%rbp),%rax
mov    0x50(%rbp),%rax
mov    0x48(%rbp),%eax
mov    0x40(%rbp),%rax
mov    0x38(%rbp),%eax
mov    0x30(%rbp),%eax
mov    0x28(%rbp),%eax
mov    0x20(%rbp),%eax
mov    0x18(%rbp),%rax
mov    0x10(%rbp),%rax
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %edx,-0x14(%rbp)
mov    %ecx,-0x18(%rbp)
mov    %r8,-0x20(%rbp)
mov    %r9,-0x28(%rbp)
mov    0x20(%rbp),%eax
imul   0x30(%rbp),%eax
mov    $0x2,%ecx
cltd
idiv   %ecx
cvtsi2sd %eax,%xmm0
call   1030 <floor@plt>
cvttsd2si %xmm0,%eax
mov    %eax,-0x30(%rbp)
mov    -0x30(%rbp),%ecx
mov    -0x20(%rbp),%rax
movslq %ecx,%rcx
shl    $0x3,%rcx
add    %rcx,%rax
mov    %rax,-0x20(%rbp)
mov    -0x30(%rbp),%ecx
mov    -0x28(%rbp),%rax
movslq %ecx,%rcx
shl    $0x3,%rcx
add    %rcx,%rax
mov    %rax,-0x28(%rbp)
mov    0x28(%rbp),%eax
imul   0x38(%rbp),%eax
mov    $0x2,%ecx
cltd
idiv   %ecx
cvtsi2sd %eax,%xmm0
call   1030 <floor@plt>
cvttsd2si %xmm0,%eax
mov    %eax,-0x34(%rbp)
mov    -0x34(%rbp),%ecx
mov    0x10(%rbp),%rax
movslq %ecx,%rcx
shl    $0x3,%rcx
add    %rcx,%rax
mov    %rax,0x10(%rbp)
mov    -0x34(%rbp),%ecx
mov    0x18(%rbp),%rax
movslq %ecx,%rcx
shl    $0x3,%rcx
add    %rcx,%rax
mov    %rax,0x18(%rbp)
movl   $0x0,-0x2c(%rbp)
mov    -0x2c(%rbp),%eax
cmp    0x48(%rbp),%eax
jge    1637 <interp2_table0_complex_per+0x527>
mov    0x40(%rbp),%rax
movslq 0x48(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
movsd  %xmm0,-0x48(%rbp)
mov    0x40(%rbp),%rax
mov    %rax,%rcx
add    $0x8,%rcx
mov    %rcx,0x40(%rbp)
movsd  (%rax),%xmm0
movsd  %xmm0,-0x50(%rbp)
xorps  %xmm0,%xmm0
movsd  %xmm0,-0x58(%rbp)
xorps  %xmm0,%xmm0
movsd  %xmm0,-0x60(%rbp)
movsd  -0x50(%rbp),%xmm0
cvtsi2sdl 0x20(%rbp),%xmm1
movsd  0xdc3(%rip),%xmm2
divsd  %xmm2,%xmm1
subsd  %xmm1,%xmm0
call   1030 <floor@plt>
movaps %xmm0,%xmm1
movsd  0xda3(%rip),%xmm0
addsd  %xmm1,%xmm0
cvttsd2si %xmm0,%eax
mov    %eax,-0x64(%rbp)
movsd  -0x48(%rbp),%xmm0
cvtsi2sdl 0x28(%rbp),%xmm1
movsd  0xd8e(%rip),%xmm2
divsd  %xmm2,%xmm1
subsd  %xmm1,%xmm0
call   1030 <floor@plt>
movaps %xmm0,%xmm1
movsd  0xd6e(%rip),%xmm0
addsd  %xmm1,%xmm0
cvttsd2si %xmm0,%eax
mov    %eax,-0x68(%rbp)
movl   $0x0,-0x3c(%rbp)
mov    -0x3c(%rbp),%eax
cmp    0x28(%rbp),%eax
jge    15f9 <interp2_table0_complex_per+0x4e9>
movsd  -0x48(%rbp),%xmm0
cvtsi2sdl -0x68(%rbp),%xmm1
subsd  %xmm1,%xmm0
cvtsi2sdl 0x38(%rbp),%xmm1
mulsd  %xmm1,%xmm0
movsd  %xmm0,-0x70(%rbp)
movsd  0xd3c(%rip),%xmm0
addsd  -0x70(%rbp),%xmm0
call   1030 <floor@plt>
cvttsd2si %xmm0,%eax
mov    %eax,-0x74(%rbp)
mov    0x10(%rbp),%rax
movslq -0x74(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
movsd  %xmm0,-0x80(%rbp)
mov    0x18(%rbp),%rax
movslq -0x74(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
movsd  %xmm0,-0x88(%rbp)
ff
cvtsi2sdl -0x68(%rbp),%xmm0
movsd  %xmm0,-0xe0(%rbp)
ff
cvtsi2sdl -0x18(%rbp),%xmm0
movsd  %xmm0,-0xd8(%rbp)
ff
cvtsi2sdl -0x68(%rbp),%xmm0
cvtsi2sdl -0x18(%rbp),%xmm1
divsd  %xmm1,%xmm0
call   1030 <floor@plt>
movsd  -0xe0(%rbp),%xmm1
ff
movaps %xmm0,%xmm2
movsd  -0xd8(%rbp),%xmm0
ff
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
cvttsd2si %xmm0,%eax
mov    %eax,-0x8c(%rbp)
mov    -0x8c(%rbp),%eax
imul   -0x14(%rbp),%eax
mov    %eax,-0x90(%rbp)
xorps  %xmm0,%xmm0
movsd  %xmm0,-0x98(%rbp)
ff
xorps  %xmm0,%xmm0
movsd  %xmm0,-0xa0(%rbp)
ff
mov    -0x64(%rbp),%eax
mov    %eax,-0xa4(%rbp)
movl   $0x0,-0x38(%rbp)
mov    -0x38(%rbp),%eax
cmp    0x20(%rbp),%eax
jge    156d <interp2_table0_complex_per+0x45d>
movsd  -0x50(%rbp),%xmm0
cvtsi2sdl -0xa4(%rbp),%xmm1
ff
subsd  %xmm1,%xmm0
cvtsi2sdl 0x30(%rbp),%xmm1
mulsd  %xmm1,%xmm0
movsd  %xmm0,-0xb0(%rbp)
ff
movsd  0xc2f(%rip),%xmm0
addsd  -0xb0(%rbp),%xmm0
ff
call   1030 <floor@plt>
cvttsd2si %xmm0,%eax
mov    %eax,-0xb4(%rbp)
mov    -0x20(%rbp),%rax
movslq -0xb4(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
movsd  %xmm0,-0xc0(%rbp)
ff
mov    -0x28(%rbp),%rax
movslq -0xb4(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
movsd  %xmm0,-0xc8(%rbp)
ff
cvtsi2sdl -0xa4(%rbp),%xmm0
ff
movsd  %xmm0,-0xf0(%rbp)
ff
cvtsi2sdl -0x14(%rbp),%xmm0
movsd  %xmm0,-0xe8(%rbp)
ff
cvtsi2sdl -0xa4(%rbp),%xmm0
ff
cvtsi2sdl -0x14(%rbp),%xmm1
divsd  %xmm1,%xmm0
call   1030 <floor@plt>
movsd  -0xf0(%rbp),%xmm1
ff
movaps %xmm0,%xmm2
movsd  -0xe8(%rbp),%xmm0
ff
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
cvttsd2si %xmm0,%eax
mov    %eax,-0xcc(%rbp)
mov    -0x90(%rbp),%eax
add    -0xcc(%rbp),%eax
mov    %eax,-0xd0(%rbp)
movsd  -0xc0(%rbp),%xmm0
ff
mov    -0x8(%rbp),%rax
movslq -0xd0(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm2
movsd  -0xc8(%rbp),%xmm1
ff
mov    -0x10(%rbp),%rax
movslq -0xd0(%rbp),%rcx
mulsd  (%rax,%rcx,8),%xmm1
movq   %xmm1,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
addsd  -0x98(%rbp),%xmm0
ff
movsd  %xmm0,-0x98(%rbp)
ff
movsd  -0xc0(%rbp),%xmm0
ff
mov    -0x10(%rbp),%rax
movslq -0xd0(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm2
movsd  -0xc8(%rbp),%xmm1
ff
mov    -0x8(%rbp),%rax
movslq -0xd0(%rbp),%rcx
mulsd  (%rax,%rcx,8),%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
addsd  -0xa0(%rbp),%xmm0
ff
movsd  %xmm0,-0xa0(%rbp)
ff
mov    -0x38(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x38(%rbp)
mov    -0xa4(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xa4(%rbp)
jmp    13ab <interp2_table0_complex_per+0x29b>
movsd  -0x80(%rbp),%xmm0
movsd  -0x98(%rbp),%xmm2
ff
movsd  -0x88(%rbp),%xmm1
ff
mulsd  -0xa0(%rbp),%xmm1
ff
movq   %xmm1,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
addsd  -0x58(%rbp),%xmm0
movsd  %xmm0,-0x58(%rbp)
movsd  -0x80(%rbp),%xmm0
movsd  -0xa0(%rbp),%xmm2
ff
movsd  -0x88(%rbp),%xmm1
ff
mulsd  -0x98(%rbp),%xmm1
ff
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
addsd  -0x60(%rbp),%xmm0
movsd  %xmm0,-0x60(%rbp)
mov    -0x3c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x3c(%rbp)
mov    -0x68(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x68(%rbp)
jmp    12a4 <interp2_table0_complex_per+0x194>
movsd  -0x58(%rbp),%xmm0
mov    0x50(%rbp),%rax
mov    %rax,%rcx
add    $0x8,%rcx
mov    %rcx,0x50(%rbp)
movsd  %xmm0,(%rax)
movsd  -0x60(%rbp),%xmm0
mov    0x58(%rbp),%rax
mov    %rax,%rcx
add    $0x8,%rcx
mov    %rcx,0x58(%rbp)
movsd  %xmm0,(%rax)
mov    -0x2c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x2c(%rbp)
jmp    11ed <interp2_table0_complex_per+0xdd>
add    $0xf0,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<interp2_table0_complex_per>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x118,%rsp
mov    %edx,0x8(%rsp)
cmpl   $0x0,0x188(%rsp)
jle    1547 <interp2_table0_complex_per+0x437>
mov    0x198(%rsp),%r15
mov    0x190(%rsp),%r14
mov    0x180(%rsp),%r12
mov    0x178(%rsp),%eax
mov    0x170(%rsp),%edx
mov    0x168(%rsp),%r10d
mov    0x160(%rsp),%r11d
cvtsi2sd %edx,%xmm0
movsd  %xmm0,0x20(%rsp)
imul   %r11d,%edx
mov    %edx,%ebp
shr    $0x1f,%ebp
add    %edx,%ebp
sar    %ebp
movslq %ebp,%rdx
lea    (%r8,%rdx,8),%rbp
lea    (%r9,%rdx,8),%rdx
mov    %rdx,0x80(%rsp)
xorps  %xmm0,%xmm0
cvtsi2sd %eax,%xmm0
movsd  %xmm0,0x78(%rsp)
imul   %r10d,%eax
mov    %eax,%edx
shr    $0x1f,%edx
add    %eax,%edx
sar    %edx
movslq %edx,%rax
shl    $0x3,%rax
mov    0x150(%rsp),%rdx
add    %rax,%rdx
mov    %rdx,0x68(%rsp)
add    0x158(%rsp),%rax
mov    %rax,0x70(%rsp)
xorps  %xmm0,%xmm0
cvtsi2sd %r11d,%xmm0
movsd  0xe1f(%rip),%xmm1
cvtsi2sd %r10d,%xmm2
mulsd  %xmm1,%xmm0
movsd  %xmm0,0x48(%rsp)
mulsd  %xmm1,%xmm2
movsd  %xmm2,0x40(%rsp)
xorps  %xmm0,%xmm0
cvtsi2sd %ecx,%xmm0
movapd 0xe07(%rip),%xmm1
movapd %xmm0,0xb0(%rsp)
xorpd  %xmm1,%xmm0
movapd %xmm0,0xa0(%rsp)
xorps  %xmm0,%xmm0
cvtsi2sdl 0x8(%rsp),%xmm0
movapd %xmm0,0xf0(%rsp)
xorpd  %xmm0,%xmm1
movapd %xmm1,0x100(%rsp)
xor    %ebx,%ebx
mov    %rsi,0x88(%rsp)
mov    %rdi,0x98(%rsp)
mov    0x80(%rsp),%r13
jmp    129d <interp2_table0_complex_per+0x18d>
nopw   0x0(%rax,%rax,1)
xorpd  %xmm0,%xmm0
mov    0x50(%rsp),%r12
add    $0x8,%r12
mov    0x58(%rsp),%r14
movhpd %xmm0,(%r14)
add    $0x8,%r14
mov    0x60(%rsp),%r15
movlpd %xmm0,(%r15)
add    $0x8,%r15
mov    0xc(%rsp),%ebx
add    $0x1,%ebx
cmp    0x188(%rsp),%ebx
je     1547 <interp2_table0_complex_per+0x437>
movsd  (%r12),%xmm0
movsd  %xmm0,0x28(%rsp)
subsd  0x48(%rsp),%xmm0
call   1030 <floor@plt>
movsd  0xd4c(%rip),%xmm1
addsd  %xmm1,%xmm0
cmpl   $0x0,0x168(%rsp)
mov    %r15,0x60(%rsp)
mov    %r14,0x58(%rsp)
mov    %r12,0x50(%rsp)
mov    %ebx,0xc(%rsp)
jle    1260 <interp2_table0_complex_per+0x150>
mov    0x188(%rsp),%eax
movsd  (%r12,%rax,8),%xmm2
cvttsd2si %xmm0,%eax
mov    %eax,0x10(%rsp)
movsd  %xmm2,0x90(%rsp)
movapd %xmm2,%xmm0
subsd  0x40(%rsp),%xmm0
call   1030 <floor@plt>
addsd  0xcf6(%rip),%xmm0
cvttsd2si %xmm0,%eax
xorpd  %xmm0,%xmm0
xor    %ecx,%ecx
movsd  0xcdc(%rip),%xmm1
jmp    139f <interp2_table0_complex_per+0x28f>
cs nopw 0x0(%rax,%rax,1)
movapd 0xc0(%rsp),%xmm2
movapd %xmm2,%xmm0
movapd 0xccb(%rip),%xmm1
xorpd  %xmm1,%xmm0
unpcklpd %xmm3,%xmm2
movapd %xmm3,%xmm1
shufpd $0x1,%xmm0,%xmm1
mulpd  %xmm2,%xmm1
movapd 0xd0(%rsp),%xmm2
unpcklpd %xmm2,%xmm2
mulpd  %xmm3,%xmm2
addpd  %xmm1,%xmm2
movapd 0xe0(%rsp),%xmm0
addpd  %xmm2,%xmm0
mov    0x14(%rsp),%ecx
add    $0x1,%ecx
mov    0x18(%rsp),%eax
add    $0x1,%eax
cmp    0x168(%rsp),%ecx
movsd  0xc67(%rip),%xmm1
je     1264 <interp2_table0_complex_per+0x154>
mov    %ecx,0x14(%rsp)
movapd %xmm0,0xe0(%rsp)
mov    %eax,0x18(%rsp)
xorps  %xmm2,%xmm2
cvtsi2sd %eax,%xmm2
movsd  %xmm2,(%rsp)
movsd  0x90(%rsp),%xmm0
subsd  %xmm2,%xmm0
mulsd  0x78(%rsp),%xmm0
addsd  %xmm1,%xmm0
call   1030 <floor@plt>
movsd  %xmm0,0x30(%rsp)
movsd  (%rsp),%xmm0
divsd  0xb0(%rsp),%xmm0
call   1030 <floor@plt>
cvttsd2si 0x30(%rsp),%eax
cltq
mov    0x68(%rsp),%rcx
movsd  (%rcx,%rax,8),%xmm1
movaps %xmm1,0xd0(%rsp)
mov    0x70(%rsp),%rcx
movsd  (%rcx,%rax,8),%xmm1
movaps %xmm1,0xc0(%rsp)
xorpd  %xmm3,%xmm3
cmpl   $0x0,0x160(%rsp)
mov    0x88(%rsp),%r12
movsd  0x20(%rsp),%xmm1
movsd  0x28(%rsp),%xmm2
jle    1330 <interp2_table0_complex_per+0x220>
mulsd  0xa0(%rsp),%xmm0
addsd  (%rsp),%xmm0
cvttsd2si %xmm0,%esi
imul   0x8(%rsp),%esi
mov    %esi,0x1c(%rsp)
xorpd  %xmm3,%xmm3
mov    0x160(%rsp),%r14d
mov    0x10(%rsp),%ebx
xchg   %ax,%ax
movapd %xmm3,0x30(%rsp)
xorps  %xmm3,%xmm3
cvtsi2sd %ebx,%xmm3
movsd  %xmm3,(%rsp)
movapd %xmm2,%xmm0
subsd  %xmm3,%xmm0
mulsd  %xmm1,%xmm0
addsd  0xb6a(%rip),%xmm0
call   1030 <floor@plt>
cvttsd2si %xmm0,%eax
mov    %rbp,%r15
movslq %eax,%rbp
movsd  (%rsp),%xmm0
divsd  0xf0(%rsp),%xmm0
call   1030 <floor@plt>
movapd 0x100(%rsp),%xmm4
mulsd  %xmm4,%xmm0
addsd  (%rsp),%xmm0
cvttsd2si %xmm0,%eax
add    0x1c(%rsp),%eax
cltq
movsd  0x0(%r13,%rbp,8),%xmm0
movapd %xmm0,%xmm1
xorpd  0xb29(%rip),%xmm1
movsd  (%r12,%rax,8),%xmm2
unpcklpd %xmm2,%xmm0
mov    0x98(%rsp),%rsi
movsd  (%rsi,%rax,8),%xmm3
unpcklpd %xmm3,%xmm2
unpcklpd %xmm1,%xmm3
movsd  0x20(%rsp),%xmm1
mulpd  %xmm0,%xmm3
movsd  (%r15,%rbp,8),%xmm0
mov    %r15,%rbp
unpcklpd %xmm0,%xmm0
mulpd  %xmm0,%xmm2
addpd  %xmm3,%xmm2
movapd 0x30(%rsp),%xmm3
addpd  %xmm2,%xmm3
movsd  0x28(%rsp),%xmm2
add    $0x1,%ebx
add    $0xffffffff,%r14d
jne    1470 <interp2_table0_complex_per+0x360>
jmp    1330 <interp2_table0_complex_per+0x220>
add    $0x118,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

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

LLVM IR (-O2):
define void @interp2_table0_complex_per(double* nocapture %0, double* nocapture %1, i32 %2, i32 %3, double* nocapture %4, double* nocapture %5, double* nocapture %6, double* nocapture %7, i32 %8, i32 %9, i32 %10, i32 %11, double* nocapture %12, i32 %13, double* nocapture writeonly %14, double* nocapture writeonly %15) {
%17 = mul nsw i32 %10, %8
%18 = sdiv i32 %17, 2
%19 = sext i32 %18 to i64
%20 = getelementptr inbounds double, double* %4, i64 %19
%21 = getelementptr inbounds double, double* %5, i64 %19
%22 = mul nsw i32 %11, %9
%23 = sdiv i32 %22, 2
%24 = sext i32 %23 to i64
%25 = getelementptr inbounds double, double* %6, i64 %24
%26 = getelementptr inbounds double, double* %7, i64 %24
%27 = icmp sgt i32 %13, 0
br i1 %27, label %28, label %144
28: ; preds = %16
%29 = zext i32 %13 to i64
%30 = sitofp i32 %8 to double
%31 = fmul double %30, 5.000000e-01
%32 = sitofp i32 %9 to double
%33 = fmul double %32, 5.000000e-01
%34 = icmp sgt i32 %9, 0
%35 = sitofp i32 %11 to double
%36 = sitofp i32 %3 to double
%37 = fneg double %36
%38 = icmp sgt i32 %8, 0
%39 = sitofp i32 %10 to double
%40 = sitofp i32 %2 to double
%41 = fneg double %40
br label %42
42: ; preds = %28, %136
%43 = phi double* [ %12, %28 ], [ %49, %136 ]
%44 = phi double* [ %14, %28 ], [ %138, %136 ]
%45 = phi double* [ %15, %28 ], [ %140, %136 ]
%46 = phi i32 [ 0, %28 ], [ %142, %136 ]
%47 = getelementptr inbounds double, double* %43, i64 %29
%48 = load double, double* %47
%49 = getelementptr inbounds double, double* %43, i64 1
%50 = load double, double* %43
%51 = fsub double %50, %31
%52 = tail call double @llvm.floor.f64(double %51)
%53 = fadd double %52, 1.000000e+00
%54 = fptosi double %53 to i32
br i1 %34, label %55, label %136
55: ; preds = %42
%56 = fsub double %48, %33
%57 = tail call double @llvm.floor.f64(double %56)
%58 = fadd double %57, 1.000000e+00
%59 = fptosi double %58 to i32
br label %60
60: ; preds = %55, %120
%61 = phi i32 [ %133, %120 ], [ 0, %55 ]
%62 = phi i32 [ %134, %120 ], [ %59, %55 ]
%63 = phi <2 x double> [ %132, %120 ], [ zeroinitializer, %55 ]
%64 = sitofp i32 %62 to double
%65 = fsub double %48, %64
%66 = fmul double %65, %35
%67 = fadd double %66, 5.000000e-01
%68 = tail call double @llvm.floor.f64(double %67)
%69 = fptosi double %68 to i32
%70 = sext i32 %69 to i64
%71 = getelementptr inbounds double, double* %25, i64 %70
%72 = load double, double* %71
%73 = getelementptr inbounds double, double* %26, i64 %70
%74 = load double, double* %73
%75 = fdiv double %64, %36
%76 = tail call double @llvm.floor.f64(double %75)
%77 = tail call double @llvm.fmuladd.f64(double %37, double %76, double %64)
%78 = fptosi double %77 to i32
%79 = mul nsw i32 %78, %2
br i1 %38, label %80, label %120
80: ; preds = %60, %80
%81 = phi i32 [ %118, %80 ], [ %54, %60 ]
%82 = phi i32 [ %117, %80 ], [ 0, %60 ]
%83 = phi <2 x double> [ %116, %80 ], [ zeroinitializer, %60 ]
%84 = sitofp i32 %81 to double
%85 = fsub double %50, %84
%86 = fmul double %85, %39
%87 = fadd double %86, 5.000000e-01
%88 = tail call double @llvm.floor.f64(double %87)
%89 = fptosi double %88 to i32
%90 = sext i32 %89 to i64
%91 = getelementptr inbounds double, double* %20, i64 %90
%92 = load double, double* %91
%93 = getelementptr inbounds double, double* %21, i64 %90
%94 = load double, double* %93
%95 = fdiv double %84, %40
%96 = tail call double @llvm.floor.f64(double %95)
%97 = tail call double @llvm.fmuladd.f64(double %41, double %96, double %84)
%98 = fptosi double %97 to i32
%99 = add nsw i32 %79, %98
%100 = sext i32 %99 to i64
%101 = getelementptr inbounds double, double* %0, i64 %100
%102 = load double, double* %101
%103 = getelementptr inbounds double, double* %1, i64 %100
%104 = load double, double* %103
%105 = fneg double %94
%106 = insertelement <2 x double> poison, double %94, i64 0
%107 = insertelement <2 x double> %106, double %104, i64 1
%108 = insertelement <2 x double> poison, double %102, i64 0
%109 = insertelement <2 x double> %108, double %105, i64 1
%110 = fmul <2 x double> %107, %109
%111 = insertelement <2 x double> poison, double %92, i64 0
%112 = shufflevector <2 x double> %111, <2 x double> poison, <2 x i32> zeroinitializer
%113 = insertelement <2 x double> poison, double %104, i64 0
%114 = insertelement <2 x double> %113, double %102, i64 1
%115 = call <2 x double> @llvm.fmuladd.v2f64(<2 x double> %112, <2 x double> %114, <2 x double> %110)
%116 = fadd <2 x double> %83, %115
%117 = add nuw nsw i32 %82, 1
%118 = add nsw i32 %81, 1
%119 = icmp eq i32 %117, %8
br i1 %119, label %120, label %80
120: ; preds = %80, %60
%121 = phi <2 x double> [ zeroinitializer, %60 ], [ %116, %80 ]
%122 = fneg double %74
%123 = insertelement <2 x double> poison, double %74, i64 0
%124 = shufflevector <2 x double> %123, <2 x double> %121, <2 x i32> <i32 0, i32 2>
%125 = extractelement <2 x double> %121, i64 1
%126 = insertelement <2 x double> poison, double %125, i64 0
%127 = insertelement <2 x double> %126, double %122, i64 1
%128 = fmul <2 x double> %124, %127
%129 = insertelement <2 x double> poison, double %72, i64 0
%130 = shufflevector <2 x double> %129, <2 x double> poison, <2 x i32> zeroinitializer
%131 = call <2 x double> @llvm.fmuladd.v2f64(<2 x double> %130, <2 x double> %121, <2 x double> %128)
%132 = fadd <2 x double> %63, %131
%133 = add nuw nsw i32 %61, 1
%134 = add nsw i32 %62, 1
%135 = icmp eq i32 %133, %9
br i1 %135, label %136, label %60
136: ; preds = %120, %42
%137 = phi <2 x double> [ zeroinitializer, %42 ], [ %132, %120 ]
%138 = getelementptr inbounds double, double* %44, i64 1
%139 = extractelement <2 x double> %137, i64 1
store double %139, double* %44
%140 = getelementptr inbounds double, double* %45, i64 1
%141 = extractelement <2 x double> %137, i64 0
store double %141, double* %45
%142 = add nuw nsw i32 %46, 1
%143 = icmp eq i32 %142, %13
br i1 %143, label %144, label %42
144: ; preds = %136, %16
ret void
}