LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O2/LenShustek[P]miditones/miditones.c
// Function: miditones_strlcpy
size_t miditones_strlcpy (char *dst, const char *src, size_t siz) {
   char *d = dst;
   const char *s = src;
   size_t n = siz;
   if (n != 0) {   /* Copy as many bytes as will fit */
      while (--n != 0) {
         if ((*d++ = *s++) == '\0') break; } }
   if (n == 0) {   /* Not enough room in dst, add NUL and traverse rest of src */
      if (siz != 0) *d = '\0';  /* NUL-terminate dst */
      while (*s++) ; }
   return (s - src - 1);        /* count does not include NUL */
}

// Assembly:
movq %rsi, %rax
movq %rsi, %rcx
testq %rdx, %rdx
je 0x1b24
decq %rdx
xorl %ecx, %ecx
cmpq %rcx, %rdx
je 0x1b1d
movb (%rax,%rcx), %sil
movb %sil, (%rdi,%rcx)
incq %rcx
testb %sil, %sil
jne 0x1b00
addq %rax, %rcx
movq %rcx, %rdx
jmp 0x1b30
movb $0x0, (%rdi,%rcx)
addq %rax, %rcx
leaq 0x1(%rcx), %rdx
cmpb $0x0, (%rcx)
movq %rdx, %rcx
jne 0x1b24
notq %rax
addq %rdx, %rax
retq
// File: /workspace/github_c_makefile_star2_O2/LenShustek[P]miditones/miditones.c
// Function: miditones_strlcat
size_t miditones_strlcat (char *dst, const char *src, size_t siz) {
   char *d = dst;
   const char *s = src;
   size_t n = siz;
   size_t dlen;
   /* Find the end of dst and adjust bytes left but don't go past end */
   while (n-- != 0 && *d != '\0') d++;
   dlen = d - dst;
   n = siz - dlen;
   if (n == 0) return (dlen + strlength (s));
   while (*s != '\0') {
      if (n != 1) {
         *d++ = *s;
         n--; }
      s++; }
   *d = '\0';
   return (dlen + (s - src));   /* count does not include NUL */
}

// Assembly:
pushq %rbx
leaq (%rdi,%rdx), %rcx
movq %rdi, %rax
movq %rdx, %r8
subq $0x1, %r8
jb 0x1b55
cmpb $0x0, (%rax)
je 0x1b52
incq %rax
jmp 0x1b42
movq %rax, %rcx
movq %rcx, %rbx
subq %rdi, %rbx
subq %rbx, %rdx
je 0x1b8c
xorl %eax, %eax
pushq $0x1
popq %rdi
movb (%rsi,%rax), %r8b
testb %r8b, %r8b
je 0x1b87
cmpq $0x1, %rdx
jne 0x1b79
movq %rdi, %rdx
jmp 0x1b82
movb %r8b, (%rcx)
incq %rcx
decq %rdx
incq %rax
jmp 0x1b65
movb $0x0, (%rcx)
jmp 0x1b96
movq %rsi, %rdi
callq 0x1ae1
cltq
addq %rbx, %rax
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O2/LenShustek[P]miditones/miditones.c
// Function: charcmp
int charcmp (const char *buf, const char *match) {
   int len, i;
   len = strlength (match);
   for (i = 0; i < len; ++i)
      if (buf[i] != match[i]) return 0;
   return 1; }

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
movq %rsi, %rdi
callq 0x1ae1
xorl %edx, %edx
testl %eax, %eax
cmovlel %edx, %eax
pushq $0x1
popq %rcx
cmpq %rdx, %rax
je 0x1bcf
movb (%r14,%rdx), %sil
leaq 0x1(%rdx), %rdi
cmpb (%rbx,%rdx), %sil
movq %rdi, %rdx
je 0x1bb7
xorl %ecx, %ecx
movl %ecx, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O2/LenShustek[P]miditones/miditones.c
// Function: outfile_items
void outfile_items(int n) {
   outfile_bytecount += n;
   outfile_itemcount += n;
   if (!binaryoutput) {
      if (outfile_itemcount >= outfile_maxitems) {
         if (asm_output) fprintf(outfile, "\n%s", byteop);
         else fprintf(outfile, ",\n");
         outfile_itemcount = 0; }
      else fprintf(outfile, ", "); } }

// Assembly:
movslq %edi, %rax
addq %rax, 0x7574(%rip)      # 0x9188
addl 0x751a(%rip), %eax      # 0x9134
movl %eax, 0x7514(%rip)      # 0x9134
cmpb $0x0, 0x7599(%rip)      # 0x91c0
jne 0x1c92
cmpl 0x74b9(%rip), %eax      # 0x90e8
jge 0x1c4a
movq 0x75b8(%rip), %rcx      # 0x91f0
leaq 0x4c21(%rip), %rdi      # 0x6860
pushq $0x2
popq %rsi
pushq $0x1
popq %rdx
jmp 0x1150
pushq %rax
movq 0x759e(%rip), %rcx      # 0x91f0
cmpb $0x1, 0x7571(%rip)      # 0x91ca
jne 0x1c75
movq 0x747e(%rip), %rdx      # 0x90e0
leaq 0x4c19(%rip), %rsi      # 0x6882
movq %rcx, %rdi
xorl %eax, %eax
callq 0x10b0
jmp 0x1c87
leaq 0x3dd7(%rip), %rdi      # 0x5a53
pushq $0x2
popq %rsi
pushq $0x1
popq %rdx
callq 0x1150
andl $0x0, 0x74a6(%rip)      # 0x9134
addq $0x8, %rsp
retq
// File: /workspace/github_c_makefile_star2_O2/LenShustek[P]miditones/miditones.c
// Function: describe
char *describe(struct noteinfo *np) { // create a description of a note
   // WARNING: returns a pointer to a static string, so only call once per line, in a printf!
   static char notedescription[100];
   int secs = np->time_usec / 1000000;
   sprintf(notedescription, "at %3lu.%06lu sec (%d:%02d), note %d (0x%02X) track %d channel %d volume %d instrument %d",
           secs, np->time_usec % 1000000,
           secs/60, secs % 60,
           np->note, np->note,
           np->track, np->channel, np->volume, np->instrument);
   return notedescription; }

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movl (%rdi), %esi
movl 0x4(%rdi), %r11d
movl $0xf4240, %ecx          # imm = 0xF4240
movl %esi, %eax
xorl %edx, %edx
divl %ecx
movl %eax, %r8d
movl %edx, %ecx
movl $0x3938700, %r9d        # imm = 0x3938700
movl %esi, %eax
xorl %edx, %edx
divl %r9d
movl %eax, %r10d
movw $0x3c, %si
movl %r8d, %eax
xorl %edx, %edx
divw %si
movzwl %dx, %r9d
movl 0xc(%rdi), %r14d
movl 0x8(%rdi), %r15d
movl 0x14(%rdi), %r12d
movl 0x10(%rdi), %r13d
leaq 0x9497(%rip), %rbx      # 0xb180
leaq 0x3d66(%rip), %rsi      # 0x5a56
movq %rbx, %rdi
movl %r8d, %edx
movl %r10d, %r8d
xorl %eax, %eax
pushq %r13
pushq %r12
pushq %r15
pushq %r11
pushq %r14
pushq %r14
callq 0x1130
addq $0x30, %rsp
movq %rbx, %rax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O2/LenShustek[P]miditones/miditones.c
// Function: show_queue
void show_queue(void) { // for debugging: dump the whole event queue
   FILE *fid = logfile;
   if (!logfile) fid = stdout;
   fprintf(fid, "***at output time %lu.%03lu  queue has %d items; oldest at %d, newest at %d\n",
           output_usec / 1000, output_usec % 1000, queue_numitems, queue_oldest_ndx, queue_newest_ndx);
   int ndx = queue_oldest_ndx;
   if (queue_numitems > 0) while (1) {
         struct queue_entry *q = &queue[ndx];
         fprintf(fid, "%2d: %s %s %s\n", ndx, q->cmd == CMD_PLAYNOTE ? "PLAY" : "STOP", q->delete ? "deleted" : "", describe(&q->note));
         if (ndx == queue_newest_ndx) break;
         if (++ndx >= QUEUE_SIZE) ndx = 0; } }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq 0x74a9(%rip), %rbx      # 0x91d8
