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

```asm
<ArabicToRoman>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x30,%rsp
  mov    %edi,-0x24(%rbp)
  mov    $0x64,%edi
  call   <malloc@plt>
  mov    %rax,-0x8(%rbp)
  mov    -0x8(%rbp),%rax
  lea    D40(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  mov    -0x24(%rbp),%edx
  movslq %edx,%rax
  imul   $0x66666667,%rax,%rax
  shr    $0x20,%rax
  sar    $0x2,%eax
  mov    %edx,%esi
  sar    $0x1f,%esi
  sub    %esi,%eax
  mov    %eax,%ecx
  mov    %ecx,%eax
  shl    $0x2,%eax
  add    %ecx,%eax
  add    %eax,%eax
  sub    %eax,%edx
  mov    %edx,-0x14(%rbp)
  mov    -0x24(%rbp),%edx
  movslq %edx,%rax
  imul   $0x51eb851f,%rax,%rax
  shr    $0x20,%rax
  sar    $0x5,%eax
  mov    %edx,%ecx
  sar    $0x1f,%ecx
  sub    %ecx,%eax
  imul   $0x64,%eax,%ecx
  mov    %edx,%eax
  sub    %ecx,%eax
  sub    -0x14(%rbp),%eax
  movslq %eax,%rdx
  imul   $0x66666667,%rdx,%rdx
  shr    $0x20,%rdx
  sar    $0x2,%edx
  sar    $0x1f,%eax
  mov    %eax,%ecx
  mov    %edx,%eax
  sub    %ecx,%eax
  mov    %eax,-0x10(%rbp)
  mov    -0x10(%rbp),%eax
  imul   $0xfffffff6,%eax,%edx
  mov    -0x24(%rbp),%eax
  add    %edx,%eax
  sub    -0x14(%rbp),%eax
  movslq %eax,%rdx
  imul   $0x51eb851f,%rdx,%rdx
  shr    $0x20,%rdx
  sar    $0x5,%edx
  sar    $0x1f,%eax
  mov    %eax,%ecx
  mov    %edx,%eax
  sub    %ecx,%eax
  mov    %eax,-0xc(%rbp)
  cmpl   $0x3,-0xc(%rbp)
  je     L246
  cmpl   $0x3,-0xc(%rbp)
  jg     L215
  cmpl   $0x2,-0xc(%rbp)
  je     L224
  cmpl   $0x2,-0xc(%rbp)
  jg     L215
  cmpl   $0x0,-0xc(%rbp)
  je     L96
  cmpl   $0x1,-0xc(%rbp)
  jne    L215
  mov    -0x8(%rbp),%rax
  lea    D39(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcat@plt>
  jmp    L215
L224:
  mov    -0x8(%rbp),%rax
  lea    D125(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcat@plt>
  jmp    L215
L246:
  mov    -0x8(%rbp),%rax
  lea    D235(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcat@plt>
  jmp    L215
L96:
  nop
L215:
  cmpl   $0x9,-0x10(%rbp)
  ja     L106
  mov    -0x10(%rbp),%eax
  lea    0x0(,%rax,4),%rdx
  lea    D157(%rip),%rax
  mov    (%rdx,%rax,1),%eax
  cltq
  lea    D157(%rip),%rdx
  add    %rdx,%rax
  notrack jmp *%rax
  mov    -0x8(%rbp),%rax
  lea    D50(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcat@plt>
  jmp    L106
  mov    -0x8(%rbp),%rax
  lea    D223(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcat@plt>
  jmp    L106
  mov    -0x8(%rbp),%rax
  lea    D131(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcat@plt>
  jmp    L106
  mov    -0x8(%rbp),%rax
  lea    D31(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcat@plt>
  jmp    L106
  mov    -0x8(%rbp),%rax
  lea    D62(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcat@plt>
  jmp    L106
  mov    -0x8(%rbp),%rax
  lea    D30(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcat@plt>
  jmp    L106
  mov    -0x8(%rbp),%rax
  lea    D51(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcat@plt>
  jmp    L106
  mov    -0x8(%rbp),%rax
  lea    D246(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcat@plt>
  jmp    L106
  mov    -0x8(%rbp),%rax
  lea    D105(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcat@plt>
  jmp    L106
  nop
L106:
  cmpl   $0x9,-0x14(%rbp)
  ja     L102
  mov    -0x14(%rbp),%eax
  lea    0x0(,%rax,4),%rdx
  lea    D67(%rip),%rax
  mov    (%rdx,%rax,1),%eax
  cltq
  lea    D67(%rip),%rdx
  add    %rdx,%rax
  notrack jmp *%rax
  mov    -0x8(%rbp),%rax
  lea    D47(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcat@plt>
  jmp    L102
  mov    -0x8(%rbp),%rax
  lea    D63(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcat@plt>
  jmp    L102
  mov    -0x8(%rbp),%rax
  lea    D42(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcat@plt>
  jmp    L102
  mov    -0x8(%rbp),%rax
  lea    D46(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcat@plt>
  jmp    L102
  mov    -0x8(%rbp),%rax
  lea    D181(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcat@plt>
  jmp    L102
  mov    -0x8(%rbp),%rax
  lea    D185(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcat@plt>
  jmp    L102
  mov    -0x8(%rbp),%rax
  lea    D175(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcat@plt>
  jmp    L102
  mov    -0x8(%rbp),%rax
  lea    D87(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcat@plt>
  jmp    L102
  mov    -0x8(%rbp),%rax
  lea    D124(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcat@plt>
  jmp    L102
  nop
L102:
  mov    -0x8(%rbp),%rax
  leave
  ret
```

