user: 请从给定的汇编指令推导出C源代码:

```asm
<mime_to_ext>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x10,%rsp
  mov    %rdi,-0x8(%rbp)
  mov    %rsi,-0x10(%rbp)
  mov    -0x8(%rbp),%rax
  movzbl (%rax),%eax
  movsbl %al,%eax
  cmp    $0x76,%eax
  je     L462
  cmp    $0x76,%eax
  jg     L463
  cmp    $0x61,%eax
  je     L163
  cmp    $0x69,%eax
  je     L502
  jmp    L463
L163:
  mov    -0x8(%rbp),%rax
  add    $0x6,%rax
  lea    D46(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcmp@plt>
  test   %eax,%eax
  jne    L198
  mov    -0x10(%rbp),%rax
  lea    D238(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  jmp    L340
L198:
  mov    -0x8(%rbp),%rax
  add    $0x6,%rax
  lea    D130(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcmp@plt>
  test   %eax,%eax
  jne    L317
  mov    -0x10(%rbp),%rax
  lea    D52(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  jmp    L340
L317:
  mov    -0x8(%rbp),%rax
  add    $0x6,%rax
  lea    D191(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcmp@plt>
  test   %eax,%eax
  jne    L383
  mov    -0x10(%rbp),%rax
  lea    D338(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  jmp    L340
L383:
  mov    -0x8(%rbp),%rax
  add    $0x6,%rax
  lea    D232(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcmp@plt>
  test   %eax,%eax
  jne    L497
  mov    -0x10(%rbp),%rax
  lea    D182(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  jmp    L340
L497:
  mov    -0x8(%rbp),%rax
  add    $0x6,%rax
  lea    D182(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcmp@plt>
  test   %eax,%eax
  jne    L89
  mov    -0x10(%rbp),%rax
  lea    D182(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  jmp    L340
L89:
  mov    -0x8(%rbp),%rax
  add    $0x6,%rax
  lea    D300(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcmp@plt>
  test   %eax,%eax
  jne    L90
  mov    -0x10(%rbp),%rax
  lea    D22(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  jmp    L340
L90:
  mov    -0x8(%rbp),%rax
  add    $0x6,%rax
  mov    $0x3,%edx
  lea    D176(%rip),%rcx
  mov    %rcx,%rsi
  mov    %rax,%rdi
  call   <strncmp@plt>
  test   %eax,%eax
  jne    L283
  mov    -0x10(%rbp),%rax
  lea    D178(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  jmp    L340
L283:
  mov    -0x8(%rbp),%rax
  add    $0x6,%rax
  lea    D124(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcmp@plt>
  test   %eax,%eax
  jne    L441
  mov    -0x10(%rbp),%rax
  lea    D425(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  jmp    L340
L441:
  mov    -0x8(%rbp),%rax
  lea    D327(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcmp@plt>
  test   %eax,%eax
  jne    L513
  mov    -0x10(%rbp),%rax
  lea    D341(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  jmp    L340
L513:
  mov    -0x10(%rbp),%rax
  lea    D329(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  jmp    L340
L462:
  mov    -0x8(%rbp),%rax
  add    $0x6,%rax
  lea    D234(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcmp@plt>
  test   %eax,%eax
  jne    L5
  mov    -0x10(%rbp),%rax
  lea    D234(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  jmp    L340
L5:
  mov    -0x8(%rbp),%rax
  add    $0x6,%rax
  lea    D0(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcmp@plt>
  test   %eax,%eax
  jne    L299
  mov    -0x10(%rbp),%rax
  lea    D234(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  jmp    L340
L299:
  mov    -0x8(%rbp),%rax
  add    $0x6,%rax
  lea    D4(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcmp@plt>
  test   %eax,%eax
  jne    L187
  mov    -0x10(%rbp),%rax
  lea    D234(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  jmp    L340
L187:
  mov    -0x8(%rbp),%rax
  add    $0x6,%rax
  lea    D46(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcmp@plt>
  test   %eax,%eax
  jne    L30
  mov    -0x10(%rbp),%rax
  lea    D434(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  jmp    L340
L30:
  mov    -0x8(%rbp),%rax
  add    $0x6,%rax
  lea    D130(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcmp@plt>
  test   %eax,%eax
  jne    L367
  mov    -0x10(%rbp),%rax
  lea    D130(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  jmp    L340
L367:
  mov    -0x8(%rbp),%rax
  add    $0x6,%rax
  lea    D483(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcmp@plt>
  test   %eax,%eax
  jne    L24
  mov    -0x10(%rbp),%rax
  lea    D259(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  jmp    L340
L24:
  mov    -0x8(%rbp),%rax
  add    $0x6,%rax
  lea    D517(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcmp@plt>
  test   %eax,%eax
  jne    L477
  mov    -0x10(%rbp),%rax
  lea    D57(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  jmp    L340
L477:
  mov    -0x8(%rbp),%rax
  add    $0x6,%rax
  lea    D432(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcmp@plt>
  test   %eax,%eax
  jne    L51
  mov    -0x10(%rbp),%rax
  lea    D57(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  jmp    L340
L51:
  mov    -0x8(%rbp),%rax
  add    $0x6,%rax
  lea    D174(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcmp@plt>
  test   %eax,%eax
  jne    L486
  mov    -0x10(%rbp),%rax
  lea    D73(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  jmp    L340
L486:
  mov    -0x8(%rbp),%rax
  add    $0x6,%rax
  lea    D19(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcmp@plt>
  test   %eax,%eax
  jne    L91
  mov    -0x10(%rbp),%rax
  lea    D434(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  jmp    L340
L91:
  mov    -0x8(%rbp),%rax
  add    $0x6,%rax
  lea    D108(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcmp@plt>
  test   %eax,%eax
  jne    L552
  mov    -0x10(%rbp),%rax
  lea    D261(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  jmp    L340
L552:
  mov    -0x8(%rbp),%rax
  add    $0x6,%rax
  lea    D124(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcmp@plt>
  test   %eax,%eax
  jne    L185
  mov    -0x10(%rbp),%rax
  lea    D425(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  jmp    L340
L185:
  mov    -0x8(%rbp),%rax
  add    $0x6,%rax
  lea    D284(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcmp@plt>
  test   %eax,%eax
  jne    L204
  mov    -0x10(%rbp),%rax
  lea    D206(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  jmp    L340
L204:
  mov    -0x10(%rbp),%rax
  lea    D329(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  jmp    L340
L502:
  mov    -0x8(%rbp),%rax
  add    $0x6,%rax
  lea    D358(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcmp@plt>
  test   %eax,%eax
  jne    L140
  mov    -0x10(%rbp),%rax
  lea    D5(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  jmp    L340
L140:
  mov    -0x8(%rbp),%rax
  add    $0x6,%rax
  lea    D512(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcmp@plt>
  test   %eax,%eax
  jne    L438
  mov    -0x10(%rbp),%rax
  lea    D512(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  jmp    L340
L438:
  mov    -0x10(%rbp),%rax
  lea    D329(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  jmp    L340
L463:
  mov    -0x10(%rbp),%rax
  lea    D329(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  nop
L340:
  nop
  leave
  ret
```

