user: Converte this assembly snippet into its equivalent C code:

```asm
<LUCroutDecompose>:
  endbr64
  test   %edi,%edi
  jle    L56
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  mov    %rsi,%r13
  mov    %rdx,%rbp
  mov    %rcx,%rax
  movslq %edi,%rdx
  lea    0x8(,%rdx,8),%rcx
  mov    %rax,%r12
  mov    $0x0,%r10d
  movsd  D2(%rip),%xmm0
L112:
  movsd  %xmm0,(%rax)
  mov    %r10d,%r15d
  add    $0x1,%r10d
  add    %rcx,%rax
  cmp    %r10d,%edi
  jne    L112
  mov    %r10d,-0x10(%rsp)
  lea    0x2(%r15),%eax
  mov    %eax,-0xc(%rsp)
  sub    $0x8,%rcx
  mov    %rbp,-0x20(%rsp)
  movl   $0xffffffff,-0x34(%rsp)
  movl   $0x0,-0x24(%rsp)
  movl   $0x0,-0x28(%rsp)
  movq   $0x0,-0x30(%rsp)
  lea    0x8(%rbp),%rax
  mov    %rax,-0x8(%rsp)
  mov    %r10d,%r14d
  jmp    L103
L8:
  mov    %eax,%r10d
L62:
  movsd  0x0(%r13,%r8,1),%xmm1
  test   %r9d,%r9d
  jle    L137
  lea    (%r8,%rbx,1),%rax
  mov    %r12,%rdx
L111:
  movsd  (%rax),%xmm0
  mulsd  (%rdx),%xmm0
  subsd  %xmm0,%xmm1
  add    $0x8,%rax
  add    %rcx,%rdx
  cmp    %rdi,%rax
  jne    L111
L137:
  movsd  %xmm1,0x0(%rbp,%r8,1)
  lea    0x1(%r10),%eax
  add    %rcx,%rdi
  add    %rcx,%r8
  cmp    %r10d,%r15d
  jne    L8
  movslq -0x24(%rsp),%rax
  lea    0x0(%rbp,%rax,8),%rbx
  lea    0x0(,%r11,8),%r10
  lea    0x0(%rbp,%r10,1),%rax
  add    %r13,%r10
  mov    %r12,%r8
  mov    -0x30(%rsp),%rdi
  mov    %r12,-0x18(%rsp)
  mov    %rax,%r12
  jmp    L104
L64:
  mov    %r8,%rdx
  mov    %r12,%rax
  pxor   %xmm1,%xmm1
L5:
  movsd  (%rax),%xmm0
  mulsd  (%rdx),%xmm0
  addsd  %xmm0,%xmm1
  add    $0x8,%rax
  add    %rcx,%rdx
  cmp    %rsi,%rax
  jne    L5
L54:
  movsd  (%r10,%rdi,8),%xmm0
  subsd  %xmm1,%xmm0
  divsd  (%rbx),%xmm0
  movsd  %xmm0,(%r8,%r11,8)
  add    $0x1,%rdi
  add    $0x8,%r8
  cmp    %edi,%r14d
  jle    L106
L104:
  pxor   %xmm1,%xmm1
  test   %r9d,%r9d
  jg     L64
  jmp    L54
L106:
  mov    -0x18(%rsp),%r12
L76:
  addq   $0x1,-0x30(%rsp)
  mov    -0x10(%rsp),%ebx
  add    %ebx,-0x28(%rsp)
  add    $0x8,%r12
  mov    -0xc(%rsp),%ebx
  add    %ebx,-0x24(%rsp)
  addl   $0x1,-0x34(%rsp)
  mov    -0x34(%rsp),%eax
  subq   $0x8,-0x20(%rsp)
  cmp    %eax,%r15d
  je     L98
L103:
  mov    -0x30(%rsp),%rax
  mov    %eax,%r10d
  mov    %eax,%r9d
  cmp    %eax,%r14d
  jle    L76
  movslq -0x28(%rsp),%r11
  mov    -0x34(%rsp),%eax
  add    %r11,%rax
  mov    -0x8(%rsp),%rbx
  lea    (%rbx,%rax,8),%rsi
  mov    -0x30(%rsp),%rax
  lea    (%r11,%rax,1),%r8
  shl    $0x3,%r8
  mov    %rsi,%rdi
  mov    -0x20(%rsp),%rbx
  jmp    L62
L98:
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
L56:
  ret
```

tool_calls: name: extract_symbolic_data
arguments: data_tag: D2
datatype: f64

tool: D2: 1

assistant: ```c
void LUCroutDecompose(int n, double *A, double *L, double *U) {
  int i, j, k;
  double soma;
  for (i = 0; i < n; i++) {
    U[i * n + i] = 1.0;
  }
  for (j = 0; j < n; j++) {
    for (i = j; i < n; i++) {
      soma = A[i * n + j];
      for (k = 0; k < j; k++) {
        soma -= L[i * n + k] * U[k * n + j];
      }
      L[i * n + j] = soma;
    }
    for (i = j; i < n; i++) {
      soma = 0.0;
      for (k = 0; k < j; k++) {
        soma += L[j * n + k] * U[k * n + i];
      }
      U[j * n + i] = (A[j * n + i] - soma) / L[j * n + j];
    }
  }
  return;
}
```