user: What would the C source look like for the assembly code provided here?

```asm
<drfti1>:
  endbr64
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x58,%rsp
  mov    %edi,0x48(%rsp)
  mov    %rsi,%r15
  mov    %rdx,%r9
  mov    $0x0,%r10d
  mov    $0x0,%esi
  mov    $0x0,%ecx
  lea    D9(%rip),%r11
  mov    %edi,%r8d
  jmp    L89
L47:
  add    $0x2,%ecx
  jmp    L60
L28:
  add    $0x1,%r10
  mov    %edi,%r8d
L89:
  cmp    $0x3,%r10d
  jg     L47
  mov    (%r11,%r10,4),%ecx
L60:
  movslq %esi,%rax
  lea    (%r9,%rax,4),%rbx
  jmp    L111
L155:
  mov    (%rax),%edi
  mov    %edi,0x4(%rax)
  sub    $0x4,%rax
  cmp    %r13,%rax
  jne    L155
L70:
  movl   $0x2,0x8(%r9)
L49:
  add    $0x4,%rbx
  cmp    $0x1,%r12d
  je     L164
  mov    %ebp,%esi
L111:
  mov    %r8d,%edi
  mov    %r8d,%eax
  cltd
  idiv   %ecx
  mov    %eax,%r12d
  mov    %eax,%r8d
  mov    %edi,%eax
  cltd
  idiv   %ecx
  test   %edx,%edx
  jne    L28
  lea    0x1(%rsi),%ebp
  mov    %ecx,0x8(%rbx)
  test   %esi,%esi
  je     L49
  cmp    $0x2,%ecx
  jne    L49
  cmp    $0x1,%ebp
  jle    L70
  movslq %ebp,%rax
  lea    (%r9,%rax,4),%rax
  lea    -0x1(%rsi),%edi
  shl    $0x2,%rdi
  mov    %rbx,%r13
  sub    %rdi,%r13
  jmp    L155
L164:
  mov    %r8d,0x38(%rsp)
  mov    %edx,0x4c(%rsp)
  mov    0x48(%rsp),%eax
  mov    %eax,(%r9)
  mov    %ebp,0x4(%r9)
  pxor   %xmm0,%xmm0
  cvtsi2ss %eax,%xmm0
  movss  D8(%rip),%xmm1
  divss  %xmm0,%xmm1
  movss  %xmm1,0x30(%rsp)
  test   %esi,%esi
  jle    L83
  lea    0x8(%r9),%rax
  mov    %rax,0x28(%rsp)
  lea    -0x1(%rsi),%eax
  lea    0xc(%r9,%rax,4),%rax
  mov    %rax,0x40(%rsp)
  mov    %edx,0x34(%rsp)
L161:
  mov    0x28(%rsp),%rax
  mov    (%rax),%ecx
  mov    %ecx,0x3c(%rsp)
  mov    0x38(%rsp),%eax
  mov    %eax,0x18(%rsp)
  imul   %ecx,%eax
  mov    %eax,%esi
  mov    %eax,0x38(%rsp)
  mov    0x48(%rsp),%eax
  cltd
  idiv   %esi
  mov    %eax,0xc(%rsp)
  cmp    $0x1,%ecx
  jle    L121
  movslq %eax,%rdx
  mov    %rdx,0x10(%rsp)
  movslq 0x34(%rsp),%r13
  lea    -0x1(%rcx),%esi
  mov    %esi,0x1c(%rsp)
  sub    $0x3,%eax
  shr    %eax
  mov    %eax,%eax
  add    %rax,%rax
  mov    %rax,0x20(%rsp)
  mov    0x4c(%rsp),%r14d
  mov    %r14d,%ebp
L24:
  add    0x18(%rsp),%ebp
  pxor   %xmm0,%xmm0
  cvtsi2ss %ebp,%xmm0
  mulss  0x30(%rsp),%xmm0
  movss  %xmm0,0x8(%rsp)
  cmpl   $0x2,0xc(%rsp)
  jle    L71
  lea    (%r15,%r13,4),%rbx
  mov    0x20(%rsp),%rax
  add    %r13,%rax
  lea    0x8(%r15,%rax,4),%r12
  pxor   %xmm5,%xmm5
  movss  %xmm5,(%rsp)
L100:
  movss  (%rsp),%xmm2
  addss  D12(%rip),%xmm2
  movss  %xmm2,(%rsp)
  movss  0x8(%rsp),%xmm3
  mulss  %xmm2,%xmm3
  movss  %xmm3,0x4(%rsp)
  movaps %xmm3,%xmm0
  call   <cos@plt>
  movss  %xmm0,(%rbx)
  movss  0x4(%rsp),%xmm0
  call   <sin@plt>
  movss  %xmm0,0x4(%rbx)
  add    $0x8,%rbx
  cmp    %r12,%rbx
  jne    L100
L71:
  add    $0x1,%r14d
  add    0x10(%rsp),%r13
  cmp    0x1c(%rsp),%r14d
  jne    L24
  mov    0x34(%rsp),%edx
  mov    0xc(%rsp),%esi
  add    %esi,%edx
  mov    0x3c(%rsp),%eax
  sub    $0x2,%eax
  imul   %esi,%eax
  add    %edx,%eax
  mov    %eax,0x34(%rsp)
L121:
  addq   $0x4,0x28(%rsp)
  mov    0x28(%rsp),%rax
  cmp    0x40(%rsp),%rax
  jne    L161
L83:
  add    $0x58,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
```

tool_calls: name: read_data
arguments: data_tag: D9
type_infered: string
name: read_data
arguments: data_tag: D8
type_infered: f32
name: read_data
arguments: data_tag: D12
type_infered: f32

tool: D9: 

tool: D8: 6.283185307179586

tool: D12: 1

assistant: ```c
void drfti1(int n, float *wa, int *ifac) {
  static int ntryh[4] = {4, 2, 3, 5};
  static float tpi = 6.28318530717958647692528676655900577;
  float arg, argh, argld, fi;
  int ntry = 0, i, j = -1;
  int k1, l1, l2, ib;
  int ld, ii, ip, is, nq, nr;
  int ido, ipm, nfm1;
  int nl = n;
  int nf = 0;
L101:
  j++;
  if (j < 4)
    ntry = ntryh[j];
  else
    ntry += 2;
L104:
  nq = nl / ntry;
  nr = nl - ntry * nq;
  if (nr != 0)
    goto L101;
  nf++;
  ifac[nf + 1] = ntry;
  nl = nq;
  if (ntry != 2)
    goto L107;
  if (nf == 1)
    goto L107;
  for (i = 1; i < nf; i++) {
    ib = nf - i + 1;
    ifac[ib + 1] = ifac[ib];
  }
  ifac[2] = 2;
L107:
  if (nl != 1)
    goto L104;
  ifac[0] = n;
  ifac[1] = nf;
  argh = tpi / n;
  is = 0;
  nfm1 = nf - 1;
  l1 = 1;
  if (nfm1 == 0)
    return;
  for (k1 = 0; k1 < nfm1; k1++) {
    ip = ifac[k1 + 2];
    ld = 0;
    l2 = l1 * ip;
    ido = n / l2;
    ipm = ip - 1;
    for (j = 0; j < ipm; j++) {
      ld += l1;
      i = is;
      argld = (float)ld * argh;
      fi = 0.;
      for (ii = 2; ii < ido; ii += 2) {
        fi += 1.;
        arg = fi * argld;
        wa[i++] = cos(arg);
        wa[i++] = sin(arg);
      }
      is += ido;
    }
    l1 = l2;
  }
}
```