user: Please show me the C implementation that matches the assembly code listed below:

```asm
<ft_putnbr_fd>:
  endbr64
  push   %r15
  mov    %esi,%r15d
  push   %r14
  mov    %edi,%r14d
  push   %r13
  mov    $0xcccccccd,%r13d
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x68,%rsp
  cmp    $0x80000000,%edi
  jne    L39
  jmp    L6
  nop
L93:
  cmp    $0x9,%r14d
  jle    L13
L78:
  mov    %r14d,%eax
  mov    %rax,0x58(%rsp)
  imul   %r13,%rax
  shr    $0x23,%rax
  mov    %eax,0x20(%rsp)
  cmp    $0x63,%r14d
  jle    L96
  mov    %eax,%eax
  mov    %rax,0x30(%rsp)
  imul   %r13,%rax
  shr    $0x23,%rax
  mov    %eax,0x24(%rsp)
  cmp    $0x3e7,%r14d
  jle    L10
  mov    %eax,%eax
  mov    %rax,0x38(%rsp)
  imul   %r13,%rax
  shr    $0x23,%rax
  mov    %eax,0x28(%rsp)
  cmp    $0x270f,%r14d
  jle    L15
  mov    %eax,%eax
  mov    %rax,0x40(%rsp)
  imul   %r13,%rax
  shr    $0x23,%rax
  mov    %eax,0x2c(%rsp)
  cmp    $0x1869f,%r14d
  jle    L115
  mov    %eax,%eax
  mov    %rax,0x50(%rsp)
  imul   %r13,%rax
  mov    %rax,%r12
  shr    $0x23,%r12
  cmp    $0xf423f,%r14d
  jle    L62
  mov    %r12d,%eax
  mov    %rax,%rbx
  mov    %rax,0x10(%rsp)
  imul   %r13,%rbx
  shr    $0x23,%rbx
  cmp    $0x98967f,%r14d
  jle    L111
  mov    %ebx,%eax
  mov    %rax,%rbp
  mov    %rax,0x8(%rsp)
  imul   %r13,%rbp
  shr    $0x23,%rbp
  cmp    $0x5f5e0ff,%r14d
  jle    L55
  mov    %ebp,%eax
  mov    %rax,0x48(%rsp)
  imul   %r13,%rax
  mov    %rax,%rdx
  shr    $0x23,%rdx
  cmp    $0x3b9ac9ff,%r14d
  jle    L70
  mov    %edx,%eax
  mov    %r15d,%esi
  mov    %edx,0x1c(%rsp)
  imul   %r13,%rax
  shr    $0x23,%rax
  mov    %eax,%edi
  mov    %eax,0x18(%rsp)
  call   <ft_putnbr_fd>
  mov    0x18(%rsp),%eax
  mov    0x1c(%rsp),%edx
  lea    (%rax,%rax,4),%eax
  add    %eax,%eax
  sub    %eax,%edx
L70:
  lea    0x30(%rdx),%edi
  mov    %r15d,%esi
  call   <ft_putchar_fd@plt>
  mov    0x48(%rsp),%rax
  imul   %r13,%rax
  shr    $0x23,%rax
  lea    (%rax,%rax,4),%eax
  add    %eax,%eax
  sub    %eax,%ebp
L55:
  lea    0x30(%rbp),%edi
  mov    %r15d,%esi
  call   <ft_putchar_fd@plt>
  mov    0x8(%rsp),%rax
  imul   %r13,%rax
  shr    $0x23,%rax
  lea    (%rax,%rax,4),%eax
  add    %eax,%eax
  sub    %eax,%ebx
L111:
  lea    0x30(%rbx),%edi
  mov    %r15d,%esi
  call   <ft_putchar_fd@plt>
  mov    0x10(%rsp),%rax
  imul   %r13,%rax
  shr    $0x23,%rax
  lea    (%rax,%rax,4),%eax
  add    %eax,%eax
  sub    %eax,%r12d
L62:
  lea    0x30(%r12),%edi
  mov    %r15d,%esi
  call   <ft_putchar_fd@plt>
  mov    0x50(%rsp),%rax
  imul   %r13,%rax
  shr    $0x23,%rax
  lea    (%rax,%rax,4),%eax
  add    %eax,%eax
  sub    %eax,0x2c(%rsp)
L115:
  mov    0x2c(%rsp),%edi
  mov    %r15d,%esi
  add    $0x30,%edi
  call   <ft_putchar_fd@plt>
  mov    0x40(%rsp),%rax
  imul   %r13,%rax
  shr    $0x23,%rax
  lea    (%rax,%rax,4),%eax
  add    %eax,%eax
  sub    %eax,0x28(%rsp)
L15:
  mov    0x28(%rsp),%edi
  mov    %r15d,%esi
  add    $0x30,%edi
  call   <ft_putchar_fd@plt>
  mov    0x38(%rsp),%rax
  imul   %r13,%rax
  shr    $0x23,%rax
  lea    (%rax,%rax,4),%eax
  add    %eax,%eax
  sub    %eax,0x24(%rsp)
L10:
  mov    0x24(%rsp),%edi
  mov    %r15d,%esi
  add    $0x30,%edi
  call   <ft_putchar_fd@plt>
  mov    0x30(%rsp),%rax
  imul   %r13,%rax
  shr    $0x23,%rax
  lea    (%rax,%rax,4),%eax
  add    %eax,%eax
  sub    %eax,0x20(%rsp)
L96:
  mov    0x20(%rsp),%edi
  mov    %r15d,%esi
  add    $0x30,%edi
  call   <ft_putchar_fd@plt>
  mov    0x58(%rsp),%rax
  imul   %r13,%rax
  shr    $0x23,%rax
  lea    (%rax,%rax,4),%eax
  add    %eax,%eax
  sub    %eax,%r14d
L39:
  test   %r14d,%r14d
  jns    L93
  mov    %r15d,%esi
  mov    $0x2d,%edi
  neg    %r14d
  call   <ft_putchar_fd@plt>
  cmp    $0x9,%r14d
  jg     L78
L13:
  add    $0x68,%rsp
  lea    0x30(%r14),%edi
  mov    %r15d,%esi
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  jmp    1070 <ft_putchar_fd@plt>
L6:
  add    $0x68,%rsp
  lea    D4(%rip),%rdi
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  jmp    1060 <ft_putstr_fd@plt>
```

tool_calls: name: retrieve_data
arguments: data_label: D4
data_type: string

tool: D4: -2147483648

assistant: ```c
void ft_putnbr_fd(int n, int fd) {
  if (n == -2147483648) {
    ft_putstr_fd("-2147483648", fd);
    return;
  }
  if (n < 0) {
    ft_putchar_fd('-', fd);
    n = -n;
  }
  if (n >= 10) {
    ft_putnbr_fd(n / 10, fd);
    ft_putnbr_fd(n % 10, fd);
    return;
  }
  ft_putchar_fd(n + '0', fd);
}
```