user: 请将以下的汇编代码转换成C语言代码：

```asm
<tqli>:
  endbr64
  push   %r15
  movslq %edx,%rax
  push   %r14
  mov    %rax,%r15
  mov    %rsi,%r14
  push   %r13
  mov    %rdi,%r13
  push   %r12
  push   %rbp
  lea    (%rsi,%rax,4),%rbp
  push   %rbx
  sub    $0x58,%rsp
  mov    %rcx,(%rsp)
  cmp    $0x1,%eax
  jle    L241
  lea    -0x1(%rax),%edx
  lea    0x8(%rsi),%rsi
  mov    %rdx,%rbx
  lea    0x4(%r14),%rdi
  shl    $0x2,%rdx
  call   <memmove@plt>
  movl   $0x0,0x0(%rbp)
L158:
  mov    (%rsp),%rax
  movss  D156(%rip),%xmm5
  mov    $0x1,%esi
  movss  D137(%rip),%xmm4
  lea    0x10(%rax,%rbx,8),%r12
L227:
  mov    %esi,%r8d
  xor    %r9d,%r9d
L36:
  cmp    %r8d,%r15d
  jle    L180
  movss  0x0(%r13,%rsi,4),%xmm6
  mov    %rsi,%rax
  movaps %xmm6,%xmm2
  jmp    L51
  nopl   (%rax)
L13:
  add    $0x1,%rax
  lea    0x1(%rdx),%ebx
  cmp    %eax,%r15d
  jle    L99
L51:
  andps  %xmm4,%xmm2
  mov    %eax,%edx
  mov    %eax,%ebx
  movaps %xmm2,%xmm0
  movss  0x4(%r13,%rax,4),%xmm2
  movaps %xmm2,%xmm1
  andps  %xmm4,%xmm1
  addss  %xmm0,%xmm1
  movss  (%r14,%rax,4),%xmm0
  andps  %xmm4,%xmm0
  cvtss2sd %xmm1,%xmm1
  cvtss2sd %xmm0,%xmm0
  addsd  %xmm1,%xmm0
  ucomisd %xmm0,%xmm1
  jp     L13
  jne    L13
L99:
  cmp    %r8d,%ebx
  jne    L33
L180:
  add    $0x1,%rsi
  cmp    %esi,%r15d
  jge    L227
L248:
  add    $0x58,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
  nopl   0x0(%rax)
L33:
  cmp    $0x1e,%r9d
  je     L125
L77:
  movss  0x4(%r13,%rsi,4),%xmm0
  pxor   %xmm3,%xmm3
  pxor   %xmm2,%xmm2
  movsd  D102(%rip),%xmm8
  cvtss2sd (%r14,%rsi,4),%xmm3
  pxor   %xmm9,%xmm9
  movaps %xmm6,%xmm1
  subss  %xmm6,%xmm0
  cvtss2sd %xmm0,%xmm2
  movapd %xmm3,%xmm0
  addsd  %xmm3,%xmm0
  divsd  %xmm0,%xmm2
  cvtsd2ss %xmm2,%xmm2
  movaps %xmm2,%xmm0
  mulss  %xmm2,%xmm0
  cvtss2sd %xmm0,%xmm0
  addsd  %xmm8,%xmm0
  ucomisd %xmm0,%xmm9
  ja     L218
  sqrtsd %xmm0,%xmm0
L104:
  movslq %ebx,%r10
  pxor   %xmm10,%xmm10
  cvtsd2ss %xmm0,%xmm0
  andps  %xmm4,%xmm0
  movss  0x0(%r13,%r10,4),%xmm7
  lea    0x0(,%r10,4),%rbp
  cvtss2sd %xmm2,%xmm10
  cvtss2sd %xmm0,%xmm0
  subss  %xmm6,%xmm7
  pxor   %xmm6,%xmm6
  cvtss2sd %xmm7,%xmm6
  pxor   %xmm7,%xmm7
  comiss %xmm2,%xmm7
  jbe    L65
  xorpd  D120(%rip),%xmm0
L65:
  addsd  %xmm10,%xmm0
  divsd  %xmm0,%xmm3
  addsd  %xmm6,%xmm3
  cvtsd2ss %xmm3,%xmm3
  cmp    %r8d,%ebx
  jle    L134
  sub    %esi,%ebx
  movaps %xmm5,%xmm10
  movaps %xmm5,%xmm2
  mov    %r10,%rcx
  lea    -0x1(%rbx),%eax
  sub    %rax,%rcx
  mov    (%rsp),%rax
  shl    $0x2,%rcx
  lea    0x8(%rax),%rdi
  nopl   0x0(%rax,%rax,1)
L25:
  mov    %rbp,%rbx
  movaps %xmm3,%xmm0
  sub    $0x4,%rbp
  movss  -0x4(%r14,%rbx,1),%xmm1
  andps  %xmm4,%xmm0
  mulss  %xmm1,%xmm2
  mulss  %xmm10,%xmm1
  movaps %xmm2,%xmm6
  andps  %xmm4,%xmm6
  comiss %xmm0,%xmm6
  jb     L216
  divss  %xmm2,%xmm3
  movaps %xmm3,%xmm0
  mulss  %xmm3,%xmm0
  cvtss2sd %xmm0,%xmm0
  addsd  %xmm8,%xmm0
  ucomisd %xmm0,%xmm9
  ja     L157
  sqrtsd %xmm0,%xmm0
L175:
  cvtsd2ss %xmm0,%xmm0
  mulss  %xmm0,%xmm2
  movss  %xmm2,(%r14,%rbx,1)
  movaps %xmm5,%xmm2
  divss  %xmm0,%xmm2
  mulss  %xmm2,%xmm3
  movaps %xmm3,%xmm10
L90:
  movss  0x0(%r13,%rbx,1),%xmm0
  movss  -0x4(%r13,%rbx,1),%xmm3
  pxor   %xmm6,%xmm6
  mov    %rdi,%rdx
  cvtss2sd %xmm10,%xmm6
  addsd  %xmm6,%xmm6
  subss  %xmm7,%xmm0
  pxor   %xmm7,%xmm7
  cvtss2sd %xmm1,%xmm7
  mulsd  %xmm7,%xmm6
  movaps %xmm2,%xmm7
  subss  %xmm0,%xmm3
  mulss  %xmm2,%xmm3
  cvtss2sd %xmm3,%xmm3
  addsd  %xmm6,%xmm3
  cvtsd2ss %xmm3,%xmm3
  mulss  %xmm3,%xmm7
  mulss  %xmm10,%xmm3
  addss  %xmm7,%xmm0
  subss  %xmm1,%xmm3
  movss  %xmm0,0x0(%r13,%rbx,1)
  nopl   0x0(%rax)
L96:
  mov    (%rdx),%rax
  movaps %xmm10,%xmm6
  add    $0x8,%rdx
  lea    (%rax,%rbx,1),%r11
  add    %rbp,%rax
  movss  (%r11),%xmm0
  movss  (%rax),%xmm1
  mulss  %xmm0,%xmm6
  mulss  %xmm2,%xmm1
  mulss  %xmm2,%xmm0
  addss  %xmm6,%xmm1
  movss  %xmm1,(%r11)
  movss  (%rax),%xmm1
  mulss  %xmm10,%xmm1
  subss  %xmm0,%xmm1
  movss  %xmm1,(%rax)
  cmp    %r12,%rdx
  jne    L96
  cmp    %rbx,%rcx
  jne    L25
  movss  0x0(%r13,%rsi,4),%xmm1
  subss  %xmm7,%xmm1
L134:
  movss  %xmm1,0x0(%r13,%rsi,4)
  add    $0x1,%r9d
  movss  %xmm3,(%r14,%rsi,4)
  movl   $0x0,(%r14,%r10,4)
  jmp    L36
L216:
  divss  %xmm3,%xmm2
  movaps %xmm2,%xmm0
  mulss  %xmm2,%xmm0
  cvtss2sd %xmm0,%xmm0
  addsd  %xmm8,%xmm0
  ucomisd %xmm0,%xmm9
  ja     L98
  sqrtsd %xmm0,%xmm0
L213:
  movaps %xmm5,%xmm10
  cvtsd2ss %xmm0,%xmm0
  divss  %xmm0,%xmm10
  mulss  %xmm0,%xmm3
  movss  %xmm3,(%r14,%rbx,1)
  mulss  %xmm10,%xmm2
  jmp    L90
L125:
  lea    D19(%rip),%rdi
  xor    %eax,%eax
  mov    %r9d,0x1c(%rsp)
  mov    %rsi,0x10(%rsp)
  mov    %r8d,0x8(%rsp)
  call   <erhand@plt>
  mov    0x10(%rsp),%rsi
  mov    0x1c(%rsp),%r9d
  movss  D137(%rip),%xmm4
  mov    0x8(%rsp),%r8d
  movss  D156(%rip),%xmm5
  movss  0x0(%r13,%rsi,4),%xmm6
  jmp    L77
L241:
  movl   $0x0,0x0(%rbp)
  jne    L248
  xor    %ebx,%ebx
  jmp    L158
L157:
  mov    %rdi,0x48(%rsp)
  mov    %rcx,0x40(%rsp)
  mov    %r9d,0x3c(%rsp)
  mov    %rsi,0x30(%rsp)
  mov    %r8d,0x28(%rsp)
  mov    %r10,0x20(%rsp)
  movss  %xmm7,0x38(%rsp)
  movss  %xmm3,0x1c(%rsp)
  movss  %xmm1,0x10(%rsp)
  movss  %xmm2,0x8(%rsp)
  call   <sqrt@plt>
  mov    0x48(%rsp),%rdi
  mov    0x40(%rsp),%rcx
  movss  D137(%rip),%xmm4
  mov    0x3c(%rsp),%r9d
  mov    0x30(%rsp),%rsi
  pxor   %xmm9,%xmm9
  mov    D102(%rip),%rax
  mov    0x28(%rsp),%r8d
  mov    0x20(%rsp),%r10
  movss  D156(%rip),%xmm5
  movss  0x38(%rsp),%xmm7
  movss  0x1c(%rsp),%xmm3
  movq   %rax,%xmm8
  movss  0x10(%rsp),%xmm1
  movss  0x8(%rsp),%xmm2
  jmp    L175
L98:
  mov    %rdi,0x48(%rsp)
  mov    %rcx,0x40(%rsp)
  mov    %r9d,0x3c(%rsp)
  mov    %rsi,0x30(%rsp)
  mov    %r8d,0x28(%rsp)
  mov    %r10,0x20(%rsp)
  movss  %xmm3,0x38(%rsp)
  movss  %xmm7,0x1c(%rsp)
  movss  %xmm2,0x10(%rsp)
  movss  %xmm1,0x8(%rsp)
  call   <sqrt@plt>
  mov    0x48(%rsp),%rdi
  mov    0x40(%rsp),%rcx
  movss  D137(%rip),%xmm4
  mov    0x3c(%rsp),%r9d
  mov    0x30(%rsp),%rsi
  pxor   %xmm9,%xmm9
  mov    D102(%rip),%rax
  mov    0x28(%rsp),%r8d
  mov    0x20(%rsp),%r10
  movss  D156(%rip),%xmm5
  movss  0x38(%rsp),%xmm3
  movss  0x1c(%rsp),%xmm7
  movq   %rax,%xmm8
  movss  0x10(%rsp),%xmm2
  movss  0x8(%rsp),%xmm1
  jmp    L213
L218:
  mov    %r9d,0x30(%rsp)
  mov    %rsi,0x28(%rsp)
  mov    %r8d,0x20(%rsp)
  movss  %xmm6,0x38(%rsp)
  movss  %xmm6,0x1c(%rsp)
  movss  %xmm2,0x10(%rsp)
  movsd  %xmm3,0x8(%rsp)
  call   <sqrt@plt>
  mov    0x30(%rsp),%r9d
  mov    0x28(%rsp),%rsi
  movss  D137(%rip),%xmm4
  mov    0x20(%rsp),%r8d
  mov    D102(%rip),%rax
  pxor   %xmm9,%xmm9
  movss  D156(%rip),%xmm5
  movss  0x38(%rsp),%xmm6
  movss  0x1c(%rsp),%xmm1
  movss  0x10(%rsp),%xmm2
  movq   %rax,%xmm8
  movsd  0x8(%rsp),%xmm3
  jmp    L104
```

