user: What is the c source code of the assembly code below?

```asm
<ldvmat>:
  endbr64
  push   %r15
  mov    %rsi,%rcx
  mov    %rdi,%r15
  push   %r14
  push   %r13
  mov    %edx,%r13d
  push   %r12
  imul   %edx,%r13d
  push   %rbp
  push   %rbx
  mov    %edx,%ebx
  sub    $0x18,%rsp
  test   %r13d,%r13d
  je     L208
  movslq %r13d,%r13
  mov    %rcx,%rdi
  xor    %esi,%esi
  lea    0x0(,%r13,8),%rdx
  call   <memset@plt>
  mov    %rax,%rcx
L112:
  movslq %ebx,%r12
  movsd  D29(%rip),%xmm4
  mov    %r13,%rdi
  lea    -0x8(%rcx,%r13,8),%r14
  sub    %r12,%rdi
  mov    $0xfffffffffffffff8,%rbp
  movsd  %xmm4,(%rcx)
  sub    %r12,%rdi
  lea    0x0(,%r12,8),%rcx
  sub    %rcx,%rbp
  shl    $0x3,%rdi
  movsd  %xmm4,(%r14)
  lea    (%r14,%rbp,1),%r10
  lea    -0x8(%r15,%rdi,1),%r9
  cmp    $0x2,%ebx
  jle    L23
  lea    0x10(%r10),%r11
  add    %r15,%rdi
  cmp    $0x1,%ebx
  jne    L180
  sub    $0x8,%r14
  shl    $0x4,%r12
  xor    %r13d,%r13d
  pxor   %xmm3,%xmm3
  movq   D27(%rip),%xmm6
  mov    %ebx,%r8d
  cs nopw 0x0(%rax,%rax,1)
L271:
  movsd  -0x8(%r9),%xmm5
  lea    0x8(%r10),%rsi
  lea    (%rcx,%r10,1),%rax
  ucomisd %xmm3,%xmm5
  jp     L187
  je     L128
L187:
  lea    -0x8(%rdi),%rbx
  movapd %xmm4,%xmm0
  movapd %xmm5,%xmm1
  xor    %edx,%edx
  test   %rcx,%rcx
  subsd  %xmm5,%xmm0
  xorpd  %xmm6,%xmm1
  cmovs  %r13,%rdx
  add    %rcx,%rdx
  movsd  %xmm0,(%r10)
  add    %r10,%rdx
  cmp    %rbx,%rdx
  seta   %bl
  xor    %edx,%edx
  test   %rcx,%rcx
  cmovns %r13,%rdx
  add    %rcx,%rdx
  add    %r10,%rdx
  cmp    %rdx,%r9
  seta   %dl
  or     %bl,%dl
  je     L92
  lea    -0x1(%r8),%edx
  cmp    $0x8,%edx
  jbe    L92
  mov    %r8d,%edx
  movapd %xmm1,%xmm2
  mov    %r9,%r15
  shr    %edx
  unpcklpd %xmm2,%xmm2
  sub    $0x1,%edx
  shl    $0x4,%rdx
  lea    0x10(%r9,%rdx,1),%rbx
  mov    %r14,%rdx
  nopl   0x0(%rax)
L144:
  movupd (%r15),%xmm0
  add    $0x10,%r15
  mulpd  %xmm2,%xmm0
  movlpd %xmm0,(%rdx)
  movhpd %xmm0,(%rdx,%rcx,1)
  add    %r12,%rdx
  cmp    %r15,%rbx
  jne    L144
  mov    %r8d,%ebx
  and    $0xfffffffe,%ebx
  mov    %ebx,%r15d
  lea    (%r9,%r15,8),%rdx
  imul   %rcx,%r15
  add    %r15,%rax
  cmp    %r8d,%ebx
  je     L201
  mulsd  (%rdx),%xmm1
  movsd  %xmm1,(%rax)
L201:
  lea    0x1(%r8),%eax
  mov    %rax,%r8
  lea    (%r10,%rax,8),%rbx
  nopw   0x0(%rax,%rax,1)
L300:
  lea    (%rsi,%rcx,1),%rax
  mov    %r9,%rdx
  movapd %xmm3,%xmm1
  mov    %rax,%r15
  cs nopw 0x0(%rax,%rax,1)
L109:
  movsd  (%rdx),%xmm0
  mulsd  (%r15),%xmm0
  add    $0x8,%rdx
  add    %rcx,%r15
  addsd  %xmm0,%xmm1
  cmp    %rdi,%rdx
  jne    L109
  mulsd  %xmm5,%xmm1
  mov    %r9,%rdx
L133:
  movsd  (%rdx),%xmm2
  movsd  (%rax),%xmm0
  add    $0x8,%rdx
  mulsd  %xmm1,%xmm2
  subsd  %xmm2,%xmm0
  movsd  %xmm0,(%rax)
  add    %rcx,%rax
  cmp    %rdi,%rdx
  jne    L133
  add    $0x8,%rsi
  xorpd  %xmm6,%xmm1
  movsd  %xmm1,-0x8(%rsi)
  cmp    %rbx,%rsi
  jne    L300
L184:
  add    %rbp,%r9
  add    %rbp,%r10
  sub    %rcx,%r11
  sub    %rcx,%rdi
  add    %rcx,%r13
  add    %rbp,%r14
  jmp    L271
  nopl   0x0(%rax)
L128:
  movsd  %xmm4,(%r10)
  nopl   (%rax)
L215:
  add    $0x8,%rsi
  movq   $0x0,-0x8(%rsi)
  movq   $0x0,(%rax)
  add    %rcx,%rax
  cmp    %r11,%rsi
  jne    L215
  add    $0x1,%r8d
  jmp    L184
L180:
  lea    -0x1(%rbx),%esi
  lea    -0x8(%r14),%rax
  mov    %ebx,0xc(%rsp)
  shl    $0x4,%r12
  mov    %esi,0x8(%rsp)
  xor    %r13d,%r13d
  mov    $0x1,%r14d
  mov    %rax,%rbx
  movq   D27(%rip),%xmm6
  pxor   %xmm3,%xmm3
L57:
  movsd  -0x8(%r9),%xmm5
  lea    0x8(%r10),%r8
  lea    (%rcx,%r10,1),%rax
  ucomisd %xmm3,%xmm5
  jp     L48
  je     L62
L48:
  lea    -0x8(%rdi),%rsi
  movapd %xmm4,%xmm0
  movapd %xmm5,%xmm1
  xor    %edx,%edx
  test   %rcx,%rcx
  subsd  %xmm5,%xmm0
  xorpd  %xmm6,%xmm1
  cmovs  %r13,%rdx
  add    %rcx,%rdx
  movsd  %xmm0,(%r10)
  add    %r10,%rdx
  cmp    %rsi,%rdx
  seta   %sil
  xor    %edx,%edx
  test   %rcx,%rcx
  cmovns %r13,%rdx
  add    %rcx,%rdx
  add    %r10,%rdx
  cmp    %rdx,%r9
  seta   %dl
  or     %sil,%dl
  je     L261
  lea    -0x1(%r14),%edx
  cmp    $0x8,%edx
  jbe    L261
  mov    %r14d,%edx
  movapd %xmm1,%xmm2
  mov    %r9,%rsi
  shr    %edx
  unpcklpd %xmm2,%xmm2
  sub    $0x1,%edx
  shl    $0x4,%rdx
  lea    0x10(%r9,%rdx,1),%r15
  mov    %rbx,%rdx
  nopw   0x0(%rax,%rax,1)
L258:
  movupd (%rsi),%xmm0
  add    $0x10,%rsi
  mulpd  %xmm2,%xmm0
  movlpd %xmm0,(%rdx)
  movhpd %xmm0,(%rdx,%rcx,1)
  add    %r12,%rdx
  cmp    %r15,%rsi
  jne    L258
  mov    %r14d,%r15d
  and    $0xfffffffe,%r15d
  mov    %r15d,%edx
  lea    (%r9,%rdx,8),%rsi
  imul   %rcx,%rdx
  add    %rax,%rdx
  cmp    %r14d,%r15d
  je     L230
  mulsd  (%rsi),%xmm1
  movsd  %xmm1,(%rdx)
L230:
  mov    0xc(%rsp),%esi
  mov    %esi,%eax
  sub    %r14d,%eax
  cmp    %eax,%esi
  jle    L204
  lea    0x1(%r14),%eax
  mov    %rax,%r14
  lea    (%r10,%rax,8),%r15
  nopl   0x0(%rax,%rax,1)
L188:
  lea    (%r8,%rcx,1),%rax
  mov    %r9,%rdx
  movapd %xmm3,%xmm1
  mov    %rax,%rsi
  xchg   %ax,%ax
L231:
  add    $0x8,%rdx
  movsd  (%rsi),%xmm0
  add    %rcx,%rsi
  mulsd  -0x8(%rdx),%xmm0
  addsd  %xmm0,%xmm1
  cmp    %rdi,%rdx
  jne    L231
  mulsd  %xmm5,%xmm1
  mov    %r9,%rdx
L221:
  movsd  (%rdx),%xmm2
  movsd  (%rax),%xmm0
  add    $0x8,%rdx
  mulsd  %xmm1,%xmm2
  subsd  %xmm2,%xmm0
  movsd  %xmm0,(%rax)
  add    %rcx,%rax
  cmp    %rdi,%rdx
  jne    L221
  add    $0x8,%r8
  xorpd  %xmm6,%xmm1
  movsd  %xmm1,-0x8(%r8)
  cmp    %r15,%r8
  jne    L188
L318:
  add    %rbp,%r9
  add    %rbp,%r10
  sub    %rcx,%r11
  sub    %rcx,%rdi
  add    %rcx,%r13
  add    %rbp,%rbx
  cmp    0x8(%rsp),%r14d
  jne    L57
L23:
  add    $0x18,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
L92:
  mov    %r9,%rdx
  nopw   0x0(%rax,%rax,1)
L292:
  movsd  (%rdx),%xmm0
  add    $0x8,%rdx
  mulsd  %xmm1,%xmm0
  movsd  %xmm0,(%rax)
  add    %rcx,%rax
  cmp    %rdi,%rdx
  jne    L292
  jmp    L201
L62:
  movsd  %xmm4,(%r10)
  nopw   0x0(%rax,%rax,1)
L195:
  add    $0x8,%r8
  movq   $0x0,-0x8(%r8)
  movq   $0x0,(%rax)
  add    %rcx,%rax
  cmp    %r11,%r8
  jne    L195
L204:
  add    $0x1,%r14d
  jmp    L318
L261:
  mov    %r9,%rdx
L37:
  movsd  (%rdx),%xmm0
  add    $0x8,%rdx
  mulsd  %xmm1,%xmm0
  movsd  %xmm0,(%rax)
  add    %rcx,%rax
  cmp    %rdi,%rdx
  jne    L37
  jmp    L230
L208:
  xor    %r13d,%r13d
  jmp    L112
```