tool_calls: name: disassemble_data
arguments: tag: D46
type: string
name: disassemble_data
arguments: tag: D238
type: string
name: disassemble_data
arguments: tag: D130
type: string
name: disassemble_data
arguments: tag: D52
type: string
name: disassemble_data
arguments: tag: D191
type: string
name: disassemble_data
arguments: tag: D338
type: string
name: disassemble_data
arguments: tag: D232
type: string
name: disassemble_data
arguments: tag: D182
type: string
name: disassemble_data
arguments: tag: D300
type: string
name: disassemble_data
arguments: tag: D22
type: string
name: disassemble_data
arguments: tag: D176
type: string
name: disassemble_data
arguments: tag: D178
type: string
name: disassemble_data
arguments: tag: D124
type: string
name: disassemble_data
arguments: tag: D425
type: string
name: disassemble_data
arguments: tag: D327
type: string
name: disassemble_data
arguments: tag: D341
type: string
name: disassemble_data
arguments: tag: D329
type: string
name: disassemble_data
arguments: tag: D234
type: string
name: disassemble_data
arguments: tag: D0
type: string
name: disassemble_data
arguments: tag: D4
type: string
name: disassemble_data
arguments: tag: D434
type: string
name: disassemble_data
arguments: tag: D483
type: string
name: disassemble_data
arguments: tag: D259
type: string
name: disassemble_data
arguments: tag: D517
type: string
name: disassemble_data
arguments: tag: D57
type: string
name: disassemble_data
arguments: tag: D432
type: string
name: disassemble_data
arguments: tag: D174
type: string
name: disassemble_data
arguments: tag: D73
type: string
name: disassemble_data
arguments: tag: D19
type: string
name: disassemble_data
arguments: tag: D108
type: string
name: disassemble_data
arguments: tag: D261
type: string
name: disassemble_data
arguments: tag: D284
type: string
name: disassemble_data
arguments: tag: D206
type: string
name: disassemble_data
arguments: tag: D358
type: string
name: disassemble_data
arguments: tag: D5
type: string
name: disassemble_data
arguments: tag: D512
type: string

