user: 请将这段汇编代码片段转换成等效的C代码:

```asm
<gaussj>:
  endbr64
  push   %r15
  mov    %rsi,%r9
  push   %r14
  push   %r13
  mov    %edi,%r13d
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x2d8,%rsp
  mov    %rcx,0x30(%rsp)
  mov    %fs:0x28,%rax
  mov    %rax,0x2c8(%rsp)
  xor    %eax,%eax
  lea    -0x1(%rdi),%eax
  mov    %eax,0x5c(%rsp)
  test   %edi,%edi
  jle    L365
  movslq %edi,%r14
  lea    0x60(%rsp),%r15
  mov    %rsi,0x8(%rsp)
  mov    %edx,%ebx
  xor    %esi,%esi
  lea    0x0(,%r14,4),%rdx
  mov    %r15,%rdi
  movslq %ebx,%rbp
  call   <memset@plt>
  lea    0x130(%rsp),%rax
  mov    0x8(%rsp),%r9
  shl    $0x3,%rbp
  mov    %rax,0x48(%rsp)
  lea    0x200(%rsp),%rax
  lea    0x0(,%r14,8),%r12
  movq   $0x0,0x28(%rsp)
  mov    %rax,0x50(%rsp)
  nopw   0x0(%rax,%rax,1)
L107:
  xor    %esi,%esi
  mov    %r12,0x38(%rsp)
  pxor   %xmm1,%xmm1
  mov    %r15,%r12
  mov    %rbp,0x40(%rsp)
  mov    %r13d,%r15d
  mov    %r9,%rbp
  mov    %r14,%r13
  mov    %ebx,0x58(%rsp)
  mov    %rsi,%r14
  jmp    L134
  nopl   (%rax)
L93:
  add    $0x1,%r14
  cmp    %r14,%r13
  je     L71
L134:
  cmpl   $0x1,(%r12,%r14,4)
  mov    %r14d,%edx
  je     L93
  mov    %r14d,0x10(%rsp)
  xor    %ebx,%ebx
  mov    %r14,0x20(%rsp)
  mov    %rbp,%r14
  mov    %edx,%ebp
  jmp    L69
  nopw   0x0(%rax,%rax,1)
L184:
  movslq %ebp,%rax
  movsd  (%r14,%rax,8),%xmm0
  andpd  D5(%rip),%xmm0
  comisd %xmm1,%xmm0
  jb     L274
  mov    0x10(%rsp),%eax
  mov    %ebx,0x18(%rsp)
  movapd %xmm0,%xmm1
  mov    %eax,0x1c(%rsp)
L274:
  add    $0x1,%rbx
  add    %r15d,%ebp
  cmp    %rbx,%r13
  je     L196
L69:
  mov    (%r12,%rbx,4),%eax
  test   %eax,%eax
  je     L184
  cmp    $0x1,%eax
  jle    L274
  lea    D46(%rip),%rdi
  movsd  %xmm1,0x8(%rsp)
  add    $0x1,%rbx
  add    %r15d,%ebp
  call   <printf@plt>
  mov    $0x63,%edi
  call   <exit@plt>
  movsd  0x8(%rsp),%xmm1
  cmp    %rbx,%r13
  jne    L69
L196:
  mov    %r14,%rbp
  mov    0x20(%rsp),%r14
  add    $0x1,%r14
  cmp    %r14,%r13
  jne    L134
L71:
  movslq 0x18(%rsp),%rcx
  mov    %r13,%r14
  mov    %rbp,%r9
  mov    %r15d,%r13d
  mov    0x40(%rsp),%rbp
  mov    %r12,%r15
  mov    0x58(%rsp),%ebx
  addl   $0x1,0x60(%rsp,%rcx,4)
  mov    0x38(%rsp),%r12
  cmp    0x1c(%rsp),%ecx
  jne    L207
L90:
  mov    0x28(%rsp),%rax
  mov    0x48(%rsp),%rsi
  pxor   %xmm3,%xmm3
  mov    0x1c(%rsp),%edi
  mov    %edi,(%rsi,%rax,4)
  mov    0x18(%rsp),%edi
  mov    0x50(%rsp),%rsi
  mov    %edi,(%rsi,%rax,4)
  mov    %edi,%eax
  imul   %r13d,%eax
  mov    %eax,0x8(%rsp)
  add    %edi,%eax
  cltq
  lea    (%r9,%rax,8),%rdx
  movsd  (%rdx),%xmm1
  ucomisd %xmm3,%xmm1
  jp     L211
  je     L60
L211:
  movsd  D33(%rip),%xmm0
  mov    D33(%rip),%rax
  xor    %esi,%esi
  divsd  %xmm1,%xmm0
  mov    %rax,(%rdx)
  lea    0x0(,%rcx,8),%rax
  lea    (%r9,%rax,1),%rdx
L331:
  movsd  (%rdx),%xmm1
  mov    %esi,%edi
  lea    0x1(%rsi),%esi
  mulsd  %xmm0,%xmm1
  movsd  %xmm1,(%rdx)
  add    %r12,%rdx
  cmp    %esi,%r13d
  jne    L331
  add    0x30(%rsp),%rax
  xor    %edx,%edx
  test   %ebx,%ebx
  jle    L277
  nopl   0x0(%rax)
L240:
  movsd  (%rax),%xmm1
  add    $0x1,%edx
  mulsd  %xmm0,%xmm1
  movsd  %xmm1,(%rax)
  add    %rbp,%rax
  cmp    %edx,%ebx
  jne    L240
L277:
  mov    %r14,0x10(%rsp)
  mov    0x30(%rsp),%r11
  mov    %r9,%r10
  xor    %r8d,%r8d
  mov    %r13d,0x20(%rsp)
  mov    0x18(%rsp),%r14d
  mov    0x8(%rsp),%r13d
  nopl   (%rax)
L26:
  cmp    %r8d,%r14d
  je     L144
  lea    (%r8,%r13,1),%eax
  xor    %edx,%edx
  cltq
  lea    (%r9,%rax,8),%rax
  movsd  (%rax),%xmm1
  movq   $0x0,(%rax)
  mov    %r10,%rax
  nop
L306:
  movsd  (%rax,%rcx,8),%xmm2
  movsd  (%rax),%xmm0
  mov    %edx,%esi
  add    $0x1,%edx
  mulsd  %xmm1,%xmm2
  subsd  %xmm2,%xmm0
  movsd  %xmm0,(%rax)
  add    %r12,%rax
  cmp    %edi,%esi
  jne    L306
  test   %ebx,%ebx
  jle    L144
  mov    %r11,%rax
  xor    %edx,%edx
  nopw   0x0(%rax,%rax,1)
L76:
  movsd  (%rax,%rcx,8),%xmm2
  movsd  (%rax),%xmm0
  add    $0x1,%edx
  mulsd  %xmm1,%xmm2
  subsd  %xmm2,%xmm0
  movsd  %xmm0,(%rax)
  add    %rbp,%rax
  cmp    %edx,%ebx
  jne    L76
L144:
  lea    0x1(%r8),%eax
  add    $0x8,%r11
  sub    $0x1,%rcx
  add    $0x8,%r10
  cmp    %edi,%r8d
  je     L123
  mov    %eax,%r8d
  jmp    L26
  nopl   0x0(%rax)
L123:
  addq   $0x1,0x28(%rsp)
  mov    0x10(%rsp),%r14
  mov    0x28(%rsp),%rax
  mov    0x20(%rsp),%r13d
  cmp    %rax,%r14
  jne    L107
L187:
  movslq 0x5c(%rsp),%rcx
  mov    0x48(%rsp),%r10
  lea    0x8(%r9),%rdi
  mov    0x50(%rsp),%r11
  mov    %ecx,%r8d
  jmp    L17
  cs nopw 0x0(%rax,%rax,1)
L335:
  sub    $0x1,%rcx
  test   %ecx,%ecx
  js     L378
L17:
  mov    (%r10,%rcx,4),%esi
  mov    (%r11,%rcx,4),%eax
  cmp    %eax,%esi
  je     L335
  test   %r13d,%r13d
  jle    L335
  imul   %r13d,%esi
  imul   %r13d,%eax
  movslq %esi,%rsi
  movslq %eax,%rdx
  lea    (%r8,%rsi,1),%rbx
  lea    (%r9,%rsi,8),%rax
  lea    (%rdi,%rbx,8),%rbx
  sub    %rsi,%rdx
  cs nopw 0x0(%rax,%rax,1)
L35:
  movsd  (%rax),%xmm0
  movsd  (%rax,%rdx,8),%xmm1
  movsd  %xmm1,(%rax)
  movsd  %xmm0,(%rax,%rdx,8)
  add    $0x8,%rax
  cmp    %rbx,%rax
  jne    L35
  sub    $0x1,%rcx
  test   %ecx,%ecx
  jns    L17
L378:
  mov    0x2c8(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L320
  add    $0x2d8,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
  nopl   0x0(%rax)
L207:
  movslq 0x1c(%rsp),%r8
  mov    %rcx,%rsi
  xor    %edi,%edi
  lea    0x0(,%r8,8),%rax
  sub    %r8,%rsi
  lea    (%r9,%rax,1),%rdx
  nopl   0x0(%rax)
L275:
  movsd  (%rdx),%xmm0
  movsd  (%rdx,%rsi,8),%xmm1
  add    $0x1,%edi
  movsd  %xmm1,(%rdx)
  movsd  %xmm0,(%rdx,%rsi,8)
  add    %r12,%rdx
  cmp    %edi,%r13d
  jne    L275
  test   %ebx,%ebx
  jle    L90
  add    0x30(%rsp),%rax
  xor    %edx,%edx
  nopl   0x0(%rax)
L97:
  movsd  (%rax),%xmm0
  movsd  (%rax,%rsi,8),%xmm1
  add    $0x1,%edx
  movsd  %xmm1,(%rax)
  movsd  %xmm0,(%rax,%rsi,8)
  add    %rbp,%rax
  cmp    %edx,%ebx
  jne    L97
  jmp    L90
L60:
  lea    D46(%rip),%rdi
  mov    %r9,0x38(%rsp)
  mov    %rcx,0x20(%rsp)
  mov    %rdx,0x10(%rsp)
  call   <printf@plt>
  mov    $0x63,%edi
  call   <exit@plt>
  mov    0x10(%rsp),%rdx
  mov    0x38(%rsp),%r9
  mov    0x20(%rsp),%rcx
  movsd  (%rdx),%xmm1
  jmp    L211
L365:
  mov    0x5c(%rsp),%eax
  test   %eax,%eax
  js     L378
  lea    0x130(%rsp),%rax
  mov    %rax,0x48(%rsp)
  lea    0x200(%rsp),%rax
  mov    %rax,0x50(%rsp)
  jmp    L187
L320:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: disassemble_data
arguments: tag: D5
data_type: qword[2]
name: disassemble_data
arguments: tag: D46
data_type: string
name: disassemble_data
arguments: tag: D33
data_type: f64

tool: {"D5": [0x7fffffffffffffff,0x0000000000000000]}

tool: D46: Error: singular matrix in gaussj


tool: D33: 1

assistant: ```c
void gaussj(int n, double a[], int m, double b[]) {
  int i, j, k, l, ll;
  int icol, irow;
  int ipiv[50], indxr[50], indxc[50];
  double big, dum, pivinv;
  for (j = 0; j < n; ++j)
    ipiv[j] = 0;
  for (i = 0; i < n; ++i) {
    big = 0.0;
    for (j = 0; j < n; ++j) {
      if (ipiv[j] != 1) {
        for (k = 0; k < n; ++k) {
          if (ipiv[k] == 0) {
            if (fabs(a[j + k * n]) >= big) {
              big = fabs(a[j + k * n]);
              irow = j;
              icol = k;
            }
          } else if (ipiv[k] > 1) {
            printf("Error: singular matrix in gaussj\n");
            exit(99);
          }
        }
      }
    }
    ++ipiv[icol];
    if (irow != icol) {
      for (l = 0; l < n; ++l) {
        dum = a[irow + l * n];
        a[irow + l * n] = a[icol + l * n];
        a[icol + l * n] = dum;
      }
      for (l = 0; l < m; ++l) {
        dum = b[irow + l * m];
        b[irow + l * m] = b[icol + l * m];
        b[icol + l * m] = dum;
      }
    }
    indxr[i] = irow;
    indxc[i] = icol;
    if (a[icol + n * icol] == 0.0) {
      printf("Error: singular matrix in gaussj\n");
      exit(99);
    }
    pivinv = 1.0 / a[icol + icol * n];
    a[icol + icol * n] = 1.0;
    for (l = 0; l < n; ++l)
      a[icol + l * n] *= pivinv;
    for (l = 0; l < m; ++l)
      b[icol + l * m] *= pivinv;
    for (ll = 0; ll < n; ++ll) {
      if (ll != icol) {
        dum = a[ll + icol * n];
        a[ll + icol * n] = 0.0;
        for (l = 0; l < n; ++l)
          a[ll + l * n] -= a[icol + l * n] * dum;
        for (l = 0; l < m; ++l)
          b[ll + l * m] -= b[icol + l * m] * dum;
      }
    }
  }
  for (l = (n - 1); l >= 0; --l) {
    if (indxr[l] != indxc[l]) {
      for (k = 0; k < n; ++k) {
        dum = a[k + indxr[l] * n];
        a[k + indxr[l] * n] = a[k + indxc[l] * n];
        a[k + indxc[l] * n] = dum;
      }
    }
  }
}
```