tool_calls: name: unpack_data
arguments: data_tag: D156
datatype: f32
name: unpack_data
arguments: data_tag: D137
datatype: dword
name: unpack_data
arguments: data_tag: D102
datatype: f32[2]
name: unpack_data
arguments: data_tag: D120
datatype: f32[4]
name: unpack_data
arguments: data_tag: D19
datatype: string

tool: D156: 1

tool: D137: 2147483647

tool: {"D102": [0.0,1.875]}

tool: {"D120": [0.0,-0.0,0.0,0.0]}

tool: D19: No convergence in TLQI.

assistant: ```c
void tqli(d, e, n, z) float d[], e[], **z;
int n;
{
  int m, l, iter, i, k;
  float s, r, p, g, f, dd, c, b;
  void erhand();
  for (i = 2; i <= n; i++)
    e[i - 1] = e[i];
  e[n] = 0.0;
  for (l = 1; l <= n; l++) {
    iter = 0;
    do {
      for (m = l; m <= n - 1; m++) {
        dd = fabs(d[m]) + fabs(d[m + 1]);
        if (fabs(e[m]) + dd == dd)
          break;
      }
      if (m != l) {
        if (iter++ == 30)
          erhand("No convergence in TLQI.");
        g = (d[l + 1] - d[l]) / (2.0 * e[l]);
        r = sqrt((g * g) + 1.0);
        g = d[m] - d[l] + e[l] / (g + ((g) < 0 ? -fabs(r) : fabs(r)));
        s = c = 1.0;
        p = 0.0;
        for (i = m - 1; i >= l; i--) {
          f = s * e[i];
          b = c * e[i];
          if (fabs(f) >= fabs(g)) {
            c = g / f;
            r = sqrt((c * c) + 1.0);
            e[i + 1] = f * r;
            c *= (s = 1.0 / r);
          } else {
            s = f / g;
            r = sqrt((s * s) + 1.0);
            e[i + 1] = g * r;
            s *= (c = 1.0 / r);
          }
          g = d[i + 1] - p;
          r = (d[i] - g) * s + 2.0 * c * b;
          p = s * r;
          d[i + 1] = g + p;
          g = c * r - b;
          for (k = 1; k <= n; k++) {
            f = z[k][i + 1];
            z[k][i + 1] = s * z[k][i] + c * f;
            z[k][i] = c * z[k][i] - s * f;
          }
        }
        d[l] = d[l] - p;
        e[l] = g;
        e[m] = 0.0;
      }
    } while (m != l);
  }
}
```