user: 请显示与下面列出的汇编代码相匹配的C语言实现:

```asm
<put_char>:
  endbr64
  push   %r15
  mov    %esi,%r15d
  push   %r14
  mov    %r9d,%r14d
  push   %r13
  mov    %edi,%r13d
  push   %r12
  mov    %r8d,%r12d
  movzbl %r13b,%r13d
  push   %rbp
  shl    $0x4,%r13
  push   %rbx
  mov    %ecx,%ebx
  sub    $0x18,%rsp
  mov    0x50(%rsp),%edi
  mov    0x58(%rsp),%rbp
  mov    %edx,0xc(%rsp)
  call   <select_font@plt>
  mov    0xc(%rsp),%edx
  mov    %ebx,%edi
  mov    %r12d,%ebx
  add    %r13,%rax
  lea    (%rdx,%rdx,4),%esi
  shl    $0x7,%esi
  add    %r15d,%esi
  movslq %esi,%rcx
  lea    0x7(%rsi),%r8d
  lea    0x4(%rsi),%r11d
  lea    0x5(%rsi),%r10d
  lea    0x0(%rbp,%rcx,1),%rdx
  add    $0x6,%esi
  lea    0x2800(%rbp,%rcx,1),%r13
  jmp    L77
  nopl   0x0(%rax,%rax,1)
L75:
  mov    %r12b,(%rdx)
  cmpb   $0x0,(%rax)
  js     L139
  mov    %r12b,0x1(%rdx)
  testb  $0x40,(%rax)
  je     L259
  mov    %dil,0x2(%rdx)
  testb  $0x20,(%rax)
  je     L393
  mov    %dil,0x3(%rdx)
  testb  $0x10,(%rax)
  jne    L320
  nopl   0x0(%rax,%rax,1)
L273:
  movslq %r11d,%rcx
  mov    %bl,0x0(%rbp,%rcx,1)
  testb  $0x8,(%rax)
  jne    L329
L177:
  movslq %r10d,%rcx
  mov    %bl,0x0(%rbp,%rcx,1)
  testb  $0x4,(%rax)
  jne    L32
L70:
  movslq %esi,%rcx
  mov    %bl,0x0(%rbp,%rcx,1)
  testb  $0x2,(%rax)
  jne    L114
L297:
  movslq %r8d,%rcx
  mov    %bl,0x0(%rbp,%rcx,1)
L298:
  add    $0x280,%rdx
  add    $0x280,%r8d
  add    $0x1,%rax
  add    $0x280,%r11d
  add    $0x280,%r10d
  add    $0x280,%esi
  cmp    %rdx,%r13
  je     L106
L77:
  test   %r14d,%r14d
  jne    L75
  movzbl (%rax),%r9d
  test   %r9b,%r9b
  jns    L17
  mov    %dil,0x1(%rdx)
  movzbl (%rax),%ecx
  mov    %ecx,%r9d
  and    $0x40,%r9d
  je     L217
  mov    %dil,0x2(%rdx)
  movzbl (%rax),%ecx
  mov    %ecx,%r9d
  and    $0x20,%r9d
  jne    L69
L356:
  test   $0x10,%cl
  jne    L320
L252:
  test   $0x8,%cl
  jne    L329
L335:
  test   $0x4,%cl
  jne    L32
L295:
  and    $0x2,%ecx
  je     L298
L114:
  movslq %r8d,%rcx
  mov    %dil,0x0(%rbp,%rcx,1)
  jmp    L298
  nopl   0x0(%rax)
L32:
  movslq %esi,%rcx
  mov    %dil,0x0(%rbp,%rcx,1)
  testb  $0x2,(%rax)
  jne    L114
  test   %r14d,%r14d
  je     L298
  jmp    L297
  nopl   0x0(%rax,%rax,1)
L329:
  movslq %r10d,%rcx
  mov    %dil,0x0(%rbp,%rcx,1)
  movzbl (%rax),%ecx
  mov    %ecx,%r9d
  and    $0x4,%r9d
  jne    L32
  test   %r14d,%r14d
  jne    L70
  jmp    L295
  nop
L259:
  mov    %r12b,0x2(%rdx)
  testb  $0x20,(%rax)
  jne    L69
L393:
  mov    %r12b,0x3(%rdx)
  testb  $0x10,(%rax)
  je     L273
L320:
  movslq %r11d,%rcx
  mov    %dil,0x0(%rbp,%rcx,1)
  movzbl (%rax),%ecx
  mov    %ecx,%r9d
  and    $0x8,%r9d
  jne    L329
  test   %r14d,%r14d
  jne    L177
  jmp    L335
  nopl   0x0(%rax,%rax,1)
L217:
  test   $0x20,%cl
  je     L356
L69:
  mov    %dil,0x3(%rdx)
  movzbl (%rax),%ecx
  mov    %ecx,%r9d
  and    $0x10,%r9d
  jne    L320
  test   %r14d,%r14d
  jne    L273
  jmp    L252
  nopw   0x0(%rax,%rax,1)
L17:
  movzbl %r9b,%ecx
  and    $0x40,%r9d
  je     L217
  mov    %dil,0x2(%rdx)
  movzbl (%rax),%ecx
  mov    %ecx,%r9d
  and    $0x20,%r9d
  je     L356
  mov    %dil,0x3(%rdx)
  movzbl (%rax),%ecx
  mov    %ecx,%r9d
  and    $0x10,%r9d
  je     L252
  jmp    L320
L106:
  add    $0x18,%rsp
  xor    %eax,%eax
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
L139:
  mov    %dil,0x1(%rdx)
  testb  $0x40,(%rax)
  je     L259
  mov    %dil,0x2(%rdx)
  testb  $0x20,(%rax)
  jne    L69
  jmp    L393
```

assistant: ```c
int put_char(unsigned char c, int x, int y, int fg_color, int bg_color, int overwrite, int which_font, unsigned char *buffer) {
  int xx, yy;
  int output_pointer;
  unsigned char(*font)[256][16];
  font = select_font(which_font);
  output_pointer = (y * 640) + x;
  for (yy = 0; yy < 16; yy++) {
    for (xx = 0; xx < 8; xx++) {
      if ((*font)[c][yy] & (1 << (8 - xx))) {
        buffer[output_pointer] = fg_color;
      } else if (overwrite) {
        buffer[output_pointer] = bg_color;
      }
      output_pointer++;
    }
    output_pointer += (640 - 8);
  }
  return 0;
}
```