user: 请将这段汇编代码片段转换成等效的C代码:

```asm
<ffmkky>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x120,%rsp
  mov    %rdi,-0xf8(%rbp)
  mov    %rsi,-0x100(%rbp)
  mov    %rdx,-0x108(%rbp)
  mov    %rcx,-0x110(%rbp)
  mov    %r8,-0x118(%rbp)
  mov    %fs:0x28,%rax
  mov    %rax,-0x8(%rbp)
  xor    %eax,%eax
  movl   $0xffffffff,-0xe4(%rbp)
  movl   $0x0,-0xe0(%rbp)
  movl   $0x0,-0xdc(%rbp)
  movl   $0x0,-0xd8(%rbp)
  movl   $0x0,-0xd4(%rbp)
  mov    -0x118(%rbp),%rax
  mov    (%rax),%eax
  test   %eax,%eax
  jle    L452
  mov    -0x118(%rbp),%rax
  mov    (%rax),%eax
  jmp    L47
L452:
  movb   $0x0,-0xb0(%rbp)
  movb   $0x0,-0x60(%rbp)
  mov    -0x110(%rbp),%rax
  movb   $0x0,(%rax)
  jmp    L374
L321:
  addl   $0x1,-0xe0(%rbp)
L374:
  mov    -0xe0(%rbp),%eax
  movslq %eax,%rdx
  mov    -0xf8(%rbp),%rax
  add    %rdx,%rax
  movzbl (%rax),%eax
  cmp    $0x20,%al
  je     L321
  mov    -0xe0(%rbp),%eax
  movslq %eax,%rdx
  mov    -0xf8(%rbp),%rax
  lea    (%rdx,%rax,1),%rcx
  lea    -0xb0(%rbp),%rax
  mov    $0x4a,%edx
  mov    %rcx,%rsi
  mov    %rax,%rdi
  call   <strncat@plt>
  mov    -0x100(%rbp),%rax
  mov    %rax,%rdi
  call   <strlen@plt>
  cltq
  mov    %rax,-0xc8(%rbp)
  lea    -0xb0(%rbp),%rax
  mov    %rax,%rdi
  call   <strlen@plt>
  cltq
  mov    %rax,-0xd0(%rbp)
  cmpq   $0x0,-0xd0(%rbp)
  je     L165
  mov    -0xd0(%rbp),%rax
  lea    -0x1(%rax),%rdx
  lea    -0xb0(%rbp),%rax
  add    %rdx,%rax
  mov    %rax,-0xb8(%rbp)
  jmp    L425
L570:
  mov    -0xb8(%rbp),%rax
  movb   $0x0,(%rax)
  subq   $0x1,-0xb8(%rbp)
L425:
  mov    -0xb8(%rbp),%rax
  movzbl (%rax),%eax
  cmp    $0x20,%al
  je     L570
  lea    -0xb0(%rbp),%rdx
  mov    -0xb8(%rbp),%rax
  sub    %rdx,%rax
  add    $0x1,%rax
  mov    %rax,-0xd0(%rbp)
L165:
  lea    -0xb0(%rbp),%rax
  mov    $0x3d,%esi
  mov    %rax,%rdi
  call   <strchr@plt>
  test   %rax,%rax
  je     L492
  lea    D148(%rip),%rax
  mov    %rax,%rdi
  call   <ffpmsg@plt>
  lea    -0xb0(%rbp),%rax
  mov    %rax,%rdi
  call   <ffpmsg@plt>
  mov    -0x118(%rbp),%rax
  movl   $0xcf,(%rax)
  mov    -0x118(%rbp),%rax
  mov    (%rax),%eax
  jmp    L47
L492:
  cmpq   $0x8,-0xd0(%rbp)
  ja     L554
  lea    -0xe4(%rbp),%rdx
  lea    -0xb0(%rbp),%rax
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <fftkey@plt>
  test   %rax,%rax
  jg     L554
  lea    -0xb0(%rbp),%rdx
  mov    -0x110(%rbp),%rax
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcat@plt>
  mov    -0xd0(%rbp),%rax
  mov    %rax,-0xc0(%rbp)
  jmp    L233
L441:
  mov    -0x110(%rbp),%rdx
  mov    -0xc0(%rbp),%rax
  add    %rdx,%rax
  movb   $0x20,(%rax)
  addq   $0x1,-0xc0(%rbp)
L233:
  cmpq   $0x7,-0xc0(%rbp)
  jbe    L441
  mov    -0x110(%rbp),%rax
  add    $0x8,%rax
  movb   $0x3d,(%rax)
  mov    -0x110(%rbp),%rax
  add    $0x9,%rax
  movb   $0x20,(%rax)
  mov    -0x110(%rbp),%rax
  add    $0xa,%rax
  movb   $0x0,(%rax)
  movq   $0xa,-0xd0(%rbp)
  jmp    L197
L554:
  movzbl -0xb0(%rbp),%eax
  mov    $0x48,%edx
  cmp    %dl,%al
  jl     L196
  movzbl -0xb0(%rbp),%eax
  mov    $0x48,%edx
  cmp    %dl,%al
  jg     L196
  lea    -0xb0(%rbp),%rax
  mov    $0x9,%edx
  lea    D104(%rip),%rcx
  mov    %rcx,%rsi
  mov    %rax,%rdi
  call   <strncmp@plt>
  test   %eax,%eax
  je     L217
L196:
  movzbl -0xb0(%rbp),%eax
  mov    $0x68,%edx
  cmp    %dl,%al
  jl     L10
  movzbl -0xb0(%rbp),%eax
  mov    $0x68,%edx
  cmp    %dl,%al
  jg     L10
  lea    -0xb0(%rbp),%rax
  mov    $0x9,%edx
  lea    D42(%rip),%rcx
  mov    %rcx,%rsi
  mov    %rax,%rdi
  call   <strncmp@plt>
  test   %eax,%eax
  jne    L10
L217:
  lea    -0xb0(%rbp),%rdx
  mov    -0x110(%rbp),%rax
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcat@plt>
  mov    -0xd0(%rbp),%rdx
  mov    -0xc8(%rbp),%rax
  add    %rdx,%rax
  add    $0x3,%rax
  cmp    $0x50,%rax
  jbe    L31
  mov    -0x110(%rbp),%rax
  lea    D45(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcat@plt>
  addq   $0x2,-0xd0(%rbp)
  jmp    L197
L31:
  mov    -0x110(%rbp),%rax
  lea    D81(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcat@plt>
  addq   $0x3,-0xd0(%rbp)
  jmp    L197
L10:
  lea    -0xb0(%rbp),%rcx
  lea    -0x60(%rbp),%rax
  mov    $0x4a,%edx
  mov    %rcx,%rsi
  mov    %rax,%rdi
  call   <strncat@plt>
  lea    -0x60(%rbp),%rax
  lea    D9(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strtok@plt>
  mov    %rax,-0xb8(%rbp)
  jmp    L212
L15:
  mov    -0xb8(%rbp),%rax
  mov    %rax,%rdi
  call   <strlen@plt>
  cmp    %eax,-0xd8(%rbp)
  jge    L518
  mov    -0xb8(%rbp),%rax
  mov    %rax,%rdi
  call   <strlen@plt>
  mov    %eax,-0xd8(%rbp)
L518:
  movl   $0xffffffff,-0xe4(%rbp)
  lea    -0xe4(%rbp),%rdx
  mov    -0xb8(%rbp),%rax
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <fftkey@plt>
  test   %rax,%rax
  jle    L94
  movl   $0x1,-0xd4(%rbp)
L94:
  lea    D9(%rip),%rax
  mov    %rax,%rsi
  mov    $0x0,%edi
  call   <strtok@plt>
  mov    %rax,-0xb8(%rbp)
  addl   $0x1,-0xdc(%rbp)
L212:
  cmpq   $0x0,-0xb8(%rbp)
  jne    L15
  movl   $0xffffffff,-0xe4(%rbp)
  cmpl   $0x0,-0xdc(%rbp)
  jle    L109
  mov    -0xd0(%rbp),%rax
  add    $0xb,%rax
  cmp    $0x50,%rax
  jbe    L371
  lea    D64(%rip),%rax
  mov    %rax,%rdi
  call   <ffpmsg@plt>
  mov    -0xf8(%rbp),%rax
  mov    %rax,%rdi
  call   <ffpmsg@plt>
  mov    -0x118(%rbp),%rax
  movl   $0xcf,(%rax)
  mov    -0x118(%rbp),%rax
  mov    (%rax),%eax
  jmp    L47
L371:
  mov    -0x110(%rbp),%rax
  lea    D104(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcat@plt>
  lea    -0xb0(%rbp),%rdx
  mov    -0x110(%rbp),%rax
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcat@plt>
  addq   $0x9,-0xd0(%rbp)
  mov    -0xd0(%rbp),%rdx
  mov    -0xc8(%rbp),%rax
  add    %rdx,%rax
  add    $0x3,%rax
  cmp    $0x50,%rax
  jbe    L147
  mov    -0x110(%rbp),%rax
  lea    D45(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcat@plt>
  addq   $0x2,-0xd0(%rbp)
  jmp    L197
L147:
  mov    -0x110(%rbp),%rax
  lea    D81(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcat@plt>
  addq   $0x3,-0xd0(%rbp)
  jmp    L197
L109:
  lea    -0xe4(%rbp),%rdx
  lea    -0xb0(%rbp),%rax
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <fftkey@plt>
  test   %rax,%rax
  jg     L0
  lea    -0xb0(%rbp),%rcx
  mov    -0x110(%rbp),%rax
  mov    $0x4a,%edx
  mov    %rcx,%rsi
  mov    %rax,%rdi
  call   <strncat@plt>
  mov    -0x110(%rbp),%rax
  lea    D45(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcat@plt>
  addq   $0x2,-0xd0(%rbp)
  jmp    L197
L0:
  lea    D76(%rip),%rax
  mov    %rax,%rdi
  call   <ffpmsg@plt>
  lea    -0xb0(%rbp),%rax
  mov    %rax,%rdi
  call   <ffpmsg@plt>
  mov    -0x118(%rbp),%rax
  movl   $0xcf,(%rax)
  mov    -0x118(%rbp),%rax
  mov    (%rax),%eax
  jmp    L47
L197:
  cmpq   $0x0,-0xc8(%rbp)
  je     L446
  mov    -0x100(%rbp),%rax
  movzbl (%rax),%eax
  cmp    $0x27,%al
  jne    L335
  cmpq   $0x4d,-0xd0(%rbp)
  jbe    L357
  lea    D86(%rip),%rax
  mov    %rax,%rdi
  call   <ffpmsg@plt>
  mov    -0xf8(%rbp),%rax
  mov    %rax,%rdi
  call   <ffpmsg@plt>
  mov    -0x100(%rbp),%rax
  mov    %rax,%rdi
  call   <ffpmsg@plt>
  mov    -0x118(%rbp),%rax
  movl   $0xcf,(%rax)
  mov    -0x118(%rbp),%rax
  mov    (%rax),%eax
  jmp    L47
L357:
  mov    -0xd0(%rbp),%rax
  mov    %eax,%edx
  mov    $0x50,%eax
  sub    %edx,%eax
  mov    %eax,%edx
  mov    -0x100(%rbp),%rcx
  mov    -0x110(%rbp),%rax
  mov    %rcx,%rsi
  mov    %rax,%rdi
  call   <strncat@plt>
  mov    -0xd0(%rbp),%rdx
  mov    -0xc8(%rbp),%rax
  add    %rdx,%rax
  mov    $0x50,%edx
  cmp    %rdx,%rax
  cmova  %rdx,%rax
  mov    %rax,-0xc8(%rbp)
  cmpq   $0x50,-0xc8(%rbp)
  jne    L1
  mov    -0x110(%rbp),%rax
  add    $0x4f,%rax
  movb   $0x27,(%rax)
L1:
  cmpq   $0x0,-0x108(%rbp)
  je     L54
  mov    -0x108(%rbp),%rax
  movzbl (%rax),%eax
  test   %al,%al
  je     L54
  cmpq   $0x1d,-0xc8(%rbp)
  ja     L54
  mov    -0xc8(%rbp),%rax
  mov    %rax,-0xc0(%rbp)
  jmp    L139
L203:
  mov    -0x110(%rbp),%rdx
  mov    -0xc0(%rbp),%rax
  add    %rdx,%rax
  movb   $0x20,(%rax)
  addq   $0x1,-0xc0(%rbp)
L139:
  cmpq   $0x1d,-0xc0(%rbp)
  jbe    L203
  mov    -0x110(%rbp),%rax
  add    $0x1e,%rax
  movb   $0x0,(%rax)
  movq   $0x1e,-0xc8(%rbp)
  jmp    L54
L335:
  mov    -0xd0(%rbp),%rdx
  mov    -0xc8(%rbp),%rax
  add    %rdx,%rax
  cmp    $0x50,%rax
  jbe    L253
  lea    D86(%rip),%rax
  mov    %rax,%rdi
  call   <ffpmsg@plt>
  mov    -0xf8(%rbp),%rax
  mov    %rax,%rdi
  call   <ffpmsg@plt>
  mov    -0x100(%rbp),%rax
  mov    %rax,%rdi
  call   <ffpmsg@plt>
  mov    -0x118(%rbp),%rax
  movl   $0xcf,(%rax)
  mov    -0x118(%rbp),%rax
  mov    (%rax),%eax
  jmp    L47
L253:
  mov    -0xd0(%rbp),%rdx
  mov    -0xc8(%rbp),%rax
  add    %rdx,%rax
  cmp    $0x1d,%rax
  ja     L353
  mov    -0xd0(%rbp),%rax
  mov    %eax,%edx
  mov    -0xc8(%rbp),%rax
  add    %eax,%edx
  mov    $0x1e,%eax
  sub    %edx,%eax
  mov    %eax,%edx
  mov    -0x110(%rbp),%rax
  lea    D113(%rip),%rcx
  mov    %rcx,%rsi
  mov    %rax,%rdi
  call   <strncat@plt>
L353:
  mov    -0xd0(%rbp),%rax
  mov    %eax,%edx
  mov    $0x50,%eax
  sub    %edx,%eax
  mov    %eax,%edx
  mov    -0x100(%rbp),%rcx
  mov    -0x110(%rbp),%rax
  mov    %rcx,%rsi
  mov    %rax,%rdi
  call   <strncat@plt>
  mov    -0xd0(%rbp),%rdx
  mov    -0xc8(%rbp),%rax
  add    %rdx,%rax
  mov    $0x50,%edx
  cmp    %rdx,%rax
  cmova  %rdx,%rax
  mov    %rax,-0xc8(%rbp)
  mov    -0xc8(%rbp),%rax
  mov    $0x1e,%edx
  cmp    %rdx,%rax
  cmovb  %rdx,%rax
  mov    %rax,-0xc8(%rbp)
L54:
  cmpq   $0x0,-0x108(%rbp)
  je     L406
  cmpq   $0x4c,-0xc8(%rbp)
  ja     L406
  mov    -0x108(%rbp),%rax
  mov    %rax,%rdi
  call   <strlen@plt>
  test   %eax,%eax
  jle    L406
  mov    -0x110(%rbp),%rax
  lea    D153(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcat@plt>
  mov    -0xc8(%rbp),%rax
  mov    %eax,%edx
  mov    $0x4d,%eax
  sub    %edx,%eax
  mov    %eax,%edx
  mov    -0x108(%rbp),%rcx
  mov    -0x110(%rbp),%rax
  mov    %rcx,%rsi
  mov    %rax,%rdi
  call   <strncat@plt>
  jmp    L406
L446:
  cmpq   $0xa,-0xd0(%rbp)
  jne    L406
  mov    -0x110(%rbp),%rax
  add    $0x8,%rax
  movb   $0x20,(%rax)
  cmpq   $0x0,-0x108(%rbp)
  je     L406
  mov    -0xd0(%rbp),%rax
  mov    %eax,%edx
  mov    $0x50,%eax
  sub    %edx,%eax
  mov    %eax,%edx
  mov    -0x108(%rbp),%rcx
  mov    -0x110(%rbp),%rax
  mov    %rcx,%rsi
  mov    %rax,%rdi
  call   <strncat@plt>
L406:
  cmpl   $0x1,-0xdc(%rbp)
  je     L154
  cmpl   $0x1,-0xd4(%rbp)
  jne    L551
L154:
  lea    D140(%rip),%rax
  mov    %rax,%rdi
  call   <ffpmsg@plt>
  mov    -0x110(%rbp),%rax
  mov    %rax,%rdi
  call   <ffpmsg@plt>
L551:
  mov    -0x118(%rbp),%rax
  mov    (%rax),%eax
L47:
  mov    -0x8(%rbp),%rdx
  sub    %fs:0x28,%rdx
  je     L64
  call   <__stack_chk_fail@plt>
L64:
  leave
  ret
```

