user: What is the c source code of the assembly code below:

```asm
<__format_uint>:
  endbr64
  sub    $0x28,%rsp
  mov    %esi,%r10d
  mov    %edi,%r8d
  mov    $0x8,%ecx
  mov    %fs:0x28,%rax
  mov    %rax,0x18(%rsp)
  xor    %eax,%eax
  and    $0x20,%r10d
  jne    L20
  mov    %esi,%eax
  and    $0x40,%eax
  cmp    $0x1,%eax
  sbb    %ecx,%ecx
  and    $0xfffffffa,%ecx
  add    $0x10,%ecx
L20:
  test   %r8d,%r8d
  je     L147
  mov    %esi,%r11d
  lea    D42(%rip),%rax
  movb   $0x0,0xf(%rsp)
  lea    D12(%rip),%rdi
  and    $0x10,%r11d
  cmove  %rax,%rdi
  mov    %r8d,%eax
  xor    %edx,%edx
  div    %ecx
  mov    %eax,%r9d
  movzbl (%rdi,%rdx,1),%eax
  mov    %al,0xe(%rsp)
  cmp    %ecx,%r8d
  jb     L229
  mov    %r9d,%eax
  xor    %edx,%edx
  div    %ecx
  mov    %eax,%r8d
  movzbl (%rdi,%rdx,1),%eax
  mov    %al,0xd(%rsp)
  cmp    %r9d,%ecx
  ja     L96
  mov    %r8d,%eax
  xor    %edx,%edx
  div    %ecx
  mov    %eax,%r9d
  movzbl (%rdi,%rdx,1),%eax
  mov    %al,0xc(%rsp)
  cmp    %ecx,%r8d
  jb     L235
  mov    %r9d,%eax
  xor    %edx,%edx
  div    %ecx
  mov    %eax,%r8d
  movzbl (%rdi,%rdx,1),%eax
  mov    %al,0xb(%rsp)
  cmp    %ecx,%r9d
  jb     L108
  mov    %r8d,%eax
  xor    %edx,%edx
  div    %ecx
  mov    %eax,%r9d
  movzbl (%rdi,%rdx,1),%eax
  mov    %al,0xa(%rsp)
  cmp    %r8d,%ecx
  ja     L33
  mov    %r9d,%eax
  xor    %edx,%edx
  div    %ecx
  mov    %eax,%r8d
  movzbl (%rdi,%rdx,1),%eax
  mov    %al,0x9(%rsp)
  cmp    %r9d,%ecx
  ja     L133
  mov    %r8d,%eax
  xor    %edx,%edx
  div    %ecx
  mov    %eax,%r9d
  movzbl (%rdi,%rdx,1),%eax
  mov    %al,0x8(%rsp)
  cmp    %r8d,%ecx
  ja     L85
  mov    %r9d,%eax
  xor    %edx,%edx
  div    %ecx
  mov    %eax,%r8d
  movzbl (%rdi,%rdx,1),%eax
  mov    %al,0x7(%rsp)
  cmp    %r9d,%ecx
  ja     L205
  mov    %r8d,%eax
  xor    %edx,%edx
  div    %ecx
  mov    %eax,%r9d
  movzbl (%rdi,%rdx,1),%eax
  mov    %al,0x6(%rsp)
  cmp    %r8d,%ecx
  ja     L272
  mov    %r9d,%eax
  xor    %edx,%edx
  div    %ecx
  movzbl (%rdi,%rdx,1),%edx
  mov    %dl,0x5(%rsp)
  cmp    %r9d,%ecx
  ja     L49
  mov    %eax,%eax
  mov    $0x3,%edx
  movzbl (%rdi,%rax,1),%eax
  mov    %al,0x4(%rsp)
  mov    $0x4,%eax
L214:
  test   $0x1,%sil
  je     L228
  movslq %edx,%rax
  movb   $0x2b,(%rsp,%rax,1)
  movslq %edx,%rax
L228:
  lea    (%rsp,%rax,1),%rdi
  test   $0x4,%sil
  je     L244
  test   %r10d,%r10d
  jne    L103
  and    $0x40,%esi
  jne    L152
L244:
  call   <strdup@plt>
L90:
  mov    0x18(%rsp),%rdx
  sub    %fs:0x28,%rdx
  jne    L102
  add    $0x28,%rsp
  ret
  nopl   0x0(%rax)
L147:
  mov    0x18(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L102
  lea    D21(%rip),%rdi
  add    $0x28,%rsp
  jmp    1090 <strdup@plt>
  nopl   0x0(%rax)
L152:
  test   %r11d,%r11d
  lea    D31(%rip),%r8
  lea    D19(%rip),%rax
  mov    %rdi,%rsi
  cmove  %rax,%r8
  xor    %edx,%edx
  mov    %r8,%rdi
  call   <strvcat@plt>
  jmp    L90
  nopl   0x0(%rax)
L103:
  mov    %rdi,%rsi
  xor    %edx,%edx
  lea    D21(%rip),%rdi
  call   <strvcat@plt>
  jmp    L90
L205:
  mov    $0x7,%eax
  mov    $0x6,%edx
  jmp    L214
L229:
  mov    $0xe,%eax
  mov    $0xd,%edx
  jmp    L214
L96:
  mov    $0xd,%eax
  mov    $0xc,%edx
  jmp    L214
L235:
  mov    $0xc,%eax
  mov    $0xb,%edx
  jmp    L214
L108:
  mov    $0xb,%eax
  mov    $0xa,%edx
  jmp    L214
L33:
  mov    $0xa,%eax
  mov    $0x9,%edx
  jmp    L214
L133:
  mov    $0x9,%eax
  mov    $0x8,%edx
  jmp    L214
L85:
  mov    $0x8,%eax
  mov    $0x7,%edx
  jmp    L214
L272:
  mov    $0x6,%eax
  mov    $0x5,%edx
  jmp    L214
L49:
  mov    $0x5,%eax
  mov    $0x4,%edx
  jmp    L214
L102:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: read_data
arguments: data_label: D42
type_guessed: string
name: read_data
arguments: data_label: D12
type_guessed: string
name: read_data
arguments: data_label: D21
type_guessed: string
name: read_data
arguments: data_label: D31
type_guessed: string
name: read_data
arguments: data_label: D19
type_guessed: string

tool: D42: 0123456789abcdef

tool: D12: 0123456789ABCDEF

tool: D21: 0

tool: D31: 0X

tool: D19: 0x

assistant: ```c
char *__format_uint(unsigned int value, int flags) {
  char buffer[16];
  int i;
  int base;
  const char *digits_lower = "0123456789abcdef";
  const char *digits_upper = "0123456789ABCDEF";
  const char *digits;
  if (flags & 0x20)
    base = 8;
  else if (flags & 0x40)
    base = 16;
  else
    base = 10;
  if (value == 0) {
    return strdup("0");
  }
  if (flags & 0x10) {
    digits = digits_upper;
  } else {
    digits = digits_lower;
  }
  buffer[15] = '\0';
  for (i = 14; i >= 0; i--) {
    if (!value)
      break;
    buffer[i] = digits[value % base];
    value /= base;
  }
  if (flags & 0x01) {
    buffer[i--] = '+';
  }
  i++;
  if (flags & 0x04) {
    if (flags & 0x20) {
      return strvcat("0", &buffer[i], NULL);
    }
    if (flags & 0x40) {
      return strvcat((flags & 0x10) ? "0X" : "0x", &buffer[i], NULL);
    }
  }
  return strdup(&buffer[i]);
}
```