user: 请将这段汇编代码片段转换成等效的C代码：

```asm
<ddct>:
  endbr64
  push   %r15
  mov    %esi,%r9d
  push   %r14
  mov    %r8,%r14
  push   %r13
  push   %r12
  mov    %edi,%r12d
  push   %rbp
  mov    %rdx,%rbp
  push   %rbx
  mov    %rcx,%rbx
  sub    $0x18,%rsp
  mov    (%rcx),%r13d
  lea    0x0(,%r13,4),%eax
  cmp    %edi,%eax
  jl     L128
L18:
  mov    0x4(%rbx),%r15d
  movslq %r13d,%r13
  lea    (%r14,%r13,4),%r13
  cmp    %r15d,%r12d
  jg     L25
L50:
  movslq %r12d,%rax
  lea    -0x4(%rbp,%rax,4),%r8
  test   %r9d,%r9d
  js     L78
  mov    %r13,%rcx
  mov    %r15d,%edx
  mov    %rbp,%rsi
  mov    %r12d,%edi
  mov    %r8,0x8(%rsp)
  call   <dctsub@plt>
  cmp    $0x4,%r12d
  mov    0x8(%rsp),%r8
  jg     L107
  je     L88
  movss  0x0(%rbp),%xmm0
  movss  0x4(%rbp),%xmm1
  movaps %xmm0,%xmm3
  addss  %xmm1,%xmm0
  subss  %xmm1,%xmm3
  movss  %xmm0,0x0(%rbp)
  cmp    $0x3,%r12d
  jne    L148
  movss  0x8(%rbp),%xmm0
  movss  0xc(%rbp),%xmm2
  movaps %xmm0,%xmm1
  addss  %xmm2,%xmm0
  subss  %xmm2,%xmm1
  unpcklps %xmm0,%xmm1
  movlps %xmm1,0x4(%rbp)
L148:
  movss  %xmm3,(%r8)
  add    $0x18,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
L78:
  lea    -0x2(%r12),%eax
  movss  (%r8),%xmm3
  cmp    $0x1,%eax
  jle    L7
  cltq
  lea    -0x4(%r12),%esi
  lea    0x0(,%rax,4),%rdx
  shr    %esi
  lea    0x0(%rbp,%rdx,1),%rax
  shl    $0x3,%rsi
  lea    -0x8(%rbp,%rdx,1),%rdx
  sub    %rsi,%rdx
  nopl   0x0(%rax)
L159:
  movss  (%rax),%xmm0
  movss  -0x4(%rax),%xmm2
  sub    $0x8,%rax
  movaps %xmm0,%xmm1
  subss  %xmm2,%xmm0
  addss  %xmm2,%xmm1
  unpcklps %xmm0,%xmm1
  movlps %xmm1,0x8(%rax)
  cmp    %rax,%rdx
  jne    L159
L7:
  movss  0x0(%rbp),%xmm0
  movaps %xmm0,%xmm1
  subss  %xmm3,%xmm0
  addss  %xmm3,%xmm1
  unpcklps %xmm0,%xmm1
  movlps %xmm1,0x0(%rbp)
  cmp    $0x4,%r12d
  jg     L76
  je     L147
L131:
  add    $0x18,%rsp
  mov    %r13,%rcx
  mov    %r15d,%edx
  mov    %rbp,%rsi
  pop    %rbx
  mov    %r12d,%edi
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  jmp    10e0 <dctsub@plt>
  nopw   0x0(%rax,%rax,1)
L25:
  mov    %r13,%rdx
  mov    %rbx,%rsi
  mov    %r12d,%edi
  mov    %r9d,0x8(%rsp)
  call   <makect@plt>
  mov    %r12d,%r15d
  mov    0x8(%rsp),%r9d
  jmp    L50
  nopl   0x0(%rax,%rax,1)
L128:
  mov    %edi,%r13d
  mov    %esi,0x8(%rsp)
  mov    %r8,%rdx
  mov    %rcx,%rsi
  sar    $0x2,%r13d
  mov    %r13d,%edi
  call   <makewt@plt>
  mov    0x8(%rsp),%r9d
  jmp    L18
  nopl   0x0(%rax,%rax,1)
L107:
  lea    0x8(%rbx),%rsi
  mov    %rbp,%rdx
  mov    %r12d,%edi
  mov    %r8,0x8(%rsp)
  call   <bitrv2@plt>
  mov    %r14,%rdx
  mov    %rbp,%rsi
  mov    %r12d,%edi
  call   <cftfsub@plt>
  mov    %r13,%rcx
  mov    %r15d,%edx
  mov    %rbp,%rsi
  mov    %r12d,%edi
  call   <rftfsub@plt>
  mov    0x8(%rsp),%r8
L115:
  movss  0x0(%rbp),%xmm1
  movss  0x4(%rbp),%xmm0
  mov    $0x2,%eax
  movaps %xmm1,%xmm3
  subss  %xmm0,%xmm3
  addss  %xmm1,%xmm0
  movss  %xmm0,0x0(%rbp)
  nop
L102:
  movss  0x0(%rbp,%rax,4),%xmm0
  movss  0x4(%rbp,%rax,4),%xmm2
  movaps %xmm0,%xmm1
  addss  %xmm2,%xmm0
  subss  %xmm2,%xmm1
  unpcklps %xmm0,%xmm1
  movlps %xmm1,-0x4(%rbp,%rax,4)
  add    $0x2,%rax
  cmp    %eax,%r12d
  jg     L102
  jmp    L148
  nopl   (%rax)
L76:
  mov    %r13,%rcx
  mov    %r15d,%edx
  mov    %rbp,%rsi
  mov    %r12d,%edi
  call   <rftbsub@plt>
  lea    0x8(%rbx),%rsi
  mov    %rbp,%rdx
  mov    %r12d,%edi
  call   <bitrv2@plt>
  mov    %r14,%rdx
  mov    %rbp,%rsi
  mov    %r12d,%edi
  call   <cftbsub@plt>
  jmp    L131
  nopl   0x0(%rax,%rax,1)
L88:
  mov    %r14,%rdx
  mov    %rbp,%rsi
  mov    $0x4,%edi
  mov    %r8,0x8(%rsp)
  call   <cftfsub@plt>
  mov    0x8(%rsp),%r8
  jmp    L115
  nopw   0x0(%rax,%rax,1)
L147:
  mov    %r14,%rdx
  mov    %rbp,%rsi
  mov    $0x4,%edi
  call   <cftfsub@plt>
  jmp    L131
```

