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

```asm
<getPLU>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x40,%rsp
  mov    %rdi,-0x18(%rbp)
  mov    %esi,-0x1c(%rbp)
  mov    %edx,-0x20(%rbp)
  mov    %rcx,-0x28(%rbp)
  mov    %r8,-0x30(%rbp)
  mov    %r9,-0x38(%rbp)
  cmpq   $0x0,-0x30(%rbp)
  je     L346
  movl   $0x0,-0x8(%rbp)
  jmp    L135
L164:
  mov    -0x8(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x30(%rbp),%rax
  add    %rdx,%rax
  pxor   %xmm0,%xmm0
  movsd  %xmm0,(%rax)
  addl   $0x1,-0x8(%rbp)
L135:
  mov    -0x1c(%rbp),%eax
  imul   %eax,%eax
  cmp    %eax,-0x8(%rbp)
  jl     L164
  movl   $0x0,-0x4(%rbp)
  jmp    L416
L478:
  mov    -0x4(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rdx
  mov    -0x28(%rbp),%rax
  add    %rdx,%rax
  mov    (%rax),%eax
  imul   -0x1c(%rbp),%eax
  mov    %eax,%edx
  mov    -0x4(%rbp),%eax
  add    %edx,%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x30(%rbp),%rax
  add    %rdx,%rax
  movsd  D9(%rip),%xmm0
  movsd  %xmm0,(%rax)
  addl   $0x1,-0x4(%rbp)
L416:
  mov    -0x4(%rbp),%eax
  cmp    -0x1c(%rbp),%eax
  jl     L478
L346:
  mov    -0x1c(%rbp),%eax
  cmp    -0x20(%rbp),%eax
  jne    L515
  cmpq   $0x0,-0x38(%rbp)
  je     L133
  movl   $0x0,-0x8(%rbp)
  jmp    L307
L455:
  movl   $0x0,-0x4(%rbp)
  jmp    L408
L303:
  mov    -0x8(%rbp),%eax
  imul   -0x1c(%rbp),%eax
  mov    %eax,%edx
  mov    -0x4(%rbp),%eax
  add    %edx,%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x18(%rbp),%rax
  add    %rax,%rdx
  mov    -0x8(%rbp),%eax
  imul   -0x1c(%rbp),%eax
  mov    %eax,%ecx
  mov    -0x4(%rbp),%eax
  add    %ecx,%eax
  cltq
  lea    0x0(,%rax,8),%rcx
  mov    -0x38(%rbp),%rax
  add    %rcx,%rax
  movsd  (%rdx),%xmm0
  movsd  %xmm0,(%rax)
  addl   $0x1,-0x4(%rbp)
L408:
  mov    -0x4(%rbp),%eax
  cmp    -0x8(%rbp),%eax
  jl     L303
  mov    -0x8(%rbp),%eax
  imul   -0x1c(%rbp),%eax
  mov    %eax,%edx
  mov    -0x8(%rbp),%eax
  add    %edx,%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x38(%rbp),%rax
  add    %rdx,%rax
  movsd  D9(%rip),%xmm0
  movsd  %xmm0,(%rax)
  mov    -0x8(%rbp),%eax
  add    $0x1,%eax
  mov    %eax,-0x4(%rbp)
  jmp    L116
L289:
  mov    -0x8(%rbp),%eax
  imul   -0x1c(%rbp),%eax
  mov    %eax,%edx
  mov    -0x4(%rbp),%eax
  add    %edx,%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x38(%rbp),%rax
  add    %rdx,%rax
  pxor   %xmm0,%xmm0
  movsd  %xmm0,(%rax)
  addl   $0x1,-0x4(%rbp)
L116:
  mov    -0x4(%rbp),%eax
  cmp    -0x1c(%rbp),%eax
  jl     L289
  addl   $0x1,-0x8(%rbp)
L307:
  mov    -0x8(%rbp),%eax
  cmp    -0x1c(%rbp),%eax
  jl     L455
L133:
  cmpq   $0x0,0x10(%rbp)
  je     L443
  movl   $0x0,-0x8(%rbp)
  jmp    L292
L294:
  movl   $0x0,-0x4(%rbp)
  jmp    L134
L333:
  mov    -0x8(%rbp),%eax
  imul   -0x1c(%rbp),%eax
  mov    %eax,%edx
  mov    -0x4(%rbp),%eax
  add    %edx,%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    0x10(%rbp),%rax
  add    %rdx,%rax
  pxor   %xmm0,%xmm0
  movsd  %xmm0,(%rax)
  addl   $0x1,-0x4(%rbp)
L134:
  mov    -0x4(%rbp),%eax
  cmp    -0x8(%rbp),%eax
  jl     L333
  mov    -0x8(%rbp),%eax
  mov    %eax,-0x4(%rbp)
  jmp    L67
L211:
  mov    -0x8(%rbp),%eax
  imul   -0x1c(%rbp),%eax
  mov    %eax,%edx
  mov    -0x4(%rbp),%eax
  add    %edx,%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x18(%rbp),%rax
  add    %rax,%rdx
  mov    -0x8(%rbp),%eax
  imul   -0x1c(%rbp),%eax
  mov    %eax,%ecx
  mov    -0x4(%rbp),%eax
  add    %ecx,%eax
  cltq
  lea    0x0(,%rax,8),%rcx
  mov    0x10(%rbp),%rax
  add    %rcx,%rax
  movsd  (%rdx),%xmm0
  movsd  %xmm0,(%rax)
  addl   $0x1,-0x4(%rbp)
L67:
  mov    -0x4(%rbp),%eax
  cmp    -0x1c(%rbp),%eax
  jl     L211
  addl   $0x1,-0x8(%rbp)
L292:
  mov    -0x8(%rbp),%eax
  cmp    -0x1c(%rbp),%eax
  jl     L294
  jmp    L443
L515:
  mov    -0x1c(%rbp),%eax
  cmp    -0x20(%rbp),%eax
  jle    L298
  cmpq   $0x0,-0x38(%rbp)
  je     L379
  movl   $0x0,-0x8(%rbp)
  jmp    L185
L82:
  movl   $0x0,-0x4(%rbp)
  jmp    L258
L284:
  mov    -0x8(%rbp),%eax
  imul   -0x20(%rbp),%eax
  mov    %eax,%edx
  mov    -0x4(%rbp),%eax
  add    %edx,%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x18(%rbp),%rax
  add    %rax,%rdx
  mov    -0x8(%rbp),%eax
  imul   -0x20(%rbp),%eax
  mov    %eax,%ecx
  mov    -0x4(%rbp),%eax
  add    %ecx,%eax
  cltq
  lea    0x0(,%rax,8),%rcx
  mov    -0x38(%rbp),%rax
  add    %rcx,%rax
  movsd  (%rdx),%xmm0
  movsd  %xmm0,(%rax)
  addl   $0x1,-0x4(%rbp)
L258:
  mov    -0x4(%rbp),%eax
  cmp    -0x8(%rbp),%eax
  jl     L284
  mov    -0x8(%rbp),%eax
  imul   -0x20(%rbp),%eax
  mov    %eax,%edx
  mov    -0x8(%rbp),%eax
  add    %edx,%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x38(%rbp),%rax
  add    %rdx,%rax
  movsd  D9(%rip),%xmm0
  movsd  %xmm0,(%rax)
  mov    -0x8(%rbp),%eax
  add    $0x1,%eax
  mov    %eax,-0x4(%rbp)
  jmp    L45
L38:
  mov    -0x8(%rbp),%eax
  imul   -0x20(%rbp),%eax
  mov    %eax,%edx
  mov    -0x4(%rbp),%eax
  add    %edx,%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x38(%rbp),%rax
  add    %rdx,%rax
  pxor   %xmm0,%xmm0
  movsd  %xmm0,(%rax)
  addl   $0x1,-0x4(%rbp)
L45:
  mov    -0x4(%rbp),%eax
  cmp    -0x20(%rbp),%eax
  jl     L38
  addl   $0x1,-0x8(%rbp)
L185:
  mov    -0x8(%rbp),%eax
  cmp    -0x20(%rbp),%eax
  jl     L82
  mov    -0x1c(%rbp),%eax
  sub    -0x20(%rbp),%eax
  cltq
  mov    %eax,%edx
  mov    -0x20(%rbp),%eax
  cltq
  imul   %edx,%eax
  shl    $0x3,%eax
  mov    %eax,%edx
  mov    -0x20(%rbp),%eax
  imul   %eax,%eax
  cltq
  lea    0x0(,%rax,8),%rcx
  mov    -0x18(%rbp),%rax
  add    %rax,%rcx
  mov    -0x20(%rbp),%eax
  imul   %eax,%eax
  cltq
  lea    0x0(,%rax,8),%rsi
  mov    -0x38(%rbp),%rax
  add    %rsi,%rax
  mov    %rcx,%rsi
  mov    %rax,%rdi
  call   <memcpy@plt>
L379:
  cmpq   $0x0,0x10(%rbp)
  je     L443
  movl   $0x0,-0x8(%rbp)
  jmp    L400
L318:
  movl   $0x0,-0x4(%rbp)
  jmp    L471
L37:
  mov    -0x8(%rbp),%eax
  imul   -0x20(%rbp),%eax
  mov    %eax,%edx
  mov    -0x4(%rbp),%eax
  add    %edx,%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    0x10(%rbp),%rax
  add    %rdx,%rax
  pxor   %xmm0,%xmm0
  movsd  %xmm0,(%rax)
  addl   $0x1,-0x4(%rbp)
L471:
  mov    -0x4(%rbp),%eax
  cmp    -0x8(%rbp),%eax
  jl     L37
  mov    -0x8(%rbp),%eax
  mov    %eax,-0x4(%rbp)
  jmp    L337
L102:
  mov    -0x8(%rbp),%eax
  imul   -0x20(%rbp),%eax
  mov    %eax,%edx
  mov    -0x4(%rbp),%eax
  add    %edx,%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x18(%rbp),%rax
  add    %rax,%rdx
  mov    -0x8(%rbp),%eax
  imul   -0x20(%rbp),%eax
  mov    %eax,%ecx
  mov    -0x4(%rbp),%eax
  add    %ecx,%eax
  cltq
  lea    0x0(,%rax,8),%rcx
  mov    0x10(%rbp),%rax
  add    %rcx,%rax
  movsd  (%rdx),%xmm0
  movsd  %xmm0,(%rax)
  addl   $0x1,-0x4(%rbp)
L337:
  mov    -0x4(%rbp),%eax
  cmp    -0x20(%rbp),%eax
  jl     L102
  addl   $0x1,-0x8(%rbp)
L400:
  mov    -0x8(%rbp),%eax
  cmp    -0x20(%rbp),%eax
  jl     L318
  jmp    L443
L298:
  mov    -0x1c(%rbp),%eax
  cmp    -0x20(%rbp),%eax
  jge    L443
  cmpq   $0x0,-0x38(%rbp)
  je     L229
  movl   $0x0,-0x8(%rbp)
  jmp    L63
L28:
  movl   $0x0,-0x4(%rbp)
  jmp    L231
L444:
  mov    -0x8(%rbp),%eax
  imul   -0x20(%rbp),%eax
  mov    %eax,%edx
  mov    -0x4(%rbp),%eax
  add    %edx,%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x18(%rbp),%rax
  add    %rax,%rdx
  mov    -0x8(%rbp),%eax
  imul   -0x1c(%rbp),%eax
  mov    %eax,%ecx
  mov    -0x4(%rbp),%eax
  add    %ecx,%eax
  cltq
  lea    0x0(,%rax,8),%rcx
  mov    -0x38(%rbp),%rax
  add    %rcx,%rax
  movsd  (%rdx),%xmm0
  movsd  %xmm0,(%rax)
  addl   $0x1,-0x4(%rbp)
L231:
  mov    -0x4(%rbp),%eax
  cmp    -0x8(%rbp),%eax
  jl     L444
  mov    -0x8(%rbp),%eax
  imul   -0x1c(%rbp),%eax
  mov    %eax,%edx
  mov    -0x8(%rbp),%eax
  add    %edx,%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x38(%rbp),%rax
  add    %rdx,%rax
  movsd  D9(%rip),%xmm0
  movsd  %xmm0,(%rax)
  mov    -0x8(%rbp),%eax
  add    $0x1,%eax
  mov    %eax,-0x4(%rbp)
  jmp    L113
L152:
  mov    -0x8(%rbp),%eax
  imul   -0x1c(%rbp),%eax
  mov    %eax,%edx
  mov    -0x4(%rbp),%eax
  add    %edx,%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x38(%rbp),%rax
  add    %rdx,%rax
  pxor   %xmm0,%xmm0
  movsd  %xmm0,(%rax)
  addl   $0x1,-0x4(%rbp)
L113:
  mov    -0x4(%rbp),%eax
  cmp    -0x1c(%rbp),%eax
  jl     L152
  addl   $0x1,-0x8(%rbp)
L63:
  mov    -0x8(%rbp),%eax
  cmp    -0x1c(%rbp),%eax
  jl     L28
L229:
  cmpq   $0x0,0x10(%rbp)
  je     L443
  movl   $0x0,-0x8(%rbp)
  jmp    L234
L495:
  movl   $0x0,-0x4(%rbp)
  jmp    L241
L494:
  mov    -0x8(%rbp),%eax
  imul   -0x20(%rbp),%eax
  mov    %eax,%edx
  mov    -0x4(%rbp),%eax
  add    %edx,%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    0x10(%rbp),%rax
  add    %rdx,%rax
  pxor   %xmm0,%xmm0
  movsd  %xmm0,(%rax)
  addl   $0x1,-0x4(%rbp)
L241:
  mov    -0x4(%rbp),%eax
  cmp    -0x8(%rbp),%eax
  jl     L494
  mov    -0x8(%rbp),%eax
  mov    %eax,-0x4(%rbp)
  jmp    L68
L39:
  mov    -0x8(%rbp),%eax
  imul   -0x20(%rbp),%eax
  mov    %eax,%edx
  mov    -0x4(%rbp),%eax
  add    %edx,%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x18(%rbp),%rax
  add    %rax,%rdx
  mov    -0x8(%rbp),%eax
  imul   -0x20(%rbp),%eax
  mov    %eax,%ecx
  mov    -0x4(%rbp),%eax
  add    %ecx,%eax
  cltq
  lea    0x0(,%rax,8),%rcx
  mov    0x10(%rbp),%rax
  add    %rcx,%rax
  movsd  (%rdx),%xmm0
  movsd  %xmm0,(%rax)
  addl   $0x1,-0x4(%rbp)
L68:
  mov    -0x4(%rbp),%eax
  cmp    -0x20(%rbp),%eax
  jl     L39
  addl   $0x1,-0x8(%rbp)
L234:
  mov    -0x8(%rbp),%eax
  cmp    -0x1c(%rbp),%eax
  jl     L495
L443:
  nop
  leave
  ret
```

