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

```asm
<mp_mulhf>:
  endbr64
  push   %r15
  mov    %r8,%r11
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  mov    %edi,%ebp
  push   %rbx
  mov    %rcx,%rbx
  sub    $0x28,%rsp
  mov    0x60(%rsp),%r14d
  mov    0x68(%rsp),%r10
  mov    %esi,0x4(%rsp)
  mov    %rdx,%rsi
  mov    %r9,0x8(%rsp)
  mov    0x70(%rsp),%r15
  mov    %r14d,%r12d
  sar    %r12d
  add    $0x1,%r12d
  cmp    %edi,%r12d
  jge    L42
  movslq %r12d,%rdx
  jmp    L2
  nopl   0x0(%rax)
L8:
  lea    0x1(%rdx),%r12d
  add    $0x1,%rdx
  cmp    %edx,%ebp
  jle    L42
L2:
  cmpw   $0x0,0x8(%rbx,%rdx,2)
  mov    %edx,%r12d
  je     L8
L42:
  mov    %ebp,%r13d
  mov    %ebp,%edx
  mov    %rsi,%r8
  mov    0x4(%rsp),%esi
  shr    $0x1f,%r13d
  sub    %r12d,%edx
  mov    %r10,%r9
  mov    %ebp,%edi
  add    %ebp,%r13d
  mov    %r11,0x18(%rsp)
  sar    %r13d
  mov    %r10,0x10(%rsp)
  add    $0x1,%r13d
  cmp    %edx,%r13d
  cmovl  %edx,%r13d
  xor    %ecx,%ecx
  mov    %r14d,%edx
  call   <mp_mul_i2d@plt>
  mov    0x4(%rsp),%esi
  mov    %r15,%r9
  mov    %rbx,%r8
  xor    %ecx,%ecx
  mov    %r14d,%edx
  mov    %ebp,%edi
  call   <mp_mul_i2d@plt>
  mov    0x10(%rsp),%rsi
  mov    %r15,%rdx
  mov    %r14d,%edi
  call   <mp_mul_cmul@plt>
  mov    0x8(%rsp),%r8
  mov    0x4(%rsp),%esi
  mov    %ebp,%edi
  mov    %r15,%rcx
  mov    %r14d,%edx
  call   <mp_mul_d2i@plt>
  mov    %rbx,%r8
  mov    0x4(%rsp),%ebx
  mov    %r15,%r9
  mov    %r12d,%ecx
  mov    %r14d,%edx
  mov    %ebp,%edi
  mov    %ebx,%esi
  call   <mp_mul_i2d@plt>
  mov    0x10(%rsp),%rsi
  mov    %r15,%rdx
  mov    %r14d,%edi
  call   <mp_mul_cmul_nt_d1@plt>
  mov    0x18(%rsp),%r11
  mov    %r15,%rcx
  mov    %r14d,%edx
  mov    %ebx,%esi
  mov    %r13d,%edi
  mov    %r11,%r8
  mov    %r11,0x10(%rsp)
  call   <mp_mul_d2i@plt>
  mov    0x10(%rsp),%r11
  mov    (%r11),%eax
  test   %eax,%eax
  je     L19
  mov    0x8(%rsp),%rcx
  add    $0x28,%rsp
  mov    %ebx,%esi
  mov    %ebp,%edi
  pop    %rbx
  mov    %r11,%r8
  pop    %rbp
  mov    %r11,%rdx
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  jmp    10e0 <mp_add@plt>
  nopl   0x0(%rax)
L19:
  mov    0x8(%rsp),%rdx
  mov    0x4(%rsp),%esi
  add    $0x28,%rsp
  mov    %ebp,%edi
  pop    %rbx
  mov    %r11,%rcx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  jmp    10b0 <mp_copy@plt>
```

assistant: ```c
void mp_mulhf(int n, int radix, int in1[], int in2[], int out[], int tmp[], int nfft, double in1fft[], double tmpfft[]) {
  void mp_copy(int n, int radix, int in[], int out[]);
  void mp_add(int n, int radix, int in1[], int in2[], int out[]);
  void mp_mul_i2d(int n, int radix, int nfft, int shift, int in[], double dout[]);
  void mp_mul_cmul(int nfft, double d1[], double d2[]);
  void mp_mul_cmul_nt_d1(int nfft, double d1[], double d2[]);
  void mp_mul_d2i(int n, int radix, int nfft, double din[], int out[]);
  int n_h, shift;
  short int *in2dgt;
  in2dgt = (short int *)&in2[2];
  shift = (nfft >> 1) + 1;
  while (n > shift) {
    if (in2dgt[shift] != 0) {
      break;
    }
    shift++;
  }
  n_h = n / 2 + 1;
  if (n_h < n - shift) {
    n_h = n - shift;
  }
  mp_mul_i2d(n, radix, nfft, 0, in1, in1fft);
  mp_mul_i2d(n, radix, nfft, 0, in2, tmpfft);
  mp_mul_cmul(nfft, in1fft, tmpfft);
  mp_mul_d2i(n, radix, nfft, tmpfft, tmp);
  mp_mul_i2d(n, radix, nfft, shift, in2, tmpfft);
  mp_mul_cmul_nt_d1(nfft, in1fft, tmpfft);
  mp_mul_d2i(n_h, radix, nfft, tmpfft, out);
  if (out[0] != 0) {
    mp_add(n, radix, out, tmp, out);
  } else {
    mp_copy(n, radix, tmp, out);
  }
}
```