testq %rbx, %rbx
jne 0x1d3e
movq 0x729d(%rip), %rax      # 0x8fd8
movq (%rax), %rbx
movl 0x7464(%rip), %eax      # 0x91a8
movl $0x3e8, %ecx            # imm = 0x3E8
xorl %edx, %edx
divl %ecx
movl %edx, %ecx
movl 0x948e(%rip), %r8d      # 0xb1e4
movl 0x948b(%rip), %r9d      # 0xb1e8
movl 0x9489(%rip), %edx      # 0xb1ec
movl %edx, (%rsp)
leaq 0x3d43(%rip), %rsi      # 0x5ab0
movq %rbx, %rdi
movl %eax, %edx
xorl %eax, %eax
callq 0x10b0
cmpl $0x0, 0x9464(%rip)      # 0xb1e4
jle 0x1e11
movl 0x945c(%rip), %eax      # 0xb1e8
leaq 0x3d6a(%rip), %r14      # 0x5afd
leaq 0x93e6(%rip), %r15      # 0xb180
movslq %eax, %r12
imulq $0x1c, %r12, %rax
leaq 0x9458(%rip), %rcx      # 0xb200
leaq (%rax,%rcx), %rdi
addq $0x4, %rdi
cmpb $-0x70, -0x4(%rdi)
leaq 0x3d56(%rip), %r13      # 0x5b11
leaq 0x3d4a(%rip), %rax      # 0x5b0c
cmoveq %rax, %r13
cmpb $0x0, -0x3(%rdi)
leaq 0x3d45(%rip), %rbp      # 0x5b16
leaq 0x48b2(%rip), %rax      # 0x668a
cmoveq %rax, %rbp
callq 0x1c93
movq %rbx, %rdi
movq %r14, %rsi
movl %r12d, %edx
movq %r13, %rcx
movq %rbp, %r8
xorl %ebp, %ebp
movq %r15, %r9
xorl %eax, %eax
callq 0x10b0
leal 0x1(%r12), %eax
cmpl $0x63, %r12d
cmovgel %ebp, %eax
cmpl 0x93dd(%rip), %r12d     # 0xb1ec
jne 0x1d9a
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/LenShustek[P]miditones/miditones.c
// Function: show_tonegens
void show_tonegens(void) { // for debugging: dump tone generator status
   FILE *fid = logfile;
   if (!logfile) fid = stdout;
   fprintf(fid, "*** tone generator status at output time %lu.%03lu\n", output_usec / 1000, output_usec % 1000);
   for (int tgnum = 0; tgnum < num_tonegens; ++tgnum) {
      struct tonegen_status *tg = &tonegen[tgnum];
      if (tg->playing)
         fprintf(fid, "#%d: playing note %d (%02X), instrument %d, track %d channel %d%s\n",
                 tgnum, tg->note.note, tg->note.note, tg->note.instrument, tg->note.track, tg->note.channel,
                 tg->stopnote_pending ? ", stopnote pending\n" : "");
      else fprintf(fid, "#%d: idle\n", tgnum); } }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq 0x73a6(%rip), %rbx      # 0x91d8
testq %rbx, %rbx
jne 0x1e41
movq 0x719a(%rip), %rax      # 0x8fd8
movq (%rax), %rbx
movl 0x7361(%rip), %eax      # 0x91a8
movl $0x3e8, %ecx            # imm = 0x3E8
xorl %edx, %edx
divl %ecx
movl %edx, %ecx
leaq 0x3cc5(%rip), %rsi      # 0x5b1e
movq %rbx, %rdi
movl %eax, %edx
xorl %eax, %eax
callq 0x10b0
leaq 0x7394(%rip), %r13      # 0x9200
leaq 0x3cdf(%rip), %r14      # 0x5b52
leaq 0x3d2f(%rip), %r15      # 0x5ba9
xorl %r12d, %r12d
movslq 0x7268(%rip), %rax      # 0x90ec
cmpq %rax, %r12
jge 0x1ef2
cmpb $0x1, (%r13)
jne 0x1ed9
movl 0x10(%r13), %ecx
movl 0x14(%r13), %r9d
movl 0x8(%r13), %r10d
cmpb $0x0, 0x1(%r13)
movl 0xc(%r13), %r11d
leaq 0x47de(%rip), %rbp      # 0x668a
leaq 0x3ce2(%rip), %rax      # 0x5b95
cmovneq %rax, %rbp
subq $0x8, %rsp
movq %rbx, %rdi
movq %r14, %rsi
movl %r12d, %edx
movl %ecx, %r8d
xorl %eax, %eax
pushq %rbp
pushq %r11
pushq %r10
callq 0x10b0
addq $0x20, %rsp
jmp 0x1ee9
movq %rbx, %rdi
movq %r15, %rsi
movl %r12d, %edx
xorl %eax, %eax
callq 0x10b0
incq %r12
addq $0x1c, %r13
jmp 0x1e7d
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/LenShustek[P]miditones/miditones.c
// Function: generate_delay
void generate_delay(unsigned long delta_msec) { // output a delay command
   if (delta_msec > 0) {
      assert(delta_msec <= 0x7fff, "time delta too big");
      if (last_output_was_delay) {
         ++consecutive_delays;
         if (loggen) fprintf(logfile, "      *** this is a consecutive delay, of %d msec\n", delta_msec); }
      last_output_was_delay = true;
      if (binaryoutput) { // output a 15-bit delay in big-endian format
         putc((byte)(delta_msec >> 8), outfile);
         putc((byte)(delta_msec & 0xff), outfile);
         outfile_bytecount += 2; }
      else if (asm_output) {
         fprintf(outfile, "%s%02X", hex, (byte)(delta_msec >> 8));
         outfile_items(1);
         fprintf(outfile, "%s%02X", hex, (byte)(delta_msec & 0xff));
         outfile_items(1); }
      else {
         fprintf(outfile, "%ld,%ld", delta_msec >> 8, delta_msec & 0xff);
         outfile_items(2); } } }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
testq %rdi, %rdi
je 0x259d
movq %rdi, %rbx
xorl %edi, %edi
cmpq $0x8000, %rbx           # imm = 0x8000
setb %dil
leaq 0x3817(%rip), %rsi      # 0x5d3f
callq 0x19f1
cmpb $0x1, 0x6c2c(%rip)      # 0x9160
jne 0x255d
incl 0x6c20(%rip)            # 0x915c
cmpb $0x1, 0x6c80(%rip)      # 0x91c3
jne 0x255d
movq 0x6c8c(%rip), %rdi      # 0x91d8
leaq 0x37ff(%rip), %rsi      # 0x5d52
movq %rbx, %rdx
xorl %eax, %eax
callq 0x10b0
movb $0x1, 0x6bfc(%rip)      # 0x9160
cmpb $0x1, 0x6c55(%rip)      # 0x91c0
jne 0x25a8
movl %ebx, %edi
shrl $0x8, %edi
movl $0xff, %ebp
andl %ebp, %edi
movq 0x6c70(%rip), %rsi      # 0x91f0
callq 0x10a0
andl %ebp, %ebx
movq 0x6c62(%rip), %rsi      # 0x91f0
movl %ebx, %edi
callq 0x10a0
addq $0x2, 0x6beb(%rip)      # 0x9188
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movq 0x6c41(%rip), %rdi      # 0x91f0
cmpb $0x1, 0x6c14(%rip)      # 0x91ca
jne 0x2609
movq 0x6b19(%rip), %rdx      # 0x90d8
movl %ebx, %ecx
shrl $0x8, %ecx
movl $0xff, %r15d
andl %r15d, %ecx
leaq 0x36de(%rip), %r14      # 0x5cb2
movq %r14, %rsi
xorl %eax, %eax
callq 0x10b0
pushq $0x1
popq %rbp
movl %ebp, %edi
callq 0x1c0a
movq 0x6c01(%rip), %rdi      # 0x91f0
movq 0x6ae2(%rip), %rdx      # 0x90d8
andl %r15d, %ebx
movq %r14, %rsi
movl %ebx, %ecx
xorl %eax, %eax
callq 0x10b0
movl %ebp, %edi
jmp 0x2624
movq %rbx, %rdx
shrq $0x8, %rdx
movzbl %bl, %ecx
leaq 0x376b(%rip), %rsi      # 0x5d85
xorl %eax, %eax
callq 0x10b0
pushq $0x2
popq %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x1c0a
// File: /workspace/github_c_makefile_star2_O2/LenShustek[P]miditones/miditones.c
// Function: queue_find_playnote
int queue_find_playnote(int search_ndx) {
   if (loggen) fprintf(logfile, "      queue_find_playnote(%d), %s: ", search_ndx, describe(&queue[search_ndx].note));
   for (int ndx = queue_newest_ndx;;) {
      if (ndx != search_ndx // don't look at the entry we're trying to match
            && !queue[ndx].delete // don't re-find queue entries already deleted
            && queue[ndx].cmd == CMD_PLAYNOTE // must match playnote
            && queue[ndx].note.channel == queue[search_ndx].note.channel //also channel, track, note, and instrument
            && queue[ndx].note.track == queue[search_ndx].note.track
            && queue[ndx].note.note == queue[search_ndx].note.note
            && queue[ndx].note.instrument == queue[search_ndx].note.instrument ) {
         if (loggen) fprintf(logfile, "found ndx %d\n", ndx);
         return ndx; }
      if (ndx == queue_oldest_ndx) break;
      if (--ndx < 0) ndx = QUEUE_SIZE - 1; }
   if (loggen) fprintf(logfile, "not found\n");
   return -1; }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %edi, %ebp
