user: 请从给定的汇编指令推导出C源代码:

```asm
<make_path>:
  endbr64
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x18,%rsp
  mov    %rdi,%rbp
  mov    %rsi,%rbx
  lea    (%rdi,%rdi,4),%r13
  shl    $0x2,%r13
  lea    (%rsi,%rsi,4),%r14
  shl    $0x2,%r14
  mov    $0xffffffff,%edx
  call   <chk_extend_path_h@plt>
  mov    %rax,%r15
  mov    $0x1,%edx
  mov    %rbx,%rsi
  mov    %rbp,%rdi
  call   <chk_extend_path_h@plt>
  mov    %rax,(%rsp)
  mov    $0x10,%edi
  call   <randm@plt>
  add    %r14,%r15
  lea    0x1(%rax),%r12d
  movslq %r12d,%r12
  add    %r13,%r12
  mov    $0x48,%r8d
  mov    %r15,%rcx
  mov    %r12,%rdx
  mov    %r15,%rsi
  mov    %r13,%rdi
  call   <line_path@plt>
  mov    (%rsp),%rax
  add    %r14,%rax
  mov    $0x48,%r8d
  mov    %rax,(%rsp)
  mov    %rax,%rcx
  mov    %r12,%rdx
  mov    %r15,%rsi
  mov    %r12,%rdi
  call   <line_path@plt>
  lea    0x11(%r13),%rdx
  mov    %rdx,0x8(%rsp)
  mov    $0x48,%r8d
  mov    (%rsp),%rcx
  mov    %rcx,%rsi
  mov    %r12,%rdi
  call   <line_path@plt>
  lea    -0x1(%rbp),%rdi
  mov    %rbx,%rsi
  call   <chk_room@plt>
  test   %rax,%rax
  jne    L37
L46:
  lea    0x1(%rbp),%rdi
  mov    %rbx,%rsi
  call   <chk_room@plt>
  test   %rax,%rax
  jne    L17
L24:
  mov    $0xffffffff,%edx
  mov    %rbx,%rsi
  mov    %rbp,%rdi
  call   <chk_extend_path_v@plt>
  mov    %rax,%r15
  mov    $0x1,%edx
  mov    %rbx,%rsi
  mov    %rbp,%rdi
  call   <chk_extend_path_v@plt>
  mov    %rax,(%rsp)
  mov    $0x10,%edi
  call   <randm@plt>
  lea    0x1(%rax),%r12d
  movslq %r12d,%r12
  add    %r14,%r12
  add    %r13,%r15
  mov    $0x56,%r8d
  mov    %r12,%rcx
  mov    %r15,%rdx
  mov    %r14,%rsi
  mov    %r15,%rdi
  call   <line_path@plt>
  mov    (%rsp),%rax
  add    %r13,%rax
  mov    $0x56,%r8d
  mov    %r12,%rcx
  mov    %rax,(%rsp)
  mov    %rax,%rdx
  mov    %r12,%rsi
  mov    %r15,%rdi
  call   <line_path@plt>
  lea    0x11(%r14),%rcx
  mov    %rcx,0x8(%rsp)
  mov    $0x56,%r8d
  mov    (%rsp),%rdx
  mov    %r12,%rsi
  mov    %rdx,%rdi
  call   <line_path@plt>
  lea    -0x1(%rbx),%rsi
  mov    %rbp,%rdi
  call   <chk_room@plt>
  test   %rax,%rax
  jne    L78
L70:
  lea    0x1(%rbx),%rsi
  mov    %rbp,%rdi
  call   <chk_room@plt>
  test   %rax,%rax
  jne    L51
L66:
  mov    $0x0,%eax
  call   <chk_lighted_path@plt>
  test   %rax,%rax
  jne    L18
L28:
  add    $0x18,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
L37:
  mov    $0x0,%ecx
  mov    $0xffffffff,%edx
  mov    %r15,%rsi
  mov    %r13,%rdi
  call   <finish_path@plt>
  jmp    L46
L17:
  mov    $0x0,%ecx
  mov    $0x1,%edx
  mov    (%rsp),%rsi
  mov    0x8(%rsp),%rdi
  call   <finish_path@plt>
  jmp    L24
L78:
  mov    $0xffffffff,%ecx
  mov    $0x0,%edx
  mov    %r14,%rsi
  mov    %r15,%rdi
  call   <finish_path@plt>
  jmp    L70
L51:
  mov    $0x1,%ecx
  mov    $0x0,%edx
  mov    0x8(%rsp),%rsi
  mov    (%rsp),%rdi
  call   <finish_path@plt>
  jmp    L66
L18:
  mov    $0x0,%edx
  mov    %r14,%rsi
  mov    %r13,%rdi
  call   <on_light_area@plt>
  jmp    L28
```

assistant: ```c
void make_path(long area_x, long area_y) {
  long bgn_x, bgn_y, end_x, end_y;
  long bend_x, bend_y;
  long mx, my;
  mx = area_x * 20;
  my = area_y * 20;
  bgn_y = chk_extend_path_h(area_x, area_y, -1);
  end_y = chk_extend_path_h(area_x, area_y, +1);
  bend_x = 1 + randm(20 - 3 + 1 - 2);
  line_path(mx + 0, my + bgn_y, mx + bend_x, my + bgn_y, 'H');
  line_path(mx + bend_x, my + bgn_y, mx + bend_x, my + end_y, 'H');
  line_path(mx + bend_x, my + end_y, mx + 20 - 3, my + end_y, 'H');
  if (chk_room(area_x - 1, area_y)) {
    finish_path(mx + 0, my + bgn_y, -1, 0);
  }
  if (chk_room(area_x + 1, area_y)) {
    finish_path(mx + 20 - 3, my + end_y, +1, 0);
  }
  bgn_x = chk_extend_path_v(area_x, area_y, -1);
  end_x = chk_extend_path_v(area_x, area_y, +1);
  bend_y = 1 + randm(20 - 3 + 1 - 2);
  line_path(mx + bgn_x, my + 0, mx + bgn_x, my + bend_y, 'V');
  line_path(mx + bgn_x, my + bend_y, mx + end_x, my + bend_y, 'V');
  line_path(mx + end_x, my + bend_y, mx + end_x, my + 20 - 3, 'V');
  if (chk_room(area_x, area_y - 1)) {
    finish_path(mx + bgn_x, my + 0, 0, -1);
  }
  if (chk_room(area_x, area_y + 1)) {
    finish_path(mx + end_x, my + 20 - 3, 0, +1);
  }
  if (chk_lighted_path()) {
    on_light_area(area_x * 20, area_y * 20, 0);
  }
}
```