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

```asm
<RunJob>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x5e0,%rsp
  mov    %rdi,-0x5d8(%rbp)
  mov    %esi,-0x5dc(%rbp)
  mov    %edx,-0x5e0(%rbp)
  mov    %fs:0x28,%rax
  mov    %rax,-0x8(%rbp)
  xor    %eax,%eax
  mov    -0x5dc(%rbp),%ecx
  mov    -0x5d8(%rbp),%rdx
  lea    -0x5b0(%rbp),%rax
  lea    D57(%rip),%rsi
  mov    %rax,%rdi
  mov    $0x0,%eax
  call   <sprintf@plt>
  cmpl   $0x0,-0x5e0(%rbp)
  je     L151
  mov    -0x5dc(%rbp),%edx
  lea    -0x100(%rbp),%rax
  lea    D22(%rip),%rcx
  mov    %rcx,%rsi
  mov    %rax,%rdi
  mov    $0x0,%eax
  call   <sprintf@plt>
  lea    -0x100(%rbp),%rax
  mov    %rax,%rdx
  mov    $0x0,%esi
  lea    D1(%rip),%rax
  mov    %rax,%rdi
  call   <Message@plt>
L151:
  lea    -0x5b0(%rbp),%rax
  lea    D37(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <fopen@plt>
  mov    %rax,-0x5c0(%rbp)
  cmpq   $0x0,-0x5c0(%rbp)
  je     L129
  mov    -0x5dc(%rbp),%edx
  mov    -0x5d8(%rbp),%rax
  mov    %edx,%esi
  mov    %rax,%rdi
  call   <GetOwner@plt>
  mov    %rax,-0x5b8(%rbp)
  mov    -0x5c0(%rbp),%rdx
  lea    -0x4c0(%rbp),%rax
  mov    $0xf0,%esi
  mov    %rax,%rdi
  call   <fgets@plt>
  test   %eax,%eax
  jne    L16
  mov    -0x5dc(%rbp),%edx
  lea    -0x100(%rbp),%rax
  lea    D130(%rip),%rcx
  mov    %rcx,%rsi
  mov    %rax,%rdi
  mov    $0x0,%eax
  call   <sprintf@plt>
  lea    -0x100(%rbp),%rax
  mov    %rax,%rdx
  mov    $0x1,%esi
  lea    D1(%rip),%rax
  mov    %rax,%rdi
  call   <Message@plt>
  mov    -0x5c0(%rbp),%rax
  mov    %rax,%rdi
  call   <fclose@plt>
  jmp    L129
L16:
  movl   $0x0,-0x5c8(%rbp)
  jmp    L161
L83:
  mov    -0x5c8(%rbp),%eax
  cltq
  movzbl -0x4c0(%rbp,%rax,1),%eax
  cmp    $0xa,%al
  jne    L166
  mov    -0x5c8(%rbp),%eax
  cltq
  movb   $0x0,-0x4c0(%rbp,%rax,1)
  jmp    L47
L166:
  addl   $0x1,-0x5c8(%rbp)
L161:
  mov    -0x5c8(%rbp),%eax
  cltq
  movzbl -0x4c0(%rbp,%rax,1),%eax
  test   %al,%al
  jne    L83
L47:
  mov    -0x5c0(%rbp),%rdx
  lea    -0x3d0(%rbp),%rax
  mov    $0xf0,%esi
  mov    %rax,%rdi
  call   <fgets@plt>
  test   %eax,%eax
  jne    L146
  mov    -0x5dc(%rbp),%edx
  lea    -0x100(%rbp),%rax
  lea    D130(%rip),%rcx
  mov    %rcx,%rsi
  mov    %rax,%rdi
  mov    $0x0,%eax
  call   <sprintf@plt>
  lea    -0x100(%rbp),%rax
  mov    %rax,%rdx
  mov    $0x1,%esi
  lea    D1(%rip),%rax
  mov    %rax,%rdi
  call   <Message@plt>
  mov    -0x5c0(%rbp),%rax
  mov    %rax,%rdi
  call   <fclose@plt>
  jmp    L129
L146:
  movl   $0x0,-0x5c4(%rbp)
  jmp    L125
L26:
  mov    -0x5c4(%rbp),%eax
  cltq
  movzbl -0x3d0(%rbp,%rax,1),%eax
  cmp    $0xa,%al
  jne    L40
  mov    -0x5c4(%rbp),%eax
  cltq
  movb   $0x0,-0x3d0(%rbp,%rax,1)
  jmp    L64
L40:
  addl   $0x1,-0x5c4(%rbp)
L125:
  mov    -0x5c4(%rbp),%eax
  cltq
  movzbl -0x3d0(%rbp,%rax,1),%eax
  test   %al,%al
  jne    L26
L64:
  mov    -0x5c0(%rbp),%rax
  mov    %rax,%rdi
  call   <fclose@plt>
  lea    -0x3d0(%rbp),%rcx
  lea    -0x4c0(%rbp),%rdx
  lea    -0x1f0(%rbp),%rax
  lea    D94(%rip),%rsi
  mov    %rax,%rdi
  mov    $0x0,%eax
  call   <sprintf@plt>
  lea    -0x1f0(%rbp),%rcx
  mov    -0x5b8(%rbp),%rdx
  lea    -0x2e0(%rbp),%rax
  lea    D120(%rip),%rsi
  mov    %rax,%rdi
  mov    $0x0,%eax
  call   <sprintf@plt>
  cmpl   $0x1,-0x5e0(%rbp)
  jle    L1
  lea    -0x1f0(%rbp),%rdx
  lea    -0x100(%rbp),%rax
  lea    D50(%rip),%rcx
  mov    %rcx,%rsi
  mov    %rax,%rdi
  mov    $0x0,%eax
  call   <sprintf@plt>
  lea    -0x100(%rbp),%rax
  mov    %rax,%rdx
  mov    $0x0,%esi
  lea    D1(%rip),%rax
  mov    %rax,%rdi
  call   <Message@plt>
L1:
  cmpl   $0x2,-0x5e0(%rbp)
  jle    L144
  lea    -0x2e0(%rbp),%rdx
  lea    -0x100(%rbp),%rax
  lea    D25(%rip),%rcx
  mov    %rcx,%rsi
  mov    %rax,%rdi
  mov    $0x0,%eax
  call   <sprintf@plt>
  lea    -0x100(%rbp),%rax
  mov    %rax,%rdx
  mov    $0x0,%esi
  lea    D1(%rip),%rax
  mov    %rax,%rdi
  call   <Message@plt>
L144:
  lea    -0x2e0(%rbp),%rax
  mov    %rax,%rdi
  call   <system@plt>
  lea    -0x5b0(%rbp),%rax
  mov    %rax,%rdi
  call   <unlink@plt>
L129:
  mov    -0x8(%rbp),%rax
  sub    %fs:0x28,%rax
  je     L107
  call   <__stack_chk_fail@plt>
L107:
  leave
  ret
```

