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

```asm
<lu_decomposition>:
  endbr64
  push   %r15
  mov    %rcx,%r15
  xor    %eax,%eax
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  mov    %esi,%ebp
  push   %rbx
  mov    %rdi,%rbx
  lea    D20(%rip),%rdi
  sub    $0x48,%rsp
  mov    %rcx,0x20(%rsp)
  movslq %esi,%rcx
  lea    D52(%rip),%rsi
  mov    %rdx,0x10(%rsp)
  shl    $0x3,%rcx
  mov    $0x186,%edx
  call   <Malloc@plt>
  movl   $0x1,(%r15)
  cltq
  mov    %rax,0x18(%rsp)
  test   %ebp,%ebp
  jle    L70
  lea    -0x1(%rbp),%edi
  mov    %rax,(%rsp)
  mov    %rax,%rcx
  pxor   %xmm4,%xmm4
  mov    %edi,0x30(%rsp)
  movq   D40(%rip),%xmm2
  mov    %rdi,0x8(%rsp)
  mov    %ebp,%edi
  movsd  D29(%rip),%xmm5
  lea    0x0(,%rdi,8),%rsi
  mov    %rdi,0x38(%rsp)
  mov    %rbx,%rdi
  lea    (%rax,%rsi,1),%r8
  sub    %rax,%rdi
  nopl   0x0(%rax,%rax,1)
L17:
  mov    (%rdi,%rcx,1),%rax
  movapd %xmm4,%xmm1
  lea    (%rax,%rsi,1),%rdx
  nopl   0x0(%rax)
L79:
  movsd  (%rax),%xmm0
  add    $0x8,%rax
  andpd  %xmm2,%xmm0
  maxsd  %xmm1,%xmm0
  movapd %xmm0,%xmm1
  cmp    %rdx,%rax
  jne    L79
  ucomisd %xmm0,%xmm0
  jp     L159
  comisd %xmm0,%xmm4
  ja     L159
  comisd %xmm4,%xmm0
  jbe    L143
L159:
  movapd %xmm5,%xmm0
  add    $0x8,%rcx
  divsd  %xmm1,%xmm0
  movsd  %xmm0,-0x8(%rcx)
  cmp    %rcx,%r8
  jne    L17
  mov    %ebp,%eax
  xor    %r11d,%r11d
  xor    %r14d,%r14d
  shr    %eax
  sub    $0x1,%eax
  add    $0x1,%rax
  shl    $0x4,%rax
  mov    %rax,0x28(%rsp)
  mov    %ebp,%eax
  and    $0xfffffffe,%eax
  mov    %eax,0x34(%rsp)
  mov    %eax,%r15d
  shl    $0x3,%r15
  nop
L149:
  lea    0x0(,%r11,8),%rdx
  mov    %r11d,%r13d
  test   %r11,%r11
  je     L247
  mov    $0x8,%esi
  mov    $0x1,%r8d
  cmp    $0x1,%r11d
  je     L247
  nopl   0x0(%rax)
L47:
  mov    (%rbx,%rsi,1),%rdi
  xor    %eax,%eax
  lea    (%rdi,%rdx,1),%r9
  movsd  (%r9),%xmm1
  nopw   0x0(%rax,%rax,1)
L220:
  mov    (%rbx,%rax,1),%rcx
  movsd  (%rcx,%rdx,1),%xmm0
  mulsd  (%rdi,%rax,1),%xmm0
  add    $0x8,%rax
  subsd  %xmm0,%xmm1
  cmp    %rax,%rsi
  jne    L220
  add    $0x1,%r8d
  movsd  %xmm1,(%r9)
  add    $0x8,%rsi
  cmp    %r8d,%r13d
  jne    L47
L247:
  mov    (%rsp),%r9
  mov    %r11,%r8
  movapd %xmm4,%xmm3
  lea    -0x1(%r11),%edi
  nopl   0x0(%rax)
L101:
  mov    (%rbx,%r8,8),%rsi
  mov    %r8d,%r12d
  lea    (%rsi,%rdx,1),%r10
  movsd  (%r10),%xmm1
  test   %r11,%r11
  je     L199
  xor    %eax,%eax
  nopw   0x0(%rax,%rax,1)
L117:
  mov    (%rbx,%rax,8),%rcx
  movsd  (%rcx,%rdx,1),%xmm0
  mulsd  (%rsi,%rax,8),%xmm0
  mov    %rax,%rcx
  add    $0x1,%rax
  subsd  %xmm0,%xmm1
  cmp    %rdi,%rcx
  jne    L117
L199:
  movsd  %xmm1,(%r10)
  andpd  %xmm2,%xmm1
  mulsd  (%r9),%xmm1
  comisd %xmm3,%xmm1
  jb     L108
  movapd %xmm1,%xmm3
  mov    %r12d,%r14d
L108:
  add    $0x1,%r8
  add    $0x8,%r9
  cmp    %r8d,%ebp
  jg     L101
  mov    (%rbx,%r11,8),%rsi
  cmp    %r13d,%r14d
  jne    L46
L8:
  movsd  (%rsi,%rdx,1),%xmm0
  mov    0x10(%rsp),%rax
  ucomisd %xmm0,%xmm0
  mov    %r14d,(%rax,%r11,4)
  jp     L115
  comisd %xmm0,%xmm4
  ja     L115
  comisd %xmm4,%xmm0
  jbe    L143
L115:
  movapd %xmm5,%xmm1
  divsd  %xmm0,%xmm1
  cmp    %r11,0x8(%rsp)
  je     L70
  add    $0x1,%r11
  mov    %r11,%rax
  nopl   (%rax)
L224:
  mov    (%rbx,%rax,8),%rcx
  add    $0x1,%rax
  add    %rdx,%rcx
  movsd  (%rcx),%xmm0
  mulsd  %xmm1,%xmm0
  movsd  %xmm0,(%rcx)
  cmp    %eax,%ebp
  jg     L224
  addq   $0x8,(%rsp)
  jmp    L149
L46:
  movslq %r14d,%rdi
  mov    (%rbx,%rdi,8),%rcx
  lea    0xf(%rcx),%rax
  sub    %rsi,%rax
  cmp    $0x1e,%rax
  mov    $0x0,%eax
  jbe    L116
  cmpl   $0x1,0x30(%rsp)
  jbe    L116
  mov    0x28(%rsp),%r8
  nopw   0x0(%rax,%rax,1)
L22:
  movupd (%rcx,%rax,1),%xmm0
  movupd (%rsi,%rax,1),%xmm6
  movups %xmm6,(%rcx,%rax,1)
  movups %xmm0,(%rsi,%rax,1)
  add    $0x10,%rax
  cmp    %rax,%r8
  jne    L22
  cmp    0x34(%rsp),%ebp
  je     L166
  add    %r15,%rcx
  lea    (%rsi,%r15,1),%rax
  movsd  (%rcx),%xmm0
  movsd  (%rax),%xmm1
  movsd  %xmm1,(%rcx)
  movsd  %xmm0,(%rax)
L166:
  mov    0x20(%rsp),%rax
  negl   (%rax)
  mov    (%rsp),%rax
  movsd  (%rax),%xmm0
  mov    0x18(%rsp),%rax
  movsd  %xmm0,(%rax,%rdi,8)
  jmp    L8
L70:
  mov    0x18(%rsp),%rcx
  mov    $0x1c0,%edx
  lea    D52(%rip),%rsi
  xor    %eax,%eax
  lea    D20(%rip),%rdi
  call   <Free@plt>
  add    $0x48,%rsp
  mov    $0x1,%eax
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
L116:
  mov    0x38(%rsp),%r8
L165:
  movsd  (%rcx,%rax,8),%xmm0
  movsd  (%rsi,%rax,8),%xmm1
  movsd  %xmm1,(%rcx,%rax,8)
  movsd  %xmm0,(%rsi,%rax,8)
  add    $0x1,%rax
  cmp    %r8,%rax
  jne    L165
  jmp    L166
L143:
  add    $0x48,%rsp
  xor    %eax,%eax
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
```

