user: Translate the below assembly code into C programming language:

```asm
<TwoPhaseAdvection_2D_Evaluate>:
  endbr64
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x38,%rsp
  movsd  %xmm0,0x8(%rsp)
  movsd  %xmm1,0x10(%rsp)
  movsd  %xmm3,0x18(%rsp)
  mov    %rsi,0x20(%rsp)
  mov    0xb0(%rsp),%r15
  test   %edi,%edi
  jle    L13
  mov    %rdx,%r13
  mov    %r9,%r14
  mov    %rcx,%r12
  mov    %r8,%rbp
  mov    %edi,%eax
  shl    $0x3,%rax
  mov    %rax,0x28(%rsp)
  mov    $0x0,%ebx
L10:
  mov    0x20(%rsp),%rax
  movsd  (%rax,%rbx,1),%xmm1
  movsd  0x8(%rsp),%xmm0
  call   <smoothedHeaviside@plt>
  movapd %xmm0,%xmm1
  movsd  D6(%rip),%xmm0
  subsd  %xmm1,%xmm0
  mulsd  0x10(%rsp),%xmm0
  mulsd  0x18(%rsp),%xmm1
  addsd  %xmm1,%xmm0
  movapd %xmm0,%xmm1
  mulsd  (%r12),%xmm1
  mulsd  0x0(%r13,%rbx,1),%xmm1
  movsd  %xmm1,(%r14,%rbx,2)
  movapd %xmm0,%xmm1
  mulsd  0x0(%rbp),%xmm1
  mulsd  0x0(%r13,%rbx,1),%xmm1
  movsd  %xmm1,0x8(%r14,%rbx,2)
  movapd %xmm0,%xmm1
  mulsd  (%r12),%xmm1
  mov    0x70(%rsp),%rax
  movsd  %xmm1,(%rax,%rbx,2)
  movapd %xmm0,%xmm1
  mulsd  0x0(%rbp),%xmm1
  movsd  %xmm1,0x8(%rax,%rbx,2)
  mov    0x78(%rsp),%rax
  movq   $0x0,(%rax,%rbx,2)
  mov    0x80(%rsp),%rax
  movq   $0x0,0x8(%rax,%rbx,2)
  movsd  (%r12),%xmm2
  movapd %xmm2,%xmm1
  mulsd  %xmm0,%xmm1
  mulsd  %xmm2,%xmm1
  mov    0x88(%rsp),%rax
  movsd  %xmm1,(%rax,%rbx,2)
  movapd %xmm0,%xmm1
  mulsd  (%r12),%xmm1
  mulsd  0x0(%rbp),%xmm1
  movsd  %xmm1,0x8(%rax,%rbx,2)
  movapd %xmm0,%xmm1
  addsd  %xmm0,%xmm1
  movapd %xmm1,%xmm2
  mulsd  (%r12),%xmm2
  mov    0x90(%rsp),%rax
  movsd  %xmm2,(%rax,%rbx,2)
  movapd %xmm0,%xmm2
  mulsd  0x0(%rbp),%xmm2
  movsd  %xmm2,0x8(%rax,%rbx,2)
  movapd %xmm0,%xmm2
  mulsd  (%r12),%xmm2
  mov    0x98(%rsp),%rax
  movsd  %xmm2,0x8(%rax,%rbx,2)
  movapd %xmm0,%xmm2
  mulsd  0x0(%rbp),%xmm2
  mulsd  (%r12),%xmm2
  mov    0xa0(%rsp),%rax
  movsd  %xmm2,(%rax,%rbx,2)
  movsd  0x0(%rbp),%xmm3
  movapd %xmm3,%xmm2
  mulsd  %xmm0,%xmm2
  mulsd  %xmm3,%xmm2
  movsd  %xmm2,0x8(%rax,%rbx,2)
  movapd %xmm0,%xmm2
  mulsd  0x0(%rbp),%xmm2
  mov    0xa8(%rsp),%rax
  movsd  %xmm2,(%rax,%rbx,2)
  mulsd  (%r12),%xmm0
  movsd  %xmm0,(%r15,%rbx,2)
  mulsd  0x0(%rbp),%xmm1
  movsd  %xmm1,0x8(%r15,%rbx,2)
  add    $0x8,%r12
  add    $0x8,%rbp
  add    $0x8,%rbx
  cmp    0x28(%rsp),%rbx
  jne    L10
L13:
  add    $0x38,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
```

tool_calls: name: unpack_data
arguments: tag: D6
datatype: f64

tool: D6: 1

assistant: ```c
void TwoPhaseAdvection_2D_Evaluate(const int nPoints, const double eps, const double rho_0, const double nu_0, const double rho_1, const double nu_1, const double *phi, const double *p, const double *u, const double *v, double *mass_adv, double *dmass_adv_p, double *dmass_adv_u, double *dmass_adv_v, double *mom_u_adv, double *dmom_u_adv_u, double *dmom_u_adv_v, double *mom_v_adv, double *dmom_v_adv_u, double *dmom_v_adv_v) {
  int k;
  double rho, nu, mu, H;
  for (k = 0; k < nPoints; k++) {
    H = smoothedHeaviside(eps, phi[k]);
    rho = rho_0 * (1.0 - H) + rho_1 * H;
    nu = nu_0 * (1.0 - H) + nu_1 * H;
    mu = rho_0 * nu_0 * (1.0 - H) + rho_1 * nu_1 * H;
    mass_adv[k * 2 + 0] = rho * u[k] * p[k];
    mass_adv[k * 2 + 1] = rho * v[k] * p[k];
    dmass_adv_p[k * 2 + 0] = rho * u[k];
    dmass_adv_p[k * 2 + 1] = rho * v[k];
    dmass_adv_u[k * 2 + 0] = 0.0;
    dmass_adv_v[k * 2 + 1] = 0.0;
    mom_u_adv[k * 2 + 0] = rho * u[k] * u[k];
    mom_u_adv[k * 2 + 1] = rho * u[k] * v[k];
    dmom_u_adv_u[k * 2 + 0] = rho * 2.0 * u[k];
    dmom_u_adv_u[k * 2 + 1] = rho * v[k];
    dmom_u_adv_v[k * 2 + 1] = rho * u[k];
    mom_v_adv[k * 2 + 0] = rho * v[k] * u[k];
    mom_v_adv[k * 2 + 1] = rho * v[k] * v[k];
    dmom_v_adv_u[k * 2 + 0] = rho * v[k];
    dmom_v_adv_v[k * 2 + 0] = rho * u[k];
    dmom_v_adv_v[k * 2 + 1] = rho * 2.0 * v[k];
  }
}
```