user: 请将这段汇编代码片段转换成等效的C代码:

```asm
<asterisk>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x20,%rsp
  mov    %rdi,-0x18(%rbp)
  mov    %rsi,-0x20(%rbp)
  movl   $0x1,-0x4(%rbp)
  mov    -0x18(%rbp),%rax
  mov    (%rax),%rax
  lea    0x1(%rax),%rdx
  mov    -0x18(%rbp),%rax
  mov    %rdx,(%rax)
  jmp    L182
L205:
  mov    -0x18(%rbp),%rax
  mov    (%rax),%rax
  movzbl (%rax),%eax
  cmp    $0x3f,%al
  jne    L114
  mov    -0x20(%rbp),%rax
  mov    (%rax),%rax
  lea    0x1(%rax),%rdx
  mov    -0x20(%rbp),%rax
  mov    %rdx,(%rax)
L114:
  mov    -0x18(%rbp),%rax
  mov    (%rax),%rax
  lea    0x1(%rax),%rdx
  mov    -0x18(%rbp),%rax
  mov    %rdx,(%rax)
L182:
  mov    -0x20(%rbp),%rax
  mov    (%rax),%rax
  movzbl (%rax),%eax
  test   %al,%al
  je     L58
  mov    -0x18(%rbp),%rax
  mov    (%rax),%rax
  movzbl (%rax),%eax
  cmp    $0x3f,%al
  je     L205
  mov    -0x18(%rbp),%rax
  mov    (%rax),%rax
  movzbl (%rax),%eax
  cmp    $0x2a,%al
  je     L205
  jmp    L58
L228:
  mov    -0x18(%rbp),%rax
  mov    (%rax),%rax
  lea    0x1(%rax),%rdx
  mov    -0x18(%rbp),%rax
  mov    %rdx,(%rax)
L58:
  mov    -0x18(%rbp),%rax
  mov    (%rax),%rax
  movzbl (%rax),%eax
  cmp    $0x2a,%al
  je     L228
  mov    -0x20(%rbp),%rax
  mov    (%rax),%rax
  movzbl (%rax),%eax
  test   %al,%al
  jne    L141
  mov    -0x18(%rbp),%rax
  mov    (%rax),%rax
  movzbl (%rax),%eax
  test   %al,%al
  je     L141
  movl   $0x0,-0x4(%rbp)
  mov    -0x4(%rbp),%eax
  jmp    L38
L141:
  mov    -0x20(%rbp),%rax
  mov    (%rax),%rax
  movzbl (%rax),%eax
  test   %al,%al
  jne    L65
  mov    -0x18(%rbp),%rax
  mov    (%rax),%rax
  movzbl (%rax),%eax
  test   %al,%al
  jne    L65
  movl   $0x1,-0x4(%rbp)
  mov    -0x4(%rbp),%eax
  jmp    L38
L65:
  mov    -0x20(%rbp),%rax
  mov    (%rax),%rdx
  mov    -0x18(%rbp),%rax
  mov    (%rax),%rax
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <wildcardfit@plt>
  test   %rax,%rax
  jne    L18
L84:
  mov    -0x20(%rbp),%rax
  mov    (%rax),%rax
  lea    0x1(%rax),%rdx
  mov    -0x20(%rbp),%rax
  mov    %rdx,(%rax)
  jmp    L21
L62:
  mov    -0x20(%rbp),%rax
  mov    (%rax),%rax
  lea    0x1(%rax),%rdx
  mov    -0x20(%rbp),%rax
  mov    %rdx,(%rax)
L21:
  mov    -0x18(%rbp),%rax
  mov    (%rax),%rax
  movzbl (%rax),%edx
  mov    -0x20(%rbp),%rax
  mov    (%rax),%rax
  movzbl (%rax),%eax
  cmp    %al,%dl
  je     L133
  mov    -0x18(%rbp),%rax
  mov    (%rax),%rax
  movzbl (%rax),%eax
  cmp    $0x5b,%al
  je     L133
  mov    -0x20(%rbp),%rax
  mov    (%rax),%rax
  movzbl (%rax),%eax
  test   %al,%al
  jne    L62
L133:
  mov    -0x20(%rbp),%rax
  mov    (%rax),%rax
  movzbl (%rax),%eax
  test   %al,%al
  je     L71
  mov    -0x20(%rbp),%rax
  mov    (%rax),%rdx
  mov    -0x18(%rbp),%rax
  mov    (%rax),%rax
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <wildcardfit@plt>
  test   %rax,%rax
  sete   %al
  jmp    L136
L71:
  movl   $0x0,-0x4(%rbp)
  cmpl   $0x0,-0x4(%rbp)
  setne  %al
L136:
  test   %al,%al
  jne    L84
L18:
  mov    -0x20(%rbp),%rax
  mov    (%rax),%rax
  movzbl (%rax),%eax
  test   %al,%al
  jne    L157
  mov    -0x18(%rbp),%rax
  mov    (%rax),%rax
  movzbl (%rax),%eax
  test   %al,%al
  jne    L157
  movl   $0x1,-0x4(%rbp)
L157:
  mov    -0x4(%rbp),%eax
L38:
  leave
  ret
```

assistant: ```c
int asterisk(char **wildcard, char **test) {
  int fit = 1;
  (*wildcard)++;
  while (('\000' != (**test)) && (('?' == **wildcard) || ('*' == **wildcard))) {
    if ('?' == **wildcard)
      (*test)++;
    (*wildcard)++;
  }
  while ('*' == (**wildcard))
    (*wildcard)++;
  if (('\0' == (**test)) && ('\0' != (**wildcard)))
    return (fit = 0);
  if (('\0' == (**test)) && ('\0' == (**wildcard)))
    return (fit = 1);
  else {
    if (0 == wildcardfit(*wildcard, (*test))) {
      do {
        (*test)++;
        while (((**wildcard) != (**test)) && ('[' != (**wildcard)) && ('\0' != (**test)))
          (*test)++;
      } while ((('\0' != **test)) ? (0 == wildcardfit(*wildcard, (*test))) : (0 != (fit = 0)));
    }
    if (('\0' == **test) && ('\0' == **wildcard))
      fit = 1;
    return (fit);
  }
}
```