user: 请显示与下面列出的汇编代码相匹配的C语言实现：

```asm
<lm_qrsolv>:
  endbr64
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0xa8,%rsp
  mov    %rcx,0x28(%rsp)
  mov    0xe8(%rsp),%r11
  mov    %edx,0x8(%rsp)
  mov    0xf0(%rsp),%rcx
  mov    %r8,0x30(%rsp)
  test   %edi,%edi
  jle    L85
  mov    %edi,%r13d
  movslq %edx,%rdi
  mov    %rsi,0x18(%rsp)
  mov    %rsi,%r14
  lea    0x8(,%rdi,8),%rbx
  mov    %r13d,%ebp
  shl    $0x3,%rdi
  mov    %rsi,%r10
  mov    %rbx,0x40(%rsp)
  mov    0xe0(%rsp),%r12
  xor    %r8d,%r8d
  mov    %rbp,0x68(%rsp)
L306:
  mov    %r10,%rdx
  mov    %r8,%rax
  cs nopw 0x0(%rax,%rax,1)
L81:
  movsd  (%rdx),%xmm0
  add    %rdi,%rdx
  movsd  %xmm0,(%rsi,%rax,8)
  add    $0x1,%rax
  cmp    %eax,%r13d
  jg     L81
  movsd  (%r10),%xmm0
  add    %rdi,%rsi
  add    %rbx,%r10
  movsd  %xmm0,(%r12,%r8,8)
  movsd  (%r9,%r8,8),%xmm0
  movsd  %xmm0,(%rcx,%r8,8)
  add    $0x1,%r8
  cmp    %rbp,%r8
  jne    L306
  mov    0x8(%rsp),%eax
  mov    %r11,%r9
  mov    $0x1,%r10d
  mov    %r13d,%r8d
  mov    %rcx,0xf0(%rsp)
  pxor   %xmm3,%xmm3
  mov    %r14,%rcx
  mov    %r11,%r14
  add    $0x1,%eax
  movl   $0x0,0x24(%rsp)
  mov    %eax,0xc(%rsp)
  lea    0x1(%r13),%eax
  mov    %rax,0x38(%rsp)
  movl   $0x0,0x20(%rsp)
  jmp    L265
  nop
L338:
  mov    0x18(%rsp),%rax
  mov    0xe0(%rsp),%rbx
  movsd  (%rax),%xmm0
  movsd  %xmm0,(%r9)
  movsd  -0x8(%rbx,%r10,8),%xmm0
  mov    0x40(%rsp),%rbx
  add    $0x1,%r10
  mov    0x10(%rsp),%r9
  movsd  %xmm0,(%rax)
  add    %rbx,%rax
  mov    0x8(%rsp),%ebx
  mov    %rax,0x18(%rsp)
  add    %ebx,0x20(%rsp)
  mov    0xc(%rsp),%ebx
  add    %ebx,0x24(%rsp)
  cmp    0x38(%rsp),%r10
  je     L45
L265:
  mov    0x28(%rsp),%rbx
  mov    %r10d,%edx
  lea    -0x1(%r10),%eax
  movslq -0x4(%rbx,%r10,4),%rsi
  mov    0x30(%rsp),%rbx
  lea    (%rbx,%rsi,8),%rbx
  ucomisd (%rbx),%xmm3
  jp     L3
  lea    0x8(%r9),%rsi
  mov    %rsi,0x10(%rsp)
  je     L338
L3:
  mov    %r8d,%r13d
  mov    %r9,%rdi
  mov    %rcx,0x60(%rsp)
  sub    %edx,%r13d
  cmp    %eax,%r8d
  mov    $0x8,%eax
  mov    %r10,0x48(%rsp)
  mov    %r13d,%edx
  mov    %r8d,0x58(%rsp)
  lea    0x8(,%rdx,8),%rdx
  cmovle %rax,%rdx
  xor    %esi,%esi
  call   <memset@plt>
  movsd  (%rbx),%xmm0
  mov    0x48(%rsp),%r10
  pxor   %xmm3,%xmm3
  mov    %rax,%r9
  lea    0x8(%rax),%rax
  mov    0x24(%rsp),%edi
  mov    0x20(%rsp),%r15d
  movsd  %xmm0,-0x8(%rax)
  mov    %rax,%rbp
  mov    %r10,%r12
  movsd  D30(%rip),%xmm7
  mov    %rax,0x10(%rsp)
  mov    D83(%rip),%rax
  movapd %xmm3,%xmm2
  mov    0x58(%rsp),%r8d
  mov    0x60(%rsp),%rcx
  mov    %r9,0x48(%rsp)
  mov    %r10,0x50(%rsp)
  mov    0xf0(%rsp),%r9
  movq   %rax,%xmm5
  movq   D134(%rip),%xmm6
  movq   D36(%rip),%xmm4
  jmp    L228
  cs nopw 0x0(%rax,%rax,1)
L219:
  cmp    %r12d,%r8d
  jle    L153
  nopl   0x0(%rax)
L5:
  add    $0x1,%r12
  add    $0x8,%rbp
  add    0xc(%rsp),%edi
  sub    $0x1,%r13d
  add    0x8(%rsp),%r15d
L228:
  movsd  -0x8(%rbp),%xmm1
  lea    -0x1(%r12),%rdx
  mov    %r12d,%ebx
  ucomisd %xmm3,%xmm1
  jp     L270
  je     L219
L270:
  movslq %edi,%rax
  movapd %xmm1,%xmm8
  lea    (%rcx,%rax,8),%rax
  andpd  %xmm4,%xmm8
  movsd  (%rax),%xmm9
  movapd %xmm9,%xmm0
  andpd  %xmm4,%xmm0
  comisd %xmm0,%xmm8
  jbe    L202
  movsd  D83(%rip),%xmm10
  movapd %xmm9,%xmm8
  divsd  %xmm1,%xmm8
  movapd %xmm8,%xmm0
  mulsd  %xmm10,%xmm0
  mulsd  %xmm8,%xmm0
  addsd  %xmm10,%xmm0
  ucomisd %xmm0,%xmm3
  ja     L21
  sqrtsd %xmm0,%xmm0
L185:
  movsd  D30(%rip),%xmm10
  divsd  %xmm0,%xmm10
  mulsd  %xmm10,%xmm8
L14:
  mulsd  %xmm8,%xmm9
  mulsd  %xmm10,%xmm1
  addsd  %xmm9,%xmm1
  movapd %xmm10,%xmm9
  mulsd  %xmm2,%xmm9
  mulsd  %xmm8,%xmm2
  movsd  %xmm1,(%rax)
  movsd  -0x8(%r9,%r12,8),%xmm0
  movslq %r12d,%rax
  movapd %xmm0,%xmm1
  mulsd  %xmm8,%xmm1
  addsd  %xmm9,%xmm1
  movapd %xmm10,%xmm9
  xorpd  %xmm6,%xmm9
  mulsd  %xmm9,%xmm0
  movsd  %xmm1,-0x8(%r9,%r12,8)
  addsd  %xmm0,%xmm2
  cmp    %r8d,%r12d
  jge    L153
  movslq %r15d,%r10
  lea    0x10(%rbp),%r11
  lea    0x3(%rdx,%r10,1),%rsi
  shl    $0x3,%rsi
  lea    -0x10(%rcx,%rsi,1),%rdx
  cmp    %r11,%rdx
  setae  %r11b
  add    %rcx,%rsi
  cmp    %rsi,%rbp
  setae  %sil
  or     %r11b,%sil
  je     L113
  cmp    $0x1,%r13d
  je     L113
  mov    %r13d,%esi
  movapd %xmm8,%xmm11
  movapd %xmm10,%xmm13
  xor    %eax,%eax
  movapd %xmm9,%xmm12
  shr    %esi
  unpcklpd %xmm11,%xmm11
  unpcklpd %xmm13,%xmm13
  unpcklpd %xmm12,%xmm12
  shl    $0x4,%rsi
  nopl   0x0(%rax,%rax,1)
L12:
  movupd 0x0(%rbp,%rax,1),%xmm0
  movupd (%rdx,%rax,1),%xmm1
  movapd %xmm12,%xmm15
  mulpd  %xmm1,%xmm15
  movapd %xmm0,%xmm14
  mulpd  %xmm11,%xmm14
  mulpd  %xmm13,%xmm0
  mulpd  %xmm11,%xmm1
  addpd  %xmm15,%xmm14
  addpd  %xmm1,%xmm0
  movups %xmm14,0x0(%rbp,%rax,1)
  movups %xmm0,(%rdx,%rax,1)
  add    $0x10,%rax
  cmp    %rsi,%rax
  jne    L12
  mov    %r13d,%eax
  and    $0xfffffffe,%eax
  add    %eax,%ebx
  cmp    %eax,%r13d
  je     L5
  lea    (%r15,%rbx,1),%eax
  movslq %ebx,%rbx
  movapd %xmm8,%xmm11
  cltq
  lea    (%r14,%rbx,8),%rdx
  lea    (%rcx,%rax,8),%rax
  movsd  (%rdx),%xmm0
  movsd  (%rax),%xmm1
  mulsd  %xmm0,%xmm11
  mulsd  %xmm1,%xmm9
  mulsd  %xmm10,%xmm0
  mulsd  %xmm8,%xmm1
  addsd  %xmm11,%xmm9
  addsd  %xmm1,%xmm0
  movsd  %xmm9,(%rdx)
  movsd  %xmm0,(%rax)
  jmp    L5
  nop
L202:
  movapd %xmm1,%xmm10
  divsd  %xmm9,%xmm10
  movapd %xmm10,%xmm0
  mulsd  %xmm5,%xmm0
  mulsd  %xmm10,%xmm0
  addsd  %xmm5,%xmm0
  ucomisd %xmm0,%xmm3
  ja     L95
  sqrtsd %xmm0,%xmm0
L218:
  movapd %xmm7,%xmm8
  divsd  %xmm0,%xmm8
  mulsd  %xmm8,%xmm10
  jmp    L14
  xchg   %ax,%ax
L153:
  mov    0x48(%rsp),%r9
  mov    0x50(%rsp),%r10
  jmp    L338
  nop
L113:
  lea    (%rcx,%r10,8),%rdx
  nopl   0x0(%rax)
L73:
  movsd  (%rdx,%rax,8),%xmm1
  movsd  (%r14,%rax,8),%xmm0
  movapd %xmm8,%xmm11
  movapd %xmm9,%xmm12
  mulsd  %xmm0,%xmm11
  mulsd  %xmm1,%xmm12
  mulsd  %xmm10,%xmm0
  mulsd  %xmm8,%xmm1
  addsd  %xmm12,%xmm11
  addsd  %xmm1,%xmm0
  movsd  %xmm11,(%r14,%rax,8)
  movsd  %xmm0,(%rdx,%rax,8)
  add    $0x1,%rax
  cmp    %eax,%r8d
  jg     L73
  jmp    L5
L45:
  mov    %r14,%r11
  mov    0x68(%rsp),%rdi
  mov    %rcx,%r14
  mov    %r8d,%r13d
  mov    0xf0(%rsp),%rcx
  mov    %r8d,%r10d
  xor    %eax,%eax
  xor    %esi,%esi
L203:
  ucomisd (%r11,%rax,8),%xmm3
  setnp  %dl
  cmovne %esi,%edx
  test   %dl,%dl
  je     L120
  cmp    %r10d,%r13d
  cmove  %eax,%r10d
L120:
  cmp    %r13d,%r10d
  jge    L340
  movq   $0x0,(%rcx,%rax,8)
L340:
  add    $0x1,%rax
  cmp    %rdi,%rax
  jne    L203
  mov    %r10d,%esi
  sub    $0x1,%esi
  js     L102
  mov    0x8(%rsp),%r8d
  movslq %esi,%rbx
  movslq %r10d,%rax
  mov    %r10d,%ebp
  xor    %r9d,%r9d
  lea    (%rcx,%rax,8),%rdx
  imul   %r8d,%esi
  nopw   0x0(%rax,%rax,1)
L292:
  mov    %ebp,%eax
  cmp    %ebp,%r10d
  jle    L71
  cmp    $0x1,%r9d
  je     L31
  movslq %esi,%rax
  mov    %r9d,%edi
  movapd %xmm3,%xmm0
  lea    0x1(%rbx,%rax,1),%rax
  shr    %edi
  lea    (%r14,%rax,8),%r12
  shl    $0x4,%rdi
  xor    %eax,%eax
  nopl   0x0(%rax,%rax,1)
L145:
  movupd (%rdx,%rax,1),%xmm2
  movupd (%r12,%rax,1),%xmm7
  add    $0x10,%rax
  mulpd  %xmm7,%xmm2
  addsd  %xmm2,%xmm0
  unpckhpd %xmm2,%xmm2
  addsd  %xmm2,%xmm0
  cmp    %rax,%rdi
  jne    L145
  mov    %r9d,%edi
  and    $0xfffffffe,%edi
  lea    0x0(%rbp,%rdi,1),%eax
  cmp    %edi,%r9d
  je     L199
L316:
  lea    (%rsi,%rax,1),%edi
  cltq
  movslq %edi,%rdi
  movsd  (%r14,%rdi,8),%xmm1
  mulsd  (%rcx,%rax,8),%xmm1
  addsd  %xmm1,%xmm0
L199:
  movsd  -0x8(%rdx),%xmm1
  sub    $0x1,%ebp
  sub    %r8d,%esi
  add    $0x1,%r9d
  sub    $0x8,%rdx
  subsd  %xmm0,%xmm1
  divsd  (%r11,%rbx,8),%xmm1
  sub    $0x1,%rbx
  movsd  %xmm1,(%rdx)
  test   %ebx,%ebx
  jns    L292
L102:
  mov    0x28(%rsp),%rsi
  mov    0xe0(%rsp),%rdi
  xor    %eax,%eax
  cs nopw 0x0(%rax,%rax,1)
L80:
  movsd  (%rcx,%rax,8),%xmm0
  movslq (%rsi,%rax,4),%rdx
  add    $0x1,%rax
  movsd  %xmm0,(%rdi,%rdx,8)
  cmp    %eax,%r13d
  jg     L80
L85:
  add    $0xa8,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
L71:
  movapd %xmm3,%xmm0
  jmp    L199
L31:
  movapd %xmm3,%xmm0
  jmp    L316
L21:
  mov    %r9,0xf0(%rsp)
  mov    %rcx,0x98(%rsp)
  mov    %r8d,0x94(%rsp)
  mov    %edi,0x90(%rsp)
  mov    %rdx,0x78(%rsp)
  mov    %rax,0x60(%rsp)
  movsd  %xmm2,0x88(%rsp)
  movsd  %xmm8,0x80(%rsp)
  movsd  %xmm9,0x70(%rsp)
  movsd  %xmm1,0x58(%rsp)
  call   <sqrt@plt>
  mov    D83(%rip),%rax
  mov    0xf0(%rsp),%r9
  pxor   %xmm3,%xmm3
  mov    0x98(%rsp),%rcx
  mov    0x94(%rsp),%r8d
  movq   %rax,%xmm5
  mov    D30(%rip),%rax
  movsd  0x88(%rsp),%xmm2
  mov    0x90(%rsp),%edi
  mov    0x78(%rsp),%rdx
  movq   %rax,%xmm7
  movsd  0x58(%rsp),%xmm1
  movq   D134(%rip),%xmm6
  movq   D36(%rip),%xmm4
  movsd  0x70(%rsp),%xmm9
  movsd  0x80(%rsp),%xmm8
  mov    0x60(%rsp),%rax
  jmp    L185
L95:
  mov    %r9,0xf0(%rsp)
  mov    %rcx,0x98(%rsp)
  mov    %r8d,0x94(%rsp)
  mov    %edi,0x90(%rsp)
  mov    %rdx,0x78(%rsp)
  mov    %rax,0x60(%rsp)
  movsd  %xmm2,0x88(%rsp)
  movsd  %xmm10,0x80(%rsp)
  movsd  %xmm9,0x70(%rsp)
  movsd  %xmm1,0x58(%rsp)
  call   <sqrt@plt>
  mov    D83(%rip),%rax
  mov    0xf0(%rsp),%r9
  pxor   %xmm3,%xmm3
  mov    0x98(%rsp),%rcx
  mov    0x94(%rsp),%r8d
  movq   %rax,%xmm5
  mov    D30(%rip),%rax
  movsd  0x88(%rsp),%xmm2
  mov    0x90(%rsp),%edi
  mov    0x78(%rsp),%rdx
  movq   %rax,%xmm7
  movsd  0x58(%rsp),%xmm1
  movq   D134(%rip),%xmm6
  movq   D36(%rip),%xmm4
  movsd  0x70(%rsp),%xmm9
  movsd  0x80(%rsp),%xmm10
  mov    0x60(%rsp),%rax
  jmp    L218
```