cmpb $0x0, 0x68fc(%rip)      # 0x91c3
leaq 0x8932(%rip), %r14      # 0xb200
je 0x2907
movq 0x6901(%rip), %rbx      # 0x91d8
movslq %ebp, %r15
imulq $0x1c, %r15, %rax
leaq (%rax,%r14), %rdi
addq $0x4, %rdi
callq 0x1c93
leaq 0x35be(%rip), %rsi      # 0x5eb0
leaq 0x8887(%rip), %rcx      # 0xb180
movq %rbx, %rdi
movl %ebp, %edx
xorl %eax, %eax
callq 0x10b0
jmp 0x290a
movslq %ebp, %r15
movl 0x88dc(%rip), %ebx      # 0xb1ec
imulq $0x1c, %r15, %rax
addq %r14, %rax
addq $0x4, %rax
movl 0x88c7(%rip), %ecx      # 0xb1e8
pushq $0x63
popq %rdx
cmpl %ebp, %ebx
je 0x295f
movslq %ebx, %rsi
imulq $0x1c, %rsi, %rsi
cmpb $0x0, 0x1(%rsi,%r14)
jne 0x295f
addq %r14, %rsi
cmpb $-0x70, (%rsi)
jne 0x295f
movl 0xc(%rsi), %edi
cmpl 0x8(%rax), %edi
jne 0x295f
movl 0x8(%rsi), %edi
cmpl 0x4(%rax), %edi
jne 0x295f
movl 0x10(%rsi), %edi
cmpl 0xc(%rax), %edi
jne 0x295f
movl 0x14(%rsi), %esi
cmpl 0x10(%rax), %esi
je 0x29a1
cmpl %ecx, %ebx
je 0x296f
testl %ebx, %ebx
leal -0x1(%rbx), %esi
cmovlel %edx, %esi
movl %esi, %ebx
jmp 0x2924
pushq $-0x1
popq %rbx
cmpb $0x1, 0x684a(%rip)      # 0x91c3
jne 0x2994
movq 0x6856(%rip), %rcx      # 0x91d8
leaq 0x3559(%rip), %rdi      # 0x5ee2
pushq $0xa
popq %rsi
pushq $0x1
popq %rdx
callq 0x1150
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
cmpb $0x1, 0x681b(%rip)      # 0x91c3
jne 0x2994
movq 0x6827(%rip), %rdi      # 0x91d8
leaq 0x351c(%rip), %rsi      # 0x5ed4
movl %ebx, %edx
xorl %eax, %eax
callq 0x10b0
jmp 0x2994
// File: /workspace/github_c_makefile_star2_O2/LenShustek[P]miditones/miditones.c
// Function: queue_find_stopnote
int queue_find_stopnote(int search_ndx) {
   if (loggen) fprintf(logfile, "      queue_find_stopnote(%d), %s: ", search_ndx, describe(&queue[search_ndx].note));
   for (int ndx = queue_newest_ndx;;) {
      if (ndx != search_ndx // don't look at the entry we're trying to match
            && !queue[ndx].delete // don't re-find queue entries already deleted
            && queue[ndx].cmd == CMD_STOPNOTE // must match stopnote
            && queue[ndx].note.time_usec == queue[search_ndx].note.time_usec // also time, note, and instrument
            && queue[ndx].note.note == queue[search_ndx].note.note
            && queue[ndx].note.instrument == queue[search_ndx].note.instrument) {
         if (loggen) fprintf(logfile, "found ndx %d\n", ndx);
         return ndx; }
      if (ndx == queue_oldest_ndx) break;
      if (--ndx < 0) ndx = QUEUE_SIZE - 1; }
   if (loggen) fprintf(logfile, "not found\n");
   return -1; }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %edi, %ebp
cmpb $0x0, 0x67f0(%rip)      # 0x91c3
leaq 0x8826(%rip), %r14      # 0xb200
je 0x2a13
movq 0x67f5(%rip), %rbx      # 0x91d8
movslq %ebp, %r15
imulq $0x1c, %r15, %rax
leaq (%rax,%r14), %rdi
addq $0x4, %rdi
callq 0x1c93
leaq 0x34ef(%rip), %rsi      # 0x5eed
leaq 0x877b(%rip), %rcx      # 0xb180
movq %rbx, %rdi
movl %ebp, %edx
xorl %eax, %eax
callq 0x10b0
jmp 0x2a16
movslq %ebp, %r15
movl 0x87d0(%rip), %ebx      # 0xb1ec
imulq $0x1c, %r15, %rax
addq %r14, %rax
addq $0x4, %rax
movl 0x87bb(%rip), %ecx      # 0xb1e8
pushq $0x63
popq %rdx
xorl %esi, %esi
cmpl %ebp, %ebx
je 0x2a68
movslq %ebx, %rdi
imulq $0x1c, %rdi, %rdi
cmpb $0x0, 0x1(%rdi,%r14)
jne 0x2a68
addq %r14, %rdi
cmpb (%rdi), %sil
jno 0x2a68
movl 0x4(%rdi), %r8d
cmpl (%rax), %r8d
jne 0x2a68
movl 0x10(%rdi), %r8d
cmpl 0xc(%rax), %r8d
jne 0x2a68
movl 0x14(%rdi), %edi
cmpl 0x10(%rax), %edi
je 0x2aaa
cmpl %ecx, %ebx
je 0x2a78
testl %ebx, %ebx
leal -0x1(%rbx), %edi
cmovlel %edx, %edi
movl %edi, %ebx
jmp 0x2a32
pushq $-0x1
popq %rbx
cmpb $0x1, 0x6741(%rip)      # 0x91c3
jne 0x2a9d
movq 0x674d(%rip), %rcx      # 0x91d8
leaq 0x3450(%rip), %rdi      # 0x5ee2
pushq $0xa
popq %rsi
pushq $0x1
popq %rdx
callq 0x1150
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
cmpb $0x1, 0x6712(%rip)      # 0x91c3
jne 0x2a9d
movq 0x671e(%rip), %rdi      # 0x91d8
leaq 0x3413(%rip), %rsi      # 0x5ed4
movl %ebx, %edx
xorl %eax, %eax
callq 0x10b0
jmp 0x2a9d
// File: /workspace/github_c_makefile_star2_O2/LenShustek[P]miditones/miditones.c
// Function: remove_queue_duplicates
void remove_queue_duplicates(int stop_ndx) {
   int play_ndx, dup_play_ndx, dup_stop_ndx;
   if ((play_ndx = queue_find_playnote(stop_ndx)) >= 0 // find its matching playnote
         && (dup_stop_ndx = queue_find_stopnote(stop_ndx)) >= 0  // find another stopnote for the same note at the same time
         && (dup_play_ndx = queue_find_playnote(dup_stop_ndx)) >= 0 // find its matching playnote
         && queue[dup_play_ndx].note.time_usec == queue[play_ndx].note.time_usec) {  // if it starts at the same time, delete it
      if (loggen) fprintf(logfile, "    remove duplicate, ndxs %d, %d: %s\n", dup_play_ndx, dup_stop_ndx, describe(&queue[dup_play_ndx].note));
      queue[dup_play_ndx].delete = queue[dup_stop_ndx].delete = true; } }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movl %edi, %ebx
