user: Please show me the C implementation that matches the assembly code listed below:

```asm
<cftbsub>:
  endbr64
  push   %r13
  mov    %rdx,%r13
  push   %r12
  mov    %edi,%r12d
  push   %rbp
  push   %rbx
  mov    %rsi,%rbx
  sub    $0x38,%rsp
  cmp    $0x10,%edi
  jg     L80
  cmp    $0x8,%edi
  jle    L40
  movsd  0x10(%rdx),%xmm3
  mov    $0x2,%ebp
  movapd %xmm3,%xmm1
L114:
  movslq %ebp,%rcx
  lea    0x0(%rbp,%rbp,1),%eax
  movapd %xmm1,%xmm15
  movq   D25(%rip),%xmm3
  lea    0x0(,%rcx,8),%rdx
  shl    $0x4,%rcx
  cltq
  lea    (%rbx,%rdx,1),%r9
  lea    0x8(%rbx,%rax,8),%r10
  movaps %xmm3,0x20(%rsp)
  xor    %eax,%eax
  add    %r9,%rcx
  lea    (%rcx,%rdx,1),%r8
  lea    (%r8,%rdx,1),%rdi
  lea    (%rdi,%rdx,1),%rsi
  add    %rsi,%rdx
  nopl   0x0(%rax,%rax,1)
L26:
  movsd  (%rbx,%rax,8),%xmm13
  movsd  0x8(%rbx,%rax,8),%xmm0
  add    $0x10,%r9
  add    $0x10,%rcx
  movapd 0x20(%rsp),%xmm3
  movsd  (%r10),%xmm2
  add    $0x10,%r8
  add    $0x10,%rdi
  movsd  -0x10(%r9),%xmm4
  movsd  -0x8(%r9),%xmm1
  movapd %xmm13,%xmm5
  add    $0x10,%rsi
  movsd  -0x8(%rcx),%xmm7
  xorpd  %xmm0,%xmm3
  movsd  -0x10(%rcx),%xmm8
  add    $0x10,%rdx
  addsd  %xmm4,%xmm5
  subsd  %xmm1,%xmm3
  movsd  -0x10(%rdx),%xmm14
  add    $0x10,%r10
  subsd  %xmm4,%xmm13
  subsd  %xmm0,%xmm1
  movapd %xmm2,%xmm4
  movsd  -0x18(%r10),%xmm0
  addsd  %xmm7,%xmm4
  subsd  %xmm7,%xmm2
  movapd %xmm0,%xmm6
  subsd  %xmm8,%xmm0
  movapd %xmm3,%xmm7
  addsd  %xmm8,%xmm6
  movapd %xmm5,%xmm9
  movapd %xmm13,%xmm11
  movsd  -0x8(%rdx),%xmm8
  subsd  %xmm4,%xmm7
  addsd  %xmm4,%xmm3
  movapd %xmm1,%xmm4
  subsd  %xmm0,%xmm4
  addsd  %xmm0,%xmm1
  movsd  -0x10(%r8),%xmm0
  subsd  %xmm6,%xmm5
  addsd  %xmm6,%xmm9
  movsd  -0x8(%rdi),%xmm6
  movsd  %xmm7,(%rsp)
  movsd  -0x10(%rdi),%xmm7
  movapd %xmm0,%xmm12
  subsd  %xmm2,%xmm11
  movsd  %xmm4,0x10(%rsp)
  movsd  -0x8(%r8),%xmm4
  addsd  %xmm2,%xmm13
  movsd  -0x8(%rsi),%xmm2
  movsd  %xmm5,0x8(%rsp)
  addsd  %xmm7,%xmm12
  subsd  %xmm7,%xmm0
  movapd %xmm4,%xmm5
  subsd  %xmm6,%xmm4
  movapd %xmm2,%xmm7
  addsd  %xmm6,%xmm5
  movsd  -0x10(%rsi),%xmm6
  addsd  %xmm8,%xmm7
  subsd  %xmm8,%xmm2
  movapd %xmm6,%xmm10
  subsd  %xmm14,%xmm6
  addsd  %xmm14,%xmm10
  movapd %xmm12,%xmm14
  movapd %xmm5,%xmm8
  addsd  %xmm7,%xmm8
  subsd  %xmm7,%xmm5
  movapd %xmm4,%xmm7
  addsd  %xmm6,%xmm7
  subsd  %xmm6,%xmm4
  addsd  %xmm10,%xmm14
  subsd  %xmm10,%xmm12
  movsd  %xmm14,0x18(%rsp)
  movapd %xmm12,%xmm14
  movapd %xmm0,%xmm12
  addsd  %xmm2,%xmm0
  subsd  %xmm2,%xmm12
  movsd  0x10(%rsp),%xmm2
  movapd %xmm12,%xmm6
  addsd  %xmm7,%xmm12
  subsd  %xmm7,%xmm6
  movapd %xmm0,%xmm7
  addsd  %xmm4,%xmm0
  subsd  %xmm4,%xmm7
  movapd %xmm11,%xmm4
  movapd %xmm12,%xmm10
  mulsd  %xmm15,%xmm6
  mulsd  %xmm15,%xmm10
  mulsd  %xmm15,%xmm0
  mulsd  %xmm15,%xmm7
  addsd  %xmm6,%xmm4
  subsd  %xmm6,%xmm11
  movsd  %xmm4,-0x10(%r9)
  movapd %xmm2,%xmm4
  subsd  %xmm10,%xmm4
  addsd  %xmm2,%xmm10
  movsd  0x18(%rsp),%xmm2
  movsd  %xmm4,-0x8(%r9)
  movapd %xmm13,%xmm4
  addsd  %xmm0,%xmm13
  subsd  %xmm0,%xmm4
  movsd  %xmm11,-0x10(%rdi)
  movapd %xmm2,%xmm0
  movsd  %xmm10,-0x8(%rdi)
  addsd  %xmm9,%xmm0
  subsd  %xmm2,%xmm9
  movsd  %xmm4,-0x10(%rcx)
  movapd %xmm1,%xmm4
  addsd  %xmm7,%xmm1
  subsd  %xmm7,%xmm4
  movsd  %xmm4,-0x8(%rcx)
  movsd  %xmm13,-0x10(%rdx)
  movsd  %xmm1,-0x8(%rdx)
  movsd  %xmm0,(%rbx,%rax,8)
  movsd  (%rsp),%xmm1
  movsd  0x8(%rsp),%xmm6
  movapd %xmm1,%xmm0
  subsd  %xmm8,%xmm0
  addsd  %xmm1,%xmm8
  movsd  %xmm0,0x8(%rbx,%rax,8)
  movapd %xmm6,%xmm0
  add    $0x2,%rax
  subsd  %xmm5,%xmm0
  movsd  %xmm9,-0x10(%r8)
  addsd  %xmm6,%xmm5
  movsd  %xmm8,-0x8(%r8)
  movsd  %xmm0,-0x18(%r10)
  movapd %xmm3,%xmm0
  addsd  %xmm14,%xmm3
  subsd  %xmm14,%xmm0
  movsd  %xmm0,-0x10(%r10)
  movsd  %xmm5,-0x10(%rsi)
  movsd  %xmm3,-0x8(%rsi)
  cmp    %eax,%ebp
  jg     L26
L12:
  add    $0x38,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  ret
  nopw   0x0(%rax,%rax,1)
L40:
  mov    $0x2,%ebp
  je     L43
L178:
  movq   D25(%rip),%xmm3
  movslq %ebp,%rax
  xor    %edx,%edx
  lea    (%rbx,%rax,8),%rax
  add    $0x8,%rbx
  movapd %xmm3,%xmm5
  nopl   0x0(%rax)
L36:
  movsd  -0x8(%rbx),%xmm1
  movsd  (%rax),%xmm3
  add    $0x2,%edx
  add    $0x10,%rax
  movsd  (%rbx),%xmm0
  movsd  -0x8(%rax),%xmm2
  add    $0x10,%rbx
  movapd %xmm1,%xmm4
  subsd  %xmm3,%xmm1
  addsd  %xmm3,%xmm4
  subsd  %xmm0,%xmm2
  xorpd  %xmm5,%xmm0
  movsd  %xmm4,-0x18(%rbx)
  subsd  -0x8(%rax),%xmm0
  movsd  %xmm0,-0x10(%rbx)
  movsd  %xmm1,-0x10(%rax)
  movsd  %xmm2,-0x8(%rax)
  cmp    %ebp,%edx
  jl     L36
  add    $0x38,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  ret
  nopl   0x0(%rax)
L80:
  xor    %eax,%eax
  call   <cft1st@plt>
  cmp    $0x80,%r12d
  jle    L193
  mov    $0x10,%esi
  mov    $0x80,%ebp
  jmp    L172
  nopl   0x0(%rax,%rax,1)
L35:
  mov    %eax,%ebp
L172:
  mov    %r13,%rcx
  mov    %rbx,%rdx
  mov    %r12d,%edi
  xor    %eax,%eax
  call   <cftmdl@plt>
  lea    0x0(,%rbp,8),%eax
  mov    %ebp,%esi
  cmp    %r12d,%eax
  jl     L35
  lea    0x0(,%rbp,4),%eax
  cmp    %r12d,%eax
  jge    L110
  test   %ebp,%ebp
  jle    L12
  movsd  0x10(%r13),%xmm3
  movapd %xmm3,%xmm1
  jmp    L114
  nopl   0x0(%rax,%rax,1)
L110:
  je     L179
  test   %ebp,%ebp
  jg     L178
  jmp    L12
  nopw   0x0(%rax,%rax,1)
L179:
  test   %ebp,%ebp
  jle    L12
L43:
  movslq %ebp,%rdx
  movq   D25(%rip),%xmm3
  xor    %eax,%eax
  shl    $0x3,%rdx
  lea    (%rbx,%rdx,1),%rsi
  movapd %xmm3,%xmm9
  lea    (%rsi,%rdx,1),%rcx
  add    %rcx,%rdx
  nopl   0x0(%rax)
L102:
  movsd  (%rbx,%rax,8),%xmm4
  movsd  (%rsi),%xmm0
  add    $0x10,%rcx
  add    $0x10,%rsi
  movsd  0x8(%rbx,%rax,8),%xmm6
  movsd  (%rdx),%xmm10
  add    $0x10,%rdx
  movapd %xmm4,%xmm5
  subsd  %xmm0,%xmm4
  movsd  -0x8(%rsi),%xmm3
  movsd  -0x8(%rcx),%xmm1
  addsd  %xmm0,%xmm5
  movsd  -0x10(%rcx),%xmm0
  movapd %xmm6,%xmm2
  movsd  -0x8(%rdx),%xmm8
  xorpd  %xmm9,%xmm2
  movapd %xmm0,%xmm7
  subsd  %xmm3,%xmm2
  subsd  %xmm6,%xmm3
  addsd  %xmm10,%xmm7
  movapd %xmm1,%xmm6
  subsd  %xmm8,%xmm1
  addsd  %xmm8,%xmm6
  movapd %xmm5,%xmm8
  subsd  %xmm10,%xmm0
  addsd  %xmm7,%xmm8
  subsd  %xmm7,%xmm5
  movsd  %xmm8,(%rbx,%rax,8)
  movapd %xmm2,%xmm8
  addsd  %xmm6,%xmm2
  subsd  %xmm6,%xmm8
  movsd  %xmm8,0x8(%rbx,%rax,8)
  add    $0x2,%rax
  movsd  %xmm2,-0x8(%rcx)
  movapd %xmm4,%xmm2
  subsd  %xmm1,%xmm2
  movsd  %xmm5,-0x10(%rcx)
  addsd  %xmm4,%xmm1
  movsd  %xmm2,-0x10(%rsi)
  movapd %xmm3,%xmm2
  subsd  %xmm0,%xmm2
  addsd  %xmm3,%xmm0
  movsd  %xmm2,-0x8(%rsi)
  movsd  %xmm1,-0x10(%rdx)
  movsd  %xmm0,-0x8(%rdx)
  cmp    %eax,%ebp
  jg     L102
  add    $0x38,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  ret
L193:
  cmp    $0x40,%r12d
  jle    L145
  movsd  0x10(%r13),%xmm3
  mov    $0x10,%ebp
  movapd %xmm3,%xmm1
  jmp    L114
L145:
  mov    $0x10,%ebp
  jne    L178
  jmp    L43
```