tool_calls: name: retrieve_data
arguments: data_tag: D30
type_infered: f64
name: retrieve_data
arguments: data_tag: D83
type_infered: f64
name: retrieve_data
arguments: data_tag: D134
type_infered: f32[2]
name: retrieve_data
arguments: data_tag: D36
type_infered: qword

tool: D30: 0.5

tool: D83: 0.25

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

tool: D36: 9223372036854775807

assistant: ```c
void lm_qrsolv(int n, double *r, int ldr, int *ipvt, double *diag, double *qtb, double *x, double *sdiag, double *wa) {
  int i, kk, j, k, nsing;
  double qtbpj, sum, temp;
  double sin, cos, tan, cotan;
  static double p25 = 0.25;
  static double p5 = 0.5;
  for (j = 0; j < n; j++) {
    for (i = j; i < n; i++)
      r[j * ldr + i] = r[i * ldr + j];
    x[j] = r[j * ldr + j];
    wa[j] = qtb[j];
  }
  for (j = 0; j < n; j++) {
    if (diag[ipvt[j]] == 0.)
      goto L90;
    for (k = j; k < n; k++)
      sdiag[k] = 0.;
    sdiag[j] = diag[ipvt[j]];
    qtbpj = 0.;
    for (k = j; k < n; k++) {
      if (sdiag[k] == 0.)
        continue;
      kk = k + ldr * k;
      if (fabs(r[kk]) < fabs(sdiag[k])) {
        cotan = r[kk] / sdiag[k];
        sin = p5 / sqrt(p25 + p25 * (cotan) * (cotan));
        cos = sin * cotan;
      } else {
        tan = sdiag[k] / r[kk];
        cos = p5 / sqrt(p25 + p25 * (tan) * (tan));
        sin = cos * tan;
      }
      r[kk] = cos * r[kk] + sin * sdiag[k];
      temp = cos * wa[k] + sin * qtbpj;
      qtbpj = -sin * wa[k] + cos * qtbpj;
      wa[k] = temp;
      for (i = k + 1; i < n; i++) {
        temp = cos * r[k * ldr + i] + sin * sdiag[i];
        sdiag[i] = -sin * r[k * ldr + i] + cos * sdiag[i];
        r[k * ldr + i] = temp;
      }
    }
  L90:
    sdiag[j] = r[j * ldr + j];
    r[j * ldr + j] = x[j];
  }
  nsing = n;
  for (j = 0; j < n; j++) {
    if (sdiag[j] == 0. && nsing == n)
      nsing = j;
    if (nsing < n)
      wa[j] = 0;
  }
  for (j = nsing - 1; j >= 0; j--) {
    sum = 0;
    for (i = j + 1; i < nsing; i++)
      sum += r[j * ldr + i] * wa[i];
    wa[j] = (wa[j] - sum) / sdiag[j];
  }
  for (j = 0; j < n; j++)
    x[ipvt[j]] = wa[j];
}
```