tool_calls: name: unpack_data
arguments: tag: D29
type: f64
name: unpack_data
arguments: tag: D27
type: f32[2]

tool: D29: 1

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

assistant: ```c
void ldvmat(double *a, double *v, int n) {
  double *p0, *q0, *p, *q, *qq;
  double h, s;
  int i, j, k, mm;
  for (i = 0, mm = n * n, q = v; i < mm; ++i)
    *q++ = 0.;
  *v = 1.;
  q0 = v + n * n - 1;
  *q0 = 1.;
  q0 -= n + 1;
  p0 = a + n * n - n - n - 1;
  for (i = n - 2, mm = 1; i > 0; --i, p0 -= n + 1, q0 -= n + 1, ++mm) {
    if (*(p0 - 1) != 0.) {
      for (j = 0, p = p0, h = 1.; j < mm; ++j, ++p)
        h += *p * *p;
      h = *(p0 - 1);
      *q0 = 1. - h;
      for (j = 0, q = q0 + n, p = p0; j < mm; ++j, q += n)
        *q = -h * *p++;
      for (k = i + 1, q = q0 + 1; k < n; ++k) {
        for (j = 0, qq = q + n, p = p0, s = 0.; j < mm; ++j, qq += n)
          s += *qq * *p++;
        s *= h;
        for (j = 0, qq = q + n, p = p0; j < mm; ++j, qq += n)
          *qq -= s * *p++;
        *q++ = -s;
      }
    } else {
      *q0 = 1.;
      for (j = 0, p = q0 + 1, q = q0 + n; j < mm; ++j, q += n)
        *q = *p++ = 0.;
    }
  }
}
```