user: 这段汇编代码用C语言表示是什么样的?

```asm
<__memchr>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  mov    %rdi,-0x48(%rbp)
  mov    %esi,-0x4c(%rbp)
  mov    %rdx,-0x58(%rbp)
  mov    -0x4c(%rbp),%eax
  mov    %al,-0x31(%rbp)
  mov    -0x48(%rbp),%rax
  mov    %rax,-0x30(%rbp)
  jmp    L91
L206:
  mov    -0x30(%rbp),%rax
  movzbl (%rax),%eax
  cmp    %al,-0x31(%rbp)
  jne    L99
  mov    -0x30(%rbp),%rax
  jmp    L227
L99:
  subq   $0x1,-0x58(%rbp)
  addq   $0x1,-0x30(%rbp)
L91:
  cmpq   $0x0,-0x58(%rbp)
  je     L98
  mov    -0x30(%rbp),%rax
  and    $0x7,%eax
  test   %rax,%rax
  jne    L206
L98:
  mov    -0x30(%rbp),%rax
  mov    %rax,-0x28(%rbp)
  mov    $0xfefefefe,%eax
  mov    %rax,-0x20(%rbp)
  movzbl -0x31(%rbp),%edx
  movzbl -0x31(%rbp),%eax
  shl    $0x8,%eax
  or     %edx,%eax
  cltq
  mov    %rax,-0x18(%rbp)
  mov    -0x18(%rbp),%rax
  shl    $0x10,%rax
  or     %rax,-0x18(%rbp)
  mov    D1(%rip),%rax
  mov    (%rax),%eax
  sar    %eax
  movslq %eax,%rdx
  mov    -0x20(%rbp),%rax
  or     $0x1,%rax
  and    %rdx,%rax
  mov    %rax,-0x20(%rbp)
  jmp    L80
L168:
  mov    -0x28(%rbp),%rax
  lea    0x8(%rax),%rdx
  mov    %rdx,-0x28(%rbp)
  mov    (%rax),%rax
  xor    -0x18(%rbp),%rax
  mov    %rax,-0x10(%rbp)
  mov    -0x10(%rbp),%rdx
  mov    -0x20(%rbp),%rax
  add    %rdx,%rax
  xor    -0x10(%rbp),%rax
  or     -0x20(%rbp),%rax
  cmp    $0xffffffffffffffff,%rax
  je     L74
  mov    -0x28(%rbp),%rax
  sub    $0x8,%rax
  mov    %rax,-0x8(%rbp)
  mov    -0x8(%rbp),%rax
  movzbl (%rax),%eax
  cmp    %al,-0x31(%rbp)
  jne    L47
  mov    -0x8(%rbp),%rax
  jmp    L227
L47:
  mov    -0x8(%rbp),%rax
  add    $0x1,%rax
  movzbl (%rax),%eax
  cmp    %al,-0x31(%rbp)
  jne    L249
  mov    -0x8(%rbp),%rax
  add    $0x1,%rax
  jmp    L227
L249:
  mov    -0x8(%rbp),%rax
  add    $0x2,%rax
  movzbl (%rax),%eax
  cmp    %al,-0x31(%rbp)
  jne    L68
  mov    -0x8(%rbp),%rax
  add    $0x2,%rax
  jmp    L227
L68:
  mov    -0x8(%rbp),%rax
  add    $0x3,%rax
  movzbl (%rax),%eax
  cmp    %al,-0x31(%rbp)
  jne    L125
  mov    -0x8(%rbp),%rax
  add    $0x3,%rax
  jmp    L227
L125:
  mov    -0x8(%rbp),%rax
  add    $0x4,%rax
  movzbl (%rax),%eax
  cmp    %al,-0x31(%rbp)
  jne    L194
  mov    -0x8(%rbp),%rax
  add    $0x4,%rax
  jmp    L227
L194:
  mov    -0x8(%rbp),%rax
  add    $0x5,%rax
  movzbl (%rax),%eax
  cmp    %al,-0x31(%rbp)
  jne    L124
  mov    -0x8(%rbp),%rax
  add    $0x5,%rax
  jmp    L227
L124:
  mov    -0x8(%rbp),%rax
  add    $0x6,%rax
  movzbl (%rax),%eax
  cmp    %al,-0x31(%rbp)
  jne    L82
  mov    -0x8(%rbp),%rax
  add    $0x6,%rax
  jmp    L227
L82:
  mov    -0x8(%rbp),%rax
  add    $0x7,%rax
  movzbl (%rax),%eax
  cmp    %al,-0x31(%rbp)
  jne    L74
  mov    -0x8(%rbp),%rax
  add    $0x7,%rax
  jmp    L227
L74:
  subq   $0x8,-0x58(%rbp)
L80:
  cmpq   $0x7,-0x58(%rbp)
  ja     L168
  mov    -0x28(%rbp),%rax
  mov    %rax,-0x30(%rbp)
  jmp    L109
L13:
  mov    -0x30(%rbp),%rax
  movzbl (%rax),%eax
  cmp    %al,-0x31(%rbp)
  jne    L93
  mov    -0x30(%rbp),%rax
  jmp    L227
L93:
  addq   $0x1,-0x30(%rbp)
L109:
  mov    -0x58(%rbp),%rax
  lea    -0x1(%rax),%rdx
  mov    %rdx,-0x58(%rbp)
  test   %rax,%rax
  jne    L13
  mov    $0x0,%eax
L227:
  pop    %rbp
  ret
```

assistant: ```c
void *__memchr(void const *s, int c_in, size_t n) {
  const unsigned char *char_ptr;
  const unsigned long int *longword_ptr;
  unsigned long int longword, magic_bits, charmask;
  unsigned char c;
  int i;
  c = (unsigned char)c_in;
  for (char_ptr = (const unsigned char *)s; n > 0 && (size_t)char_ptr % sizeof longword != 0; --n, ++char_ptr)
    if (*char_ptr == c)
      return (void *)char_ptr;
  longword_ptr = (const unsigned long int *)char_ptr;
  magic_bits = 0xfefefefe;
  charmask = c | (c << 8);
  charmask |= charmask << 16;
  magic_bits = (ULONG_MAX >> 1) & (magic_bits | 1);
  while (n >= sizeof longword) {
    longword = *longword_ptr++ ^ charmask;
    if ((((longword + magic_bits) ^ ~longword) & ~magic_bits) != 0) {
      const unsigned char *cp = (const unsigned char *)(longword_ptr - 1);
      if (cp[0] == c)
        return (void *)cp;
      if (cp[1] == c)
        return (void *)&cp[1];
      if (cp[2] == c)
        return (void *)&cp[2];
      if (cp[3] == c)
        return (void *)&cp[3];
      if (4 < sizeof longword && cp[4] == c)
        return (void *)&cp[4];
      if (5 < sizeof longword && cp[5] == c)
        return (void *)&cp[5];
      if (6 < sizeof longword && cp[6] == c)
        return (void *)&cp[6];
      if (7 < sizeof longword && cp[7] == c)
        return (void *)&cp[7];
      if (8 < sizeof longword)
        for (i = 8; i < sizeof longword; i++)
          if (cp[i] == c)
            return (void *)&cp[i];
    }
    n -= sizeof longword;
  }
  char_ptr = (const unsigned char *)longword_ptr;
  while (n-- > 0) {
    if (*char_ptr == c)
      return (void *)char_ptr;
    else
      ++char_ptr;
  }
  return 0;
}
```