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

```asm
<getModuleFamily>:
  endbr64
  push   %r15
  lea    D10(%rip),%r15
  pxor   %xmm0,%xmm0
  push   %r14
  mov    %r15,%rsi
  push   %r13
  mov    %rdi,%r13
  lea    D80(%rip),%rdi
  push   %r12
  lea    D14(%rip),%r12
  push   %rbp
  push   %rbx
  sub    $0x1a8,%rsp
  mov    %fs:0x28,%rax
  mov    %rax,0x198(%rsp)
  xor    %eax,%eax
  movaps %xmm0,0x10(%rsp)
  lea    0x10(%rsp),%r14
  lea    0x90(%rsp),%rbx
  movaps %xmm0,0x20(%rsp)
  movaps %xmm0,0x30(%rsp)
  movaps %xmm0,0x40(%rsp)
  movaps %xmm0,0x50(%rsp)
  movaps %xmm0,0x60(%rsp)
  movaps %xmm0,0x70(%rsp)
  movaps %xmm0,0x80(%rsp)
  call   <fopen@plt>
  mov    %rax,%rbp
  lea    0x97(%rsp),%rax
  mov    %rax,0x8(%rsp)
  test   %rbp,%rbp
  jne    L100
  jmp    L24
  xchg   %ax,%ax
L137:
  mov    %r12,%rsi
  mov    %rbx,%rdi
  call   <strstr@plt>
  test   %rax,%rax
  jne    L55
L100:
  mov    %rbp,%rdx
  mov    $0xff,%esi
  mov    %rbx,%rdi
  call   <fgets@plt>
  test   %rax,%rax
  jne    L137
  mov    %rbp,%rdi
  lea    D12(%rip),%r12
  call   <fclose@plt>
  mov    %r12,%rsi
  mov    %r14,%rdi
  call   <strstr@plt>
  mov    %rax,%rbp
  test   %rax,%rax
  je     L124
  add    $0x8,%rbp
  lea    D135(%rip),%rsi
  mov    %rbp,%rdi
  call   <strstr@plt>
  test   %rax,%rax
  je     L33
  sub    %rbp,%rax
  lea    -0x1(%rax),%r15
L183:
  mov    %r15,%rdx
  mov    %rbp,%rsi
  mov    %r13,%rdi
  call   <strncpy@plt>
  lea    D96(%rip),%rsi
  mov    %r13,%rdi
  call   <strstr@plt>
  mov    %rax,%r8
  xor    %eax,%eax
  test   %r8,%r8
  jne    L56
  lea    D74(%rip),%rsi
  mov    %r13,%rdi
  call   <strstr@plt>
  cmp    $0x1,%rax
  sbb    %eax,%eax
  or     $0x1,%eax
L56:
  mov    0x198(%rsp),%rdx
  sub    %fs:0x28,%rdx
  jne    L92
  add    $0x1a8,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
  nopw   0x0(%rax,%rax,1)
L55:
  mov    0x8(%rsp),%rdi
  mov    $0x3a,%esi
  call   <strchr@plt>
  lea    D1(%rip),%rsi
  mov    %r14,%rdi
  mov    %rax,%rdx
  call   <sprintf@plt>
  jmp    L100
  cs nopw 0x0(%rax,%rax,1)
L33:
  lea    D47(%rip),%rsi
  mov    %rbp,%rdi
  call   <strcspn@plt>
  mov    %rax,%r15
  jmp    L183
  nopw   0x0(%rax,%rax,1)
L24:
  lea    D4(%rip),%rdi
  xor    %r15d,%r15d
  call   <printf@plt>
  mov    $0xffffffff,%edi
  call   <exit@plt>
  jmp    L183
L124:
  mov    %r15,%rsi
  lea    D88(%rip),%rdi
  call   <fopen@plt>
  mov    %rax,%r14
  test   %rax,%rax
  je     L134
L188:
  xor    %r15d,%r15d
  nopl   0x0(%rax)
L3:
  mov    %r14,%rdx
  mov    $0xff,%esi
  mov    %rbx,%rdi
  call   <fgets@plt>
  test   %rax,%rax
  je     L146
  mov    %r12,%rsi
  mov    %rbx,%rdi
  call   <strstr@plt>
  mov    %rax,%rbp
  test   %rax,%rax
  je     L38
L20:
  add    $0x8,%rbp
  lea    D37(%rip),%rsi
  mov    %rbp,%rdi
  call   <strstr@plt>
  test   %rax,%rax
  je     L171
  sub    %rbp,%rax
  lea    -0x1(%rax),%r15
  jmp    L3
  nopl   0x0(%rax)
L171:
  mov    %rbp,%rdi
  call   <strlen@plt>
  mov    %rax,%r15
  jmp    L3
L38:
  lea    D28(%rip),%rdi
  call   <printf@plt>
  mov    $0xffffffff,%edi
  call   <exit@plt>
  jmp    L20
L146:
  mov    %r14,%rdi
  call   <fclose@plt>
  jmp    L183
L134:
  mov    %r15,%rsi
  lea    D111(%rip),%rdi
  call   <fopen@plt>
  mov    %rax,%r14
  test   %rax,%rax
  jne    L188
  xor    %r15d,%r15d
  jmp    L183
L92:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: retrieve_data
arguments: tag: D10
type: string
name: retrieve_data
arguments: tag: D80
type: string
name: retrieve_data
arguments: tag: D14
type: string
name: retrieve_data
arguments: tag: D12
type: string
name: retrieve_data
arguments: tag: D135
type: string
name: retrieve_data
arguments: tag: D96
type: string
name: retrieve_data
arguments: tag: D74
type: string
name: retrieve_data
arguments: tag: D1
type: string
name: retrieve_data
arguments: tag: D47
type: string
name: retrieve_data
arguments: tag: D4
type: string
name: retrieve_data
arguments: tag: D88
type: string
name: retrieve_data
arguments: tag: D37
type: string
name: retrieve_data
arguments: tag: D28
type: string
name: retrieve_data
arguments: tag: D111
type: string

tool: D10: r

tool: D80: /proc/cpuinfo

tool: D14: Hardware

tool: D12: Toradex

tool: D135: Module

tool: D96: Colibri

tool: D74: Apalis

tool: D1: %s

tool: D47: 


tool: D4: CPU info not available!

tool: D88: /sys/firmware/devicetree/base/model

tool: D37: on

tool: D28: Invalid Machine!

tool: D111: /sys/bus/soc/devices/soc0/machine

assistant: ```c
unsigned int getModuleFamily(char *moduleName) {
  char buf[256], hardware[128] = {0};
  FILE *file = NULL;
  char *start = NULL, *numStr = NULL, *end = NULL;
  size_t len = 0;
  file = fopen("/proc/cpuinfo", "r");
  if (file) {
    while (fgets(buf, 255, file)) {
      if (strstr(buf, "Hardware")) {
        numStr = strstr(&buf[7], ":");
        sprintf(hardware, "%s", numStr);
      }
    }
    fclose(file);
    start = strstr(hardware, "Toradex");
    if (start != NULL) {
      start += 8;
      end = strstr(start, "Module");
      if (end)
        len = end - start - 1;
      else
        len = strcspn(start, "\n");
    } else {
      file = fopen("/sys/firmware/devicetree/base/model", "r");
      if (file == NULL) {
        file = fopen("/sys/bus/soc/devices/soc0/machine", "r");
      }
      if (file) {
        while (fgets(buf, 255, file)) {
          start = strstr(buf, "Toradex");
          if (start == NULL) {
            printf("Invalid Machine!");
            exit(-1);
          }
          start += 8;
          end = strstr(start, "on");
          if (end)
            len = end - start - 1;
          else
            len = strlen(start);
        }
        fclose(file);
      }
    }
  } else {
    printf("CPU info not available!");
    exit(-1);
  }
  strncpy(moduleName, start, len);
  if (strstr(moduleName, "Colibri")) {
    return 0;
  } else if (strstr(moduleName, "Apalis")) {
    return 1;
  }
  return -1;
}
```