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

```asm
<display>:
  endbr64
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  lea    -0x3(%rsi),%ebp
  push   %rbx
  mov    %esi,%ebx
  sub    $0x28,%rsp
  mov    %edi,0x1c(%rsp)
  mov    %rdx,0x10(%rsp)
  test   %ebp,%ebp
  jle    L2
  lea    -0x4(%rsi),%eax
  mov    %rdx,%rcx
  add    $0x1,%rax
  lea    (%rax,%rax,4),%rdx
  lea    (%rax,%rdx,8),%rax
  add    %rax,%rcx
  mov    %rcx,0x10(%rsp)
L2:
  xor    %esi,%esi
  xor    %edi,%edi
  lea    D17(%rip),%r12
  call   <move@plt>
  mov    %r12,%rdi
  lea    D4(%rip),%r15
  call   <addstr@plt>
  xor    %esi,%esi
  mov    $0xf,%edi
  call   <move@plt>
  mov    %r12,%rdi
  call   <addstr@plt>
  lea    0x3(%rbx),%eax
  mov    $0x1,%ebx
  mov    %eax,0x18(%rsp)
  jmp    L1
  nop
L57:
  call   <move@plt>
  mov    %r15,%rdi
  add    $0x1,%ebp
  add    $0x2,%ebx
  call   <addstr@plt>
  xor    %esi,%esi
  mov    %r13d,%edi
  call   <move@plt>
  mov    %r15,%rdi
  call   <addstr@plt>
  cmp    0x18(%rsp),%ebp
  jg     L51
L1:
  lea    -0x1(%rbx),%r12d
  lea    0x1(%rbx),%r13d
  xor    %esi,%esi
  mov    %ebx,%edi
  cmp    $0xf,%ebp
  ja     L57
  call   <move@plt>
  mov    $0x7c,%edi
  xor    %r14d,%r14d
  call   <addch@plt>
  mov    $0x22,%esi
  mov    %ebx,%edi
  call   <move@plt>
  mov    $0x7c,%edi
  call   <addch@plt>
  xor    %esi,%esi
  mov    %r13d,%edi
  call   <move@plt>
  mov    $0x7c,%edi
  call   <addch@plt>
  mov    %r13d,%edi
  mov    $0x22,%esi
  call   <move@plt>
  mov    $0x7c,%edi
  call   <addch@plt>
  mov    0x1c(%rsp),%eax
  lea    0x5(%rax),%ecx
  mov    %ecx,0xc(%rsp)
  lea    -0x5(%rax),%ecx
  movslq %ecx,%r13
  jmp    L63
  cs nopw 0x0(%rax,%rax,1)
L66:
  mov    %r14d,%edi
  mov    $0x23,%edx
  mov    %r12d,%esi
  add    $0x1,%r13
  call   <draw_symbol@plt>
  add    $0x3,%r14d
  cmp    %r13d,0xc(%rsp)
  jl     L45
L63:
  cmp    $0x27,%r13d
  ja     L66
  mov    0x10(%rsp),%rax
  mov    %r14d,%edi
  mov    %r12d,%esi
  add    $0x3,%r14d
  movsbl (%rax,%r13,1),%edx
  add    $0x1,%r13
  call   <draw_symbol@plt>
  cmp    %r13d,0xc(%rsp)
  jge    L63
L45:
  addq   $0x29,0x10(%rsp)
  add    $0x1,%ebp
  add    $0x2,%ebx
  cmp    0x18(%rsp),%ebp
  jle    L1
L51:
  xor    %esi,%esi
  mov    $0x10,%edi
  call   <move@plt>
  add    $0x28,%rsp
  xor    %eax,%eax
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  jmp    10d0 <refresh@plt>
```

tool_calls: name: read_data
arguments: data_tag: D17
type_infered: string
name: read_data
arguments: data_tag: D4
type_infered: string

tool: D17: +---------------------------------+

tool: D4: |#################################|

assistant: ```c
void display(int cx, int cy, char (*row_ptr)[40 + 1], long score) {
  int x, y = 0, x_coord, y_coord;
  char ch;
  while (y < (cy - 3)) {
    y++;
    row_ptr++;
  };
  move(0, 0);
  addstr("+---------------------------------+");
  move(15, 0);
  addstr("+---------------------------------+");
  for (y = (cy - 3); y <= (cy + 3); y++) {
    y_coord = (y + 3 - cy) * 2;
    if ((y < 0) || (y >= 16)) {
      move(y_coord + 1, 0);
      addstr("|#################################|");
      move(y_coord + 2, 0);
      addstr("|#################################|");
    } else {
      move(y_coord + 1, 0);
      addch('|');
      move(y_coord + 1, 34);
      addch('|');
      move(y_coord + 2, 0);
      addch('|');
      move(y_coord + 2, 34);
      addch('|');
      for (x = (cx - 5); x <= (cx + 5); x++) {
        x_coord = (x + 5 - cx) * 3;
        if ((x < 0) || (x > 40 - 1))
          draw_symbol(x_coord, y_coord, '#');
        else {
          ch = (*row_ptr)[x];
          draw_symbol(x_coord, y_coord, ch);
        }
      };
      row_ptr++;
    }
  }
  move(16, 0);
  refresh();
}
```