// File: /workspace/github_c_makefile_star2_O2/LenShustek[P]miditones/miditones_scroll.c
// Function: print_status
void print_status (void) {
   unsigned gen;
   bool any_instr_changed = false;
   for (gen = 0; gen < num_tonegens; ++gen)
      any_instr_changed |= gen_instrument_changed[gen];
   if (any_instr_changed) {
      if (codeoutput)
         fprintf (outfile, "//");
      fprintf (outfile, "%15s", "");
      for (gen = 0; gen < num_tonegens; ++gen) {
         if (gen_instrument_changed[gen]) {
            gen_instrument_changed[gen] = false;
            fprintf (outfile, "%6s", instrumentname[gen_instrument[gen]]); }
         else
            fprintf (outfile, "%6s", "");
         if (expect_volume && !ignore_volume)
            fprintf (outfile, "%5s", ""); }
      fprintf (outfile, "\n"); }

   if (codeoutput)
      fprintf (outfile, "/*");  // start comment
   // print the current timestamp
   fprintf (outfile, "%7d.%03d ", timenow / 1000, timenow % 1000);
   // print the current status of all tone generators
   for (gen = 0; gen < num_tonegens; ++gen) {
      if (showhex && gen_note[gen] != SILENT)
         fprintf(outfile, " 0x%02X ", gen_note[gen]);
      else fprintf (outfile, "%6s", gen_note[gen] == SILENT ? " " : notename[gen_note[gen]]);
      if (expect_volume && !ignore_volume)
         if (gen_note[gen] == SILENT)
            fprintf (outfile, "     ");
         else
            fprintf (outfile, " v%-3d", gen_volume[gen]); }
   // display the hex commands that created these changes
   fprintf (outfile, "%3u.%03u %c", delay/1000, delay%1000, warning ? '!' : ' ');
   if (showbytestream) fprintf (outfile, "%04X: ", (unsigned int) (lastbufptr - buffer));
   warning = false;
   if (codeoutput)
      fprintf (outfile, "*/ "); // end comment
   if (showbytestream) for (; lastbufptr <= bufptr; ++lastbufptr)
         fprintf (outfile, codeoutput ? "0x%02X," : "%02X ", *lastbufptr);
   fprintf (outfile, "\n");
   lastbufptr = bufptr + 1; }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl 0x4b76(%rip), %eax      # 0x70b0
