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

```asm
<sor>:
  endbr64
  movapd %xmm1,%xmm6
  movapd %xmm2,%xmm7
  push   %r15
  movapd %xmm0,%xmm4
  push   %r14
  mulsd  %xmm1,%xmm6
  push   %r13
  mulsd  %xmm2,%xmm7
  push   %r12
  mulsd  %xmm3,%xmm3
  push   %rbp
  mov    %edx,%ebp
  push   %rbx
  sub    $0x98,%rsp
  movsd  D37(%rip),%xmm0
  movsd  D37(%rip),%xmm1
  movsd  %xmm6,0x20(%rsp)
  mov    0xd0(%rsp),%rax
  divsd  %xmm7,%xmm1
  movsd  %xmm7,0x28(%rsp)
  movsd  D37(%rip),%xmm7
  mov    %edi,0x5c(%rsp)
  subsd  %xmm4,%xmm7
  mov    %esi,0x58(%rsp)
  mov    %rcx,0x68(%rsp)
  mov    %r8,0x38(%rsp)
  mov    %r9,0x80(%rsp)
  mov    %rax,0x70(%rsp)
  movsd  %xmm3,0x30(%rsp)
  movsd  %xmm7,0x50(%rsp)
  divsd  %xmm6,%xmm0
  movapd %xmm4,%xmm6
  addsd  %xmm1,%xmm0
  movsd  D37(%rip),%xmm1
  divsd  %xmm3,%xmm1
  addsd  %xmm1,%xmm0
  addsd  %xmm0,%xmm0
  divsd  %xmm0,%xmm6
  movsd  %xmm6,0x48(%rsp)
  test   %edi,%edi
  jle    L119
  mov    0x70(%rsp),%rsi
  mov    %rcx,0x78(%rsp)
  pxor   %xmm6,%xmm6
  movq   $0x1,0x40(%rsp)
  lea    0x8(%rsi),%r12
  movsd  %xmm6,0x60(%rsp)
  mov    %r12,0x88(%rsp)
  mov    %r12,%r14
  mov    %rcx,%r12
  movsd  %xmm6,0x18(%rsp)
  nopl   (%rax)
L57:
  mov    0x58(%rsp),%edx
  movl   $0x1,0xc(%rsp)
  mov    $0x8,%ebx
  test   %edx,%edx
  jle    L156
  nopl   0x0(%rax)
L95:
  lea    0x8(%rbx),%rax
  xor    %r15d,%r15d
  mov    %rax,(%rsp)
  lea    -0x8(%rbx),%rax
  mov    %r15,%r13
  mov    %r14,%r15
  mov    %rax,0x10(%rsp)
  test   %ebp,%ebp
  jg     L79
  jmp    L120
  nopl   0x0(%rax,%rax,1)
L106:
  lea    0x1(%r14),%eax
  mov    %r14,%r13
  cmp    %eax,%ebp
  jl     L193
L79:
  mov    (%r15),%rax
  lea    0x1(%r13),%r14
  mov    (%rax,%rbx,1),%rax
  mov    (%rax,%r14,4),%edi
  call   <isfluid@plt>
  test   %rax,%rax
  je     L106
  mov    (%r15),%rax
  mov    (%rax,%rbx,1),%rax
  mov    (%rax,%r14,4),%edi
  call   <emptyneighbor@plt>
  test   %eax,%eax
  jne    L106
  mov    0x10(%r12),%r10
  mov    0x8(%r12),%r9
  lea    0x0(,%r13,8),%rax
  mov    (%rsp),%rdx
  mov    0x10(%rsp),%rsi
  mov    (%r10,%rbx,1),%r11
  mov    (%r12),%r10
  mov    (%r9,%rbx,1),%r8
  movsd  D37(%rip),%xmm5
  mov    (%r10,%rbx,1),%r10
  movsd  0x8(%r11,%rax,1),%xmm0
  lea    0x8(%r8,%rax,1),%rdi
  addsd  0x18(%rsp),%xmm5
  addsd  0x8(%r10,%rax,1),%xmm0
  mov    (%r9,%rdx,1),%r10
  divsd  0x20(%rsp),%xmm0
  mov    (%r9,%rsi,1),%r9
  mov    0x38(%rsp),%rdx
  mov    0x40(%rsp),%rsi
  movsd  0x8(%r10,%rax,1),%xmm1
  movsd  %xmm5,0x18(%rsp)
  addsd  0x8(%r9,%rax,1),%xmm1
  divsd  0x28(%rsp),%xmm1
  addsd  %xmm1,%xmm0
  movsd  0x10(%r8,%rax,1),%xmm1
  mov    (%rdx,%rsi,8),%rcx
  addsd  (%r8,%r13,8),%xmm1
  divsd  0x30(%rsp),%xmm1
  mov    %r14,%r13
  mov    (%rcx,%rbx,1),%rcx
  addsd  %xmm1,%xmm0
  movsd  0x50(%rsp),%xmm1
  mulsd  (%rdi),%xmm1
  subsd  0x8(%rcx,%rax,1),%xmm0
  mulsd  0x48(%rsp),%xmm0
  lea    0x1(%r14),%eax
  addsd  %xmm1,%xmm0
  movsd  %xmm0,(%rdi)
  cmp    %eax,%ebp
  jge    L79
  nopw   0x0(%rax,%rax,1)
L193:
  mov    %r15,%r14
L120:
  addl   $0x1,0xc(%rsp)
  mov    (%rsp),%rbx
  mov    0xc(%rsp),%eax
  cmp    %eax,0x58(%rsp)
  jge    L95
L156:
  addq   $0x1,0x40(%rsp)
  add    $0x8,%r12
  mov    0x40(%rsp),%rax
  add    $0x8,%r14
  cmp    %eax,0x5c(%rsp)
  jge    L57
  mov    0x88(%rsp),%r12
  movsd  0x60(%rsp),%xmm7
  movq   $0x1,0x48(%rsp)
  mov    0x78(%rsp),%r13
  movsd  %xmm7,0x10(%rsp)
  mov    %r12,%r15
  nopl   0x0(%rax)
L157:
  mov    0x58(%rsp),%eax
  movl   $0x1,0xc(%rsp)
  mov    $0x8,%ebx
  test   %eax,%eax
  jle    L165
  nopl   0x0(%rax)
L43:
  lea    0x8(%rbx),%rax
  xor    %r14d,%r14d
  mov    %r15,%r12
  mov    %rax,(%rsp)
  lea    -0x8(%rbx),%rax
  mov    %rax,0x40(%rsp)
  test   %ebp,%ebp
  jg     L212
  jmp    L75
L192:
  lea    0x1(%r15),%eax
  mov    %r15,%r14
  cmp    %eax,%ebp
  jl     L0
L212:
  mov    (%r12),%rax
  lea    0x1(%r14),%r15
  mov    (%rax,%rbx,1),%rax
  mov    (%rax,%r15,4),%edi
  call   <isfluid@plt>
  test   %rax,%rax
  je     L192
  mov    (%r12),%rax
  mov    (%rax,%rbx,1),%rax
  mov    (%rax,%r15,4),%edi
  call   <emptyneighbor@plt>
  test   %eax,%eax
  jne    L192
  mov    0x8(%r13),%r8
  mov    0x10(%r13),%r9
  lea    0x0(,%r14,8),%rax
  mov    (%rsp),%rdx
  mov    0x40(%rsp),%rsi
  mov    (%r8,%rbx,1),%rdi
  mov    (%r9,%rbx,1),%r9
  movsd  0x8(%rdi,%rax,1),%xmm2
  movsd  0x8(%r9,%rax,1),%xmm0
  mov    0x0(%r13),%r9
  addsd  %xmm2,%xmm2
  mov    (%r9,%rbx,1),%r9
  subsd  %xmm2,%xmm0
  addsd  0x8(%r9,%rax,1),%xmm0
  mov    (%r8,%rdx,1),%r9
  divsd  0x20(%rsp),%xmm0
  mov    (%r8,%rsi,1),%r8
  mov    0x38(%rsp),%rdx
  mov    0x48(%rsp),%rsi
  movsd  0x8(%r9,%rax,1),%xmm1
  mov    (%rdx,%rsi,8),%rcx
  subsd  %xmm2,%xmm1
  addsd  0x8(%r8,%rax,1),%xmm1
  divsd  0x28(%rsp),%xmm1
  addsd  %xmm1,%xmm0
  movsd  0x10(%rdi,%rax,1),%xmm1
  mov    (%rcx,%rbx,1),%rcx
  subsd  %xmm2,%xmm1
  addsd  (%rdi,%r14,8),%xmm1
  divsd  0x30(%rsp),%xmm1
  mov    %r15,%r14
  addsd  %xmm1,%xmm0
  subsd  0x8(%rcx,%rax,1),%xmm0
  lea    0x1(%r15),%eax
  mulsd  %xmm0,%xmm0
  addsd  0x10(%rsp),%xmm0
  movsd  %xmm0,0x10(%rsp)
  cmp    %eax,%ebp
  jge    L212
  xchg   %ax,%ax
L0:
  mov    %r12,%r15
L75:
  addl   $0x1,0xc(%rsp)
  mov    (%rsp),%rbx
  mov    0xc(%rsp),%eax
  cmp    %eax,0x58(%rsp)
  jge    L43
L165:
  addq   $0x1,0x48(%rsp)
  add    $0x8,%r13
  mov    0x48(%rsp),%rax
  add    $0x8,%r15
  cmp    %eax,0x5c(%rsp)
  jge    L157
L15:
  movsd  0x60(%rsp),%xmm7
  movsd  0x10(%rsp),%xmm0
  divsd  0x18(%rsp),%xmm0
  ucomisd %xmm0,%xmm7
  ja     L123
  sqrtsd %xmm0,%xmm0
L82:
  mov    0x80(%rsp),%rax
  mov    0x58(%rsp),%ecx
  mov    %ebp,%r8d
  mov    0x5c(%rsp),%edx
  mov    0x70(%rsp),%rsi
  movsd  %xmm0,(%rax)
  mov    0x68(%rsp),%rdi
  add    $0x98,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  jmp    1090 <boundaryvalues_pressure@plt>
L119:
  pxor   %xmm4,%xmm4
  movsd  %xmm4,0x60(%rsp)
  movsd  %xmm4,0x18(%rsp)
  movsd  %xmm4,0x10(%rsp)
  jmp    L15
L123:
  call   <sqrt@plt>
  jmp    L82
```

