user: 请显示与下面列出的汇编代码相匹配的C语言实现：

```asm
<misc_getuptimestr>:
  endbr64
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x40,%rsp
  mov    %rdi,%rbp
  mov    %esi,%r12d
  mov    %edx,%r13d
  mov    %fs:0x28,%rax
  mov    %rax,0x38(%rsp)
  xor    %eax,%eax
  lea    0xc(%rsp),%rdi
  call   <time@plt>
  mov    0xc(%rsp),%ebx
  sub    %r13d,%ebx
  mov    %r12d,%edx
  mov    $0x0,%esi
  mov    %rbp,%rdi
  call   <memset@plt>
  cmp    $0x15180,%ebx
  jg     L39
L67:
  cmp    $0xe10,%ebx
  jg     L82
L72:
  cmp    $0x3c,%ebx
  jg     L81
L57:
  test   %ebx,%ebx
  jg     L11
L2:
  mov    0x38(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L18
  mov    %rbp,%rax
  add    $0x40,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  ret
L39:
  movslq %ebx,%r13
  imul   $0xffffffffc22e4507,%r13,%r13
  shr    $0x20,%r13
  add    %ebx,%r13d
  sar    $0x10,%r13d
  mov    %ebx,%eax
  sar    $0x1f,%eax
  sub    %eax,%r13d
  lea    0x10(%rsp),%r14
  mov    %r13d,%ecx
  lea    D17(%rip),%rdx
  mov    $0x1f,%esi
  mov    %r14,%rdi
  call   <snprintf@plt>
  imul   $0x15180,%r13d,%r13d
  sub    %r13d,%ebx
  lea    -0x1(%r12),%edx
  mov    %r14,%rsi
  mov    %rbp,%rdi
  call   <strncpy@plt>
  jmp    L67
L82:
  movslq %ebx,%r13
  imul   $0xffffffff91a2b3c5,%r13,%r13
  shr    $0x20,%r13
  add    %ebx,%r13d
  sar    $0xb,%r13d
  mov    %ebx,%eax
  sar    $0x1f,%eax
  sub    %eax,%r13d
  lea    0x10(%rsp),%r14
  mov    %r13d,%ecx
  lea    D9(%rip),%rdx
  mov    $0x1f,%esi
  mov    %r14,%rdi
  call   <snprintf@plt>
  imul   $0xe10,%r13d,%r13d
  sub    %r13d,%ebx
  lea    -0x1(%r12),%edx
  mov    %r14,%rsi
  mov    %rbp,%rdi
  call   <strncat@plt>
  jmp    L72
L81:
  movslq %ebx,%r13
  imul   $0xffffffff88888889,%r13,%r13
  shr    $0x20,%r13
  add    %ebx,%r13d
  sar    $0x5,%r13d
  mov    %ebx,%eax
  sar    $0x1f,%eax
  sub    %eax,%r13d
  lea    0x10(%rsp),%r14
  mov    %r13d,%ecx
  lea    D1(%rip),%rdx
  mov    $0x1f,%esi
  mov    %r14,%rdi
  call   <snprintf@plt>
  imul   $0x3c,%r13d,%r13d
  sub    %r13d,%ebx
  lea    -0x1(%r12),%edx
  mov    %r14,%rsi
  mov    %rbp,%rdi
  call   <strncat@plt>
  jmp    L57
L11:
  lea    0x10(%rsp),%r13
  mov    %ebx,%ecx
  lea    D16(%rip),%rdx
  mov    $0x1f,%esi
  mov    %r13,%rdi
  call   <snprintf@plt>
  lea    -0x1(%r12),%edx
  mov    %r13,%rsi
  mov    %rbp,%rdi
  call   <strncat@plt>
  jmp    L2
L18:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: unpack_data
arguments: tag: D17
type_guessed: string
name: unpack_data
arguments: tag: D9
type_guessed: string
name: unpack_data
arguments: tag: D1
type_guessed: string
name: unpack_data
arguments: tag: D16
type_guessed: string

tool: D17: %d days 

tool: D9: %d saat 

tool: D1: %d dakika 

tool: D16: %d saniye

assistant: ```c
char *misc_getuptimestr(char *uptime_str, int len, time_t firetime) {
  char fmt[32];
  time_t now;
  time_t diff;
  time(&now);
  diff = now - firetime;
  memset(uptime_str, 0, len);
  if (diff > 86400) {
    snprintf(fmt, 31, "%d days ", (int)(diff / 86400));
    diff -= (diff / 86400) * 86400;
    strncpy(uptime_str, fmt, len - 1);
  }
  if (diff > 3600) {
    snprintf(fmt, 31, "%d saat ", (int)(diff / 3600));
    diff -= (diff / 3600) * 3600;
    strncat(uptime_str, fmt, len - 1);
  }
  if (diff > 60) {
    snprintf(fmt, 31, "%d dakika ", (int)(diff / 60));
    diff -= (diff / 60) * 60;
    strncat(uptime_str, fmt, len - 1);
  }
  if (diff > 0) {
    snprintf(fmt, 31, "%d saniye", (int)diff);
    strncat(uptime_str, fmt, len - 1);
  }
  return uptime_str;
}
```