user: 请从给定的汇编指令推导出C源代码：

```asm
<floating>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x40,%rsp
  mov    %rdi,-0x28(%rbp)
  mov    %rsi,-0x30(%rbp)
  cmpq   $0x0,-0x28(%rbp)
  je     L51
  mov    -0x28(%rbp),%rax
  movzbl (%rax),%eax
  test   %al,%al
  je     L51
  mov    -0x28(%rbp),%rax
  mov    %rax,%rdi
  call   <strlen@plt>
  cmp    $0x2,%eax
  jbe    L18
L51:
  mov    $0x0,%eax
  jmp    L144
L18:
  mov    -0x28(%rbp),%rax
  mov    %rax,%rdi
  call   <strlen@plt>
  cmp    $0x1,%eax
  jne    L211
  movb   $0x68,-0x1a(%rbp)
  mov    -0x28(%rbp),%rax
  movzbl (%rax),%eax
  mov    %al,-0x19(%rbp)
  jmp    L231
L211:
  mov    -0x28(%rbp),%rax
  movzbl (%rax),%eax
  mov    %al,-0x1a(%rbp)
  mov    -0x28(%rbp),%rax
  movzbl 0x1(%rax),%eax
  mov    %al,-0x19(%rbp)
L231:
  cmpb   $0x66,-0x19(%rbp)
  jne    L67
  lea    D8(%rip),%rax
  mov    %rax,-0x18(%rbp)
  jmp    L154
L67:
  cmpb   $0x65,-0x19(%rbp)
  jne    L143
  lea    D32(%rip),%rax
  mov    %rax,-0x18(%rbp)
  jmp    L154
L143:
  mov    $0x0,%eax
  jmp    L144
L154:
  cmpb   $0x68,-0x1a(%rbp)
  jne    L106
  mov    -0x30(%rbp),%rax
  movss  (%rax),%xmm0
  movss  %xmm0,-0x38(%rbp)
  flds   -0x38(%rbp)
  mov    -0x18(%rbp),%rax
  lea    -0x10(%rsp),%rsp
  fstpt  (%rsp)
  mov    $0x7,%edx
  mov    %rax,%rsi
  lea    D28(%rip),%rax
  mov    %rax,%rdi
  call   <sprintf@plt>
  add    $0x10,%rsp
  jmp    L228
L106:
  cmpb   $0x6c,-0x1a(%rbp)
  jne    L224
  mov    -0x30(%rbp),%rax
  movsd  (%rax),%xmm1
  movsd  %xmm1,-0x38(%rbp)
  fldl   -0x38(%rbp)
  mov    -0x18(%rbp),%rax
  lea    -0x10(%rsp),%rsp
  fstpt  (%rsp)
  mov    $0xd,%edx
  mov    %rax,%rsi
  lea    D28(%rip),%rax
  mov    %rax,%rdi
  call   <sprintf@plt>
  add    $0x10,%rsp
  jmp    L228
L224:
  cmpb   $0x4c,-0x1a(%rbp)
  jne    L176
  mov    -0x30(%rbp),%rax
  fldt   (%rax)
  mov    -0x18(%rbp),%rax
  lea    -0x10(%rsp),%rsp
  fstpt  (%rsp)
  mov    $0xd,%edx
  mov    %rax,%rsi
  lea    D28(%rip),%rax
  mov    %rax,%rdi
  call   <sprintf@plt>
  add    $0x10,%rsp
  jmp    L228
L176:
  mov    $0x0,%eax
  jmp    L144
L228:
  mov    $0x2e,%esi
  lea    D28(%rip),%rax
  mov    %rax,%rdi
  call   <strchr@plt>
  mov    %rax,-0x10(%rbp)
  cmpq   $0x0,-0x10(%rbp)
  jne    L181
  lea    D28(%rip),%rax
  jmp    L144
L181:
  addq   $0x2,-0x10(%rbp)
  mov    -0x10(%rbp),%rax
  mov    %rax,-0x8(%rbp)
  jmp    L127
L137:
  mov    -0x10(%rbp),%rax
  movzbl (%rax),%eax
  cmp    $0x30,%al
  je     L223
  mov    -0x10(%rbp),%rax
  add    $0x1,%rax
  mov    %rax,-0x8(%rbp)
L223:
  addq   $0x1,-0x10(%rbp)
L127:
  mov    -0x10(%rbp),%rax
  movzbl (%rax),%eax
  movsbl %al,%eax
  mov    %eax,%edi
  call   <isdigit@plt>
  test   %rax,%rax
  jne    L137
  nop
L39:
  mov    -0x10(%rbp),%rdx
  lea    0x1(%rdx),%rax
  mov    %rax,-0x10(%rbp)
  mov    -0x8(%rbp),%rax
  lea    0x1(%rax),%rcx
  mov    %rcx,-0x8(%rbp)
  movzbl (%rdx),%edx
  mov    %dl,(%rax)
  movzbl (%rax),%eax
  test   %al,%al
  jne    L39
  lea    D28(%rip),%rax
L144:
  leave
  ret
```

tool_calls: name: parse_data
arguments: label: D8
type_guessed: string
name: parse_data
arguments: label: D32
type_guessed: string

tool: D8: %#.*G

tool: D32: %#.*E

assistant: ```c
char *floating(char *type, void *value) {
  static char str[80];
  char len, chr, *fmt, *srce, *dest;
  if (!type || !*type || strlen(type) > (size_t)2)
    return NULL;
  else if (strlen(type) == 1) {
    len = 'h';
    chr = *type;
  } else {
    len = type[0];
    chr = type[1];
  }
  if (chr == 'f')
    fmt = "%#.*G";
  else if (chr == 'e')
    fmt = "%#.*E";
  else
    return NULL;
  if (len == 'h')
    sprintf(str, fmt, 7, *((float *)value));
  else if (len == 'l')
    sprintf(str, fmt, 13, *((double *)value));
  else if (len == 'L')
    sprintf(str, fmt, 13, *((long double *)value));
  else
    return NULL;
  if (!(srce = strchr(str, '.')))
    return str;
  for (dest = srce += 2; isdigit(*srce); ++srce)
    if (*srce != '0')
      dest = srce + 1;
  while (*dest++ = *srce++)
    ;
  return str;
}
```