user: 请将以下的汇编代码转换成C语言代码：

```asm
<cvt>:
  endbr64
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x28,%rsp
  movq   %xmm0,%rbx
  mov    %edi,%ebp
  mov    %esi,%r15d
  mov    %rdx,%rax
  mov    %rcx,%r14
  mov    %r8d,%r13d
  mov    %r9,%r12
  mov    %fs:0x28,%rdx
  mov    %rdx,0x18(%rsp)
  xor    %edx,%edx
  cmp    $0x66,%r8d
  je     L99
  mov    %r8d,%edx
  and    $0xffffffdf,%edx
  cmp    $0x45,%edx
  sete   %dl
  movzbl %dl,%edx
  add    %edx,%ebp
  pxor   %xmm0,%xmm0
  movq   %rbx,%xmm3
  mov    $0x2,%edi
  comisd %xmm3,%xmm0
  ja     L63
  movb   $0x0,(%rax)
  lea    0xc(%rsp),%rcx
  lea    0x10(%rsp),%r8
  mov    %r14,%rdx
  mov    %ebp,%esi
  mov    $0x2,%edi
  movq   %rbx,%xmm0
  mov    $0x1,%eax
  call   <__dtoa@plt>
  movslq %eax,%rsi
  mov    %r13d,%eax
  and    $0xffffffdf,%eax
  cmp    $0x47,%eax
  je     L62
  movslq %ebp,%rcx
  add    %rsi,%rcx
  jmp    L34
L46:
  mov    $0x3,%edi
L63:
  movq   %rbx,%xmm0
  xorpd  D25(%rip),%xmm0
  movq   %xmm0,%rbx
  movb   $0x2d,(%rax)
  lea    0xc(%rsp),%rcx
  lea    0x10(%rsp),%r8
  mov    %r14,%rdx
  mov    %ebp,%esi
  mov    $0x1,%eax
  call   <__dtoa@plt>
  movslq %eax,%rsi
  mov    %r13d,%eax
  and    $0xffffffdf,%eax
  cmp    $0x47,%eax
  jne    L146
L62:
  test   $0x1,%r15b
  je     L4
L146:
  movslq %ebp,%rcx
  add    %rsi,%rcx
  cmp    $0x66,%r13d
  je     L179
L34:
  movq   %rbx,%xmm1
  ucomisd D3(%rip),%xmm1
  jp     L48
  jne    L48
  mov    %rcx,0x10(%rsp)
  jmp    L4
L100:
  mov    $0x1,%eax
  sub    %ebp,%eax
  mov    %eax,(%r14)
  jmp    L74
L48:
  mov    0x10(%rsp),%rax
  cmp    %rax,%rcx
  jbe    L4
L95:
  lea    0x1(%rax),%rdx
  mov    %rdx,0x10(%rsp)
  movb   $0x30,(%rax)
  mov    0x10(%rsp),%rax
  cmp    %rcx,%rax
  jb     L95
L4:
  mov    0x10(%rsp),%rax
  sub    %rsi,%rax
  mov    %eax,(%r12)
  mov    0x18(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L130
  mov    %rsi,%rax
  add    $0x28,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
L99:
  pxor   %xmm0,%xmm0
  movq   %rbx,%xmm4
  comisd %xmm4,%xmm0
  ja     L46
  movb   $0x0,(%rax)
  lea    0xc(%rsp),%rcx
  lea    0x10(%rsp),%r8
  mov    %r14,%rdx
  mov    %ebp,%esi
  mov    $0x3,%edi
  movq   %rbx,%xmm0
  mov    $0x1,%eax
  call   <__dtoa@plt>
  movslq %eax,%rsi
  movslq %ebp,%rcx
  add    %rsi,%rcx
L179:
  cmpb   $0x30,(%rsi)
  jne    L74
  movq   %rbx,%xmm5
  ucomisd D3(%rip),%xmm5
  setp   %al
  mov    $0x1,%edx
  cmovne %edx,%eax
  test   %al,%al
  jne    L100
L74:
  movslq (%r14),%rax
  add    %rax,%rcx
  jmp    L34
L130:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: parse_data
arguments: data_tag: D25
type_guessed: byte[16]
name: parse_data
arguments: data_tag: D3
type_guessed: byte[8]

tool: {"D25": [0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00]}

tool: {"D3": [0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00]}

assistant: ```c
char *cvt(value, ndigits, flags, sign, decpt, ch, length)
double value;
int ndigits, flags, *decpt, ch, *length;
char *sign;
{
  int mode, dsgn;
  char *digits, *bp, *rve;
  if (ch == 'f') {
    mode = 3;
  } else {
    if (ch == 'e' || ch == 'E') {
      ndigits++;
    }
    mode = 2;
  }
  if (value < 0) {
    value = -value;
    *sign = '-';
  } else
    *sign = '\000';
  digits = __dtoa(value, mode, ndigits, decpt, &dsgn, &rve);
  if ((ch != 'g' && ch != 'G') || flags & 0x001) {
    bp = digits + ndigits;
    if (ch == 'f') {
      if (*digits == '0' && value)
        *decpt = -ndigits + 1;
      bp += *decpt;
    }
    if (value == 0)
      rve = bp;
    while (rve < bp)
      *rve++ = '0';
  }
  *length = rve - digits;
  return (digits);
}
```