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

```asm
<type_from_name>:
  endbr64
  push   %r12
  lea    D73(%rip),%rsi
  mov    %rdi,%r12
  call   <strcmp@plt>
  mov    %eax,%r8d
  mov    $0x73,%eax
  test   %r8d,%r8d
  je     L58
  lea    D150(%rip),%rsi
  mov    %r12,%rdi
  call   <strcmp@plt>
  mov    %eax,%r8d
  mov    $0x6e,%eax
  test   %r8d,%r8d
  je     L58
  lea    D38(%rip),%rsi
  mov    %r12,%rdi
  call   <strcmp@plt>
  mov    %eax,%r8d
  mov    $0x71,%eax
  test   %r8d,%r8d
  je     L58
  lea    D104(%rip),%rsi
  mov    %r12,%rdi
  call   <strcmp@plt>
  mov    %eax,%r8d
  mov    $0x69,%eax
  test   %r8d,%r8d
  je     L58
  lea    D152(%rip),%rsi
  mov    %r12,%rdi
  call   <strcmp@plt>
  mov    %eax,%r8d
  mov    $0x75,%eax
  test   %r8d,%r8d
  je     L58
  lea    D127(%rip),%rsi
  mov    %r12,%rdi
  call   <strcmp@plt>
  mov    %eax,%r8d
  mov    $0x78,%eax
  test   %r8d,%r8d
  je     L58
  lea    D49(%rip),%rsi
  mov    %r12,%rdi
  call   <strcmp@plt>
  mov    %eax,%r8d
  mov    $0x74,%eax
  test   %r8d,%r8d
  je     L58
  lea    D0(%rip),%rsi
  mov    %r12,%rdi
  call   <strcmp@plt>
  mov    %eax,%r8d
  mov    $0x64,%eax
  test   %r8d,%r8d
  je     L58
  lea    D140(%rip),%rsi
  mov    %r12,%rdi
  call   <strcmp@plt>
  mov    %eax,%r8d
  mov    $0x79,%eax
  test   %r8d,%r8d
  je     L58
  lea    D62(%rip),%rsi
  mov    %r12,%rdi
  call   <strcmp@plt>
  mov    %eax,%r8d
  mov    $0x62,%eax
  test   %r8d,%r8d
  je     L58
  lea    D50(%rip),%rsi
  mov    %r12,%rdi
  call   <strcmp@plt>
  mov    %eax,%r8d
  mov    $0x6f,%eax
  test   %r8d,%r8d
  je     L58
  lea    D118(%rip),%rsi
  mov    %r12,%rdi
  call   <strcmp@plt>
  mov    %eax,%r8d
  mov    $0x76,%eax
  test   %r8d,%r8d
  je     L58
  lea    D108(%rip),%rsi
  mov    %r12,%rdi
  call   <strcmp@plt>
  mov    %eax,%r8d
  mov    $0x61,%eax
  test   %r8d,%r8d
  je     L58
  lea    D25(%rip),%rsi
  mov    %r12,%rdi
  call   <strcmp@plt>
  mov    %eax,%r8d
  mov    $0x72,%eax
  test   %r8d,%r8d
  je     L58
  lea    D16(%rip),%rsi
  mov    %r12,%rdi
  call   <strcmp@plt>
  mov    %eax,%r8d
  mov    $0x65,%eax
  test   %r8d,%r8d
  je     L58
  mov    %r12,%rdx
  lea    D96(%rip),%rsi
  xor    %edi,%edi
  call   <assert_error@plt>
  xor    %eax,%eax
L58:
  pop    %r12
  ret
```

tool_calls: name: retrieve_data
arguments: tag: D73
datatype: string
name: retrieve_data
arguments: tag: D150
datatype: string
name: retrieve_data
arguments: tag: D38
datatype: string
name: retrieve_data
arguments: tag: D104
datatype: string
name: retrieve_data
arguments: tag: D152
datatype: string
name: retrieve_data
arguments: tag: D127
datatype: string
name: retrieve_data
arguments: tag: D49
datatype: string
name: retrieve_data
arguments: tag: D0
datatype: string
name: retrieve_data
arguments: tag: D140
datatype: string
name: retrieve_data
arguments: tag: D62
datatype: string
name: retrieve_data
arguments: tag: D50
datatype: string
name: retrieve_data
arguments: tag: D118
datatype: string
name: retrieve_data
arguments: tag: D108
datatype: string
name: retrieve_data
arguments: tag: D25
datatype: string
name: retrieve_data
arguments: tag: D16
datatype: string
name: retrieve_data
arguments: tag: D96
datatype: string

tool: D73: string

tool: D150: int16

tool: D38: uint16

tool: D104: int32

tool: D152: uint32

tool: D127: int64

tool: D49: uint64

tool: D0: double

tool: D140: byte

tool: D62: boolean

tool: D50: objpath

tool: D118: variant

tool: D108: array

tool: D25: struct

tool: D16: dict

tool: D96: Unknown type '%s'

assistant: ```c
int type_from_name(const char *arg) {
  if (!strcmp(arg, "string"))
    return 's';
  else if (!strcmp(arg, "int16"))
    return 'n';
  else if (!strcmp(arg, "uint16"))
    return 'q';
  else if (!strcmp(arg, "int32"))
    return 'i';
  else if (!strcmp(arg, "uint32"))
    return 'u';
  else if (!strcmp(arg, "int64"))
    return 'x';
  else if (!strcmp(arg, "uint64"))
    return 't';
  else if (!strcmp(arg, "double"))
    return 'd';
  else if (!strcmp(arg, "byte"))
    return 'y';
  else if (!strcmp(arg, "boolean"))
    return 'b';
  else if (!strcmp(arg, "objpath"))
    return 'o';
  else if (!strcmp(arg, "variant"))
    return 'v';
  else if (!strcmp(arg, "array"))
    return 'a';
  else if (!strcmp(arg, "struct"))
    return 'r';
  else if (!strcmp(arg, "dict"))
    return 'e';
  assert_error(0, "Unknown type '%s'", arg);
  return 0;
}
```