callq 0x28b7
testl %eax, %eax
js 0x2b6f
movl %eax, %r14d
movl %ebx, %edi
callq 0x29c3
testl %eax, %eax
js 0x2b6f
movl %eax, %ebx
movl %eax, %edi
callq 0x28b7
testl %eax, %eax
js 0x2b6f
movl %eax, %ebp
movl %eax, %eax
imulq $0x1c, %rax, %rax
leaq 0x86f3(%rip), %r15      # 0xb200
movl 0x4(%rax,%r15), %ecx
movl %r14d, %edx
imulq $0x1c, %rdx, %rdx
cmpl 0x4(%rdx,%r15), %ecx
jne 0x2b6f
leaq (%r15,%rax), %r12
cmpb $0x1, 0x6698(%rip)      # 0x91c3
jne 0x2b5d
leaq (%rax,%r15), %rdi
addq $0x4, %rdi
movq 0x669c(%rip), %r14      # 0x91d8
callq 0x1c93
leaq 0x33c9(%rip), %rsi      # 0x5f11
leaq 0x8631(%rip), %r8       # 0xb180
movq %r14, %rdi
movl %ebp, %edx
movl %ebx, %ecx
xorl %eax, %eax
callq 0x10b0
movl %ebx, %eax
imulq $0x1c, %rax, %rax
movb $0x1, %cl
movb %cl, 0x1(%rax,%r15)
movb %cl, 0x1(%r12)
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/LenShustek[P]miditones/miditones.c
// Function: show_queue_cmd
void show_queue_cmd(timestamp time_usec, byte cmd, int note) {
   printf("debug queue %s note %02X at %6ld\n", cmd == CMD_PLAYNOTE ? "PLAY" : "STOP", note, time_usec);
   struct noteinfo notedata;
   notedata.time_usec = time_usec;
   notedata.track = 0;
   notedata.channel = 0;
   notedata.note = note;
   notedata.instrument = 1;
   notedata.volume = 100;
   queue_cmd(cmd, &notedata);
   show_queue(); }

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
subq $0x20, %rsp
movl %edx, %ebx
movl %esi, %ebp
movl %edi, %r14d
cmpl $0x90, %esi
leaq 0x2da0(%rip), %rax      # 0x5b0c
leaq 0x2d9e(%rip), %rsi      # 0x5b11
cmoveq %rax, %rsi
leaq 0x3217(%rip), %rdi      # 0x5f95
movl %r14d, %ecx
xorl %eax, %eax
callq 0x1080
leaq 0x8(%rsp), %rsi
movl %r14d, (%rsi)
andq $0x0, 0x4(%rsi)
movl %ebx, 0xc(%rsi)
movabsq $0x6400000001, %rax     # imm = 0x6400000001
movq %rax, 0x10(%rsi)
movl %ebp, %edi
callq 0x2b78
addq $0x20, %rsp
popq %rbx
popq %r14
popq %rbp
jmp 0x1d1d
// File: /workspace/github_c_makefile_star2_O2/LenShustek[P]miditones/miditones.c
// Function: process_file_header
void process_file_header (void) {
   struct midi_header *hdr;
   unsigned int time_division;

   chk_bufdata (hdrptr, sizeof (struct midi_header));
   hdr = (struct midi_header *) hdrptr;
   if (!charcmp ((char *) hdr->MThd, "MThd"))
      midi_error ("Missing 'MThd'", hdrptr);
   num_tracks = rev_short (hdr->number_of_tracks);
   time_division = rev_short (hdr->time_division);
   if (time_division < 0x8000)
      ticks_per_beat = time_division;
   else
      ticks_per_beat = ((time_division >> 8) & 0x7f) /* SMTE frames/sec */ *(time_division & 0xff);     /* ticks/SMTE frame */
   if (logparse) {
      fprintf (logfile, "Header size %" PRId32 "\n", rev_long (hdr->header_size));
      fprintf (logfile, "Format type %d\n", rev_short (hdr->format_type));
      fprintf (logfile, "Number of tracks %d\n", num_tracks);
      fprintf (logfile, "Time division %04X\n", time_division);
      fprintf (logfile, "Ticks/beat = %d\n", ticks_per_beat); }
   hdrptr += rev_long (hdr->header_size) + 8;   /* point past header to track header, presumably. */
   return; }

