user: Translate the below assembly code into C programming language:

```asm
<sincApply>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x40,%rsp
  movsd  %xmm0,-0x28(%rbp)
  mov    %edi,-0x2c(%rbp)
  mov    %rsi,-0x38(%rbp)
  mov    %edx,-0x30(%rbp)
  mov    -0x30(%rbp),%eax
  sub    $0x1,%eax
  mov    %eax,-0x14(%rbp)
  movl   $0x0,-0x18(%rbp)
  jmp    L112
L57:
  mov    -0x14(%rbp),%eax
  mov    %eax,%edx
  shr    $0x1f,%edx
  add    %edx,%eax
  sar    %eax
  neg    %eax
  mov    %eax,%edx
  mov    -0x18(%rbp),%eax
  add    %edx,%eax
  test   %eax,%eax
  jne    L120
  mov    D12(%rip),%rax
  movsd  (%rax),%xmm0
  addsd  %xmm0,%xmm0
  mov    -0x18(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x38(%rbp),%rax
  add    %rdx,%rax
  mulsd  -0x28(%rbp),%xmm0
  movsd  %xmm0,(%rax)
  jmp    L34
L120:
  mov    -0x14(%rbp),%eax
  mov    %eax,%edx
  shr    $0x1f,%edx
  add    %edx,%eax
  sar    %eax
  neg    %eax
  mov    %eax,%edx
  mov    -0x18(%rbp),%eax
  add    %edx,%eax
  pxor   %xmm0,%xmm0
  cvtsi2sd %eax,%xmm0
  movsd  %xmm0,-0x8(%rbp)
  mov    D12(%rip),%rax
  movsd  (%rax),%xmm0
  addsd  %xmm0,%xmm0
  mulsd  -0x28(%rbp),%xmm0
  mulsd  -0x8(%rbp),%xmm0
  movq   %xmm0,%rax
  movq   %rax,%xmm0
  call   <sin@plt>
  movq   %xmm0,%rax
  mov    -0x18(%rbp),%edx
  movslq %edx,%rdx
  lea    0x0(,%rdx,8),%rcx
  mov    -0x38(%rbp),%rdx
  add    %rcx,%rdx
  movq   %rax,%xmm0
  divsd  -0x8(%rbp),%xmm0
  movsd  %xmm0,(%rdx)
  cmpl   $0x2,-0x2c(%rbp)
  je     L38
  cmpl   $0x2,-0x2c(%rbp)
  jg     L84
  cmpl   $0x0,-0x2c(%rbp)
  je     L15
  cmpl   $0x1,-0x2c(%rbp)
  je     L94
  jmp    L84
L15:
  mov    -0x30(%rbp),%edx
  mov    -0x18(%rbp),%eax
  mov    %edx,%esi
  mov    %eax,%edi
  call   <wdw_Hamming@plt>
  mov    -0x18(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x38(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm1
  mov    -0x18(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x38(%rbp),%rax
  add    %rdx,%rax
  mulsd  %xmm1,%xmm0
  movsd  %xmm0,(%rax)
  jmp    L34
L94:
  mov    -0x30(%rbp),%edx
  mov    -0x18(%rbp),%eax
  mov    %edx,%esi
  mov    %eax,%edi
  call   <wdw_Blackman@plt>
  mov    -0x18(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x38(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm1
  mov    -0x18(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x38(%rbp),%rax
  add    %rdx,%rax
  mulsd  %xmm1,%xmm0
  movsd  %xmm0,(%rax)
  jmp    L34
L38:
  mov    -0x30(%rbp),%edx
  mov    -0x18(%rbp),%eax
  mov    %edx,%esi
  mov    %eax,%edi
  call   <wdw_Hanning@plt>
  mov    -0x18(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x38(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm1
  mov    -0x18(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x38(%rbp),%rax
  add    %rdx,%rax
  mulsd  %xmm1,%xmm0
  movsd  %xmm0,(%rax)
  jmp    L34
L84:
  mov    $0x0,%edi
  call   <assert@plt>
L34:
  addl   $0x1,-0x18(%rbp)
L112:
  mov    -0x18(%rbp),%eax
  cmp    -0x30(%rbp),%eax
  jl     L57
  movl   $0x0,-0x18(%rbp)
  pxor   %xmm0,%xmm0
  movsd  %xmm0,-0x10(%rbp)
  jmp    L96
L1:
  mov    -0x18(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x38(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm0
  movsd  -0x10(%rbp),%xmm1
  addsd  %xmm1,%xmm0
  movsd  %xmm0,-0x10(%rbp)
  addl   $0x1,-0x18(%rbp)
L96:
  mov    -0x18(%rbp),%eax
  cmp    -0x30(%rbp),%eax
  jl     L1
  movl   $0x0,-0x18(%rbp)
  jmp    L8
L125:
  mov    -0x18(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x38(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm0
  mov    -0x18(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x38(%rbp),%rax
  add    %rdx,%rax
  divsd  -0x10(%rbp),%xmm0
  movsd  %xmm0,(%rax)
  addl   $0x1,-0x18(%rbp)
L8:
  mov    -0x18(%rbp),%eax
  cmp    -0x30(%rbp),%eax
  jl     L125
  nop
  nop
  leave
  ret
```

assistant: ```c
void sincApply(double fc, int wdw, double a[], int m) {
  int i;
  int Mp = m - 1;
  double sum;
  for (i = 0; i < m; i++) {
    if ((i - (Mp / 2)) == 0) {
      a[i] = 2.0 * M_PI * fc;
    } else {
      double k = (double)(i - (Mp / 2));
      a[i] = sin(2.0 * M_PI * fc * k) / k;
      switch (wdw) {
      case 0:
        a[i] *= wdw_Hamming(i, m);
        break;
      case 1:
        a[i] *= wdw_Blackman(i, m);
        break;
      case 2:
        a[i] *= wdw_Hanning(i, m);
        break;
      default:
        assert(0);
      }
    }
  }
  for (i = 0, sum = 0.0; i < m; i++) {
    sum += a[i];
  }
  for (i = 0; i < m; i++) {
    a[i] /= sum;
  }
}
```