user: Converte this assembly snippet into its equivalent C code:

```asm
<advance>:
  endbr64
  push   %r14
  lea    D5(%rip),%r14
  push   %r13
  push   %r12
  movslq %edi,%r12
  push   %rbp
  movslq %esi,%rbp
  push   %rbx
  lea    D15(%rip),%rbx
L9:
  movzbl 0x0(%rbp),%eax
  lea    0x1(%rbp),%r13
  cmp    $0xb,%al
  ja     L30
  movzbl %al,%edx
  movslq (%rbx,%rdx,4),%rdx
  add    %rbx,%rdx
  notrack jmp *%rdx
  nopl   (%rax)
  mov    %r12,%rbx
  jmp    L183
  nopl   (%rax)
L160:
  movzbl 0x0(%rbp),%eax
L183:
  add    $0x1,%rbx
  xor    %edx,%edx
  movsbl -0x1(%rbx),%esi
  cmp    $0x7,%al
  sete   %dl
  mov    %r13,%rdi
  xor    %eax,%eax
  call   <cclass@plt>
  test   %eax,%eax
  jne    L160
  movsbq 0x1(%rbp),%r13
  xchg   %ax,%ax
L146:
  sub    $0x1,%rbx
  xor    %eax,%eax
  mov    %r13,%rsi
  mov    %rbx,%rdi
  call   <advance>
  test   %eax,%eax
  jne    L58
  cmp    %rbx,%r12
  jb     L146
L138:
  pop    %rbx
  xor    %eax,%eax
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  ret
  nopl   (%rax)
L58:
  pop    %rbx
  mov    $0x1,%eax
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  ret
  cs nopw 0x0(%rax,%rax,1)
  movzbl (%r12),%eax
  cmp    %al,0x1(%rbp)
  jne    L138
  add    $0x2,%rbp
  add    $0x1,%r12
  jmp    L9
  nopw   0x0(%rax,%rax,1)
  movzbl 0x1(%rbp),%eax
  mov    %r12,%rbx
  nopw   0x0(%rax,%rax,1)
L33:
  add    $0x1,%rbx
  cmp    %al,-0x1(%rbx)
  je     L33
  lea    0x2(%rbp),%r13
  jmp    L146
  nop
  cmpb   $0x0,(%r12)
  je     L138
  add    $0x1,%r12
  mov    %r13,%rbp
  jmp    L9
  nopl   0x0(%rax,%rax,1)
  mov    %r12,%rbx
  nopl   0x0(%rax,%rax,1)
L184:
  add    $0x1,%rbx
  cmpb   $0x0,-0x1(%rbx)
  jne    L184
  jmp    L146
  nop
  movsbl (%r12),%esi
  xor    %edx,%edx
L56:
  xor    %eax,%eax
  mov    %r13,%rdi
  call   <cclass@plt>
  test   %eax,%eax
  je     L138
  movsbq 0x1(%rbp),%rbp
  add    $0x1,%r12
  jmp    L9
  nopw   0x0(%rax,%rax,1)
  cmpb   $0x0,(%r12)
  jne    L138
  mov    %r13,%rbp
  jmp    L9
  nopl   0x0(%rax,%rax,1)
  movsbl (%r12),%esi
  mov    $0x1,%edx
  jmp    L56
L30:
  mov    %r14,%rdi
  xor    %eax,%eax
  mov    %r13,%rbp
  call   <printf2@plt>
  jmp    L9
```

tool_calls: name: extract_symbolic_data
arguments: data_tag: D5
data_type: string

tool: D5: RE botch


assistant: ```c
advance(alp, aep) {
  register char *lp, *ep, *curlp;
  char *nextep;
  lp = alp;
  ep = aep;
  for (;;)
    switch (*ep++) {
    case 2:
      if (*ep++ == *lp++)
        continue;
      return (0);
    case 4:
      if (*lp++)
        continue;
      return (0);
    case 10:
      if (*lp == 0)
        continue;
      return (0);
    case 11:
      return (1);
    case 6:
      if (cclass(ep, *lp++, 1)) {
        ep = +*ep;
        continue;
      }
      return (0);
    case 8:
      if (cclass(ep, *lp++, 0)) {
        ep = +*ep;
        continue;
      }
      return (0);
    case 4 | 01:
      curlp = lp;
      while (*lp++)
        ;
      goto star;
    case 2 | 01:
      curlp = lp;
      while (*lp++ == *ep)
        ;
      ep++;
      goto star;
    case 6 | 01:
    case 8 | 01:
      curlp = lp;
      while (cclass(ep, *lp++, ep[-1] == (6 | 01)))
        ;
      ep = +*ep;
      goto star;
    star:
      do {
        lp--;
        if (advance(lp, ep))
          return (1);
      } while (lp > curlp);
      return (0);
    default:
      printf2("RE botch\n");
    }
}
```