user: Please show me the C implementation that matches the assembly code listed below:

```asm
<fcitx_utf8_char_len>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  mov    %rdi,-0x8(%rbp)
  mov    -0x8(%rbp),%rax
  movzbl (%rax),%eax
  test   %al,%al
  js     L83
  mov    $0x1,%eax
  jmp    L213
L83:
  mov    -0x8(%rbp),%rax
  movzbl (%rax),%eax
  movsbl %al,%eax
  and    $0xe0,%eax
  cmp    $0xc0,%eax
  jne    L4
  mov    -0x8(%rbp),%rax
  add    $0x1,%rax
  movzbl (%rax),%eax
  movsbl %al,%eax
  and    $0xc0,%eax
  cmp    $0x80,%eax
  jne    L4
  mov    $0x2,%eax
  jmp    L213
L4:
  mov    -0x8(%rbp),%rax
  movzbl (%rax),%eax
  movsbl %al,%eax
  and    $0xf0,%eax
  cmp    $0xe0,%eax
  jne    L111
  mov    -0x8(%rbp),%rax
  add    $0x1,%rax
  movzbl (%rax),%eax
  movsbl %al,%eax
  and    $0xc0,%eax
  cmp    $0x80,%eax
  jne    L111
  mov    -0x8(%rbp),%rax
  add    $0x2,%rax
  movzbl (%rax),%eax
  movsbl %al,%eax
  and    $0xc0,%eax
  cmp    $0x80,%eax
  jne    L111
  mov    $0x3,%eax
  jmp    L213
L111:
  mov    -0x8(%rbp),%rax
  movzbl (%rax),%eax
  movsbl %al,%eax
  and    $0xf8,%eax
  cmp    $0xf0,%eax
  jne    L10
  mov    -0x8(%rbp),%rax
  add    $0x1,%rax
  movzbl (%rax),%eax
  movsbl %al,%eax
  and    $0xc0,%eax
  cmp    $0x80,%eax
  jne    L10
  mov    -0x8(%rbp),%rax
  add    $0x2,%rax
  movzbl (%rax),%eax
  movsbl %al,%eax
  and    $0xc0,%eax
  cmp    $0x80,%eax
  jne    L10
  mov    -0x8(%rbp),%rax
  add    $0x3,%rax
  movzbl (%rax),%eax
  movsbl %al,%eax
  and    $0xc0,%eax
  cmp    $0x80,%eax
  jne    L10
  mov    $0x4,%eax
  jmp    L213
L10:
  mov    -0x8(%rbp),%rax
  movzbl (%rax),%eax
  movsbl %al,%eax
  and    $0xfc,%eax
  cmp    $0xf8,%eax
  jne    L47
  mov    -0x8(%rbp),%rax
  add    $0x1,%rax
  movzbl (%rax),%eax
  movsbl %al,%eax
  and    $0xc0,%eax
  cmp    $0x80,%eax
  jne    L47
  mov    -0x8(%rbp),%rax
  add    $0x2,%rax
  movzbl (%rax),%eax
  movsbl %al,%eax
  and    $0xc0,%eax
  cmp    $0x80,%eax
  jne    L47
  mov    -0x8(%rbp),%rax
  add    $0x3,%rax
  movzbl (%rax),%eax
  movsbl %al,%eax
  and    $0xc0,%eax
  cmp    $0x80,%eax
  jne    L47
  mov    -0x8(%rbp),%rax
  add    $0x4,%rax
  movzbl (%rax),%eax
  movsbl %al,%eax
  and    $0xc0,%eax
  cmp    $0x80,%eax
  jne    L47
  mov    $0x5,%eax
  jmp    L213
L47:
  mov    -0x8(%rbp),%rax
  movzbl (%rax),%eax
  movsbl %al,%eax
  and    $0xfe,%eax
  cmp    $0xfc,%eax
  jne    L263
  mov    -0x8(%rbp),%rax
  add    $0x1,%rax
  movzbl (%rax),%eax
  movsbl %al,%eax
  and    $0xc0,%eax
  cmp    $0x80,%eax
  jne    L263
  mov    -0x8(%rbp),%rax
  add    $0x2,%rax
  movzbl (%rax),%eax
  movsbl %al,%eax
  and    $0xc0,%eax
  cmp    $0x80,%eax
  jne    L263
  mov    -0x8(%rbp),%rax
  add    $0x3,%rax
  movzbl (%rax),%eax
  movsbl %al,%eax
  and    $0xc0,%eax
  cmp    $0x80,%eax
  jne    L263
  mov    -0x8(%rbp),%rax
  add    $0x4,%rax
  movzbl (%rax),%eax
  movsbl %al,%eax
  and    $0xc0,%eax
  cmp    $0x80,%eax
  jne    L263
  mov    -0x8(%rbp),%rax
  add    $0x5,%rax
  movzbl (%rax),%eax
  movsbl %al,%eax
  and    $0xc0,%eax
  cmp    $0x80,%eax
  jne    L263
  mov    $0x6,%eax
  jmp    L213
L263:
  mov    $0x1,%eax
L213:
  pop    %rbp
  ret
```

assistant: ```c
__attribute__((visibility("default"))) int fcitx_utf8_char_len(const char *in) {
  if (!(in[0] & 0x80))
    return 1;
  if ((in[0] & 0xe0) == 0xc0 && (((in[1]) & 0xc0) == 0x80))
    return 2;
  if ((in[0] & 0xf0) == 0xe0 && (((in[1]) & 0xc0) == 0x80) && (((in[2]) & 0xc0) == 0x80))
    return 3;
  if ((in[0] & 0xf8) == 0xf0 && (((in[1]) & 0xc0) == 0x80) && (((in[2]) & 0xc0) == 0x80) && (((in[3]) & 0xc0) == 0x80))
    return 4;
  if ((in[0] & 0xfc) == 0xf8 && (((in[1]) & 0xc0) == 0x80) && (((in[2]) & 0xc0) == 0x80) && (((in[3]) & 0xc0) == 0x80) && (((in[4]) & 0xc0) == 0x80))
    return 5;
  if ((in[0] & 0xfe) == 0xfc && (((in[1]) & 0xc0) == 0x80) && (((in[2]) & 0xc0) == 0x80) && (((in[3]) & 0xc0) == 0x80) && (((in[4]) & 0xc0) == 0x80) && (((in[5]) & 0xc0) == 0x80))
    return 6;
  return 1;
}
```