xorl %ecx, %ecx
leaq 0x4ddd(%rip), %r12      # 0x7320
xorl %edx, %edx
cmpq %rcx, %rax
je 0x2556
andb $0x1, %dl
orb (%rcx,%r12), %dl
incq %rcx
jmp 0x2545
testb $0x1, %dl
je 0x263a
cmpb $0x1, 0x4b8a(%rip)      # 0x70f0
jne 0x2581
movq 0x4d91(%rip), %rcx      # 0x7300
leaq 0x2082(%rip), %rdi      # 0x45f8
pushq $0x2
popq %rsi
pushq $0x1
popq %rdx
callq 0x2130
movq 0x4d78(%rip), %rdi      # 0x7300
leaq 0x206c(%rip), %rsi      # 0x45fb
leaq 0x23c0(%rip), %rbx      # 0x4956
movq %rbx, %rdx
xorl %eax, %eax
callq 0x20b0
leaq 0x4d89(%rip), %r13      # 0x7330
leaq 0x4432(%rip), %rbp      # 0x69e0
leaq 0x204b(%rip), %r14      # 0x4600
xorl %r15d, %r15d
movl 0x4af2(%rip), %eax      # 0x70b0
cmpq %rax, %r15
jae 0x262b
cmpb $0x1, (%r15,%r12)
jne 0x25e4
movb $0x0, (%r15,%r12)
movq 0x4d2a(%rip), %rdi      # 0x7300
movslq (%r13), %rax
movq (%rbp,%rax,8), %rdx
movq %r14, %rsi
jmp 0x25f1
movq 0x4d15(%rip), %rdi      # 0x7300
movq %r14, %rsi
movq %rbx, %rdx
xorl %eax, %eax
callq 0x20b0
cmpb $0x1, 0x4af2(%rip)      # 0x70f1
jne 0x2622
cmpb $0x0, 0x4aea(%rip)      # 0x70f2
jne 0x2622
movq 0x4cef(%rip), %rdi      # 0x7300
leaq 0x1fec(%rip), %rsi      # 0x4604
movq %rbx, %rdx
xorl %eax, %eax
callq 0x20b0
incq %r15
addq $0x4, %r13
jmp 0x25b8
movq 0x4cce(%rip), %rsi      # 0x7300
pushq $0xa
popq %rdi
callq 0x20a0
cmpb $0x1, 0x4aaf(%rip)      # 0x70f0
jne 0x265c
movq 0x4cb6(%rip), %rcx      # 0x7300
leaq 0x1fb7(%rip), %rdi      # 0x4608
pushq $0x2
popq %rsi
pushq $0x1
popq %rdx
callq 0x2130
movq 0x4c9d(%rip), %rdi      # 0x7300
movq 0x4a7e(%rip), %rax      # 0x70e8
movl $0x3e8, %ecx            # imm = 0x3E8
xorl %edx, %edx
divq %rcx
movq %rdx, %rcx
leaq 0x1f8d(%rip), %rsi      # 0x460b
movq %rax, %rdx
xorl %eax, %eax
callq 0x20b0
leaq 0x4ce1(%rip), %r15      # 0x7370
leaq 0x1f8c(%rip), %r12      # 0x4622
leaq 0x1f63(%rip), %r14      # 0x4600
leaq 0x1988(%rip), %r13      # 0x402c
xorl %ebp, %ebp
xorl %ebx, %ebx
movl 0x4a02(%rip), %eax      # 0x70b0
cmpq %rax, %rbx
jae 0x2761
movslq (%rbp,%r15), %rdx
cmpb $0x1, 0x4a30(%rip)      # 0x70f3
jne 0x26e1
movq 0x4c34(%rip), %rdi      # 0x7300
cmpl $-0x1, %edx
je 0x26f7
leaq 0x1f3d(%rip), %rsi      # 0x4615
xorl %eax, %eax
callq 0x20b0
jmp 0x2704
movq 0x4c18(%rip), %rdi      # 0x7300
cmpl $-0x1, %edx
je 0x26f7
movslq (%r13,%rdx,4), %rdx
addq %r13, %rdx
jmp 0x26fa
movq %r12, %rdx
movq %r14, %rsi
xorl %eax, %eax
callq 0x20b0
cmpb $0x1, 0x49e6(%rip)      # 0x70f1
jne 0x2755
cmpb $0x0, 0x49de(%rip)      # 0x70f2
jne 0x2755
cmpl $-0x1, (%rbp,%r15)
movq 0x4bdd(%rip), %rcx      # 0x7300
je 0x2743
leaq 0x4c84(%rip), %rax      # 0x73b0
movl (%rbp,%rax), %edx
movq %rcx, %rdi
leaq 0x1eea(%rip), %rsi      # 0x4624
xorl %eax, %eax
callq 0x20b0
jmp 0x2755
leaq 0x1ed4(%rip), %rdi      # 0x461e
pushq $0x5
popq %rsi
pushq $0x1
popq %rdx
callq 0x2130
incq %rbx
addq $0x4, %rbp
jmp 0x26a8
movq 0x4b98(%rip), %rdi      # 0x7300
movl 0x4c82(%rip), %eax      # 0x73f0
movl $0x3e8, %ecx            # imm = 0x3E8
xorl %edx, %edx
divl %ecx
movl %edx, %ecx
movzbl 0x495f(%rip), %r8d      # 0x70e0
orl $0x20, %r8d
leaq 0x1e9f(%rip), %rsi      # 0x462b
movl %eax, %edx
xorl %eax, %eax
callq 0x20b0
cmpb $0x1, 0x4918(%rip)      # 0x70b4
jne 0x27bf
movq 0x4b5b(%rip), %rdi      # 0x7300
movl 0x4c4d(%rip), %edx      # 0x73f8
subl 0x4b57(%rip), %edx      # 0x7308
leaq 0x1e7f(%rip), %rsi      # 0x4637
xorl %eax, %eax
callq 0x20b0
movb $0x0, 0x491a(%rip)      # 0x70e0
cmpb $0x1, 0x4923(%rip)      # 0x70f0
jne 0x27e8
movq 0x4b2a(%rip), %rcx      # 0x7300
leaq 0x1e61(%rip), %rdi      # 0x463e
pushq $0x3
popq %rsi
pushq $0x1
popq %rdx
callq 0x2130
cmpb $0x1, 0x48c5(%rip)      # 0x70b4
jne 0x2841
movq 0x4c00(%rip), %rax      # 0x73f8
leaq 0x1e43(%rip), %rbx      # 0x4642
leaq 0x1e12(%rip), %r14      # 0x4618
cmpq 0x4bf3(%rip), %rax      # 0x7400
ja 0x2841
movq 0x4aea(%rip), %rdi      # 0x7300
cmpb $0x0, 0x48d3(%rip)      # 0x70f0
movq %r14, %rsi
cmovneq %rbx, %rsi
movzbl (%rax), %edx
xorl %eax, %eax
callq 0x20b0
movq 0x4bc3(%rip), %rax      # 0x73f8
incq %rax
movq %rax, 0x4bb9(%rip)      # 0x73f8
jmp 0x2806
movq 0x4ab8(%rip), %rsi      # 0x7300
pushq $0xa
popq %rdi
callq 0x20a0
movq 0x4ba9(%rip), %rax      # 0x7400
incq %rax
movq %rax, 0x4b97(%rip)      # 0x73f8
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq