user: 请将以下的汇编代码转换成C语言代码:

```asm
<match>:
  endbr64
  jmp    L347
  cs nopw 0x0(%rax,%rax,1)
L130:
  movzbl 0x1(%rdi),%eax
  cmp    $0x3f,%al
  je     L27
  cmp    $0x2a,%al
  je     L27
  cmp    $0x5c,%dl
  jne    L285
  add    $0x1,%rsi
  nopl   (%rax)
L85:
  mov    %rcx,%rdi
L347:
  movzbl (%rdi),%eax
  lea    0x1(%rdi),%rcx
  test   %al,%al
  je     L247
  cmp    $0x2a,%al
  je     L107
  movzbl (%rsi),%edx
  cmp    $0x3f,%al
  je     L97
  cmp    $0x5c,%al
  je     L130
L109:
  cmp    %al,%dl
  jne    L285
L97:
  add    $0x1,%rsi
  test   %dl,%dl
  jne    L85
L285:
  mov    $0x1,%eax
  ret
  nopl   0x0(%rax,%rax,1)
L201:
  movzbl (%rdx),%eax
  mov    %rsi,%rdi
  lea    0x1(%rdx),%rcx
  test   %al,%al
  je     L200
L278:
  cmp    $0x3f,%al
  je     L259
  cmp    $0x5c,%al
  je     L23
  cmp    $0x2a,%al
  je     L329
L352:
  cmp    %al,(%rdi)
  jne    L28
L29:
  add    $0x1,%rdi
  test   %al,%al
  je     L285
L238:
  mov    %rcx,%rdx
  movzbl (%rdx),%eax
  lea    0x1(%rdx),%rcx
  test   %al,%al
  jne    L278
L200:
  cmpb   $0x0,(%rdi)
  je     L57
L28:
  mov    %rsi,%rdi
  mov    %r8,%rcx
  nop
L329:
  mov    %rdi,%rsi
L107:
  movzbl (%rcx),%eax
  lea    0x1(%rcx),%rdx
  test   %al,%al
  je     L57
L153:
  lea    -0x1(%rdx),%r8
  cmp    $0x3f,%al
  je     L237
  cmp    $0x5c,%al
  je     L333
  cmp    $0x2a,%al
  jne    L134
  jmp    L186
L149:
  cmpb   $0x0,(%rsi)
  je     L285
L134:
  add    $0x1,%rsi
  cmp    %al,-0x1(%rsi)
  jne    L149
  jmp    L201
L27:
  lea    0x2(%rdi),%rcx
  jmp    L109
  nopl   0x0(%rax)
L237:
  cmpb   $0x0,(%rsi)
  je     L285
  add    $0x1,%rsi
L186:
  movzbl (%rdx),%eax
  add    $0x1,%rdx
  test   %al,%al
  jne    L153
L57:
  xor    %eax,%eax
  ret
  nopl   0x0(%rax,%rax,1)
L333:
  movzbl (%rdx),%ecx
  cmp    $0x3f,%cl
  je     L388
  cmp    $0x2a,%cl
  jne    L134
L388:
  lea    0x2(%r8),%rdx
  test   %cl,%cl
  je     L57
  mov    %ecx,%eax
  jmp    L134
  nopl   0x0(%rax)
L23:
  movzbl 0x1(%rdx),%eax
  cmp    $0x3f,%al
  je     L301
  cmp    $0x2a,%al
  je     L301
  cmpb   $0x5c,(%rdi)
  jne    L28
  add    $0x1,%rdi
  jmp    L238
  xchg   %ax,%ax
L259:
  movzbl (%rdi),%eax
  jmp    L29
  nopl   0x0(%rax,%rax,1)
L247:
  movsbl (%rsi),%eax
  ret
L301:
  lea    0x2(%rdx),%rcx
  jmp    L352
```

assistant: ```c
int match(const char *mask, const char *string) {
  const char *m = mask, *s = string;
  char ch;
  const char *bm, *bs;
  while ((ch = *m++) && (ch != '*'))
    switch (ch) {
    case '\\':
      if (*m == '?' || *m == '*')
        ch = *m++;
    default:
      if (*s != ch)
        return 1;
    case '?':
      if (!*s++)
        return 1;
    };
  if (!ch)
    return *s;
got_star:
  bm = m;
  while ((ch = *m++))
    switch (ch) {
    case '?':
      if (!*s++)
        return 1;
    case '*':
      bm = m;
      continue;
    case '\\':
      if (*m == '?' || *m == '*')
        ch = *m++;
    default:
      goto break_while;
    };
break_while:
  if (!ch)
    return 0;
  while (*s++ != ch)
    if (!*s)
      return 1;
  bs = s;
  while ((ch = *m++)) {
    switch (ch) {
    case '*':
      goto got_star;
    case '\\':
      if (*m == '?' || *m == '*')
        ch = *m++;
    default:
      if (*s != ch) {
        m = bm;
        s = bs;
        goto got_star;
      };
    case '?':
      if (!*s++)
        return 1;
    };
  };
  if (*s) {
    m = bm;
    s = bs;
    goto got_star;
  };
  return 0;
}
```