assistant: ```c
void ddct(int n, int isgn, float *a, int *ip, float *w) {
  int j, nw, nc;
  float xr;
  nw = ip[0];
  if (n > (nw << 2)) {
    nw = n >> 2;
    makewt(nw, ip, w);
  }
  nc = ip[1];
  if (n > nc) {
    nc = n;
    makect(nc, ip, w + nw);
  }
  if (isgn < 0) {
    xr = a[n - 1];
    for (j = n - 2; j >= 2; j -= 2) {
      a[j + 1] = a[j] - a[j - 1];
      a[j] += a[j - 1];
    }
    a[1] = a[0] - xr;
    a[0] += xr;
    if (n > 4) {
      rftbsub(n, a, nc, w + nw);
      bitrv2(n, ip + 2, a);
      cftbsub(n, a, w);
    } else if (n == 4) {
      cftfsub(n, a, w);
    }
  }
  dctsub(n, a, nc, w + nw);
  if (isgn >= 0) {
    if (n > 4) {
      bitrv2(n, ip + 2, a);
      cftfsub(n, a, w);
      rftfsub(n, a, nc, w + nw);
    } else if (n == 4) {
      cftfsub(n, a, w);
    }
    xr = a[0] - a[1];
    a[0] += a[1];
    for (j = 2; j < n; j += 2) {
      a[j - 1] = a[j] - a[j + 1];
      a[j] += a[j + 1];
    }
    a[n - 1] = xr;
  }
}
```