user: Demonstrate the C code that generates the assembly output below:

```asm
<ki_dump>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x20,%rsp
  mov    %rdi,-0x18(%rbp)
  mov    %esi,-0x1c(%rbp)
  mov    %edx,-0x20(%rbp)
  mov    -0x18(%rbp),%rax
  movzbl (%rax),%eax
  movzbl %al,%eax
  and    $0xf,%eax
  mov    %eax,-0x8(%rbp)
  cmpl   $0x0,-0x8(%rbp)
  jne    L68
  mov    -0x1c(%rbp),%eax
  lea    -0x1(%rax),%esi
  mov    -0x18(%rbp),%rax
  lea    0x1(%rax),%rcx
  mov    -0x20(%rbp),%eax
  mov    %eax,%edx
  mov    %rcx,%rdi
  call   <ax25_dump@plt>
  jmp    L87
L68:
  mov    -0x18(%rbp),%rax
  add    $0x1,%rax
  movzbl (%rax),%eax
  movzbl %al,%eax
  mov    %eax,-0x4(%rbp)
  cmpl   $0xf,-0x8(%rbp)
  ja     L101
  mov    -0x8(%rbp),%eax
  lea    0x0(,%rax,4),%rdx
  lea    D14(%rip),%rax
  mov    (%rdx,%rax,1),%eax
  cltq
  lea    D14(%rip),%rdx
  add    %rdx,%rax
  notrack jmp *%rax
  mov    -0x4(%rbp),%eax
  movslq %eax,%rdx
  mov    %rdx,%rax
  shl    $0x2,%rax
  add    %rdx,%rax
  add    %rax,%rax
  mov    %rax,%rdx
  lea    D71(%rip),%rax
  mov    %rax,%rsi
  mov    $0x3,%edi
  mov    $0x0,%eax
  call   <lprintf@plt>
  jmp    L87
  mov    -0x4(%rbp),%eax
  add    $0x1,%eax
  mov    %eax,%edx
  lea    D75(%rip),%rax
  mov    %rax,%rsi
  mov    $0x3,%edi
  mov    $0x0,%eax
  call   <lprintf@plt>
  jmp    L87
  mov    -0x4(%rbp),%eax
  movslq %eax,%rdx
  mov    %rdx,%rax
  shl    $0x2,%rax
  add    %rdx,%rax
  add    %rax,%rax
  mov    %rax,%rdx
  lea    D39(%rip),%rax
  mov    %rax,%rsi
  mov    $0x3,%edi
  mov    $0x0,%eax
  call   <lprintf@plt>
  jmp    L87
  mov    -0x4(%rbp),%eax
  movslq %eax,%rdx
  mov    %rdx,%rax
  shl    $0x2,%rax
  add    %rdx,%rax
  add    %rax,%rax
  mov    %rax,%rdx
  lea    D0(%rip),%rax
  mov    %rax,%rsi
  mov    $0x3,%edi
  mov    $0x0,%eax
  call   <lprintf@plt>
  jmp    L87
  cmpl   $0x0,-0x4(%rbp)
  jne    L37
  lea    D100(%rip),%rax
  jmp    L106
L37:
  lea    D8(%rip),%rax
L106:
  mov    %rax,%rdx
  lea    D13(%rip),%rax
  mov    %rax,%rsi
  mov    $0x3,%edi
  mov    $0x0,%eax
  call   <lprintf@plt>
  jmp    L87
  mov    -0x4(%rbp),%eax
  mov    %eax,%edx
  lea    D63(%rip),%rax
  mov    %rax,%rsi
  mov    $0x3,%edi
  mov    $0x0,%eax
  call   <lprintf@plt>
  jmp    L87
  lea    D41(%rip),%rax
  mov    %rax,%rsi
  mov    $0x3,%edi
  mov    $0x0,%eax
  call   <lprintf@plt>
  jmp    L87
L101:
  mov    -0x4(%rbp),%edx
  mov    -0x8(%rbp),%eax
  mov    %edx,%ecx
  mov    %eax,%edx
  lea    D16(%rip),%rax
  mov    %rax,%rsi
  mov    $0x3,%edi
  mov    $0x0,%eax
  call   <lprintf@plt>
  nop
L87:
  leave
  ret
```

tool_calls: name: unpack_data
arguments: tag: D71
type: string
name: unpack_data
arguments: tag: D75
type: string
name: unpack_data
arguments: tag: D39
type: string
name: unpack_data
arguments: tag: D0
type: string
name: unpack_data
arguments: tag: D100
type: string
name: unpack_data
arguments: tag: D8
type: string
name: unpack_data
arguments: tag: D13
type: string
name: unpack_data
arguments: tag: D63
type: string
name: unpack_data
arguments: tag: D41
type: string
name: unpack_data
arguments: tag: D16
type: string

tool: D71: TX Delay: %lu ms


tool: D75: Persistence: %u/256


tool: D39: Slot time: %lu ms


tool: D0: TX Tail time: %lu ms


tool: D100: Half

tool: D8: Full

tool: D13: Duplex: %s


tool: D63: Hardware %u


tool: D41: RETURN


tool: D16: code %u arg %u


assistant: ```c
void ki_dump(unsigned char *data, int length, int hexdump) {
  int type;
  int val;
  type = data[0] & 0xf;
  if (type == 0) {
    ax25_dump(data + 1, length - 1, hexdump);
    return;
  }
  val = data[1];
  switch (type) {
  case 1:
    lprintf(3, "TX Delay: %lu ms\n", val * 10L);
    break;
  case 2:
    lprintf(3, "Persistence: %u/256\n", val + 1);
    break;
  case 3:
    lprintf(3, "Slot time: %lu ms\n", val * 10L);
    break;
  case 4:
    lprintf(3, "TX Tail time: %lu ms\n", val * 10L);
    break;
  case 5:
    lprintf(3, "Duplex: %s\n", val == 0 ? "Half" : "Full");
    break;
  case 6:
    lprintf(3, "Hardware %u\n", val);
    break;
  case 15:
    lprintf(3, "RETURN\n");
    break;
  default:
    lprintf(3, "code %u arg %u\n", type, val);
    break;
  }
}
```