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

```asm
<DumpHex>:
  endbr64
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x38,%rsp
  mov    %fs:0x28,%rax
  mov    %rax,0x28(%rsp)
  xor    %eax,%eax
  test   %edx,%edx
  je     L51
  lea    -0x1(%rdx),%eax
  mov    %rdi,%r13
  mov    %rsi,%rbx
  xor    %ebp,%ebp
  lea    0x4(%rsi,%rax,4),%rax
  mov    %rax,0x8(%rsp)
  jmp    L7
  nopl   0x0(%rax)
L120:
  cmp    $0x8,%ebp
  je     L125
  mov    %ebp,0x4(%rsp)
  add    $0x1,%ebp
L69:
  mov    (%rbx),%r12d
  movsbl %r12b,%r14d
  mov    %r12d,%r15d
  mov    %r14d,%edi
  call   <isprint@plt>
  test   %rax,%rax
  je     L127
  cmp    $0x20,%r12b
  je     L14
  mov    %r14d,%edi
  call   <isspace@plt>
  test   %eax,%eax
  je     L14
  nopl   0x0(%rax)
L127:
  mov    $0x2e,%r15d
L14:
  mov    0x4(%rsp),%r12d
  mov    (%rbx),%edx
  lea    D20(%rip),%rsi
  xor    %eax,%eax
  mov    %r13,%rdi
  add    $0x4,%rbx
  mov    %r15b,0x10(%rsp,%r12,1)
  call   <fprintf@plt>
  cmp    %rbx,0x8(%rsp)
  je     L11
L7:
  cmp    $0x11,%ebp
  jne    L120
  lea    0x10(%rsp),%rdx
  mov    %r13,%rdi
  xor    %eax,%eax
  movb   $0x0,0x21(%rsp)
  lea    D44(%rip),%rsi
  mov    $0x1,%ebp
  call   <fprintf@plt>
  movl   $0x0,0x4(%rsp)
  jmp    L69
  nopl   0x0(%rax,%rax,1)
L125:
  mov    %r13,%rsi
  mov    $0x20,%edi
  movb   $0x20,0x18(%rsp)
  mov    $0xa,%ebp
  call   <fputc@plt>
  movl   $0x9,0x4(%rsp)
  jmp    L69
  nopl   0x0(%rax)
L11:
  test   %ebp,%ebp
  je     L51
  mov    %ebp,%eax
  movb   $0x0,0x10(%rsp,%rax,1)
  cmp    $0x10,%ebp
  ja     L48
  lea    D21(%rip),%rbx
  lea    D36(%rip),%r12
L98:
  cmp    $0x8,%ebp
  jne    L17
  mov    %r13,%rcx
  mov    $0x4,%edx
  mov    $0x1,%esi
  mov    %r12,%rdi
  movb   $0x20,0x18(%rsp)
  mov    $0xc,%ebp
  call   <fwrite@plt>
  mov    %r13,%rcx
  mov    $0x3,%edx
  mov    %rbx,%rdi
  mov    $0x1,%esi
  call   <fwrite@plt>
  mov    %r13,%rcx
  mov    $0x3,%edx
  mov    %rbx,%rdi
  mov    $0x1,%esi
  call   <fwrite@plt>
L17:
  mov    %r13,%rcx
  mov    $0x3,%edx
  mov    $0x1,%esi
  mov    %rbx,%rdi
  call   <fwrite@plt>
  add    $0x1,%ebp
  cmp    $0x11,%ebp
  jne    L98
L48:
  lea    0x10(%rsp),%rdx
  lea    D44(%rip),%rsi
  mov    %r13,%rdi
  xor    %eax,%eax
  call   <fprintf@plt>
L51:
  mov    0x28(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L106
  add    $0x38,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
L106:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: retrieve_data
arguments: data_label: D20
type_infered: string
name: retrieve_data
arguments: data_label: D44
type_infered: string
name: retrieve_data
arguments: data_label: D21
type_infered: string
name: retrieve_data
arguments: data_label: D36
type_infered: string

tool: D20: %02X 

tool: D44:   %s


tool: D21:    

tool: D36:     

assistant: ```c
void DumpHex(FILE *fp, const uint8_t *data, unsigned len) {
  char str[18];
  unsigned i;
  unsigned pos;
  char c;
  for (i = 0, pos = 0; i < len; i++, pos++) {
    if (pos == 17) {
      str[pos] = 0;
      fprintf(fp, "  %s\n", str);
      pos = 0;
    } else if (pos == 8) {
      str[pos] = ' ';
      pos++;
      fprintf(fp, "%s", " ");
    }
    c = (char)data[i];
    if (isprint(c) && (c == ' ' || !isspace(c)))
      str[pos] = c;
    else
      str[pos] = '.';
    fprintf(fp, "%02X ", data[i]);
  }
  if (pos) {
    str[pos] = 0;
    for (; pos < 17; pos++) {
      if (pos == 8) {
        str[pos] = ' ';
        pos++;
        fprintf(fp, "%s", "    ");
      } else {
        fprintf(fp, "%s", "   ");
      }
    }
    fprintf(fp, "  %s\n", str);
  }
}
```