LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O1/mjosaarinen[P]brutus/crypto_aead/pi64cipher128v2/ref2/encrypt.c
// Function: crypto_aead_encrypt
int crypto_aead_encrypt(
	unsigned char *c,unsigned long long *clen,
	const unsigned char *m,unsigned long long mlen,
	const unsigned char *ad,unsigned long long adlen,
	const unsigned char *nsec,
	const unsigned char *npub,
	const unsigned char *k
)
{
/*
...
... the code for the cipher implementation goes here,
... generating a ciphertext c[0],c[1],...,c[*clen-1]
... from a plaintext m[0],m[1],...,m[mlen-1]
... and associated data ad[0],ad[1],...,ad[adlen-1]
... and secret message number nsec[0],nsec[1],...
... and public message number npub[0],npub[1],...
... and secret key k[0],k[1],...
...
*/
	size_t x, v;
	PI_ENCRYPT_SIMPLE(
			c,
			&x,
			&c[mlen + (nsec ? PI_CT_BLOCK_LENGTH_BYTES : 0)],
			&v,
			m,
			mlen,
			ad,
			adlen,
			nsec,
			npub,
			CRYPTO_NPUBBYTES,
			k,
			CRYPTO_KEYBYTES );
	*clen = x + PI_TAG_BYTES;
	return 0;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %r9, %r10
movq %r8, %rax
movq %rcx, %r9
movq %rdx, %r8
movq %rsi, %rbx
movq 0x30(%rsp), %r11
xorl %edx, %edx
testq %r11, %r11
setne %dl
shll $0x6, %edx
addq %rdi, %rcx
addq %rcx, %rdx
subq $0x8, %rsp
movl $0x10, %r15d
leaq 0x10(%rsp), %r14
leaq 0x8(%rsp), %rcx
movq %r14, %rsi
pushq %r15
pushq 0x50(%rsp)
pushq %r15
pushq 0x58(%rsp)
pushq %r11
pushq %r10
pushq %rax
callq 0x10d0
addq $0x40, %rsp
movq (%r14), %rax
addq $0x40, %rax
movq %rax, (%rbx)
xorl %eax, %eax
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/mjosaarinen[P]brutus/crypto_aead/pi64cipher128v2/ref2/pi-cipher.c
// Function: inject_block
static void inject_block(
        state_t a,
        const void *block )
{
	word_t x;
	int i;
	for (i = 0; i < 4; ++i) {
		x = load_word_little(&((const word_t *)block)[i]);
	    a[0][i] ^= x;
	}
	for (; i < 8; ++i) {
		x = load_word_little(&((const word_t *)block)[i]);
	    a[2][i - 4] ^= x;
	}
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %rbx
movq %rdi, %r14
xorl %r15d, %r15d
leaq (%rbx,%r15), %rdi
callq 0x13b8
xorq %rax, (%r14,%r15)
addq $0x8, %r15
cmpq $0x20, %r15
jne 0x153f
addq $0x20, %rbx
xorl %r15d, %r15d
leaq (%rbx,%r15), %rdi
callq 0x13b8
xorq %rax, 0x40(%r14,%r15)
addq $0x8, %r15
cmpq $0x20, %r15
jne 0x155d
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/mjosaarinen[P]brutus/crypto_aead/pi64cipher128v2/ref2/pi-cipher.c
// Function: replace_block
static void replace_block(
        state_t a,
        const void *block )
{
	word_t x;
	int i;
	for (i = 0; i < 4; ++i) {
		x = load_word_little(&((const word_t *)block)[i]);
	    a[0][i] = x;
	}
	for (; i < 8; ++i) {
		x = load_word_little(&((const word_t *)block)[i]);
	    a[2][i - 4] = x;
	}
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %rbx
movq %rdi, %r14
xorl %r15d, %r15d
leaq (%rbx,%r15), %rdi
callq 0x13b8
movq %rax, (%r14,%r15)
addq $0x8, %r15
cmpq $0x20, %r15
jne 0x1892
addq $0x20, %rbx
xorl %r15d, %r15d
leaq (%rbx,%r15), %rdi
callq 0x13b8
movq %rax, 0x40(%r14,%r15)
addq $0x8, %r15
cmpq $0x20, %r15
jne 0x18b0
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/simh[P]simtools/extracters/cpytap/cpytap.c
// Function: usage
void usage(void)
{
  fprintf(stderr,
          "Usage: cpytap src dst [-r len] [-S n] [-I n,file] [-R n,file] [-A file]\n");
  fprintf(stderr,
          "  Copy src .tap file to destination maintaining the internal\n"
          "  record structure. The switches control file level changes to\n"
          "  destination tape.\n");
  fprintf(stderr, "\nSwitches:\n\n");
  fprintf(stderr,
          "-r len        - Specify max record size when writing new files.\n"
          "                There may be multiple \"-r\" switches on the\n"
          "                command line if the new files need different\n"
          "                record sizes. (%u <= len <= %u, default %u)\n"
          "                If len is outside the supported range, it will be\n"
          "                quietly modified to the minimum or maximum value.\n",
          MINRECLEN, MAXRECLEN, DEFRECLEN);
  fprintf(stderr,
          "-I n,file     - Insert specified file before file n of the source tape.\n");
  fprintf(stderr,
          "-R n,file     - Replace file n of the source tape with the specified file.\n");
  fprintf(stderr,
          "-S n          - Skip file n from the source tape.\n");
  fprintf(stderr,
          "-A file       - Append the specified file after all the files on\n"
          "                the source tape have been copied to the destination.\n");
  fprintf(stderr,
          "\nFiles are number 1 - N according to their position on the\n"
          "source tape.\n");
  exit(1);
}

// Assembly:
pushq %rbx
movq 0x3b74(%rip), %rbx      # 0x4ff8
movq (%rbx), %rcx
leaq 0x1b76(%rip), %rdi      # 0x3004
movl $0x48, %esi
movl $0x1, %edx
callq 0x1130
movq (%rbx), %rcx
leaq 0x1ba6(%rip), %rdi      # 0x304d
movl $0x90, %esi
movl $0x1, %edx
callq 0x1130
movq (%rbx), %rcx
leaq 0x1c1e(%rip), %rdi      # 0x30de
movl $0xc, %esi
movl $0x1, %edx
callq 0x1130
movq (%rbx), %rdi
leaq 0x1c12(%rip), %rsi      # 0x30eb
movl $0x1, %edx
movl $0x10000, %ecx          # imm = 0x10000
movl $0x2800, %r8d           # imm = 0x2800
xorl %eax, %eax
callq 0x10a0
movq (%rbx), %rcx
leaq 0x1d6a(%rip), %rdi      # 0x3264
movl $0x48, %esi
movl $0x1, %edx
callq 0x1130
movq (%rbx), %rcx
leaq 0x1d9a(%rip), %rdi      # 0x32ad
movl $0x4b, %esi
movl $0x1, %edx
callq 0x1130
movq (%rbx), %rcx
leaq 0x1dcd(%rip), %rdi      # 0x32f9
movl $0x32, %esi
movl $0x1, %edx
callq 0x1130
movq (%rbx), %rcx
leaq 0x1de7(%rip), %rdi      # 0x332c
movl $0x86, %esi
movl $0x1, %edx
callq 0x1130
movq (%rbx), %rcx
leaq 0x1e55(%rip), %rdi      # 0x33b3
movl $0x48, %esi
movl $0x1, %edx
callq 0x1130
movl $0x1, %edi
callq 0x1120
// File: /workspace/github_c_makefile_star2_O1/simh[P]simtools/extracters/cpytap/cpytap.c
// Function: parse
int parse(
  char *arg,
  int *file,
  char **name
)
{
  char *endptr;

  *file = strtoul(arg, &endptr, 0);

  if ((*endptr == ',') && (*++endptr == '\0'))
    return -1;
  if ((*file == 0) || (*file > MAXFILES))
    return -1;

  *name = endptr;
  return 0;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rdx, %rbx
movq %rsi, %r14
leaq 0x8(%rsp), %r15
movq %r15, %rsi
xorl %edx, %edx
callq 0x1110
movl %eax, (%r14)
movq (%r15), %rcx
cmpb $0x2c, (%rcx)
jne 0x15af
leaq 0x1(%rcx), %rdx
movq %rdx, 0x8(%rsp)
cmpb $0x0, 0x1(%rcx)
je 0x15cf
testl %eax, %eax
sete %cl
cmpl $0x65, %eax
setge %al
orb %cl, %al
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
jne 0x15d4
movq 0x8(%rsp), %rax
movq %rax, (%rbx)
xorl %eax, %eax
jmp 0x15d4
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/simh[P]simtools/extracters/cpytap/cpytap.c
// Function: writeFile
static void writeFile(
  char *filename,
  int rlen
)
{
  FILE *file;
  size_t datalen;
  char record[MAXRCLNT];

  if ((file = fopen(filename, "r")) != NULL) {
    while ((datalen = fread(record, sizeof(char), rlen, file)) != 0) {
      if (ferror(file)) {
        fprintf(stderr, "Error reading %s\n", filename);
        exit(4);
      }
      if (WriteTapeRecord(dst, record, rlen) != 0) {
        fprintf(stderr, "Error writing record to destination tape\n");
        exit(5);
      }
    }
    if (WriteTapeMark(dst, 0) != 0) {
      fprintf(stderr, "Error writing tape mark to destination tape\n");
      exit(5);
    }
    fclose(file);
    return;
  }
  fprintf(stderr, "Failed to open file - %s\n", filename);
  exit(3);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x10000, %rsp          # imm = 0x10000
movl %esi, %ebp
movq %rdi, %r14
leaq 0x1b88(%rip), %rsi      # 0x3570
callq 0x10f0
testq %rax, %rax
je 0x1a6b
movq %rax, %rbx
movslq %ebp, %r15
movq %rsp, %r12
movl $0x1, %esi
movq %r12, %rdi
movq %r15, %rdx
movq %rbx, %rcx
callq 0x1060
testq %rax, %rax
je 0x1a39
movq %rbx, %rdi
callq 0x1050
testl %eax, %eax
jne 0x1a63
movq 0x36c2(%rip), %rdi      # 0x50e8
movq %r12, %rsi
movl %ebp, %edx
callq 0x1f4f
testl %eax, %eax
je 0x19fb
callq 0x12ce
movq 0x36a8(%rip), %rdi      # 0x50e8
xorl %esi, %esi
callq 0x204c
testl %eax, %eax
jne 0x1a73
movq %rbx, %rdi
callq 0x1070
addq $0x10000, %rsp          # imm = 0x10000
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movq %r14, %rdi
callq 0x12aa
movq %r14, %rdi
callq 0x1318
callq 0x12f3
// File: /workspace/github_c_makefile_star2_O1/simh[P]simtools/extracters/cpytap/cpytap.c
// Function: copyFile
static unsigned int copyFile(void)
{
  char record[MAXRCLNT];
  uint32 len;

  for (;;) {
    switch (len = ReadTapeRecord(src, record, sizeof(record))) {
        case ST_EOM:
          return ST_EOM;

        case ST_TM:
          if (WriteTapeMark(dst, 0) == 0)
            return ST_TM;
          fprintf(stderr, "Error writing tape mark to destination tape\n");
          exit(6);

        default:
          if (WriteTapeRecord(dst, record, len) == 0)
            continue;
          fprintf(stderr, "Error writing record to destination tape\n");
          exit(6);
      }
  }
}

// Assembly:
pushq %rbp
pushq %rbx
subq $0x10008, %rsp          # imm = 0x10008
movq %rsp, %rbx
movq 0x3655(%rip), %rdi      # 0x50e0
movq %rbx, %rsi
movl $0x10000, %edx          # imm = 0x10000
callq 0x1dc9
movl %eax, %ebp
cmpl $-0x1, %eax
je 0x1acf
testl %ebp, %ebp
je 0x1abd
movq 0x363e(%rip), %rdi      # 0x50e8
movq %rbx, %rsi
movl %ebp, %edx
callq 0x1f4f
testl %eax, %eax
je 0x1a84
callq 0x1361
movq 0x3624(%rip), %rdi      # 0x50e8
xorl %esi, %esi
callq 0x204c
testl %eax, %eax
jne 0x1adb
movl %ebp, %eax
addq $0x10008, %rsp          # imm = 0x10008
popq %rbx
popq %rbp
retq
callq 0x133c
// File: /workspace/github_c_makefile_star2_O1/simh[P]simtools/extracters/cpytap/tapeio.c
// Function: OpenTapeForRead
int OpenTapeForRead(
  FILE **handle,
  char *name
)
{
  FILE *tfile;

  if ((tfile = fopen(name, "r")) != NULL) {
    int status;

    status = verifyFormat(tfile);
    rewind(tfile);
    if ((status != TIO_SUCCESS) && (status != TIO_ERROR))
      CloseTape(tfile);
    else *handle = tfile;
    return status;
  }
  return TIO_OPENFAIL;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movq %rsi, %rax
movq %rdi, %rbx
leaq 0x1a7f(%rip), %rsi      # 0x3570
movq %rax, %rdi
callq 0x10f0
testq %rax, %rax
je 0x1b26
movq %rax, %r14
movq %rax, %rdi
callq 0x1b37
movl %eax, %ebp
movq %r14, %rdi
callq 0x1080
movl %ebp, %eax
decl %eax
cmpl $-0x3, %eax
ja 0x1b2d
movq %r14, %rdi
callq 0x1070
jmp 0x1b30
movl $0xfffffffd, %ebp       # imm = 0xFFFFFFFD
jmp 0x1b30
movq %r14, (%rbx)
movl %ebp, %eax
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/simh[P]simtools/extracters/cpytap/tapeio.c
// Function: OpenTapeForWrite
int OpenTapeForWrite(
  FILE **handle,
  char *name
)
{
  FILE *tfile;

  /*
   * Fail if the file exists
   */
  if (access(name, F_OK) == 0)
    return TIO_CREATEFAIL;

  if ((tfile = fopen(name, "w+")) != NULL) {
    uint32 tm = 0;
    int status = TIO_SUCCESS;

    /*
     * Write 2 tape marks
     */
    if (fwrite(&tm, sizeof(tm), 2, tfile) != 2)
      status = TIO_IOERROR;

    if (status == TIO_SUCCESS) {
      rewind(tfile);
      *handle = tfile;
      return TIO_SUCCESS;
    }

    /*
     * Failed to write the 2 tape marks. Try to delete the file before
     * returning an error.
     */
    CloseTape(tfile);
    unlink(name);
    return TIO_IOERROR;
  }
  return TIO_CREATEFAIL;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
movq %rsi, %rdi
xorl %esi, %esi
callq 0x10e0
movl $0xfffffffc, %ebp       # imm = 0xFFFFFFFC
testl %eax, %eax
je 0x1d6f
leaq 0x18dd(%rip), %rsi      # 0x35f5
movq %rbx, %rdi
callq 0x10f0
testq %rax, %rax
je 0x1d6f
movq %rax, %r15
leaq 0x4(%rsp), %rdi
movl $0x0, (%rdi)
movl $0x4, %esi
movl $0x2, %edx
movq %rax, %rcx
callq 0x1130
cmpq $0x2, %rax
jne 0x1d5a
movq %r15, %rdi
callq 0x1080
movq %r15, (%r14)
xorl %ebp, %ebp
jmp 0x1d6f
movq %r15, %rdi
callq 0x1070
movq %rbx, %rdi
callq 0x1030
movl $0xfffffffb, %ebp       # imm = 0xFFFFFFFB
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/simh[P]simtools/extracters/cpytap/tapeio.c
// Function: OpenTapeForAppend
int OpenTapeForAppend(
  FILE **handle,
  char *name
)
{
  FILE *tfile;

  if ((tfile =fopen(name, "r+")) != NULL) {
    int status;

    status = verifyFormat(tfile);
    if ((status != TIO_SUCCESS) && (status != TIO_ERROR))
      CloseTape(tfile);
    else *handle = tfile;
    return status;
  }
  return TIO_OPENFAIL;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movq %rsi, %rax
movq %rdi, %rbx
leaq 0x186b(%rip), %rsi      # 0x35f8
movq %rax, %rdi
callq 0x10f0
testq %rax, %rax
je 0x1db8
movq %rax, %r14
movq %rax, %rdi
callq 0x1b37
movl %eax, %ebp
decl %eax
cmpl $-0x3, %eax
ja 0x1dbf
movq %r14, %rdi
callq 0x1070
jmp 0x1dc2
movl $0xfffffffd, %ebp       # imm = 0xFFFFFFFD
jmp 0x1dc2
movq %r14, (%rbx)
movl %ebp, %eax
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/simh[P]simtools/extracters/cpytap/tapeio.c
// Function: ReadTapeRecordLength
uint32 ReadTapeRecordLength(
  FILE *handle
)
 {
   long pos = ftell(handle);
   uint8 meta[4];
   uint32 bc, erflag;

   /*
    * Note: any I/O errors are treated as "end of medium" detection.
    */
   if (fread(meta, sizeof(meta), 1, handle) != 1)
     return ST_EOM;

   bc = (((unsigned int)meta[3]) << 24) |
        (((unsigned int)meta[2]) << 16) |
        (((unsigned int)meta[1]) << 8) |
        (unsigned int)meta[0];

   switch (bc) {
     case ST_EOM:
     case ST_TM:
       return bc;

     default:
       erflag = bc & ST_ERROR;
       bc &= ST_LENGTH;

       /*
        * Now position the file after this record.
        */
       pos += RECLEN(bc) + (2 * sizeof(meta));
       if (fseek(handle, pos, SEEK_SET) != 0)
         return ST_EOM;

       return erflag | bc;
   }
   return ST_EOM;
 }

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x10, %rsp
movq %rdi, %r14
callq 0x10b0
movq %rax, %r15
leaq 0xc(%rsp), %rdi
movl $0x4, %esi
movl $0x1, %edx
movq %r14, %rcx
callq 0x1060
movl $0xffffffff, %ebx       # imm = 0xFFFFFFFF
cmpq $0x1, %rax
jne 0x1f36
movzbl 0xf(%rsp), %r12d
shll $0x18, %r12d
movzbl 0xe(%rsp), %eax
shll $0x10, %eax
movzbl 0xd(%rsp), %ecx
shll $0x8, %ecx
orl %eax, %ecx
movzbl 0xc(%rsp), %r13d
orl %ecx, %r13d
leal (%r12,%r13), %eax
incl %eax
cmpl $0x2, %eax
jae 0x1f19
orl %r12d, %r13d
movl %r13d, %ebx
jmp 0x1f36
leal 0x1(%r13), %eax
andl $-0x2, %eax
leaq (%rax,%r15), %rsi
addq $0x8, %rsi
movq %r14, %rdi
xorl %edx, %edx
callq 0x10d0
testl %eax, %eax
je 0x1f46
movl %ebx, %eax
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
andl $0x80000000, %r12d      # imm = 0x80000000
jmp 0x1f11
// File: /workspace/github_c_makefile_star2_O1/simh[P]simtools/extracters/cpytap/tapeio.c
// Function: WriteTapeRecord
int WriteTapeRecord(
  FILE *handle,
  void *buf,
  int len
)
{
  uint8 meta[4];
  int datalen;

  meta[0] = len & 0xFF;
  meta[1] = (len >> 8) & 0xFF;
  meta[2] = (len >> 16) & 0xFF;
  meta[3] = (len >> 24) & 0xFF;

  datalen = ((len + 1)  & ST_LENGTH) & ~1;

  if (fwrite(meta, sizeof(meta), 1, handle) != 1)
    return -1;

  if (fwrite(buf, datalen, 1, handle) != 1)
    return -1;

  if (fwrite(meta, sizeof(meta), 1, handle) != 1)
    return -1;

  return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %edx, %r14d
movq %rsi, %r15
movq %rdi, %rbx
leaq 0x4(%rsp), %rdi
movl %edx, (%rdi)
movl $0x4, %esi
movl $0x1, %edx
movq %rbx, %rcx
callq 0x1130
movl $0xffffffff, %ebp       # imm = 0xFFFFFFFF
cmpq $0x1, %rax
jne 0x1fc9
incl %r14d
andl $0xfffffe, %r14d        # imm = 0xFFFFFE
movl $0x1, %edx
movq %r15, %rdi
movq %r14, %rsi
movq %rbx, %rcx
callq 0x1130
cmpq $0x1, %rax
jne 0x1fc9
leaq 0x4(%rsp), %rdi
movl $0x4, %esi
movl $0x1, %edx
movq %rbx, %rcx
callq 0x1130
xorl %ebp, %ebp
cmpq $0x1, %rax
setne %bpl
negl %ebp
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/simh[P]simtools/extracters/cpytap/tapeio.c
// Function: SkipToNextTapeMark
unsigned int SkipToNextTapeMark(
  FILE *handle
)
{
  long pos = ftell(handle);
  uint8 meta[4];
  uint32 bc;

  for (;;) {
    /*
     * Note: any I/O errors are treated as "end of medium" detection.
     */
    if (fread(meta, sizeof(meta), 1, handle) != 1)
      return ST_EOM;

    bc = (((unsigned int)meta[3]) << 24) |
         (((unsigned int)meta[2]) << 16) |
         (((unsigned int)meta[1]) << 8) |
         (unsigned int)meta[0];

    switch (bc) {
      case ST_EOM:
      case ST_TM:
        return bc;

      default:
        bc &= ST_LENGTH;

        /*
         * Now position the file after this record.
         */
        pos += RECLEN(bc) + (2 * sizeof(meta));
        if (fseek(handle, pos, SEEK_SET) != 0)
          return ST_EOM;
        break;
    }
  }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
callq 0x10b0
movq %rax, %r14
leaq 0x4(%rsp), %r15
movl $0xffffffff, %ebp       # imm = 0xFFFFFFFF
movl $0x4, %esi
movl $0x1, %edx
movq %r15, %rdi
movq %rbx, %rcx
callq 0x1060
cmpq $0x1, %rax
jne 0x203f
movl 0x4(%rsp), %eax
leal 0x1(%rax), %ecx
cmpl $0x2, %ecx
jb 0x203d
andl $0xffffff, %eax         # imm = 0xFFFFFF
incl %eax
andl $-0x2, %eax
addq %rax, %r14
addq $0x8, %r14
movq %rbx, %rdi
movq %r14, %rsi
xorl %edx, %edx
callq 0x10d0
testl %eax, %eax
je 0x1ff2
jmp 0x203f
movl %eax, %ebp
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/simh[P]simtools/extracters/cpytap/tapeio.c
// Function: WriteTapeMark
int WriteTapeMark(
  FILE *handle,
  int backup
)
{
  uint32 tm = 0;

  if (fwrite(&tm, sizeof(tm), 1, handle) != 1)
    return -1;

  if (backup)
    if (fseek(handle, -sizeof(tm), SEEK_CUR) != 0)
      return -1;

  return 0;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
subq $0x10, %rsp
movl %esi, %ebp
movq %rdi, %r14
leaq 0xc(%rsp), %rdi
movl $0x0, (%rdi)
movl $0x4, %esi
movl $0x1, %edx
movq %r14, %rcx
callq 0x1130
movl $0xffffffff, %ebx       # imm = 0xFFFFFFFF
cmpq $0x1, %rax
jne 0x209f
testl %ebp, %ebp
je 0x209d
movq %r14, %rdi
movq $-0x4, %rsi
movl $0x1, %edx
callq 0x10d0
testl %eax, %eax
jne 0x209f
xorl %ebx, %ebx
movl %ebx, %eax
addq $0x10, %rsp
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/simh[P]simtools/extracters/cpytap/tapeio.c
// Function: writeTapeBuffering
int writeTapeBuffering(
  FILE *handle,
  char ch
)
{
  buffer[occupied++] = ch;

  if (occupied == rLength) {
    occupied = 0;
    return WriteTapeRecord(handle, buffer, rLength);
  }
  return 0;
}

// Assembly:
movslq 0xb91f(%rip), %rax      # 0xda04
leal 0x1(%rax), %ecx
movl %ecx, 0xb916(%rip)      # 0xda04
leaq 0xb91b(%rip), %rdx      # 0xda10
movb %sil, (%rax,%rdx)
movl 0xb901(%rip), %edx      # 0xda00
cmpl %edx, %ecx
jne 0x2119
movl $0x0, 0xb8f7(%rip)      # 0xda04
leaq 0xb8fc(%rip), %rsi      # 0xda10
jmp 0x1f4f
xorl %eax, %eax
retq
// File: /workspace/github_c_makefile_star2_O1/evilwombat[P]gopro-fw-tools/goprom.c
// Function: print_usage
static void print_usage(void)
{
	fprintf(stderr, "Usage:\n");
	fprintf(stderr, "	goprom --unpack romfs_section > unpack-romfs.sh\n");
	fprintf(stderr, "	Generate shell script to unpack a romfs section\n");
	fprintf(stderr, "\n");
	fprintf(stderr, "	goprom --update romfs_section > update-romfs.sh\n");
	fprintf(stderr, "	Generate shell script to update files in an existing romfs section\n");
	fprintf(stderr, "	DO NOT DO THIS UNLESS YOU *REALLY* KNOW WHAT YOU ARE DOING.\n");
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq 0x2efc(%rip), %r15      # 0x3ff8
movq (%r15), %rcx
leaq 0x10a4(%rip), %rdi      # 0x21aa
pushq $0x7
popq %rsi
pushq $0x1
popq %rbx
movq %rbx, %rdx
callq 0x10d0
movq (%r15), %rcx
leaq 0x1094(%rip), %rdi      # 0x21b2
pushq $0x31
popq %r14
movq %r14, %rsi
movq %rbx, %rdx
callq 0x10d0
movq (%r15), %rcx
leaq 0x10ad(%rip), %rdi      # 0x21e4
movq %r14, %rsi
movq %rbx, %rdx
callq 0x10d0
movq (%r15), %rsi
pushq $0xa
popq %rdi
callq 0x1070
movq (%r15), %rcx
leaq 0x10bf(%rip), %rdi      # 0x2216
movq %r14, %rsi
movq %rbx, %rdx
callq 0x10d0
movq (%r15), %rcx
leaq 0x10dc(%rip), %rdi      # 0x2248
pushq $0x44
popq %rsi
movq %rbx, %rdx
callq 0x10d0
movq (%r15), %rcx
leaq 0x110c(%rip), %rdi      # 0x228d
pushq $0x3d
popq %rsi
movq %rbx, %rdx
popq %rbx
popq %r14
popq %r15
jmp 0x10d0
// File: /workspace/github_c_makefile_star2_O1/igaw[P]jitterdebugger/jitterdebugger.c
// Function: usage
static void __attribute__((noreturn)) usage(int status)
{
	printf("jitterdebugger [options]\n");
	printf("\n");
	printf("General usage:\n");
	printf("  -h, --help            Print this help\n");
	printf("  -v, --verbose         Print live statistics\n");
	printf("      --version         Print version of jitterdebugger\n");
	printf("  -o, --output DIR      Store collected data into DIR\n");
	printf("  -c, --command CMD	Execute CMD (workload) in background\n");
	printf("\n");
	printf("Sampling:\n");
	printf("  -l, --loops VALUE     Max number of measurements\n");
	printf("  -D, --duration TIME   Specify a length for the test run.\n");
	printf("                        Append 'm', 'h', or 'd' to specify minutes, hours or days.\n");
	printf("  -b, --break VALUE     Stop if max latency exceeds VALUE.\n");
	printf("                        Also the tracers\n");
	printf("  -N, --nsec            Meassurement in nano seconds\n");
	printf("  -i, --interval TIME   Sleep interval for sampling threads in microseconds\n");
	printf("                        or nano seconds (see -N/--nsec)\n");
	printf("  -n			Send samples to host:port\n");
	printf("  -s			Store samples into --output DIR\n");
	printf("\n");
	printf("Threads: \n");
	printf("  -a, --affinity CPUSET Core affinity specification\n");
	printf("                        e.g. 0,2,5-7 starts a thread on first, third and last two\n");
	printf("                        cores on a 8-core system.\n");
	printf("                        May also be set in hexadecimal with '0x' prefix\n");
	printf("  -p, --priority PRI    Worker thread priority. [1..98]\n");

	exit(status);
}

// Assembly:
pushq %rbx
movl %edi, %ebx
leaq 0x2143(%rip), %rdi      # 0x5991
callq 0x20b0
movl $0xa, %edi
callq 0x2050
leaq 0x2146(%rip), %rdi      # 0x59aa
callq 0x20b0
leaq 0x2149(%rip), %rdi      # 0x59b9
callq 0x20b0
leaq 0x2165(%rip), %rdi      # 0x59e1
callq 0x20b0
leaq 0x2187(%rip), %rdi      # 0x5a0f
callq 0x20b0
leaq 0x21b3(%rip), %rdi      # 0x5a47
callq 0x20b0
leaq 0x21dd(%rip), %rdi      # 0x5a7d
callq 0x20b0
movl $0xa, %edi
callq 0x2050
leaq 0x2200(%rip), %rdi      # 0x5ab6
callq 0x20b0
leaq 0x21fe(%rip), %rdi      # 0x5ac0
callq 0x20b0
leaq 0x2225(%rip), %rdi      # 0x5af3
callq 0x20b0
leaq 0x2254(%rip), %rdi      # 0x5b2e
callq 0x20b0
leaq 0x229b(%rip), %rdi      # 0x5b81
callq 0x20b0
leaq 0x22ca(%rip), %rdi      # 0x5bbc
callq 0x20b0
leaq 0x22e7(%rip), %rdi      # 0x5be5
callq 0x20b0
leaq 0x2310(%rip), %rdi      # 0x5c1a
callq 0x20b0
leaq 0x2350(%rip), %rdi      # 0x5c66
callq 0x20b0
leaq 0x237c(%rip), %rdi      # 0x5c9e
callq 0x20b0
leaq 0x2391(%rip), %rdi      # 0x5cbf
callq 0x20b0
movl $0xa, %edi
callq 0x2050
leaq 0x23a2(%rip), %rdi      # 0x5ce6
callq 0x20b0
leaq 0x23a0(%rip), %rdi      # 0x5cf0
callq 0x20b0
leaq 0x23c8(%rip), %rdi      # 0x5d24
callq 0x20b0
leaq 0x240e(%rip), %rdi      # 0x5d76
callq 0x20b0
leaq 0x2434(%rip), %rdi      # 0x5da8
callq 0x20b0
leaq 0x2470(%rip), %rdi      # 0x5df0
callq 0x20b0
movl %ebx, %edi
callq 0x23c0
// File: /workspace/github_c_makefile_star2_O1/igaw[P]jitterdebugger/jitterdebugger.c
// Function: display_stats
static void *display_stats(void *arg)
{
	struct stats *s = arg;
	unsigned int i;

	for (i = 0; i < num_threads; i++)
		printf("\n");

	while (!READ_ONCE(jd_shutdown)) {
		printf(VT100_CURSOR_UP, num_threads);

		__display_stats(s);

		fflush(stdout);
		usleep(100 * 1000); /* 100 ms interval */
	}

	return NULL;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
cmpl $0x0, 0x47b4(%rip)      # 0x84b0
je 0x3d14
xorl %ebp, %ebp
movl $0xa, %edi
callq 0x2050
incl %ebp
cmpl 0x479e(%rip), %ebp      # 0x84b0
jb 0x3d00
cmpl $0x0, 0x4799(%rip)      # 0x84b4
jne 0x3d5e
leaq 0x1a8d(%rip), %r14      # 0x57b1
movq 0x42a5(%rip), %r15      # 0x7fd0
movl 0x477f(%rip), %esi      # 0x84b0
movq %r14, %rdi
xorl %eax, %eax
callq 0x2160
movq %rbx, %rdi
callq 0x3d6b
movq (%r15), %rdi
callq 0x22c0
movl $0x186a0, %edi          # imm = 0x186A0
callq 0x2470
cmpl $0x0, 0x4758(%rip)      # 0x84b4
je 0x3d2b
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/igaw[P]jitterdebugger/jitterdebugger.c
// Function: _display_stats
static void __display_stats(struct stats *s)
{
	unsigned int i;

	for (i = 0; i < num_threads; i++) {
		printf("T:%2u (%5lu) A:%2u C:%10" PRIu64
			" Min:%10" PRIu64 " Avg:%8.2f Max:%10" PRIu64 " "
			VT100_ERASE_EOL "\n",
			i, (long)s[i].tid, s[i].affinity,
			s[i].count,
			s[i].min,
			(double) s[i].total / (double) s[i].count,
			s[i].max);
	}
}

// Assembly:
cmpl $0x0, 0x473e(%rip)      # 0x84b0
je 0x3e15
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rdi, %rbx
addq $0x8, %rbx
xorl %r14d, %r14d
leaq 0x1a25(%rip), %r15      # 0x57b7
movslq (%rbx), %rdx
movl 0x4(%rbx), %ecx
movq 0x38(%rbx), %r8
movq 0x10(%rbx), %r9
movsd 0x30(%rbx), %xmm1
movsd 0x1263(%rip), %xmm2     # 0x5010
unpcklps %xmm2, %xmm1            # xmm1 = xmm1[0],xmm2[0],xmm1[1],xmm2[1]
movapd 0x1268(%rip), %xmm3     # 0x5020
subpd %xmm3, %xmm1
movapd %xmm1, %xmm0
unpckhpd %xmm1, %xmm0            # xmm0 = xmm0[1],xmm1[1]
addsd %xmm1, %xmm0
movq %r8, %xmm1
punpckldq %xmm2, %xmm1    # xmm1 = xmm1[0],xmm2[0],xmm1[1],xmm2[1]
subpd %xmm3, %xmm1
movapd %xmm1, %xmm2
unpckhpd %xmm1, %xmm2            # xmm2 = xmm2[1],xmm1[1]
addsd %xmm1, %xmm2
divsd %xmm2, %xmm0
movq 0x8(%rbx), %rax
movq %rax, (%rsp)
movq %r15, %rdi
movl %r14d, %esi
movb $0x1, %al
callq 0x2160
incq %r14
movl 0x46ad(%rip), %eax      # 0x84b0
addq $0x50, %rbx
cmpq %rax, %r14
jb 0x3d92
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/igaw[P]jitterdebugger/jd_work.c
// Function: start_workload
int start_workload(const char *cmd)
{
	int err;

	if (!cmd)
		return 0;

	bpid = fork();
	if (bpid > 0)
		return 0;
	if (bpid < 0)
		return errno;

	err = setpgid(0,0);
	if (err)
		err_handler(errno, "setpgid()");

	printf("start background workload: %s\n", cmd);
	err = execl("/bin/sh", "sh", "-c", cmd, (char *)0);
	if (err) {
		err_handler(err, "execl()");
		exit(EXIT_FAILURE);
	}

	exit(0);
}

// Assembly:
pushq %rbp
pushq %rbx
pushq %rax
xorl %ebp, %ebp
testq %rdi, %rdi
je 0x4965
movq %rdi, %rbx
callq 0x2450
movl %eax, 0x3b60(%rip)      # 0x84b8
testl %eax, %eax
jg 0x4965
jns 0x496e
callq 0x2070
movl (%rax), %ebp
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
xorl %edi, %edi
xorl %esi, %esi
callq 0x23b0
testl %eax, %eax
je 0x499e
callq 0x2070
movl (%rax), %edi
leaq 0x15c1(%rip), %rsi      # 0x5f4a
leaq 0x15cd(%rip), %rdx      # 0x5f5d
leaq 0x15d0(%rip), %rcx      # 0x5f67
xorl %eax, %eax
callq 0x4184
leaq 0x15d1(%rip), %rdi      # 0x5f76
movq %rbx, %rsi
xorl %eax, %eax
callq 0x2160
leaq 0x15df(%rip), %rdi      # 0x5f95
leaq 0x15dd(%rip), %rsi      # 0x5f9a
leaq 0x15d9(%rip), %rdx      # 0x5f9d
movq %rbx, %rcx
xorl %r8d, %r8d
xorl %eax, %eax
callq 0x2440
testl %eax, %eax
jne 0x49dc
xorl %edi, %edi
callq 0x23c0
leaq 0x15bd(%rip), %rsi      # 0x5fa0
leaq 0x1573(%rip), %rdx      # 0x5f5d
leaq 0x1576(%rip), %rcx      # 0x5f67
movl %eax, %edi
xorl %eax, %eax
callq 0x4184
movl $0x1, %edi
callq 0x23c0
// File: /workspace/github_c_makefile_star2_O1/igaw[P]jitterdebugger/jd_work.c
// Function: stop_workload
void stop_workload(void)
{
	int status;
	int err;

	if (bpid == 0)
		return;

	err = killpg(bpid, SIGTERM);
	if (err)
		err_handler(errno, "kill()");

	if (!waitpid(bpid, &status, 0))
		err_handler(errno, "waitpid()");

	err = WEXITSTATUS(status);
	if (WIFEXITED(status) && err)
		warn_handler("workload exited with %d", err);
}

// Assembly:
movl 0x3aae(%rip), %edi      # 0x84b8
testl %edi, %edi
je 0x4ab8
pushq %rax
movl $0xf, %esi
callq 0x22d0
testl %eax, %eax
je 0x4a44
callq 0x2070
movl (%rax), %edi
leaq 0x1582(%rip), %rsi      # 0x5fb1
leaq 0x1527(%rip), %rdx      # 0x5f5d
leaq 0x1584(%rip), %rcx      # 0x5fc1
xorl %eax, %eax
callq 0x4184
movl 0x3a6e(%rip), %edi      # 0x84b8
leaq 0x4(%rsp), %rsi
xorl %edx, %edx
callq 0x2320
testl %eax, %eax
jne 0x4a7d
callq 0x2070
movl (%rax), %edi
leaq 0x1567(%rip), %rsi      # 0x5fcf
leaq 0x14ee(%rip), %rdx      # 0x5f5d
leaq 0x154b(%rip), %rcx      # 0x5fc1
xorl %eax, %eax
callq 0x4184
movl 0x4(%rsp), %eax
movl %eax, %ecx
shrl $0x8, %ecx
testb $0x7f, %al
setne %al
andl $0xff, %ecx
sete %dl
orb %al, %dl
jne 0x4ab4
leaq 0x1543(%rip), %rdi      # 0x5fe2
leaq 0x14b7(%rip), %rsi      # 0x5f5d
leaq 0x1514(%rip), %rdx      # 0x5fc1
xorl %eax, %eax
callq 0x4253
addq $0x8, %rsp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O1/igaw[P]jitterdebugger/jd_sysinfo.c
// Function: collect_system_info
struct system_info *collect_system_info(void)
{
	struct system_info *info;
	struct utsname buf;
	int err;

	info = malloc(sizeof(*info));
	if (!info)
		err_handler(errno, "malloc()");

	err = uname(&buf);
	if (err)
		err_handler(errno, "Could not retrieve name and information about current kernel");

	info->sysname = jd_strdup(buf.sysname);
	info->nodename = jd_strdup(buf.nodename);
	info->release = jd_strdup(buf.release);
	info->version = jd_strdup(buf.version);
	info->machine = jd_strdup(buf.machine);

	info->cpus_online = get_nprocs();

	return info;
}

// Assembly:
pushq %rbx
subq $0x190, %rsp            # imm = 0x190
movl $0x30, %edi
callq 0x22b0
movq %rax, %rbx
testq %rax, %rax
jne 0x4af9
callq 0x2070
movl (%rax), %edi
leaq 0x7d0(%rip), %rsi       # 0x52b4
leaq 0x1519(%rip), %rdx      # 0x6004
leaq 0x151f(%rip), %rcx      # 0x6011
xorl %eax, %eax
callq 0x4184
leaq 0xa(%rsp), %rdi
callq 0x2180
testl %eax, %eax
je 0x4b2a
callq 0x2070
movl (%rax), %edi
leaq 0x1510(%rip), %rsi      # 0x6025
leaq 0x14e8(%rip), %rdx      # 0x6004
leaq 0x14ee(%rip), %rcx      # 0x6011
xorl %eax, %eax
callq 0x4184
leaq 0xa(%rsp), %rdi
callq 0x477c
movq %rax, (%rbx)
leaq 0x4b(%rsp), %rdi
callq 0x477c
movq %rax, 0x8(%rbx)
leaq 0x8c(%rsp), %rdi
callq 0x477c
movq %rax, 0x10(%rbx)
leaq 0xcd(%rsp), %rdi
callq 0x477c
movq %rax, 0x18(%rbx)
leaq 0x10e(%rsp), %rdi
callq 0x477c
movq %rax, 0x20(%rbx)
callq 0x2460
movl %eax, 0x28(%rbx)
movq %rbx, %rax
addq $0x190, %rsp            # imm = 0x190
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O1/igaw[P]jitterdebugger/jd_sysinfo.c
// Function: store_system_info
void store_system_info(const char *path, struct system_info *sysinfo)
{
	char *buf;
	FILE *fd;
	unsigned int len;

	jd_cp("/proc/cmdline", path);
	jd_cp("/proc/config.gz", path);
	jd_cp("/proc/cpuinfo", path);
	jd_cp("/proc/interrupts", path);
	jd_cp("/proc/sched_debug", path);

	// cpus_online
	fd = jd_fopen(path, "cpus_online", "w");
	if (!fd)
		return;
	fprintf(fd, "%d\n", sysinfo->cpus_online);
	fclose(fd);

	// uname
	fd = jd_fopen(path, "uname", "w");
	if (!fd)
		return;
	fprintf(fd, "%s %s %s %s %s\n",
		sysinfo->sysname,
		sysinfo->nodename,
		sysinfo->release,
		sysinfo->version,
		sysinfo->machine);
	fclose(fd);

	// dmesg
	len = klogctl(SYSLOG_ACTION_SIZE_BUFFER, NULL, 0);
	buf = malloc(len * sizeof(char));
	if (!buf)
		err_handler(errno, "malloc()");

	if (klogctl(SYSLOG_ACTION_READ_ALL, buf, len) < 0)
		return;

	fd = jd_fopen(path, "dmesg", "w");
	if (!fd) {
		free(buf);
		return;
	}

	if (fwrite(buf, sizeof(char), len, fd) != len)
		warn_handler("writing dmesg failed\n");

	fclose(fd);
	free(buf);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x14c9(%rip), %rdi      # 0x606b
movq %rbx, %rsi
callq 0x483d
leaq 0x14c8(%rip), %rdi      # 0x6079
movq %rbx, %rsi
callq 0x483d
leaq 0x14c9(%rip), %rdi      # 0x6089
movq %rbx, %rsi
callq 0x483d
leaq 0x14c8(%rip), %rdi      # 0x6097
movq %rbx, %rsi
callq 0x483d
leaq 0x14ca(%rip), %rdi      # 0x60a8
movq %rbx, %rsi
callq 0x483d
leaq 0x14cd(%rip), %rsi      # 0x60ba
leaq 0x72d(%rip), %rdx       # 0x5321
movq %rbx, %rdi
callq 0x47ac
testq %rax, %rax
je 0x4d3a
movq %rax, %r15
movl 0x28(%r14), %edx
leaq 0x13ed(%rip), %rsi      # 0x6000
movq %rax, %rdi
xorl %eax, %eax
callq 0x2240
movq %r15, %rdi
callq 0x2120
leaq 0x149a(%rip), %rsi      # 0x60c6
leaq 0x6ee(%rip), %rdx       # 0x5321
movq %rbx, %rdi
callq 0x47ac
testq %rax, %rax
je 0x4d3a
movq %rax, %r15
movq (%r14), %rdx
movq 0x8(%r14), %rcx
movq 0x10(%r14), %r8
movq 0x18(%r14), %r9
movq 0x20(%r14), %rax
movq %rax, (%rsp)
leaq 0x1467(%rip), %rsi      # 0x60cc
movq %r15, %rdi
xorl %eax, %eax
callq 0x2240
movq %r15, %rdi
callq 0x2120
movl $0xa, %edi
xorl %esi, %esi
xorl %edx, %edx
callq 0x22e0
movl %eax, %r15d
movq %r15, %rdi
callq 0x22b0
movq %rax, %r14
testq %rax, %rax
jne 0x4cbb
callq 0x2070
movl (%rax), %edi
leaq 0x60e(%rip), %rsi       # 0x52b4
leaq 0x1357(%rip), %rdx      # 0x6004
leaq 0x1428(%rip), %rcx      # 0x60dc
xorl %eax, %eax
callq 0x4184
movl $0x3, %edi
movq %r14, %rsi
movl %r15d, %edx
callq 0x22e0
testl %eax, %eax
js 0x4d3a
leaq 0x1418(%rip), %rsi      # 0x60ee
leaq 0x644(%rip), %rdx       # 0x5321
movq %rbx, %rdi
callq 0x47ac
testq %rax, %rax
je 0x4d29
movq %rax, %rbx
movl $0x1, %esi
movq %r14, %rdi
movq %r15, %rdx
movq %rax, %rcx
callq 0x23d0
cmpq %r15, %rax
je 0x4d21
leaq 0x13e8(%rip), %rdi      # 0x60f4
leaq 0x12f1(%rip), %rsi      # 0x6004
leaq 0x13c2(%rip), %rdx      # 0x60dc
xorl %eax, %eax
callq 0x4253
movq %rbx, %rdi
callq 0x2120
movq %r14, %rdi
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
jmp 0x2040
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/igaw[P]jitterdebugger/jd_sysinfo.c
// Function: free_system_info
void free_system_info(struct system_info *sysinfo)
{
	if (sysinfo->sysname)
		free(sysinfo->sysname);
	if (sysinfo->nodename)
		free(sysinfo->nodename);
	if (sysinfo->release)
		free(sysinfo->release);
	if (sysinfo->version)
		free(sysinfo->version);
	if (sysinfo->machine)
		free(sysinfo->machine);
	free(sysinfo);
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
movq (%rdi), %rdi
testq %rdi, %rdi
je 0x4d55
callq 0x2040
movq 0x8(%rbx), %rdi
testq %rdi, %rdi
je 0x4d63
callq 0x2040
movq 0x10(%rbx), %rdi
testq %rdi, %rdi
je 0x4d71
callq 0x2040
movq 0x18(%rbx), %rdi
testq %rdi, %rdi
je 0x4d7f
callq 0x2040
movq 0x20(%rbx), %rdi
testq %rdi, %rdi
je 0x4d8d
callq 0x2040
movq %rbx, %rdi
popq %rbx
jmp 0x2040
// File: /workspace/github_c_makefile_star2_O1/otrtool[P]otrtool/src/blowfish_gen.c
// Function: modpow
uint32_t modpow(uint32_t b, uint32_t e, uint32_t m)
{
  uint32_t x = 1;

  while (e > 0) {
    if (e % 2 == 0) {
      b = (uint64_t)b*b % m;
      e /= 2;
    }
    else {
      x = (uint64_t)b * x % m;
      e -= 1;
    }
  }
  return x;
}

// Assembly:
testl %esi, %esi
je 0x11e9
movl %edx, %r8d
movl $0x1, %ecx
movl %edi, %eax
testb $0x1, %sil
jne 0x11d0
imulq %rax, %rax
xorl %edx, %edx
divq %r8
movq %rdx, %rdi
shrl %esi
jmp 0x11e3
movl %ecx, %ecx
imulq %rax, %rcx
movq %rcx, %rax
xorl %edx, %edx
divq %r8
decl %esi
movq %rdx, %rcx
testl %esi, %esi
jne 0x11b8
jmp 0x11ee
movl $0x1, %ecx
movl %ecx, %eax
retq
// File: /workspace/github_c_makefile_star2_O1/otrtool[P]otrtool/src/blowfish_gen.c
// Function: s
double s(int n, int j)
{
  int k;
  double x = 0.0;

  for (k=0; k <= n; k++) {
    x += (double)modpow(16, n-k, 8*k+j) / (8*k+j);
    if (x > 1.0) x -= 1.0;
  }

  double d = 1.0;
  double x0 = -1.0;
  for (; x - x0 > 1e-12; k++) {
    x0 = x;
    d /= 16;
    x += d / (8.0*k+j);
  }

  return x;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
testl %edi, %edi
js 0x12b5
movl %esi, %r10d
movl %edi, %r11d
leal 0x1(%rdi), %r9d
xorpd %xmm1, %xmm1
xorl %ebx, %ebx
movsd 0xdf1(%rip), %xmm0      # 0x2008
movsd 0xdf1(%rip), %xmm2      # 0x2010
leaq (%r10,%rbx,8), %r14
movapd %xmm0, %xmm3
cmpq %r11, %rbx
je 0x1276
movl %r14d, %r15d
movl %edi, %ebp
subl %ebx, %ebp
movl $0x10, %ecx
movl $0x1, %r8d
movl %ecx, %eax
testb $0x1, %bpl
jne 0x1256
imulq %rax, %rax
xorl %edx, %edx
divq %r15
movq %rdx, %rcx
shrl %ebp
jmp 0x1267
movl %r8d, %edx
imulq %rdx, %rax
xorl %edx, %edx
divq %r15
decl %ebp
movq %rdx, %r8
testl %ebp, %ebp
jne 0x123e
movl %r8d, %eax
xorps %xmm3, %xmm3
cvtsi2sd %rax, %xmm3
xorps %xmm4, %xmm4
cvtsi2sd %r14d, %xmm4
divsd %xmm4, %xmm3
addsd %xmm3, %xmm1
movapd %xmm1, %xmm3
addsd %xmm2, %xmm3
movapd %xmm0, %xmm4
cmpltsd %xmm1, %xmm4
andpd %xmm4, %xmm3
andnpd %xmm1, %xmm4
orpd %xmm3, %xmm4
movapd %xmm4, %xmm1
incq %rbx
cmpq %r9, %rbx
jne 0x121f
jmp 0x12bc
xorpd %xmm1, %xmm1
xorl %r9d, %r9d
movsd 0xd44(%rip), %xmm0      # 0x2008
addsd %xmm1, %xmm0
ucomisd 0xd48(%rip), %xmm0      # 0x2018
jbe 0x1330
xorps %xmm2, %xmm2
cvtsi2sd %esi, %xmm2
movsd 0xd27(%rip), %xmm3      # 0x2008
movsd 0xd37(%rip), %xmm4      # 0x2020
movsd 0xd37(%rip), %xmm5      # 0x2028
movsd 0xd1f(%rip), %xmm6      # 0x2018
xorps %xmm7, %xmm7
cvtsi2sd %r9d, %xmm7
mulsd %xmm4, %xmm3
mulsd %xmm5, %xmm7
addsd %xmm2, %xmm7
movapd %xmm3, %xmm0
divsd %xmm7, %xmm0
addsd %xmm1, %xmm0
incl %r9d
movapd %xmm0, %xmm7
subsd %xmm1, %xmm7
ucomisd %xmm6, %xmm7
movapd %xmm0, %xmm1
ja 0x12f9
jmp 0x1334
movapd %xmm1, %xmm0
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/otrtool[P]otrtool/src/blowfish_gen.c
// Function: pi_digit16
int pi_digit16(int n)
{
  double d = 16*(4*s(n,1) - 2*s(n,4) - s(n,5) - s(n,6));
  if (d < 0) d -= 1.0;

  ticks += 100ul*(n+1);
  if (ticks >= TICKS_PER_PERCENT) {
    ticks -= TICKS_PER_PERCENT;
    fprintf(stderr, "%d%%\r", ++percent);
    fflush(stderr);
  }

  return (unsigned)(int)d % 16;
}

// Assembly:
pushq %rbx
subq $0x30, %rsp
movl %edi, %ebx
movl $0x1, %esi
callq 0x11f1
movapd %xmm0, 0x20(%rsp)
movl %ebx, %edi
movl $0x4, %esi
callq 0x11f1
movsd %xmm0, 0x18(%rsp)
movl %ebx, %edi
movl $0x5, %esi
callq 0x11f1
movsd %xmm0, 0x10(%rsp)
movl %ebx, %edi
movl $0x6, %esi
callq 0x11f1
incl %ebx
movslq %ebx, %rax
imulq $0x64, %rax, %rdi
addq 0x2cbe(%rip), %rdi      # 0x4050
movq %rdi, 0x2cb7(%rip)      # 0x4050
cmpq $0x21238c8, %rdi        # imm = 0x21238C8
jae 0x1402
movsd 0x18(%rsp), %xmm1
addsd %xmm1, %xmm1
movapd 0x20(%rsp), %xmm3
mulsd 0xc76(%rip), %xmm3      # 0x2030
subsd %xmm1, %xmm3
subsd 0x10(%rsp), %xmm3
subsd %xmm0, %xmm3
mulsd 0xc68(%rip), %xmm3      # 0x2038
movsd 0xc38(%rip), %xmm0      # 0x2010
addsd %xmm3, %xmm0
xorpd %xmm1, %xmm1
movapd %xmm3, %xmm2
cmpltsd %xmm1, %xmm2
andpd %xmm2, %xmm0
andnpd %xmm3, %xmm2
orpd %xmm0, %xmm2
cvttsd2si %xmm2, %eax
andl $0xf, %eax
addq $0x30, %rsp
popq %rbx
retq
movsd %xmm0, 0x8(%rsp)
callq 0x1080
movsd 0x8(%rsp), %xmm0
jmp 0x13a2
// File: /workspace/github_c_makefile_star2_O1/otrtool[P]otrtool/src/blowfish_gen.c
// Function: print_constants
void print_constants(int *digi, int n, int indent)
{
  int i, j;
  uint32_t x;

  for (i=0; i<n; i++) {
    if (i % 4 == 0) {
      if (i > 0)
        printf(",\n");
      printf("%*c", indent, ' ');
    }
    else
      printf(", ");
    for (x=0, j=0; j<8; j++)
      x = 16*x + pi_digit16((*digi)++);
    printf("0x%.8Xul", x);
  }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %edx, 0x4(%rsp)
testl %esi, %esi
jle 0x14af
movl %esi, %ebp
movq %rdi, %r14
leaq 0xc15(%rip), %r13       # 0x204d
xorl %r15d, %r15d
testb $0x3, %r15b
je 0x1451
leaq 0xc02(%rip), %rdi       # 0x204a
xorl %eax, %eax
callq 0x1040
jmp 0x1479
testl %r15d, %r15d
je 0x1462
leaq 0xc01(%rip), %rdi       # 0x205e
callq 0x1030
leaq 0xbdd(%rip), %rdi       # 0x2046
movl 0x4(%rsp), %esi
movl $0x20, %edx
xorl %eax, %eax
callq 0x1040
xorl %eax, %eax
movl $0x8, %r12d
movl %eax, %ebx
shll $0x4, %ebx
movl (%r14), %edi
leal 0x1(%rdi), %eax
movl %eax, (%r14)
callq 0x133b
orl %ebx, %eax
decl %r12d
jne 0x1481
movq %r13, %rdi
movl %eax, %esi
xorl %eax, %eax
callq 0x1040
incl %r15d
cmpl %ebp, %r15d
jne 0x143b
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/otrtool[P]otrtool/src/blowfish_gen.c
// Function: main
int main(void)
{
  int n = 0;
  int i;

  printf(
    "/* initial subkeys and S-boxes for Blowfish\n"
    "   generated by blowfish_gen.c */\n"
    "static const uint32_t P0[18] = {\n");
  print_constants(&n, 18, 2);
  printf(
    "\n};\n"
    "static const uint32_t S0[4][256] = {\n");
  for (i=0; i<4; i++) {
    printf("  {\n");
    print_constants(&n, 256, 4);
    printf("\n  }%s\n", (i < 3) ? "," : "");
  }
  printf("};\n");
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
leaq 0x4(%rsp), %rbx
movl $0x0, (%rbx)
leaq 0xb85(%rip), %rdi       # 0x2060
callq 0x1030
movq %rbx, %rdi
movl $0x12, %esi
movl $0x2, %edx
callq 0x1415
leaq 0xbd6(%rip), %rdi       # 0x20cf
callq 0x1030
movl $0x4, %ebp
leaq 0xbf1(%rip), %r14       # 0x20fb
leaq 0xb4c(%rip), %r12       # 0x205d
leaq 0xb46(%rip), %r13       # 0x205e
leaq 0xb37(%rip), %r15       # 0x2056
movq %r14, %rdi
callq 0x1030
movq %rbx, %rdi
movl $0x100, %esi            # imm = 0x100
movl $0x4, %edx
callq 0x1415
cmpl $0x1, %ebp
movq %r13, %rsi
cmoveq %r12, %rsi
movq %r15, %rdi
xorl %eax, %eax
callq 0x1040
decl %ebp
jne 0x151f
leaq 0xba0(%rip), %rdi       # 0x20f8
callq 0x1030
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/ohkimur[P]the-c-programming-language-2nd-edition-solutions/chapter_6/exercise_6_03/cross_referencer.c
// Function: main
int main(void)
{
  size_t line_number = 1;
  char word[MAX_WORD_LEN];
  struct tree_node *tree_root = NULL;

  while (get_word(word, MAX_WORD_LEN) != EOF)
  {
    if (word[0] == '\n')
    {
      ++line_number;
    }
    else if (isalpha(word[0]))
    {
      if (bin_search(word, linking_words, NR_OF_LINKING_WORDS) == -1)
      {
        tree_root = add_to_tree(tree_root, word, line_number);
      }
    }
  }

  print_tree(tree_root);

  return EXIT_SUCCESS;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x70, %rsp
movq %rsp, %rdi
movl $0x64, %esi
callq 0x1261
cmpl $-0x1, %eax
je 0x1247
movl $0x1, %r14d
xorl %ebx, %ebx
movq %rsp, %r15
leaq 0x2e83(%rip), %r12      # 0x4070
movsbq (%rsp), %r13
cmpq $0xa, %r13
jne 0x11fd
incq %r14
jmp 0x1233
callq 0x10b0
movq (%rax), %rax
testb $0x4, 0x1(%rax,%r13,2)
je 0x1233
movq %r15, %rdi
movq %r12, %rsi
movl $0x1a, %edx
callq 0x1341
cmpl $-0x1, %eax
jne 0x1233
movq %rbx, %rdi
movq %r15, %rsi
movq %r14, %rdx
callq 0x13ae
movq %rax, %rbx
movq %r15, %rdi
movl $0x64, %esi
callq 0x1261
cmpl $-0x1, %eax
jne 0x11ed
jmp 0x1249
xorl %ebx, %ebx
movq %rbx, %rdi
callq 0x1446
xorl %eax, %eax
addq $0x70, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/ohkimur[P]the-c-programming-language-2nd-edition-solutions/chapter_6/exercise_6_03/cross_referencer.c
// Function: add_to_tree
struct tree_node *add_to_tree(struct tree_node *node_p, char *word, size_t line_number)
{
  int cond;

  if (node_p == NULL)
  {
    node_p = (struct tree_node *)malloc(sizeof(struct tree_node));
    node_p->line_numbers = add_to_list(node_p->line_numbers, line_number);
    node_p->word = str_dup(word);
    node_p->left = node_p->right = NULL;
  }
  else if ((cond = strcmp(word, node_p->word)) == 0)
  {
    node_p->line_numbers = add_to_list(node_p->line_numbers, line_number);
  }
  else if (cond < 0)
  {
    node_p->left = add_to_tree(node_p->left, word, line_number);
  }
  else if (cond > 0)
  {
    node_p->right = add_to_tree(node_p->right, word, line_number);
  }

  return node_p;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdx, %r14
movq %rsi, %r15
testq %rdi, %rdi
je 0x13e7
movq %rdi, %rbx
movq (%rdi), %rsi
movq %r15, %rdi
callq 0x1070
testl %eax, %eax
je 0x1418
jns 0x142a
movq 0x10(%rbx), %rdi
movq %r15, %rsi
movq %r14, %rdx
callq 0x13ae
movq %rax, 0x10(%rbx)
jmp 0x143d
movl $0x20, %edi
callq 0x1080
movq %rax, %rbx
movq 0x8(%rax), %rdi
movq %r14, %rsi
callq 0x14ed
movq %rax, 0x8(%rbx)
movq %r15, %rdi
callq 0x1490
movq %rax, (%rbx)
xorps %xmm0, %xmm0
movups %xmm0, 0x10(%rbx)
jmp 0x143d
movq 0x8(%rbx), %rdi
movq %r14, %rsi
callq 0x14ed
movq %rax, 0x8(%rbx)
jmp 0x143d
movq 0x18(%rbx), %rdi
movq %r15, %rsi
movq %r14, %rdx
callq 0x13ae
movq %rax, 0x18(%rbx)
movq %rbx, %rax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/ohkimur[P]the-c-programming-language-2nd-edition-solutions/chapter_6/exercise_6_03/cross_referencer.c
// Function: print_tree
void print_tree(struct tree_node *node_p)
{
  if (node_p != NULL)
  {
    print_tree(node_p->left);
    printf("%s: ", node_p->word);
    print_list(node_p->line_numbers);
    putchar('\n');
    print_tree(node_p->right);
  }
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
leaq 0xc11(%rip), %r14       # 0x2065
testq %rbx, %rbx
je 0x1488
movq 0x10(%rbx), %rdi
callq 0x1446
movq (%rbx), %rsi
movq %r14, %rdi
xorl %eax, %eax
callq 0x1060
movq 0x8(%rbx), %rdi
callq 0x1531
movl $0xa, %edi
callq 0x1030
movq 0x18(%rbx), %rbx
jmp 0x1454
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O1/ohkimur[P]the-c-programming-language-2nd-edition-solutions/chapter_6/exercise_6_03/cross_referencer.c
// Function: add_to_list
struct list_node *add_to_list(struct list_node *list_node_p, size_t line_number)
{
  if (list_node_p == NULL)
  {
    list_node_p = (struct list_node *)malloc(sizeof(struct list_node));
    list_node_p->line_number = line_number;
    list_node_p->next = NULL;
  }
  else
  {
    list_node_p->next = add_to_list(list_node_p->next, line_number);
  }

  return list_node_p;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %r14
testq %rdi, %rdi
je 0x150e
movq %rdi, %rbx
movq 0x8(%rdi), %rdi
movq %r14, %rsi
callq 0x14ed
movq %rax, 0x8(%rbx)
jmp 0x1526
movl $0x10, %edi
callq 0x1080
movq %rax, %rbx
movq %r14, (%rax)
movq $0x0, 0x8(%rax)
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O1/ohkimur[P]the-c-programming-language-2nd-edition-solutions/chapter_6/exercise_6_03/cross_referencer.c
// Function: print_list
void print_list(struct list_node *node_p)
{
  static enum boolean first = TRUE;
  if (node_p != NULL)
  {
    if (first)
    {
      first = FALSE;
      printf("%zu", node_p->line_number);
    }
    else
    {
      printf(", %zu", node_p->line_number);
    }

    print_list(node_p->next);
  }
  else
  {
    first = TRUE;
  }
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %rbx
leaq 0xb2a(%rip), %r14       # 0x206a
leaq 0xb25(%rip), %r15       # 0x206c
testq %rbx, %rbx
je 0x1572
cmpb $0x0, 0x2bf1(%rip)      # 0x4144
movq %r14, %rdi
jne 0x1562
movb $0x1, 0x2be5(%rip)      # 0x4144
movq %r15, %rdi
movq (%rbx), %rsi
xorl %eax, %eax
callq 0x1060
movq 0x8(%rbx), %rbx
jmp 0x1547
movb $0x0, 0x2bcb(%rip)      # 0x4144
popq %rbx
popq %r14
popq %r15
retq