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

```asm
<string_match_len>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  push   %rbx
  sub    $0x48,%rsp
  mov    %rdi,-0x38(%rbp)
  mov    %esi,-0x3c(%rbp)
  mov    %rdx,-0x48(%rbp)
  mov    %ecx,-0x40(%rbp)
  mov    %r8d,-0x4c(%rbp)
  jmp    L515
L7:
  mov    -0x38(%rbp),%rax
  movzbl (%rax),%eax
  movsbl %al,%eax
  cmp    $0x5c,%eax
  je     L426
  cmp    $0x5c,%eax
  jg     L417
  cmp    $0x5b,%eax
  je     L332
  cmp    $0x5b,%eax
  jg     L417
  cmp    $0x2a,%eax
  je     L63
  cmp    $0x3f,%eax
  je     L136
  jmp    L417
L222:
  addq   $0x1,-0x38(%rbp)
  subl   $0x1,-0x3c(%rbp)
L63:
  mov    -0x38(%rbp),%rax
  add    $0x1,%rax
  movzbl (%rax),%eax
  cmp    $0x2a,%al
  je     L222
  cmpl   $0x1,-0x3c(%rbp)
  jne    L375
  mov    $0x1,%eax
  jmp    L281
L313:
  mov    -0x3c(%rbp),%eax
  lea    -0x1(%rax),%esi
  mov    -0x38(%rbp),%rax
  lea    0x1(%rax),%rdi
  mov    -0x4c(%rbp),%ecx
  mov    -0x40(%rbp),%edx
  mov    -0x48(%rbp),%rax
  mov    %ecx,%r8d
  mov    %edx,%ecx
  mov    %rax,%rdx
  call   <string_match_len>
  test   %eax,%eax
  je     L270
  mov    $0x1,%eax
  jmp    L281
L270:
  addq   $0x1,-0x48(%rbp)
  subl   $0x1,-0x40(%rbp)
L375:
  cmpl   $0x0,-0x40(%rbp)
  jne    L313
  mov    $0x0,%eax
  jmp    L281
L136:
  cmpl   $0x0,-0x40(%rbp)
  jne    L181
  mov    $0x0,%eax
  jmp    L281
L181:
  addq   $0x1,-0x48(%rbp)
  subl   $0x1,-0x40(%rbp)
  jmp    L162
L332:
  addq   $0x1,-0x38(%rbp)
  subl   $0x1,-0x3c(%rbp)
  mov    -0x38(%rbp),%rax
  movzbl (%rax),%eax
  cmp    $0x5e,%al
  sete   %al
  movzbl %al,%eax
  mov    %eax,-0x18(%rbp)
  cmpl   $0x0,-0x18(%rbp)
  je     L91
  addq   $0x1,-0x38(%rbp)
  subl   $0x1,-0x3c(%rbp)
L91:
  movl   $0x0,-0x28(%rbp)
L476:
  mov    -0x38(%rbp),%rax
  movzbl (%rax),%eax
  cmp    $0x5c,%al
  jne    L310
  addq   $0x1,-0x38(%rbp)
  subl   $0x1,-0x3c(%rbp)
  mov    -0x38(%rbp),%rax
  movzbl (%rax),%edx
  mov    -0x48(%rbp),%rax
  movzbl (%rax),%eax
  cmp    %al,%dl
  jne    L288
  movl   $0x1,-0x28(%rbp)
  jmp    L288
L310:
  mov    -0x38(%rbp),%rax
  movzbl (%rax),%eax
  cmp    $0x5d,%al
  je     L275
  cmpl   $0x0,-0x3c(%rbp)
  jne    L249
  subq   $0x1,-0x38(%rbp)
  addl   $0x1,-0x3c(%rbp)
  jmp    L28
L249:
  mov    -0x38(%rbp),%rax
  add    $0x1,%rax
  movzbl (%rax),%eax
  cmp    $0x2d,%al
  jne    L334
  cmpl   $0x2,-0x3c(%rbp)
  jle    L334
  mov    -0x38(%rbp),%rax
  movzbl (%rax),%eax
  movsbl %al,%eax
  mov    %eax,-0x24(%rbp)
  mov    -0x38(%rbp),%rax
  add    $0x2,%rax
  movzbl (%rax),%eax
  movsbl %al,%eax
  mov    %eax,-0x20(%rbp)
  mov    -0x48(%rbp),%rax
  movzbl (%rax),%eax
  movsbl %al,%eax
  mov    %eax,-0x1c(%rbp)
  mov    -0x24(%rbp),%eax
  cmp    -0x20(%rbp),%eax
  jle    L122
  mov    -0x24(%rbp),%eax
  mov    %eax,-0x14(%rbp)
  mov    -0x20(%rbp),%eax
  mov    %eax,-0x24(%rbp)
  mov    -0x14(%rbp),%eax
  mov    %eax,-0x20(%rbp)
L122:
  cmpl   $0x0,-0x4c(%rbp)
  je     L510
  mov    -0x24(%rbp),%eax
  mov    %eax,%edi
  call   <tolower@plt>
  mov    %eax,-0x24(%rbp)
  mov    -0x20(%rbp),%eax
  mov    %eax,%edi
  call   <tolower@plt>
  mov    %eax,-0x20(%rbp)
  mov    -0x1c(%rbp),%eax
  mov    %eax,%edi
  call   <tolower@plt>
  mov    %eax,-0x1c(%rbp)
L510:
  addq   $0x2,-0x38(%rbp)
  subl   $0x2,-0x3c(%rbp)
  mov    -0x1c(%rbp),%eax
  cmp    -0x24(%rbp),%eax
  jl     L182
  mov    -0x1c(%rbp),%eax
  cmp    -0x20(%rbp),%eax
  jg     L182
  movl   $0x1,-0x28(%rbp)
  jmp    L182
L334:
  cmpl   $0x0,-0x4c(%rbp)
  jne    L159
  mov    -0x38(%rbp),%rax
  movzbl (%rax),%edx
  mov    -0x48(%rbp),%rax
  movzbl (%rax),%eax
  cmp    %al,%dl
  jne    L288
  movl   $0x1,-0x28(%rbp)
  jmp    L288
L159:
  mov    -0x38(%rbp),%rax
  movzbl (%rax),%eax
  movsbl %al,%eax
  mov    %eax,%edi
  call   <tolower@plt>
  mov    %eax,%ebx
  mov    -0x48(%rbp),%rax
  movzbl (%rax),%eax
  movsbl %al,%eax
  mov    %eax,%edi
  call   <tolower@plt>
  cmp    %eax,%ebx
  jne    L288
  movl   $0x1,-0x28(%rbp)
  jmp    L288
L182:
  nop
L288:
  addq   $0x1,-0x38(%rbp)
  subl   $0x1,-0x3c(%rbp)
  jmp    L476
L275:
  nop
L28:
  cmpl   $0x0,-0x18(%rbp)
  je     L537
  cmpl   $0x0,-0x28(%rbp)
  sete   %al
  movzbl %al,%eax
  mov    %eax,-0x28(%rbp)
L537:
  cmpl   $0x0,-0x28(%rbp)
  jne    L145
  mov    $0x0,%eax
  jmp    L281
L145:
  addq   $0x1,-0x48(%rbp)
  subl   $0x1,-0x40(%rbp)
  jmp    L162
L426:
  cmpl   $0x1,-0x3c(%rbp)
  jle    L417
  addq   $0x1,-0x38(%rbp)
  subl   $0x1,-0x3c(%rbp)
L417:
  cmpl   $0x0,-0x4c(%rbp)
  jne    L8
  mov    -0x38(%rbp),%rax
  movzbl (%rax),%edx
  mov    -0x48(%rbp),%rax
  movzbl (%rax),%eax
  cmp    %al,%dl
  je     L157
  mov    $0x0,%eax
  jmp    L281
L8:
  mov    -0x38(%rbp),%rax
  movzbl (%rax),%eax
  movsbl %al,%eax
  mov    %eax,%edi
  call   <tolower@plt>
  mov    %eax,%ebx
  mov    -0x48(%rbp),%rax
  movzbl (%rax),%eax
  movsbl %al,%eax
  mov    %eax,%edi
  call   <tolower@plt>
  cmp    %eax,%ebx
  je     L157
  mov    $0x0,%eax
  jmp    L281
L157:
  addq   $0x1,-0x48(%rbp)
  subl   $0x1,-0x40(%rbp)
  nop
L162:
  addq   $0x1,-0x38(%rbp)
  subl   $0x1,-0x3c(%rbp)
  cmpl   $0x0,-0x40(%rbp)
  jne    L515
  jmp    L20
L320:
  addq   $0x1,-0x38(%rbp)
  subl   $0x1,-0x3c(%rbp)
L20:
  mov    -0x38(%rbp),%rax
  movzbl (%rax),%eax
  cmp    $0x2a,%al
  je     L320
  jmp    L266
L515:
  cmpl   $0x0,-0x3c(%rbp)
  jne    L7
L266:
  cmpl   $0x0,-0x3c(%rbp)
  jne    L88
  cmpl   $0x0,-0x40(%rbp)
  jne    L88
  mov    $0x1,%eax
  jmp    L281
L88:
  mov    $0x0,%eax
L281:
  mov    -0x8(%rbp),%rbx
  leave
  ret
```