tool_calls: name: unpack_data
arguments: data_tag: D20
type_guessed: string
name: unpack_data
arguments: data_tag: D52
type_guessed: string
name: unpack_data
arguments: data_tag: D40
type_guessed: qword
name: unpack_data
arguments: data_tag: D29
type_guessed: f32[2]

tool: D20: lu_decomposition

tool: D52: /scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/AZed/cdo/refs/heads/master/src/statistic.c

tool: D40: 9223372036854775807

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

assistant: ```c
int lu_decomposition(double **a, int n, int *index, int *sign) {
  int i, imax = 0, j, k;
  double big, sum, temp;
  double *v;
  v = (double *)Malloc(__func__, "/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/AZed/cdo/refs/heads/master/src/statistic.c", 390, (n * sizeof(double)));
  *sign = 1;
  for (i = 0; i < n; i++) {
    big = 0;
    for (j = 0; j < n; j++)
      if ((temp = fabs(a[i][j])) > big)
        big = temp;
    if ((((big) != (big)) || ((0.) != (0.)) ? (((big) != (big)) && ((0.) != (0.)) ? 1 : 0) : !(big < 0. || 0. < big)))
      return 0;
    v[i] = 1 / big;
  }
  for (j = 0; j < n; j++) {
    for (i = 0; i < j; i++) {
      sum = a[i][j];
      for (k = 0; k < i; k++)
        sum -= a[i][k] * a[k][j];
      a[i][j] = sum;
    }
    big = 0;
    for (i = j; i < n; i++) {
      sum = a[i][j];
      for (k = 0; k < j; k++)
        sum -= a[i][k] * a[k][j];
      a[i][j] = sum;
      if ((temp = v[i] * fabs(sum)) >= big) {
        big = temp;
        imax = i;
      }
    }
    if (j != imax) {
      for (k = 0; k < n; k++) {
        temp = a[imax][k];
        a[imax][k] = a[j][k];
        a[j][k] = temp;
      }
      *sign = -*sign;
      v[imax] = v[j];
    }
    index[j] = imax;
    if ((((a[j][j]) != (a[j][j])) || ((0.) != (0.)) ? (((a[j][j]) != (a[j][j])) && ((0.) != (0.)) ? 1 : 0) : !(a[j][j] < 0. || 0. < a[j][j])))
      return 0;
    if (j != n) {
      temp = 1 / a[j][j];
      for (i = j + 1; i < n; i++)
        a[i][j] *= temp;
    }
  }
  Free(__func__, "/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/AZed/cdo/refs/heads/master/src/statistic.c", 448, (v));
  return 1;
}
```