LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_cpp_makefile_star2_O3/Ahhgust[P]STRaitRazor/str8.cpp
// Function: printReportsMT(_IO_FILE*)
void
printReportsMT(FILE *stream) {
  int i;
  // merge the maps
  for (i=1 ; i < opt.numThreads; ++i) {
    Matches::iterator itr = matches[i].begin();
    // sum up all of the unique haplotypes itr->first
    // with their associated frequency counts
    for( ; itr != matches[i].end(); ++itr) {
      matches[0][ itr->first ].first += itr->second.first;
      matches[0][ itr->first ].second += itr->second.second;
    }
  }
  printReports(stream, matches[0], opt.minPrint,opt.noReverseComplement);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
movl 0xb117(%rip), %eax      # 0xf2e8
movq 0x6261e8(%rip), %rsi    # 0x62a3c0
cmpl $0x2, %eax
jl 0x4257
movl $0x1, %r12d
leaq (%r12,%r12,2), %r13
shlq $0x4, %r13
leaq (%rsi,%r13), %rcx
addq $0x8, %rcx
movq 0x10(%rcx), %r14
cmpq %rcx, %r14
je 0x424c
leaq 0x20(%r14), %r15
movl 0x38(%r14), %ebp
movq %rsi, %rdi
movq %r15, %rsi
callq 0x6d24
addl %ebp, (%rax)
movl 0x3c(%r14), %ebp
movq 0x6261a4(%rip), %rdi    # 0x62a3c0
movq %r15, %rsi
callq 0x6d24
addl %ebp, 0x4(%rax)
movq %r14, %rdi
callq 0x31d0
movq %rax, %r14
movq 0x626187(%rip), %rsi    # 0x62a3c0
leaq (%rsi,%r13), %rax
addq $0x8, %rax
cmpq %rax, %r14
jne 0x41fc
movl 0xb09c(%rip), %eax      # 0xf2e8
incq %r12
movslq %eax, %rcx
cmpq %rcx, %r12
jl 0x41e3
movl 0xb06b(%rip), %edx      # 0xf2c8
movzbl 0xb06b(%rip), %ecx      # 0xf2cf
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x3b20
// File: /workspace/github_cpp_makefile_star2_O3/Ahhgust[P]STRaitRazor/str8.cpp
// Function: revcompCstring(char const*, int)
char *
revcompCstring(const char *dna, int len) {
  char *revcompd = new char[ len + 1 ];
  revcompd[len]=0;
  int j=len-1;
  int i=0;
  char c;
  for ( ; i < len; ++i, --j) {
    c = dna[j];
    if (c=='A')
      revcompd[i] = 'T';
    else if (c=='T')
      revcompd[i] = 'A';
    else if (c=='G')
      revcompd[i] = 'C';
    else if (c=='C')
      revcompd[i] = 'G';
    else
      revcompd[i] = c;

  }
  return revcompd;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movl %esi, %r14d
movq %rdi, %rbx
leal 0x1(%r14), %eax
movslq %eax, %rdi
callq 0x3030
movslq %r14d, %rdx
movb $0x0, (%rax,%rdx)
testl %edx, %edx
jle 0x44e8
movl %edx, %ecx
addq %rbx, %rdx
decq %rdx
xorl %esi, %esi
movb (%rdx), %dil
movzbl %dil, %r8d
cmpl $0x46, %r8d
jg 0x44c0
cmpl $0x41, %r8d
je 0x44d1
cmpl $0x43, %r8d
jne 0x44d9
movb $0x47, %dil
jmp 0x44d9
cmpl $0x47, %r8d
je 0x44d6
cmpl $0x54, %r8d
jne 0x44d9
movb $0x41, %dil
jmp 0x44d9
movb $0x54, %dil
jmp 0x44d9
movb $0x43, %dil
movb %dil, (%rax,%rsi)
incq %rsi
decq %rdx
cmpq %rsi, %rcx
jne 0x44a2
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_cpp_makefile_star2_O3/Ahhgust[P]STRaitRazor/str8.cpp
// Function: findMatchesOneThread()
void
findMatchesOneThread() {

  bool done=false;

    // a ceiling on the number of matches you can find on a single pass through the trie
  unsigned *matchIds = new unsigned[ numStrs * 4];
  unsigned char *matchTypes = new unsigned char[ numStrs * 4];
  
  records = MEM; // we're only using one of the buffers...
  qrecords=QMEM;
  while (!done) {
    done = buffer(MEM, QMEM);
    processDNA_Trie(0, matchIds, matchTypes);
  }
    
  delete [] matchIds;
  delete [] matchTypes;

  printReports(opt.out, matches[0], opt.minPrint,opt.noReverseComplement);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movl 0x624e88(%rip), %r14d   # 0x62a380
shll $0x2, %r14d
leaq (,%r14,4), %rdi
callq 0x3030
movq %rax, %rbx
movq %r14, %rdi
callq 0x3030
movq %rax, %r14
leaq 0x9de2(%rip), %r15      # 0xf300
movq %r15, 0x6245db(%rip)    # 0x629b00
leaq 0x3171d4(%rip), %r12    # 0x31c700
movq %r12, 0x6245d5(%rip)    # 0x629b08
movq %r15, %rdi
movq %r12, %rsi
callq 0x427a
movl %eax, %ebp
xorl %edi, %edi
movq %rbx, %rsi
movq %r14, %rdx
callq 0x490d
testb %bpl, %bpl
je 0x5533
movq %rbx, %rdi
callq 0x3360
movq %r14, %rdi
callq 0x3360
movq 0x9d6f(%rip), %rdi      # 0xf2d8
movq 0x624e50(%rip), %rsi    # 0x62a3c0
movl 0x9d52(%rip), %edx      # 0xf2c8
movzbl 0x9d52(%rip), %ecx      # 0xf2cf
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0x3b20
// File: /workspace/github_cpp_makefile_star2_O3/Ahhgust[P]STRaitRazor/str8.cpp
// Function: writerThread(void*)
void *
writerThread(void *arg) {
  
  done=buffer(MEM, QMEM); // read in a bunch of data
  if (done)
    nextdone = true;

  records = MEM; // set up the pointer
  qrecords=QMEM;
  
  workersWorking= opt.numThreads; // let the workers start processing the data

  unsigned i=0;
  while (! nextdone) {
    ++i;

    if (records == MEM) 
      nextdone=buffer(OTHERMEM, OTHERQMEM);
    else 
      nextdone=buffer(MEM, QMEM);

    buffered=1; // the double buffer is set up

    if (nextdone) {
      break; // no sense waiting...
    }

#ifdef OSX
    sem_wait(writersLock); // wait for the readers to finish reading *records
#else
    sem_wait(&writersLock); // wait for the readers to finish reading *records
#endif
  }

  return NULL;

}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
leaq 0x90fa(%rip), %rbx      # 0xf300
leaq 0x3164f3(%rip), %r14    # 0x31c700
movq %rbx, %rdi
movq %r14, %rsi
callq 0x427a
xchgb %al, 0x90da(%rip)       # 0xf2f8
movb 0x90d4(%rip), %al       # 0xf2f8
testb $0x1, %al
je 0x6230
movb $0x1, %al
xchgb %al, 0x90c9(%rip)       # 0xf2f9
movq %rbx, 0x6238c9(%rip)    # 0x629b00
movq %r14, 0x6238ca(%rip)    # 0x629b08
movl 0x90a4(%rip), %eax      # 0xf2e8
xchgl %eax, 0x623916(%rip)    # 0x629b60
movb 0x90a9(%rip), %al       # 0xf2f9
testb $0x1, %al
jne 0x62b6
leaq 0x18faa5(%rip), %r14    # 0x195d00
leaq 0x49ce9e(%rip), %r15    # 0x4a3100
leaq 0x6238d7(%rip), %r12    # 0x629b40
leaq 0x316490(%rip), %r13    # 0x31c700
cmpq %rbx, 0x623889(%rip)    # 0x629b00
je 0x6281
movq %rbx, %rdi
movq %r13, %rsi
jmp 0x6287
movq %r14, %rdi
movq %r15, %rsi
callq 0x427a
xchgb %al, 0x9067(%rip)       # 0xf2f9
movb $0x1, %al
xchgb %al, 0x6238ca(%rip)     # 0x629b64
movb 0x9059(%rip), %al       # 0xf2f9
testb $0x1, %al
jne 0x62b6
movq %r12, %rdi
callq 0x3190
movb 0x9047(%rip), %al       # 0xf2f9
testb $0x1, %al
je 0x6270
xorl %eax, %eax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O3/Ahhgust[P]STRaitRazor/str8.cpp
// Function: CompareReport::operator()(Report const&, Report const&) const
bool operator() (const Report &a, const Report &b) const {
    //TODO: Handle string/float pair instead of lexicographic ordering

    unsigned i1 = a.strIndex;
    unsigned i2 = b.strIndex;

    // different loci
    if (i2 < i1) 
      return false;
    else if (i1 < i2) 
      return true;


    // different haplotype lengths; ergo different haplotypes
    if (a.hapLength < b.hapLength)
      return true;
    else if (a.hapLength > b.hapLength)
      return false;

    // one haplotype has nonstandard letters and the other does not.    
    if (a.nonstandardLetters == false && b.nonstandardLetters==true)
      return false;
    else if (a.nonstandardLetters == true && b.nonstandardLetters==false)
      return true;

    if (a.nonstandardLetters==false) { // compare binary words

    // compute the (min) length in binarywords of the two haplotypes
      unsigned i, lengthInWords = ceil( min(a.hapLength, b.hapLength)/ (MAXWORD/2.0));
      binaryword *b1 = a.haplotype;
      binaryword *b2 = b.haplotype;
      
      for (i=0; i < lengthInWords; ++i, ++b1, ++b2) {
        if (*b1 < *b2)
          return true;
        else if (*b1 > *b2)
          return false;
      }

    } else { // compare char*s
      char *b1 = (char*) a.haplotype;
      char *b2 = (char*) b.haplotype;

      for (int i=0; i < a.hapLength; ++i, ++b1, ++b2) {
        if (*b1 < *b2)
          return true;
        else if (*b1 > *b2)
          return false;
      }
    }

    return false;
    
  }

// Assembly:
movl (%rsi), %eax
movl (%rdx), %ecx
cmpl %eax, %ecx
jae 0x7f0d
xorl %eax, %eax
retq
movb $0x1, %al
ja 0x7f0c
pushq %r14
pushq %rbx
pushq %rax
movq %rdx, %r14
movq %rsi, %rbx
movl 0x14(%rsi), %ecx
movl 0x14(%rdx), %edx
cmpl %edx, %ecx
jl 0x7f29
jle 0x7f31
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
movb 0x10(%r14), %dl
cmpb $0x0, 0x10(%rbx)
je 0x7f67
testb %dl, %dl
je 0x7f29
testl %ecx, %ecx
jle 0x7f27
movq 0x8(%r14), %rdx
movq 0x8(%rbx), %rsi
xorl %edi, %edi
movb (%rsi,%rdi), %al
movb (%rdx,%rdi), %r8b
cmpb %r8b, %al
setl %al
jl 0x7f29
jg 0x7f29
incq %rdi
cmpl %ecx, %edi
jl 0x7f4d
jmp 0x7f29
testb $0x1, %dl
jne 0x7f27
cvtsi2sd %ecx, %xmm0
mulsd 0x30a8(%rip), %xmm0     # 0xb020
callq 0x3080
cvttsd2si %xmm0, %rcx
testl %ecx, %ecx
je 0x7f27
movq 0x8(%r14), %rdx
movq 0x8(%rbx), %rsi
xorl %edi, %edi
movq (%rsi,%rdi,8), %rax
movq (%rdx,%rdi,8), %r8
cmpq %r8, %rax
setb %al
jb 0x7f29
ja 0x7f29
incq %rdi
cmpl %ecx, %edi
jb 0x7f90
jmp 0x7f29
// File: /workspace/github_cpp_makefile_star2_O3/Ahhgust[P]STRaitRazor/lookup.cpp
// Function: setLetter(unsigned long, char, unsigned int)
binaryword
setLetter(binaryword w, char letter, unsigned pos) {


  pos = MAXWORD - 2 - (pos + pos);
  

  if (letter == 'A') { // clear two bits
    w &= ~( ((binaryword)3) << pos);
  } else if (letter == 'C') { // C is 01 in this schema
    w |= ((binaryword)1) << (pos); // set 1 bit to 1
    w &= ~( ((binaryword)1) << (pos+1)); // set the next bit to 0
  } else if (letter == 'G') {
    w |= ((binaryword)1) << (pos+1); //  and vice versa
    w &= ~( ((binaryword)1) << (pos)); //
  } else { // setting two bits
    w |= ((binaryword)3) << (pos);
  }

  return w;
}

// Assembly:
addl %edx, %edx
movl $0x3e, %ecx
subl %edx, %ecx
cmpl $0x47, %esi
je 0x966d
cmpl $0x43, %esi
je 0x965f
movl $0x3, %eax
shlq %cl, %rax
cmpl $0x41, %esi
jne 0x967d
notq %rax
andq %rdi, %rax
retq
btsq %rcx, %rdi
movb $0x3f, %al
subb %dl, %al
btrq %rax, %rdi
jmp 0x9679
movb $0x3f, %al
subb %dl, %al
btsq %rax, %rdi
btrq %rcx, %rdi
movq %rdi, %rax
retq
orq %rdi, %rax
retq
// File: /workspace/github_cpp_makefile_star2_O3/Ahhgust[P]STRaitRazor/lookup.cpp
// Function: gatcToLong(char*, unsigned int)
binaryword
gatcToLong(char *s, unsigned numChars) {

  unsigned i;
  binaryword num=0;


  for (i=0; i < numChars; ++i, ++s) {
    num = setLetter(num, *s, i);
  }

  return num;
}

// Assembly:
testl %esi, %esi
je 0x96cc
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %rbx
movl %esi, %r15d
xorl %r14d, %r14d
xorl %eax, %eax
movsbl (%rbx,%r14), %esi
movq %rax, %rdi
movl %r14d, %edx
callq 0x9638
incq %r14
cmpl %r14d, %r15d
jne 0x96ae
popq %rbx
popq %r14
popq %r15
retq
xorl %eax, %eax
retq
// File: /workspace/github_cpp_makefile_star2_O3/Ahhgust[P]STRaitRazor/lookup.cpp
// Function: reverseComplement(unsigned long*, unsigned long*, unsigned int)
void
reverseComplement(binaryword *in, binaryword *out, unsigned numBases) {

  unsigned j, i = numBases-1;
  unsigned inIndex, inBase, outIndex, outBase, prevOutIndex=UINT_MAX;

  char c;
  for (j=0 ; j < numBases; --i, ++j) {
    inIndex = i/(MAXWORD/2);
    inBase = i % (MAXWORD/2);
    c = getLetter(in[inIndex], inBase);
    if (c == 'A') {
      c = 'T';
    } else if (c == 'T') {
      c = 'A';
    } else if (c == 'G') {
      c = 'C';
    } else if (c == 'C') {
      c = 'G';
    } else {
      fprintf(stderr, "Cannot happen! Got letter: %c\n", c);
      exit(EXIT_FAILURE);
    }


    outIndex = j / (MAXWORD/2);
    outBase = j %  (MAXWORD/2);

    if (outIndex != prevOutIndex)
      out[outIndex] = 0;

    out[outIndex] = setLetter(out[outIndex], c, outBase);
    prevOutIndex = outIndex;
  }


}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, (%rsp)
testl %edx, %edx
je 0x9823
movl %edx, %ebx
movq %rsi, %r14
leal -0x2(,%rbx,2), %ebp
decl %ebx
xorl %r12d, %r12d
movl $0xffffffff, %edx       # imm = 0xFFFFFFFF
movl %ebx, %eax
shrl $0x5, %eax
movq (%rsp), %rcx
movq (%rcx,%rax,8), %rax
movl %ebp, %ecx
notb %cl
andb $0x3e, %cl
shrq %cl, %rax
shll $0x3, %eax
movl $0x41434754, %esi       # imm = 0x41434754
movl %eax, %ecx
shrl %cl, %esi
movl %r12d, %r13d
shrl $0x5, %r13d
movl %r13d, %r15d
cmpl %edx, %r13d
jne 0x97f8
movl %edx, %eax
movq (%r14,%rax,8), %rdi
jmp 0x9802
movq $0x0, (%r14,%r15,8)
xorl %edi, %edi
movl %r12d, %edx
andl $0x1f, %edx
movzbl %sil, %esi
callq 0x9638
movq %rax, (%r14,%r15,8)
incl %r12d
addl $-0x2, %ebp
movl %r13d, %edx
addl $-0x1, %ebx
jb 0x97be
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O3/Ahhgust[P]STRaitRazor/trie.cpp
// Function: Trie::existsPrefixMatch(char const*, unsigned int, unsigned int, unsigned char)
bool
Trie::existsPrefixMatch(const char *w, unsigned wordLen, unsigned outId, unsigned char outType) {

  unsigned i;
  char c;
  TrieNode *parent, *child;
  parent = root;
  
  // traverse the tree, 
  for (i=0; i < wordLen && *w; ++i, ++w) {

    if (parent->id != NULL) {
      int size = parent->id->size();
      for ( int i = 0; i < size; ++i) {
	if ( parent->type->at(i) == outType &&
	     parent->id->at(i) == outId)
	  return true;
      }
    }


    c = *w;
    if (c == 'A') {
      if (parent->a == NULL) {
	return false;
      }
      child = parent->a;
    } else if (c == 'C') {
      if (parent->c == NULL) {
	return false;
      }
      child = parent->c;
    } else if (c == 'G') {
      if (parent->g == NULL) {
	return false;
      }
      child = parent->g;
    } else {
      if (parent->t == NULL) {
	return false;
      }
      child = parent->t;
    }
    
    parent = child;
  }

  // this is a corner case....
  // the entire binaryword matches the entire anchor sequence

  if (parent->id != NULL) {
    int size = parent->id->size();
    for ( int i = 0; i < size; ++i) {
	if ( parent->type->at(i) == outType &&
	     parent->id->at(i) == outId)
	  return true;
    }
  }

  return false;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq (%rdi), %rdi
testl %edx, %edx
je 0x9a63
xorl %r11d, %r11d
movzbl (%rsi), %ebx
testl %ebx, %ebx
je 0x9a63
movq 0x20(%rdi), %rax
testq %rax, %rax
je 0x9a2b
movq (%rax), %r14
movq 0x8(%rax), %rax
subq %r14, %rax
sarq $0x2, %rax
testl %eax, %eax
jle 0x9a2b
movq 0x28(%rdi), %r9
movq (%r9), %r15
movq 0x8(%r9), %r9
subq %r15, %r9
movl %eax, %r12d
andl $0x7fffffff, %r12d      # imm = 0x7FFFFFFF
xorl %r10d, %r10d
cmpq %r10, %r9
je 0x9ac8
cmpb %r8b, (%r15,%r10)
jne 0x9a23
cmpq %r10, %rax
jbe 0x9ad7
cmpl %ecx, (%r14,%r10,4)
je 0x9aba
incq %r10
cmpq %r10, %r12
jne 0x9a01
cmpl $0x47, %ebx
je 0x9a45
cmpl $0x43, %ebx
je 0x9a3f
cmpl $0x41, %ebx
jne 0x9a4b
movq (%rdi), %rdi
jmp 0x9a4f
movq 0x8(%rdi), %rdi
jmp 0x9a4f
movq 0x10(%rdi), %rdi
jmp 0x9a4f
movq 0x18(%rdi), %rdi
testq %rdi, %rdi
je 0x9ab6
incl %r11d
incq %rsi
cmpl %edx, %r11d
jne 0x99c0
movq 0x20(%rdi), %rax
testq %rax, %rax
je 0x9ab6
movq (%rax), %r9
movq 0x8(%rax), %rdx
subq %r9, %rdx
sarq $0x2, %rdx
testl %edx, %edx
jle 0x9ab6
movq 0x28(%rdi), %rax
movq (%rax), %rdi
movq 0x8(%rax), %rax
subq %rdi, %rax
movl %edx, %r10d
andl $0x7fffffff, %r10d      # imm = 0x7FFFFFFF
xorl %esi, %esi
cmpq %rsi, %rax
je 0x9ae3
cmpb %r8b, (%rdi,%rsi)
jne 0x9aae
cmpq %rsi, %rdx
jbe 0x9af7
cmpl %ecx, (%r9,%rsi,4)
je 0x9aba
incq %rsi
cmpq %rsi, %r10
jne 0x9a98
xorl %eax, %eax
jmp 0x9abc
movb $0x1, %al
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
leaq 0x2540(%rip), %rdi      # 0xc00f
movq %r9, %rsi
movq %r9, %rdx
jmp 0x9af0
leaq 0x2531(%rip), %rdi      # 0xc00f
movq %r10, %rsi
jmp 0x9aed
leaq 0x2525(%rip), %rdi      # 0xc00f
movq %rax, %rsi
movq %rax, %rdx
xorl %eax, %eax
callq 0x33d0
leaq 0x2511(%rip), %rdi      # 0xc00f
jmp 0x9af0
// File: /workspace/github_cpp_makefile_star2_O3/Ahhgust[P]STRaitRazor/trie.cpp
// Function: Trie::initMem(unsigned int)
void
Trie::initMem(unsigned num_nodes) {
  
  unsigned i;
  mem = new TrieNode[num_nodes];
  TrieNode *head = mem;
  for (i=0; i < num_nodes; ++i, ++head) {
    (*head).a =     (*head).c =    (*head).g =     (*head).t = NULL;
    (*head).id = NULL;
    (*head).type = NULL;
  }

  numNodes = num_nodes;
  root = mem;
  
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %esi, %ebp
movq %rdi, %rbx
movl %esi, %eax
shlq $0x4, %rax
leaq (%rax,%rax,2), %r14
movq %r14, %rdi
callq 0x3030
movq %rax, %r15
movq %rax, 0x8(%rbx)
testl %ebp, %ebp
je 0x9b36
movq %r15, %rdi
xorl %esi, %esi
movq %r14, %rdx
callq 0x3180
movl %ebp, 0x10(%rbx)
movq %r15, (%rbx)
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O3/Ahhgust[P]STRaitRazor/trie.cpp
// Function: Trie::~Trie()
Trie::~Trie() {
  unsigned i;
  TrieNode *n = root;
  for (i=0; i < numNodes; ++i, ++n) {
    if ((*n).id != NULL) {
      delete((*n).id);
      delete((*n).type);
    }
  }

  delete [] root;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq (%rdi), %rbx
movl 0x10(%rdi), %eax
testl %eax, %eax
je 0x9f38
movq %rdi, %r14
addq $0x28, %rbx
xorl %ebp, %ebp
movq -0x8(%rbx), %r15
testq %r15, %r15
je 0x9f2b
movq (%r15), %rdi
testq %rdi, %rdi
je 0x9ef1
movq 0x10(%r15), %rsi
subq %rdi, %rsi
callq 0x32d0
movl $0x18, %esi
movq %r15, %rdi
callq 0x32d0
movq (%rbx), %r15
testq %r15, %r15
je 0x9f1a
movq (%r15), %rdi
testq %rdi, %rdi
je 0x9f1a
movq 0x10(%r15), %rsi
subq %rdi, %rsi
callq 0x32d0
movl $0x18, %esi
movq %r15, %rdi
callq 0x32d0
movl 0x10(%r14), %eax
incl %ebp
addq $0x30, %rbx
cmpl %eax, %ebp
jb 0x9ed4
movq (%r14), %rbx
testq %rbx, %rbx
je 0x9f4f
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x3360
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/tomsmeding[P]MarioLANG/mariolang.cpp
// Function: getch()
char getch(){char b=0;struct termios o={};fflush(stdout);if(tcgetattr(0,&o)<0)
perror("tcsetattr()");o.c_lflag&=~ICANON;o.c_lflag&=~ECHO;o.c_cc[VMIN]=1;o.c_cc[
VTIME]=0;if(tcsetattr(0,TCSANOW,&o)<0)perror("tcsetattr ICANON");if(read(0,&b,1)
<0)perror("read()");o.c_lflag|=ICANON;o.c_lflag|=ECHO;if(tcsetattr(0,TCSADRAIN,&
o)<0)perror("tcsetattr ~ICANON");return b;}

// Assembly:
pushq %rbx
subq $0x50, %rsp
movb $0x0, 0xf(%rsp)
xorps %xmm0, %xmm0
leaq 0x10(%rsp), %rbx
movups %xmm0, 0x2c(%rbx)
movaps %xmm0, 0x20(%rbx)
movaps %xmm0, 0x10(%rbx)
movaps %xmm0, (%rbx)
movq 0x5434(%rip), %rax      # 0x7fb8
movq (%rax), %rdi
callq 0x2160
xorl %edi, %edi
movq %rbx, %rsi
callq 0x2130
testl %eax, %eax
js 0x2bef
leaq 0x10(%rsp), %rdx
andb $-0xb, 0xc(%rdx)
movw $0x100, 0x16(%rdx)      # imm = 0x100
xorl %edi, %edi
xorl %esi, %esi
callq 0x2190
testl %eax, %eax
js 0x2bfd
leaq 0xf(%rsp), %rsi
movl $0x1, %edx
xorl %edi, %edi
callq 0x21f0
testq %rax, %rax
js 0x2c0b
leaq 0x10(%rsp), %rdx
orb $0xa, 0xc(%rdx)
xorl %edi, %edi
movl $0x1, %esi
callq 0x2190
testl %eax, %eax
js 0x2c19
movb 0xf(%rsp), %al
addq $0x50, %rsp
popq %rbx
retq
leaq 0x24da(%rip), %rdi      # 0x50d0
callq 0x20d0
jmp 0x2b9a
leaq 0x24d8(%rip), %rdi      # 0x50dc
callq 0x20d0
jmp 0x2bb6
leaq 0x24db(%rip), %rdi      # 0x50ed
callq 0x20d0
jmp 0x2bcc
leaq 0x24d4(%rip), %rdi      # 0x50f4
callq 0x20d0
jmp 0x2be5
// File: /workspace/github_cpp_makefile_star2_O3/tomsmeding[P]MarioLANG/mariolang.cpp
// Function: signalhandler(int)
void signalhandler(int sig){
	switch(sig){
	case SIGINT:
		if(animate)moveto(L->getoutputx(),L->getoutputy());
		exit(2);
	case SIGUSR1:
		animatedelay+=100000; //100ms extra
		break;
	}
}

// Assembly:
cmpl $0xa, %edi
je 0x2c5e
cmpl $0x2, %edi
je 0x2c69
retq
addl $0x186a0, 0x5500(%rip)  # imm = 0x186A0
retq
pushq %rax
cmpb $0x1, 0x54fb(%rip)      # 0x816c
jne 0x2c85
movq 0x54f6(%rip), %rax      # 0x8170
movl 0x48(%rax), %edi
movl 0x4c(%rax), %esi
callq 0x2c27
movl $0x2, %edi
callq 0x2180
// File: /workspace/github_cpp_makefile_star2_O3/tomsmeding[P]MarioLANG/mariolang.cpp
// Function: Level::Level(std::basic_ifstream<char, std::char_traits<char>>&)
Level(ifstream &cf){
		code.resize(10); //some nice starting amount
		int i,maxlen=0;
		for(i=0;cf.good();i++){
			if(i+1>(int)code.size())code.resize(code.size()*2);
			getline(cf,code[i]);
			if((int)code[i].size()>maxlen)maxlen=code[i].size();
		}
		if(&cf!=&cin)cf.close();
		code.resize(i);
		for(i=0;i<(int)code.size();i++)code[i].resize(maxlen,' ');
	}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %r15
movq %rdi, %rbx
leaq 0x30(%rdi), %rdi
xorps %xmm0, %xmm0
movups %xmm0, 0x30(%rbx)
movups %xmm0, 0x20(%rbx)
movups %xmm0, 0x10(%rbx)
movups %xmm0, (%rbx)
movq $0x0, 0x40(%rbx)
movl $0xa, %esi
movq %rdi, (%rsp)
callq 0x3324
movq (%r15), %rax
movq -0x18(%rax), %rcx
xorl %r12d, %r12d
cmpl $0x0, 0x20(%r15,%rcx)
je 0x302b
xorl %r13d, %r13d
jmp 0x30b2
movq 0x30(%rbx), %r13
xorl %r14d, %r14d
xorl %ebp, %ebp
movq 0x38(%rbx), %rsi
subq %r13, %rsi
movq %rsi, %rcx
shrq $0x5, %rcx
movslq %ecx, %rcx
cmpq %rcx, %rbp
jl 0x3061
sarq $0x4, %rsi
movq (%rsp), %rdi
callq 0x3324
movq (%rsp), %rax
movq (%rax), %r13
movq (%r15), %rax
movq -0x18(%rax), %rdi
addq %r15, %rdi
movl $0xa, %esi
callq 0x20f0
addq %r14, %r13
movsbl %al, %edx
movq %r15, %rdi
movq %r13, %rsi
callq 0x2250
movq (%rsp), %rax
movq (%rax), %r13
movl 0x8(%r13,%r14), %eax
cmpl %eax, %r12d
cmovlel %eax, %r12d
movq (%r15), %rax
movq -0x18(%rax), %rcx
addq $0x20, %r14
incq %rbp
cmpl $0x0, 0x20(%r15,%rcx)
je 0x3034
movl %r12d, %r13d
movl %ebp, %r12d
cmpq 0x4f27(%rip), %r15      # 0x7fe0
je 0x30c3
movq %r15, %rdi
callq 0x2040
movq (%rsp), %rdi
movq %r12, %rsi
callq 0x3324
movq 0x30(%rbx), %rdi
movq 0x38(%rbx), %rax
subq %rdi, %rax
shrq $0x5, %rax
testl %eax, %eax
jle 0x3115
xorl %r14d, %r14d
xorl %r15d, %r15d
addq %r14, %rdi
movq %r13, %rsi
movl $0x20, %edx
callq 0x2070
incq %r15
movq 0x30(%rbx), %rdi
movq 0x38(%rbx), %rax
subq %rdi, %rax
shrq $0x5, %rax
cltq
addq $0x20, %r14
cmpq %rax, %r15
jl 0x30e8
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x312a
jmp 0x312a
jmp 0x312a
movq %rax, %r15
movq (%rsp), %rdi
callq 0x3296
movq %rbx, %rdi
callq 0x32f4
movq %r15, %rdi
callq 0x2240
// File: /workspace/github_cpp_makefile_star2_O3/tomsmeding[P]MarioLANG/mariolang.cpp
// Function: Level::play()
void play(void){
		mario *m=new mario;
		memory.resizepos(300);
		memory.resizeneg(300);
		m->ipx=0; m->ipy=0;
		m->dir=DIRRIGHT;
		m->walking=true;
		m->skip=false;
		m->memp=0;
		if(animate){
			printf("\x1B[1J");
			moveto(0,0);
			print();
			inputy=code.size(); //input comes first line under the code in animation mode
			outputx=0;
			outputy=inputy+2; //output comes under the input line, under "Output:"
			tapex=code[0].size()+1; //tape comes to the right of the code
			moveto(0,outputy-1);
			printf("\x1B[34;1mOutput:\x1B[0m"); fflush(stdout);
			moveto(outputx,outputy);
		}
		while(execcommandStep(m));
	}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
movl $0x14, %edi
callq 0x2100
movq %rax, %r14
xorl %ebp, %ebp
movq %rsp, %rdx
movl %ebp, (%rdx)
movl $0x12c, %esi            # imm = 0x12C
movq %rbx, %rdi
callq 0x379a
leaq 0x4(%rsp), %rdx
movl %ebp, (%rdx)
leaq 0x18(%rbx), %rdi
movl $0x12c, %esi            # imm = 0x12C
callq 0x379a
xorps %xmm0, %xmm0
movups %xmm0, (%r14)
movw $0x1, 0x10(%r14)
cmpb $0x1, 0x4fcd(%rip)      # 0x816c
jne 0x3278
leaq 0x2219(%rip), %rdi      # 0x53c5
xorl %eax, %eax
callq 0x2030
leaq 0x1f4c(%rip), %rdi      # 0x5106
movl $0x1, %esi
movl $0x1, %edx
xorl %eax, %eax
callq 0x2030
movq 0x4de6(%rip), %r13      # 0x7fb8
movq (%r13), %rdi
callq 0x2160
movq 0x30(%rbx), %r15
cmpq 0x38(%rbx), %r15
je 0x31fd
movq (%r15), %rdi
callq 0x2210
addq $0x20, %r15
cmpq 0x38(%rbx), %r15
jne 0x31e5
movq 0x30(%rbx), %rax
jmp 0x3200
movq %r15, %rax
subq %rax, %r15
shrq $0x5, %r15
movl %r15d, 0x50(%rbx)
movl $0x0, 0x48(%rbx)
addl $0x2, %r15d
movl %r15d, 0x4c(%rbx)
movl 0x8(%rax), %eax
incl %eax
movl %eax, 0x54(%rbx)
leaq 0x1edd(%rip), %r12      # 0x5106
movq %r12, %rdi
movl %r15d, %esi
movl $0x1, %edx
xorl %eax, %eax
callq 0x2030
movq (%r13), %rdi
callq 0x2160
leaq 0x217f(%rip), %rdi      # 0x53ca
xorl %eax, %eax
callq 0x2030
movq (%r13), %rdi
callq 0x2160
movl 0x48(%rbx), %edx
movl 0x4c(%rbx), %esi
incl %esi
incl %edx
movq %r12, %rdi
xorl %eax, %eax
callq 0x2030
movq (%r13), %rdi
callq 0x2160
movq %rbx, %rdi
movq %r14, %rsi
callq 0x3554
testb %al, %al
jne 0x3278
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/tomsmeding[P]MarioLANG/mariolang.cpp
// Function: Level::animationFrameEnd(mario*, int, int, char)
void animationFrameEnd(mario *m,int x,int y,char c){
		usleep(animatedelay);
		moveto(x,y);
		printf("%c",c); fflush(stdout);
		moveto(outputx,outputy);
		if(animateShowTape)drawTape(m);
	}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %r8d, %ebp
movl %ecx, %r12d
movl %edx, %r13d
movq %rsi, %rbx
movq %rdi, %r14
movl 0x3bc4(%rip), %edi      # 0x8168
callq 0x21d0
incl %r12d
incl %r13d
leaq 0xb50(%rip), %r15       # 0x5106
movq %r15, %rdi
movl %r12d, %esi
movl %r13d, %edx
xorl %eax, %eax
callq 0x2030
movq 0x39eb(%rip), %r12      # 0x7fb8
movq (%r12), %rdi
callq 0x2160
movl %ebp, %edi
callq 0x21b0
movq (%r12), %rdi
callq 0x2160
movl 0x48(%r14), %edx
movl 0x4c(%r14), %esi
incl %esi
incl %edx
movq %r15, %rdi
xorl %eax, %eax
callq 0x2030
movq (%r12), %rdi
callq 0x2160
cmpb $0x1, 0x3b61(%rip)      # 0x816d
jne 0x4627
movq %r14, %rdi
movq %rbx, %rsi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x4636
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/narula[P]skiplists/skiplist-fanout.cc
// Function: SkipList::fastFindNode(int)
int SkipList::fastFindNode(int key) {
  node* pred = head;
  int lFound = -1;
  for (int level = pred->topLevel-1; level >= 0; level--) {
	node* curr;
	curr = pred->nexts[level][FANOUT-1].nxt;
	inc();
	while (key > pred->nexts[level][FANOUT-1].prefix) {
	  pred = curr;
	  curr = pred->nexts[level][FANOUT-1].nxt;
	  inc();
	}
	if (lFound == -1 && key == pred->nexts[level][FANOUT-1].prefix) {
	  return level;
	}

	// pred.key is less than key, curr.key is greater than key.
	int k = 0;
	while (key > pred->nexts[level][k].prefix) {
	  k++;
	}
	//assert(k < FANOUT);
	if (k != 0) {
	  if (lFound == -1 && key == pred->nexts[level][k-1].prefix) {
		return level;
	  }
	  pred = pred->nexts[level][k-1].nxt;
	  inc();
	}
  }
  return lFound;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq (%rdi), %rbx
movslq 0x4(%rbx), %rcx
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
testq %rcx, %rcx
jle 0x1361
movl 0x18(%rdi), %edx
movl 0x1c(%rdi), %r8d
movq %rcx, %r9
shlq $0x6, %r9
addq $-0x40, %r9
movabsq $0x100000000, %r11      # imm = 0x100000000
movq %rcx, %r14
decq %rcx
movq %rcx, %r15
shlq $0x6, %r15
movq 0x40(%rbx,%r15), %r13
cmpl $0x1, %r8d
jne 0x12e0
incl %edx
movl %edx, 0x18(%rdi)
leaq 0x8(%rbx), %r12
movl 0x30(%r12,%r15), %ebp
cmpl %esi, %ebp
jge 0x12f7
movq %r13, %rbx
movq 0x40(%r13,%r15), %r13
jmp 0x12d5
cmpl %esi, %ebp
je 0x135f
leaq (%r12,%r9), %rbp
xorl %r10d, %r10d
movabsq $-0x200000000, %r13     # imm = 0xFFFFFFFE00000000
movq %r10, %rax
addq %r11, %r13
addq $0x10, %r10
cmpl %esi, (%rbp,%rax)
jl 0x130c
cmpq $0x10, %r10
je 0x134a
addq %r15, %r12
movq %r13, %rax
sarq $0x1c, %rax
cmpl %esi, (%rax,%r12)
je 0x135f
sarq $0x20, %r13
shlq $0x4, %r13
movq 0x8(%r13,%r12), %rbx
cmpl $0x1, %r8d
jne 0x134a
incl %edx
movl %edx, 0x18(%rdi)
addq $-0x40, %r9
cmpq $0x2, %r14
jge 0x12c3
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
jmp 0x1361
movl %ecx, %eax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/narula[P]skiplists/skiplist-fanout.cc
// Function: SkipList::findNode(int, node* (*) [4], node* (*) [4])
int SkipList::findNode(int key, node* preds[][FANOUT], node* succs[][FANOUT]) {
  node* pred = head;
  int lFound = -1;
  for (int level = pred->topLevel-1; level >= 0; level--) {
	node* curr;
	curr = pred->nexts[level][FANOUT-1].nxt;
	inc();
	while (key > pred->nexts[level][FANOUT-1].prefix) {
	  pred = curr;
	  curr = pred->nexts[level][FANOUT-1].nxt;
	  inc();
	}
	preds[level][FANOUT-1] = pred;
	succs[level][FANOUT-1] = curr;
	if (lFound == -1 && key == pred->nexts[level][FANOUT-1].prefix) {
	  lFound = level;
	  continue;
	}

	// pred.key is less than key, curr.key is greater than key.
	int k = 0;
	while (key > pred->nexts[level][k].prefix) {
	  k++;
	}
	//assert(k < FANOUT);
	if (k != 0) {
	  if (lFound == -1 && key == pred->nexts[level][k-1].prefix) {
		lFound = level;
	  }
	  pred = pred->nexts[level][k-1].nxt;
	  inc();
	}
	// for (int k = 0; k < FANOUT; k++) {
	//   if (pred->nexts[level][k].nxt == NULL) {
	// 	continue;
	//   }
	//   if (key >= pred->nexts[level][k].prefix) {
	// 	//		preds[level][k] = pred->nexts[level][k].nxt;
	// 	continue;
	//   } else {
	// 	if (k != 0) {
	// 	  if (lFound == -1 && key == pred->nexts[level][k-1].prefix) {
	// 		lFound = level;
	// 	  }
	// 	  pred = pred->nexts[level][k-1].nxt;
	// 	  inc();
	// 	}
	//   }
	//   succs[level][k] = pred->nexts[level][k].nxt;
	// }
  }
  return lFound;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rcx, -0x8(%rsp)
movq %rdx, -0x10(%rsp)
movq (%rdi), %rbx
movslq 0x4(%rbx), %r8
testq %r8, %r8
jle 0x14c5
movl 0x18(%rdi), %r9d
movl 0x1c(%rdi), %r10d
movq %r8, %r11
shlq $0x6, %r11
addq $-0x40, %r11
movl $0xffffffff, -0x14(%rsp) # imm = 0xFFFFFFFF
movabsq $0x100000000, %r14      # imm = 0x100000000
movq %r8, %rax
decq %r8
movq %r8, %r13
shlq $0x6, %r13
movq 0x40(%rbx,%r13), %r15
cmpl $0x1, %r10d
jne 0x1408
incl %r9d
movl %r9d, 0x18(%rdi)
leaq 0x8(%rbx), %rbp
movl 0x30(%rbp,%r13), %r12d
cmpl %esi, %r12d
jge 0x1420
movq %r15, %rbx
movq 0x40(%r15,%r13), %r15
jmp 0x13fb
movq %r8, %rcx
shlq $0x5, %rcx
movq -0x10(%rsp), %rdx
movq %rbx, 0x18(%rdx,%rcx)
movq -0x8(%rsp), %rdx
movq %r15, 0x18(%rdx,%rcx)
cmpl $-0x1, -0x14(%rsp)
jne 0x144e
cmpl %esi, %r12d
jne 0x144e
movl %r8d, -0x14(%rsp)
jmp 0x14b5
leaq (%r11,%rbp), %r12
xorl %ecx, %ecx
movabsq $-0x200000000, %r15     # imm = 0xFFFFFFFE00000000
movq %rcx, %rdx
addq %r14, %r15
addq $0x10, %rcx
cmpl %esi, (%r12,%rdx)
jl 0x145e
cmpq $0x10, %rcx
je 0x14b5
sarq $0x20, %r15
cmpl $-0x1, -0x14(%rsp)
jne 0x149c
movq %rbp, %rcx
addq %r13, %rcx
movq %r15, %rdx
shlq $0x4, %rdx
cmpl %esi, (%rdx,%rcx)
movl $0xffffffff, %ecx       # imm = 0xFFFFFFFF
cmovel %r8d, %ecx
movl %ecx, -0x14(%rsp)
addq %r13, %rbp
shlq $0x4, %r15
movq 0x8(%r15,%rbp), %rbx
cmpl $0x1, %r10d
jne 0x14b5
incl %r9d
movl %r9d, 0x18(%rdi)
addq $-0x40, %r11
cmpq $0x1, %rax
jg 0x13e9
jmp 0x14cd
movl $0xffffffff, -0x14(%rsp) # imm = 0xFFFFFFFF
movl -0x14(%rsp), %eax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/narula[P]skiplists/skiplist-fanout.cc
// Function: SkipList::insert(int)
int SkipList::insert(int key) {
  node *preds[max_level][FANOUT], *succs[max_level][FANOUT];
  int found = findNode(key, preds, succs);
  if (found != -1) return 0;
  node* add = new node();
  add->key = key;
  int topLevel = randomLevel(max_level);
  for (int i = 0; i < topLevel; i++) {
	add->nexts[i][FANOUT-1].nxt = succs[i][FANOUT-1];
	add->nexts[i][FANOUT-1].prefix = succs[i][FANOUT-1]->key;
	preds[i][FANOUT-1]->nexts[i][FANOUT-1].nxt = add;
	preds[i][FANOUT-1]->nexts[i][FANOUT-1].prefix = key;
	for (int k = 0; k < FANOUT-1; k++) {
	  if (preds[i][FANOUT-1]->nexts[i][k].prefix > key) {
		add->nexts[i][k].nxt = preds[i][FANOUT-1]->nexts[i][k].nxt;
		add->nexts[i][k].prefix = preds[i][FANOUT-1]->nexts[i][k].prefix;
		preds[i][k]->nexts[i][k].nxt = NULL;
		preds[i][k]->nexts[i][k].prefix = 0;
	  }
	}
  }
  return 1;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %esi, %ebx
movq %rdi, %r13
movl 0x14(%rdi), %eax
movq %rsp, %r14
shlq $0x5, %rax
subq %rax, %r14
movq %r14, %rsp
movq %rsp, %r15
subq %rax, %r15
movq %r15, %rsp
movq %r14, %rdx
movq %r15, %rcx
callq 0x13a0
movl %eax, %ecx
xorl %eax, %eax
cmpl $-0x1, %ecx
jne 0x1633
movl $0x348, %edi            # imm = 0x348
callq 0x10d0
movq %rax, %r12
movl $0x348, %edx            # imm = 0x348
movq %rax, %rdi
xorl %esi, %esi
callq 0x1060
movl %ebx, (%r12)
movl 0x14(%r13), %r13d
callq 0x1050
movl %eax, %ecx
movl %eax, %esi
notl %esi
movl $0x1, %eax
movl $0x1, %edx
testb $0x3, %sil
jne 0x1575
movslq %ecx, %rcx
movq %rcx, %rsi
incl %edx
shrq $0x2, %rsi
notl %ecx
testb $0xc, %cl
movq %rsi, %rcx
je 0x1565
testl %r13d, %r13d
jle 0x1633
cmpl %r13d, %edx
cmovll %edx, %r13d
leaq 0x8(%r12), %rax
cmpl $0x2, %r13d
movl $0x1, %ecx
cmovgel %r13d, %ecx
movq %r12, %rdx
addq $0x10, %rdx
movl $0x10, %esi
xorl %edi, %edi
movq %r14, %r8
movq %rdi, %r9
shlq $0x5, %r9
movq 0x18(%r15,%r9), %r10
movq %rdi, %r11
shlq $0x6, %r11
movq %r10, 0x38(%rax,%r11)
movl (%r10), %r10d
movl %r10d, 0x30(%rax,%r11)
movq 0x18(%r14,%r9), %r9
movq %r12, 0x40(%r9,%r11)
movl %ebx, 0x38(%r9,%r11)
addq %rsi, %r9
xorl %r10d, %r10d
movl -0x8(%r9,%r10,2), %r11d
cmpl %ebx, %r11d
jle 0x160c
movq (%r9,%r10,2), %r13
movq %r13, (%rdx,%r10,2)
movl %r11d, -0x8(%rdx,%r10,2)
movq (%r8,%r10), %r11
addq %rsi, %r11
movq $0x0, (%r11,%r10,2)
movl $0x0, -0x8(%r11,%r10,2)
addq $0x8, %r10
cmpq $0x18, %r10
jne 0x15dd
incq %rdi
addq $0x20, %r8
addq $0x40, %rsi
addq $0x40, %rdx
cmpq %rcx, %rdi
jne 0x15a8
movl $0x1, %eax
leaq -0x28(%rbp), %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/narula[P]skiplists/skiplist-fanout.cc
// Function: insert_test(SkipList*)
int insert_test(SkipList* sk) {
  assert (sk->lookup(99) <= 0);
  assert (sk->insert(99) > 0);
  assert (sk->lookup(99) > 0);
  assert (sk->insert(99) <= 0);
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
movl $0x63, %esi
callq 0x1288
testl %eax, %eax
jns 0x1a48
movq %rbx, %rdi
movl $0x63, %esi
callq 0x14dc
testl %eax, %eax
jne 0x1a67
leaq 0x62b(%rip), %rdi       # 0x205b
leaq 0x5f5(%rip), %rsi       # 0x202c
leaq 0x601(%rip), %rcx       # 0x203f
movl $0x116, %edx            # imm = 0x116
callq 0x1070
leaq 0x5c9(%rip), %rdi       # 0x2018
leaq 0x5d6(%rip), %rsi       # 0x202c
leaq 0x5e2(%rip), %rcx       # 0x203f
movl $0x115, %edx            # imm = 0x115
callq 0x1070
movq %rbx, %rdi
movl $0x63, %esi
callq 0x1288
testl %eax, %eax
jns 0x1a97
leaq 0x5ef(%rip), %rdi       # 0x206e
leaq 0x5a6(%rip), %rsi       # 0x202c
leaq 0x5b2(%rip), %rcx       # 0x203f
movl $0x117, %edx            # imm = 0x117
callq 0x1070
movq %rbx, %rdi
movl $0x63, %esi
callq 0x14dc
leaq 0x5d6(%rip), %rdi       # 0x2081
leaq 0x57a(%rip), %rsi       # 0x202c
leaq 0x586(%rip), %rcx       # 0x203f
movl $0x118, %edx            # imm = 0x118
callq 0x1070
// File: /workspace/github_cpp_makefile_star2_O3/narula[P]skiplists/skiplist-fanout.cc
// Function: basic_test(SkipList*)
int basic_test(SkipList* sk) {
  for (int i = 0; i < 16; i++) {
	assert (sk->lookup(i) > 0);
  }
  assert (sk->lookup(99) <= 0);
  printf("PASSED\n");
}

// Assembly:
pushq %rbp
pushq %rbx
pushq %rax
movq %rdi, %rbx
xorl %ebp, %ebp
movq %rbx, %rdi
movl %ebp, %esi
callq 0x1288
testl %eax, %eax
js 0x1b10
incl %ebp
cmpl $0x10, %ebp
jne 0x1acb
movq %rbx, %rdi
movl $0x63, %esi
callq 0x1288
testl %eax, %eax
js 0x1b2f
leaq 0x520(%rip), %rdi       # 0x2018
leaq 0x52d(%rip), %rsi       # 0x202c
leaq 0x5a1(%rip), %rcx       # 0x20a7
movl $0x11f, %edx            # imm = 0x11F
callq 0x1070
leaq 0x57e(%rip), %rdi       # 0x2095
leaq 0x50e(%rip), %rsi       # 0x202c
leaq 0x582(%rip), %rcx       # 0x20a7
movl $0x11d, %edx            # imm = 0x11D
callq 0x1070
leaq 0x618(%rip), %rdi       # 0x214e
callq 0x1100
nop
// File: /workspace/github_cpp_makefile_star2_O3/narula[P]skiplists/skiplist-fanout.cc
// Function: SkipList::printlist()
void SkipList::printlist() {
  node* ptr = head;
  while (ptr != tail) {
	printf("[K:%02d ", ptr->key);
	printf("N: %02d ", ptr->nexts[0][0].nxt->key);
	for (int j = 1; j < ptr->topLevel; j++) {
	  printf("N: ");
	  for (int k = 0; k < FANOUT; k++) {
		printf("%02d ", ptr->nexts[j][k].nxt->key);
	  }
	}
	printf("]\n");
	ptr = ptr->nexts[0][0].nxt;
  }
  printf("]\n");
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq (%rdi), %r14
movq %rdi, (%rsp)
cmpq 0x8(%rdi), %r14
je 0x1bef
leaq 0x575(%rip), %r12       # 0x20d4
leaq 0x568(%rip), %r13       # 0x20ce
movl (%r14), %esi
leaq 0x552(%rip), %rdi       # 0x20c2
xorl %eax, %eax
callq 0x1040
movq 0x10(%r14), %rax
movl (%rax), %esi
leaq 0x547(%rip), %rdi       # 0x20cb
xorl %eax, %eax
callq 0x1040
cmpl $0x2, 0x4(%r14)
jl 0x1bd1
leaq 0x50(%r14), %r15
movl $0x1, %ebp
movq %r12, %rdi
xorl %eax, %eax
callq 0x1040
xorl %ebx, %ebx
movq (%r15,%rbx), %rax
movl (%rax), %esi
movq %r13, %rdi
xorl %eax, %eax
callq 0x1040
addq $0x10, %rbx
cmpq $0x40, %rbx
jne 0x1ba7
incq %rbp
movslq 0x4(%r14), %rax
addq $0x40, %r15
cmpq %rax, %rbp
jl 0x1b9b
leaq 0x57d(%rip), %rdi       # 0x2155
callq 0x1100
movq 0x10(%r14), %r14
movq (%rsp), %rax
cmpq 0x8(%rax), %r14
jne 0x1b66
leaq 0x55f(%rip), %rdi       # 0x2155
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x1100
nop
// File: /workspace/github_cpp_makefile_star2_O3/narula[P]skiplists/skiplist-fanout.cc
// Function: main
int main(int argc, char** argv) {
  srand(time(NULL));
  int LIST_SIZE = atoi(argv[1]);
  int ITERATIONS = 10000;
  int maxl = floor(log(LIST_SIZE)/log(4))+1;
  SkipList* stest2 = SkipList::init_list(LIST_SIZE, maxl);
  assert(stest2);
  if (LIST_SIZE < 99) {
	basic_test(stest2);
	stest2->pretty_print_skiplist();
  }
  stest2->enable_counts();
  timespec ts;
  clock_gettime(CLOCK_MONOTONIC, &ts);
  time_t start = ts.tv_sec*1000000000 + ts.tv_nsec;
  for (int i = 0; i < ITERATIONS; i++) {
	int key = (rand() % LIST_SIZE);
	if (ITERATIONS < 50) printf("key: %d\n", key);
	stest2->lookup(key);
  }
  clock_gettime(CLOCK_MONOTONIC, &ts);
  stest2->disable_counts();
  time_t lookup_time = ts.tv_sec*1000000000 + ts.tv_nsec;
  printf("lookupns: %ld; itr: %d; size: %d; levels: %d; probability: %d; ptr: %d\n", 
		 (lookup_time-start)/(ITERATIONS), ITERATIONS, LIST_SIZE, maxl, FANOUT, stest2->get_ptr_count());
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rsi, %rbx
xorl %edi, %edi
callq 0x10b0
movl %eax, %edi
callq 0x10c0
movq 0x8(%rbx), %rdi
callq 0x1110
movl %eax, %ebx
cvtsi2sd %eax, %xmm0
callq 0x1080
divsd 0x206(%rip), %xmm0      # 0x2008
callq 0x1120
addsd 0x201(%rip), %xmm0      # 0x2010
cvttsd2si %xmm0, %ebp
movl %ebx, %edi
movl %ebp, %esi
callq 0x1642
movq %rax, %r14
cmpl $0x62, %ebx
jle 0x1ee0
movl $0x1, 0x1c(%r14)
leaq 0x8(%rsp), %r15
movl $0x1, %edi
movq %r15, %rsi
callq 0x10a0
movq (%r15), %r13
movq 0x8(%r15), %r12
movl $0x2710, %r15d          # imm = 0x2710
callq 0x1050
cltd
idivl %ebx
movq %r14, %rdi
movl %edx, %esi
callq 0x1288
decl %r15d
jne 0x1e4f
leaq 0x8(%rsp), %r15
movl $0x1, %edi
movq %r15, %rsi
callq 0x10a0
movq (%r15), %rax
subq %r13, %rax
movq 0x8(%r15), %rcx
subq %r12, %rcx
imulq $0x3b9aca00, %rax, %rax # imm = 0x3B9ACA00
addq %rcx, %rax
movabsq $0x346dc5d63886594b, %rcx # imm = 0x346DC5D63886594B
imulq %rcx
movq %rdx, %rsi
shrq $0x3f, %rsi
sarq $0xb, %rdx
addq %rdx, %rsi
movl 0x18(%r14), %eax
movl %eax, (%rsp)
leaq 0x24e(%rip), %rdi       # 0x2106
movl $0x2710, %edx           # imm = 0x2710
movl %ebx, %ecx
movl %ebp, %r8d
movl $0x4, %r9d
xorl %eax, %eax
callq 0x1040
xorl %eax, %eax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %r14, %rdi
callq 0x1ac3
// File: /workspace/github_cpp_makefile_star2_O3/leobru[P]ACPUfont/averager.cc
// Function: Picture::divide()
Picture divide() {
	Picture ret = *this;
	for (int i = 0; i < height; ++i)
            for (int j = 0; j < width; ++j)
		ret.p(i,j) = (ret.p(i,j) + (weight+1)/2)/weight;
        ret.weight = 1;
	return ret;
    }

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %rbx
callq 0x2e3e
leaq 0x18(%rbx), %rax
movupd 0x18(%r14), %xmm0
movupd %xmm0, 0x18(%rbx)
movl 0x24(%r14), %esi
testl %esi, %esi
jle 0x24b3
movq (%rbx), %rcx
movsd 0x18(%r14), %xmm0
movsd 0x2be3(%rip), %xmm1     # 0x5040
addsd %xmm0, %xmm1
mulsd 0x2bc7(%rip), %xmm1     # 0x5030
movl 0x20(%r14), %edi
xorl %edx, %edx
testl %edi, %edi
jle 0x24ad
movslq %edx, %rsi
xorl %r8d, %r8d
movslq 0x20(%rbx), %rdi
imulq %rsi, %rdi
addq %r8, %rdi
xorps %xmm2, %xmm2
cvtsi2sdl (%rcx,%rdi,4), %xmm2
addsd %xmm1, %xmm2
divsd %xmm0, %xmm2
cvttsd2si %xmm2, %r9d
movl %r9d, (%rcx,%rdi,4)
movl 0x20(%r14), %edi
incq %r8
cmpl %edi, %r8d
jl 0x2479
movl 0x24(%r14), %esi
incl %edx
cmpl %esi, %edx
jl 0x246f
movabsq $0x3ff0000000000000, %rcx # imm = 0x3FF0000000000000
movq %rcx, (%rax)
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
nop
// File: /workspace/github_cpp_makefile_star2_O3/leobru[P]ACPUfont/averager.cc
// Function: Picture::dump(_IO_FILE*) const
void dump(FILE * f) const {
	fprintf(f, "P5\n%d %d\n255\n", width, height);
	for (int i = 0; i < height; ++i) {
            for (int j = 0; j < width; ++j)
                putc(255-(p(i,j)+weight/2)/weight, f);
	}
        fclose(f);
    }

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
movl 0x20(%rdi), %edx
movl 0x24(%rdi), %ecx
leaq 0x2bc8(%rip), %rsi      # 0x50af
xorl %r15d, %r15d
movq %rbx, %rdi
xorl %eax, %eax
callq 0x1140
movl 0x24(%r14), %ecx
testl %ecx, %ecx
jle 0x2581
movl 0x20(%r14), %eax
movsd 0x2b24(%rip), %xmm3     # 0x5030
movsd 0x2b24(%rip), %xmm4     # 0x5038
testl %eax, %eax
jle 0x2579
xorl %r12d, %r12d
imull %r15d, %eax
cltq
addq %r12, %rax
movq (%r14), %rcx
xorps %xmm0, %xmm0
cvtsi2sdl (%rcx,%rax,4), %xmm0
movsd 0x18(%r14), %xmm1
movapd %xmm1, %xmm2
mulsd %xmm3, %xmm2
addsd %xmm0, %xmm2
divsd %xmm1, %xmm2
movapd %xmm4, %xmm0
subsd %xmm2, %xmm0
cvttsd2si %xmm0, %edi
movq %rbx, %rsi
callq 0x11d0
movsd 0x2ad7(%rip), %xmm4     # 0x5038
movsd 0x2ac7(%rip), %xmm3     # 0x5030
movl 0x20(%r14), %eax
incq %r12
cmpl %eax, %r12d
jl 0x251b
movl 0x24(%r14), %ecx
incl %r15d
cmpl %ecx, %r15d
jl 0x2514
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
jmp 0x10e0
// File: /workspace/github_cpp_makefile_star2_O3/leobru[P]ACPUfont/averager.cc
// Function: Picture::contrast(int, int)
Picture contrast(int pivot, int power) {
        Picture ret = *this;
        if (weight == 0.0) return ret;
        double knee = pivot/255.0;
        for (int i = 0; i < height; ++i)
            for (int j = 0; j < width; ++j) {
                double v = p(i,j)/(weight*255.0);
                if (v <= knee) {
                    v = pow(v/knee/2, power)/pow(0.5, power-1);
                } else {
                    v = 1-pow((1-v)/(1-knee)/2, power)/pow(0.5, power-1);
                }
                ret.p(i,j) = lround(v*255*weight);
            }
        return ret;
    }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movl %ecx, %ebp
movl %edx, %r15d
movq %rsi, %r14
movq %rdi, %rbx
callq 0x2e3e
movups 0x18(%r14), %xmm0
movups %xmm0, 0x18(%rbx)
movsd 0x18(%r14), %xmm0
xorpd %xmm1, %xmm1
ucomisd %xmm1, %xmm0
jne 0x279f
jnp 0x2913
movl 0x24(%r14), %ecx
testl %ecx, %ecx
jle 0x2913
cvtsi2sd %r15d, %xmm2
divsd 0x2880(%rip), %xmm2     # 0x5038
xorps %xmm0, %xmm0
cvtsi2sd %ebp, %xmm0
movsd %xmm0, 0x8(%rsp)
decl %ebp
xorps %xmm0, %xmm0
cvtsi2sd %ebp, %xmm0
xorpd 0x284a(%rip), %xmm0     # 0x5020
movapd %xmm0, 0x20(%rsp)
movsd 0x285c(%rip), %xmm0     # 0x5040
subsd %xmm2, %xmm0
movsd %xmm0, 0x10(%rsp)
movl 0x20(%r14), %eax
xorl %r15d, %r15d
movsd 0x283b(%rip), %xmm3     # 0x5038
movsd %xmm2, 0x18(%rsp)
testl %eax, %eax
jle 0x2907
movslq %r15d, %r12
xorl %r13d, %r13d
imull %r15d, %eax
cltq
addq %r13, %rax
movq (%r14), %rcx
xorps %xmm0, %xmm0
cvtsi2sdl (%rcx,%rax,4), %xmm0
movsd 0x18(%r14), %xmm1
mulsd %xmm3, %xmm1
divsd %xmm1, %xmm0
ucomisd %xmm0, %xmm2
jae 0x2889
movsd 0x27ff(%rip), %xmm1     # 0x5040
subsd %xmm0, %xmm1
divsd 0x10(%rsp), %xmm1
mulsd 0x27dd(%rip), %xmm1     # 0x5030
movapd %xmm1, %xmm0
movsd 0x8(%rsp), %xmm1
callq 0x11a0
movsd %xmm0, (%rsp)
movapd 0x20(%rsp), %xmm0
callq 0x10d0
movsd (%rsp), %xmm2
divsd %xmm0, %xmm2
movsd 0x27bd(%rip), %xmm1     # 0x5040
subsd %xmm2, %xmm1
jmp 0x28b9
divsd %xmm2, %xmm0
mulsd 0x279b(%rip), %xmm0     # 0x5030
movsd 0x8(%rsp), %xmm1
callq 0x11a0
movsd %xmm0, (%rsp)
movapd 0x20(%rsp), %xmm0
callq 0x10d0
movsd (%rsp), %xmm1
divsd %xmm0, %xmm1
movsd 0x2777(%rip), %xmm0     # 0x5038
mulsd %xmm0, %xmm1
mulsd 0x18(%r14), %xmm1
movapd %xmm1, %xmm0
callq 0x1030
movsd 0x275c(%rip), %xmm3     # 0x5038
movslq 0x20(%rbx), %rcx
imulq %r12, %rcx
addq %r13, %rcx
movq (%rbx), %rdx
movl %eax, (%rdx,%rcx,4)
movl 0x20(%r14), %eax
incq %r13
cmpl %eax, %r13d
movsd 0x18(%rsp), %xmm2
jl 0x2811
movl 0x24(%r14), %ecx
incl %r15d
cmpl %ecx, %r15d
jl 0x2803
movq %rbx, %rax
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O3/leobru[P]ACPUfont/averager.cc
// Function: Picture::mse(Picture const&, int, int) const
double mse(const Picture & other, int voff, int hoff) const {
	unsigned totpix = 0;
	double sum = 0.0;
	for (int i = max(0, voff); i < min(height, height+voff); ++i) {
            for (int j = std::max(0, hoff); j < min(width, width+hoff); ++j) {
                double diff=p(i,j)/weight - other.p(i-voff,j-hoff)/other.weight;
                sum += diff*diff;
                ++totpix;
            }
        }
	return sum / pow(totpix, msepower);
    }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
xorl %eax, %eax
testl %edx, %edx
movl $0x0, %r14d
cmovgl %edx, %r14d
movl 0x24(%rdi), %r15d
leal (%r15,%rdx), %r8d
cmpl %r15d, %r8d
cmovll %r8d, %r15d
xorpd %xmm3, %xmm3
xorpd %xmm0, %xmm0
cmpl %r15d, %r14d
jge 0x2a97
testl %ecx, %ecx
movl $0x0, %r8d
cmovgl %ecx, %r8d
movslq 0x20(%rdi), %r9
leal (%r9,%rcx), %r10d
cmpl %r9d, %r10d
cmovgel %r9d, %r10d
movupd 0x18(%rdi), %xmm0
movslq 0x20(%rsi), %r11
movq (%rsi), %rbx
movl %r10d, %ebp
subl %r8d, %ebp
movl %r14d, %r14d
movslq %edx, %rdx
movhpd 0x18(%rsi), %xmm0       # xmm0 = xmm0[0],mem[0]
movq %r9, %rsi
imulq %r14, %rsi
shlq $0x2, %rsi
addq (%rdi), %rsi
movl %r15d, %edi
shlq $0x2, %r9
negl %ecx
cmpl %r10d, %r8d
jge 0x2a82
movq %r14, %r15
subq %rdx, %r15
imulq %r11, %r15
leaq (%rbx,%r15,4), %r15
movq %r8, %r12
leal (%rcx,%r12), %r13d
movslq %r13d, %r13
movss (%rsi,%r12,4), %xmm1
movss (%r15,%r13,4), %xmm2
unpcklps %xmm2, %xmm1            # xmm1 = xmm1[0],xmm2[0],xmm1[1],xmm2[1]
cvtdq2pd %xmm1, %xmm1
divpd %xmm0, %xmm1
movapd %xmm1, %xmm2
unpckhpd %xmm1, %xmm2            # xmm2 = xmm2[1],xmm1[1]
subsd %xmm2, %xmm1
mulsd %xmm1, %xmm1
addsd %xmm1, %xmm3
incq %r12
cmpq %r12, %r10
jne 0x2a46
addl %ebp, %eax
incq %r14
addq %r9, %rsi
cmpq %rdi, %r14
jne 0x2a30
movl %eax, %eax
xorps %xmm0, %xmm0
cvtsi2sd %rax, %xmm0
movsd %xmm3, (%rsp)
movsd 0x566c(%rip), %xmm1     # 0x8110
callq 0x11a0
movsd (%rsp), %xmm1
divsd %xmm0, %xmm1
movapd %xmm1, %xmm0
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nop