assistant: ```c
int string_match_len(const char *pattern, int patternLen, const char *string, int stringLen, int nocase) {
  while (patternLen) {
    switch (pattern[0]) {
    case '*':
      while (pattern[1] == '*') {
        pattern++;
        patternLen--;
      }
      if (patternLen == 1)
        return 1;
      while (stringLen) {
        if (string_match_len(pattern + 1, patternLen - 1, string, stringLen, nocase))
          return 1;
        string++;
        stringLen--;
      }
      return 0;
      break;
    case '?':
      if (stringLen == 0)
        return 0;
      string++;
      stringLen--;
      break;
    case '[': {
      int not, match;
      pattern++;
      patternLen--;
      not = pattern[0] == '^';
      if (not ) {
        pattern++;
        patternLen--;
      }
      match = 0;
      while (1) {
        if (pattern[0] == '\\') {
          pattern++;
          patternLen--;
          if (pattern[0] == string[0])
            match = 1;
        } else if (pattern[0] == ']') {
          break;
        } else if (patternLen == 0) {
          pattern--;
          patternLen++;
          break;
        } else if (pattern[1] == '-' && patternLen >= 3) {
          int start = pattern[0];
          int end = pattern[2];
          int c = string[0];
          if (start > end) {
            int t = start;
            start = end;
            end = t;
          }
          if (nocase) {
            start = tolower(start);
            end = tolower(end);
            c = tolower(c);
          }
          pattern += 2;
          patternLen -= 2;
          if (c >= start && c <= end)
            match = 1;
        } else {
          if (!nocase) {
            if (pattern[0] == string[0])
              match = 1;
          } else {
            if (tolower((int)pattern[0]) == tolower((int)string[0]))
              match = 1;
          }
        }
        pattern++;
        patternLen--;
      }
      if (not )
        match = !match;
      if (!match)
        return 0;
      string++;
      stringLen--;
      break;
    }
    case '\\':
      if (patternLen >= 2) {
        pattern++;
        patternLen--;
      }
    default:
      if (!nocase) {
        if (pattern[0] != string[0])
          return 0;
      } else {
        if (tolower((int)pattern[0]) != tolower((int)string[0]))
          return 0;
      }
      string++;
      stringLen--;
      break;
    }
    pattern++;
    patternLen--;
    if (stringLen == 0) {
      while (*pattern == '*') {
        pattern++;
        patternLen--;
      }
      break;
    }
  }
  if (patternLen == 0 && stringLen == 0)
    return 1;
  return 0;
}
```