tool_calls: name: parse_data
arguments: data_label: D37
type_infered: f64

tool: D37: 1

assistant: ```c
void sor(double omg, double dx, double dy, double dz, int imax, int jmax, int kmax, double ***P, double ***RS, double *res, int ***Flag) {
  int i, j, k;
  double rloc;
  double coeff = omg / (2.0 * (1.0 / (dx * dx) + 1.0 / (dy * dy) + 1.0 / (dz * dz)));
  double FluidCells = 0.0;
  double tmp = 0;
  double dx2 = dx * dx;
  double dy2 = dy * dy;
  double dz2 = dz * dz;
  double omg2 = 1 - omg;
  for (i = 1; i <= imax; i++) {
    for (j = 1; j <= jmax; j++) {
      for (k = 1; k <= kmax; k++) {
        if (isfluid(Flag[i][j][k]) && !emptyneighbor(Flag[i][j][k])) {
          P[i][j][k] = omg2 * P[i][j][k] + coeff * ((P[i + 1][j][k] + P[i - 1][j][k]) / dx2 + (P[i][j + 1][k] + P[i][j - 1][k]) / dy2 + (P[i][j][k + 1] + P[i][j][k - 1]) / dz2 - RS[i][j][k]);
          FluidCells++;
        }
      }
    }
  }
  rloc = 0;
  for (i = 1; i <= imax; i++) {
    for (j = 1; j <= jmax; j++) {
      for (k = 1; k <= kmax; k++) {
        if (isfluid(Flag[i][j][k]) && !emptyneighbor(Flag[i][j][k])) {
          tmp = (P[i + 1][j][k] - 2.0 * P[i][j][k] + P[i - 1][j][k]) / (dx2) + (P[i][j + 1][k] - 2.0 * P[i][j][k] + P[i][j - 1][k]) / (dy2) + (P[i][j][k + 1] - 2.0 * P[i][j][k] + P[i][j][k - 1]) / (dz2)-RS[i][j][k];
          rloc += tmp * tmp;
        }
      }
    }
  }
  rloc = rloc / FluidCells;
  rloc = sqrt(rloc);
  *res = rloc;
  boundaryvalues_pressure(P, Flag, imax, jmax, kmax);
}
```