user: Translate the below assembly code into C programming language:

```asm
<parse_server_input>:
  endbr64
  push   %r12
  lea    D122(%rip),%r12
  push   %rbp
  mov    %r12,%rsi
  push   %rbx
  call   <strtok@plt>
  xor    %edi,%edi
  mov    %r12,%rsi
  mov    %rax,%rbp
  call   <strtok@plt>
  test   %rbp,%rbp
  je     L319
  mov    %rax,%rbx
  test   %rax,%rax
  je     L311
  lea    D137(%rip),%rsi
  xor    %edi,%edi
  call   <strtok@plt>
  mov    %rbp,%rdi
  mov    %rax,%r12
  call   <atoi@plt>
  lea    D108(%rip),%rsi
  mov    %rbx,%rdi
  mov    %eax,%ebp
  call   <strcmp@plt>
  test   %rax,%rax
  je     L84
  lea    D112(%rip),%rsi
  mov    %rbx,%rdi
  call   <strcmp@plt>
  test   %rax,%rax
  jne    L161
  mov    %r12,%rsi
  mov    %ebp,%edi
  call   <server_msg@plt>
  xor    %eax,%eax
L37:
  pop    %rbx
  pop    %rbp
  pop    %r12
  ret
  nopl   (%rax)
L84:
  mov    %r12,%rsi
  mov    %ebp,%edi
  call   <server_hello@plt>
  pop    %rbx
  xor    %eax,%eax
  pop    %rbp
  pop    %r12
  ret
  nopl   0x0(%rax)
L161:
  lea    D107(%rip),%rsi
  mov    %rbx,%rdi
  call   <strcmp@plt>
  test   %rax,%rax
  je     L180
  lea    D138(%rip),%rsi
  mov    %rbx,%rdi
  call   <strcmp@plt>
  test   %rax,%rax
  jne    L243
  mov    %r12,%rsi
  mov    %ebp,%edi
  call   <server_notice@plt>
  xor    %eax,%eax
  jmp    L37
  xchg   %ax,%ax
L180:
  mov    %r12,%rsi
  mov    %ebp,%edi
  call   <server_ctcp@plt>
  pop    %rbx
  xor    %eax,%eax
  pop    %rbp
  pop    %r12
  ret
  nopl   0x0(%rax)
L243:
  lea    D25(%rip),%rsi
  mov    %rbx,%rdi
  call   <strcmp@plt>
  test   %rax,%rax
  je     L267
  lea    D147(%rip),%rsi
  mov    %rbx,%rdi
  call   <strcmp@plt>
  test   %rax,%rax
  jne    L86
  mov    %r12,%rsi
  mov    %ebp,%edi
  call   <server_ctcpr@plt>
  xor    %eax,%eax
  jmp    L37
  nopl   0x0(%rax)
L267:
  mov    %r12,%rsi
  mov    %ebp,%edi
  call   <server_snotice@plt>
  xor    %eax,%eax
  jmp    L37
  nopl   0x0(%rax)
L86:
  lea    D80(%rip),%rsi
  mov    %rbx,%rdi
  call   <strcmp@plt>
  test   %rax,%rax
  jne    L188
  mov    %r12,%rsi
  mov    %ebp,%edi
  call   <server_join@plt>
  xor    %eax,%eax
  jmp    L37
L188:
  lea    D133(%rip),%rsi
  mov    %rbx,%rdi
  call   <strcmp@plt>
  test   %rax,%rax
  jne    L152
  mov    %r12,%rsi
  mov    %ebp,%edi
  call   <server_part@plt>
  xor    %eax,%eax
  jmp    L37
L311:
  lea    D71(%rip),%rcx
L200:
  mov    $0x4,%edx
  xor    %esi,%esi
  mov    $0xffffffff,%edi
  xor    %eax,%eax
  call   <log_add@plt>
  mov    $0xffffffff,%eax
  jmp    L37
L152:
  lea    D70(%rip),%rsi
  mov    %rbx,%rdi
  call   <strcmp@plt>
  test   %rax,%rax
  jne    L157
  mov    %r12,%rsi
  mov    %ebp,%edi
  call   <server_nick@plt>
  xor    %eax,%eax
  jmp    L37
L319:
  lea    D15(%rip),%rcx
  jmp    L200
L157:
  lea    D179(%rip),%rsi
  mov    %rbx,%rdi
  call   <strcmp@plt>
  test   %rax,%rax
  jne    L72
  mov    %r12,%rsi
  mov    %ebp,%edi
  call   <server_quit@plt>
  xor    %eax,%eax
  jmp    L37
L72:
  lea    D206(%rip),%rsi
  mov    %rbx,%rdi
  call   <strcmp@plt>
  test   %rax,%rax
  jne    L111
  mov    %r12,%rsi
  mov    %ebp,%edi
  call   <server_connect@plt>
  xor    %eax,%eax
  jmp    L37
L111:
  lea    D113(%rip),%rsi
  mov    %rbx,%rdi
  call   <strcmp@plt>
  test   %rax,%rax
  jne    L314
  mov    %r12,%rsi
  mov    %ebp,%edi
  call   <server_update@plt>
  xor    %eax,%eax
  jmp    L37
L314:
  lea    D19(%rip),%rsi
  mov    %rbx,%rdi
  call   <strcmp@plt>
  test   %rax,%rax
  jne    L140
  mov    %r12,%rsi
  mov    %ebp,%edi
  call   <server_send@plt>
  xor    %eax,%eax
  jmp    L37
L140:
  lea    D125(%rip),%rsi
  mov    %rbx,%rdi
  call   <strcmp@plt>
  test   %rax,%rax
  jne    L327
  mov    %r12,%rsi
  mov    %ebp,%edi
  call   <server_topic@plt>
  xor    %eax,%eax
  jmp    L37
L327:
  lea    D123(%rip),%rsi
  mov    %rbx,%rdi
  call   <strcmp@plt>
  test   %rax,%rax
  jne    L40
  mov    %r12,%rsi
  mov    %ebp,%edi
  call   <server_note@plt>
  xor    %eax,%eax
  jmp    L37
L40:
  lea    D109(%rip),%rsi
  mov    %rbx,%rdi
  call   <strcmp@plt>
  test   %rax,%rax
  jne    L208
  mov    %r12,%rsi
  mov    %ebp,%edi
  call   <server_dcc@plt>
  xor    %eax,%eax
  jmp    L37
L208:
  lea    D46(%rip),%rsi
  mov    %rbx,%rdi
  call   <strcmp@plt>
  test   %rax,%rax
  jne    L254
  mov    %r12,%rsi
  mov    %ebp,%edi
  call   <server_invite@plt>
  xor    %eax,%eax
  jmp    L37
L254:
  mov    %rbx,%r8
  lea    D160(%rip),%rcx
  xor    %esi,%esi
  or     $0xffffffff,%edi
  mov    $0x4,%edx
  xor    %eax,%eax
  call   <log_add@plt>
  xor    %eax,%eax
  jmp    L37
```

