user: 请从给定的汇编指令推导出C源代码：

```asm
<mp_mul_radix_test>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x40,%rsp
  mov    %edi,-0x14(%rbp)
  mov    %esi,-0x18(%rbp)
  mov    %edx,-0x1c(%rbp)
  mov    %rcx,-0x28(%rbp)
  mov    %r8,-0x30(%rbp)
  mov    %r9,-0x38(%rbp)
  mov    -0x1c(%rbp),%eax
  sar    %eax
  add    $0x1,%eax
  mov    %eax,-0x8(%rbp)
  mov    -0x8(%rbp),%eax
  cmp    -0x14(%rbp),%eax
  jle    L27
  mov    -0x14(%rbp),%eax
  mov    %eax,-0x8(%rbp)
L27:
  mov    -0x18(%rbp),%eax
  lea    -0x1(%rax),%edx
  mov    -0x1c(%rbp),%eax
  cltq
  add    $0x1,%rax
  lea    0x0(,%rax,8),%rcx
  mov    -0x28(%rbp),%rax
  add    %rcx,%rax
  pxor   %xmm0,%xmm0
  cvtsi2sd %edx,%xmm0
  movsd  %xmm0,(%rax)
  mov    -0x1c(%rbp),%eax
  mov    %eax,-0xc(%rbp)
  jmp    L6
L32:
  mov    -0xc(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x28(%rbp),%rax
  add    %rdx,%rax
  pxor   %xmm0,%xmm0
  movsd  %xmm0,(%rax)
  subl   $0x1,-0xc(%rbp)
L6:
  mov    -0xc(%rbp),%eax
  cmp    -0x8(%rbp),%eax
  jg     L32
  mov    -0x18(%rbp),%eax
  add    $0x1,%eax
  mov    %eax,%edx
  shr    $0x1f,%edx
  add    %edx,%eax
  sar    %eax
  mov    %eax,-0x4(%rbp)
  mov    -0x8(%rbp),%eax
  mov    %eax,-0xc(%rbp)
  jmp    L3
L35:
  mov    -0xc(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x28(%rbp),%rax
  add    %rdx,%rax
  pxor   %xmm0,%xmm0
  cvtsi2sdl -0x4(%rbp),%xmm0
  movsd  %xmm0,(%rax)
  subl   $0x1,-0xc(%rbp)
L3:
  cmpl   $0x2,-0xc(%rbp)
  jg     L35
  mov    -0x28(%rbp),%rax
  add    $0x10,%rax
  pxor   %xmm0,%xmm0
  cvtsi2sdl -0x18(%rbp),%xmm0
  movsd  %xmm0,(%rax)
  mov    -0x18(%rbp),%eax
  lea    -0x1(%rax),%edx
  mov    -0x28(%rbp),%rax
  add    $0x8,%rax
  pxor   %xmm0,%xmm0
  cvtsi2sd %edx,%xmm0
  movsd  %xmm0,(%rax)
  mov    -0x28(%rbp),%rax
  pxor   %xmm0,%xmm0
  movsd  %xmm0,(%rax)
  mov    -0x28(%rbp),%rax
  lea    0x8(%rax),%rsi
  mov    -0x38(%rbp),%rcx
  mov    -0x30(%rbp),%rdx
  mov    -0x1c(%rbp),%eax
  mov    %rcx,%r8
  mov    %rdx,%rcx
  mov    %rsi,%rdx
  mov    $0x1,%esi
  mov    %eax,%edi
  call   <rdft@plt>
  mov    -0x28(%rbp),%rdx
  mov    -0x1c(%rbp),%eax
  mov    %rdx,%rsi
  mov    %eax,%edi
  call   <mp_mul_csqu@plt>
  mov    -0x28(%rbp),%rax
  lea    0x8(%rax),%rsi
  mov    -0x38(%rbp),%rcx
  mov    -0x30(%rbp),%rdx
  mov    -0x1c(%rbp),%eax
  mov    %rcx,%r8
  mov    %rdx,%rcx
  mov    %rsi,%rdx
  mov    $0xffffffff,%esi
  mov    %eax,%edi
  call   <rdft@plt>
  mov    -0x28(%rbp),%rdx
  mov    -0x1c(%rbp),%ecx
  mov    -0x18(%rbp),%eax
  mov    %ecx,%esi
  mov    %eax,%edi
  call   <mp_mul_d2i_test@plt>
  addsd  %xmm0,%xmm0
  movq   %xmm0,%rax
  movq   %rax,%xmm0
  leave
  ret
```

assistant: ```c
double mp_mul_radix_test(int n, int radix, int nfft, double tmpfft[], int ip[], double w[]) {
  void rdft(int n, int isgn, double *a, int *ip, double *w);
  void mp_mul_csqu(int nfft, double dinout[]);
  double mp_mul_d2i_test(int radix, int nfft, double din[]);
  int j, ndata, radix_2;
  ndata = (nfft >> 1) + 1;
  if (ndata > n) {
    ndata = n;
  }
  tmpfft[nfft + 1] = radix - 1;
  for (j = nfft; j > ndata; j--) {
    tmpfft[j] = 0;
  }
  radix_2 = (radix + 1) / 2;
  for (j = ndata; j > 2; j--) {
    tmpfft[j] = radix_2;
  }
  tmpfft[2] = radix;
  tmpfft[1] = radix - 1;
  tmpfft[0] = 0;
  rdft(nfft, 1, &tmpfft[1], ip, w);
  mp_mul_csqu(nfft, tmpfft);
  rdft(nfft, -1, &tmpfft[1], ip, w);
  return 2 * mp_mul_d2i_test(radix, nfft, tmpfft);
}
```