user: Please show me the C implementation that matches the assembly code listed below:

```asm
<main>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x10,%rsp
  mov    %edi,-0x4(%rbp)
  mov    %rsi,-0x10(%rbp)
  cmpl   $0x2,-0x4(%rbp)
  je     L9
  lea    D139(%rip),%rax
  mov    %rax,%rdi
  call   <err_quit@plt>
L9:
  lea    D60(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D230(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D51(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D189(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D378(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D207(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D472(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D71(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D476(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D241(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D257(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D340(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D158(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D57(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D292(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D245(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D477(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D108(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D126(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D383(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D21(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D498(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D115(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D192(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D369(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D546(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D61(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D123(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D107(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D296(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D342(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D7(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D282(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D13(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D79(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D393(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D132(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D74(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D141(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D24(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D491(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D504(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D532(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D214(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D117(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D33(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D466(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D208(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D191(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D273(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D350(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D98(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D26(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D82(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  mov    $0x0,%edi
  call   <exit@plt>
  mov    $0x0,%eax
  leave
  ret
```

tool_calls: name: read_data
arguments: tag: D139
datatype: string
name: read_data
arguments: tag: D60
datatype: string
name: read_data
arguments: tag: D230
datatype: string
name: read_data
arguments: tag: D51
datatype: string
name: read_data
arguments: tag: D189
datatype: string
name: read_data
arguments: tag: D378
datatype: string
name: read_data
arguments: tag: D207
datatype: string
name: read_data
arguments: tag: D472
datatype: string
name: read_data
arguments: tag: D71
datatype: string
name: read_data
arguments: tag: D476
datatype: string
name: read_data
arguments: tag: D241
datatype: string
name: read_data
arguments: tag: D257
datatype: string
name: read_data
arguments: tag: D340
datatype: string
name: read_data
arguments: tag: D158
datatype: string
name: read_data
arguments: tag: D57
datatype: string
name: read_data
arguments: tag: D292
datatype: string
name: read_data
arguments: tag: D245
datatype: string
name: read_data
arguments: tag: D477
datatype: string
name: read_data
arguments: tag: D108
datatype: string
name: read_data
arguments: tag: D126
datatype: string
name: read_data
arguments: tag: D383
datatype: string
name: read_data
arguments: tag: D21
datatype: string
name: read_data
arguments: tag: D498
datatype: string
name: read_data
arguments: tag: D115
datatype: string
name: read_data
arguments: tag: D192
datatype: string
name: read_data
arguments: tag: D369
datatype: string
name: read_data
arguments: tag: D546
datatype: string
name: read_data
arguments: tag: D61
datatype: string
name: read_data
arguments: tag: D123
datatype: string
name: read_data
arguments: tag: D107
datatype: string
name: read_data
arguments: tag: D296
datatype: string
name: read_data
arguments: tag: D342
datatype: string
name: read_data
arguments: tag: D7
datatype: string
name: read_data
arguments: tag: D282
datatype: string
name: read_data
arguments: tag: D13
datatype: string
name: read_data
arguments: tag: D79
datatype: string
name: read_data
arguments: tag: D393
datatype: string
name: read_data
arguments: tag: D132
datatype: string
name: read_data
arguments: tag: D74
datatype: string
name: read_data
arguments: tag: D141
datatype: string
name: read_data
arguments: tag: D24
datatype: string
name: read_data
arguments: tag: D491
datatype: string
name: read_data
arguments: tag: D504
datatype: string
name: read_data
arguments: tag: D532
datatype: string
name: read_data
arguments: tag: D214
datatype: string
name: read_data
arguments: tag: D117
datatype: string
name: read_data
arguments: tag: D33
datatype: string
name: read_data
arguments: tag: D466
datatype: string
name: read_data
arguments: tag: D208
datatype: string
name: read_data
arguments: tag: D191
datatype: string
name: read_data
arguments: tag: D273
datatype: string
name: read_data
arguments: tag: D350
datatype: string
name: read_data
arguments: tag: D98
datatype: string
name: read_data
arguments: tag: D26
datatype: string
name: read_data
arguments: tag: D82
datatype: string

tool: D139: usage: a.out <dirname>

tool: D60: no symbol for ARG_MAX


tool: D230: no symbol for _SC_ARG_MAX


tool: D51: no symbol for ATEXIT_MAX


tool: D189: no symbol for _SC_ATEXIT_MAX


tool: D378: no symbol for CHARCLASS_NAME_MAX


tool: D207: no symbol for _SC_CHARCLASS_NAME_MAX


tool: D472: no symbol for CHILD_MAX


tool: D71: no symbol for _SC_CHILD_MAX


tool: D476: no symbol for CLOCKTICKSPERSECOND


tool: D241: no symbol for _SC_CLK_TCK


tool: D257: no symbol for COLL_WEIGHTS_MAX


tool: D340: no symbol for _SC_COLL_WEIGHTS_MAX


tool: D158: no symbol for HOST_NAME_MAX


tool: D57: no symbol for _SC_HOST_NAME_MAX


tool: D292: no symbol for IOV_MAX


tool: D245: no symbol for _SC_IOV_MAX


tool: D477: no symbol for LINE_MAX


tool: D108: no symbol for _SC_LINE_MAX


tool: D126: no symbol for LOGIN_NAME_MAX


tool: D383: no symbol for _SC_LOGIN_NAME_MAX