tool_calls: name: extract_symbolic_data
arguments: data_label: D122
type_guessed: string
name: extract_symbolic_data
arguments: data_label: D137
type_guessed: string
name: extract_symbolic_data
arguments: data_label: D108
type_guessed: string
name: extract_symbolic_data
arguments: data_label: D112
type_guessed: string
name: extract_symbolic_data
arguments: data_label: D107
type_guessed: string
name: extract_symbolic_data
arguments: data_label: D138
type_guessed: string
name: extract_symbolic_data
arguments: data_label: D25
type_guessed: string
name: extract_symbolic_data
arguments: data_label: D147
type_guessed: string
name: extract_symbolic_data
arguments: data_label: D80
type_guessed: string
name: extract_symbolic_data
arguments: data_label: D133
type_guessed: string
name: extract_symbolic_data
arguments: data_label: D71
type_guessed: string
name: extract_symbolic_data
arguments: data_label: D70
type_guessed: string
name: extract_symbolic_data
arguments: data_label: D15
type_guessed: string
name: extract_symbolic_data
arguments: data_label: D179
type_guessed: string
name: extract_symbolic_data
arguments: data_label: D206
type_guessed: string
name: extract_symbolic_data
arguments: data_label: D113
type_guessed: string
name: extract_symbolic_data
arguments: data_label: D19
type_guessed: string
name: extract_symbolic_data
arguments: data_label: D125
type_guessed: string
name: extract_symbolic_data
arguments: data_label: D123
type_guessed: string
name: extract_symbolic_data
arguments: data_label: D109
type_guessed: string
name: extract_symbolic_data
arguments: data_label: D46
type_guessed: string
name: extract_symbolic_data
arguments: data_label: D160
type_guessed: string

