user: Please show me the C implementation that matches the assembly code listed below:

```asm
<boundaryvalues>:
  endbr64
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x48,%rsp
  mov    %edi,0x3c(%rsp)
  mov    %esi,0x38(%rsp)
  mov    %edx,0xc(%rsp)
  mov    %rcx,0x10(%rsp)
  mov    %r8,0x18(%rsp)
  mov    %r9,0x20(%rsp)
  movsd  %xmm0,0x30(%rsp)
  cmp    $0xffffffff,%edi
  jl     L35
  lea    0x1(%rdx),%eax
  cmp    $0xffffffff,%esi
  jl     L35
  test   %eax,%eax
  js     L35
  mov    0xa8(%rsp),%r14
  xor    %r13d,%r13d
  lea    D3(%rip),%rbx
  nopw   0x0(%rax,%rax,1)
L52:
  movq   $0x0,0x28(%rsp)
  nopl   0x0(%rax)
L56:
  mov    0x28(%rsp),%rax
  xor    %r12d,%r12d
  mov    %eax,%ebp
  shl    $0x3,%rax
  mov    %rax,(%rsp)
  nopw   0x0(%rax,%rax,1)
L90:
  mov    (%r14),%rax
  mov    (%rsp),%rdx
  mov    (%rax,%rdx,1),%rax
  mov    (%rax,%r12,4),%edi
  call   <getcelltype@plt>
  cmp    $0x6,%eax
  ja     L39
  mov    %eax,%eax
  movslq (%rbx,%rax,4),%rax
  add    %rbx,%rax
  notrack jmp *%rax
  nopl   (%rax)
  push   0xb0(%rsp)
  mov    %r12d,%edx
  mov    %ebp,%esi
  mov    %r13d,%edi
  push   0xb0(%rsp)
  mov    0x30(%rsp),%r9
  mov    0x28(%rsp),%r8
  mov    0x20(%rsp),%rcx
  call   <boundaryvalues_moving_wall@plt>
  pop    %rax
  pop    %rdx
L39:
  add    $0x1,%r12
  lea    -0x1(%r12),%eax
  cmp    %eax,0xc(%rsp)
  jge    L90
  addq   $0x1,0x28(%rsp)
  mov    0x28(%rsp),%rax
  sub    $0x1,%eax
  cmp    %eax,0x38(%rsp)
  jge    L56
  lea    0x1(%r13),%eax
  add    $0x8,%r14
  cmp    %r13d,0x3c(%rsp)
  jl     L35
  mov    %eax,%r13d
  jmp    L52
  cs nopw 0x0(%rax,%rax,1)
  sub    $0x8,%rsp
  mov    %r12d,%edx
  mov    %ebp,%esi
  mov    %r13d,%edi
  push   0xb0(%rsp)
  mov    0x30(%rsp),%r9
  mov    0x28(%rsp),%r8
  mov    0x20(%rsp),%rcx
  call   <boundaryvalues_free_slip@plt>
  pop    %r10
  pop    %r11
  jmp    L39
  nopl   (%rax)
  sub    $0x8,%rsp
  mov    %r12d,%edx
  mov    %ebp,%esi
  mov    %r13d,%edi
  push   0xb0(%rsp)
  mov    0x30(%rsp),%r9
  mov    0x28(%rsp),%r8
  mov    0x20(%rsp),%rcx
  call   <boundaryvalues_no_slip@plt>
  pop    %rdi
  push   0xb0(%rsp)
  mov    %r12d,%edx
  movsd  0x40(%rsp),%xmm0
  mov    %ebp,%esi
  mov    %r13d,%edi
  mov    0x30(%rsp),%r9
  mov    0x28(%rsp),%r8
  mov    0x20(%rsp),%rcx
  call   <boundaryvalues_inflow@plt>
  pop    %r8
  pop    %r9
  jmp    L39
  nopw   0x0(%rax,%rax,1)
  sub    $0x8,%rsp
  mov    %ebp,%esi
  mov    %r12d,%edx
  mov    %r13d,%edi
  push   0xb0(%rsp)
  mov    0x30(%rsp),%r9
  mov    0x28(%rsp),%r8
  mov    0x20(%rsp),%rcx
  call   <boundaryvalues_outflow@plt>
  pop    %rcx
  pop    %rsi
  jmp    L39
  xchg   %ax,%ax
  sub    $0x8,%rsp
  mov    %r12d,%edx
  mov    %ebp,%esi
  mov    %r13d,%edi
  push   0xb0(%rsp)
  mov    0x30(%rsp),%r9
  mov    0x28(%rsp),%r8
  mov    0x20(%rsp),%rcx
  call   <boundaryvalues_no_slip@plt>
  pop    %r15
  pop    %rax
  jmp    L39
L35:
  add    $0x48,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
```

assistant: ```c
void boundaryvalues(int imax, int jmax, int kmax, double ***U, double ***V, double ***W, double ***P, double ***F, double ***G, double ***H, char *problem, int ***Flag, double velIN, double *velMW) {
  int i, j, k;
  for (i = 0; i < imax + 2; i++) {
    for (j = 0; j < jmax + 2; j++) {
      for (k = 0; k < kmax + 2; k++) {
        switch (getcelltype(Flag[i][j][k])) {
        case 2:
          boundaryvalues_no_slip(i, j, k, U, V, W, Flag);
          break;
        case 3:
          boundaryvalues_free_slip(i, j, k, U, V, W, Flag);
          break;
        case 5:
          boundaryvalues_no_slip(i, j, k, U, V, W, Flag);
          boundaryvalues_inflow(i, j, k, U, V, W, Flag, velIN);
          break;
        case 4:
          boundaryvalues_outflow(i, j, k, U, V, W, Flag);
          break;
        case 6:
          boundaryvalues_moving_wall(i, j, k, U, V, W, Flag, velMW);
          break;
        default:
          break;
        }
      }
    }
  }
}
```