// File: /workspace/github_c_makefile_star2_O3/diaxen[P]fft-garden/mr_dit_dr.c
// Function: mr_dit_dr
static inline void
mr_dit_dr(const complex double * restrict in,
	      complex double * restrict out,
	      int s, int log2_N)
{
  unsigned l = 1 << (log2_N - s);
  unsigned stride = 1 << s;

  switch (l)
    {
    case 2:			/* last stage radix 2 */
      ct_dit_bf2_0(1, stride, out, in);
      break;

    case 4:			/* last stage radix 4 */
      mr_dit_bf4_0(1, stride, out, in);
      break;

    default:
      l >>= 2;
      mr_dit_dr(in,              out,         s + 2, log2_N);
      mr_dit_dr(in + stride,     out + l,     s + 2, log2_N);
      mr_dit_dr(in + stride * 2, out + 2 * l, s + 2, log2_N);
      mr_dit_dr(in + stride * 3, out + 3 * l, s + 2, log2_N);

      for (unsigned k = 0; k < l; k++)
        mr_dit_bf4(l, out + k,
               get_twiddle(k << s, log2_N),
               get_twiddle(k * 2 << s, log2_N),
               get_twiddle_mr(k * 3 << s, log2_N));
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xb8, %rsp
movl %ecx, %r12d
movl %edx, %r8d
movq %rsi, %rbx
movl %ecx, %eax
subl %edx, %eax
movl $0x1, %ebp
movl $0x1, %r15d
movl %eax, %ecx
shll %cl, %r15d
movl %r8d, %ecx
shll %cl, %ebp
movq %rdi, %r13
shlq $0x4, %rbp
addq %rdi, %rbp
cmpl $0x4, %r15d
je 0x1a8d
cmpl $0x2, %r15d
jne 0x1b52
movupd (%r13), %xmm1
movupd (%rbp), %xmm0
movapd %xmm1, %xmm2
addpd %xmm0, %xmm2
movupd %xmm2, (%rbx)
subpd %xmm0, %xmm1
movl $0x18, %eax
movl $0x10, %ecx
jmp 0x1b36
movl $0x2, %eax
movl %r8d, %ecx
shll %cl, %eax
movl $0x3, %edx
shll %cl, %edx
shlq $0x4, %rax
shlq $0x4, %rdx
movupd (%r13), %xmm3
movupd (%rbp), %xmm5
movupd (%r13,%rax), %xmm6
movupd (%r13,%rdx), %xmm7
movapd %xmm5, %xmm4
subpd %xmm7, %xmm4
xorpd %xmm0, %xmm0
mulpd %xmm4, %xmm0
movapd %xmm4, %xmm1
shufpd $0x1, %xmm4, %xmm1      # xmm1 = xmm1[1],xmm4[0]
movapd %xmm0, %xmm2
subpd %xmm1, %xmm2
addpd %xmm0, %xmm1
movapd %xmm1, %xmm0
movsd %xmm2, %xmm0            # xmm0 = xmm2[0],xmm0[1]
ucomisd %xmm2, %xmm2
jp 0x20cb
movapd %xmm3, %xmm1
subpd %xmm6, %xmm1
addpd %xmm7, %xmm5
addpd %xmm6, %xmm3
movapd %xmm3, %xmm2
addpd %xmm5, %xmm2
movupd %xmm2, (%rbx)
movapd %xmm1, %xmm2
subpd %xmm0, %xmm2
movupd %xmm2, 0x10(%rbx)
subpd %xmm5, %xmm3
movupd %xmm3, 0x20(%rbx)
addpd %xmm0, %xmm1
movl $0x38, %eax
movl $0x30, %ecx
movlpd %xmm1, (%rbx,%rcx)
movhpd %xmm1, (%rbx,%rax)
addq $0xb8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
shrl $0x2, %r15d
leal 0x2(%r8), %edx
movl %edx, 0x10(%rsp)
movq %r13, %rdi
movq %rbx, %rsi
movl %r12d, %ecx
movq %r8, 0x40(%rsp)
movl %eax, 0x20(%rsp)
callq 0x1a16
movq %r15, %r14
shlq $0x4, %r14
addq %rbx, %r14
movq %rbp, %rdi
movq %r14, %rsi
movl 0x10(%rsp), %ebp
movl %ebp, %edx
movl %r12d, %ecx
callq 0x1a16
movl $0x2, %edi
movq 0x40(%rsp), %rcx
shll %cl, %edi
shlq $0x4, %rdi
addq %r13, %rdi
leal (%r15,%r15), %esi
shlq $0x4, %rsi
addq %rbx, %rsi
movl %ebp, %edx
movl %r12d, %ecx
callq 0x1a16
movl $0x3, %edi
movq 0x40(%rsp), %rcx
shll %cl, %edi
shlq $0x4, %rdi
addq %r13, %rdi
leal (%r15,%r15,2), %esi
shlq $0x4, %rsi
addq %rbx, %rsi
movl %ebp, %edx
movl %r12d, %ecx
callq 0x1a16
movq 0x40(%rsp), %rcx
cmpl $0x2, 0x20(%rsp)
jb 0x1b40
movq %r14, %rdi
cmpl $0x2, %r15d
movl $0x1, %r8d
cmovael %r15d, %r8d
leaq (%r15,%r15,2), %rbp
shlq $0x4, %rbp
addq %rbx, %rbp
shlq $0x5, %r15
addq %rbx, %r15
addl %r8d, %r8d
xorl %r13d, %r13d
leaq 0x345d(%rip), %r9       # 0x5080
xorpd %xmm6, %xmm6
movsd 0x1621(%rip), %xmm3     # 0x3250
xorl %r12d, %r12d
xorl %r14d, %r14d
movl %r13d, %eax
shll %cl, %eax
movl %r12d, %edx
shll %cl, %edx
movq (%r9), %rsi
shlq $0x4, %rdx
movupd (%rsi,%rdx), %xmm7
movl %r14d, %edx
shll %cl, %edx
shlq $0x4, %rax
shlq $0x4, %rdx
movupd (%rsi,%rdx), %xmm5
movsd (%rbx,%r12,8), %xmm8
movsd 0x8(%rbx,%r12,8), %xmm9
movupd (%rsi,%rax), %xmm2
movupd (%rdi,%r12,8), %xmm0
movapd %xmm2, %xmm10
mulpd %xmm0, %xmm10
movapd %xmm2, %xmm1
shufpd $0x1, %xmm2, %xmm1      # xmm1 = xmm1[1],xmm2[0]
mulpd %xmm0, %xmm1
movapd %xmm10, %xmm4
unpckhpd %xmm10, %xmm4           # xmm4 = xmm4[1],xmm10[1]
subsd %xmm4, %xmm10
movapd %xmm1, %xmm11
unpckhpd %xmm1, %xmm11           # xmm11 = xmm11[1],xmm1[1]
addsd %xmm1, %xmm11
ucomisd %xmm10, %xmm10
jp 0x1e19
movupd (%r15,%r12,8), %xmm0
movapd %xmm7, %xmm12
mulpd %xmm0, %xmm12
movapd %xmm7, %xmm1
shufpd $0x1, %xmm7, %xmm1      # xmm1 = xmm1[1],xmm7[0]
mulpd %xmm0, %xmm1
movapd %xmm12, %xmm2
unpckhpd %xmm12, %xmm2           # xmm2 = xmm2[1],xmm12[1]
subsd %xmm2, %xmm12
movapd %xmm1, %xmm13
unpckhpd %xmm1, %xmm13           # xmm13 = xmm13[1],xmm1[1]
addsd %xmm1, %xmm13
ucomisd %xmm12, %xmm12
jp 0x1ea8
movupd (%rbp,%r12,8), %xmm0
movapd %xmm5, %xmm7
mulpd %xmm0, %xmm7
movapd %xmm5, %xmm1
shufpd $0x1, %xmm5, %xmm1      # xmm1 = xmm1[1],xmm5[0]
mulpd %xmm0, %xmm1
movapd %xmm7, %xmm2
unpckhpd %xmm7, %xmm2            # xmm2 = xmm2[1],xmm7[1]
subsd %xmm2, %xmm7
movapd %xmm1, %xmm2
unpckhpd %xmm1, %xmm2            # xmm2 = xmm2[1],xmm1[1]
addsd %xmm1, %xmm2
ucomisd %xmm7, %xmm7
jp 0x1f4b
movapd %xmm10, %xmm5
subsd %xmm7, %xmm5
movapd %xmm11, %xmm4
subsd %xmm2, %xmm4
movapd %xmm5, %xmm0
mulsd %xmm6, %xmm0
movapd %xmm4, %xmm1
mulsd %xmm6, %xmm1
subsd %xmm4, %xmm0
addsd %xmm5, %xmm1
ucomisd %xmm0, %xmm0
jp 0x2001
addsd %xmm2, %xmm11
addsd %xmm7, %xmm10
movapd %xmm9, %xmm2
subsd %xmm13, %xmm2
movapd %xmm8, %xmm7
subsd %xmm12, %xmm7
addsd %xmm13, %xmm9
addsd %xmm12, %xmm8
movapd %xmm8, %xmm4
addsd %xmm10, %xmm4
movapd %xmm9, %xmm5
addsd %xmm11, %xmm5
movsd %xmm4, (%rbx,%r12,8)
movsd %xmm5, 0x8(%rbx,%r12,8)
movapd %xmm7, %xmm4
subsd %xmm0, %xmm4
movapd %xmm2, %xmm5
subsd %xmm1, %xmm5
movsd %xmm4, (%rdi,%r12,8)
movsd %xmm5, 0x8(%rdi,%r12,8)
subsd %xmm10, %xmm8
subsd %xmm11, %xmm9
movsd %xmm8, (%r15,%r12,8)
movsd %xmm9, 0x8(%r15,%r12,8)
addsd %xmm0, %xmm7
addsd %xmm1, %xmm2
movsd %xmm7, (%rbp,%r12,8)
movsd %xmm2, 0x8(%rbp,%r12,8)
addl $0x3, %r14d
addq $0x2, %r12
incl %r13d
cmpq %r12, %r8
jne 0x1c35
jmp 0x1b40
ucomisd %xmm11, %xmm11
jnp 0x1cb5
movapd %xmm2, %xmm3
unpckhpd %xmm2, %xmm3            # xmm3 = xmm3[1],xmm2[1]
movapd %xmm0, %xmm1
unpckhpd %xmm0, %xmm1            # xmm1 = xmm1[1],xmm0[1]
movq %rdi, 0x20(%rsp)
movq %r8, 0x10(%rsp)
movsd %xmm8, 0x30(%rsp)
movsd %xmm9, 0x8(%rsp)
movapd %xmm5, 0x50(%rsp)
movapd %xmm7, 0x60(%rsp)
callq 0x2140
movapd 0x60(%rsp), %xmm7
movapd 0x50(%rsp), %xmm5
movsd 0x8(%rsp), %xmm9
movsd 0x30(%rsp), %xmm8
movsd 0x13d1(%rip), %xmm3     # 0x3250
xorpd %xmm6, %xmm6
leaq 0x31f6(%rip), %r9       # 0x5080
movq 0x10(%rsp), %r8
movq 0x20(%rsp), %rdi
movq 0x40(%rsp), %rcx
movapd %xmm0, %xmm10
movapd %xmm1, %xmm11
jmp 0x1cb5
ucomisd %xmm13, %xmm13
jnp 0x1cfb
movapd %xmm7, %xmm2
movapd %xmm7, %xmm3
unpckhpd %xmm7, %xmm3            # xmm3 = xmm3[1],xmm7[1]
movapd %xmm0, %xmm1
unpckhpd %xmm0, %xmm1            # xmm1 = xmm1[1],xmm0[1]
movq %rdi, 0x20(%rsp)
movq %r8, 0x10(%rsp)
movsd %xmm8, 0x30(%rsp)
movsd %xmm9, 0x8(%rsp)
movapd %xmm10, 0x60(%rsp)
movapd %xmm11, 0x70(%rsp)
movapd %xmm5, 0x50(%rsp)
callq 0x2140
movapd 0x50(%rsp), %xmm5
movapd 0x70(%rsp), %xmm11
movapd 0x60(%rsp), %xmm10
movsd 0x8(%rsp), %xmm9
movsd 0x30(%rsp), %xmm8
movsd 0x132e(%rip), %xmm3     # 0x3250
xorpd %xmm6, %xmm6
leaq 0x3153(%rip), %r9       # 0x5080
movq 0x10(%rsp), %r8
movq 0x20(%rsp), %rdi
movq 0x40(%rsp), %rcx
movapd %xmm0, %xmm12
movapd %xmm1, %xmm13
jmp 0x1cfb
ucomisd %xmm2, %xmm2
jnp 0x1d39
movapd %xmm5, %xmm2
movapd %xmm5, %xmm3
unpckhpd %xmm5, %xmm3            # xmm3 = xmm3[1],xmm5[1]
movapd %xmm0, %xmm1
unpckhpd %xmm0, %xmm1            # xmm1 = xmm1[1],xmm0[1]
movq %rdi, 0x20(%rsp)
movq %r8, 0x10(%rsp)
movsd %xmm8, 0x30(%rsp)
movsd %xmm9, 0x8(%rsp)
movapd %xmm10, 0x60(%rsp)
movapd %xmm11, 0x70(%rsp)
movapd %xmm12, 0x50(%rsp)
movapd %xmm13, 0x80(%rsp)
callq 0x2140
movapd 0x80(%rsp), %xmm13
movapd 0x50(%rsp), %xmm12
movapd 0x70(%rsp), %xmm11
movapd 0x60(%rsp), %xmm10
movsd 0x8(%rsp), %xmm9
movsd 0x30(%rsp), %xmm8
movsd 0x1276(%rip), %xmm3     # 0x3250
xorpd %xmm6, %xmm6
leaq 0x309b(%rip), %r9       # 0x5080
movq 0x10(%rsp), %r8
movq 0x20(%rsp), %rdi
movq 0x40(%rsp), %rcx
movapd %xmm0, %xmm7
movapd %xmm1, %xmm2
jmp 0x1d39
ucomisd %xmm1, %xmm1
jnp 0x1d6d
movapd %xmm2, 0x90(%rsp)
xorpd %xmm2, %xmm2
movapd %xmm5, %xmm0
movapd %xmm4, %xmm1
movq %rdi, 0x20(%rsp)
movq %r8, 0x10(%rsp)
movsd %xmm8, 0x30(%rsp)
movsd %xmm9, 0x8(%rsp)
movapd %xmm10, 0x60(%rsp)
movapd %xmm11, 0x70(%rsp)
movapd %xmm12, 0x50(%rsp)
movapd %xmm13, 0x80(%rsp)
movapd %xmm7, 0xa0(%rsp)
callq 0x2140
movapd 0x90(%rsp), %xmm2
movapd 0xa0(%rsp), %xmm7
movapd 0x80(%rsp), %xmm13
movapd 0x50(%rsp), %xmm12
movapd 0x70(%rsp), %xmm11
movapd 0x60(%rsp), %xmm10
movsd 0x8(%rsp), %xmm9
movsd 0x30(%rsp), %xmm8
movsd 0x11a4(%rip), %xmm3     # 0x3250
xorpd %xmm6, %xmm6
leaq 0x2fc9(%rip), %r9       # 0x5080
movq 0x10(%rsp), %r8
movq 0x20(%rsp), %rdi
movq 0x40(%rsp), %rcx
jmp 0x1d6d
unpckhpd %xmm1, %xmm1            # xmm1 = xmm1[1,1]
ucomisd %xmm1, %xmm1
jnp 0x1af6
movapd %xmm4, %xmm1
unpckhpd %xmm4, %xmm1            # xmm1 = xmm1[1],xmm4[1]
movapd %xmm3, 0x40(%rsp)
movsd 0x1161(%rip), %xmm3     # 0x3250
xorpd %xmm2, %xmm2
movapd %xmm4, %xmm0
movapd %xmm5, 0x20(%rsp)
movapd %xmm6, 0x10(%rsp)
movapd %xmm7, 0x30(%rsp)
callq 0x2140
movapd 0x30(%rsp), %xmm7
movapd 0x10(%rsp), %xmm6
movapd 0x20(%rsp), %xmm5
movapd 0x40(%rsp), %xmm3
unpcklpd %xmm1, %xmm0            # xmm0 = xmm0[0],xmm1[0]
jmp 0x1af6