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

```asm
<dumpdata>:
  endbr64
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x28,%rsp
  mov    %rdi,%rbp
  mov    %rsi,0x10(%rsp)
  lea    (%rcx,%r8,1),%rax
  mov    %rax,0x8(%rsp)
  cmp    %rax,%rcx
  jae    L81
  mov    %rcx,%r13
  lea    (%rdx,%rdx,1),%eax
  mov    %eax,0x1c(%rsp)
  lea    D0(%rip),%r14
  lea    D24(%rip),%r15
  jmp    L44
L54:
  mov    %rbp,%rsi
  mov    $0x2e,%edi
  call   <fputc@plt>
L88:
  add    $0x1,%rbx
  cmp    %r12,%rbx
  jae    L16
L134:
  movzbl 0x0(%r13,%rbx,1),%edi
  lea    -0x20(%rdi),%eax
  cmp    $0x5e,%al
  ja     L54
  movzbl %dil,%edi
  mov    %rbp,%rsi
  call   <fputc@plt>
  jmp    L88
L16:
  mov    %rbp,%rsi
  mov    $0xa,%edi
  call   <fputc@plt>
  add    $0x10,%r13
  cmp    %r13,0x8(%rsp)
  jbe    L81
L44:
  mov    0x8(%rsp),%r12
  sub    %r13,%r12
  cmp    $0xf,%r12
  ja     L91
  lea    D3(%rip),%r8
  mov    0x1c(%rsp),%ecx
  mov    0x10(%rsp),%rdx
  lea    D38(%rip),%rsi
  mov    %rbp,%rdi
  mov    $0x0,%eax
  call   <fprintf@plt>
  test   %r12,%r12
  jne    L18
  mov    %r12,%rbx
  jmp    L109
L81:
  mov    %rbp,%rdi
  call   <fflush@plt>
  add    $0x28,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
L10:
  mov    %rbp,%rcx
  mov    $0x2,%edx
  mov    $0x1,%esi
  mov    %r14,%rdi
  call   <fwrite@plt>
  jmp    L141
L91:
  lea    D3(%rip),%r8
  mov    0x1c(%rsp),%ecx
  mov    0x10(%rsp),%rdx
  lea    D38(%rip),%rsi
  mov    %rbp,%rdi
  mov    $0x0,%eax
  call   <fprintf@plt>
  mov    $0x10,%r12d
L18:
  mov    $0x0,%ebx
L25:
  movzbl 0x0(%r13,%rbx,1),%edx
  mov    %r15,%rsi
  mov    %rbp,%rdi
  mov    $0x0,%eax
  call   <fprintf@plt>
  add    $0x1,%rbx
  cmp    %r12,%rbx
  jb     L25
  test   %r12,%r12
  mov    $0x1,%ebx
  cmovne %r12,%rbx
  cmp    $0xf,%rbx
  ja     L10
L109:
  mov    %rbp,%rcx
  mov    $0x2,%edx
  mov    $0x1,%esi
  mov    %r14,%rdi
  call   <fwrite@plt>
  add    $0x1,%rbx
  cmp    $0xf,%rbx
  jbe    L109
  mov    %rbp,%rcx
  mov    $0x2,%edx
  mov    $0x1,%esi
  mov    %r14,%rdi
  call   <fwrite@plt>
  test   %r12,%r12
  je     L16
L141:
  mov    $0x0,%ebx
  jmp    L134
```

tool_calls: name: retrieve_data
arguments: data_label: D0
type: string
name: retrieve_data
arguments: data_label: D24
type: string
name: retrieve_data
arguments: data_label: D3
type: string
name: retrieve_data
arguments: data_label: D38
type: string

tool: D0:   

tool: D24: %02x

tool: 

tool: D38: %s%*s  

assistant: ```c
void dumpdata(FILE *stream, const char *leader, unsigned int depth, const unsigned char *data, size_t len) {
  const unsigned char *dataend = data + len;
  const unsigned char *p;
  const size_t rowsize = 16;
  for (p = data; p < dataend; p += rowsize) {
    size_t amt = rowsize;
    size_t i;
    if (amt > (dataend - p))
      amt = (dataend - p);
    fprintf(stream, "%s%*s  ", leader, 2 * depth, "");
    for (i = 0; i < amt; ++i) {
      fprintf(stream, "%02x", p[i]);
    }
    for (; i < rowsize; ++i) {
      fprintf(stream, "  ");
    }
    fprintf(stream, "  ");
    for (i = 0; i < amt; ++i) {
      if (p[i] >= ' ' && p[i] <= '~') {
        fprintf(stream, "%c", p[i]);
      } else {
        fprintf(stream, ".");
      }
    }
    fprintf(stream, "\n");
  }
  fflush(stream);
}
```