tool_calls: name: read_data
arguments: data_tag: D40
type_guessed: string
name: read_data
arguments: data_tag: D39
type_guessed: string
name: read_data
arguments: data_tag: D125
type_guessed: string
name: read_data
arguments: data_tag: D235
type_guessed: string
name: read_data
arguments: data_tag: D50
type_guessed: string
name: read_data
arguments: data_tag: D223
type_guessed: string
name: read_data
arguments: data_tag: D131
type_guessed: string
name: read_data
arguments: data_tag: D31
type_guessed: string
name: read_data
arguments: data_tag: D62
type_guessed: string
name: read_data
arguments: data_tag: D30
type_guessed: string
name: read_data
arguments: data_tag: D51
type_guessed: string
name: read_data
arguments: data_tag: D246
type_guessed: string
name: read_data
arguments: data_tag: D105
type_guessed: string
name: read_data
arguments: data_tag: D47
type_guessed: string
name: read_data
arguments: data_tag: D63
type_guessed: string
name: read_data
arguments: data_tag: D42
type_guessed: string
name: read_data
arguments: data_tag: D46
type_guessed: string
name: read_data
arguments: data_tag: D181
type_guessed: string
name: read_data
arguments: data_tag: D185
type_guessed: string
name: read_data
arguments: data_tag: D175
type_guessed: string
name: read_data
arguments: data_tag: D87
type_guessed: string
name: read_data
arguments: data_tag: D124
type_guessed: string

tool: 

tool: D39: C

tool: D125: CC

tool: D235: CCC

tool: D50: X

tool: D223: XX

tool: D131: XXX

tool: D31: XL

tool: D62: L

tool: D30: LX

tool: D51: LXX

tool: D246: LXXX

tool: D105: XC

tool: D47: I

tool: D63: II

tool: D42: III

tool: D46: IV

tool: D181: V

tool: D185: VI

tool: D175: VII

tool: D87: VIII

tool: D124: IX

assistant: ```c
char *ArabicToRoman(int arabic) {
  int unidades;
  int decenas;
  int centenas;
  char *roman;
  roman = malloc(sizeof(char) * 100);
  strcpy(roman, "");
  unidades = arabic % 10;
  decenas = ((arabic % 100) - unidades) / 10;
  centenas = (arabic - decenas * 10 - unidades) / 100;
  switch (centenas) {
  case 0:
    break;
  case 1:
    strcat(roman, "C");
    break;
  case 2:
    strcat(roman, "CC");
    break;
  case 3:
    strcat(roman, "CCC");
    break;
  }
  switch (decenas) {
  case 0:
    break;
  case 1:
    strcat(roman, "X");
    break;
  case 2:
    strcat(roman, "XX");
    break;
  case 3:
    strcat(roman, "XXX");
    break;
  case 4:
    strcat(roman, "XL");
    break;
  case 5:
    strcat(roman, "L");
    break;
  case 6:
    strcat(roman, "LX");
    break;
  case 7:
    strcat(roman, "LXX");
    break;
  case 8:
    strcat(roman, "LXXX");
    break;
  case 9:
    strcat(roman, "XC");
    break;
  }
  switch (unidades) {
  case 0:
    break;
  case 1:
    strcat(roman, "I");
    break;
  case 2:
    strcat(roman, "II");
    break;
  case 3:
    strcat(roman, "III");
    break;
  case 4:
    strcat(roman, "IV");
    break;
  case 5:
    strcat(roman, "V");
    break;
  case 6:
    strcat(roman, "VI");
    break;
  case 7:
    strcat(roman, "VII");
    break;
  case 8:
    strcat(roman, "VIII");
    break;
  case 9:
    strcat(roman, "IX");
    break;
  }
  return roman;
}
```