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

```asm
<Tcl_StringMatch>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x20,%rsp
  mov    %rdi,-0x18(%rbp)
  mov    %rsi,-0x20(%rbp)
L206:
  mov    -0x20(%rbp),%rax
  movzbl (%rax),%eax
  test   %al,%al
  jne    L317
  mov    -0x18(%rbp),%rax
  movzbl (%rax),%eax
  test   %al,%al
  jne    L75
  mov    $0x1,%eax
  jmp    L42
L75:
  mov    $0x0,%eax
  jmp    L42
L317:
  mov    -0x18(%rbp),%rax
  movzbl (%rax),%eax
  test   %al,%al
  jne    L55
  mov    -0x20(%rbp),%rax
  movzbl (%rax),%eax
  cmp    $0x2a,%al
  je     L55
  mov    $0x0,%eax
  jmp    L42
L55:
  mov    -0x20(%rbp),%rax
  movzbl (%rax),%eax
  cmp    $0x2a,%al
  jne    L363
  addq   $0x1,-0x20(%rbp)
  mov    -0x20(%rbp),%rax
  movzbl (%rax),%eax
  test   %al,%al
  jne    L152
  mov    $0x1,%eax
  jmp    L42
L152:
  mov    -0x20(%rbp),%rdx
  mov    -0x18(%rbp),%rax
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <Tcl_StringMatch>
  test   %eax,%eax
  je     L3
  mov    $0x1,%eax
  jmp    L42
L3:
  mov    -0x18(%rbp),%rax
  movzbl (%rax),%eax
  test   %al,%al
  jne    L211
  mov    $0x0,%eax
  jmp    L42
L211:
  addq   $0x1,-0x18(%rbp)
  jmp    L152
L363:
  mov    -0x20(%rbp),%rax
  movzbl (%rax),%eax
  cmp    $0x3f,%al
  je     L90
  mov    -0x20(%rbp),%rax
  movzbl (%rax),%eax
  cmp    $0x5b,%al
  jne    L227
  addq   $0x1,-0x20(%rbp)
L106:
  mov    -0x20(%rbp),%rax
  movzbl (%rax),%eax
  cmp    $0x5d,%al
  je     L23
  mov    -0x20(%rbp),%rax
  movzbl (%rax),%eax
  test   %al,%al
  jne    L262
L23:
  mov    $0x0,%eax
  jmp    L42
L262:
  mov    -0x20(%rbp),%rax
  movzbl (%rax),%edx
  mov    -0x18(%rbp),%rax
  movzbl (%rax),%eax
  cmp    %al,%dl
  je     L395
  mov    -0x20(%rbp),%rax
  add    $0x1,%rax
  movzbl (%rax),%eax
  cmp    $0x2d,%al
  jne    L283
  mov    -0x20(%rbp),%rax
  add    $0x2,%rax
  movzbl (%rax),%eax
  mov    %al,-0x1(%rbp)
  cmpb   $0x0,-0x1(%rbp)
  jne    L158
  mov    $0x0,%eax
  jmp    L42
L158:
  mov    -0x20(%rbp),%rax
  movzbl (%rax),%edx
  mov    -0x18(%rbp),%rax
  movzbl (%rax),%eax
  cmp    %al,%dl
  jg     L127
  mov    -0x18(%rbp),%rax
  movzbl (%rax),%eax
  cmp    %al,-0x1(%rbp)
  jge    L129
L127:
  mov    -0x20(%rbp),%rax
  movzbl (%rax),%edx
  mov    -0x18(%rbp),%rax
  movzbl (%rax),%eax
  cmp    %al,%dl
  jl     L72
  mov    -0x18(%rbp),%rax
  movzbl (%rax),%eax
  cmp    %al,-0x1(%rbp)
  jle    L86
L72:
  addq   $0x2,-0x20(%rbp)
L283:
  addq   $0x1,-0x20(%rbp)
  jmp    L106
L395:
  nop
  jmp    L107
L129:
  nop
  jmp    L107
L86:
  nop
  jmp    L107
L400:
  addq   $0x1,-0x20(%rbp)
L107:
  mov    -0x20(%rbp),%rax
  movzbl (%rax),%eax
  cmp    $0x5d,%al
  je     L386
  mov    -0x20(%rbp),%rax
  movzbl (%rax),%eax
  test   %al,%al
  jne    L400
  jmp    L386
L227:
  mov    -0x20(%rbp),%rax
  movzbl (%rax),%eax
  cmp    $0x5c,%al
  jne    L274
  addq   $0x1,-0x20(%rbp)
  mov    -0x20(%rbp),%rax
  movzbl (%rax),%eax
  test   %al,%al
  jne    L274
  mov    $0x0,%eax
  jmp    L42
L274:
  mov    -0x20(%rbp),%rax
  movzbl (%rax),%edx
  mov    -0x18(%rbp),%rax
  movzbl (%rax),%eax
  cmp    %al,%dl
  je     L101
  mov    $0x0,%eax
  jmp    L42
L90:
  nop
  jmp    L255
L386:
  nop
  jmp    L255
L101:
  nop
L255:
  addq   $0x1,-0x20(%rbp)
  addq   $0x1,-0x18(%rbp)
  jmp    L206
L42:
  leave
  ret
```

assistant: ```c
int Tcl_StringMatch(const char *string, const char *pattern) {
  char c2;
  while (1) {
    if (*pattern == 0) {
      if (*string == 0) {
        return 1;
      } else {
        return 0;
      }
    }
    if ((*string == 0) && (*pattern != '*')) {
      return 0;
    }
    if (*pattern == '*') {
      pattern += 1;
      if (*pattern == 0) {
        return 1;
      }
      while (1) {
        if (Tcl_StringMatch(string, pattern)) {
          return 1;
        }
        if (*string == 0) {
          return 0;
        }
        string += 1;
      }
    }
    if (*pattern == '?') {
      goto thisCharOK;
    }
    if (*pattern == '[') {
      pattern += 1;
      while (1) {
        if ((*pattern == ']') || (*pattern == 0)) {
          return 0;
        }
        if (*pattern == *string) {
          break;
        }
        if (pattern[1] == '-') {
          c2 = pattern[2];
          if (c2 == 0) {
            return 0;
          }
          if ((*pattern <= *string) && (c2 >= *string)) {
            break;
          }
          if ((*pattern >= *string) && (c2 <= *string)) {
            break;
          }
          pattern += 2;
        }
        pattern += 1;
      }
      while ((*pattern != ']') && (*pattern != 0)) {
        pattern += 1;
      }
      goto thisCharOK;
    }
    if (*pattern == '\\') {
      pattern += 1;
      if (*pattern == 0) {
        return 0;
      }
    }
    if (*pattern != *string) {
      return 0;
    }
  thisCharOK:
    pattern += 1;
    string += 1;
  }
}
```