LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_cpp_makefile_star2_O1/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 0x976d
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 $0x54474341, %edi       # imm = 0x54474341
movl %eax, %ecx
shrl %cl, %edi
movzbl %dil, %ecx
cmpl $0x46, %ecx
jg 0x971e
movb $0x54, %al
cmpl $0x41, %ecx
je 0x972e
cmpl $0x43, %ecx
jne 0x977c
movb $0x47, %al
jmp 0x972e
cmpl $0x47, %ecx
je 0x972c
cmpl $0x54, %ecx
jne 0x977c
movb $0x41, %al
jmp 0x972e
movb $0x43, %al
movl %r12d, %r13d
shrl $0x5, %r13d
movl %r13d, %r15d
cmpl %edx, %r13d
je 0x9745
movq $0x0, (%r14,%r15,8)
movl %r12d, %edx
andl $0x1f, %edx
movq (%r14,%r15,8), %rdi
movzbl %al, %esi
callq 0x9558
movq %rax, (%r14,%r15,8)
incl %r12d
addl $-0x2, %ebp
movl %r13d, %edx
addl $-0x1, %ebx
jb 0x96e2
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
callq 0x35eb
nopl (%rax)
// File: /workspace/github_cpp_makefile_star2_O1/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 0x99ad
xorl %r11d, %r11d
movzbl (%rsi), %ebx
testl %ebx, %ebx
je 0x99ad
movq 0x20(%rdi), %rax
testq %rax, %rax
je 0x9975
movq (%rax), %r14
movq 0x8(%rax), %rax
subq %r14, %rax
sarq $0x2, %rax
testl %eax, %eax
jle 0x9975
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 0x9a12
cmpb %r8b, (%r15,%r10)
jne 0x996d
cmpq %r10, %rax
jbe 0x9a21
cmpl %ecx, (%r14,%r10,4)
je 0x9a04
incq %r10
cmpq %r10, %r12
jne 0x994b
cmpl $0x47, %ebx
je 0x998f
cmpl $0x43, %ebx
je 0x9989
cmpl $0x41, %ebx
jne 0x9995
movq (%rdi), %rdi
jmp 0x9999
movq 0x8(%rdi), %rdi
jmp 0x9999
movq 0x10(%rdi), %rdi
jmp 0x9999
movq 0x18(%rdi), %rdi
testq %rdi, %rdi
je 0x9a00
incl %r11d
incq %rsi
cmpl %edx, %r11d
jne 0x990a
movq 0x20(%rdi), %rax
testq %rax, %rax
je 0x9a00
movq (%rax), %r9
movq 0x8(%rax), %rdx
subq %r9, %rdx
sarq $0x2, %rdx
testl %edx, %edx
jle 0x9a00
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 0x9a2d
cmpb %r8b, (%rdi,%rsi)
jne 0x99f8
cmpq %rsi, %rdx
jbe 0x9a41
cmpl %ecx, (%r9,%rsi,4)
je 0x9a04
incq %rsi
cmpq %rsi, %r10
jne 0x99e2
xorl %eax, %eax
jmp 0x9a06
movb $0x1, %al
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
leaq 0x25d6(%rip), %rdi      # 0xbfef
movq %r9, %rsi
movq %r9, %rdx
jmp 0x9a3a
leaq 0x25c7(%rip), %rdi      # 0xbfef
movq %r10, %rsi
jmp 0x9a37
leaq 0x25bb(%rip), %rdi      # 0xbfef
movq %rax, %rsi
movq %rax, %rdx
xorl %eax, %eax
callq 0x33d0
leaq 0x25a7(%rip), %rdi      # 0xbfef
jmp 0x9a3a
// File: /workspace/github_cpp_makefile_star2_O1/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, %r15d
movq %r15, %rax
shlq $0x4, %rax
leaq (%rax,%rax,2), %rdi
callq 0x3030
movq %rax, %r14
movq %rax, 0x8(%rbx)
testl %ebp, %ebp
je 0x9a86
shlq $0x4, %r15
leaq (%r15,%r15,2), %rdx
movq %r14, %rdi
xorl %esi, %esi
callq 0x3180
movl %ebp, 0x10(%rbx)
movq %r14, (%rbx)
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/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
cmpl $0x0, 0x10(%rdi)
je 0x9dfd
movq (%rbx), %r15
addq $0x28, %r15
xorl %ebp, %ebp
movq -0x8(%r15), %r14
testq %r14, %r14
je 0x9df2
movq (%r14), %rdi
testq %rdi, %rdi
je 0x9dbc
movq 0x10(%r14), %rsi
subq %rdi, %rsi
callq 0x32d0
movl $0x18, %esi
movq %r14, %rdi
callq 0x32d0
movq (%r15), %r14
testq %r14, %r14
je 0x9df2
movq (%r14), %rdi
testq %rdi, %rdi
je 0x9de5
movq 0x10(%r14), %rsi
subq %rdi, %rsi
callq 0x32d0
movl $0x18, %esi
movq %r14, %rdi
callq 0x32d0
incl %ebp
addq $0x30, %r15
cmpl 0x10(%rbx), %ebp
jb 0x9d9f
movq (%rbx), %rdi
addq $0x8, %rsp
testq %rdi, %rdi
je 0x9e14
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x3360
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/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 0x5474(%rip), %rax      # 0x7fb8
movq (%rax), %rdi
callq 0x2160
xorl %edi, %edi
movq %rbx, %rsi
callq 0x2130
testl %eax, %eax
js 0x2baf
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 0x2bbd
leaq 0xf(%rsp), %rsi
movl $0x1, %edx
xorl %edi, %edi
callq 0x2200
testq %rax, %rax
js 0x2bcb
leaq 0x10(%rsp), %rdx
orb $0xa, 0xc(%rdx)
xorl %edi, %edi
movl $0x1, %esi
callq 0x2190
testl %eax, %eax
js 0x2bd9
movb 0xf(%rsp), %al
addq $0x50, %rsp
popq %rbx
retq
leaq 0x24e2(%rip), %rdi      # 0x5098
callq 0x20d0
jmp 0x2b5a
leaq 0x24e0(%rip), %rdi      # 0x50a4
callq 0x20d0
jmp 0x2b76
leaq 0x24e3(%rip), %rdi      # 0x50b5
callq 0x20d0
jmp 0x2b8c
leaq 0x24dc(%rip), %rdi      # 0x50bc
callq 0x20d0
jmp 0x2ba5
// File: /workspace/github_cpp_makefile_star2_O1/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 0x2c1e
cmpl $0x2, %edi
je 0x2c29
retq
addl $0x186a0, 0x5548(%rip)  # imm = 0x186A0
retq
pushq %rax
cmpb $0x1, 0x5543(%rip)      # 0x8174
jne 0x2c45
movq 0x553e(%rip), %rax      # 0x8178
movl 0x48(%rax), %edi
movl 0x4c(%rax), %esi
callq 0x2be7
movl $0x2, %edi
callq 0x2180
// File: /workspace/github_cpp_makefile_star2_O1/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 0x32d6
movq (%r15), %rax
movq -0x18(%rax), %rax
xorl %r12d, %r12d
cmpl $0x0, 0x20(%r15,%rax)
je 0x2fed
xorl %r13d, %r13d
jmp 0x3070
xorl %r14d, %r14d
xorl %ebp, %ebp
movq 0x38(%rbx), %rsi
subq 0x30(%rbx), %rsi
movq %rsi, %rax
shrq $0x5, %rax
cltq
cmpq %rax, %rbp
jl 0x3015
sarq $0x4, %rsi
movq (%rsp), %rdi
callq 0x32d6
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 0x2260
movq (%rsp), %rax
movq (%rax), %rax
movl 0x8(%rax,%r14), %eax
cmpl %eax, %r12d
cmovlel %eax, %r12d
movq (%r15), %rax
movq -0x18(%rax), %rax
addq $0x20, %r14
incq %rbp
cmpl $0x0, 0x20(%r15,%rax)
je 0x2ff2
movl %r12d, %r13d
movl %ebp, %r12d
cmpq 0x4f69(%rip), %r15      # 0x7fe0
je 0x3081
movq %r15, %rdi
callq 0x2040
movq (%rsp), %rdi
movq %r12, %rsi
callq 0x32d6
movq 0x30(%rbx), %rdi
movq 0x38(%rbx), %rax
subq %rdi, %rax
shrq $0x5, %rax
testl %eax, %eax
jle 0x30d3
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 0x30a6
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x30e8
jmp 0x30e8
jmp 0x30e8
movq %rax, %r15
movq (%rsp), %rdi
callq 0x324a
movq %rbx, %rdi
callq 0x32a6
movq %r15, %rdi
callq 0x2250
// File: /workspace/github_cpp_makefile_star2_O1/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 %r12
pushq %rbx
subq $0x10, %rsp
movq %rdi, %rbx
movl $0x14, %edi
callq 0x2100
movq %rax, %r14
xorl %ebp, %ebp
leaq 0x8(%rsp), %rdx
movl %ebp, (%rdx)
movl $0x12c, %esi            # imm = 0x12C
movq %rbx, %rdi
callq 0x374c
leaq 0xc(%rsp), %rdx
movl %ebp, (%rdx)
leaq 0x18(%rbx), %rdi
movl $0x12c, %esi            # imm = 0x12C
callq 0x374c
xorps %xmm0, %xmm0
movups %xmm0, (%r14)
movw $0x1, 0x10(%r14)
cmpb $0x1, 0x5014(%rip)      # 0x8174
jne 0x322e
leaq 0x2222(%rip), %rdi      # 0x538f
xorl %eax, %eax
callq 0x2030
leaq 0x1f53(%rip), %rdi      # 0x50ce
movl $0x1, %esi
movl $0x1, %edx
xorl %eax, %eax
callq 0x2030
movq 0x4e25(%rip), %r12      # 0x7fb8
movq (%r12), %rdi
callq 0x2160
movq 0x30(%rbx), %r15
cmpq 0x38(%rbx), %r15
je 0x31b4
movq (%r15), %rdi
callq 0x2220
addq $0x20, %r15
jmp 0x31a0
movq 0x30(%rbx), %rax
movq 0x38(%rbx), %rsi
subq %rax, %rsi
shrq $0x5, %rsi
movl %esi, 0x50(%rbx)
movl $0x0, 0x48(%rbx)
addl $0x2, %esi
movl %esi, 0x4c(%rbx)
movl 0x8(%rax), %eax
incl %eax
movl %eax, 0x54(%rbx)
leaq 0x1eec(%rip), %r15      # 0x50ce
movq %r15, %rdi
movl $0x1, %edx
xorl %eax, %eax
callq 0x2030
movq (%r12), %rdi
callq 0x2160
leaq 0x2193(%rip), %rdi      # 0x5394
xorl %eax, %eax
callq 0x2030
movq (%r12), %rdi
callq 0x2160
movl 0x48(%rbx), %edx
movl 0x4c(%rbx), %esi
incl %esi
incl %edx
movq %r15, %rdi
xorl %eax, %eax
callq 0x2030
movq (%r12), %rdi
callq 0x2160
movq %rbx, %rdi
movq %r14, %rsi
callq 0x3506
testb %al, %al
jne 0x322e
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/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 0x3fe8(%rip), %edi      # 0x8170
callq 0x21e0
incl %r12d
incl %r13d
leaq 0xf34(%rip), %r15       # 0x50ce
movq %r15, %rdi
movl %r12d, %esi
movl %r13d, %edx
xorl %eax, %eax
callq 0x2030
movq 0x3e07(%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, 0x3f85(%rip)      # 0x8175
jne 0x420b
movq %r14, %rdi
movq %rbx, %rsi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x421a
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/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
movl 0x4(%rbx), %ecx
movl 0x1c(%rdi), %edx
movl 0x18(%rdi), %r8d
leal -0x1(%rcx), %r9d
movabsq $0x100000000, %r11      # imm = 0x100000000
testl %ecx, %ecx
jle 0x1357
decq %rcx
movl %ecx, %r14d
shlq $0x6, %r14
movq 0x40(%rbx,%r14), %r15
jmp 0x12ce
movq %r15, %rbx
movq 0x40(%r15,%r14), %r15
cmpl $0x1, %edx
jne 0x12da
incl %r8d
movl %r8d, 0x18(%rdi)
movl 0x38(%rbx,%r14), %ebp
cmpl %esi, %ebp
jl 0x12c6
leaq 0x8(%rbx), %r15
cmpl %esi, %ebp
jne 0x12f1
xorl %ebp, %ebp
movl %ecx, %eax
jmp 0x1322
movl %r9d, %r13d
shlq $0x6, %r13
addq %r15, %r13
xorl %r10d, %r10d
movabsq $-0x200000000, %r12     # imm = 0xFFFFFFFE00000000
movq %r10, %rbp
addq %r11, %r12
addq $0x10, %r10
cmpl %esi, (%r13,%rbp)
jl 0x1308
movb $0x1, %bpl
cmpq $0x10, %r10
jne 0x132c
decl %r9d
testb %bpl, %bpl
jne 0x12ad
jmp 0x135c
addq %r14, %r15
movq %r12, %r10
sarq $0x1c, %r10
cmpl %esi, (%r10,%r15)
je 0x12eb
sarq $0x20, %r12
shlq $0x4, %r12
movq 0x8(%r12,%r15), %rbx
cmpl $0x1, %edx
jne 0x1322
incl %r8d
movl %r8d, 0x18(%rdi)
jmp 0x1322
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/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 0x14bb
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 0x1402
incl %r9d
movl %r9d, 0x18(%rdi)
movl 0x38(%rbx,%r13), %r12d
cmpl %esi, %r12d
jge 0x1416
movq %r15, %rbx
movq 0x40(%r15,%r13), %r15
jmp 0x13f5
leaq 0x8(%rbx), %rbp
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 0x1448
cmpl %esi, %r12d
jne 0x1448
movl %r8d, -0x14(%rsp)
jmp 0x14ab
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 0x1458
cmpq $0x10, %rcx
je 0x14ab
cmpl $-0x1, -0x14(%rsp)
jne 0x1492
movq %rbp, %rcx
addq %r13, %rcx
movq %r15, %rdx
sarq $0x1c, %rdx
cmpl %esi, (%rdx,%rcx)
movl $0xffffffff, %ecx       # imm = 0xFFFFFFFF
cmovel %r8d, %ecx
movl %ecx, -0x14(%rsp)
addq %r13, %rbp
sarq $0x1c, %r15
movq 0x8(%r15,%rbp), %rbx
cmpl $0x1, %r10d
jne 0x14ab
incl %r9d
movl %r9d, 0x18(%rdi)
addq $-0x40, %r11
cmpq $0x1, %rax
jg 0x13e3
jmp 0x14c3
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_O1/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 0x139a
movl %eax, %ecx
xorl %eax, %eax
cmpl $-0x1, %ecx
jne 0x1629
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 0x156b
movslq %ecx, %rcx
movq %rcx, %rsi
incl %edx
shrq $0x2, %rsi
notl %ecx
testb $0xc, %cl
movq %rsi, %rcx
je 0x155b
testl %r13d, %r13d
jle 0x1629
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 0x1602
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 0x15d3
incq %rdi
addq $0x20, %r8
addq $0x40, %rsi
addq $0x40, %rdx
cmpq %rcx, %rdi
jne 0x159e
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_O1/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 0x1a20
movq %rbx, %rdi
movl $0x63, %esi
callq 0x14d2
testl %eax, %eax
jne 0x1a3f
leaq 0x653(%rip), %rdi       # 0x205b
leaq 0x61d(%rip), %rsi       # 0x202c
leaq 0x629(%rip), %rcx       # 0x203f
movl $0x116, %edx            # imm = 0x116
callq 0x1070
leaq 0x5f1(%rip), %rdi       # 0x2018
leaq 0x5fe(%rip), %rsi       # 0x202c
leaq 0x60a(%rip), %rcx       # 0x203f
movl $0x115, %edx            # imm = 0x115
callq 0x1070
movq %rbx, %rdi
movl $0x63, %esi
callq 0x1288
testl %eax, %eax
jns 0x1a6f
leaq 0x617(%rip), %rdi       # 0x206e
leaq 0x5ce(%rip), %rsi       # 0x202c
leaq 0x5da(%rip), %rcx       # 0x203f
movl $0x117, %edx            # imm = 0x117
callq 0x1070
movq %rbx, %rdi
movl $0x63, %esi
callq 0x14d2
leaq 0x5fe(%rip), %rdi       # 0x2081
leaq 0x5a2(%rip), %rsi       # 0x202c
leaq 0x5ae(%rip), %rcx       # 0x203f
movl $0x118, %edx            # imm = 0x118
callq 0x1070
// File: /workspace/github_cpp_makefile_star2_O1/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 0x1ae8
incl %ebp
cmpl $0x10, %ebp
jne 0x1aa3
movq %rbx, %rdi
movl $0x63, %esi
callq 0x1288
testl %eax, %eax
js 0x1b07
leaq 0x548(%rip), %rdi       # 0x2018
leaq 0x555(%rip), %rsi       # 0x202c
leaq 0x5c9(%rip), %rcx       # 0x20a7
movl $0x11f, %edx            # imm = 0x11F
callq 0x1070
leaq 0x5a6(%rip), %rdi       # 0x2095
leaq 0x536(%rip), %rsi       # 0x202c
leaq 0x5aa(%rip), %rcx       # 0x20a7
movl $0x11d, %edx            # imm = 0x11D
callq 0x1070
leaq 0x640(%rip), %rdi       # 0x214e
callq 0x1100
nop
// File: /workspace/github_cpp_makefile_star2_O1/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 0x1bc7
leaq 0x59d(%rip), %r12       # 0x20d4
leaq 0x590(%rip), %r13       # 0x20ce
movl (%r14), %esi
leaq 0x57a(%rip), %rdi       # 0x20c2
xorl %eax, %eax
callq 0x1040
movq 0x10(%r14), %rax
movl (%rax), %esi
leaq 0x56f(%rip), %rdi       # 0x20cb
xorl %eax, %eax
callq 0x1040
cmpl $0x2, 0x4(%r14)
jl 0x1ba9
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 0x1b7f
incq %rbp
movslq 0x4(%r14), %rax
addq $0x40, %r15
cmpq %rax, %rbp
jl 0x1b73
leaq 0x5a5(%rip), %rdi       # 0x2155
callq 0x1100
movq 0x10(%r14), %r14
movq (%rsp), %rax
cmpq 0x8(%rax), %r14
jne 0x1b3e
leaq 0x587(%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_O1/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 0x22e(%rip), %xmm0      # 0x2008
callq 0x1120
addsd 0x229(%rip), %xmm0      # 0x2010
cvttsd2si %xmm0, %ebp
movl %ebx, %edi
movl %ebp, %esi
callq 0x1638
movq %rax, %r14
cmpl $0x62, %ebx
jle 0x1ec0
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 0x1e27
leaq 0x8(%rsp), %r15
movl $0x1, %edi
movq %r15, %rsi
callq 0x10a0
movl $0x0, 0x1c(%r14)
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 0x26e(%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 0x1a9b
// File: /workspace/github_cpp_makefile_star2_O1/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 0x2e0e
leaq 0x18(%rbx), %rax
movupd 0x18(%r14), %xmm0
movupd %xmm0, 0x18(%rbx)
cmpl $0x0, 0x24(%r14)
jle 0x2454
movq (%rbx), %rcx
movsd 0x18(%r14), %xmm0
movsd 0x2c3c(%rip), %xmm1     # 0x5040
addsd %xmm0, %xmm1
mulsd 0x2c20(%rip), %xmm1     # 0x5030
xorl %edx, %edx
cmpl $0x0, 0x20(%r14)
jle 0x244c
movslq %edx, %rsi
xorl %edi, %edi
movslq 0x20(%rbx), %r8
imulq %rsi, %r8
addq %rdi, %r8
xorps %xmm2, %xmm2
cvtsi2sdl (%rcx,%r8,4), %xmm2
addsd %xmm1, %xmm2
divsd %xmm0, %xmm2
cvttsd2si %xmm2, %r9d
movl %r9d, (%rcx,%r8,4)
incq %rdi
cmpl 0x20(%r14), %edi
jl 0x241e
incl %edx
cmpl 0x24(%r14), %edx
jl 0x2412
movabsq $0x3ff0000000000000, %rcx # imm = 0x3FF0000000000000
movq %rcx, (%rax)
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_cpp_makefile_star2_O1/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 0x2c28(%rip), %rsi      # 0x50af
xorl %r15d, %r15d
movq %rbx, %rdi
xorl %eax, %eax
callq 0x1140
cmpl $0x0, 0x24(%r14)
jle 0x2519
movsd 0x2b8d(%rip), %xmm3     # 0x5030
movsd 0x2b8d(%rip), %xmm4     # 0x5038
movl 0x20(%r14), %eax
testl %eax, %eax
jle 0x2510
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 0x2b3c(%rip), %xmm4     # 0x5038
movsd 0x2b2c(%rip), %xmm3     # 0x5030
movl 0x20(%r14), %eax
incq %r12
cmpl %eax, %r12d
jl 0x24b6
incl %r15d
cmpl 0x24(%r14), %r15d
jl 0x24ab
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
jmp 0x10e0
// File: /workspace/github_cpp_makefile_star2_O1/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 0x2e0e
movups 0x18(%r14), %xmm0
movups %xmm0, 0x18(%rbx)
movsd 0x18(%r14), %xmm0
xorpd %xmm1, %xmm1
ucomisd %xmm1, %xmm0
jne 0x274f
jnp 0x28bf
cmpl $0x0, 0x24(%r14)
jle 0x28bf
cvtsi2sd %r15d, %xmm2
divsd 0x28d1(%rip), %xmm2     # 0x5038
xorps %xmm0, %xmm0
cvtsi2sd %ebp, %xmm0
movsd %xmm0, 0x8(%rsp)
decl %ebp
xorps %xmm0, %xmm0
cvtsi2sd %ebp, %xmm0
xorpd 0x289b(%rip), %xmm0     # 0x5020
movapd %xmm0, 0x20(%rsp)
movsd 0x28ad(%rip), %xmm0     # 0x5040
subsd %xmm2, %xmm0
movsd %xmm0, 0x10(%rsp)
xorl %r15d, %r15d
movsd 0x2890(%rip), %xmm3     # 0x5038
movsd %xmm2, 0x18(%rsp)
movl 0x20(%r14), %eax
testl %eax, %eax
jle 0x28b2
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 0x2838
movsd 0x2850(%rip), %xmm1     # 0x5040
subsd %xmm0, %xmm1
divsd 0x10(%rsp), %xmm1
mulsd 0x282e(%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 0x280e(%rip), %xmm1     # 0x5040
subsd %xmm2, %xmm1
jmp 0x2868
divsd %xmm2, %xmm0
mulsd 0x27ec(%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 0x27c8(%rip), %xmm0     # 0x5038
mulsd %xmm0, %xmm1
mulsd 0x18(%r14), %xmm1
movapd %xmm1, %xmm0
callq 0x1030
movsd 0x27ad(%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 0x27c0
incl %r15d
cmpl 0x24(%r14), %r15d
jl 0x27ae
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_O1/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 0x2a41
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 0x2a2c
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 0x29f0
addl %ebp, %eax
incq %r14
addq %r9, %rsi
cmpq %rdi, %r14
jne 0x29da
movl %eax, %eax
xorps %xmm0, %xmm0
cvtsi2sd %rax, %xmm0
movsd %xmm3, (%rsp)
movsd 0x56c2(%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
// File: /workspace/github_cpp_makefile_star2_O1/leobru[P]ACPUfont/averager.cc
// Function: Picture::best_offset(Picture const&, int&, int&) const
double best_offset(const Picture & other, int & voff, int & hoff) const {
	// Compute average distances for all offsets up to size/3
	double minmse = 10e38;
	for (int i = -height/3; i <= height/3; ++i) 
	for (int j = -width/3; j <= width/3; ++j) {
		double curmse = mse(other, i, j);
		if (curmse < minmse) {
			// fprintf(stderr, "MSE = %.3f voff=%d hoff=%d\n", curmse, i, j);
			minmse = curmse;
			voff = i;
			hoff = j;
		}
	}
	// fprintf(stderr, "Best offsets are %d %d\n", voff, hoff);
        return minmse;
    }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rcx, %rbx
movslq 0x24(%rdi), %rax
imulq $0x55555555, %rax, %r13 # imm = 0x55555555
shrq $0x20, %r13
subl %eax, %r13d
movl %r13d, %ecx
shrl $0x1f, %ecx
sarl %r13d
addl %ecx, %r13d
imulq $0x55555556, %rax, %rax # imm = 0x55555556
movq %rax, %rcx
shrq $0x3f, %rcx
shrq $0x20, %rax
addl %ecx, %eax
cmpl %eax, %r13d
jle 0x2ac7
movsd 0x258b(%rip), %xmm0     # 0x5048
movsd %xmm0, (%rsp)
jmp 0x2b80
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %r12
movsd 0x2570(%rip), %xmm0     # 0x5048
movsd %xmm0, (%rsp)
movslq 0x20(%r12), %rax
imulq $0x55555555, %rax, %rbp # imm = 0x55555555
shrq $0x20, %rbp
subl %eax, %ebp
movl %ebp, %ecx
shrl $0x1f, %ecx
sarl %ebp
addl %ecx, %ebp
imulq $0x55555556, %rax, %rax # imm = 0x55555556
movq %rax, %rcx
shrq $0x3f, %rcx
shrq $0x20, %rax
addl %ecx, %eax
cmpl %eax, %ebp
jg 0x2b57
movq %r12, %rdi
movq %r15, %rsi
movl %r13d, %edx
movl %ebp, %ecx
callq 0x2952
movsd (%rsp), %xmm1
ucomisd %xmm0, %xmm1
jbe 0x2b35
movl %r13d, (%r14)
movl %ebp, (%rbx)
movsd %xmm0, (%rsp)
leal 0x1(%rbp), %eax
movslq 0x20(%r12), %rcx
imulq $0x55555556, %rcx, %rcx # imm = 0x55555556
movq %rcx, %rdx
shrq $0x3f, %rdx
shrq $0x20, %rcx
addl %edx, %ecx
cmpl %ecx, %ebp
movl %eax, %ebp
jl 0x2b10
leal 0x1(%r13), %eax
movslq 0x24(%r12), %rcx
imulq $0x55555556, %rcx, %rcx # imm = 0x55555556
movq %rcx, %rdx
shrq $0x3f, %rdx
shrq $0x20, %rcx
addl %edx, %ecx
cmpl %ecx, %r13d
movl %eax, %r13d
jl 0x2add
movsd (%rsp), %xmm0
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/leobru[P]ACPUfont/averager.cc
// Function: Picture::Picture(char const*)
Picture(const char * fname) : weight(1) {
        FILE * f = fopen(fname, "r");
        if (!f) {
            fprintf(stderr, "Cannot open %s\n", fname);
            exit(1);
        }
        int full;
        char p2[3];
        fscanf(f, "%2s", p2);
        if (strcmp("P5", p2)) {
            fprintf(stderr, "Want to see binary PGM (P5)\n");
            exit(1);
        }
        if (3 != fscanf(f, "%d %d %d", &width, &height, &full) || full != 255) {
            fprintf(stderr, "Could not parse PGM header\n");
            exit(1);
        }
        getc(f); // eat linefeed
        reserve(height*width);
        for (int i = 0; i < height; ++i)
            for (int j = 0; j < width; ++j) {
                int pixel = getc(f);
                if (pixel == EOF) {
                    fprintf(stderr, "File ended prematurely\n");
                    exit(1);
                }
                push_back(full-pixel);
                // Now array is in degrees of blackness
            }
        fclose (f);
    }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rsi, %r15
movq %rdi, %rbx
xorps %xmm0, %xmm0
movups %xmm0, (%rdi)
movq $0x0, 0x10(%rdi)
movabsq $0x3ff0000000000000, %rax # imm = 0x3FF0000000000000
movq %rax, 0x18(%rdi)
leaq 0x24db(%rip), %rsi      # 0x50ee
movq %r15, %rdi
callq 0x1110
testq %rax, %rax
je 0x2d2f
movq %rax, %r14
leaq 0x24d2(%rip), %rsi      # 0x5100
leaq 0x5(%rsp), %rdx
movq %rax, %rdi
xorl %eax, %eax
callq 0x11c0
movzwl 0x5(%rsp), %eax
xorl $0x3550, %eax           # imm = 0x3550
movzbl 0x7(%rsp), %ecx
orw %ax, %cx
jne 0x2d37
leaq 0x20(%rbx), %r15
leaq 0x24(%rbx), %rcx
leaq 0x24c0(%rip), %rsi      # 0x5124
leaq 0x8(%rsp), %r8
movq %r14, %rdi
movq %r15, %rdx
movq %rcx, 0x10(%rsp)
xorl %eax, %eax
callq 0x11c0
cmpl $0x3, %eax
jne 0x2d3c
cmpl $0xff, 0x8(%rsp)
jne 0x2d3c
movq %r14, %rdi
callq 0x1060
movslq 0x24(%rbx), %rax
movslq 0x20(%rbx), %rsi
imulq %rax, %rsi
movq %rbx, %rdi
callq 0x35be
movq 0x10(%rsp), %rax
cmpl $0x0, (%rax)
jle 0x2d13
xorl %ebp, %ebp
leaq 0xc(%rsp), %r13
cmpl $0x0, (%r15)
jle 0x2d08
xorl %r12d, %r12d
movq %r14, %rdi
callq 0x1060
cmpl $-0x1, %eax
je 0x2d2a
movl 0x8(%rsp), %ecx
subl %eax, %ecx
movl %ecx, 0xc(%rsp)
movq 0x8(%rbx), %rsi
cmpq 0x10(%rbx), %rsi
je 0x2cf5
movl %ecx, (%rsi)
addq $0x4, %rsi
movq %rsi, 0x8(%rbx)
jmp 0x2d00
movq %rbx, %rdi
movq %r13, %rdx
callq 0x3654
incl %r12d
cmpl (%r15), %r12d
jl 0x2cc8
incl %ebp
movq 0x10(%rsp), %rax
cmpl (%rax), %ebp
jl 0x2cbf
movq %r14, %rdi
callq 0x10e0
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
callq 0x1273
movq %r15, %rdi
callq 0x12bd
callq 0x124e
callq 0x1298
jmp 0x2d43
movq %rax, %r14
movq (%rbx), %rdi
testq %rdi, %rdi
je 0x2d5a
movq 0x10(%rbx), %rsi
subq %rdi, %rsi
callq 0x1100
movq %r14, %rdi
callq 0x11b0
// File: /workspace/github_cpp_makefile_star2_O1/davidgfnet[P]tadns/tadns-server.cc
// Function: resolved_cb(dns_cb_data*)
void resolved_cb(struct dns_cb_data *cbdata) {
    // Return whatever we found
    struct dns_response *dresp = (struct dns_response*)cbdata->context;

    unsigned numans = 0;
    for (const auto &e: cbdata->replies)
        if (e.resptype == RESPONSE_ANSWER)
            numans++;

    switch (cbdata->error) {
    case DNS_OK:
        dresp->pkt.answers = cbdata->replies;
        dresp->pkt.header.flags = 0x8180;
        dresp->pkt.header.nanswers = numans;
        break;
    case DNS_DOES_NOT_EXIST:
        dresp->pkt.header.flags = 0x8180;
        break;
    case DNS_TIMEOUT:
    case DNS_ERROR:
    case DNS_NET_ERROR:
        dresp->pkt.header.flags = 0x8182;
        break;
    };

    // Blocking send, automatic rate limiting?
    uint8_t tmp[2048];
    unsigned towrite = serialize_udp_packet(&dresp->pkt, tmp);
    sendto(listenfd, tmp, towrite, 0, (struct sockaddr*)&dresp->addrstorage, dresp->addrlen);

    delete dresp;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
subq $0x800, %rsp            # imm = 0x800
movq %rdi, %rsi
movq 0x30(%rdi), %rax
movq 0x38(%rdi), %rcx
xorl %ebp, %ebp
cmpq %rcx, %rax
je 0x36c6
cmpl $0x1, 0x4(%rax)
adcl $0x0, %ebp
addq $0x50, %rax
jmp 0x36b4
movq (%rsi), %rbx
movl 0x8(%rsi), %ecx
movl $0x2, %eax
leal -0x2(%rcx), %edx
cmpl $0x3, %edx
jae 0x36df
movw $0x8182, %bp            # imm = 0x8182
jmp 0x3706
testl %ecx, %ecx
je 0x36ee
movw $0x8180, %bp            # imm = 0x8180
cmpl $0x1, %ecx
je 0x3706
jmp 0x370a
addq $0x30, %rsi
leaq 0x28(%rbx), %rdi
callq 0x3a6a
movw $0x8180, 0x2(%rbx)      # imm = 0x8180
movl $0x6, %eax
movw %bp, (%rbx,%rax)
movq %rsp, %r14
movq %rbx, %rdi
movq %r14, %rsi
callq 0x9eb1
movl 0xcb42(%rip), %edi      # 0x10260
movl %eax, %edx
leaq 0x40(%rbx), %r8
movl 0xc0(%rbx), %r9d
movq %r14, %rsi
xorl %ecx, %ecx
callq 0x3070
testq %rbx, %rbx
je 0x3759
leaq 0x28(%rbx), %rdi
callq 0x3b82
leaq 0x10(%rbx), %rdi
callq 0x3bb2
movl $0xc8, %esi
movq %rbx, %rdi
callq 0x32b0
addq $0x800, %rsp            # imm = 0x800
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/davidgfnet[P]tadns/tadns.cc
// Function: parseAddr(char const*, sockaddr_storage*)
bool parseAddr(const char *ipaddr, struct sockaddr_storage *addrout) {
    unsigned ok = 0;
    union {
        struct sockaddr_storage addrst;
        struct sockaddr_in6 ipv6addr;
        struct sockaddr_in ipv4addr;
    } addrunion;
    if (strchr(ipaddr, '.') == NULL) {
        addrunion.ipv6addr.sin6_family = AF_INET6;
        addrunion.ipv6addr.sin6_port = htons(53);
        addrunion.ipv6addr.sin6_flowinfo = 0;
        addrunion.ipv6addr.sin6_scope_id = 0;
        ok |= inet_pton(AF_INET6, ipaddr, &addrunion.ipv6addr.sin6_addr);
    } else {
        addrunion.ipv4addr.sin_family = AF_INET;
        addrunion.ipv4addr.sin_port = htons(53);
        ok |= inet_pton(AF_INET, ipaddr, &addrunion.ipv4addr.sin_addr);
    }
    *addrout = addrunion.addrst;
    return (ok == 1);
}

// Assembly:
pushq %r14
pushq %rbx
subq $0x88, %rsp
movq %rsi, %rbx
movq %rdi, %r14
movl $0x2e, %esi
callq 0x3120
testq %rax, %rax
je 0x435e
leaq 0xc(%rsp), %rdx
movl $0x35000002, -0x4(%rdx) # imm = 0x35000002
movl $0x2, %edi
jmp 0x4377
leaq 0x10(%rsp), %rdx
movq $0x3500000a, -0x8(%rdx) # imm = 0x3500000A
movl $0x0, 0x10(%rdx)
movl $0xa, %edi
movq %r14, %rsi
callq 0x3440
leaq 0x8(%rsp), %rsi
movl $0x10, %ecx
movq %rbx, %rdi
rep  movsq (%rsi), %es:(%rdi)
cmpl $0x1, %eax
sete %al
addq $0x88, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_cpp_makefile_star2_O1/davidgfnet[P]tadns/tadns.cc
// Function: DNSResolver::find_cached_query(dns_record_type, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
cache_entry* DNSResolver::find_cached_query(enum dns_record_type qtype, std::string name) {
    time_t now = time(NULL);
    auto entry = std::make_pair(name, qtype);
    if (cached.find(entry) != cached.end()) {
        auto r = &(cached.at(entry));
        r->hits++;
        if (r->expire > now)
            return r;
    }
    return (NULL);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x58, %rsp
movq %rdx, %r15
movl %esi, %ebp
movq %rdi, %r14
xorl %edi, %edi
callq 0x3260
movq %rax, %rbx
leaq 0x40(%rsp), %r13
movq %r13, -0x10(%r13)
movq (%r15), %rsi
movq 0x8(%r15), %rdx
addq %rsi, %rdx
leaq 0x30(%rsp), %r15
movq %r15, %rdi
callq 0x3c70
movl %ebp, 0x20(%r15)
leaq 0x18(%rsp), %rbp
movq %rbp, -0x10(%rbp)
movq (%r15), %rsi
movq 0x8(%r15), %rdx
addq %rsi, %rdx
leaq 0x8(%rsp), %rdi
callq 0x3c70
leaq 0xa0(%r14), %r15
movzwl 0x50(%rsp), %eax
leaq 0x8(%rsp), %rsi
movw %ax, 0x20(%rsi)
movq %r15, %rdi
callq 0x7c36
movq %rax, %r12
addq $0xa8, %r14
movq 0x8(%rsp), %rdi
cmpq %rbp, %rdi
je 0x475f
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x32b0
cmpq %r14, %r12
je 0x47b8
leaq 0x8(%rsp), %rdi
movq %rbp, (%rdi)
movq 0x30(%rsp), %rsi
movq 0x38(%rsp), %rdx
addq %rsi, %rdx
callq 0x3c70
movzwl 0x50(%rsp), %eax
leaq 0x8(%rsp), %rsi
movw %ax, 0x20(%rsi)
movq %r15, %rdi
callq 0x6f6e
movq %rax, %r14
movq 0x8(%rsp), %rdi
cmpq %rbp, %rdi
je 0x47ae
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x32b0
incl 0x20(%r14)
cmpq %rbx, 0x18(%r14)
jg 0x47bb
xorl %r14d, %r14d
movq 0x30(%rsp), %rdi
cmpq %r13, %rdi
je 0x47d2
movq 0x40(%rsp), %rsi
incq %rsi
callq 0x32b0
movq %r14, %rax
addq $0x58, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x47e8
jmp 0x4804
movq %rax, %rbx
movq 0x8(%rsp), %rdi
cmpq %rbp, %rdi
je 0x4807
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x32b0
jmp 0x4807
movq %rax, %rbx
movq 0x30(%rsp), %rdi
cmpq %r13, %rdi
je 0x481e
movq 0x40(%rsp), %rsi
incq %rsi
callq 0x32b0
movq %rbx, %rdi
callq 0x3400