user: What is the c source code of the assembly code below?

```asm
<calculateMinimumHP>:
  endbr64
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x18,%rsp
  mov    %rdi,%rbx
  mov    %esi,%r13d
  mov    %edx,%r14d
  mov    %edx,0x4(%rsp)
  movslq %esi,%rax
  mov    %rax,0x8(%rsp)
  lea    0x0(,%rsi,8),%edi
  call   <malloc@plt>
  mov    %rax,%r12
  test   %r13d,%r13d
  jle    L17
  lea    0x0(,%r14,4),%r15d
  mov    %rax,%rbp
  mov    %r13d,%eax
  lea    (%r12,%rax,8),%r14
L15:
  mov    %r15d,%edi
  call   <malloc@plt>
  mov    %rax,0x0(%rbp)
  add    $0x8,%rbp
  cmp    %r14,%rbp
  jne    L15
L17:
  mov    0x8(%rsp),%rax
  lea    -0x8(,%rax,8),%rcx
  lea    (%rbx,%rcx,1),%rdi
  movslq 0x4(%rsp),%rdx
  lea    0x0(,%rdx,4),%rsi
  lea    -0x4(%rsi),%r9
  add    %r12,%rcx
  mov    (%rcx),%r8
  mov    (%rdi),%r10
  mov    $0x1,%eax
  sub    -0x4(%r10,%rsi,1),%eax
  test   %eax,%eax
  mov    $0x1,%r10d
  cmovle %r10d,%eax
  mov    %eax,-0x4(%r8,%rsi,1)
  mov    %r13d,%esi
  sub    $0x2,%esi
  js     L89
  movslq %esi,%r8
L85:
  mov    (%r12,%r8,8),%r10
  mov    0x8(%r12,%r8,8),%rax
  mov    (%rbx,%r8,8),%r11
  mov    (%rax,%r9,1),%eax
  sub    (%r11,%r9,1),%eax
  test   %eax,%eax
  mov    $0x1,%r11d
  cmovle %r11d,%eax
  mov    %eax,(%r10,%r9,1)
  sub    $0x1,%r8
  test   %r8d,%r8d
  jns    L85
  mov    0x4(%rsp),%r8d
  sub    $0x2,%r8d
  js     L50
L37:
  movslq %r8d,%r9
  shl    $0x2,%r9
  mov    0x4(%rsp),%eax
  lea    -0x2(%rax),%r10d
  mov    %rdx,%rax
  sub    %r10,%rax
  lea    -0xc(,%rax,4),%r11
L11:
  mov    (%rcx),%r10
  mov    (%rdi),%rbp
  mov    0x4(%r10,%r9,1),%eax
  sub    0x0(%rbp,%r9,1),%eax
  test   %eax,%eax
  mov    $0x1,%ebp
  cmovle %ebp,%eax
  mov    %eax,(%r10,%r9,1)
  sub    $0x4,%r9
  cmp    %r11,%r9
  jne    L11
  test   %esi,%esi
  js     L70
L50:
  movslq %esi,%rax
  shl    $0x3,%rax
  lea    (%r12,%rax,1),%rdi
  add    %rax,%rbx
  sub    $0x8,%rax
  lea    -0x2(%r13),%ecx
  shl    $0x3,%rcx
  sub    %rcx,%rax
  lea    (%r12,%rax,1),%r10
  mov    0x4(%rsp),%eax
  sub    $0x2,%eax
  movslq %eax,%r11
  shl    $0x2,%r11
  mov    %eax,%eax
  sub    %rax,%rdx
  lea    -0xc(,%rdx,4),%r9
  jmp    L83
L120:
  mov    (%rdi),%rsi
  mov    (%rbx),%rax
  mov    (%rax,%rcx,1),%ebp
  mov    0x4(%rsi,%rcx,1),%eax
  sub    %ebp,%eax
  mov    0x8(%rdi),%rdx
  mov    (%rdx,%rcx,1),%edx
  sub    %ebp,%edx
  test   %eax,%eax
  mov    $0x1,%ebp
  cmovle %ebp,%eax
  test   %edx,%edx
  cmovle %ebp,%edx
  cmp    %edx,%eax
  cmovg  %edx,%eax
  mov    %eax,(%rsi,%rcx,1)
  sub    $0x4,%rcx
  cmp    %r9,%rcx
  jne    L120
L110:
  sub    $0x8,%rdi
  sub    $0x8,%rbx
  cmp    %r10,%rdi
  je     L70
L83:
  mov    %r11,%rcx
  test   %r8d,%r8d
  jns    L120
  jmp    L110
L89:
  mov    0x4(%rsp),%r8d
  sub    $0x2,%r8d
  jns    L37
L70:
  mov    (%r12),%rax
  mov    (%rax),%eax
  add    $0x18,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
```

assistant: ```c
int calculateMinimumHP(int **dungeon, int dungeonRowSize, int dungeonColSize) {
  int i, j;
  int **dp = malloc(dungeonRowSize * sizeof(int *));
  for (i = 0; i < dungeonRowSize; i++) {
    dp[i] = malloc(dungeonColSize * sizeof(int));
  }
  int hp = 1 - dungeon[dungeonRowSize - 1][dungeonColSize - 1];
  dp[dungeonRowSize - 1][dungeonColSize - 1] = hp >= 1 ? hp : 1;
  for (i = dungeonRowSize - 2; i >= 0; i--) {
    hp = dp[i + 1][dungeonColSize - 1] - dungeon[i][dungeonColSize - 1];
    dp[i][dungeonColSize - 1] = hp >= 1 ? hp : 1;
  }
  for (i = dungeonColSize - 2; i >= 0; i--) {
    hp = dp[dungeonRowSize - 1][i + 1] - dungeon[dungeonRowSize - 1][i];
    dp[dungeonRowSize - 1][i] = hp >= 1 ? hp : 1;
  }
  for (i = dungeonRowSize - 2; i >= 0; i--) {
    for (j = dungeonColSize - 2; j >= 0; j--) {
      int hp_r = dp[i][j + 1] - dungeon[i][j];
      int hp_d = dp[i + 1][j] - dungeon[i][j];
      hp_r = hp_r >= 1 ? hp_r : 1;
      hp_d = hp_d >= 1 ? hp_d : 1;
      dp[i][j] = hp_r < hp_d ? hp_r : hp_d;
    }
  }
  return dp[0][0];
}
```