tool: D46: mpeg

tool: D238: mp3

tool: D130: mp4

tool: D52: m4a

tool: D191: x-ms-wma

tool: D338: wma

tool: D232: x-flac

tool: D182: flac

tool: D300: x-wav

tool: D22: wav

tool: D176: L16

tool: D178: pcm

tool: D124: 3gpp

tool: D425: 3gp

tool: D327: application/ogg

tool: D341: ogg

tool: D329: dat

tool: D234: avi

tool: D0: divx

tool: D4: x-msvideo

tool: D434: mpg

tool: D483: x-ms-wmv

tool: D259: wmv

tool: D517: x-matroska

tool: D57: mkv

tool: D432: x-mkv

tool: D174: x-flv

tool: D73: flv

tool: D19: vnd.dlna.mpeg-tts

tool: D108: quicktime

tool: D261: mov

tool: D284: x-tivo-mpeg

tool: D206: TiVo

tool: D358: jpeg

tool: D5: jpg

tool: D512: png

assistant: ```c
void mime_to_ext(const char *mime, char *buf) {
  switch (*mime) {
  case 'a':
    if (strcmp(mime + 6, "mpeg") == 0)
      strcpy(buf, "mp3");
    else if (strcmp(mime + 6, "mp4") == 0)
      strcpy(buf, "m4a");
    else if (strcmp(mime + 6, "x-ms-wma") == 0)
      strcpy(buf, "wma");
    else if (strcmp(mime + 6, "x-flac") == 0)
      strcpy(buf, "flac");
    else if (strcmp(mime + 6, "flac") == 0)
      strcpy(buf, "flac");
    else if (strcmp(mime + 6, "x-wav") == 0)
      strcpy(buf, "wav");
    else if (strncmp(mime + 6, "L16", 3) == 0)
      strcpy(buf, "pcm");
    else if (strcmp(mime + 6, "3gpp") == 0)
      strcpy(buf, "3gp");
    else if (strcmp(mime, "application/ogg") == 0)
      strcpy(buf, "ogg");
    else
      strcpy(buf, "dat");
    break;
  case 'v':
    if (strcmp(mime + 6, "avi") == 0)
      strcpy(buf, "avi");
    else if (strcmp(mime + 6, "divx") == 0)
      strcpy(buf, "avi");
    else if (strcmp(mime + 6, "x-msvideo") == 0)
      strcpy(buf, "avi");
    else if (strcmp(mime + 6, "mpeg") == 0)
      strcpy(buf, "mpg");
    else if (strcmp(mime + 6, "mp4") == 0)
      strcpy(buf, "mp4");
    else if (strcmp(mime + 6, "x-ms-wmv") == 0)
      strcpy(buf, "wmv");
    else if (strcmp(mime + 6, "x-matroska") == 0)
      strcpy(buf, "mkv");
    else if (strcmp(mime + 6, "x-mkv") == 0)
      strcpy(buf, "mkv");
    else if (strcmp(mime + 6, "x-flv") == 0)
      strcpy(buf, "flv");
    else if (strcmp(mime + 6, "vnd.dlna.mpeg-tts") == 0)
      strcpy(buf, "mpg");
    else if (strcmp(mime + 6, "quicktime") == 0)
      strcpy(buf, "mov");
    else if (strcmp(mime + 6, "3gpp") == 0)
      strcpy(buf, "3gp");
    else if (strcmp(mime + 6, "x-tivo-mpeg") == 0)
      strcpy(buf, "TiVo");
    else
      strcpy(buf, "dat");
    break;
  case 'i':
    if (strcmp(mime + 6, "jpeg") == 0)
      strcpy(buf, "jpg");
    else if (strcmp(mime + 6, "png") == 0)
      strcpy(buf, "png");
    else
      strcpy(buf, "dat");
    break;
  default:
    strcpy(buf, "dat");
    break;
  }
}
```