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

```asm
<count_4>:
  endbr64
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x98,%rsp
  mov    %fs:0x28,%rax
  mov    %rax,0x88(%rsp)
  xor    %eax,%eax
  lea    0x10(%rsp),%rdi
  mov    $0xd,%ecx
  rep stos %rax,%es:(%rdi)
  movl   $0x0,(%rdi)
  mov    $0x0,%ebp
  mov    $0x0,%r14d
  mov    $0x0,%r12d
  mov    $0x0,%ebx
  mov    $0x1,%r13d
  jmp    L145
L170:
  lea    -0x30(%rdi),%eax
  cmp    $0x9,%eax
  ja     L83
  add    $0x1,%r14d
  jmp    L192
L83:
  lea    -0x9(%rdi),%eax
  cmp    $0x1,%eax
  jbe    L39
  cmp    $0x20,%edi
  je     L39
  test   %ebx,%ebx
  jne    L192
L39:
  add    $0x1,%ebp
L192:
  mov    %r13d,%ebx
L145:
  mov    $0x0,%eax
  call   <getchar@plt>
  mov    %eax,%edi
  cmp    $0x7e,%eax
  je     L70
  lea    -0x41(%rdi),%eax
  cmp    $0x39,%eax
  ja     L170
  call   <toupper@plt>
  sub    $0x41,%eax
  cltq
  addl   $0x1,0x10(%rsp,%rax,4)
  add    $0x1,%r12d
  jmp    L192
L70:
  mov    %r14d,%ecx
  mov    %r12d,%edx
  mov    %ebp,%esi
  lea    D39(%rip),%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  lea    0x10(%rsp),%rax
  mov    %rax,0x8(%rsp)
  lea    0x78(%rsp),%r12
  mov    $0x0,%r15d
L133:
  mov    (%rax),%edx
  cmp    %edx,%r15d
  cmovl  %edx,%r15d
  add    $0x4,%rax
  cmp    %r12,%rax
  jne    L133
  mov    %r15d,%ebp
  lea    D48(%rip),%r14
  lea    D13(%rip),%r13
  test   %r15d,%r15d
  jns    L153
L97:
  lea    D49(%rip),%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  mov    $0x41,%ebx
  lea    D8(%rip),%rbp
L41:
  mov    %ebx,%esi
  mov    %rbp,%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  add    $0x1,%ebx
  cmp    $0x5b,%ebx
  jne    L41
  mov    0x88(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L198
  add    $0x98,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
L99:
  mov    %ebp,%esi
  lea    D16(%rip),%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  jmp    L128
L10:
  mov    %r14,%rdi
  mov    $0x0,%eax
  call   <printf@plt>
L131:
  add    $0x4,%rbx
  cmp    %rbx,%r12
  je     L110
L98:
  cmp    %ebp,(%rbx)
  jl     L10
  mov    %r13,%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  jmp    L131
L110:
  mov    $0xa,%edi
  call   <putchar@plt>
  lea    D19(%rip),%rdi
  call   <puts@plt>
  sub    $0x1,%ebp
  cmp    $0xffffffff,%ebp
  je     L97
L153:
  cmp    %ebp,%r15d
  jge    L99
L128:
  mov    0x8(%rsp),%rbx
  jmp    L98
L198:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: unpack_data
arguments: label: D39
data_type: string
name: unpack_data
arguments: label: D48
data_type: string
name: unpack_data
arguments: label: D13
data_type: string
name: unpack_data
arguments: label: D49
data_type: string
name: unpack_data
arguments: label: D8
data_type: string
name: unpack_data
arguments: label: D16
data_type: string
name: unpack_data
arguments: label: D19
data_type: string

tool: D39: So you had %d words with %d letters and %d numbers




tool: D48:    

tool: D13:  * 

tool: D49:   Letter |

tool: D8:  %c 

tool: D16: Times x %d|

tool: D19: ----------------------------------------------------------------------------------------

assistant: ```c
void count_4(void) {
  int x, c, nr_maxim, state, lit, nre, words;
  nr_maxim = lit = nre = words = 0;
  int litere[27] = {0};
  state = 0;
  while ((c = getchar()) != '~') {
    if (c >= 'A' && c <= 'z') {
      c = toupper(c);
      litere[c - 'A']++;
      lit++;
      state = 1;
    } else if (c >= '0' && c <= '9') {
      nre++;
      state = 1;
    } else if (c == ' ' || c == '\t' || c == '\n')
      state = 0;
    if (state == 0) {
      words++;
      state = 1;
    }
  }
  printf("So you had %d words with %d letters and %d numbers\n\n\n", words, lit, nre);
  for (x = 0; x < 26; x++) {
    if (nr_maxim < litere[x]) {
      nr_maxim = litere[x];
    }
  }
  for (x = nr_maxim; x >= 0; x--) {
    while (x <= nr_maxim) {
      printf("Times x %d|", x);
      break;
    }
    for (c = 0; c < 26; c++) {
      if (litere[c] >= x)
        printf(" * ");
      else
        printf("   ");
    }
    putchar('\n');
    puts("----------------------------------------------------------------------------------------");
  }
  printf("  Letter |");
  for (x = 65; x < 91; x++)
    printf(" %c ", x);
}
```