tool_calls: name: disassemble_data
arguments: data_tag: D9
type_guessed: f64

tool: D9: 1

assistant: ```c
void getPLU(double *A, int M, int N, int *ipiv, double *P, double *L, double *U) {
  int i, j, k;
  if (P) {
    for (i = 0; i < M * M; ++i) {
      P[i] = 0.0;
    }
    for (j = 0; j < M; ++j) {
      P[ipiv[j] * M + j] = 1.0;
    }
  }
  if (M == N) {
    if (L) {
      for (i = 0; i < M; ++i) {
        for (j = 0; j < i; ++j) {
          L[i * M + j] = A[i * M + j];
        }
        L[i * M + i] = 1.0;
        for (j = i + 1; j < M; ++j) {
          L[i * M + j] = 0.0;
        }
      }
    }
    if (U) {
      for (i = 0; i < M; ++i) {
        for (j = 0; j < i; ++j) {
          U[i * M + j] = 0.0;
        }
        for (j = i; j < M; ++j) {
          U[i * M + j] = A[i * M + j];
        }
      }
    }
  } else if (M > N) {
    if (L) {
      for (i = 0; i < N; ++i) {
        for (j = 0; j < i; ++j) {
          L[i * N + j] = A[i * N + j];
        }
        L[i * N + i] = 1.0;
        for (j = i + 1; j < N; ++j) {
          L[i * N + j] = 0.0;
        }
      }
      memcpy(L + N * N, A + N * N, sizeof(double) * (M - N) * N);
    }
    if (U) {
      for (i = 0; i < N; ++i) {
        for (j = 0; j < i; ++j) {
          U[i * N + j] = 0.0;
        }
        for (j = i; j < N; ++j) {
          U[i * N + j] = A[i * N + j];
        }
      }
    }
  } else if (M < N) {
    if (L) {
      for (i = 0; i < M; ++i) {
        for (j = 0; j < i; ++j) {
          L[i * M + j] = A[i * N + j];
        }
        L[i * M + i] = 1.0;
        for (j = i + 1; j < M; ++j) {
          L[i * M + j] = 0.0;
        }
      }
    }
    if (U) {
      for (i = 0; i < M; ++i) {
        for (j = 0; j < i; ++j) {
          U[i * N + j] = 0.0;
        }
        for (j = i; j < N; ++j) {
          U[i * N + j] = A[i * N + j];
        }
      }
    }
  }
}
```