LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O1/ksherlock[P]nroff_man/render.c
// Function: set_in_ti
void set_in_ti(int new_in, int new_ti) {
	int lm;
	prev_in = in;
	in = new_in;
	ti = new_ti;
	lm = new_ti >= 0 ? new_ti : new_in;
	width = ll - lm;
}

// Assembly:
leaq 0x6b9c(%rip), %rax      # 0xe36c
movl (%rax), %ecx
leaq 0x6b97(%rip), %rdx      # 0xe370
movl %ecx, (%rdx)
movl %edi, (%rax)
leaq 0x6b44(%rip), %rax      # 0xe328
movl %esi, (%rax)
testl %esi, %esi
cmovsl %edi, %esi
leaq 0x6b3a(%rip), %rax      # 0xe32c
movl (%rax), %eax
subl %esi, %eax
leaq 0x6b37(%rip), %rcx      # 0xe334
movl %eax, (%rcx)
retq
// File: /workspace/github_c_makefile_star2_O1/ksherlock[P]nroff_man/render.c
// Function: set_ll
void set_ll(int new_ll) {
	int lm;
	prev_ll = ll;
	ll = new_ll;
	lm = ti >= 0 ? ti : in;
	width = ll - lm;
}

// Assembly:
leaq 0x6b25(%rip), %rax      # 0xe32c
movl (%rax), %ecx
leaq 0x6b20(%rip), %rdx      # 0xe330
movl %ecx, (%rdx)
movl %edi, (%rax)
leaq 0x6b0d(%rip), %rax      # 0xe328
movl (%rax), %eax
testl %eax, %eax
jns 0x782a
leaq 0x6b44(%rip), %rax      # 0xe36c
movl (%rax), %eax
subl %eax, %edi
leaq 0x6b01(%rip), %rax      # 0xe334
movl %edi, (%rax)
retq
// File: /workspace/github_c_makefile_star2_O1/ksherlock[P]nroff_man/render.c
// Function: print
unsigned print(const unsigned char *cp, int fi) {
	unsigned i;
	uint_fast8_t prev = 0;
	unsigned length = 0;

	indent();
	for (i = 0; ;++i) {
		uint_fast8_t c = cp[i];
		if (c == 0) return length;
		switch(c) {
			case FONT_R: case FONT_B: case FONT_I: case FONT_P: case FONT_X:
				set_font(c);
				break;
			case HYPHEN: case ZWSPACE: break;
			case NBSPACE: case XSPACE: fputc(' ', stdout); length++; break;
			case ' ': case '\t':
				if (fi) {
					c = ' ';
					if (prev != ' ') { fputc(' ', stdout); length++; }
				} else {
					fputc(c, stdout); length++;
				}
				break;
			default: 
				if (flags.T == FMT_ASCII) {
					if (ft == FONT_B) {
						fputc(c, stdout);
						fputc(8, stdout);
					}
					if (ft == FONT_I) {
						fputs("_\x08", stdout);
					}
				}
				fputc(c, stdout); length++;
				break;
		}
		prev = c;
	}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %esi, 0x4(%rsp)
movq %rdi, %r14
callq 0x797e
xorl %r13d, %r13d
xorl %eax, %eax
xorl %ebp, %ebp
movl %r13d, %ecx
movzbl (%r14,%rcx), %r12d
testl %r12d, %r12d
je 0x7882
leal -0x80(%r12), %ecx
cmpl $0x8, %ecx
ja 0x78ae
movl $0xf8, %eax
btl %ecx, %eax
jae 0x788c
movl %r12d, %edi
callq 0x761c
jmp 0x795b
movl %ebp, %r15d
movl %eax, %ebx
jmp 0x795e
movl $0x3, %eax
btl %ecx, %eax
jae 0x795b
movq 0x671f(%rip), %rax      # 0xdfc0
movq (%rax), %rsi
movl $0x20, %edi
jmp 0x7954
cmpl $0x9, %r12d
je 0x78ba
cmpl $0x20, %r12d
jne 0x78e7
cmpl $0x0, 0x4(%rsp)
je 0x7947
movb $0x20, %bl
cmpb $0x20, %al
je 0x795e
movq 0x66ea(%rip), %rax      # 0xdfc0
movq (%rax), %rsi
movl $0x20, %edi
callq 0x40e0
incl %ebp
jmp 0x795e
leaq 0x6a8a(%rip), %rax      # 0xe378
cmpl $0x1, 0x20(%rax)
jne 0x7947
leaq 0x6a25(%rip), %rax      # 0xe320
cmpl $0x84, (%rax)
jne 0x7922
movq 0x66b6(%rip), %rbx      # 0xdfc0
movq (%rbx), %rsi
movl %r12d, %edi
callq 0x40e0
movq (%rbx), %rsi
movl $0x8, %edi
callq 0x40e0
leaq 0x69f7(%rip), %rax      # 0xe320
cmpl $0x85, (%rax)
jne 0x7947
movq 0x6688(%rip), %rax      # 0xdfc0
movq (%rax), %rsi
leaq 0x24fe(%rip), %rdi      # 0x9e40
callq 0x40c0
movq 0x6672(%rip), %rax      # 0xdfc0
movq (%rax), %rsi
movl %r12d, %edi
callq 0x40e0
incl %ebp
movl %r12d, %ebx
incl %r13d
movl %ebx, %eax
testb %r12b, %r12b
jne 0x7854
movl %r15d, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/ksherlock[P]nroff_man/render.c
// Function: indent
static void indent(void) {
	int i, amt;

	if (ti >= 0) {
		amt = ti;
		ti = -1;
		width = ll - in;
	} else {
		amt = in;
	}

	if (!amt) return;

	switch(ft) {
		case FONT_B: _(bold_end);
		case FONT_I: _(italic_end);
	}
	for (i = 0; i < amt; ++i) fputc(' ', stdout);
	switch(ft) {
		case FONT_B: _(bold_begin);
		case FONT_I: _(italic_begin);
	}
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
leaq 0x699e(%rip), %rax      # 0xe328
movl (%rax), %ebx
testl %ebx, %ebx
js 0x79b3
movl $0xffffffff, (%rax)     # imm = 0xFFFFFFFF
leaq 0x698f(%rip), %rax      # 0xe32c
movl (%rax), %eax
leaq 0x69c6(%rip), %rcx      # 0xe36c
subl (%rcx), %eax
leaq 0x6985(%rip), %rcx      # 0xe334
movl %eax, (%rcx)
jmp 0x79bc
leaq 0x69b2(%rip), %rax      # 0xe36c
movl (%rax), %ebx
testl %ebx, %ebx
je 0x7a76
leaq 0x6955(%rip), %r14      # 0xe320
movl (%r14), %eax
cmpl $0x85, %eax
je 0x79e5
cmpl $0x84, %eax
jne 0x7a10
leaq 0x82b5(%rip), %rax      # 0xfc98
jmp 0x79ec
leaq 0x82bc(%rip), %rax      # 0xfca8
movq (%rax), %rdi
testq %rdi, %rdi
je 0x7a10
leaq 0x697d(%rip), %rax      # 0xe378
cmpl $0x0, 0x20(%rax)
jne 0x7a10
movq 0x65b8(%rip), %rax      # 0xdfc0
movq (%rax), %rsi
callq 0x40c0
testl %ebx, %ebx
jle 0x7a2c
movq 0x65a5(%rip), %r15      # 0xdfc0
movq (%r15), %rsi
movl $0x20, %edi
callq 0x40e0
decl %ebx
jne 0x7a1b
movl (%r14), %eax
cmpl $0x85, %eax
je 0x7a46
cmpl $0x84, %eax
jne 0x7a76
leaq 0x824c(%rip), %rax      # 0xfc90
jmp 0x7a4d
leaq 0x8253(%rip), %rax      # 0xfca0
movq (%rax), %rdi
testq %rdi, %rdi
je 0x7a76
leaq 0x691c(%rip), %rax      # 0xe378
cmpl $0x0, 0x20(%rax)
jne 0x7a76
movq 0x6557(%rip), %rax      # 0xdfc0
movq (%rax), %rsi
popq %rbx
popq %r14
popq %r15
jmp 0x40c0
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/ksherlock[P]nroff_man/render.c
// Function: xstrlen
unsigned xstrlen(const unsigned char *cp) {
	unsigned length = 0;
	unsigned i;
	for (i = 0; ; ++i) {
		uint_fast8_t c = cp[i];
		if (!c) return length;
		if (c <= NBSPACE) length++;
	}
}

// Assembly:
movb (%rdi), %dl
xorl %eax, %eax
testb %dl, %dl
je 0x7a9f
movl $0x1, %ecx
xorl %esi, %esi
cmpb $-0x7f, %dl
adcl $0x0, %esi
movl %ecx, %edx
movb (%rdi,%rdx), %dl
incl %ecx
testb %dl, %dl
cmovel %esi, %eax
jne 0x7a8b
retq
// File: /workspace/github_c_makefile_star2_O1/ksherlock[P]nroff_man/render.c
// Function: xstrnlen
unsigned xstrnlen(const unsigned char *cp, unsigned max) {

	unsigned length = 0;
	unsigned i;
	for (i = 0; i < max; ++i) {
		uint_fast8_t c = cp[i];
		if (!c) return length;
		if (c <= NBSPACE) length++;
	}
	return length;
}

// Assembly:
testl %esi, %esi
je 0x7ac5
movl %esi, %ecx
xorl %edx, %edx
xorl %eax, %eax
movb (%rdi,%rdx), %r8b
testb %r8b, %r8b
cmovel %eax, %esi
je 0x7ac8
cmpb $-0x7f, %r8b
adcl $0x0, %eax
incq %rdx
cmpl %edx, %ecx
jne 0x7aaa
retq
xorl %eax, %eax
retq
movl %esi, %eax
retq
// File: /workspace/github_c_makefile_star2_O1/ksherlock[P]nroff_man/render.c
// Function: append_font
void append_font(unsigned font) {
	/* todo - check if buffer is overflowing */

	/* if there is trailing WS, this inserts a FONT_X token before the whitespace. */
	unsigned k;
	unsigned xfont = 0;

	k = buffer_offset;
	if (k == 0) {
		buffer[0] = font;
		buffer_offset++;
		return;
	}

	while (k > 0) {
		uint_fast8_t c = buffer[--k];
		if (c == ' ' || c == XSPACE) {
			buffer[k+1] = c;
			xfont = 1;
		} else break;
	}
	if (xfont) {
		buffer[k+1] = FONT_X;
		++buffer_offset;
	}
	buffer[buffer_offset++] = font;
}

// Assembly:
movl 0x8ee7(%rip), %ecx      # 0x109b8
testq %rcx, %rcx
je 0x7b1a
leaq 0x1(%rcx), %rdx
xorl %esi, %esi
leaq 0x8edd(%rip), %rax      # 0x109c0
cmpq $0x1, %rdx
je 0x7b2c
movzbl -0x2(%rdx,%rax), %r8d
cmpl $0x81, %r8d
je 0x7afe
cmpl $0x20, %r8d
jne 0x7b0d
movb %r8b, -0x1(%rdx,%rax)
movb $0x1, %r8b
movl $0x1, %esi
jmp 0x7b10
xorl %r8d, %r8d
decq %rdx
testb %r8b, %r8b
jne 0x7ae3
jmp 0x7b31
movb %dil, 0x8e9f(%rip)      # 0x109c0
movl $0x1, 0x8e8d(%rip)      # 0x109b8
retq
movl $0x1, %edx
testl %esi, %esi
je 0x7b43
movl %edx, %edx
movb $-0x79, (%rdx,%rax)
incl %ecx
movl %ecx, 0x8e75(%rip)      # 0x109b8
movl 0x8e6f(%rip), %ecx      # 0x109b8
leal 0x1(%rcx), %edx
movl %edx, 0x8e66(%rip)      # 0x109b8
movb %dil, (%rcx,%rax)
retq
// File: /workspace/github_c_makefile_star2_O1/ksherlock[P]nroff_man/render.c
// Function: set_tag
void set_tag(const unsigned char *cp, unsigned IP) {
	/* set the tag for IP/TP */
	unsigned n;

	/* assumes buffer has been flushed */
	/* set_in_ti(LM + IP, LM); */

	n = xstrlen(cp);
	if (n >= width || n >= IP) { 
		append(cp);
		flush(0);
	} else {
		uint_fast8_t c;
		unsigned i;
		for (i = 0; ; ++i) {
			c = cp[i];
			if (c == 0) break;
			if (c == ' ' || c == '\t') c = NBSPACE;
			buffer[buffer_offset++] = c;
			if (c <= NBSPACE) buffer_width++;
		}
		buffer[buffer_offset] = 0;

		while(buffer_width < IP) {
			buffer[buffer_offset++] = NBSPACE;
			buffer_width++;
		}
		buffer[buffer_offset] = 0;
	}
}

// Assembly:
pushq %rbx
movb (%rdi), %dl
xorl %eax, %eax
testb %dl, %dl
je 0x8163
movl $0x1, %ecx
xorl %r8d, %r8d
cmpb $-0x7f, %dl
adcl $0x0, %r8d
movl %ecx, %edx
movb (%rdi,%rdx), %dl
incl %ecx
testb %dl, %dl
cmovel %r8d, %eax
jne 0x814d
cmpl %esi, %eax
jae 0x8228
leaq 0x61c2(%rip), %rcx      # 0xe334
cmpl (%rcx), %eax
jae 0x8228
movb (%rdi), %r10b
testb %r10b, %r10b
je 0x81e7
movl 0x882c(%rip), %edx      # 0x109b4
movl $0x1, %eax
movl 0x8825(%rip), %ecx      # 0x109b8
movl $0x80, %r8d
leaq 0x8820(%rip), %r9       # 0x109c0
leal (%rcx,%rax), %r11d
decl %r11d
cmpb $0x9, %r10b
movzbl %r10b, %r10d
movl %r10d, %ebx
cmovel %r8d, %ebx
cmpb $0x20, %r10b
cmovel %r8d, %ebx
movb %bl, (%r11,%r9)
cmpb $-0x80, %bl
ja 0x81cf
incl %edx
movl %edx, 0x87e5(%rip)      # 0x109b4
movl %eax, %r10d
movb (%rdi,%r10), %r10b
incl %eax
testb %r10b, %r10b
jne 0x81a0
addl %ecx, %eax
decl %eax
movl %eax, 0x87d1(%rip)      # 0x109b8
movl 0x87cb(%rip), %ecx      # 0x109b8
leaq 0x87cc(%rip), %rax      # 0x109c0
movb $0x0, (%rcx,%rax)
movl 0x87b6(%rip), %edx      # 0x109b4
cmpl %esi, %edx
jae 0x821c
movl %ecx, %edi
incl %ecx
movb $-0x80, (%rdi,%rax)
incl %edx
cmpl %edx, %esi
jne 0x8202
movl %ecx, 0x87a2(%rip)      # 0x109b8
movl %esi, 0x8798(%rip)      # 0x109b4
movl 0x8796(%rip), %ecx      # 0x109b8
movb $0x0, (%rcx,%rax)
popq %rbx
retq
callq 0x7b57
xorl %edi, %edi
popq %rbx
jmp 0x7e72
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O1/ksherlock[P]nroff_man/tbl.c
// Function: num_width
unsigned num_width(const char *cp, unsigned n, int *offset) {

	int zwsp = -1;
	int dig = -1;
	int dot = -1;
	unsigned l = 0;
	int st = 0;
	for (unsigned i = 0; i < n; ++i) {
		unsigned c = cp[i];
		if (c == ZWSPACE && zwsp < 0) zwsp = l+1;
		if (c > XSPACE) continue;
		++l;

		st <<= 2;
		if (c == '.') st |= 0b01;
		else if (isdigit(c)) {
			dig = l+1;
			st |= 0b11;
		}
		st &= 0b1111;
		if (st == 0b1101) dot = l;
		if (st == 0b0111) dot = l-1;
	}
	if (dot < 0) dot = dig;
	if (zwsp >= 0) dot = zwsp;
	*offset = dot;
	return l;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rdx, 0x10(%rsp)
testl %esi, %esi
je 0x82ce
movq %rdi, %r13
movl %esi, %ecx
movl $0xffffffff, %ebp       # imm = 0xFFFFFFFF
xorl %ebx, %ebx
xorl %r12d, %r12d
xorl %r15d, %r15d
movl $0xffffffff, 0x4(%rsp)  # imm = 0xFFFFFFFF
movq %rcx, 0x8(%rsp)
movsbq (%r13,%rbx), %r14
testq %r14, %r14
js 0x82c4
shll $0x2, %r12d
cmpb $0x2e, %r14b
jne 0x8289
orl $0x1, %r12d
jmp 0x82aa
callq 0x41d0
movq (%rax), %rax
testb $0x8, 0x1(%rax,%r14,2)
je 0x82a5
leal 0x2(%r15), %eax
movl %eax, 0x4(%rsp)
orl $0x3, %r12d
movq 0x8(%rsp), %rcx
leal 0x1(%r15), %eax
andl $0xf, %r12d
cmpl $0xd, %r12d
cmovel %eax, %ebp
cmpl $0x7, %r12d
cmovel %r15d, %ebp
movl %eax, %r15d
incq %rbx
cmpq %rbx, %rcx
jne 0x826e
jmp 0x82de
xorl %r15d, %r15d
movl $0xffffffff, 0x4(%rsp)  # imm = 0xFFFFFFFF
movl $0xffffffff, %ebp       # imm = 0xFFFFFFFF
testl %ebp, %ebp
movl 0x4(%rsp), %ecx
cmovnsl %ebp, %ecx
movq 0x10(%rsp), %rax
movl %ecx, (%rax)
movl %r15d, %eax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/liuhaotian[P]xmppsh/libstrophe/examples/basic.c
// Function: main
int main(int argc, char **argv)
{
    xmpp_ctx_t *ctx;
    xmpp_conn_t *conn;
    xmpp_log_t *log;
    char *jid, *pass, *host;

    /* take a jid and password on the command line */
    if (argc < 3 || argc > 4) {
        fprintf(stderr, "Usage: basic <jid> <pass> [<host>]\n\n");
        return 1;
    }

    jid = argv[1];
    pass = argv[2];
    host = NULL;

    if (argc == 4)
        host = argv[3];

    /* init library */
    xmpp_initialize();

    /* create a context */
    log = xmpp_get_default_logger(XMPP_LEVEL_DEBUG); /* pass NULL instead to silence output */
    ctx = xmpp_ctx_new(NULL, log);

    /* create a connection */
    conn = xmpp_conn_new(ctx);

    /* setup authentication information */
    xmpp_conn_set_jid(conn, jid);
    xmpp_conn_set_pass(conn, pass);

    /* initiate connection */
    xmpp_connect_client(conn, host, 0, conn_handler, ctx);

    /* enter the event loop -
       our connect handler will trigger an exit */
    xmpp_run(ctx);

    /* release our connection and context */
    xmpp_conn_release(conn);
    xmpp_ctx_free(ctx);

    /* final shutdown of the library */
    xmpp_shutdown();

    return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
leal -0x5(%rdi), %eax
cmpl $-0x3, %eax
jbe 0x25a0
movq 0x8(%rsi), %r12
movq 0x10(%rsi), %r14
xorl %ebx, %ebx
cmpl $0x4, %edi
jne 0x251e
movq 0x18(%rsi), %r15
jmp 0x2521
xorl %r15d, %r15d
callq 0x48ac
xorl %edi, %edi
callq 0x4904
xorl %edi, %edi
movq %rax, %rsi
callq 0x4c6d
movq %rax, %r13
movq %rax, %rdi
callq 0x3c90
movq %rax, %rbp
movq %rax, %rdi
movq %r12, %rsi
callq 0x42c0
movq %rbp, %rdi
movq %r14, %rsi
callq 0x42fc
leaq -0x96(%rip), %rcx       # 0x24cc
movq %rbp, %rdi
movq %r15, %rsi
xorl %edx, %edx
movq %r13, %r8
callq 0x433b
movq %r13, %rdi
callq 0x52ac
movq %rbp, %rdi
callq 0x4092
movq %r13, %rdi
callq 0x4cd6
callq 0x48b8
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
callq 0x23c4
movl $0x1, %ebx
jmp 0x258f
// File: /workspace/github_c_makefile_star2_O1/mjosaarinen[P]brutus/crypto_aead/acorn128v2/ref/encrypt.c
// Function: Encrypt_StateUpdate128_1bit
void Encrypt_StateUpdate128_1bit(unsigned char *state, unsigned char plaintextbit, unsigned char *ciphertextbit, unsigned char *ks, unsigned char ca, unsigned char cb)
{
    unsigned int  j;
    unsigned char f;

    state[289] ^= state[235] ^ state[230];
    state[230] ^= state[196] ^ state[193];
    state[193] ^= state[160] ^ state[154];
    state[154] ^= state[111] ^ state[107];
    state[107] ^= state[66]  ^ state[61];
    state[61]  ^= state[23]  ^ state[0];

    f  = FBK128(state, ks, ca, cb);

    for (j = 0; j <= 291; j++) state[j] = state[j+1];
    state[292] = f ^ plaintextbit;
    *ciphertextbit = *ks ^ plaintextbit;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rcx, %r14
movq %rdx, %rbx
movl %esi, %ebp
movq %rdi, %r15
movb 0xeb(%rdi), %al
movb 0xe6(%rdi), %cl
xorb 0x121(%rdi), %al
xorb %cl, %al
movb %al, 0x121(%rdi)
movb 0xc1(%rdi), %al
xorb 0xc4(%rdi), %cl
xorb %al, %cl
movb %cl, 0xe6(%rdi)
xorb 0xa0(%rdi), %al
movb 0x9a(%rdi), %cl
xorb %cl, %al
movb %al, 0xc1(%rdi)
movb 0x6b(%rdi), %al
xorb 0x6f(%rdi), %cl
xorb %al, %cl
movb %cl, 0x9a(%rdi)
movb 0x17(%rdi), %cl
movb 0x3d(%rdi), %dl
xorb 0x42(%rdi), %al
xorb %dl, %al
movb %al, 0x6b(%rdi)
xorb (%rdi), %cl
xorb %dl, %cl
movb %cl, 0x3d(%rdi)
movq %r14, %rsi
movl %r8d, %edx
movl %r9d, %ecx
callq 0x1080
movl %eax, %r12d
leaq 0x1(%r15), %rsi
movl $0x124, %edx            # imm = 0x124
movq %r15, %rdi
callq 0x1070
xorb %bpl, %r12b
movb %r12b, 0x124(%r15)
xorb (%r14), %bpl
movb %bpl, (%rbx)
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/mjosaarinen[P]brutus/crypto_aead/acorn128v2/ref/encrypt.c
// Function: Decrypt_StateUpdate128_1bit
void Decrypt_StateUpdate128_1bit(unsigned char *state, unsigned char *plaintextbit, unsigned char ciphertextbit, unsigned char *ks, unsigned char ca, unsigned char cb)
{
    unsigned int  j;
    unsigned char f;

    state[289] ^= state[235] ^ state[230];
    state[230] ^= state[196] ^ state[193];
    state[193] ^= state[160] ^ state[154];
    state[154] ^= state[111] ^ state[107];
    state[107] ^= state[66]  ^ state[61];
    state[61]  ^= state[23]  ^ state[0];

    f = FBK128(state, ks, ca, cb);

    for (j = 0; j <= 291; j++) state[j] = state[j+1];
    *plaintextbit = *ks ^ ciphertextbit;
    state[292] = f ^ *plaintextbit;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rcx, %r15
movl %edx, %ebx
movq %rsi, %r12
movq %rdi, %r14
movb 0xeb(%rdi), %al
movb 0xe6(%rdi), %cl
xorb 0x121(%rdi), %al
xorb %cl, %al
movb %al, 0x121(%rdi)
movb 0xc1(%rdi), %al
xorb 0xc4(%rdi), %cl
xorb %al, %cl
movb %cl, 0xe6(%rdi)
xorb 0xa0(%rdi), %al
movb 0x9a(%rdi), %cl
xorb %cl, %al
movb %al, 0xc1(%rdi)
movb 0x6b(%rdi), %al
xorb 0x6f(%rdi), %cl
xorb %al, %cl
movb %cl, 0x9a(%rdi)
movb 0x17(%rdi), %cl
movb 0x3d(%rdi), %dl
xorb 0x42(%rdi), %al
xorb %dl, %al
movb %al, 0x6b(%rdi)
xorb (%rdi), %cl
xorb %dl, %cl
movb %cl, 0x3d(%rdi)
movq %r15, %rsi
movl %r8d, %edx
movl %r9d, %ecx
callq 0x1080
movl %eax, %ebp
leaq 0x1(%r14), %rsi
movl $0x124, %edx            # imm = 0x124
movq %r14, %rdi
callq 0x1070
xorb (%r15), %bl
movb %bl, (%r12)
xorb %bpl, %bl
movb %bl, 0x124(%r14)
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/mjosaarinen[P]brutus/crypto_aead/acorn128v2/ref/encrypt.c
// Function: acorn128_enc_onebyte
void acorn128_enc_onebyte(unsigned char *state, unsigned char plaintextbyte,
       unsigned char *ciphertextbyte, unsigned char *ksbyte, unsigned char cabyte, unsigned char cbbyte)
{
    unsigned char i,t[4];
    unsigned char plaintextbit,ciphertextbit,kstem,ca,cb;

    *ciphertextbyte = 0;
    kstem = 0;
    *ksbyte = 0;
    for (i = 0; i < 8; i++)
    {
        ca = (cabyte >> i) & 1;
        cb = (cbbyte >> i) & 1;
        plaintextbit = (plaintextbyte >> i) & 1;
        Encrypt_StateUpdate128_1bit(state, plaintextbit, &ciphertextbit, &kstem, ca, cb);
        *ciphertextbyte |= (ciphertextbit << i);
        *ksbyte |= (kstem << i);
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %r9d, 0x4(%rsp)
movl %r8d, %ebp
movq %rcx, %r14
movq %rdx, %r15
movl %esi, %r12d
movq %rdi, %r13
xorl %ebx, %ebx
movb %bl, (%rdx)
leaq 0x2(%rsp), %rax
movb %bl, (%rax)
movb %bl, (%rcx)
shrxl %ebx, %ebp, %r8d
shrxl %ebx, 0x4(%rsp), %r9d
shrxl %ebx, %r12d, %esi
andl $0x1, %esi
andl $0x1, %r8d
andl $0x1, %r9d
movq %r13, %rdi
leaq 0x3(%rsp), %rdx
leaq 0x2(%rsp), %rcx
callq 0x10b0
movzbl 0x3(%rsp), %eax
shlxl %ebx, %eax, %eax
orb %al, (%r15)
movzbl 0x2(%rsp), %eax
shlxl %ebx, %eax, %eax
orb %al, (%r14)
incl %ebx
cmpl $0x8, %ebx
jne 0x1406
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/mjosaarinen[P]brutus/crypto_aead/acorn128v2/ref/encrypt.c
// Function: acorn128_dec_onebyte
void acorn128_dec_onebyte(unsigned char *state, unsigned char *plaintextbyte,
       unsigned char ciphertextbyte, unsigned char *ksbyte, unsigned char cabyte, unsigned char cbbyte)
{
    unsigned char i;
    unsigned char plaintextbit,ciphertextbit, ks,ca,cb;

    *plaintextbyte = 0;
    for  (i = 0; i < 8; i++)
    {
        ca = (cabyte >> i) & 1;
        cb = (cbbyte >> i) & 1;
        ciphertextbit = (ciphertextbyte >> i) & 1;
        Decrypt_StateUpdate128_1bit(state, &plaintextbit, ciphertextbit, &ks, ca, cb);
        *plaintextbyte |= (plaintextbit << i);
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %r9d, %ebx
movl %r8d, %ebp
movl %edx, %r14d
movq %rsi, %r15
movq %rdi, %r12
movb $0x0, (%rsi)
xorl %r13d, %r13d
shrxl %r13d, %ebp, %r8d
shrxl %r13d, %ebx, %r9d
shrxl %r13d, %r14d, %edx
andl $0x1, %edx
andl $0x1, %r8d
andl $0x1, %r9d
movq %r12, %rdi
leaq 0x6(%rsp), %rsi
leaq 0x7(%rsp), %rcx
callq 0x1090
movzbl 0x6(%rsp), %eax
shlxl %r13d, %eax, %eax
orb %al, (%r15)
incl %r13d
cmpl $0x8, %r13d
jne 0x1484
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/mjosaarinen[P]brutus/crypto_aead/acorn128v2/ref/encrypt.c
// Function: acorn128_initialization
void acorn128_initialization(const unsigned char *key, const unsigned char *iv, unsigned char *state)
{
        int i,j;
        unsigned char m[293], ks, tem;

        //initialize the state to 0
        for (j = 0; j <= 292; j++) state[j] = 0;

        //set the value of m
        for (j = 0; j <=  15;   j++)   m[j] = key[j];
        for (j = 16; j <= 31;   j++)   m[j] = iv[j - 16];
        for (j = 32; j <= 223;  j++)   m[j] = key[j & 0xf];
        m[32] ^= 1;

        //run the cipher for 1792 steps
        for (i = 0; i < 224; i++)
        {
             acorn128_enc_onebyte(state, m[i], &tem, &ks, 0xff, 0xff);
        }
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x138, %rsp            # imm = 0x138
movq %rdx, %rbx
movq %rsi, %r15
movq %rdi, %r14
movl $0x125, %edx            # imm = 0x125
movq %rbx, %rdi
xorl %esi, %esi
callq 0x1030
vmovups (%r14), %xmm0
vmovaps %xmm0, 0x10(%rsp)
vmovups (%r15), %xmm0
vmovaps %xmm0, 0x20(%rsp)
movl $0x20, %eax
movl %eax, %ecx
andl $0xf, %ecx
movb (%r14,%rcx), %cl
movb %cl, 0x10(%rsp,%rax)
incq %rax
cmpq $0xe0, %rax
jne 0x1516
xorb $0x1, 0x30(%rsp)
xorl %r12d, %r12d
leaq 0xe(%rsp), %r14
leaq 0xf(%rsp), %r15
movzbl 0x10(%rsp,%r12), %esi
movq %rbx, %rdi
movq %r14, %rdx
movq %r15, %rcx
movl $0xff, %r8d
movl $0xff, %r9d
callq 0x10e0
incq %r12
cmpq $0xe0, %r12
jne 0x1540
addq $0x138, %rsp            # imm = 0x138
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/mjosaarinen[P]brutus/crypto_aead/acorn128v2/ref/encrypt.c
// Function: acorn128_tag_generation
void acorn128_tag_generation(unsigned long long msglen, unsigned long long adlen, unsigned char maclen, unsigned char *mac, unsigned char *state)
{
    int i;
    unsigned char plaintextbyte  = 0;
    unsigned char ciphertextbyte = 0;
    unsigned char ksbyte = 0;

    for (i = 0; i < 768/8; i++)
    {
        acorn128_enc_onebyte(state, plaintextbyte, &ciphertextbyte, &ksbyte, 0xff, 0xff);
        if ( i >= (768/8 - 16) ) {mac[i-(768/8-16)] = ksbyte; }
    }
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x10, %rsp
movq %r8, %rbx
movq %rcx, %r14
xorl %r13d, %r13d
leaq 0xf(%rsp), %r15
movb %r13b, (%r15)
leaq 0xe(%rsp), %r12
movb %r13b, (%r12)
movq %rbx, %rdi
xorl %esi, %esi
movq %r15, %rdx
movq %r12, %rcx
movl $0xff, %r8d
movl $0xff, %r9d
callq 0x10e0
cmpq $0x50, %r13
jb 0x15cd
movb 0xe(%rsp), %al
movb %al, -0x50(%r14,%r13)
incq %r13
cmpq $0x60, %r13
jne 0x15a2
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/buptlxb[P]xRay/src/binary.cpp
// Function: BinInfo::dumpFunc()
void BinInfo::dumpFunc()
{
    fprintf(stderr, "%-18s\t%-16s\t%-16s\t%-16s\t\n", "[Function Name]", "[Virtual Addr]", "[Map Start]", "[Map End]");
    char buf[128];
    for (FunctionIter iter = funcInfo.begin(); iter != funcInfo.end(); iter++) {
        fprintf(stderr, "%s\n", iter->toString(buf, sizeof(buf)));
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x88, %rsp
movq %rdi, %rbx
movq 0x2fc5f(%rip), %rbp     # 0x37fd0
movq (%rbp), %rdi
leaq 0x24eb9(%rip), %rsi     # 0x2d235
leaq 0x24ecc(%rip), %rdx     # 0x2d24f
leaq 0x24ed5(%rip), %rcx     # 0x2d25f
leaq 0x24edd(%rip), %r8      # 0x2d26e
leaq 0x24ee2(%rip), %r9      # 0x2d27a
xorl %eax, %eax
callq 0x81f0
movq 0x38(%rbx), %r14
cmpq 0x40(%rbx), %r14
je 0x83e4
movq %rsp, %r15
leaq 0x24d66(%rip), %r12     # 0x2d119
movq (%rbp), %r13
movq %r14, %rdi
movq %r15, %rsi
movl $0x80, %edx
callq 0x9aba
movq %r13, %rdi
movq %r12, %rsi
movq %rax, %rdx
xorl %eax, %eax
callq 0x81f0
addq $0x268, %r14            # imm = 0x268
cmpq 0x40(%rbx), %r14
jne 0x83b3
addq $0x88, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/buptlxb[P]xRay/src/basic_block.cpp
// Function: BasicBlock::BasicBlock(unsigned long long, unsigned long long, Function*)
BasicBlock::BasicBlock(ADDR eip, ADDR vAddr, Function *func):
    hashNext(NULL), func(func), disasmed(false), disasm_pending(false)
    , visited(false)
{
    DISASM MyDisasm;
    memset(&MyDisasm, 0, sizeof(DISASM));
    MyDisasm.EIP = eip;
    MyDisasm.VirtualAddr = vAddr;
    MyDisasm.Archi = 64;
    MyDisasm.Options = ATSyntax|PrefixedNumeral|Tabulation;
    insts.push_back(MyDisasm);
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x298, %rsp            # imm = 0x298
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbx
xorps %xmm0, %xmm0
movups %xmm0, 0x40(%rdi)
movups %xmm0, 0x30(%rdi)
movups %xmm0, 0x20(%rdi)
movups %xmm0, 0x10(%rdi)
movups %xmm0, (%rdi)
movq %rcx, 0x50(%rdi)
movw $0x0, 0x58(%rdi)
movb $0x0, 0x5a(%rdi)
leaq 0x8(%rsp), %r12
movl $0x28d, %edx            # imm = 0x28D
movq %r12, %rdi
xorl %esi, %esi
callq 0x80c0
movq %r15, (%r12)
movq %r14, 0x8(%r12)
movl $0x40, 0x54(%r12)
movq $0x10401, 0x58(%r12)    # imm = 0x10401
movq 0x8(%rbx), %rax
cmpq 0x10(%rbx), %rax
je 0x867c
leaq 0x8(%rsp), %rsi
movl $0x28d, %edx            # imm = 0x28D
movq %rax, %rdi
callq 0x8120
addq $0x28d, 0x8(%rbx)       # imm = 0x28D
jmp 0x8694
leaq 0x18(%rbx), %r15
leaq 0x10(%rbx), %r14
leaq 0x8(%rsp), %rdx
movq %rbx, %rdi
movq %rax, %rsi
callq 0x8b7c
addq $0x298, %rsp            # imm = 0x298
popq %rbx
popq %r12
popq %r14
popq %r15
retq
movq %rax, %r12
movq 0x30(%rbx), %rdi
testq %rdi, %rdi
je 0x86bb
movq 0x40(%rbx), %rsi
subq %rdi, %rsi
callq 0x8170
movq %r15, %rdi
movq %rbx, %rsi
movq %r14, %rdx
callq 0x82d0
movq %r12, %rdi
callq 0x8270
nop
// File: /workspace/github_c_makefile_star2_O1/buptlxb[P]xRay/src/basic_block.cpp
// Function: BasicBlock::toString(char*, int) const
char *BasicBlock::toString(char *buf, int size) const
{
    snprintf(buf, size, "\t\t\t0x%llx(0x%llx) %ld instructions", (ADDR)this, getFirstInstAddr(), insts.size());

    if (!successors.empty()) {
        snprintf(buf+strlen(buf), size-strlen(buf), "\n\t\t\tsucc{");
        for (ConstBBPtrIter iter = successors.begin(); iter != successors.end(); iter++) {
            snprintf(buf+strlen(buf), size-strlen(buf), "0x%llx(0x%llx), ", (ADDR)(*iter), (*iter)->getFirstInstAddr());
        }
        snprintf(buf+strlen(buf)-2, size-strlen(buf)+2, "}");
    }

    if (!predecessors.empty()) {
        snprintf(buf+strlen(buf), size-strlen(buf), "\n\t\t\tpred{");
        for (ConstBBPtrIter iter = predecessors.begin(); iter != predecessors.end(); iter++) {
            snprintf(buf+strlen(buf), size-strlen(buf), "0x%llx(0x%llx), ", (ADDR)(*iter), (*iter)->getFirstInstAddr());
        }
        snprintf(buf+strlen(buf)-2, size-strlen(buf)+2, "}");
    }
    return buf;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rsi, %rbx
movq %rdi, %r15
movslq %edx, %r14
movq (%rdi), %rax
movq 0x8(%rdi), %rcx
movq 0x8(%rax), %r8
subq %rax, %rcx
movabsq $-0x5e16bcf632f6fbb, %r9 # imm = 0xFA1E94309CD09045
imulq %rcx, %r9
leaq 0x24775(%rip), %rdx     # 0x2d0c4
movq %rsi, %rdi
movq %r14, %rsi
movq %r15, %rcx
xorl %eax, %eax
callq 0x8230
movq 0x18(%r15), %rax
cmpq 0x20(%r15), %rax
je 0x89f7
movq %rbx, %rdi
callq 0x8090
leaq (%rbx,%rax), %rdi
movq %r14, %rsi
subq %rax, %rsi
leaq 0x24761(%rip), %rdx     # 0x2d0e7
xorl %eax, %eax
callq 0x8230
movq 0x18(%r15), %r13
cmpq 0x20(%r15), %r13
je 0x89cf
leaq 0x24753(%rip), %r12     # 0x2d0f1
movq %rbx, %rdi
callq 0x8090
leaq (%rbx,%rax), %rdi
movq %r14, %rsi
subq %rax, %rsi
movq (%r13), %rcx
movq (%rcx), %rax
movq 0x8(%rax), %r8
movq %r12, %rdx
xorl %eax, %eax
callq 0x8230
addq $0x8, %r13
cmpq 0x20(%r15), %r13
jne 0x899e
movq %rbx, %rdi
callq 0x8090
leaq (%rbx,%rax), %rdi
addq $-0x2, %rdi
movq %r14, %rsi
subq %rax, %rsi
addq $0x2, %rsi
leaq 0x24712(%rip), %rdx     # 0x2d102
xorl %eax, %eax
callq 0x8230
movq 0x30(%r15), %rax
cmpq 0x38(%r15), %rax
je 0x8a8f
movq %rbx, %rdi
callq 0x8090
leaq (%rbx,%rax), %rdi
movq %r14, %rsi
subq %rax, %rsi
leaq 0x246e6(%rip), %rdx     # 0x2d104
xorl %eax, %eax
callq 0x8230
movq 0x30(%r15), %r13
cmpq 0x38(%r15), %r13
je 0x8a67
leaq 0x246bb(%rip), %r12     # 0x2d0f1
movq %rbx, %rdi
callq 0x8090
leaq (%rbx,%rax), %rdi
movq %r14, %rsi
subq %rax, %rsi
movq (%r13), %rcx
movq (%rcx), %rax
movq 0x8(%rax), %r8
movq %r12, %rdx
xorl %eax, %eax
callq 0x8230
addq $0x8, %r13
cmpq 0x38(%r15), %r13
jne 0x8a36
movq %rbx, %rdi
callq 0x8090
leaq (%rbx,%rax), %rdi
addq $-0x2, %rdi
subq %rax, %r14
addq $0x2, %r14
leaq 0x2467d(%rip), %rdx     # 0x2d102
movq %r14, %rsi
xorl %eax, %eax
callq 0x8230
movq %rbx, %rax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/buptlxb[P]xRay/src/basic_block.cpp
// Function: BasicBlock::dump() const
void BasicBlock::dump() const
{
    dumpBiref();
    for (ConstDisasmIter iter = insts.begin(); iter != insts.end(); iter++) {
    printf("\t\t\t0x%.8lx\t%s\n", iter->VirtualAddr, (char *)&iter->CompleteInstr);
    }
    puts("");
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x400, %rsp            # imm = 0x400
movq %rdi, %rbx
movq %rsp, %r14
movq %r14, %rsi
movl $0x400, %edx            # imm = 0x400
callq 0x891a
movq %r14, %rdi
callq 0x8220
movq (%rbx), %r15
cmpq 0x8(%rbx), %r15
je 0x8b1c
leaq 0x24611(%rip), %r14     # 0x2d10e
movq 0x8(%r15), %rsi
leaq 0x14(%r15), %rdx
movq %r14, %rdi
xorl %eax, %eax
callq 0x8030
addq $0x28d, %r15            # imm = 0x28D
cmpq 0x8(%rbx), %r15
jne 0x8afd
movl $0xa, %edi
callq 0x81d0
addq $0x400, %rsp            # imm = 0x400
popq %rbx
popq %r14
popq %r15
retq
nop
// File: /workspace/github_c_makefile_star2_O1/buptlxb[P]xRay/src/function.cpp
// Function: Function::Function(Function const&)
Function::Function (const Function &func)
{
    this->mapStart = func.mapStart;
    this->mapEnd = func.mapEnd;
    this->virStart = func.virStart;
    this->funcName = strdup(func.funcName);
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
xorps %xmm0, %xmm0
movups %xmm0, 0x20(%rdi)
xorl %eax, %eax
movq %rax, 0x30(%rdi)
leaq 0x40(%rdi), %rcx
movl $0x0, 0x40(%rdi)
movq %rax, 0x48(%rdi)
movq %rcx, 0x50(%rdi)
movq %rcx, 0x58(%rdi)
movq %rax, 0x60(%rdi)
movq (%rsi), %rax
movq %rax, (%rdi)
movq 0x8(%rsi), %rax
movq %rax, 0x8(%rdi)
movq 0x10(%rsi), %rax
movq %rax, 0x10(%rdi)
movq 0x18(%rsi), %rdi
callq 0x82a0
movq %rax, 0x18(%rbx)
popq %rbx
retq
nop
// File: /workspace/github_c_makefile_star2_O1/buptlxb[P]xRay/src/function.cpp
// Function: Function::disasm()
void Function::disasm()
{
    //printf("\tStart Function::disasm %s\n", funcName);
    queue<BasicBlock *> que;
    BasicBlock *bb = findBasicBlock(mapStart);
    que.push(bb);
    bb->setDisasmPending(true);
    while (!que.empty()) {
        bb = que.front();
        bb->disasm();
        const vector<BasicBlock *> &succ = bb->getSuccessors();
        for (BasicBlock::ConstBBPtrIter iter = succ.begin(); iter != succ.end(); iter++) {
            if ((*iter)->isDisasmed() || (*iter)->isDisasmPending())
                continue;
            que.push(*iter);
            (*iter)->setDisasmPending(true);
        }
        que.pop();
        bb->setDisasmPending(false);
    }
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x60, %rsp
movq %rdi, %rbx
xorps %xmm0, %xmm0
leaq 0x10(%rsp), %rdi
movaps %xmm0, 0x40(%rdi)
movaps %xmm0, 0x30(%rdi)
movaps %xmm0, 0x20(%rdi)
movaps %xmm0, 0x10(%rdi)
movaps %xmm0, (%rdi)
xorl %esi, %esi
callq 0xa244
movq (%rbx), %rsi
movq %rbx, %rdi
callq 0x9ca4
movq %rax, 0x8(%rsp)
movq 0x40(%rsp), %rcx
movq 0x50(%rsp), %rdx
addq $-0x8, %rdx
cmpq %rdx, %rcx
je 0x9b84
movq %rax, (%rcx)
addq $0x8, 0x40(%rsp)
jmp 0x9b93
leaq 0x10(%rsp), %rdi
leaq 0x8(%rsp), %rsi
callq 0xa3ba
movq 0x8(%rsp), %rax
movb $0x1, 0x59(%rax)
movq 0x20(%rsp), %rax
cmpq %rax, 0x40(%rsp)
je 0x9c76
leaq 0x10(%rsp), %rbx
movq (%rax), %rdi
movq %rdi, 0x8(%rsp)
callq 0x86d2
movq 0x8(%rsp), %r15
movq 0x18(%r15), %r14
cmpq 0x20(%r15), %r14
je 0x9c12
movq (%r14), %rax
cmpb $0x0, 0x58(%rax)
jne 0x9c0c
cmpb $0x0, 0x59(%rax)
jne 0x9c0c
movq 0x40(%rsp), %rcx
movq 0x50(%rsp), %rdx
addq $-0x8, %rdx
cmpq %rdx, %rcx
je 0x9bfa
movq %rax, (%rcx)
addq $0x8, 0x40(%rsp)
jmp 0x9c05
movq %rbx, %rdi
movq %r14, %rsi
callq 0xa3ba
movq (%r14), %rax
movb $0x1, 0x59(%rax)
addq $0x8, %r14
jmp 0x9bc7
movq 0x20(%rsp), %rax
movq 0x30(%rsp), %rcx
addq $-0x8, %rcx
cmpq %rcx, %rax
je 0x9c2b
addq $0x8, %rax
jmp 0x9c5d
movq 0x28(%rsp), %rdi
movl $0x200, %esi            # imm = 0x200
callq 0x8170
movq 0x38(%rsp), %rax
leaq 0x8(%rax), %rcx
movq %rcx, 0x38(%rsp)
movq 0x8(%rax), %rax
movq %rax, 0x28(%rsp)
leaq 0x200(%rax), %rcx
movq %rcx, 0x30(%rsp)
movq %rax, 0x20(%rsp)
movq 0x8(%rsp), %rcx
movb $0x0, 0x59(%rcx)
cmpq %rax, 0x40(%rsp)
jne 0x9bb1
leaq 0x10(%rsp), %rdi
callq 0xa1f4
addq $0x60, %rsp
popq %rbx
popq %r14
popq %r15
retq
jmp 0x9c8e
jmp 0x9c8e
movq %rax, %rbx
leaq 0x10(%rsp), %rdi
callq 0xa1f4
movq %rbx, %rdi
callq 0x8270
nop
// File: /workspace/github_c_makefile_star2_O1/buptlxb[P]xRay/src/function.cpp
// Function: Function::findBasicBlock(unsigned long long)
BasicBlock *Function::findBasicBlock(ADDR addr)
{
    BasicBlock *pos = hashTableBB[hash(addr)];
    while (pos) {
        if (pos->getFirstInstAddr() == getVirAddr(addr))
            break;
        pos = pos->getHashNext();
    }

    if (!pos) {
        pos = new BasicBlock(addr, getVirAddr(addr), this);
        basicBlocks.push_back(pos);
        BasicBlock *bb = hashTableBB[hash(addr)];
        pos->setHashNext(bb);
        hashTableBB[hash(addr)] = pos;
    }
    return pos;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %rbx
movl %r14d, %r12d
andl $0x3f, %r12d
movl %r12d, %eax
movq 0x68(%rdi,%rax,8), %rax
movq %rax, (%rsp)
testq %rax, %rax
sete %dl
je 0x9d18
movq %r14, %rcx
subq (%rbx), %rcx
setb %sil
addq 0x10(%rbx), %rcx
testb $0x1, %sil
movq $-0x1, %rsi
cmovneq %rsi, %rcx
cmpq %r14, 0x8(%rbx)
movq (%rax), %rdi
cmovbq %rsi, %rcx
cmpq %rcx, 0x8(%rdi)
je 0x9d14
movq 0x48(%rax), %rax
movq %rax, (%rsp)
testq %rax, %rax
sete %dl
je 0x9d18
movq (%rax), %rsi
cmpq %rcx, 0x8(%rsi)
jne 0x9cfb
testb %dl, %dl
je 0x9d85
movl $0x60, %edi
callq 0x8160
movq %rax, %r15
movq $-0x1, %rdx
cmpq %r14, 0x8(%rbx)
jb 0x9d41
movq %r14, %rax
subq (%rbx), %rax
jb 0x9d41
addq 0x10(%rbx), %rax
movq %rax, %rdx
movq %r15, %rdi
movq %r14, %rsi
movq %rbx, %rcx
callq 0x85ec
movq %r15, (%rsp)
movq 0x28(%rbx), %rsi
cmpq 0x30(%rbx), %rsi
je 0x9d67
movq %r15, (%rsi)
addq $0x8, 0x28(%rbx)
jmp 0x9d73
leaq 0x20(%rbx), %rdi
movq %rsp, %rdx
callq 0x8cdc
movq 0x68(%rbx,%r12,8), %rax
movq (%rsp), %rcx
movq %rax, 0x48(%rcx)
movq %rcx, 0x68(%rbx,%r12,8)
movq (%rsp), %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
movq %rax, %rbx
movl $0x60, %esi
movq %r15, %rdi
callq 0x8170
movq %rbx, %rdi
callq 0x8270
nop
// File: /workspace/github_c_makefile_star2_O1/buptlxb[P]xRay/src/function.cpp
// Function: Function::mergeBB()
long Function::mergeBB()
{
    long count = 0;
    for (set<BasicBlock *>::iterator iter = pairBBs.begin(); iter!=pairBBs.end(); iter++) {
        BasicBlock* bbptr = *iter;
        
        assert(bbptr->getSuccessors().size() == 2);
        TaintBlock *left = new TaintBlock(bbptr->getSuccessors().front());
        TaintBlock *right = new TaintBlock(bbptr->getSuccessors().back());
        if (*left == *right) {
            bbptr->dump();
            left->dump();
            bbptr->getSuccessors().front()->dump();
            right->dump();
            bbptr->getSuccessors().back()->dump();
            count++;
        }
        free(left);
        free(right);
    }
    return count;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0x50(%rdi), %r15
addq $0x40, %rbx
xorl %r14d, %r14d
cmpq %rbx, %r15
je 0x9ec8
movq 0x20(%r15), %r13
movq 0x20(%r13), %rax
subq 0x18(%r13), %rax
cmpq $0x10, %rax
jne 0x9eda
movl $0xe0, %edi
callq 0x8160
movq %rax, %r12
movq 0x18(%r13), %rax
movq (%rax), %rsi
movq %r12, %rdi
callq 0xae36
movl $0xe0, %edi
callq 0x8160
movq %rax, %rbp
movq 0x20(%r13), %rax
movq -0x8(%rax), %rsi
movq %rbp, %rdi
callq 0xae36
movq %r12, %rdi
movq %rbp, %rsi
callq 0xad94
testb %al, %al
je 0x9ea4
movq %r13, %rdi
callq 0x8ac6
movq %r12, %rdi
callq 0xb282
movq 0x18(%r13), %rax
movq (%rax), %rdi
callq 0x8ac6
movq %rbp, %rdi
callq 0xb282
movq 0x20(%r13), %rax
movq -0x8(%rax), %rdi
callq 0x8ac6
incq %r14
movq %r12, %rdi
callq 0x81c0
movq %rbp, %rdi
callq 0x81c0
movq %r15, %rdi
callq 0x81b0
movq %rax, %r15
cmpq %rbx, %rax
jne 0x9e12
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x23466(%rip), %rdi     # 0x2d347
leaq 0x23482(%rip), %rsi     # 0x2d36a
leaq 0x2348c(%rip), %rcx     # 0x2d37b
movl $0x7f, %edx
callq 0x80e0
movq %rax, %rbx
jmp 0x9f04
movq %rax, %rbx
movq %rbp, %r12
movl $0xe0, %esi
movq %r12, %rdi
callq 0x8170
movq %rbx, %rdi
callq 0x8270
nop
// File: /workspace/github_c_makefile_star2_O1/buptlxb[P]xRay/src/function.cpp
// Function: Function::reduction()
void Function::reduction()
{
    bool change = false;
    do {
        change = false;
        for (BasicBlock::BBPtrIter iter = basicBlocks.begin(); iter!=basicBlocks.end(); iter++) {
            BasicBlock* bbptr = *iter;
            if (bbptr->isRemoved()) {
                basicBlocks.erase(iter);
                break;
            }
            const vector<BasicBlock *> succs = bbptr->getSuccessors();
            if (succs.size() != 1)
                continue;
            BasicBlock *succ = succs.front();
            if (succ->getPredecessors().size() != 1)
                continue;
            
            bbptr->merge(succ);
            succ->setRemoved(true);
            change = true;
        }
    } while (change);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rdi, 0x8(%rsp)
movq 0x8(%rsp), %rax
movq 0x20(%rax), %rbp
movq 0x28(%rax), %rdx
cmpq %rdx, %rbp
je 0xa0f3
leaq 0x8(%rbp), %r15
movq $-0x8, %r14
subq %rbp, %r14
movl $0x0, 0x4(%rsp)
movq (%rbp), %r12
cmpb $0x1, 0x5b(%r12)
jne 0xa05a
cmpq %rdx, %r15
je 0xa049
leaq -0x8(%r15), %rdi
addq %r14, %rdx
movq %r15, %rsi
callq 0x8240
movq 0x8(%rsp), %rax
addq $-0x8, 0x28(%rax)
movl $0x4, %ebx
jmp 0xa0c1
leaq 0x18(%r12), %rsi
leaq 0x10(%rsp), %rdi
callq 0xa124
movq 0x10(%rsp), %rax
movq 0x18(%rsp), %rcx
subq %rax, %rcx
movl $0x6, %ebx
cmpq $0x8, %rcx
jne 0xa0aa
movq (%rax), %r13
movq 0x38(%r13), %rax
subq 0x30(%r13), %rax
cmpq $0x8, %rax
jne 0xa0aa
movq %r12, %rdi
movq %r13, %rsi
callq 0x8b34
movb $0x1, 0x5b(%r13)
movb $0x1, %al
movl %eax, 0x4(%rsp)
xorl %ebx, %ebx
movq 0x10(%rsp), %rdi
testq %rdi, %rdi
je 0xa0c1
movq 0x20(%rsp), %rsi
subq %rdi, %rsi
callq 0x8170
cmpl $0x6, %ebx
je 0xa0ca
testl %ebx, %ebx
jne 0xa0e8
addq $0x8, %rbp
movq 0x8(%rsp), %rax
movq 0x28(%rax), %rdx
addq $0x8, %r15
addq $-0x8, %r14
cmpq %rdx, %rbp
jne 0xa029
testb $0x1, 0x4(%rsp)
jne 0x9ffd
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
movq 0x10(%rsp), %rdi
testq %rdi, %rdi
je 0xa11c
movq 0x20(%rsp), %rsi
subq %rdi, %rsi
callq 0x8170
movq %rbx, %rdi
callq 0x8270
// File: /workspace/github_c_makefile_star2_O1/buptlxb[P]xRay/src/main.cpp
// Function: main
int main(int argc, char* argv [])
{
    // 1.judge illegal
    if(argc<=1){
        fprintf(stderr, "Usage: ./rop FileList\n");
        abort();
    }
    // 2.read file List and find Ret Code
    vector<BinInfo> vBin;
    puts("[1] BinInfo parse");
    for(int i=1; i<argc; i++){
        BinInfo bin(argv[i]);
        //bin.findRetCodeInElf();
        vBin.push_back(bin);
    }

#if 0
    puts("");
    puts("[2] Dump Function Information");
    for (vector<BinInfo>::iterator iter = vBin.begin(); iter != vBin.end(); iter++) {
        iter->dumpFunc();
    }
#endif
    puts("");
    puts("[2] Disasm Function");
    for (vector<BinInfo>::iterator iter = vBin.begin(); iter != vBin.end(); iter++) {
        iter->disasm();
    }
    return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x78, %rsp
cmpl $0x1, %edi
jle 0xa7b6
movq %rsi, %rbx
movl %edi, %ebp
xorps %xmm0, %xmm0
movq %rsp, %rax
movaps %xmm0, (%rax)
movq $0x0, 0x10(%rax)
leaq 0x22cc7(%rip), %rdi     # 0x2d3db
callq 0x8220
leaq 0x58(%rsp), %r15
leaq 0x30(%rsp), %r13
movl %ebp, %ebp
movl $0x1, %r14d
leaq 0x20(%rsp), %r12
movq (%rbx,%r14,8), %rsi
movq %r12, %rdi
callq 0x91f8
movq %rsp, %rdi
movq %r12, %rsi
callq 0xa7e0
movq %r15, %rdi
callq 0x9650
movq 0x20(%rsp), %rdi
cmpq %r13, %rdi
je 0xa766
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x8170
incq %r14
cmpq %r14, %rbp
jne 0xa730
movl $0xa, %edi
callq 0x81d0
leaq 0x22c6e(%rip), %rdi     # 0x2d3ed
callq 0x8220
movq (%rsp), %rbx
cmpq 0x8(%rsp), %rbx
je 0xa79d
movq %rbx, %rdi
callq 0x955e
addq $0x58, %rbx
jmp 0xa788
movq %rsp, %rdi
callq 0xa832
xorl %eax, %eax
addq $0x78, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
callq 0x8444
jmp 0xa7bd
movq %rax, %rbx
jmp 0xa7cf
movq %rax, %rbx
leaq 0x20(%rsp), %rdi
callq 0xa80a
movq %rsp, %rdi
callq 0xa832
movq %rbx, %rdi
callq 0x8270
nop
// File: /workspace/github_c_makefile_star2_O1/buptlxb[P]xRay/disasm/instr_set/opcodes_A_M.c
// Function: add_EbGb
void __bea_callspec__ add_EbGb(PDISASM pMyDisasm)
{
    if ((*pMyDisasm).Prefix.LockPrefix == InvalidPrefix) {
        (*pMyDisasm).Prefix.LockPrefix = InUsePrefix;
    }
    (*pMyDisasm).Instruction.Category = GENERAL_PURPOSE_INSTRUCTION+ARITHMETIC_INSTRUCTION;
    #ifndef BEA_LIGHT_DISASSEMBLY
       (void) strcpy ((*pMyDisasm).Instruction.Mnemonic, "add ");
    #endif
    EbGb(pMyDisasm);
    FillFlags(pMyDisasm,5);
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
cmpb $0x4, 0x1dc(%rdi)
jne 0xb50c
movb $0x1, 0x1dc(%rbx)
movl $0x10002, 0x60(%rbx)    # imm = 0x10002
movl $0x20646461, 0x68(%rbx) # imm = 0x20646461
movb $0x0, 0x6c(%rbx)
movq %rbx, %rdi
callq 0x2ad9b
movl 0x2cc98(%rip), %eax     # 0x381c4
movl %eax, 0x84(%rbx)
movq 0x2cc83(%rip), %rax     # 0x381bc
movq %rax, 0x7c(%rbx)
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O1/buptlxb[P]xRay/disasm/instr_set/opcodes_A_M.c
// Function: add_EvGv
void __bea_callspec__ add_EvGv(PDISASM pMyDisasm)
{
    if ((*pMyDisasm).Prefix.LockPrefix == InvalidPrefix) {
        (*pMyDisasm).Prefix.LockPrefix = InUsePrefix;
    }
    (*pMyDisasm).Instruction.Category = GENERAL_PURPOSE_INSTRUCTION+ARITHMETIC_INSTRUCTION;
    #ifndef BEA_LIGHT_DISASSEMBLY
       (void) strcpy ((*pMyDisasm).Instruction.Mnemonic, "add ");
    #endif
    EvGv(pMyDisasm);
    FillFlags(pMyDisasm,5);
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
cmpb $0x4, 0x1dc(%rdi)
jne 0xb553
movb $0x1, 0x1dc(%rbx)
movl $0x10002, 0x60(%rbx)    # imm = 0x10002
movl $0x20646461, 0x68(%rbx) # imm = 0x20646461
movb $0x0, 0x6c(%rbx)
movq %rbx, %rdi
callq 0x2ae0b
movl 0x2cc51(%rip), %eax     # 0x381c4
movl %eax, 0x84(%rbx)
movq 0x2cc3c(%rip), %rax     # 0x381bc
movq %rax, 0x7c(%rbx)
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O1/buptlxb[P]xRay/disasm/instr_set/opcodes_A_M.c
// Function: add_GbEb
void __bea_callspec__ add_GbEb(PDISASM pMyDisasm)
{
    if ((*pMyDisasm).Prefix.LockPrefix == InvalidPrefix) {
        (*pMyDisasm).Prefix.LockPrefix = InUsePrefix;
    }
    (*pMyDisasm).Instruction.Category = GENERAL_PURPOSE_INSTRUCTION+ARITHMETIC_INSTRUCTION;
    #ifndef BEA_LIGHT_DISASSEMBLY
       (void) strcpy ((*pMyDisasm).Instruction.Mnemonic, "add ");
    #endif
    GbEb(pMyDisasm);
    FillFlags(pMyDisasm,5);
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
cmpb $0x4, 0x1dc(%rdi)
jne 0xb59a
movb $0x1, 0x1dc(%rbx)
movl $0x10002, 0x60(%rbx)    # imm = 0x10002
movl $0x20646461, 0x68(%rbx) # imm = 0x20646461
movb $0x0, 0x6c(%rbx)
movq %rbx, %rdi
callq 0x2ae61
movl 0x2cc0a(%rip), %eax     # 0x381c4
movl %eax, 0x84(%rbx)
movq 0x2cbf5(%rip), %rax     # 0x381bc
movq %rax, 0x7c(%rbx)
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O1/buptlxb[P]xRay/disasm/instr_set/opcodes_A_M.c
// Function: add_GvEv
void __bea_callspec__ add_GvEv(PDISASM pMyDisasm)
{
    if ((*pMyDisasm).Prefix.LockPrefix == InvalidPrefix) {
        (*pMyDisasm).Prefix.LockPrefix = InUsePrefix;
    }
    (*pMyDisasm).Instruction.Category = GENERAL_PURPOSE_INSTRUCTION+ARITHMETIC_INSTRUCTION;
    #ifndef BEA_LIGHT_DISASSEMBLY
       (void) strcpy ((*pMyDisasm).Instruction.Mnemonic, "add ");
    #endif
    GvEv(pMyDisasm);
    FillFlags(pMyDisasm,5);
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
cmpb $0x4, 0x1dc(%rdi)
jne 0xb5e1
movb $0x1, 0x1dc(%rbx)
movl $0x10002, 0x60(%rbx)    # imm = 0x10002
movl $0x20646461, 0x68(%rbx) # imm = 0x20646461
movb $0x0, 0x6c(%rbx)
movq %rbx, %rdi
callq 0x2aeb0
movl 0x2cbc3(%rip), %eax     # 0x381c4
movl %eax, 0x84(%rbx)
movq 0x2cbae(%rip), %rax     # 0x381bc
movq %rax, 0x7c(%rbx)
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O1/buptlxb[P]xRay/disasm/instr_set/opcodes_A_M.c
// Function: add_ALIb
void __bea_callspec__ add_ALIb(PDISASM pMyDisasm)
{
    if ((*pMyDisasm).Prefix.LockPrefix == InvalidPrefix) {
        (*pMyDisasm).Prefix.LockPrefix = InUsePrefix;
    }
    (*pMyDisasm).Instruction.Category = GENERAL_PURPOSE_INSTRUCTION+ARITHMETIC_INSTRUCTION;
    #ifndef BEA_LIGHT_DISASSEMBLY
       (void) strcpy ((*pMyDisasm).Instruction.Mnemonic, "add ");
    #endif
    ALIb(pMyDisasm);
    FillFlags(pMyDisasm,5);
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
cmpb $0x4, 0x1dc(%rdi)
jne 0xb628
movb $0x1, 0x1dc(%rbx)
movl $0x10002, 0x60(%rbx)    # imm = 0x10002
movl $0x20646461, 0x68(%rbx) # imm = 0x20646461
movb $0x0, 0x6c(%rbx)
movq %rbx, %rdi
callq 0x2af06
movl 0x2cb7c(%rip), %eax     # 0x381c4
movl %eax, 0x84(%rbx)
movq 0x2cb67(%rip), %rax     # 0x381bc
movq %rax, 0x7c(%rbx)
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O1/buptlxb[P]xRay/disasm/instr_set/opcodes_A_M.c
// Function: add_eAX_Iv
void __bea_callspec__ add_eAX_Iv(PDISASM pMyDisasm)
{
    if ((*pMyDisasm).Prefix.LockPrefix == InvalidPrefix) {
        (*pMyDisasm).Prefix.LockPrefix = InUsePrefix;
    }
    (*pMyDisasm).Instruction.Category = GENERAL_PURPOSE_INSTRUCTION+ARITHMETIC_INSTRUCTION;
    #ifndef BEA_LIGHT_DISASSEMBLY
       (void) strcpy ((*pMyDisasm).Instruction.Mnemonic, "add ");
    #endif
    eAX_Iv(pMyDisasm);
    FillFlags(pMyDisasm,5);
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
cmpb $0x4, 0x1dc(%rdi)
jne 0xb66f
movb $0x1, 0x1dc(%rbx)
movl $0x10002, 0x60(%rbx)    # imm = 0x10002
movl $0x20646461, 0x68(%rbx) # imm = 0x20646461
movb $0x0, 0x6c(%rbx)
movq %rbx, %rdi
callq 0x2afb0
movl 0x2cb35(%rip), %eax     # 0x381c4
movl %eax, 0x84(%rbx)
movq 0x2cb20(%rip), %rax     # 0x381bc
movq %rax, 0x7c(%rbx)
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O1/buptlxb[P]xRay/disasm/instr_set/opcodes_N_Z.c
// Function: push_es
void __bea_callspec__ push_es(PDISASM pMyDisasm)
{
    (*pMyDisasm).Instruction.Category = GENERAL_PURPOSE_INSTRUCTION+DATA_TRANSFER;
    #ifndef BEA_LIGHT_DISASSEMBLY
       (void) strcpy ((*pMyDisasm).Instruction.Mnemonic, "push ");
    #endif
    if (GV.Architecture == 64) {
        FailDecode(pMyDisasm);
    }
    else {
        #ifndef BEA_LIGHT_DISASSEMBLY
           (void) strcpy((char*) &(*pMyDisasm).Argument1.ArgMnemonic, RegistersSEG[0]);
        #endif
        (*pMyDisasm).Argument2.ArgType = REGISTER_TYPE+SEGMENT_REG+REGS[0];
        (*pMyDisasm).Argument2.ArgSize = 16;
        (*pMyDisasm).Argument1.ArgType = MEMORY_TYPE;
        (*pMyDisasm).Argument1.ArgSize = 16;
        (*pMyDisasm).Argument1.Memory.BaseRegister = REG4;
        (*pMyDisasm).Instruction.ImplicitModifiedRegs = REGISTER_TYPE+GENERAL_REG+REG4;
        GV.EIP_++;
    }
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
movl $0x10001, 0x60(%rdi)    # imm = 0x10001
movl $0x68737570, 0x68(%rdi) # imm = 0x68737570
movw $0x20, 0x6c(%rdi)
cmpl $0x40, 0x25c(%rdi)
jne 0xb6dd
leaq 0x68(%rbx), %rax
movb $0x0, 0x4(%rax)
movl $0x203f3f3f, (%rax)     # imm = 0x203F3F3F
movl $0x1, 0x280(%rbx)
jmp 0xb734
leaq 0x9c(%rbx), %rdi
leaq 0x2d235(%rip), %rsi     # 0x38920
callq 0x8150
movl $0x21000000, %eax       # imm = 0x21000000
addl 0x2d745(%rip), %eax     # 0x38e40
movl %eax, 0x144(%rbx)
movl $0x10, %eax
movl %eax, 0x148(%rbx)
movabsq $0x1040000000, %rcx     # imm = 0x1040000000
movq %rcx, 0xdc(%rbx)
movl %eax, 0xec(%rbx)
movl $0x20020010, 0x98(%rbx) # imm = 0x20020010
incq 0x1f0(%rbx)
popq %rbx
retq