LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O3/qpfiffer[P]38-Moths/src/greshunkel.c
// Function: gshkl_add_string
int gshkl_add_string(greshunkel_ctext *ctext, const char name[const], const char value[const]) {
	assert(ctext != NULL);
	assert(name != NULL);
	assert(value != NULL);

	/* Create a new tuple to hold type and name and shit. */
	greshunkel_tuple _stack_tuple = {
		.name = {0},
		.type = GSHKL_STR,
		.value =  {{0}}
	};
	strncpy(_stack_tuple.name, name, WISDOM_OF_WORDS - 1);

	/* Copy the value of the string into the var object: */
	greshunkel_var _stack_var = {{0}};
	if (value != NULL)
		strncpy(_stack_var.str, value, MAX_GSHKL_STR_SIZE);
	_stack_var.str[MAX_GSHKL_STR_SIZE] = '\0';

	/* Copy the var object itself into the tuple's var space: */
	memcpy(&_stack_tuple.value, &_stack_var, sizeof(greshunkel_var));

	/* Push that onto our values stack. */
	return _gshkl_add_var_to_context(ctext, &_stack_tuple);
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x438, %rsp            # imm = 0x438
testq %rdi, %rdi
je 0x200e
testq %rsi, %rsi
je 0x202d
movq %rdx, %r15
testq %rdx, %rdx
je 0x204c
movq %rdi, %rbx
xorps %xmm0, %xmm0
movq %rsp, %r14
movups %xmm0, 0x18(%r14)
movl $0x1, 0x20(%r14)
movl $0x1f, %edx
movq %r14, %rdi
callq 0x1050
leaq 0x230(%rsp), %r12
movq $0x0, 0x200(%r12)
movl $0x200, %edx            # imm = 0x200
movq %r12, %rdi
movq %r15, %rsi
callq 0x1050
leaq 0x28(%rsp), %rdi
movl $0x208, %edx            # imm = 0x208
movq %r12, %rsi
callq 0x1190
movq (%rbx), %rdi
movl $0x230, %edx            # imm = 0x230
movq %r14, %rsi
callq 0x483b
xorl %ecx, %ecx
testl %eax, %eax
sete %cl
movl %ecx, %eax
addq $0x438, %rsp            # imm = 0x438
popq %rbx
popq %r12
popq %r14
popq %r15
retq
leaq 0x421b(%rip), %rdi      # 0x6230
leaq 0x4222(%rip), %rsi      # 0x623e
leaq 0x4368(%rip), %rcx      # 0x638b
movl $0x76, %edx
callq 0x1110
leaq 0x471f(%rip), %rdi      # 0x6753
leaq 0x4203(%rip), %rsi      # 0x623e
leaq 0x4349(%rip), %rcx      # 0x638b
movl $0x77, %edx
callq 0x1110
leaq 0x4387(%rip), %rdi      # 0x63da
leaq 0x41e4(%rip), %rsi      # 0x623e
leaq 0x432a(%rip), %rcx      # 0x638b
movl $0x78, %edx
callq 0x1110
// File: /workspace/github_c_makefile_star2_O3/qpfiffer[P]38-Moths/src/greshunkel.c
// Function: gshkl_add_int
int gshkl_add_int(greshunkel_ctext *ctext, const char name[const], const int value) {
	assert(ctext != NULL);
	assert(name != NULL);

	greshunkel_tuple _stack_tuple = {
		.name = {0},
		.type = GSHKL_STR,
		.value = {{0}}
	};
	strncpy(_stack_tuple.name, name, WISDOM_OF_WORDS - 1);

	greshunkel_var _stack_var = {{0}};
	snprintf(_stack_var.str, MAX_GSHKL_STR_SIZE, "%i", value);

	memcpy(&_stack_tuple.value, &_stack_var, sizeof(greshunkel_var));

	return _gshkl_add_var_to_context(ctext, &_stack_tuple);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x438, %rsp            # imm = 0x438
testq %rdi, %rdi
je 0x2129
movq %rsi, %r15
testq %rsi, %rsi
je 0x2148
movl %edx, %ebp
movq %rdi, %rbx
leaq 0x18(%rsp), %r14
movl $0x218, %edx            # imm = 0x218
movq %r14, %rdi
xorl %esi, %esi
callq 0x1120
movl $0x1, 0x8(%r14)
movq %rsp, %r14
movl $0x1f, %edx
movq %r14, %rdi
movq %r15, %rsi
callq 0x1050
leaq 0x230(%rsp), %r15
movl $0x208, %edx            # imm = 0x208
movq %r15, %rdi
xorl %esi, %esi
callq 0x1120
leaq 0x487c(%rip), %rdx      # 0x695b
movl $0x200, %esi            # imm = 0x200
movq %r15, %rdi
movl %ebp, %ecx
xorl %eax, %eax
callq 0x10f0
leaq 0x28(%rsp), %rdi
movl $0x208, %edx            # imm = 0x208
movq %r15, %rsi
callq 0x1190
movq (%rbx), %rdi
movl $0x230, %edx            # imm = 0x230
movq %r14, %rsi
callq 0x483b
xorl %ecx, %ecx
testl %eax, %eax
sete %cl
movl %ecx, %eax
addq $0x438, %rsp            # imm = 0x438
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
leaq 0x4100(%rip), %rdi      # 0x6230
leaq 0x4107(%rip), %rsi      # 0x623e
leaq 0x42aa(%rip), %rcx      # 0x63e8
movl $0x90, %edx
callq 0x1110
leaq 0x4604(%rip), %rdi      # 0x6753
leaq 0x40e8(%rip), %rsi      # 0x623e
leaq 0x428b(%rip), %rcx      # 0x63e8
movl $0x91, %edx
callq 0x1110
// File: /workspace/github_c_makefile_star2_O3/qpfiffer[P]38-Moths/src/greshunkel.c
// Function: gshkl_add_array
greshunkel_var gshkl_add_array(greshunkel_ctext *ctext, const char name[]) {
	assert(ctext != NULL);

	greshunkel_tuple _stack_tuple = {
		.name = {0},
		.type = GSHKL_ARR,
		.value = {
			.arr = vector_new(sizeof(greshunkel_tuple), 16)
		}
	};
	const size_t name_len = strnlen(name, WISDOM_OF_WORDS) < WISDOM_OF_WORDS ? strnlen(name, WISDOM_OF_WORDS) : WISDOM_OF_WORDS;
	strncpy(_stack_tuple.name, name, name_len);

	_gshkl_add_var_to_context(ctext, &_stack_tuple);
	return _stack_tuple.value;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x238, %rsp            # imm = 0x238
testq %rsi, %rsi
je 0x2213
movq %rdx, %r12
movq %rsi, %r15
movq %rdi, %rbx
leaq 0x30(%rsp), %r14
leaq 0x8(%rsp), %r13
movl $0x230, %edx            # imm = 0x230
movq %r13, %rdi
xorl %esi, %esi
callq 0x1120
movl $0x230, %edi            # imm = 0x230
movl $0x10, %esi
callq 0x47fc
movq %rax, 0x28(%r13)
movl $0x20, %ebp
movl $0x20, %esi
movq %r12, %rdi
callq 0x1130
cmpq $0x20, %rax
cmovbq %rax, %rbp
movq %r13, %rdi
movq %r12, %rsi
movq %rbp, %rdx
callq 0x1050
movq (%r15), %rdi
movl $0x230, %edx            # imm = 0x230
movq %r13, %rsi
callq 0x483b
movl $0x208, %edx            # imm = 0x208
movq %rbx, %rdi
movq %r14, %rsi
callq 0x1190
movq %rbx, %rax
addq $0x238, %rsp            # imm = 0x238
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x4016(%rip), %rdi      # 0x6230
leaq 0x401d(%rip), %rsi      # 0x623e
leaq 0x4204(%rip), %rcx      # 0x642c
movl $0xa3, %edx
callq 0x1110
// File: /workspace/github_c_makefile_star2_O3/qpfiffer[P]38-Moths/src/greshunkel.c
// Function: gshkl_add_int_to_loop
int gshkl_add_int_to_loop(greshunkel_var *loop, const int value) {
	assert(loop != NULL);

	greshunkel_tuple _stack_tuple = {
		.name = {0},
		.type = GSHKL_STR,
		.value = {{0}}
	};

	greshunkel_var _stack_var = {{0}};
	snprintf(_stack_var.str, MAX_GSHKL_STR_SIZE, "%i", value);

	memcpy(&_stack_tuple.value, &_stack_var, sizeof(greshunkel_var));

	return _gshkl_add_var_to_loop(loop, &_stack_tuple);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x438, %rsp            # imm = 0x438
testq %rdi, %rdi
je 0x22d5
movl %esi, %ebp
movq %rdi, %rbx
xorps %xmm0, %xmm0
leaq 0x28(%rsp), %r14
movaps %xmm0, -0x18(%r14)
movaps %xmm0, -0x28(%r14)
movq $0x0, -0x8(%r14)
movl $0x1, -0x8(%r14)
leaq 0x230(%rsp), %r15
movl $0x208, %edx            # imm = 0x208
movq %r15, %rdi
xorl %esi, %esi
callq 0x1120
leaq 0x46ce(%rip), %rdx      # 0x695b
movl $0x200, %esi            # imm = 0x200
movq %r15, %rdi
movl %ebp, %ecx
xorl %eax, %eax
callq 0x10f0
movl $0x208, %edx            # imm = 0x208
movq %r14, %rdi
movq %r15, %rsi
callq 0x1190
movq (%rbx), %rdi
movq %rsp, %rsi
movl $0x230, %edx            # imm = 0x230
callq 0x483b
xorl %ecx, %ecx
testl %eax, %eax
sete %cl
movl %ecx, %eax
addq $0x438, %rsp            # imm = 0x438
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
leaq 0x4191(%rip), %rdi      # 0x646d
leaq 0x3f5b(%rip), %rsi      # 0x623e
leaq 0x4190(%rip), %rcx      # 0x647a
movl $0xb4, %edx
callq 0x1110
// File: /workspace/github_c_makefile_star2_O3/qpfiffer[P]38-Moths/src/greshunkel.c
// Function: gshkl_add_sub_context_to_loop
int gshkl_add_sub_context_to_loop(greshunkel_var *loop, const greshunkel_ctext *ctext) {
	assert(loop != NULL);
	assert(ctext != NULL);

	greshunkel_tuple _stack_tuple = {
		.name = {0},
		.type = GSHKL_SUBCTEXT,
		.value = {
			.sub_ctext = ctext
		}
	};

	return _gshkl_add_var_to_loop(loop, &_stack_tuple);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x230, %rsp            # imm = 0x230
testq %rdi, %rdi
je 0x2354
movq %rsi, %r14
testq %rsi, %rsi
je 0x2373
movq %rdi, %rbx
movq %rsp, %r15
movl $0x230, %edx            # imm = 0x230
movq %r15, %rdi
xorl %esi, %esi
callq 0x1120
movl $0x2, 0x20(%r15)
movq %r14, 0x28(%r15)
movq (%rbx), %rdi
movl $0x230, %edx            # imm = 0x230
movq %r15, %rsi
callq 0x483b
xorl %ecx, %ecx
testl %eax, %eax
sete %cl
movl %ecx, %eax
addq $0x230, %rsp            # imm = 0x230
popq %rbx
popq %r14
popq %r15
retq
leaq 0x4112(%rip), %rdi      # 0x646d
leaq 0x3edc(%rip), %rsi      # 0x623e
leaq 0x4148(%rip), %rcx      # 0x64b1
movl $0xc5, %edx
callq 0x1110
leaq 0x3eb6(%rip), %rdi      # 0x6230
leaq 0x3ebd(%rip), %rsi      # 0x623e
leaq 0x4129(%rip), %rcx      # 0x64b1
movl $0xc6, %edx
callq 0x1110
// File: /workspace/github_c_makefile_star2_O3/qpfiffer[P]38-Moths/src/greshunkel.c
// Function: gshkl_add_string_to_loop
int gshkl_add_string_to_loop(greshunkel_var *loop, const char *value) {
	assert(loop != NULL);

	greshunkel_tuple _stack_tuple = {
		.name = {0},
		.type = GSHKL_STR,
		.value = {{0}}
	};

	greshunkel_var _stack_var = {{0}};
	if (value != NULL)
		strncpy(_stack_var.str, value, MAX_GSHKL_STR_SIZE);
	_stack_var.str[MAX_GSHKL_STR_SIZE] = '\0';

	memcpy(&_stack_tuple.value, &_stack_var, sizeof(union greshunkel_var));

	return _gshkl_add_var_to_loop(loop, &_stack_tuple);
}

// Assembly:
pushq %r14
pushq %rbx
subq $0x438, %rsp            # imm = 0x438
testq %rdi, %rdi
je 0x2438
movq %rsi, %r14
movq %rdi, %rbx
xorps %xmm0, %xmm0
movaps %xmm0, 0x10(%rsp)
movaps %xmm0, (%rsp)
movq $0x0, 0x20(%rsp)
movl $0x1, 0x20(%rsp)
leaq 0x230(%rsp), %rdi
movl $0x208, %edx            # imm = 0x208
xorl %esi, %esi
callq 0x1120
testq %r14, %r14
je 0x23f6
leaq 0x230(%rsp), %rdi
movl $0x200, %edx            # imm = 0x200
movq %r14, %rsi
callq 0x1050
leaq 0x230(%rsp), %rsi
movb $0x0, 0x200(%rsi)
leaq 0x28(%rsp), %rdi
movl $0x208, %edx            # imm = 0x208
callq 0x1190
movq (%rbx), %rdi
movq %rsp, %rsi
movl $0x230, %edx            # imm = 0x230
callq 0x483b
xorl %ecx, %ecx
testl %eax, %eax
sete %cl
movl %ecx, %eax
addq $0x438, %rsp            # imm = 0x438
popq %rbx
popq %r14
retq
leaq 0x402e(%rip), %rdi      # 0x646d
leaq 0x3df8(%rip), %rsi      # 0x623e
leaq 0x40b2(%rip), %rcx      # 0x64ff
movl $0xd4, %edx
callq 0x1110
// File: /workspace/github_c_makefile_star2_O3/qpfiffer[P]38-Moths/src/greshunkel.c
// Function: gshkl_free_context
void gshkl_free_context(greshunkel_ctext *ctext) {
	unsigned int i;
	for (i = 0; i < ctext->values->count; i++) {
		greshunkel_tuple *next = (greshunkel_tuple *)vector_get(ctext->values, i);
		if (next->type == GSHKL_ARR) {
			_gshkl_free_arr(next);
		} else if (next->type == GSHKL_SUBCTEXT) {
			gshkl_free_context((struct greshunkel_ctext *)next->value.sub_ctext);
		}
	}
	vector_free(ctext->values);
	vector_free(ctext->filter_functions);

	free(ctext);
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq (%rdi), %rdi
cmpq $0x0, 0x10(%rdi)
je 0x249f
xorl %r14d, %r14d
movl %r14d, %esi
callq 0x494b
movl 0x20(%rax), %ecx
cmpl $0x2, %ecx
je 0x248a
testl %ecx, %ecx
jne 0x2493
movq 0x28(%rax), %rdi
callq 0x4a90
jmp 0x2493
movq 0x28(%rax), %rdi
callq 0x2457
incl %r14d
movq (%rbx), %rdi
cmpq %r14, 0x10(%rdi)
ja 0x246b
callq 0x4a90
movq 0x8(%rbx), %rdi
callq 0x4a90
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x1030
// File: /workspace/github_c_makefile_star2_O3/qpfiffer[P]38-Moths/src/greshunkel.c
// Function: regexec_2_0_beta
static int regexec_2_0_beta(const regex_t *preg, const char *string, size_t nmatch, match_t pmatch[]) {
	unsigned int i;
	regmatch_t matches[nmatch];
	memset(matches, 0, sizeof(matches));

	if (regexec(preg, string, nmatch, matches, 0) != 0) {
		return 1;
	}
	for (i = 0; i < nmatch; i++) {
		pmatch[i].rm_so = matches[i].rm_so;
		pmatch[i].rm_eo = matches[i].rm_eo;
		pmatch[i].len = matches[i].rm_eo - matches[i].rm_so;
		pmatch[i].start = string + matches[i].rm_so;
	}
	return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rcx, %rbx
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %r13
movq %rsp, %r12
leaq 0xf(,%rdx,8), %rax
andq $-0x10, %rax
subq %rax, %r12
movq %r12, %rsp
leaq (,%rdx,8), %rdx
movq %r12, %rdi
xorl %esi, %esi
callq 0x1120
movq %r13, %rdi
movq %r15, %rsi
movq %r14, %rdx
movq %r12, %rcx
xorl %r8d, %r8d
callq 0x11c0
movl %eax, %ecx
movl $0x1, %eax
testl %ecx, %ecx
jne 0x3b13
movl $0x0, %eax
testq %r14, %r14
je 0x3b13
addq $0x10, %rbx
xorl %eax, %eax
xorl %ecx, %ecx
movslq (%r12,%rcx,8), %rdx
movl %edx, -0x10(%rbx)
movl 0x4(%r12,%rcx,8), %esi
movl %esi, -0xc(%rbx)
subl %edx, %esi
movslq %esi, %rsi
movq %rsi, -0x8(%rbx)
addq %r15, %rdx
movq %rdx, (%rbx)
incq %rcx
movl %ecx, %edx
addq $0x18, %rbx
cmpq %r14, %rdx
jb 0x3ae7
leaq -0x28(%rbp), %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/qpfiffer[P]38-Moths/src/greshunkel.c
// Function: find_needle
static const void *find_needle(const greshunkel_ctext *ctext, const char *needle, int find_values) {
	const greshunkel_ctext *current_ctext = ctext;
	while (current_ctext != NULL) {
		vector *current_vector;
		current_vector = (find_values) ? current_ctext->values : current_ctext->filter_functions;
		unsigned int i;
		for (i = 0; i < current_vector->count; i++) {
			const greshunkel_named_item *item = (greshunkel_named_item *)vector_get(current_vector, i);
			assert(item->name != NULL);
			const size_t larger = strlen(item->name) > strlen(needle) ? strlen(item->name) : strlen(needle);
			if (strncmp(item->name, needle, larger) == 0)
				return item;
		}
		current_ctext = current_ctext->parent;
	}
	return NULL;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
testq %rdi, %rdi
je 0x3ba9
movq %rsi, %rbx
movq %rdi, %r14
xorl %eax, %eax
testl %edx, %edx
sete %al
shll $0x3, %eax
movq %rax, (%rsp)
movq (%rsp), %rax
movq (%r14,%rax), %r15
cmpq $0x0, 0x10(%r15)
je 0x3ba0
xorl %r12d, %r12d
movq %r15, %rdi
movl %r12d, %esi
callq 0x494b
testq %rax, %rax
je 0x3bbe
movq %rax, %r13
movq %rax, %rdi
callq 0x10c0
movq %rax, %rbp
movq %rbx, %rdi
callq 0x10c0
cmpq %rax, %rbp
cmovbeq %rax, %rbp
movq %r13, %rdi
movq %rbx, %rsi
movq %rbp, %rdx
callq 0x1060
testl %eax, %eax
je 0x3bac
incl %r12d
cmpq %r12, 0x10(%r15)
ja 0x3b58
movq 0x10(%r14), %r14
testq %r14, %r14
jne 0x3b46
xorl %r13d, %r13d
movq %r13, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x2b88(%rip), %rdi      # 0x674d
leaq 0x2672(%rip), %rsi      # 0x623e
leaq 0x2b8d(%rip), %rcx      # 0x6760
movl $0x139, %edx            # imm = 0x139
callq 0x1110
// File: /workspace/github_c_makefile_star2_O3/qpfiffer[P]38-Moths/src/greshunkel.c
// Function: vishnu
static void vishnu(line *new_line_to_add, const match_t match, const char *result, const line *operating_line) {
	char *p;
	const size_t sizes[3] = {match.rm_so, strlen(result), operating_line->size - match.rm_eo};

	new_line_to_add->size = sizes[0] + sizes[1] + sizes[2];
	new_line_to_add->data = p = calloc(1, new_line_to_add->size + 1);

	memcpy(p, operating_line->data, sizes[0]);
	p += sizes[0];
	memcpy(p, result, sizes[1]);
	p += sizes[1];
	memcpy(p, operating_line->data + match.rm_eo, sizes[2]);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %r8, %r12
movq %rcx, 0x10(%rsp)
movl %edx, %ebp
movq %rdi, %r13
movslq %esi, %rbx
movq %rcx, %rdi
callq 0x10c0
movq %rax, %r15
movq (%r12), %r14
movslq %ebp, %rax
movq %rax, 0x8(%rsp)
subq %rax, %r14
leaq (%r15,%rbx), %rax
leaq (%rax,%r14), %rcx
movq %rcx, (%r13)
leaq (%r14,%rax), %rsi
incq %rsi
movl $0x1, %edi
callq 0x1160
movq %rax, %rbp
movq %rax, 0x8(%r13)
movq 0x8(%r12), %r12
movq %rax, %rdi
movq %r12, %rsi
movq %rbx, %rdx
callq 0x1190
addq %rbx, %rbp
movq %rbp, %rdi
movq 0x10(%rsp), %rsi
movq %r15, %rdx
callq 0x1190
addq %r15, %rbp
addq 0x8(%rsp), %r12
movq %rbp, %rdi
movq %r12, %rsi
movq %r14, %rdx
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x1190
// File: /workspace/github_c_makefile_star2_O3/qpfiffer[P]38-Moths/src/vector.c
// Function: vector_new
vector *vector_new(const size_t item_size, const size_t initial_element_count) {
	vector _vec = {
		.item_size = item_size,
		.max_size = initial_element_count,
		.count = 0,
		.items = calloc(1, initial_element_count * item_size + 1)
	};

	vector *to_return = calloc(1, sizeof(vector));
	memcpy(to_return, &_vec, sizeof(vector));

	return to_return;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %rbx
movq %rdi, %r14
imulq %rdi, %rsi
incq %rsi
movl $0x1, %edi
callq 0x1160
movq %rax, %r15
movl $0x1, %edi
movl $0x20, %esi
callq 0x1160
movq %r14, (%rax)
movq %rbx, 0x8(%rax)
movq %r15, 0x18(%rax)
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O3/qpfiffer[P]38-Moths/src/vector.c
// Function: vector_append
inline int vector_append(vector *vec, const void *item, const size_t item_size) {
	if (vec == NULL)
		return 0;

	if (item_size > vec->item_size)
		return 0;

	if (vec->count == vec->max_size) {
		vec->max_size *= 2;
		void *array = realloc(vec->items, vec->max_size * vec->item_size + 1);
		if (!array)
			return 0;
		vec->items = array;
	}

	if (item_size != 0 && item != NULL) {
		memcpy(nth(vec->count), item, item_size);
		memset(nth(vec->count) + item_size, '\0', sizeof(char));
	} else {
		/* Just zero out the memory so we can check for NULLs. */
		memset(nth(vec->count), 0, vec->item_size);
	}
	vec->count++;
	return 1;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
xorl %ebp, %ebp
testq %rdi, %rdi
je 0x48d5
movq %rdx, %r14
movq %rdi, %rbx
movq (%rdi), %rax
cmpq %rdx, %rax
jb 0x48d5
movq %rsi, %r15
movq 0x10(%rbx), %rsi
cmpq 0x8(%rbx), %rsi
jne 0x4888
addq %rsi, %rsi
movq %rsi, 0x8(%rbx)
movq 0x18(%rbx), %rdi
imulq %rax, %rsi
incq %rsi
callq 0x11d0
testq %rax, %rax
je 0x48d5
movq %rax, 0x18(%rbx)
testq %r14, %r14
sete %al
testq %r15, %r15
sete %cl
movq (%rbx), %rdx
movq 0x10(%rbx), %rdi
imulq %rdx, %rdi
addq 0x18(%rbx), %rdi
orb %al, %cl
jne 0x48c5
movq %r15, %rsi
movq %r14, %rdx
callq 0x1190
movq (%rbx), %rax
imulq 0x10(%rbx), %rax
addq 0x18(%rbx), %rax
movb $0x0, (%r14,%rax)
jmp 0x48cc
xorl %esi, %esi
callq 0x1120
incq 0x10(%rbx)
movl $0x1, %ebp
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/qpfiffer[P]38-Moths/src/vector.c
// Function: vector_append_ptr
inline int vector_append_ptr(vector *vec, const void *pointer) {
	if (vec == NULL)
		return 0;

	if (vec->item_size != sizeof(pointer))
		return 0;

	if (vec->count == vec->max_size) {
		vec->max_size *= 2;
		void *array = realloc(vec->items, (vec->max_size * vec->item_size));
		if (!array)
			return 0;
		vec->items = array;
	}

	memcpy(nth(vec->count), &pointer, sizeof(void *));
	vec->count++;
	return 1;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
xorl %ebp, %ebp
testq %rdi, %rdi
je 0x4944
movq %rdi, %rbx
cmpq $0x8, (%rdi)
jne 0x4944
movq %rsi, %r14
movq 0x10(%rbx), %rsi
cmpq 0x8(%rbx), %rsi
jne 0x492a
leaq (%rsi,%rsi), %rax
movq %rax, 0x8(%rbx)
movq 0x18(%rbx), %rdi
shlq $0x4, %rsi
callq 0x11d0
testq %rax, %rax
je 0x4944
movq %rax, 0x18(%rbx)
movq (%rbx), %rcx
movq 0x10(%rbx), %rsi
jmp 0x4933
movq 0x18(%rbx), %rax
movl $0x8, %ecx
imulq %rsi, %rcx
movq %r14, (%rax,%rcx)
incq 0x10(%rbx)
movl $0x1, %ebp
movl %ebp, %eax
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/qpfiffer[P]38-Moths/src/vector.c
// Function: vector_reverse
int vector_reverse(vector *vec) {
	if (vec == NULL)
		return 0;

	const size_t item_size = vec->item_size;
	unsigned int i = 0;

	unsigned char *buf = malloc(item_size);
	if (!buf)
		return 0;

	for (;i < (unsigned int)(vec->count / 2); i++) {
		const void *item = vector_get(vec, i);
		const unsigned int offset = vec->count - i - 1;
		if (!memcpy(buf, vector_get(vec, offset), item_size))
			return 0;

		if (!memcpy(nth(offset), item, item_size))
			return 0;

		if (!memcpy(nth(i), buf, item_size))
			return 0;
	}
	free(buf);

	return 1;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq $0x0, (%rsp)
testq %rdi, %rdi
je 0x4a7d
movq %rdi, %r12
movq (%rdi), %r13
movq %r13, %rdi
callq 0x11a0
testq %rax, %rax
je 0x4a7d
movq %rax, %rdi
movq 0x10(%r12), %rax
movq %rax, %rcx
shrq %rcx
testl %ecx, %ecx
je 0x4a6f
movq $-0x1, %rsi
xorl %ebx, %ebx
movq %r13, 0x8(%rsp)
movq (%r12), %r13
movq 0x8(%r12), %rcx
movq 0x18(%r12), %r15
movq %r13, %rbp
imulq %rbx, %rbp
addq %r15, %rbp
cmpq %rbx, %rcx
movl $0x0, %edx
cmovbq %rdx, %rbp
movq %rsi, 0x10(%rsp)
addl %esi, %eax
imulq %rax, %r13
addq %r15, %r13
cmpq %rax, %rcx
movq %r13, %rsi
movl $0x0, %eax
movq %rax, (%rsp)
cmovbq %rdx, %rsi
movq %rdi, %r14
movq 0x8(%rsp), %rdx
callq 0x1190
movq %r13, %rdi
movq 0x8(%rsp), %r13
movq %rbp, %rsi
movq %r13, %rdx
callq 0x1190
testq %r15, %r15
je 0x4a7d
movq 0x18(%r12), %r15
movq (%r12), %rdi
imulq %rbx, %rdi
addq %r15, %rdi
movq %r14, %rbp
movq %r14, %rsi
movq %r13, %rdx
callq 0x1190
testq %r15, %r15
je 0x4a7d
incq %rbx
movq 0x10(%r12), %rax
movq %rax, %rcx
shrq %rcx
movl %ecx, %ecx
movq 0x10(%rsp), %rsi
decq %rsi
cmpq %rcx, %rbx
movq %rbp, %rdi
jb 0x49be
callq 0x1030
movl $0x1, %eax
movq %rax, (%rsp)
movq (%rsp), %rax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/coapp-packages[P]bzip2/bzip2recover.c
// Function: bsOpenReadStream
static BitStream* bsOpenReadStream ( FILE* stream )
{
   BitStream *bs = malloc ( sizeof(BitStream) );
   if (bs == NULL) mallocFail ( sizeof(BitStream) );
   bs->handle = stream;
   bs->buffer = 0;
   bs->buffLive = 0;
   bs->mode = 'r';
   return bs;
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
movl $0x18, %edi
callq 0x10c0
testq %rax, %rax
je 0x1b60
movq %rbx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x72, 0x10(%rax)
popq %rbx
retq
callq 0x1c86
// File: /workspace/github_c_makefile_star2_O3/coapp-packages[P]bzip2/bzip2recover.c
// Function: bsGetBit
static Int32 bsGetBit ( BitStream* bs )
{
   if (bs->buffLive > 0) {
      bs->buffLive --;
      return ( ((bs->buffer) >> (bs->buffLive)) & 0x1 );
   } else {
      Int32 retVal = getc ( bs->handle );
      if ( retVal == EOF ) {
         if (errno != 0) readError();
         return 2;
      }
      bs->buffLive = 7;
      bs->buffer = retVal;
      return ( ((bs->buffer) >> 7) & 0x1 );
   }
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
movl 0xc(%rdi), %ecx
testl %ecx, %ecx
jle 0x1b82
decl %ecx
movl %ecx, 0xc(%rbx)
movl 0x8(%rbx), %edx
xorl %eax, %eax
btl %ecx, %edx
setb %al
jmp 0x1bb3
movq (%rbx), %rdi
callq 0x1140
cmpl $-0x1, %eax
je 0x1ba1
movl $0x7, 0xc(%rbx)
movl %eax, 0x8(%rbx)
shrl $0x7, %eax
andl $0x1, %eax
jmp 0x1bb3
callq 0x1040
movq %rax, %rcx
movl $0x2, %eax
cmpl $0x0, (%rcx)
jne 0x1bb5
popq %rbx
retq
callq 0x1ccf
// File: /workspace/github_c_makefile_star2_O3/coapp-packages[P]bzip2/bzip2recover.c
// Function: bsClose
static void bsClose ( BitStream* bs )
{
   Int32 retVal;

   if ( bs->mode == 'w' ) {
      while ( bs->buffLive < 8 ) {
         bs->buffLive++;
         bs->buffer <<= 1;
      };
      retVal = putc ( (UChar) (bs->buffer), bs->handle );
      if (retVal == EOF) writeError();
      bytesOut++;
      retVal = fflush ( bs->handle );
      if (retVal == EOF) writeError();
   }
   retVal = fclose ( bs->handle );
   if (retVal == EOF) {
      if (bs->mode == 'w') writeError(); else readError();
   }
   free ( bs );
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
cmpb $0x77, 0x10(%rdi)
jne 0x1c06
movl 0x8(%rbx), %eax
movl 0xc(%rbx), %ecx
cmpl $0x7, %ecx
jg 0x1be2
addl $-0x8, %ecx
addl %eax, %eax
incl %ecx
jne 0x1bd2
movl $0x8, 0xc(%rbx)
movl %eax, 0x8(%rbx)
movzbl %al, %edi
movq (%rbx), %rsi
callq 0x10a0
cmpl $-0x1, %eax
je 0x1c22
incq 0x24d7(%rip)            # 0x40d0
movq (%rbx), %rdi
callq 0x10d0
cmpl $-0x1, %eax
je 0x1c22
movq (%rbx), %rdi
callq 0x1060
cmpl $-0x1, %eax
je 0x1c1c
movq %rbx, %rdi
popq %rbx
jmp 0x1030
cmpb $0x77, 0x10(%rbx)
jne 0x1c27
callq 0x1d22
callq 0x1ccf
// File: /workspace/github_c_makefile_star2_O3/coapp-packages[P]bzip2/bzip2recover.c
// Function: bsPutBit
static void bsPutBit ( BitStream* bs, Int32 bit )
{
   if (bs->buffLive == 8) {
      Int32 retVal = putc ( (UChar) bs->buffer, bs->handle );
      if (retVal == EOF) writeError();
      bytesOut++;
      bs->buffLive = 1;
      bs->buffer = bit & 0x1;
   } else {
      bs->buffer = ( (bs->buffer << 1) | (bit & 0x1) );
      bs->buffLive++;
   };
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movl %esi, %r14d
movq %rdi, %rbx
movl 0x8(%rdi), %ecx
movl 0xc(%rdi), %eax
cmpl $0x8, %eax
jne 0x1c69
movzbl %cl, %edi
movq (%rbx), %rsi
callq 0x10a0
cmpl $-0x1, %eax
je 0x1c81
incq 0x2478(%rip)            # 0x40d0
movl $0x1, 0xc(%rbx)
andl $0x1, %r14d
movl %r14d, 0x8(%rbx)
jmp 0x1c79
andl $0x1, %r14d
leal (%r14,%rcx,2), %ecx
movl %ecx, 0x8(%rbx)
incl %eax
movl %eax, 0xc(%rbx)
addq $0x8, %rsp
popq %rbx
popq %r14
retq
callq 0x1d22
// File: /workspace/github_c_makefile_star2_O3/coapp-packages[P]bzip2/bzip2recover.c
// Function: readError
static void readError ( void )
{
   fprintf ( stderr,
             "%s: I/O error reading `%s', possible reason follows.\n",
            progName, inFileName );
   perror ( progName );
   fprintf ( stderr, "%s: warning: output file(s) may be incomplete.\n",
             progName );
   exit ( 1 );
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq 0x231e(%rip), %r14      # 0x3ff8
movq (%r14), %rdi
leaq 0x597(%rip), %rsi       # 0x227b
leaq 0x23f5(%rip), %rbx      # 0x40e0
leaq 0x338e(%rip), %rcx      # 0x5080
movq %rbx, %rdx
xorl %eax, %eax
callq 0x10b0
movq %rbx, %rdi
callq 0x10f0
movq (%r14), %rdi
leaq 0x53d(%rip), %rsi       # 0x224b
movq %rbx, %rdx
xorl %eax, %eax
callq 0x10b0
movl $0x1, %edi
callq 0x1120
// File: /workspace/github_c_makefile_star2_O3/rsa9000[P]regfanalysistools/regfwalk.c
// Function: regf_unicode2wchar
static const wchar_t *regf_unicode2wchar(const void *ptr, unsigned len)
{
#define __MAX_LEN	50
	static wchar_t __obuf[__MAX_LEN + 4 + 1];
	uint16_t __ibuf[__MAX_LEN * 2];
	unsigned __len;
	char *ibuf = (char *)__ibuf;
	char *obuf = (char *)__obuf;
	size_t ilen, olen, res;

	__len = len / 2 > __MAX_LEN ? __MAX_LEN : len / 2;

	memcpy(__ibuf, ptr, __len * sizeof(__ibuf[0]));

	ilen = __len * sizeof(__ibuf[0]);
	olen = __len * sizeof(__obuf[0]);

	iconv(st.icd, NULL, NULL, NULL, NULL);	/* Reset descriptor */

	res = iconv(st.icd, &ibuf, &ilen, &obuf, &olen);
	if (res == (size_t)-1)
		return L"<error>";

	if (__len != len / 2) {
		__obuf[__MAX_LEN + 0] = '.';
		__obuf[__MAX_LEN + 1] = '.';
		__obuf[__MAX_LEN + 2] = '.';
		__obuf[__MAX_LEN + 3] = '\0';
	} else {
		__obuf[__len] = '\0';
	}

	return __obuf;
#undef __MAX_LEN
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xe8, %rsp
movl %esi, %ebp
movq %rdi, %rsi
leaq 0x20(%rsp), %rdi
movq %rsp, %rax
movq %rdi, (%rax)
leaq 0x516a(%rip), %rbx      # 0x7140
leaq 0x18(%rsp), %r15
movq %rbx, (%r15)
movl %ebp, %eax
shrl %eax
cmpl $0x66, %ebp
movl $0x32, %r14d
cmovbl %eax, %r14d
movl %r14d, %r12d
addl %r12d, %r12d
movq %r12, %rdx
callq 0x10e0
leaq 0x10(%rsp), %r13
movq %r12, (%r13)
leaq (,%r14,4), %rax
leaq 0x8(%rsp), %r12
movq %rax, (%r12)
movq 0x50d2(%rip), %rdi      # 0x70f0
xorl %esi, %esi
xorl %edx, %edx
xorl %ecx, %ecx
xorl %r8d, %r8d
callq 0x1050
movq 0x50bd(%rip), %rdi      # 0x70f0
movq %rsp, %rsi
movq %r13, %rdx
movq %r15, %rcx
movq %r12, %r8
callq 0x1050
cmpq $-0x1, %rax
je 0x2073
cmpl $0x66, %ebp
jb 0x207c
movabsq $0x2e0000002e, %rax     # imm = 0x2E0000002E
movq %rax, 0x51a8(%rip)      # 0x7208
movl $0x2e, 0x51a6(%rip)     # 0x7210
leaq 0x51a3(%rip), %rax      # 0x7214
jmp 0x2080
leaq 0x2e32(%rip), %rbx      # 0x4eac
jmp 0x2086
leaq (%rbx,%r14,4), %rax
movl $0x0, (%rax)
movq %rbx, %rax
addq $0xe8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/rsa9000[P]regfanalysistools/regfwalk.c
// Function: regf_parse_lst
static int regf_parse_lst(const char *pref, unsigned off)
{
	const struct regf_cell *rc = st.data + off;
	const struct regf_lst *lst = (void *)rc->data;

	if (regf_cell_check_len(st.data, off, "lst", sizeof(*lst)))
		return -1;

	printf("%s%.2s.{off,len} = 0x%08X, 0x%08X\n", pref, lst->sign, off, -rc->sz);

	if (strncmp(lst->sign, "lf", 2) == 0) {
		return regf_parse_lst_lf(pref, off);
	} else if (strncmp(lst->sign, "lh", 2) == 0) {
		return regf_parse_lst_lh(pref, off);
	} else if (strncmp(lst->sign, "li", 2) == 0) {
		return regf_parse_lst_li(pref, off);
	} else if (strncmp(lst->sign, "ri", 2) == 0) {
		return regf_parse_lst_ri(pref, off);
	} else {
		PR_ERR(off, "lst", "unexpected list signature\n");
		return -1;
	}

	return 0;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movl %esi, %ebx
movq %rdi, %r14
movq 0x5054(%rip), %r15      # 0x7100
leaq 0x2c50(%rip), %rdx      # 0x4d03
movq %r15, %rdi
movl $0x4, %ecx
callq 0x340a
testl %eax, %eax
jne 0x2168
movl %ebx, %eax
addq %rax, %r15
leaq 0x4(%r15), %rdx
xorl %r8d, %r8d
subl (%r15), %r8d
leaq 0x2613(%rip), %rdi      # 0x46f1
movq %r14, %rsi
movl %ebx, %ecx
xorl %eax, %eax
callq 0x10a0
movzbl 0x4(%r15), %eax
cmpl $0x72, %eax
je 0x210f
cmpl $0x6c, %eax
jne 0x2151
cmpb $0x66, 0x5(%r15)
jne 0x2125
movq %r14, %rdi
movl %ebx, %esi
popq %rbx
popq %r14
popq %r15
jmp 0x22d0
cmpb $0x69, 0x5(%r15)
jne 0x2151
movq %r14, %rdi
movl %ebx, %esi
popq %rbx
popq %r14
popq %r15
jmp 0x2642
cmpb $0x68, 0x5(%r15)
jne 0x213b
movq %r14, %rdi
movl %ebx, %esi
popq %rbx
popq %r14
popq %r15
jmp 0x23fd
cmpb $0x69, 0x5(%r15)
jne 0x2151
movq %r14, %rdi
movl %ebx, %esi
popq %rbx
popq %r14
popq %r15
jmp 0x2525
leaq 0x25c8(%rip), %rdi      # 0x4720
leaq 0x2ba4(%rip), %rdx      # 0x4d03
movl %ebx, %esi
xorl %eax, %eax
callq 0x1339
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O3/rsa9000[P]regfanalysistools/regfwalk.c
// Function: regf_parse_vlst
static int regf_parse_vlst(const char *pref, unsigned off, unsigned num)
{
#define VLST_PR_WARN(__fmt, ...)	PR_WARN(off, "vlst", __fmt, ##__VA_ARGS__)
	const struct regf_cell *rc = st.data + off;
	const uint32_t *vals = (void *)rc->data;
	size_t pref_len = strlen(pref);
	char __pref[pref_len + 3];
	struct cell *cell;
	unsigned i;
	int res, ret = 0;

	if (regf_cell_check_len(st.data, off, "vlst", num * sizeof(vals[0])))
		return -1;

	printf("%svals.{off,len} = 0x%08X, 0x%08X\n", pref, off, -rc->sz);

	snprintf(__pref, sizeof(__pref), "%s  ", pref);

	for (i = 0; i < num; ++i) {
		printf("%svals[%u] = 0x%08X\n", pref, i, vals[i]);
		cell = cache_cell_find(vals[i]);
		if (!cell) {
			VLST_PR_WARN("could not find value cell 0x%08X\n",
				     vals[i]);
			ret = -1;
			continue;
		}
		cache_cell_updref(cell, CT_VK);
		res = regf_parse_vk(__pref, vals[i]);
		if (res) {
			VLST_PR_WARN("could not parse value key in cell 0x%08X\n",
				     vals[i]);
			ret = -1;
			continue;
		}
	}

	return ret;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movl %edx, %r13d
movl %esi, %ebx
movq %rdi, %r14
movq 0x4f6d(%rip), %r15      # 0x7100
callq 0x1080
movq %rax, %r12
movq %rsp, %rcx
addq $0x12, %rax
andq $-0x10, %rax
subq %rax, %rcx
movq %rcx, -0x40(%rbp)
movq %rcx, %rsp
movq %r13, -0x38(%rbp)
leal (,%r13,4), %ecx
leaq 0x272e(%rip), %rdx      # 0x48f1
movq %r15, %rdi
movl %ebx, -0x2c(%rbp)
movl %ebx, %esi
callq 0x340a
movl $0xffffffff, %r13d      # imm = 0xFFFFFFFF
testl %eax, %eax
jne 0x22be
movl -0x2c(%rbp), %edx
movl %edx, %eax
addq %rax, %r15
addq $0x3, %r12
xorl %r13d, %r13d
xorl %ecx, %ecx
subl (%r15), %ecx
leaq 0x26fd(%rip), %rdi      # 0x48f6
movq %r14, %rsi
xorl %eax, %eax
callq 0x10a0
leaq 0x20f2(%rip), %rdx      # 0x42fc
movq -0x40(%rbp), %rdi
movq %r12, %rsi
movq %r14, %rcx
xorl %eax, %eax
callq 0x10b0
cmpl $0x0, -0x38(%rbp)
je 0x22be
movl -0x38(%rbp), %ebx
xorl %r12d, %r12d
xorl %r13d, %r13d
movl 0x4(%r15,%r12,4), %ecx
leaq 0x26df(%rip), %rdi      # 0x4919
movq %r14, %rsi
movl %r12d, %edx
xorl %eax, %eax
callq 0x10a0
movl 0x4(%r15,%r12,4), %esi
leaq 0x4ec5(%rip), %rdi      # 0x7118
callq 0x330d
leaq 0x4ec1(%rip), %rcx      # 0x7120
cmpq %rcx, %rax
sete %cl
testq %rax, %rax
sete %dl
orb %cl, %dl
leaq 0x26ba(%rip), %rdi      # 0x492e
jne 0x2296
incl 0x24(%rax)
orb $0x40, 0x28(%rax)
movl 0x4(%r15,%r12,4), %esi
movq -0x40(%rbp), %rdi
callq 0x275f
leaq 0x26ce(%rip), %rdi      # 0x4960
testl %eax, %eax
je 0x22b2
movl 0x4(%r15,%r12,4), %ecx
movl -0x2c(%rbp), %esi
leaq 0x264c(%rip), %rdx      # 0x48f1
xorl %eax, %eax
callq 0x1339
movl $0xffffffff, %r13d      # imm = 0xFFFFFFFF
incq %r12
cmpq %r12, %rbx
jne 0x222e
movl %r13d, %eax
leaq -0x28(%rbp), %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/rsa9000[P]regfanalysistools/regfwalk.c
// Function: regf_parse_lst_lf
static int regf_parse_lst_lf(const char *pref, unsigned off)
{
#define LF_PR_WARN(__fmt, ...)	PR_WARN(off, "lf", __fmt, ##__VA_ARGS__)
	const struct regf_cell *rc = st.data + off;
	const struct regf_lst *lst = (void *)rc->data;
	const struct regf_lf_elem *elems = (void *)lst->data;
	size_t pref_len = strlen(pref);
	char __pref[pref_len + 3];
	struct cell *cell;
	int i, res, ret = 0;

	snprintf(__pref, sizeof(__pref), "%s  ", pref);

	printf("%slf.nelem = %u\n", pref, lst->nelem);
	for (i = 0; i < lst->nelem; ++i) {
		printf("%slf.elem[%u]{off,hint} = 0x%08X, %.4s\n",
		       pref, i, elems[i].off, elems[i].hint);
		cell = cache_cell_find(elems[i].off);
		if (!cell) {
			LF_PR_WARN("could not find key cell 0x%08X\n",
				   elems[i].off);
			ret = -1;
			continue;
		}
		cache_cell_updref(cell, CT_NK);
		res = regf_parse_nk(pref, elems[i].off);
		if (res) {
			LF_PR_WARN("could not parse subkey in cell 0x%08X\n",
				   elems[i].off);
			ret = -1;
			continue;
		}
	}

	return ret;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %r14
movq 0x4e18(%rip), %r12      # 0x7100
movl %esi, -0x2c(%rbp)
movl %esi, %r13d
callq 0x1080
leaq 0x3(%rax), %rsi
movq %rsp, %rdi
addq $0x12, %rax
andq $-0x10, %rax
subq %rax, %rdi
movq %rdi, %rsp
leaq 0x1fed(%rip), %rdx      # 0x42fc
xorl %r15d, %r15d
movq %r14, %rcx
xorl %eax, %eax
callq 0x10b0
movzwl 0x6(%r12,%r13), %edx
leaq 0x2421(%rip), %rdi      # 0x474a
movq %r14, %rsi
xorl %eax, %eax
callq 0x10a0
cmpw $0x0, 0x6(%r12,%r13)
je 0x23eb
leaq (%r12,%r13), %rbx
addq %r13, %r12
addq $0xc, %r12
xorl %r13d, %r13d
xorl %r15d, %r15d
movl 0x8(%rbx,%r13,8), %ecx
leaq 0x23fe(%rip), %rdi      # 0x475b
movq %r14, %rsi
movl %r13d, %edx
movq %r12, %r8
xorl %eax, %eax
callq 0x10a0
movl 0x8(%rbx,%r13,8), %esi
leaq 0x4d9f(%rip), %rdi      # 0x7118
callq 0x330d
leaq 0x4d9b(%rip), %rcx      # 0x7120
cmpq %rcx, %rax
sete %cl
testq %rax, %rax
sete %dl
orb %cl, %dl
leaq 0x23e9(%rip), %rdi      # 0x4783
jne 0x23bb
incl 0x24(%rax)
orb $0x2, 0x28(%rax)
movl 0x8(%rbx,%r13,8), %esi
movq %r14, %rdi
callq 0x1a02
leaq 0x23fc(%rip), %rdi      # 0x47b3
testl %eax, %eax
je 0x23d7
movl 0x8(%rbx,%r13,8), %ecx
movl -0x2c(%rbp), %esi
leaq 0x234a(%rip), %rdx      # 0x4714
xorl %eax, %eax
callq 0x1339
movl $0xffffffff, %r15d      # imm = 0xFFFFFFFF
incq %r13
movzwl 0x6(%rbx), %eax
addq $0x8, %r12
cmpq %rax, %r13
jb 0x2351
movl %r15d, %eax
leaq -0x28(%rbp), %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/rsa9000[P]regfanalysistools/regfwalk.c
// Function: regf_parse_lst_lh
static int regf_parse_lst_lh(const char *pref, unsigned off)
{
#define LH_PR_WARN(__fmt, ...)	PR_WARN(off, "lh", __fmt, ##__VA_ARGS__)
	const struct regf_cell *rc = st.data + off;
	const struct regf_lst *lst = (void *)rc->data;
	const struct regf_lh_elem *elems = (void *)lst->data;
	size_t pref_len = strlen(pref);
	char __pref[pref_len + 3];
	struct cell *cell;
	int i, res, ret = 0;

	snprintf(__pref, sizeof(__pref), "%s  ", pref);

	printf("%slh.nelem = %u\n", pref, lst->nelem);
	for (i = 0; i < lst->nelem; ++i) {
		printf("%slh.elem[%u]{off,hash} = 0x%08X, 0x%08X\n",
		       pref, i, elems[i].off, elems[i].hash);
		cell = cache_cell_find(elems[i].off);
		if (!cell) {
			LH_PR_WARN("could not find key cell 0x%08X\n",
				   elems[i].off);
			ret = -1;
			continue;
		}
		cache_cell_updref(cell, CT_NK);
		res = regf_parse_nk(pref, elems[i].off);
		if (res) {
			LH_PR_WARN("could not parse subkey in cell 0x%08X\n",
				   elems[i].off);
			ret = -1;
			continue;
		}
	}

	return ret;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %r14
movq 0x4ceb(%rip), %rbx      # 0x7100
movl %esi, -0x2c(%rbp)
movl %esi, %r12d
callq 0x1080
leaq 0x3(%rax), %rsi
movq %rsp, %rdi
addq $0x12, %rax
andq $-0x10, %rax
subq %rax, %rdi
movq %rdi, %rsp
leaq 0x1ec0(%rip), %rdx      # 0x42fc
xorl %r15d, %r15d
movq %r14, %rcx
xorl %eax, %eax
callq 0x10b0
movzwl 0x6(%rbx,%r12), %edx
leaq 0x2394(%rip), %rdi      # 0x47ea
movq %r14, %rsi
xorl %eax, %eax
callq 0x10a0
cmpw $0x0, 0x6(%rbx,%r12)
je 0x2513
leaq (%rbx,%r12), %r13
addq %r12, %rbx
addq $0x8, %rbx
xorl %r12d, %r12d
xorl %r15d, %r15d
movl (%rbx,%r12,8), %ecx
movl 0x4(%rbx,%r12,8), %r8d
leaq 0x236d(%rip), %rdi      # 0x47fb
movq %r14, %rsi
movl %r12d, %edx
xorl %eax, %eax
callq 0x10a0
movl (%rbx,%r12,8), %esi
leaq 0x4c72(%rip), %rdi      # 0x7118
callq 0x330d
leaq 0x4c6e(%rip), %rcx      # 0x7120
cmpq %rcx, %rax
sete %cl
testq %rax, %rax
sete %dl
orb %cl, %dl
leaq 0x22bc(%rip), %rdi      # 0x4783
jne 0x24e7
incl 0x24(%rax)
orb $0x2, 0x28(%rax)
movl (%rbx,%r12,8), %esi
movq %r14, %rdi
callq 0x1a02
leaq 0x22d0(%rip), %rdi      # 0x47b3
testl %eax, %eax
je 0x2502
movl (%rbx,%r12,8), %ecx
movl -0x2c(%rbp), %esi
leaq 0x2222(%rip), %rdx      # 0x4717
xorl %eax, %eax
callq 0x1339
movl $0xffffffff, %r15d      # imm = 0xFFFFFFFF
incq %r12
movzwl 0x6(%r13), %eax
cmpq %rax, %r12
jb 0x247e
movl %r15d, %eax
leaq -0x28(%rbp), %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/rsa9000[P]regfanalysistools/regfwalk.c
// Function: regf_parse_lst_li
static int regf_parse_lst_li(const char *pref, unsigned off)
{
#define LI_PR_WARN(__fmt, ...)	PR_WARN(off, "li", __fmt, ##__VA_ARGS__)
	const struct regf_cell *rc = st.data + off;
	const struct regf_lst *lst = (void *)rc->data;
	const struct regf_li_elem *elems = (void *)lst->data;
	size_t pref_len = strlen(pref);
	char __pref[pref_len + 3];
	struct cell *cell;
	int i, res, ret = 0;

	snprintf(__pref, sizeof(__pref), "%s  ", pref);

	printf("%sli.nelem = %u\n", pref, lst->nelem);
	for (i = 0; i < lst->nelem; ++i) {
		printf("%sli.elem[%u].off = 0x%08X\n",
		       pref, i, elems[i].off);
		cell = cache_cell_find(elems[i].off);
		if (!cell) {
			LI_PR_WARN("could not find key cell 0x%08X\n",
				   elems[i].off);
			ret = -1;
			continue;
		}
		cache_cell_updref(cell, CT_NK);
		res = regf_parse_nk(pref, elems[i].off);
		if (res) {
			LI_PR_WARN("could not parse subkey in cell 0x%08X\n",
				   elems[i].off);
			ret = -1;
			continue;
		}
	}

	return ret;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %esi, %ebx
movq %rdi, %r14
movq 0x4bc1(%rip), %r13      # 0x7100
movl %esi, %r12d
callq 0x1080
leaq 0x3(%rax), %rsi
movq %rsp, %rdi
addq $0x12, %rax
andq $-0x10, %rax
subq %rax, %rdi
movq %rdi, %rsp
leaq 0x1d99(%rip), %rdx      # 0x42fc
xorl %r15d, %r15d
movq %r14, %rcx
xorl %eax, %eax
callq 0x10b0
movzwl 0x6(%r13,%r12), %edx
leaq 0x22a8(%rip), %rdi      # 0x4825
movq %r14, %rsi
xorl %eax, %eax
callq 0x10a0
cmpw $0x0, 0x6(%r13,%r12)
je 0x2630
addq %r12, %r13
xorl %r12d, %r12d
xorl %r15d, %r15d
movl 0x8(%r13,%r12,4), %ecx
leaq 0x228d(%rip), %rdi      # 0x4836
movq %r14, %rsi
movl %r12d, %edx
xorl %eax, %eax
callq 0x10a0
movl 0x8(%r13,%r12,4), %esi
leaq 0x4b56(%rip), %rdi      # 0x7118
callq 0x330d
leaq 0x4b52(%rip), %rcx      # 0x7120
cmpq %rcx, %rax
sete %cl
testq %rax, %rax
sete %dl
orb %cl, %dl
leaq 0x21a0(%rip), %rdi      # 0x4783
jne 0x2604
incl 0x24(%rax)
orb $0x2, 0x28(%rax)
movl 0x8(%r13,%r12,4), %esi
movq %r14, %rdi
callq 0x1a02
leaq 0x21b3(%rip), %rdi      # 0x47b3
testl %eax, %eax
je 0x261f
movl 0x8(%r13,%r12,4), %ecx
movl %ebx, %esi
leaq 0x2108(%rip), %rdx      # 0x471a
xorl %eax, %eax
callq 0x1339
movl $0xffffffff, %r15d      # imm = 0xFFFFFFFF
incq %r12
movzwl 0x6(%r13), %eax
cmpq %rax, %r12
jb 0x259d
movl %r15d, %eax
leaq -0x28(%rbp), %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/rsa9000[P]regfanalysistools/regfwalk.c
// Function: regf_parse_lst_ri
static int regf_parse_lst_ri(const char *pref, unsigned off)
{
#define RI_PR_WARN(__fmt, ...)	PR_WARN(off, "ri", __fmt, ##__VA_ARGS__)
	const struct regf_cell *rc = st.data + off;
	const struct regf_lst *lst = (void *)rc->data;
	const struct regf_ri_elem *elems = (void *)lst->data;
	size_t pref_len = strlen(pref);
	char __pref[pref_len + 3];
	struct cell *cell;
	int i, res, ret = 0;

	snprintf(__pref, sizeof(__pref), "%s  ", pref);

	printf("%sri.nelem = %u\n", pref, lst->nelem);
	for (i = 0; i < lst->nelem; ++i) {
		printf("%sri.elem[%u].off = 0x%08X\n",
		       pref, i, elems[i].off);
		cell = cache_cell_find(elems[i].off);
		if (!cell) {
			RI_PR_WARN("could not find keys list cell 0x%08X\n",
				   elems[i].off);
			ret = -1;
			continue;
		}
		cache_cell_updref(cell, CT_LST);
		res = regf_parse_lst(pref, elems[i].off);
		if (res) {
			RI_PR_WARN("could not parse subkey list in cell 0x%08X\n",
				   elems[i].off);
			ret = -1;
			continue;
		}
	}

	return ret;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %esi, %ebx
movq %rdi, %r14
movq 0x4aa4(%rip), %r13      # 0x7100
movl %esi, %r12d
callq 0x1080
leaq 0x3(%rax), %rsi
movq %rsp, %rdi
addq $0x12, %rax
andq $-0x10, %rax
subq %rax, %rdi
movq %rdi, %rsp
leaq 0x1c7c(%rip), %rdx      # 0x42fc
xorl %r15d, %r15d
movq %r14, %rcx
xorl %eax, %eax
callq 0x10b0
movzwl 0x6(%r13,%r12), %edx
leaq 0x21b8(%rip), %rdi      # 0x4852
movq %r14, %rsi
xorl %eax, %eax
callq 0x10a0
cmpw $0x0, 0x6(%r13,%r12)
je 0x274d
addq %r12, %r13
xorl %r12d, %r12d
xorl %r15d, %r15d
movl 0x8(%r13,%r12,4), %ecx
leaq 0x219d(%rip), %rdi      # 0x4863
movq %r14, %rsi
movl %r12d, %edx
xorl %eax, %eax
callq 0x10a0
movl 0x8(%r13,%r12,4), %esi
leaq 0x4a39(%rip), %rdi      # 0x7118
callq 0x330d
leaq 0x4a35(%rip), %rcx      # 0x7120
cmpq %rcx, %rax
sete %cl
testq %rax, %rax
sete %dl
orb %cl, %dl
leaq 0x217f(%rip), %rdi      # 0x487f
jne 0x2721
incl 0x24(%rax)
orb $0x10, 0x28(%rax)
movl 0x8(%r13,%r12,4), %esi
movq %r14, %rdi
callq 0x209b
leaq 0x2198(%rip), %rdi      # 0x48b5
testl %eax, %eax
je 0x273c
movl 0x8(%r13,%r12,4), %ecx
movl %ebx, %esi
leaq 0x1fee(%rip), %rdx      # 0x471d
xorl %eax, %eax
callq 0x1339
movl $0xffffffff, %r15d      # imm = 0xFFFFFFFF
incq %r12
movzwl 0x6(%r13), %eax
cmpq %rax, %r12
jb 0x26ba
movl %r15d, %eax
leaq -0x28(%rbp), %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/rsa9000[P]regfanalysistools/regfwalk.c
// Function: regf_print_data
static int regf_print_data(const char *pref, const void *p, unsigned type,
			   unsigned len)
{
	switch (type) {
	case REGF_VK_T_DWORD:
		printf("%sdword: %s\n", pref, regf_dword2str(p, len));
		break;
	case REGF_VK_T_QWORD:
		printf("%sqword: %s\n", pref, regf_qword2str(p, len));
		break;
	case REGF_VK_T_SZ:
		printf("%sstr: %ls\n", pref, regf_unicode2wchar(p, len));
		break;
	case REGF_VK_T_EXPAND_SZ:
		printf("%sestr: %ls\n", pref, regf_unicode2wchar(p, len));
		break;
	default:
		printf("%shex: %s\n", pref, regf_hexdump(p, len));
		break;
	}

	return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rsi, %r14
movq %rdi, %rbx
cmpl $0x3, %edx
jg 0x2bf3
cmpl $0x1, %edx
je 0x2ccc
cmpl $0x2, %edx
jne 0x2c3a
movq %r14, %rdi
movl %ecx, %esi
callq 0x1fae
leaq 0x2014(%rip), %rdi      # 0x4c02
jmp 0x2cdd
cmpl $0xb, %edx
je 0x2ce5
cmpl $0x4, %edx
jne 0x2c3a
testl %ecx, %ecx
je 0x2d13
cmpl $0x4, %ecx
jne 0x2d25
movl (%r14), %ecx
leaq 0x4704(%rip), %r14      # 0x7320
leaq 0x1ff9(%rip), %rdx      # 0x4c1c
movl $0x20, %esi
movq %r14, %rdi
movl %ecx, %r8d
xorl %eax, %eax
callq 0x10b0
jmp 0x2d2c
testl %ecx, %ecx
je 0x2cb9
movq %rbx, 0x10(%rsp)
cmpl $0x10, %ecx
movl $0x10, %r13d
movl %ecx, 0xc(%rsp)
cmovbl %ecx, %r13d
leaq 0x4725(%rip), %rbx      # 0x7380
leaq 0x1fe6(%rip), %r15      # 0x4c48
xorl %ebp, %ebp
movq %rbx, %rdi
movq %rdi, %r12
movq %rbx, %rsi
subq %rdi, %rsi
addq $0x35, %rsi
movzbl (%r14,%rbp), %ecx
movq %r15, %rdx
xorl %eax, %eax
callq 0x10b0
movslq %eax, %rdi
addq %r12, %rdi
incq %rbp
cmpq %rbp, %r13
jne 0x2c67
cmpl $0x11, 0xc(%rsp)
movq 0x10(%rsp), %rbx
jb 0x2cb9
leaq 0x46dc(%rip), %rsi      # 0x7380
subq %rdi, %rsi
addq $0x35, %rsi
leaq 0x1f9c(%rip), %rdx      # 0x4c4e
xorl %eax, %eax
callq 0x10b0
leaq 0x1f4f(%rip), %rdi      # 0x4c0f
leaq 0x46ba(%rip), %rdx      # 0x7381
movq %rbx, %rsi
jmp 0x2d49
movq %r14, %rdi
movl %ecx, %esi
callq 0x1fae
leaq 0x1f19(%rip), %rdi      # 0x4bf6
movq %rbx, %rsi
movq %rax, %rdx
jmp 0x2d49
testl %ecx, %ecx
je 0x2d1c
cmpl $0x8, %ecx
jne 0x2d35
movq (%r14), %rcx
leaq 0x4648(%rip), %r14      # 0x7340
leaq 0x1f3a(%rip), %rdx      # 0x4c39
movl $0x40, %esi
movq %r14, %rdi
movq %rcx, %r8
xorl %eax, %eax
callq 0x10b0
jmp 0x2d3c
leaq 0x1f00(%rip), %r14      # 0x4c1a
jmp 0x2d2c
leaq 0x1ef7(%rip), %r14      # 0x4c1a
jmp 0x2d3c
leaq 0x1efc(%rip), %r14      # 0x4c28
leaq 0x1ea9(%rip), %rdi      # 0x4bdc
jmp 0x2d43
leaq 0x1eec(%rip), %r14      # 0x4c28
leaq 0x1ea6(%rip), %rdi      # 0x4be9
movq %rbx, %rsi
movq %r14, %rdx
xorl %eax, %eax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x10a0
nop
// File: /workspace/github_c_makefile_star2_O3/rsa9000[P]regfanalysistools/rbtree.c
// Function: rbtree_predecessor
struct rbtree_head *rbtree_predecessor(const struct rbtree *t,
				       const struct rbtree_head *node)
{
	struct rbtree_head *tmp;

	if (!rbt_is_nil(t, node->left))
		return rbtree_maximum(t, node->left);

	tmp = rbt_get_p(node);
	while (!rbt_is_nil(t, tmp) && node == tmp->left) {
		node = tmp;
		tmp = rbt_get_p(tmp);
	}

	return tmp;
}

// Assembly:
movq 0x8(%rsi), %rcx
addq $0x8, %rdi
cmpq %rcx, %rdi
je 0x2db9
movq %rcx, %rax
movq 0x10(%rcx), %rcx
cmpq %rcx, %rdi
jne 0x2da2
jmp 0x2dc5
cmpq 0x8(%rax), %rsi
movq %rax, %rsi
jne 0x2dc5
movq (%rsi), %rax
andq $-0x2, %rax
cmpq %rax, %rcx
jne 0x2db0
retq
// File: /workspace/github_c_makefile_star2_O3/rsa9000[P]regfanalysistools/rbtree.c
// Function: rbtree_successor
struct rbtree_head *rbtree_successor(const struct rbtree *t,
				     const struct rbtree_head *node)
{
	struct rbtree_head *tmp;

	if (!rbt_is_nil(t, node->right))
		return rbtree_minimum(t, node->right);

	tmp = rbt_get_p(node);
	while (!rbt_is_nil(t, tmp) && node == tmp->right) {
		node = tmp;
		tmp = rbt_get_p(tmp);
	}

	return tmp;
}

// Assembly:
movq 0x10(%rsi), %rcx
addq $0x8, %rdi
cmpq %rcx, %rdi
je 0x2dea
movq %rcx, %rax
movq 0x8(%rcx), %rcx
cmpq %rcx, %rdi
jne 0x2dd3
jmp 0x2df6
cmpq 0x10(%rax), %rsi
movq %rax, %rsi
jne 0x2df6
movq (%rsi), %rax
andq $-0x2, %rax
cmpq %rax, %rcx
jne 0x2de1
retq
// File: /workspace/github_c_makefile_star2_O3/rsa9000[P]regfanalysistools/rbtree.c
// Function: rbtree_left_rotate
void rbtree_left_rotate(struct rbtree *t, struct rbtree_head *node)
{
	struct rbtree_head *n;

	if (rbt_is_nil(t, node->right))
		return;

	n = node->right;

	node->right = n->left;
	if (!rbt_is_nil(t, n->left))
		rbt_set_p(n->left, node);

	rbt_set_p(n, rbt_get_p(node));
	if (rbt_is_nil(t, rbt_get_p(node))) {
		t->rbt_root = n;
	} else {
		if (rbt_get_p(node)->left == node)
			rbt_get_p(node)->left = n;
		else
			rbt_get_p(node)->right = n;
	}

	n->left = node;
	rbt_set_p(node, n);
}

// Assembly:
movq 0x10(%rsi), %rax
leaq 0x8(%rdi), %rcx
cmpq %rax, %rcx
je 0x2e6c
movq 0x8(%rax), %rdx
movq %rdx, 0x10(%rsi)
cmpq %rdx, %rcx
je 0x2e25
movq %rsi, %r8
andq $-0x2, %r8
movq (%rdx), %r9
andl $0x1, %r9d
orq %r8, %r9
movq %r9, (%rdx)
movq (%rsi), %rdx
andq $-0x2, %rdx
movq (%rax), %r8
andl $0x1, %r8d
orq %rdx, %r8
movq %r8, (%rax)
movq (%rsi), %rdx
movq %rdx, %r8
andq $-0x2, %r8
cmpq %r8, %rcx
je 0x2e58
leaq 0x8(%r8), %rcx
leaq 0x10(%r8), %rdi
cmpq %rsi, 0x8(%r8)
cmoveq %rcx, %rdi
movq %rax, (%rdi)
movq %rsi, 0x8(%rax)
andq $-0x2, %rax
andl $0x1, %edx
orq %rax, %rdx
movq %rdx, (%rsi)
retq