tool_calls: name: extract_symbolic_data
arguments: tag: D25
type_guessed: byte[8]

tool: {"D25": [0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80]}

assistant: ```c
void cftbsub(int n, double *a, double *w) {
  int j, j1, j2, j3, j4, j5, j6, j7, l;
  double wn4r, x0r, x0i, x1r, x1i, x2r, x2i, x3r, x3i, y0r, y0i, y1r, y1i, y2r, y2i, y3r, y3i, y4r, y4i, y5r, y5i, y6r, y6i, y7r, y7i;
  l = 2;
  if (n > 16) {
    cft1st(n, a, w);
    l = 16;
    while ((l << 3) < n) {
      cftmdl(n, l, a, w);
      l <<= 3;
    }
  }
  if ((l << 2) < n) {
    wn4r = w[2];
    for (j = 0; j < l; j += 2) {
      j1 = j + l;
      j2 = j1 + l;
      j3 = j2 + l;
      j4 = j3 + l;
      j5 = j4 + l;
      j6 = j5 + l;
      j7 = j6 + l;
      x0r = a[j] + a[j1];
      x0i = -a[j + 1] - a[j1 + 1];
      x1r = a[j] - a[j1];
      x1i = -a[j + 1] + a[j1 + 1];
      x2r = a[j2] + a[j3];
      x2i = a[j2 + 1] + a[j3 + 1];
      x3r = a[j2] - a[j3];
      x3i = a[j2 + 1] - a[j3 + 1];
      y0r = x0r + x2r;
      y0i = x0i - x2i;
      y2r = x0r - x2r;
      y2i = x0i + x2i;
      y1r = x1r - x3i;
      y1i = x1i - x3r;
      y3r = x1r + x3i;
      y3i = x1i + x3r;
      x0r = a[j4] + a[j5];
      x0i = a[j4 + 1] + a[j5 + 1];
      x1r = a[j4] - a[j5];
      x1i = a[j4 + 1] - a[j5 + 1];
      x2r = a[j6] + a[j7];
      x2i = a[j6 + 1] + a[j7 + 1];
      x3r = a[j6] - a[j7];
      x3i = a[j6 + 1] - a[j7 + 1];
      y4r = x0r + x2r;
      y4i = x0i + x2i;
      y6r = x0r - x2r;
      y6i = x0i - x2i;
      x0r = x1r - x3i;
      x0i = x1i + x3r;
      x2r = x1r + x3i;
      x2i = x1i - x3r;
      y5r = wn4r * (x0r - x0i);
      y5i = wn4r * (x0r + x0i);
      y7r = wn4r * (x2r - x2i);
      y7i = wn4r * (x2r + x2i);
      a[j1] = y1r + y5r;
      a[j1 + 1] = y1i - y5i;
      a[j5] = y1r - y5r;
      a[j5 + 1] = y1i + y5i;
      a[j3] = y3r - y7i;
      a[j3 + 1] = y3i - y7r;
      a[j7] = y3r + y7i;
      a[j7 + 1] = y3i + y7r;
      a[j] = y0r + y4r;
      a[j + 1] = y0i - y4i;
      a[j4] = y0r - y4r;
      a[j4 + 1] = y0i + y4i;
      a[j2] = y2r - y6i;
      a[j2 + 1] = y2i - y6r;
      a[j6] = y2r + y6i;
      a[j6 + 1] = y2i + y6r;
    }
  } else if ((l << 2) == n) {
    for (j = 0; j < l; j += 2) {
      j1 = j + l;
      j2 = j1 + l;
      j3 = j2 + l;
      x0r = a[j] + a[j1];
      x0i = -a[j + 1] - a[j1 + 1];
      x1r = a[j] - a[j1];
      x1i = -a[j + 1] + a[j1 + 1];
      x2r = a[j2] + a[j3];
      x2i = a[j2 + 1] + a[j3 + 1];
      x3r = a[j2] - a[j3];
      x3i = a[j2 + 1] - a[j3 + 1];
      a[j] = x0r + x2r;
      a[j + 1] = x0i - x2i;
      a[j2] = x0r - x2r;
      a[j2 + 1] = x0i + x2i;
      a[j1] = x1r - x3i;
      a[j1 + 1] = x1i - x3r;
      a[j3] = x1r + x3i;
      a[j3 + 1] = x1i + x3r;
    }
  } else {
    for (j = 0; j < l; j += 2) {
      j1 = j + l;
      x0r = a[j] - a[j1];
      x0i = -a[j + 1] + a[j1 + 1];
      a[j] += a[j1];
      a[j + 1] = -a[j + 1] - a[j1 + 1];
      a[j1] = x0r;
      a[j1 + 1] = x0i;
    }
  }
}
```