tool_calls: name: unpack_data
arguments: label: D57
type_infered: string
name: unpack_data
arguments: label: D22
type_infered: string
name: unpack_data
arguments: label: D1
type_infered: string
name: unpack_data
arguments: label: D37
type_infered: string
name: unpack_data
arguments: label: D130
type_infered: string
name: unpack_data
arguments: label: D94
type_infered: string
name: unpack_data
arguments: label: D120
type_infered: string
name: unpack_data
arguments: label: D50
type_infered: string
name: unpack_data
arguments: label: D25
type_infered: string

tool: D57: %s/%d

tool: D22: Running job %d

tool: D1: simq

tool: D37: r

tool: D130: Invalid Job file (%d)

tool: D94: (cd %s; %s)

tool: D120: su - %s -c "%s"

tool: D50: Command is: %s

tool: D25: Expanded command is: %s

assistant: ```c
void RunJob(char *queueDir, int jobID, int verbose) {
  char jobFile[240], pwd[240], job[240], exe[240], cmd[240];
  FILE *fp;
  sprintf(jobFile, "%s/%d", queueDir, jobID);
  if (verbose) {
    char msg[240];
    sprintf(msg, "Running job %d", jobID);
    Message("simq", 0, msg);
  }
  if ((fp = fopen(jobFile, "r")) != NULL) {
    char *username;
    username = GetOwner(queueDir, jobID);
    if (!fgets(pwd, 240, fp)) {
      char car_msg[240];
      sprintf(car_msg, "Invalid Job file (%d)", jobID);
      Message("simq", 1, car_msg);
      fclose(fp);
      return;
    };
    do {
      int _terminate_macro_j;
      for (_terminate_macro_j = 0; (pwd)[_terminate_macro_j]; _terminate_macro_j++) {
        if ((pwd)[_terminate_macro_j] == '\n') {
          (pwd)[_terminate_macro_j] = '\0';
          break;
        }
      }
    } while (0);
    if (!fgets(job, 240, fp)) {
      char car_msg[240];
      sprintf(car_msg, "Invalid Job file (%d)", jobID);
      Message("simq", 1, car_msg);
      fclose(fp);
      return;
    };
    do {
      int _terminate_macro_j;
      for (_terminate_macro_j = 0; (job)[_terminate_macro_j]; _terminate_macro_j++) {
        if ((job)[_terminate_macro_j] == '\n') {
          (job)[_terminate_macro_j] = '\0';
          break;
        }
      }
    } while (0);
    fclose(fp);
    sprintf(cmd, "(cd %s; %s)", pwd, job);
    sprintf(exe, "su - %s -c \"%s\"", username, cmd);
    if (verbose >= 2) {
      char msg[240];
      sprintf(msg, "Command is: %s", cmd);
      Message("simq", 0, msg);
    }
    if (verbose >= 3) {
      char msg[240];
      sprintf(msg, "Expanded command is: %s", exe);
      Message("simq", 0, msg);
    }
    system(exe);
    unlink(jobFile);
  }
}
```