tool: D122:  

tool: 

tool: D108: HELLO

tool: D112: MSG

tool: D107: CTCP

tool: D138: NOTICE

tool: D25: SNOTICE

tool: D147: CTCPR

tool: D80: JOIN

tool: D133: PART

tool: D71: Garbage server input: no command

tool: D70: NICK

tool: D15: Garbage server input: no child id

tool: D179: QUIT

tool: D206: CONNECT

tool: D113: UPDATE

tool: D19: SEND

tool: D125: TOPIC

tool: D123: NOTE

tool: D109: DCC

tool: D46: INVITE

tool: D160: Garbage server input: unknown command `%s'.

assistant: ```c
int parse_server_input(char *msg) {
  char *id, *cmd, *param;
  int cid;
  id = strtok(msg, " ");
  cmd = strtok(NULL, " ");
  if (id == NULL) {
    log_add(-1, NULL, 0x00000004, "Garbage server input: no child id");
    return -1;
  }
  if (cmd == NULL) {
    log_add(-1, NULL, 0x00000004, "Garbage server input: no command");
    return -1;
  }
  param = strtok(NULL, "");
  cid = atoi(id);
  if (strcmp(cmd, "HELLO") == 0)
    server_hello(cid, param);
  else if (strcmp(cmd, "MSG") == 0)
    server_msg(cid, param);
  else if (strcmp(cmd, "CTCP") == 0)
    server_ctcp(cid, param);
  else if (strcmp(cmd, "NOTICE") == 0)
    server_notice(cid, param);
  else if (strcmp(cmd, "SNOTICE") == 0)
    server_snotice(cid, param);
  else if (strcmp(cmd, "CTCPR") == 0)
    server_ctcpr(cid, param);
  else if (strcmp(cmd, "JOIN") == 0)
    server_join(cid, param);
  else if (strcmp(cmd, "PART") == 0)
    server_part(cid, param);
  else if (strcmp(cmd, "NICK") == 0)
    server_nick(cid, param);
  else if (strcmp(cmd, "QUIT") == 0)
    server_quit(cid, param);
  else if (strcmp(cmd, "CONNECT") == 0)
    server_connect(cid, param);
  else if (strcmp(cmd, "UPDATE") == 0)
    server_update(cid, param);
  else if (strcmp(cmd, "SEND") == 0)
    server_send(cid, param);
  else if (strcmp(cmd, "TOPIC") == 0)
    server_topic(cid, param);
  else if (strcmp(cmd, "NOTE") == 0)
    server_note(cid, param);
  else if (strcmp(cmd, "DCC") == 0)
    server_dcc(cid, param);
  else if (strcmp(cmd, "INVITE") == 0)
    server_invite(cid, param);
  else {
    log_add(-1, NULL, 0x00000004, "Garbage server input: unknown command `%s'.", cmd);
  }
  return 0;
}
```