// Assembly:
pushq %rbp
pushq %rbx
pushq %rax
movq 0x8f2c(%rip), %rdi      # 0xbcf0
pushq $0x10
popq %rsi
callq 0x1bd9
movq 0x8f1d(%rip), %rbx      # 0xbcf0
leaq 0x31dd(%rip), %rsi      # 0x5fb7
movq %rbx, %rdi
callq 0x1b9b
testl %eax, %eax
je 0x2ed8
movzwl 0xa(%rbx), %eax
rolw $0x8, %ax
movzwl %ax, %eax
movl %eax, 0x8efd(%rip)      # 0xbcf8
movzwl 0xc(%rbx), %eax
rolw $0x8, %ax
movzwl %ax, %ebp
movl %ebp, %eax
shrl $0x8, %eax
andl $0x7f, %eax
movzbl %bpl, %ecx
imull %eax, %ecx
testw %bp, %bp
cmovnsl %ebp, %ecx
movl %ecx, 0x62eb(%rip)      # 0x910c
cmpb $0x1, 0x639d(%rip)      # 0x91c5
movq %rbx, %rax
jne 0x2ebf
movq 0x63a0(%rip), %rdi      # 0x91d8
movl 0x4(%rbx), %edx
bswapl %edx
leaq 0x3187(%rip), %rsi      # 0x5fcb
xorl %eax, %eax
callq 0x10b0
movq 0x6386(%rip), %rdi      # 0x91d8
movzwl 0x8(%rbx), %eax
rolw $0x8, %ax
movzwl %ax, %edx
leaq 0x3177(%rip), %rsi      # 0x5fdb
xorl %eax, %eax
callq 0x10b0
movq 0x6366(%rip), %rdi      # 0x91d8
movl 0x8e80(%rip), %edx      # 0xbcf8
leaq 0x316c(%rip), %rsi      # 0x5feb
xorl %eax, %eax
callq 0x10b0
movq 0x634b(%rip), %rdi      # 0x91d8
leaq 0x316c(%rip), %rsi      # 0x6000
movl %ebp, %edx
xorl %eax, %eax
callq 0x10b0
movq 0x6334(%rip), %rdi      # 0x91d8
movl 0x6262(%rip), %edx      # 0x910c
leaq 0x3163(%rip), %rsi      # 0x6014
xorl %eax, %eax
callq 0x10b0
movq 0x8e31(%rip), %rax      # 0xbcf0
movl 0x4(%rbx), %ecx
bswapl %ecx
addl $0x8, %ecx
addq %rax, %rcx
movq %rcx, 0x8e1f(%rip)      # 0xbcf0
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
leaq 0x30dd(%rip), %rdi      # 0x5fbc
movq %rbx, %rsi
callq 0x1a3a
// File: /workspace/github_c_makefile_star2_O2/LenShustek[P]miditones/miditones.c
// Function: process_track_header
void process_track_header (int tracknum) {
   struct track_header *hdr;
   unsigned long tracklen;

   chk_bufdata (hdrptr, sizeof (struct track_header));
   hdr = (struct track_header *) hdrptr;
   if (!charcmp ((char *) (hdr->MTrk), "MTrk"))
      midi_error ("Missing 'MTrk'", hdrptr);
   tracklen = rev_long (hdr->track_size);
   if (logparse) fprintf (logfile, "\nTrack %d length %ld\n", tracknum, tracklen);
   hdrptr += sizeof (struct track_header);      /* point past header */
   chk_bufdata (hdrptr, tracklen);
   track[tracknum].trkptr = hdrptr;
   hdrptr += tracklen;          /* point to the start of the next track */
   track[tracknum].trkend = hdrptr;     /* the point past the end of the track */
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movl %edi, %ebx
movq 0x8dfb(%rip), %rdi      # 0xbcf0
pushq $0x8
popq %rsi
callq 0x1bd9
movq 0x8dec(%rip), %r15      # 0xbcf0
leaq 0x311a(%rip), %rsi      # 0x6025
movq %r15, %rdi
callq 0x1b9b
testl %eax, %eax
je 0x2f8c
movl 0x4(%r15), %r14d
bswapl %r14d
cmpb $0x1, 0x62a0(%rip)      # 0x91c5
jne 0x2f48
movq 0x62aa(%rip), %rdi      # 0x91d8
leaq 0x3104(%rip), %rsi      # 0x6039
movl %ebx, %edx
movq %r14, %rcx
xorl %eax, %eax
callq 0x10b0
movq 0x8da8(%rip), %r15      # 0xbcf0
addq $0x8, %r15
movq %r15, 0x8d9d(%rip)      # 0xbcf0
movq %r15, %rdi
movq %r14, %rsi
callq 0x1bd9
movq 0x8d8b(%rip), %rax      # 0xbcf0
movslq %ebx, %rcx
imulq $0x30, %rcx, %rcx
leaq 0x644d(%rip), %rdx      # 0x93c0
movq %rax, (%rcx,%rdx)
addq %r14, %rax
movq %rax, 0x8d6f(%rip)      # 0xbcf0
movq %rax, 0x8(%rcx,%rdx)
popq %rbx
popq %r14
popq %r15
retq
leaq 0x3097(%rip), %rdi      # 0x602a
movq %r15, %rsi
callq 0x1a3a
// File: /workspace/github_c_makefile_star2_O2/LenShustek[P]miditones/miditones.c
// Function: get_varlen
unsigned long get_varlen (uint8_t ** ptr) { // get a MIDI-style integer
   /* Get a 1-4 byte variable-length value and adjust the pointer past it.
   These are a succession of 7-bit values with a MSB bit of zero marking the end */
   unsigned long val = 0;
   for (int i = 0; i < 4; ++i) {
      byte b = *(*ptr)++;
      val = (val << 7) | (b & 0x7f);
      if (!(b & 0x80))
         return val; }
   return val; }

// Assembly:
pushq $0x5
popq %rcx
xorl %eax, %eax
decl %ecx
je 0x2fc1
movq (%rdi), %rdx
leaq 0x1(%rdx), %rsi
movq %rsi, (%rdi)
movzbl (%rdx), %edx
shlq $0x7, %rax
movl %edx, %esi
andl $0x7f, %esi
orq %rsi, %rax
testb %dl, %dl
js 0x2fa0
retq
// File: /workspace/github_c_makefile_star2_O2/LenShustek[P]miditones/miditones.c
// Function: show_noteinfo_slots
void show_noteinfo_slots(int channum) {
   struct channel_status *cp = &channel[channum];
   if (loggen) {
      fprintf(logfile, "notes playing for channel %d:\n", channum);
      for (int ndx = 0; ndx < MAX_CHANNELNOTES; ++ndx)
         if (cp->note_playing[ndx]) {
            struct noteinfo *np = &cp->notes_playing[ndx];
            fprintf(logfile, "  %2d: %s\n", ndx, describe(np)); } } }

// Assembly:
cmpb $0x1, 0x5a27(%rip)      # 0x91c3
jne 0x3836
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movslq %edi, %rdx
imulq $0x194, %rdx, %rbx      # imm = 0x194
leaq 0x6082(%rip), %r14      # 0x9840
leaq (%r14,%rbx), %rbp
movq 0x5a0f(%rip), %rdi      # 0x91d8
leaq 0x2b89(%rip), %rsi      # 0x6359
xorl %eax, %eax
callq 0x10b0
addq %r14, %rbx
addq $0x14, %rbx
leaq 0x2b93(%rip), %r14      # 0x6378
leaq 0x7994(%rip), %r15      # 0xb180
xorl %r12d, %r12d
cmpq $0x10, %r12
je 0x3828
cmpb $0x1, 0x4(%rbp,%r12)
jne 0x381f
movq 0x59d4(%rip), %r13      # 0x91d8
movq %rbx, %rdi
callq 0x1c93
movq %r13, %rdi
movq %r14, %rsi
movl %r12d, %edx
movq %r15, %rcx
xorl %eax, %eax
callq 0x10b0
incq %r12
addq $0x18, %rbx
jmp 0x37ef
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/keithnoguchi[P]pearls-in-action/0xc/main_test.c
// Function: main
int main(void)
{
	int fail = 0;
	int i = 0;

	printf("============================\n");
	printf("Column 0xc: A Sample Problem\n");
	printf("============================\n");

	if (test_genknuth(&i))
		fail++;
	if (bench_genknuth(&i))
		fail++;

	return fail;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
leaq 0x4(%rsp), %rbx
andl $0x0, (%rbx)
leaq 0xe42(%rip), %r14       # 0x2021
movq %r14, %rdi
callq 0x1060
leaq 0xe16(%rip), %rdi       # 0x2004
callq 0x1060
movq %r14, %rdi
callq 0x1060
movq %rbx, %rdi
callq 0x129c
xorl %r14d, %r14d
testl %eax, %eax
setne %r14b
movq %rbx, %rdi
callq 0x1358
leal 0x1(%r14), %ecx
testl %eax, %eax
cmovel %r14d, %ecx
movl %ecx, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O2/keithnoguchi[P]pearls-in-action/0xc/genknuth.c
// Function: genknuth
void genknuth(int m, int n, int x[])
{
	int i, j;

	srandom(time(0));

	j = 0;
	for (i = 0; i < n; i++)
		if (random()%(n-i) < (m-j))
			x[j++] = i;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %rbx
movl %esi, %r14d
movl %edi, %ebp
xorl %r15d, %r15d
xorl %edi, %edi
callq 0x1090
movl %eax, %edi
callq 0x1050
movslq %r14d, %r14
testl %r14d, %r14d
movl $0x0, %r12d
cmovgl %r14d, %r12d
xorl %r13d, %r13d
cmpq %r15, %r12
je 0x128c
callq 0x10a0
cqto
idivq %r14
movl %ebp, %eax
subl %r13d, %eax
cltq
cmpq %rax, %rdx
jge 0x1284
movslq %r13d, %rax
incl %r13d
movl %r15d, (%rbx,%rax,4)
incq %r15
decq %r14
jmp 0x125f
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_c_makefile_star2_O2/niho[P]elmc/src/estack.c
// Function: elmS_stack_new
elmS_stack_t *elmS_stack_new() {
    elmS_stack_t *stack = malloc(sizeof(elmS_stack_t));
    stack->size = 0;
    stack->head = NULL;
    return stack;
}

// Assembly:
pushq %rax
pushq $0x10
popq %rdi
callq 0x1070
andl $0x0, 0x8(%rax)
andq $0x0, (%rax)
popq %rcx
retq
// File: /workspace/github_c_makefile_star2_O2/niho[P]elmc/src/estack.c
// Function: elmS_stack_push
void elmS_stack_push(elmS_stack_t *stack, void *item) {
    elmS_stack_frame_t *frame = malloc(sizeof(elmS_stack_frame_t));
    frame->item = item;
    /* Start of critical section */
    frame->next = stack->head;
    stack->head = frame;
    stack->size++;
    /* End of critical section */
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
pushq $0x10
popq %rdi
callq 0x1070
movq %rbx, (%rax)
movq (%r14), %rcx
movq %rcx, 0x8(%rax)
movq %rax, (%r14)
incl 0x8(%r14)
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O2/aap[P]rx-0/misc/texas.c
// Function: listsyms
void
listsyms(void)
{
	Sym *s;

	qsort(symtab, MAXSYM, sizeof(Sym), cmpsym);
	fprintf(lstfp, "\n    SYMBOL TABLE\n");
	for(s = symtab; s < &symtab[MAXSYM]; s++){
		if((s->type&7) != SymValue)
			continue;
		if(s->supress)
			continue;
		fprintf(lstfp, "%-07s %06o\n", s->name, s->val);
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
leaq 0x3fec(%rip), %rbx      # 0x54a0
leaq -0x22(%rip), %rcx       # 0x1499
pushq $0x18
popq %rdx
movl $0xfa0, %esi            # imm = 0xFA0
movq %rbx, %rdi
callq 0x1050
movq 0x3fbe(%rip), %rcx      # 0x5490
leaq 0x1b75(%rip), %rdi      # 0x304e
pushq $0x12
popq %rsi
pushq $0x1
popq %rdx
callq 0x1160
leaq 0x1b76(%rip), %r14      # 0x3061
xorl %r15d, %r15d
cmpq $0x176ff, %r15          # imm = 0x176FF
ja 0x152c
movl 0x8(%r15,%rbx), %eax
andl $0x7, %eax
cmpl $0x1, %eax
jne 0x1526
cmpl $0x0, 0xc(%r15,%rbx)
jne 0x1526
leaq (%rbx,%r15), %rdx
movq 0x3f79(%rip), %rdi      # 0x5490
movl 0x10(%r15,%rbx), %ecx
movq %r14, %rsi
xorl %eax, %eax
callq 0x10d0
addq $0x18, %r15
jmp 0x14ee
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/aap[P]rx-0/misc/texas.c
// Function: putword
void
putword(word w)
{
	static char left[64];

	if(pass2){
		/* listing */
		sprintf(left, "%06o  %06o\t", dot->val, w);
		list(left);

		fprintf(outfp, "%o: %o\n", dot->val++, w);
	}else{
		// this is probably useless...
		memory[dot->val++] = w;
	}
	dot->val &= W;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movl %edi, %ebx
cmpl $0x0, 0x1b1ac(%rip)     # 0x1cba4
movq 0x1b1c9(%rip), %rax     # 0x1cbc8
movl 0x10(%rax), %edx
je 0x1a56
leaq 0x1b1c5(%rip), %r14     # 0x1cbd0
leaq 0x1701(%rip), %rsi      # 0x3113
movq %r14, %rdi
movl %ebx, %ecx
xorl %eax, %eax
callq 0x1140
movq %r14, %rdi
callq 0x1443
movq 0x1b1e3(%rip), %rdi     # 0x1cc10
movq 0x1b194(%rip), %rax     # 0x1cbc8
movl 0x10(%rax), %edx
leal 0x1(%rdx), %ecx
movl %ecx, 0x10(%rax)
leaq 0x16db(%rip), %rsi      # 0x311f
movl %ebx, %ecx
xorl %eax, %eax
callq 0x10d0
movq 0x1b174(%rip), %rax     # 0x1cbc8
jmp 0x1a66
leal 0x1(%rdx), %ecx
movl %ecx, 0x10(%rax)
leaq 0x1b1bd(%rip), %rcx     # 0x1cc20
movl %ebx, (%rcx,%rdx,4)
andl $0x3ffff, 0x10(%rax)    # imm = 0x3FFFF
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/aap[P]rx-0/misc/texas.c
// Function: writelits
void
writelits(void)
{
	word a;
	static char left[64];

	fprintf(lstfp, "\n    LITERALS\n");
	for(a = litdot; a < litend; a++){
		/* listing */
		sprintf(left, "%06o  %06o\t", a, memory[a]);
		list(left);

		fprintf(outfp, "%o: %o\n", a, memory[a]);
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq 0x3a09(%rip), %rcx      # 0x5490
leaq 0x1699(%rip), %rdi      # 0x3127
pushq $0xe
popq %rsi
pushq $0x1
popq %rdx
callq 0x1160
movl 0x5b1c1(%rip), %ebx     # 0x5cc60
leaq 0x1b17a(%rip), %rax     # 0x1cc20
leaq (%rax,%rbx,4), %r13
leaq 0x5b16f(%rip), %r14     # 0x5cc20
leaq 0x165b(%rip), %r15      # 0x3113
leaq 0x1660(%rip), %r12      # 0x311f
movl 0x5b19f(%rip), %eax     # 0x5cc64
cmpq %rax, %rbx
jae 0x1b05
movl (%r13), %ecx
movq %r14, %rdi
movq %r15, %rsi
movl %ebx, %edx
xorl %eax, %eax
callq 0x1140
movq %r14, %rdi
callq 0x1443
movq 0x1b124(%rip), %rdi     # 0x1cc10
movl (%r13), %ecx
movq %r12, %rsi
movl %ebx, %edx
xorl %eax, %eax
callq 0x10d0
incq %rbx
addq $0x4, %r13
jmp 0x1abf
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/aap[P]rx-0/misc/texas.c
// Function: putlit
word
putlit(word w)
{
	word a;

	maxlits++;
	for(a = litdot; a < MAXMEM; a++)
		if(memory[a] == w)
			return a;
	if(litdot == 0)
		err(1, "error: too many literals");
	a = --litdot;
	memory[a] = w;
	return a;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movl %edi, %ebx
incl 0x5b145(%rip)           # 0x5cc68
movl 0x5b137(%rip), %eax     # 0x5cc60
leaq 0x1b0f0(%rip), %r14     # 0x1cc20
leaq (%r14,%rax,4), %rdx
movq %rax, %rcx
cmpq $0xffff, %rcx           # imm = 0xFFFF
ja 0x1b4d
cmpl %ebx, (%rdx)
je 0x1b76
incq %rcx
addq $0x4, %rdx
jmp 0x1b37
testl %eax, %eax
jne 0x1b68
leaq 0x15de(%rip), %rsi      # 0x3136
pushq $0x1
popq %rdi
xorl %eax, %eax
callq 0x128c
movl 0x5b0f8(%rip), %eax     # 0x5cc60
decl %eax
movl %eax, 0x5b0f0(%rip)     # 0x5cc60
movl %ebx, (%r14,%rax,4)
jmp 0x1b78
movl %ecx, %eax
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/aap[P]rx-0/misc/texas.c
// Function: combine
word
combine(int op, word w1, word w2)
{
	switch(op){
	case 0:
		return w2;
	case '+':
		w1 += w2;
		if(w1 & 01000000)
			w1 += 1;
		return w1 & W;
	case '-':
		w1 += ~w2 & W;
		if(w1 & 01000000)
			w1 += 1;
		return w1 & W;
	case ' ':
	case '!':
		return (w1 | w2) & W;
	case '&':
		return (w1 & w2) & W;
	default:
		panic("unknown operator %c", op);
	}
	return 0;
}

// Assembly:
movl %edi, %eax
leal -0x20(%rax), %ecx
cmpl $0x2, %ecx
jb 0x1ba5
testl %eax, %eax
je 0x1bc7
cmpl $0x26, %eax
je 0x1bbf
cmpl $0x2d, %eax
je 0x1ba9
cmpl $0x2b, %eax
jne 0x1bca
leal (%rdx,%rsi), %eax
btl $0x12, %eax
adcl %esi, %edx
jmp 0x1bc1
orl %esi, %edx
jmp 0x1bc1
notl %edx
movl $0x3ffff, %eax          # imm = 0x3FFFF
andl %eax, %edx
leal (%rdx,%rsi), %ecx
btl $0x12, %ecx
adcl %esi, %edx
andl %eax, %edx
jmp 0x1bc7
andl %esi, %edx
andl $0x3ffff, %edx          # imm = 0x3FFFF
movl %edx, %eax
retq
pushq %rbp
movq %rsp, %rbp
leaq 0x157a(%rip), %rdi      # 0x314f
movl %eax, %esi
xorl %eax, %eax
callq 0x1364
// File: /workspace/github_c_makefile_star2_O2/aap[P]rx-0/misc/texas.c
// Function: main
int
main(int argc, char *argv[])
{
	int i;

	infp = stdin;
	filename = "<stdin>";
	tmpfp = mustopen("tmptmp", "wb");

	initsymtab();

	litdot = MAXMEM;
	dot->val = 040;
	pass2 = 0;
	assemble();

	checkundef();

	pass2 = 1;
	fclose(tmpfp);
	tmpfp = nil;
	infp = mustopen("tmptmp", "rb");
	outfp = mustopen("out.mem", "wb");

	lstfp = mustopen("out.lst", "w");
	litend = dot->val + maxlits;	// dot->val + (MAXMEM-litdot);
	litdot = litend;
	dot->val = 040;
	lineno = 1;
	peekc = 0;
	memset(memory, 0, sizeof(memory));
	assemble();

	writelits();

	fclose(infp);
	fclose(outfp);

	listsyms();

	printf("start: %o\n", startaddr);

	return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq 0x2ffd(%rip), %rax      # 0x4fd8
movq (%rax), %rax
movq %rax, 0x1abc3(%rip)     # 0x1cba8
leaq 0x131e(%rip), %rax      # 0x330a
movq %rax, 0x343d(%rip)      # 0x5430
leaq 0x1318(%rip), %r14      # 0x3312
leaq 0x1318(%rip), %rbx      # 0x3319
movq %r14, %rdi
movq %rbx, %rsi
callq 0x13fa
movq %rax, 0x1ab9d(%rip)     # 0x1cbb0
callq 0x1f77
movl $0x10000, 0x5ac3e(%rip) # imm = 0x10000
movq 0x1ab9f(%rip), %rax     # 0x1cbc8
pushq $0x20
popq %r15
movl %r15d, 0x10(%rax)
andl $0x0, 0x1ab6c(%rip)     # 0x1cba4
callq 0x1ec6
callq 0x1efe
pushq $0x1
popq %r12
movl %r12d, 0x1ab57(%rip)    # 0x1cba4
movq 0x1ab5c(%rip), %rdi     # 0x1cbb0
callq 0x1060
andq $0x0, 0x1ab4f(%rip)     # 0x1cbb0
leaq 0x12b4(%rip), %rsi      # 0x331c
movq %r14, %rdi
callq 0x13fa
movq %rax, 0x1ab31(%rip)     # 0x1cba8
leaq 0x12a1(%rip), %rdi      # 0x331f
movq %rbx, %rsi
callq 0x13fa
movq %rax, 0x1ab83(%rip)     # 0x1cc10
leaq 0x1293(%rip), %rdi      # 0x3327
leaq 0x1294(%rip), %rsi      # 0x332f
callq 0x13fa
movq %rax, 0x33e9(%rip)      # 0x5490
movq 0x1ab1a(%rip), %rax     # 0x1cbc8
movl 0x5abb4(%rip), %ecx     # 0x5cc68
addl 0x10(%rax), %ecx
movl %ecx, 0x5aba7(%rip)     # 0x5cc64
movl %ecx, 0x5ab9d(%rip)     # 0x5cc60
movl %r15d, 0x10(%rax)
movl %r12d, 0x3016(%rip)     # 0x50e4
andl $0x0, 0x1aacb(%rip)     # 0x1cba0
leaq 0x1ab44(%rip), %rdi     # 0x1cc20
movl $0x40000, %edx          # imm = 0x40000
xorl %esi, %esi
callq 0x1080
callq 0x1ec6
callq 0x1a72
movq 0x1aaaf(%rip), %rdi     # 0x1cba8
callq 0x1060
movq 0x1ab0b(%rip), %rdi     # 0x1cc10
callq 0x1060
callq 0x14a3
movl 0x5ab57(%rip), %esi     # 0x5cc6c
leaq 0x1215(%rip), %rdi      # 0x3331
xorl %eax, %eax
callq 0x1070
xorl %eax, %eax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/albinoloverats[P]hide/src/bmp.c
// Function: init
extern image_type_t *init(void)
{
	static image_type_t bmp;
	bmp.type = "BMP";
	bmp.is_type = is_bmp;
	bmp.read = read_bmp;
	bmp.write = write_bmp;
	bmp.info = info_bmp;
	bmp.free = free_bmp;
	return &bmp;
}

// Assembly:
leaq 0xe7d(%rip), %rax       # 0x2000
movq %rax, 0x2ede(%rip)      # 0x4068
leaq 0x2ed7(%rip), %rax      # 0x4068
leaq 0x40(%rip), %rcx        # 0x11d8
movq %rcx, 0x2ed1(%rip)      # 0x4070
leaq 0x7d(%rip), %rcx        # 0x1223
movq %rcx, 0x2ecb(%rip)      # 0x4078
leaq 0x282(%rip), %rcx       # 0x1436
movq %rcx, 0x2ec5(%rip)      # 0x4080
leaq 0x393(%rip), %rcx       # 0x1555
movq %rcx, 0x2ebf(%rip)      # 0x4088
leaq 0x39f(%rip), %rcx       # 0x156f
movq %rcx, 0x2eb9(%rip)      # 0x4090
retq
// File: /workspace/github_c_makefile_star2_O2/albinoloverats[P]hide/src/bmp.c
// Function: is_bmp
static bool is_bmp(char *file_name)
{
	FILE *bmp = fopen(file_name, "rb");
	if (!bmp)
		return false;
	uint8_t header[2];
	fread(header, sizeof header, 1, bmp);
	fclose(bmp);
	return !memcmp(HEADER, header, sizeof header);
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
leaq 0xe21(%rip), %rsi       # 0x2004
callq 0x1070
testq %rax, %rax
je 0x1219
movq %rax, %rbx
leaq 0x6(%rsp), %r14
pushq $0x2
popq %rsi
pushq $0x1
popq %rdx
movq %r14, %rdi
movq %rax, %rcx
callq 0x1050
movq %rbx, %rdi
callq 0x1060
cmpw $0x4d42, (%r14)         # imm = 0x4D42
sete %al
jmp 0x121b
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O2/albinoloverats[P]hide/src/bmp.c
// Function: write_bmp
static int write_bmp(image_info_t image_info, void (*progress_update)(uint64_t, uint64_t))
{
	errno = EXIT_SUCCESS;

	FILE *bmp = fopen(image_info.file, "wb");
	if (!bmp)
		return errno;

	bmp_extra_t *extra = image_info.extra;
	fwrite(extra->data, extra->size, 1, bmp);

	uint32_t padding = image_info.width % 4;
	if (padding == 4)
		padding = 0;

	fseek(bmp, extra->size, SEEK_SET);
	for (uint64_t y = 0; y < image_info.height; y++)
	{
		fwrite(image_info.buffer[y], image_info.width, image_info.bpp, bmp);
		free(image_info.buffer[y]);
		uint32_t ignored = 0;
		if (padding)
			fwrite(&ignored, padding, 1, bmp);
		if (progress_update)
			progress_update(y, image_info.height);
	}
	free(image_info.buffer);

	free(extra->data);
	free(extra);

	fclose(bmp);

	return errno;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rdi, %r15
callq 0x1040
movq %rax, %rbx
andl $0x0, (%rax)
movq 0x60(%rsp), %rdi
leaq 0xba9(%rip), %rsi       # 0x2007
callq 0x1070
testq %rax, %rax
je 0x1544
movq %rax, %r14
movq %rbx, 0x10(%rsp)
leaq 0x60(%rsp), %r12
movq 0x48(%r12), %rbx
movq 0x8(%rbx), %rdi
movl (%rbx), %esi
pushq $0x1
popq %rdx
movq %rax, %rcx
callq 0x10a0
movq 0x30(%r12), %rbp
movq %rbx, 0x8(%rsp)
movl (%rbx), %esi
xorl %ebx, %ebx
movq %r14, %rdi
xorl %edx, %edx
callq 0x1090
movq %r12, %rax
movq 0x28(%r12), %r13
movq 0x40(%r12), %r12
movzwl 0x38(%rax), %eax
movq %rax, 0x18(%rsp)
movq %rbp, 0x20(%rsp)
andl $0x3, %ebp
cmpq %r13, %rbx
jae 0x1519
movq (%r12,%rbx,8), %rdi
movq 0x20(%rsp), %rsi
movq 0x18(%rsp), %rdx
movq %r14, %rcx
callq 0x10a0
movq (%r12,%rbx,8), %rdi
callq 0x1030
andl $0x0, 0x4(%rsp)
testq %rbp, %rbp
je 0x1506
leaq 0x4(%rsp), %rdi
movq %rbp, %rsi
pushq $0x1
popq %rdx
movq %r14, %rcx
callq 0x10a0
testq %r15, %r15
je 0x1514
movq %rbx, %rdi
movq %r13, %rsi
callq *%r15
incq %rbx
jmp 0x14c5
movq %r12, %rdi
callq 0x1030
movq 0x8(%rsp), %rbx
movq 0x8(%rbx), %rdi
callq 0x1030
movq %rbx, %rdi
callq 0x1030
movq %r14, %rdi
callq 0x1060
movq 0x10(%rsp), %rbx
movl (%rbx), %eax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/albinoloverats[P]hide/src/bmp.c
// Function: free_bmp
static void free_bmp(image_info_t image_info)
{
	for (uint64_t y = 0; y < image_info.height; y++)
		free(image_info.buffer[y]);
	free(image_info.buffer);
	bmp_extra_t *extra = image_info.extra;
	free(extra->data);
	free(extra);
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
leaq 0x30(%rsp), %r14
movq 0x28(%r14), %r15
movq 0x40(%r14), %rbx
xorl %r12d, %r12d
cmpq %r15, %r12
jae 0x159a
movq (%rbx,%r12,8), %rdi
callq 0x1030
incq %r12
jmp 0x1587
movq %rbx, %rdi
callq 0x1030
movq 0x48(%r14), %rbx
movq 0x8(%rbx), %rdi
callq 0x1030
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
jmp 0x1030
// File: /workspace/github_c_makefile_star2_O2/gadget114514[P]fatfs-example/rf2.c
// Function: main
void main()
{
  FIL f;
  int w;
  FATFS fs;
  char buf[1024];
  FCHK(f_mount(&fs, "", 1)); 
  if (f_open(&f, "0:a.txt", FA_OPEN_EXISTING|FA_READ) == FR_OK) {
    FCHK(f_read(&f, buf, 9, &w));
    printf("open & write %d %s\n", w, buf);
  } else {
    printf("open error\n");
    FCHK(f_close(&f));    
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x8b8, %rsp            # imm = 0x8B8
leaq 0x42d9(%rip), %rsi      # 0x548c
leaq -0x4c8(%rbp), %rdi
pushq $0x1
popq %rbx
movl %ebx, %edx
callq 0x142c
movl %eax, %r14d
movl %eax, %edi
callq 0x12a6
leaq 0x3e2f(%rip), %rdi      # 0x5004
leaq 0x3e3b(%rip), %rsi      # 0x5017
movl %r14d, %edx
movq %rax, %rcx
xorl %eax, %eax
callq 0x1050
leaq 0x3e3b(%rip), %rsi      # 0x502b
leaq -0x270(%rbp), %rdi
movl %ebx, %edx
callq 0x17db
testl %eax, %eax
je 0x123f
leaq 0x41e8(%rip), %rdi      # 0x53f1
callq 0x1030
leaq -0x270(%rbp), %rdi
callq 0x2913
movl %eax, %ebx
movl %eax, %edi
callq 0x12a6
leaq 0x3dda(%rip), %rdi      # 0x5004
leaq 0x3e2d(%rip), %rsi      # 0x505e
movl %ebx, %edx
movq %rax, %rcx
xorl %eax, %eax
callq 0x1050
jmp 0x1298
leaq -0x270(%rbp), %rdi
leaq -0x8d0(%rbp), %rbx
pushq $0x9
popq %rdx
leaq -0x1c(%rbp), %r14
movq %rbx, %rsi
movq %r14, %rcx
callq 0x209c
movl %eax, %r15d
movl %eax, %edi
callq 0x12a6
leaq 0x3d94(%rip), %rdi      # 0x5004
leaq 0x3dbc(%rip), %rsi      # 0x5033
movl %r15d, %edx
movq %rax, %rcx
xorl %eax, %eax
callq 0x1050
movl (%r14), %esi
leaq 0x3dbc(%rip), %rdi      # 0x504a
movq %rbx, %rdx
xorl %eax, %eax
callq 0x1050
addq $0x8b8, %rsp            # imm = 0x8B8
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/snej[P]zdelta/zdc.c
// Function: main_single
int main_single(int argc, char *argv[]){
  FILE *fp_ref;
  zd_mem_buffer tar_buf;
  zd_mem_buffer ref_buf;
  Bytef *delta = NULL;
  uLong d_size = 0;

  /* open and check the input files */
  if( !(fp_ref = fopen(argv[1],"rb")) )
  {
    perror(argv[1]);
    exit(0);
  }

  if(argc>2 && (!freopen(argv[2],"rb",stdin)))
  {
    perror(argv[2]); 
    exit(0);
  }

  /* copy input data to memory */
  if(dread_file(fp_ref,&ref_buf) < 0) perror(argv[1]);
  if(dread_file(stdin,&tar_buf) < 0) perror(argv[2]);

  /* compress the data */
  if(zd_compress1((const Bytef*) ref_buf.buffer, ref_buf.pos - ref_buf.buffer,
		  (const Bytef*) tar_buf.buffer, tar_buf.pos - tar_buf.buffer,
		  &delta, &d_size) == ZD_OK){

    /* successfull compression write the delta to a file */
    if(argc>3 && (!freopen(argv[3],"wb",stdout))){
      perror(argv[3]);
      exit(0);
    }
    if(d_size != fwrite(delta, sizeof(char), d_size, stdout)) perror("ouput");
  }
  
  /* release memory */
  free(delta);
  zd_free(&tar_buf);
  zd_free(&ref_buf);

  /* close files */
  fclose(fp_ref);

  return 0;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
subq $0x40, %rsp
movq %rsi, %r14
movl %edi, %ebp
andq $0x0, (%rsp)
andq $0x0, 0x8(%rsp)
movq 0x8(%rsi), %rdi
leaq 0x7d85(%rip), %rsi      # 0x9004
callq 0x1120
testq %rax, %rax
je 0x13b9
movq %rax, %rbx
cmpl $0x3, %ebp
jl 0x12b8
movq 0x10(%r14), %rdi
movq 0xcd30(%rip), %rax      # 0xdfd0
movq (%rax), %rdx
leaq 0x7d5a(%rip), %rsi      # 0x9004
callq 0x10a0
testq %rax, %rax
je 0x13bf
leaq 0x10(%rsp), %rsi
movq %rbx, %rdi
callq 0x1539
testl %eax, %eax
js 0x138f
movq 0xccfc(%rip), %rax      # 0xdfd0
movq (%rax), %rdi
leaq 0x28(%rsp), %rsi
callq 0x1539
testl %eax, %eax
js 0x139d
movq 0x10(%rsp), %rdi
movq 0x18(%rsp), %rsi
subq %rdi, %rsi
movq 0x28(%rsp), %rdx
movq 0x30(%rsp), %rcx
subq %rdx, %rcx
movq %rsp, %r8
leaq 0x8(%rsp), %r9
callq 0x16d9
testl %eax, %eax
jne 0x135f
cmpl $0x4, %ebp
jl 0x133c
movq 0x18(%r14), %rdi
movq 0xcca4(%rip), %rax      # 0xdfc8
movq (%rax), %rdx
leaq 0x7cd9(%rip), %rsi      # 0x9007
callq 0x10a0
testq %rax, %rax
je 0x13c5
movq 0x8(%rsp), %r14
movq (%rsp), %rdi
movq 0xcc7c(%rip), %rax      # 0xdfc8
movq (%rax), %rcx
pushq $0x1
popq %rsi
movq %r14, %rdx
callq 0x1150
cmpq %rax, %r14
jne 0x13ab
movq (%rsp), %rdi
callq 0x1030
leaq 0x28(%rsp), %rdi
callq 0x14bf
leaq 0x10(%rsp), %rdi
callq 0x14bf
movq %rbx, %rdi
callq 0x1060
xorl %eax, %eax
addq $0x40, %rsp
popq %rbx
popq %r14
popq %rbp
retq
movq 0x8(%r14), %rdi
callq 0x1130
jmp 0x12cd
movq 0x10(%r14), %rdi
callq 0x1130
jmp 0x12e9
leaq 0x7c58(%rip), %rdi      # 0x900a
callq 0x1130
jmp 0x135f
movq 0x8(%r14), %rdi
jmp 0x13c9
movq 0x10(%r14), %rdi
jmp 0x13c9
movq 0x18(%r14), %rdi
callq 0x1130
xorl %edi, %edi
callq 0x1140