tool_calls: name: parse_data
arguments: data_label: D148
type: string
name: parse_data
arguments: data_label: D104
type: string
name: parse_data
arguments: data_label: D42
type: string
name: parse_data
arguments: data_label: D45
type: string
name: parse_data
arguments: data_label: D81
type: string
name: parse_data
arguments: data_label: D9
type: string
name: parse_data
arguments: data_label: D64
type: string
name: parse_data
arguments: data_label: D76
type: string
name: parse_data
arguments: data_label: D86
type: string
name: parse_data
arguments: data_label: D113
type: string
name: parse_data
arguments: data_label: D153
type: string
name: parse_data
arguments: data_label: D140
type: string

tool: D148: Illegal keyword name; contains an equals sign (=)

tool: D104: HIERARCH 

tool: D42: hierarch 

tool: D45: = 

tool: D81:  = 

tool: D9:  

tool: D64: The following keyword is too long to fit on a card:

tool: D76: Illegal keyword name:

tool: D86: The following keyword + value is too long to fit on a card:

tool: D113:                     

tool: D153:  / 

tool: D140: Warning: the following keyword does not conform to the HIERARCH convention

assistant: ```c
int ffmkky(const char *keyname, char *value, const char *comm, char *card, int *status) {
  size_t namelen, len, ii;
  char tmpname[75], tmpname2[75], *cptr;
  char *saveptr;
  int tstatus = -1, nblank = 0, ntoken = 0, maxlen = 0, specialchar = 0;
  if (*status > 0)
    return (*status);
  *tmpname = '\0';
  *tmpname2 = '\0';
  *card = '\0';
  while (*(keyname + nblank) == ' ')
    nblank++;
  strncat(tmpname, keyname + nblank, 75 - 1);
  len = strlen(value);
  namelen = strlen(tmpname);
  if (namelen) {
    cptr = tmpname + namelen - 1;
    while (*cptr == ' ') {
      *cptr = '\0';
      cptr--;
    }
    namelen = cptr - tmpname + 1;
  }
  if (strchr(tmpname, '=')) {
    ffpmsg("Illegal keyword name; contains an equals sign (=)");
    ffpmsg(tmpname);
    return (*status = 207);
  }
  if (namelen <= 8 && fftkey(tmpname, &tstatus) <= 0) {
    strcat(card, tmpname);
    for (ii = namelen; ii < 8; ii++)
      card[ii] = ' ';
    card[8] = '=';
    card[9] = ' ';
    card[10] = '\0';
    namelen = 10;
  } else if ((((tmpname)[0] < ("HIERARCH ")[0] ? -1 : (tmpname)[0] > ("HIERARCH ")[0] ? 1 : strncmp((tmpname), ("HIERARCH "), (9))) == 0) || (((tmpname)[0] < ("hierarch ")[0] ? -1 : (tmpname)[0] > ("hierarch ")[0] ? 1 : strncmp((tmpname), ("hierarch "), (9))) == 0)) {
    strcat(card, tmpname);
    if (namelen + 3 + len > 80) {
      strcat(card, "= ");
      namelen += 2;
    } else {
      strcat(card, " = ");
      namelen += 3;
    }
  } else {
    strncat(tmpname2, tmpname, 75 - 1);
    cptr = strtok(tmpname2, " ");
    while (cptr) {
      if (strlen(cptr) > maxlen)
        maxlen = strlen(cptr);
      tstatus = -1;
      if (fftkey(cptr, &tstatus) > 0)
        specialchar = 1;
      cptr = strtok(NULL, " ");
      ntoken++;
    }
    tstatus = -1;
    if (ntoken > 0) {
      if (namelen + 11 > 81 - 1) {
        ffpmsg("The following keyword is too long to fit on a card:");
        ffpmsg(keyname);
        return (*status = 207);
      }
      strcat(card, "HIERARCH ");
      strcat(card, tmpname);
      namelen += 9;
      if (namelen + 3 + len > 80) {
        strcat(card, "= ");
        namelen += 2;
      } else {
        strcat(card, " = ");
        namelen += 3;
      }
    } else if ((fftkey(tmpname, &tstatus) <= 0)) {
      strncat(card, tmpname, 75 - 1);
      strcat(card, "= ");
      namelen += 2;
    } else {
      ffpmsg("Illegal keyword name:");
      ffpmsg(tmpname);
      return (*status = 207);
    }
  }
  if (len > 0) {
    if (value[0] == '\'') {
      if (namelen > 77) {
        ffpmsg("The following keyword + value is too long to fit on a card:");
        ffpmsg(keyname);
        ffpmsg(value);
        return (*status = 207);
      }
      strncat(card, value, 80 - namelen);
      len = ((80) < (namelen + len) ? (80) : (namelen + len));
      if (len == 80) {
        card[79] = '\'';
      }
      if (comm) {
        if (comm[0] != 0) {
          if (len < 30) {
            for (ii = len; ii < 30; ii++)
              card[ii] = ' ';
            card[30] = '\0';
            len = 30;
          }
        }
      }
    } else {
      if (namelen + len > 80) {
        ffpmsg("The following keyword + value is too long to fit on a card:");
        ffpmsg(keyname);
        ffpmsg(value);
        return (*status = 207);
      } else if (namelen + len < 30) {
        strncat(card, "                    ", 30 - (namelen + len));
      }
      strncat(card, value, 80 - namelen);
      len = ((80) < (namelen + len) ? (80) : (namelen + len));
      len = ((30) > (len) ? (30) : (len));
    }
    if (comm) {
      if ((len < 77) && (strlen(comm) > 0)) {
        strcat(card, " / ");
        strncat(card, comm, 77 - len);
      }
    }
  } else {
    if (namelen == 10) {
      card[8] = ' ';
      if (comm) {
        strncat(card, comm, 80 - namelen);
      }
    }
  }
  if (ntoken == 1 || specialchar == 1) {
    ffpmsg("Warning: the following keyword does not conform to the HIERARCH convention");
    ffpmsg(card);
  }
  return (*status);
}
```