tool: D21: no symbol for NGROUPS_MAX


tool: D498: no symbol for _SC_NGROUPS_MAX


tool: D115: no symbol for OPEN_MAX


tool: D192: no symbol for _SC_OPEN_MAX


tool: D369: no symbol for PAGESIZE


tool: D546: no symbol for _SC_PAGESIZE


tool: D61: no symbol for PAGE_SIZE


tool: D123: no symbol for _SC_PAGE_SIZE


tool: D107: no symbol for RE_DUP_MAX


tool: D296: no symbol for _SC_RE_DUP_MAX


tool: D342: no symbol for STREAM_MAX


tool: D7: no symbol for _SC_STREAM_MAX


tool: D282: no symbol for SYMLOOP_MAX


tool: D13: no symbol for _SC_SYMLOOP_MAX


tool: D79: no symbol for TTY_NAME_MAX


tool: D393: no symbol for _SC_TTY_NAME_MAX


tool: D132: no symbol for TZNAME_MAX


tool: D74: no symbol for _SC_TZNAME_MAX


tool: D141: no symbol for MAX_CANON


tool: D24: no symbol for _PC_MAX_CANON


tool: D491: no symbol for MAX_INPUT


tool: D504: no symbol for _PC_MAX_INPUT


tool: D532: no symbol for FILESIZEBITS


tool: D214: no symbol for _PC_FILESIZEBITS


tool: D117: no symbol for LINK_MAX


tool: D33: no symbol for _PC_LINK_MAX


tool: D466: no symbol for NAME_MAX


tool: D208: no symbol for _PC_NAME_MAX


tool: D191: no symbol for PATH_MAX


tool: D273: no symbol for _PC_PATH_MAX


tool: D350: no symbol for PIPE_BUF


tool: D98: no symbol for _PC_PIPE_BUF


tool: D26: no symbol for SYMLINK_MAX


tool: D82: no symbol for _PC_SYMLINK_MAX


assistant: ```c
int main(int argc, char *argv[]) {
  if (argc != 2)
    err_quit("usage: a.out <dirname>");
  printf("no symbol for ARG_MAX\n");
  printf("no symbol for _SC_ARG_MAX\n");
  printf("no symbol for ATEXIT_MAX\n");
  printf("no symbol for _SC_ATEXIT_MAX\n");
  printf("no symbol for CHARCLASS_NAME_MAX\n");
  printf("no symbol for _SC_CHARCLASS_NAME_MAX\n");
  printf("no symbol for CHILD_MAX\n");
  printf("no symbol for _SC_CHILD_MAX\n");
  printf("no symbol for CLOCKTICKSPERSECOND\n");
  printf("no symbol for _SC_CLK_TCK\n");
  printf("no symbol for COLL_WEIGHTS_MAX\n");
  printf("no symbol for _SC_COLL_WEIGHTS_MAX\n");
  printf("no symbol for HOST_NAME_MAX\n");
  printf("no symbol for _SC_HOST_NAME_MAX\n");
  printf("no symbol for IOV_MAX\n");
  printf("no symbol for _SC_IOV_MAX\n");
  printf("no symbol for LINE_MAX\n");
  printf("no symbol for _SC_LINE_MAX\n");
  printf("no symbol for LOGIN_NAME_MAX\n");
  printf("no symbol for _SC_LOGIN_NAME_MAX\n");
  printf("no symbol for NGROUPS_MAX\n");
  printf("no symbol for _SC_NGROUPS_MAX\n");
  printf("no symbol for OPEN_MAX\n");
  printf("no symbol for _SC_OPEN_MAX\n");
  printf("no symbol for PAGESIZE\n");
  printf("no symbol for _SC_PAGESIZE\n");
  printf("no symbol for PAGE_SIZE\n");
  printf("no symbol for _SC_PAGE_SIZE\n");
  printf("no symbol for RE_DUP_MAX\n");
  printf("no symbol for _SC_RE_DUP_MAX\n");
  printf("no symbol for STREAM_MAX\n");
  printf("no symbol for _SC_STREAM_MAX\n");
  printf("no symbol for SYMLOOP_MAX\n");
  printf("no symbol for _SC_SYMLOOP_MAX\n");
  printf("no symbol for TTY_NAME_MAX\n");
  printf("no symbol for _SC_TTY_NAME_MAX\n");
  printf("no symbol for TZNAME_MAX\n");
  printf("no symbol for _SC_TZNAME_MAX\n");
  printf("no symbol for MAX_CANON\n");
  printf("no symbol for _PC_MAX_CANON\n");
  printf("no symbol for MAX_INPUT\n");
  printf("no symbol for _PC_MAX_INPUT\n");
  printf("no symbol for FILESIZEBITS\n");
  printf("no symbol for _PC_FILESIZEBITS\n");
  printf("no symbol for LINK_MAX\n");
  printf("no symbol for _PC_LINK_MAX\n");
  printf("no symbol for NAME_MAX\n");
  printf("no symbol for _PC_NAME_MAX\n");
  printf("no symbol for PATH_MAX\n");
  printf("no symbol for _PC_PATH_MAX\n");
  printf("no symbol for PIPE_BUF\n");
  printf("no symbol for _PC_PIPE_BUF\n");
  printf("no symbol for SYMLINK_MAX\n");
  printf("no symbol for _PC_SYMLINK_MAX\n");
  exit(0);
}
```