LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/modules/bmff.c
// Function: do_box_ulst
static void do_box_ulst(deark *c, lctx *d, struct de_boxesctx *bctx)
{
	struct de_boxdata *curbox = bctx->curbox;
	i64 pos = curbox->payload_pos;
	i64 nuuids;
	i64 k;
	u8 ubuf[16];
	char uuid_string[50];

	nuuids = dbuf_getu16be_p(bctx->f, &pos);
	de_dbg(c, "number of UUIDs: %d", (int)nuuids);

	for(k=0; k<nuuids; k++) {
		if(pos+16 > curbox->payload_pos + curbox->payload_len) break;
		dbuf_read(bctx->f, ubuf, pos, 16);
		fmtutil_render_uuid(c, ubuf, uuid_string, sizeof(uuid_string));
		de_dbg(c, "UUID[%d]: {%s}", (int)k, uuid_string);
		pos += 16;
	}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x58, %rsp
movq %rdi, %r14
movq 0x28(%rdx), %rbx
movq 0x38(%rbx), %rax
movq %rsp, %rsi
movq %rax, (%rsi)
movq %rdx, 0x8(%rsp)
movq 0x10(%rdx), %rdi
callq 0xef193
movq %rax, %r15
leaq 0xe8dad(%rip), %rsi     # 0x11628c
movq %r14, %rdi
movl %r15d, %edx
xorl %eax, %eax
callq 0xe9226
testq %r15, %r15
jle 0x2d55e
leaq 0x10(%rsp), %r12
leaq 0x20(%rsp), %r13
xorl %ebp, %ebp
movq (%rsp), %rdx
leaq 0x10(%rdx), %rax
movq 0x40(%rbx), %rcx
addq 0x38(%rbx), %rcx
cmpq %rcx, %rax
jg 0x2d55e
movq 0x8(%rsp), %rax
movq 0x10(%rax), %rdi
movl $0x10, %ecx
movq %r12, %rsi
callq 0xeeee8
movl $0x32, %ecx
movq %r14, %rdi
movq %r12, %rsi
movq %r13, %rdx
callq 0xf8559
movq %r14, %rdi
leaq 0xe8d5b(%rip), %rsi     # 0x1162a0
movl %ebp, %edx
movq %r13, %rcx
xorl %eax, %eax
callq 0xe9226
addq $0x10, (%rsp)
incq %rbp
cmpq %rbp, %r15
jne 0x2d4fd
addq $0x58, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/modules/bmff.c
// Function: do_box_ispe
static void do_box_ispe(deark *c, lctx *d, struct de_boxesctx *bctx)
{
	struct de_boxdata *curbox = bctx->curbox;
	i64 pos = curbox->payload_pos;
	i64 w, h;

	if(curbox->payload_len<12) return;
	do_read_version_and_flags(c, d, bctx, NULL, NULL, 1);
	pos += 4;
	w = dbuf_getu32be_p(bctx->f, &pos);
	h = dbuf_getu32be_p(bctx->f, &pos);
	de_dbg_dimensions(c, w, h);
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq 0x28(%rdx), %rax
movq 0x38(%rax), %rsi
movq %rsi, (%rsp)
cmpq $0xc, 0x40(%rax)
jl 0x2d62e
movq %rdx, %r14
movq %rdi, %rbx
movq 0x10(%rdx), %rdi
callq 0xef32a
movl %eax, %ecx
andl $0xffffff, %ecx         # imm = 0xFFFFFF
shrl $0x18, %eax
leaq 0xe8496(%rip), %rsi     # 0x115a88
movq %rbx, %rdi
movl %eax, %edx
xorl %eax, %eax
callq 0xe9226
movq %rsp, %r15
addq $0x4, (%r15)
movq 0x10(%r14), %rdi
movq %r15, %rsi
callq 0xef34e
movq %rax, %r12
movq 0x10(%r14), %rdi
movq %r15, %rsi
callq 0xef34e
movq %rbx, %rdi
movq %r12, %rsi
movq %rax, %rdx
callq 0xe9b05
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/modules/bmff.c
// Function: apply_brand
static void apply_brand(deark *c, lctx *d, u32 brand_id)
{
	switch(brand_id) {
	case BRAND_jp2:
		d->is_jp2_jpx_jpm = 1;
		break;
	case BRAND_jpx:
		d->is_jpx = 1;
		d->is_jp2_jpx_jpm = 1;
		break;
	case BRAND_jpm:
		d->is_jpm = 1;
		d->is_jp2_jpx_jpm = 1;
		break;
	case BRAND_mjp2:
	case BRAND_mj2s:
		d->is_bmff = 1;
		d->is_mj2 = 1;
		break;
	case BRAND_isom:
	case BRAND_mp41:
	case BRAND_mp42:
	case BRAND_M4A:
	case BRAND_qt:
		d->is_bmff = 1;
		break;
	case BRAND_mif1:
	case BRAND_heic:
		d->is_heif = 1;
		break;
	default:
		if((brand_id>>16) == 0x3367) { // "3g??"
			d->is_bmff = 1;
		}
	}
}

// Assembly:
cmpl $0x6d696630, %esi       # imm = 0x6D696630
jg 0x2d664
cmpl $0x6a70321f, %esi       # imm = 0x6A70321F
jg 0x2d68d
cmpl $0x4d344120, %esi       # imm = 0x4D344120
je 0x2d6cd
cmpl $0x68656963, %esi       # imm = 0x68656963
je 0x2d6d2
cmpl $0x69736f6d, %esi       # imm = 0x69736F6D
je 0x2d6cd
jmp 0x2d6bf
cmpl $0x6d703430, %esi       # imm = 0x6D703430
jg 0x2d6ac
cmpl $0x6d696631, %esi       # imm = 0x6D696631
je 0x2d6d2
cmpl $0x6d6a3273, %esi       # imm = 0x6D6A3273
je 0x2d684
cmpl $0x6d6a7032, %esi       # imm = 0x6D6A7032
jne 0x2d6bf
movb $0x1, %al
movb %al, 0x4(%rdi)
movb %al, 0x8(%rdi)
retq
cmpl $0x6a703220, %esi       # imm = 0x6A703220
je 0x2d6d7
cmpl $0x6a706d20, %esi       # imm = 0x6A706D20
je 0x2d6dc
cmpl $0x6a707820, %esi       # imm = 0x6A707820
jne 0x2d6bf
movw $0x101, 0x5(%rdi)       # imm = 0x101
retq
leal -0x6d703431(%rsi), %eax
cmpl $0x2, %eax
jb 0x2d6cd
cmpl $0x71742020, %esi       # imm = 0x71742020
je 0x2d6cd
andl $0xffff0000, %esi       # imm = 0xFFFF0000
cmpl $0x33670000, %esi       # imm = 0x33670000
jne 0x2d6d6
movb $0x1, 0x4(%rdi)
retq
movb $0x1, 0x9(%rdi)
retq
movb $0x1, 0x5(%rdi)
retq
movb $0x1, %al
movb %al, 0x7(%rdi)
movb %al, 0x5(%rdi)
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/modules/bmff.c
// Function: do_simple_int_table
static void do_simple_int_table(deark *c, lctx *d, struct de_boxesctx *bctx,
	i64 pos1, i64 e_count, i64 e_size,
	const char *s1, const char *s2)
{
	i64 bytesleft;
	i64 e_to_print;
	i64 k;
	struct de_boxdata *curbox = bctx->curbox;
	i64 pos = pos1;

	if(e_count<=0) return;
	bytesleft = curbox->payload_pos + curbox->payload_len - pos;
	if(bytesleft < e_size*e_count) return;

	e_to_print = de_min_int(e_count, d->max_entries_to_print);

	for(k=0; k<e_to_print; k++) {
		i64 n;

		if(e_size==8) {
			n = dbuf_geti64be(bctx->f, pos); pos += 8;
		}
		else {
			n = dbuf_getu32be_p(bctx->f, &pos);
		}

		de_dbg(c, "%s[%"I64_FMT"]: %s=%"I64_FMT, s1, k, s2, n);
	}
	if(e_to_print < e_count) {
		de_dbg(c, "[%"I64_FMT" more %s(s) omitted, starting at %"I64_FMT"]",
			e_count-e_to_print, s1, pos);
	}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq 0x28(%rdx), %rax
movq %rcx, 0x8(%rsp)
testq %r8, %r8
jle 0x2d7c1
movq %r9, %r15
movq %rdx, %r12
movq 0x38(%rax), %rdx
subq %rcx, %rdx
addq 0x40(%rax), %rdx
movq %r9, %rax
imulq %r8, %rax
cmpq %rax, %rdx
jl 0x2d7c1
movq %rdi, %r14
movq 0x10(%rsi), %rsi
movq %r8, 0x10(%rsp)
movq %r8, %rdi
callq 0xea792
movq %rax, %rbp
testq %rax, %rax
jle 0x2d79c
leaq 0xe8358(%rip), %r13     # 0x115aa1
xorl %ebx, %ebx
cmpq $0x8, %r15
jne 0x2d768
movq 0x10(%r12), %rdi
movq 0x8(%rsp), %rsi
callq 0xef4c3
addq $0x8, 0x8(%rsp)
jmp 0x2d777
movq 0x10(%r12), %rdi
leaq 0x8(%rsp), %rsi
callq 0xef34e
movq %r14, %rdi
movq %r13, %rsi
movq 0x50(%rsp), %rdx
movq %rbx, %rcx
movq 0x58(%rsp), %r8
movq %rax, %r9
xorl %eax, %eax
callq 0xe9226
incq %rbx
cmpq %rbx, %rbp
jne 0x2d74b
movq 0x10(%rsp), %rdx
subq %rbp, %rdx
jle 0x2d7c1
movq 0x8(%rsp), %r8
leaq 0xe82ff(%rip), %rsi     # 0x115ab1
movq %r14, %rdi
movq 0x50(%rsp), %rcx
xorl %eax, %eax
callq 0xe9226
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/modules/bmff.c
// Function: format_jp2_res
static void format_jp2_res(char *buf, size_t buflen,
	i64 num, i64 denom, int exponent)
{
	char descr[100];

	if(denom != 0 && exponent >= -POW10_MAX_E && exponent <= POW10_MAX_E) {
		double dpm, dpi;

		dpm = ((double)num / (double)denom) * limited_pow10(exponent);
		dpi = dpm * 0.0254;
		de_snprintf(descr, sizeof(descr),  " = %f points/meter (%f dpi)", dpm, dpi);
	}
	else {
		descr[0] = '\0';
	}
	de_snprintf(buf, buflen, "(%"I64_FMT",%"I64_FMT",%d)%s",
		num, denom, exponent, descr);
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x78, %rsp
movl %ecx, %ebx
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %r12
testq %rdx, %rdx
sete %al
leal 0xc(%rbx), %ecx
cmpl $0x19, %ecx
setae %cl
orb %al, %cl
jne 0x2d82b
cvtsi2sd %r15, %xmm0
cvtsi2sd %r14, %xmm1
divsd %xmm1, %xmm0
testl %ebx, %ebx
jle 0x2d832
leal 0x1(%rbx), %ecx
movl $0x1, %eax
addq %rax, %rax
leaq (%rax,%rax,4), %rax
decl %ecx
cmpl $0x1, %ecx
jg 0x2d813
xorps %xmm1, %xmm1
cvtsi2sd %rax, %xmm1
jmp 0x2d83a
movb $0x0, 0x10(%rsp)
jmp 0x2d862
movsd 0xe7a7e(%rip), %xmm1    # 0x1152b8
mulsd %xmm1, %xmm0
movsd 0xe7a7a(%rip), %xmm1    # 0x1152c0
mulsd %xmm0, %xmm1
leaq 0xe88f7(%rip), %rdx     # 0x116148
leaq 0x10(%rsp), %rdi
movl $0x64, %esi
movb $0x2, %al
callq 0xe8d67
leaq 0x10(%rsp), %rax
movq %rax, (%rsp)
leaq 0xe88f2(%rip), %rdx     # 0x116164
movl $0xa0, %esi
movq %r12, %rdi
movq %r15, %rcx
movq %r14, %r8
movl %ebx, %r9d
xorl %eax, %eax
callq 0xe8d67
addq $0x78, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
nop
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/modules/apple2-dsk.c
// Function: de_module_apple2_dsk
void de_module_apple2_dsk(deark *c, struct deark_module_info *mi)
{
	mi->id = "apple2_dsk";
	mi->desc = "Apple II floppy disk image";
	mi->run_fn = de_run_apple2_dsk;
	mi->identify_fn = de_identify_apple2_dsk;
}

// Assembly:
leaq 0xe8ba9(%rip), %rax     # 0x116448
movq %rax, (%rsi)
leaq 0xe8baa(%rip), %rax     # 0x116453
movq %rax, 0x8(%rsi)
leaq 0x10(%rip), %rax        # 0x2d8c4
movq %rax, 0x18(%rsi)
leaq 0xa03(%rip), %rax       # 0x2e2c2
movq %rax, 0x20(%rsi)
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/modules/apple2-dsk.c
// Function: de_identify_apple2_dsk
static int de_identify_apple2_dsk(deark *c)
{
	int has_sig;

	if(c->infile->len<143358 || c->infile->len>143362) return 0;
	if(!test_VTOC(c, 17*16*256)) return 0;
	has_sig = !dbuf_memcmp(c->infile, 0, (const u8*)"\x01\xa5\x27\xc9\x09\xd0", 6);
	if(has_sig) return 100;
	return 60;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %r14
movq 0x18(%rdi), %rdi
movq $-0x23003, %rax         # imm = 0xFFFDCFFD
addq 0x18(%rdi), %rax
xorl %ebx, %ebx
cmpq $-0x5, %rax
jb 0x2e34d
movl $0x11027, %esi          # imm = 0x11027
callq 0xef0d5
cmpb $0x7a, %al
jne 0x2e34d
movq 0x18(%r14), %rdi
movl $0x11034, %esi          # imm = 0x11034
callq 0xef0d5
cmpb $0x23, %al
jne 0x2e34d
movq 0x18(%r14), %rdi
movl $0x11035, %esi          # imm = 0x11035
callq 0xef0d5
cmpb $0x10, %al
jne 0x2e34d
movq 0x18(%r14), %rdi
movl $0x11036, %esi          # imm = 0x11036
callq 0xef1ca
cmpl $0x100, %eax            # imm = 0x100
jne 0x2e34d
movq 0x18(%r14), %rdi
leaq 0xe8427(%rip), %rdx     # 0x116759
movl $0x6, %ecx
xorl %esi, %esi
callq 0xf025e
testl %eax, %eax
movl $0x64, %eax
movl $0x3c, %ebx
cmovel %eax, %ebx
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/modules/apple2-dsk.c
// Function: de_module_woz
void de_module_woz(deark *c, struct deark_module_info *mi)
{
	mi->id = "woz";
	mi->desc = "WOZ floppy disk image";
	mi->desc2 = "metadata only";
	mi->run_fn = de_run_woz;
	mi->identify_fn = de_identify_woz;
}

// Assembly:
leaq 0xe8110(%rip), %rax     # 0x11646e
movq %rax, (%rsi)
leaq 0xe810a(%rip), %rax     # 0x116472
movq %rax, 0x8(%rsi)
leaq 0xe8115(%rip), %rax     # 0x116488
movq %rax, 0x10(%rsi)
leaq 0x10(%rip), %rax        # 0x2e38e
movq %rax, 0x18(%rsi)
leaq 0xc(%rip), %rax         # 0x2e395
movq %rax, 0x20(%rsi)
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/modules/apple2-dsk.c
// Function: de_module_moof
void de_module_moof(deark *c, struct deark_module_info *mi)
{
	mi->id = "moof";
	mi->desc = "MOOF floppy disk image";
	mi->desc2 = "metadata only";
	mi->run_fn = de_run_moof;
	mi->identify_fn = de_identify_moof;
}

// Assembly:
leaq 0xe80a6(%rip), %rax     # 0x116496
movq %rax, (%rsi)
leaq 0xe80a1(%rip), %rax     # 0x11649b
movq %rax, 0x8(%rsi)
leaq 0xe8083(%rip), %rax     # 0x116488
movq %rax, 0x10(%rsi)
leaq 0x10(%rip), %rax        # 0x2e420
movq %rax, 0x18(%rsi)
leaq 0xc(%rip), %rax         # 0x2e427
movq %rax, 0x20(%rsi)
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/modules/apple2-dsk.c
// Function: claim_sector
static int claim_sector(deark *c, lctx *d, UI tr, UI se)
{
	i64 idx;

	if((i64)tr>d->ntracks || (i64)se>d->sectors_per_track) {
		de_err(c, "Bad sector ID: %u,%u", tr, se);
		return 0;
	}
	idx = (i64)tr * d->sectors_per_track + (i64)se;
	if(d->sector_used_flags[idx]) {
		de_err(c, "Attempt to reuse sector: %u,%u", tr, se);
		return 0;
	}
	d->sector_used_flags[idx] = 1;
	return 1;
}

// Assembly:
pushq %rbx
movl %edx, %r8d
cmpq %r8, 0x8(%rsi)
jl 0x2e462
movl %ecx, %eax
movq 0x10(%rsi), %r9
cmpq %rax, %r9
jge 0x2e476
leaq 0xe810a(%rip), %rsi     # 0x116573
xorl %ebx, %ebx
xorl %eax, %eax
callq 0xe9df7
movl %ebx, %eax
popq %rbx
retq
imulq %r8, %r9
addq 0x28(%rsi), %r9
cmpb $0x0, (%rax,%r9)
je 0x2e48e
leaq 0xe80fc(%rip), %rsi     # 0x116588
jmp 0x2e469
movb $0x1, (%r9,%rax)
movl $0x1, %ebx
jmp 0x2e472
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/modules/apple2-dsk.c
// Function: my_preprocess_wozmoof_chunk_fn
static int my_preprocess_wozmoof_chunk_fn(struct de_iffctx *ictx)
{
	const char *name = NULL;

	switch(ictx->chunkctx->chunk4cc.id) {
	case CODE_TMAP: name = "track map"; break;
	case CODE_TRKS: name = "data for tracks"; break;
	case CODE_META: name = "metadata"; break;
	case CODE_WRIT: name = "disk writing instructions"; break;
	}

	if(name) {
		ictx->chunkctx->chunk_name = name;
	}
	return 1;
}

// Assembly:
movq 0x128(%rdi), %rax
movl 0x4(%rax), %esi
movb $0x1, %dl
xorl %ecx, %ecx
cmpl $0x54524b52, %esi       # imm = 0x54524B52
jg 0x2e63e
cmpl $0x4d455441, %esi       # imm = 0x4D455441
je 0x2e657
cmpl $0x544d4150, %esi       # imm = 0x544D4150
jne 0x2e669
leaq 0xe8158(%rip), %rcx     # 0x116794
jmp 0x2e667
cmpl $0x54524b53, %esi       # imm = 0x54524B53
je 0x2e660
cmpl $0x57524954, %esi       # imm = 0x57524954
jne 0x2e669
leaq 0xe8159(%rip), %rcx     # 0x1167ae
jmp 0x2e667
leaq 0xf90aa(%rip), %rcx     # 0x127708
jmp 0x2e667
leaq 0xe8137(%rip), %rcx     # 0x11679e
xorl %edx, %edx
testb %dl, %dl
jne 0x2e671
movq %rcx, 0x58(%rax)
movl $0x1, %eax
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/modules/apple2-dsk.c
// Function: my_moof_chunk_handler
static int my_moof_chunk_handler(struct de_iffctx *ictx)
{
	deark *c = ictx->c;

	switch(ictx->chunkctx->chunk4cc.id) {
	case CODE_INFO:
		ictx->handled = 1;
		do_moof_INFO(c, ictx, ictx->chunkctx);
		break;
	case CODE_META:
		ictx->handled = 1;
		do_wozmoof_META(c, ictx, ictx->chunkctx);
		break;
	}

	return 1;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %r14
movq (%rdi), %rbx
movq 0x128(%rdi), %rdx
movl 0x4(%rdx), %eax
cmpl $0x4d455441, %eax       # imm = 0x4D455441
je 0x2e70b
cmpl $0x494e464f, %eax       # imm = 0x494E464F
jne 0x2e856
movl $0x1, 0x130(%r14)
movq 0x40(%rdx), %rax
movq %rax, (%rsp)
cmpq $0x2c, 0x48(%rdx)
jl 0x2e856
movq 0x18(%r14), %rdi
movq %rsp, %r15
movq %r15, %rsi
callq 0xef14d
movzbl %al, %edx
leaq 0xe80f0(%rip), %rsi     # 0x1167c8
movq %rbx, %rdi
xorl %eax, %eax
callq 0xe9226
movq 0x18(%r14), %rdi
movq %r15, %rsi
callq 0xef14d
movzbl %al, %edx
leal -0x1(%rdx), %eax
cmpb $0x2, %al
ja 0x2e726
movzbl %al, %eax
leaq 0xe7d3a(%rip), %rsi     # 0x11643c
movslq (%rsi,%rax,4), %rcx
addq %rsi, %rcx
jmp 0x2e72d
movl $0x1, 0x130(%r14)
movq %rbx, %rdi
movq %r14, %rsi
callq 0x2ead7
jmp 0x2e856
leaq 0xfd73c(%rip), %rcx     # 0x12be69
leaq 0xe80ab(%rip), %rsi     # 0x1167df
movq %rbx, %rdi
xorl %eax, %eax
callq 0xe9226
movq 0x18(%r14), %rdi
movq %rsp, %r15
movq %r15, %rsi
callq 0xef14d
movzbl %al, %edx
leaq 0xe809b(%rip), %rsi     # 0x1167f2
movq %rbx, %rdi
xorl %eax, %eax
callq 0xe9226
movq 0x18(%r14), %rdi
movq %r15, %rsi
callq 0xef14d
movzbl %al, %edx
leaq 0xe808f(%rip), %rsi     # 0x116806
movq %rbx, %rdi
xorl %eax, %eax
callq 0xe9226
movq 0x18(%r14), %rdi
movq %r15, %rsi
callq 0xef14d
movzbl %al, %edx
leaq 0xe8080(%rip), %rsi     # 0x116817
movq %rbx, %rdi
xorl %eax, %eax
callq 0xe9226
movq %rbx, %rdi
callq 0xf6870
movq %rax, %r12
movq 0x18(%r14), %rdi
movq (%r15), %rsi
movl $0x20, %edx
movq %rax, %rcx
xorl %r8d, %r8d
movl $0x2, %r9d
callq 0xf01b0
movq %r12, %rdi
callq 0xf6900
movq %r12, %rdi
callq 0xf74bd
leaq 0xe804e(%rip), %rsi     # 0x11682e
movq %rbx, %rdi
movq %rax, %rdx
xorl %eax, %eax
callq 0xe9226
addq $0x21, (%r15)
movq 0x18(%r14), %rdi
movq %r15, %rsi
callq 0xef1ed
leaq 0xe8038(%rip), %rsi     # 0x11683c
movq %rbx, %rdi
movl %eax, %edx
xorl %eax, %eax
callq 0xe9226
movq 0x18(%r14), %rdi
movq %r15, %rsi
callq 0xef1ed
leaq 0xe8032(%rip), %rsi     # 0x116855
movq %rbx, %rdi
movl %eax, %edx
xorl %eax, %eax
callq 0xe9226
movq 0x18(%r14), %rdi
movq %r15, %rsi
callq 0xef1ed
leaq 0xe8022(%rip), %rsi     # 0x116864
movq %rbx, %rdi
movl %eax, %edx
xorl %eax, %eax
callq 0xe9226
movq %r12, %rdi
callq 0xf6bb0
movl $0x1, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/modules/apple2-dsk.c
// Function: do_wozmoof_META
static void do_wozmoof_META(deark *c, struct de_iffctx *ictx,
	const struct de_iffchunkctx *chunkctx)
{
	i64 k;
	int reading_val;
	de_ucstring *s = NULL;
	de_ucstring *name = NULL;
	de_ucstring *val = NULL;

	// Read the entire metadata string.
	s = ucstring_create(c);
	dbuf_read_to_ucstring_n(ictx->f, chunkctx->dpos, chunkctx->dlen,
		65536, s, 0, DE_ENCODING_UTF8);

	// Parse out the individual metadata items
	name = ucstring_create(c);
	val = ucstring_create(c);
	reading_val = 0;

	for(k=0; k<s->len; k++) {
		i32 ch = s->str[k];

		if(ch==0x0a) { // End of item
			do_wozmoof_print_metadata_item(c, name, val);
			ucstring_empty(name);
			ucstring_empty(val);
			reading_val = 0;
		}
		else if(ch==0x09 && !reading_val) { // Name/value separator
			reading_val = 1;
		}
		else { // A non-special character
			if(reading_val) {
				ucstring_append_char(val, ch);
			}
			else {
				ucstring_append_char(name, ch);
			}
		}
	}
	do_wozmoof_print_metadata_item(c, name, val);

	ucstring_destroy(s);
	ucstring_destroy(name);
	ucstring_destroy(val);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rdx, %r15
movq %rsi, %r12
movq %rdi, %r14
callq 0xf6870
movq %rax, %rbx
movq 0x18(%r12), %rdi
movq 0x40(%r15), %rsi
movq 0x48(%r15), %rdx
movl $0x2, (%rsp)
xorl %ebp, %ebp
movl $0x10000, %ecx          # imm = 0x10000
movq %rax, %r8
xorl %r9d, %r9d
callq 0xf0203
movq %r14, %rdi
callq 0xf6870
movq %rax, %r15
movq %r14, 0x10(%rsp)
movq %r14, %rdi
callq 0xf6870
movq %rax, %r12
cmpq $0x0, 0x10(%rbx)
jle 0x2eba6
xorl %r13d, %r13d
movq 0x8(%rbx), %rax
movl (%rax,%r13,4), %esi
cmpl $0xa, %esi
jne 0x2eb73
movq 0x10(%rsp), %rdi
movq %r15, %rsi
movq %r12, %rdx
callq 0x2ebdc
movq %r15, %rdi
callq 0xf6883
movq %r12, %rdi
callq 0xf6883
xorl %r14d, %r14d
jmp 0x2eb8e
movl $0x1, %r14d
testl %ebp, %ebp
jne 0x2eb82
cmpl $0x9, %esi
je 0x2eb8e
testl %ebp, %ebp
je 0x2eb9c
movq %r12, %rdi
callq 0xf69a2
incq %r13
movl %r14d, %ebp
cmpq 0x10(%rbx), %r13
jl 0x2eb41
jmp 0x2eba6
movq %r15, %rdi
callq 0xf69a2
jmp 0x2eb6e
movq 0x10(%rsp), %rdi
movq %r15, %rsi
movq %r12, %rdx
callq 0x2ebdc
movq %rbx, %rdi
callq 0xf6bb0
movq %r15, %rdi
callq 0xf6bb0
movq %r12, %rdi
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0xf6bb0
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/modules/apple2-dsk.c
// Function: do_wozmoof_print_metadata_item
static void do_wozmoof_print_metadata_item(deark *c, de_ucstring *name, de_ucstring *val)
{
	if(name->len==0 && val->len==0) return;
	de_dbg(c, "item: \"%s\" = \"%s\"",
		ucstring_getpsz_d(name),
		ucstring_getpsz_d(val));
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdx, %r14
movq %rdi, %rbx
cmpq $0x0, 0x10(%rsi)
jne 0x2ebf5
cmpq $0x0, 0x10(%r14)
je 0x2ec24
movq %rsi, %rdi
callq 0xf7557
movq %rax, %r15
movq %r14, %rdi
callq 0xf7557
leaq 0xe7ca4(%rip), %rsi     # 0x1168b3
movq %rbx, %rdi
movq %r15, %rdx
movq %rax, %rcx
xorl %eax, %eax
popq %rbx
popq %r14
popq %r15
jmp 0xe9226
popq %rbx
popq %r14
popq %r15
retq
nop
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/modules/applesd.c
// Function: de_module_applesd
void de_module_applesd(deark *c, struct deark_module_info *mi)
{
	mi->id = "applesd";
	mi->id_alias[0] = "applesingle";
	mi->id_alias[1] = "appledouble";
	mi->desc = "AppleSingle/AppleDouble";
	mi->run_fn = de_run_applesd;
	mi->identify_fn = de_identify_applesd;
	mi->help_fn = de_help_applesd;
}

// Assembly:
leaq 0xe7d1b(%rip), %rax     # 0x11694e
movq %rax, (%rsi)
leaq 0xe7d19(%rip), %rax     # 0x116956
movq %rax, 0x38(%rsi)
leaq 0xe7d1a(%rip), %rax     # 0x116962
movq %rax, 0x40(%rsi)
leaq 0xe7d1b(%rip), %rax     # 0x11696e
movq %rax, 0x8(%rsi)
leaq 0x1b(%rip), %rax        # 0x2ec79
movq %rax, 0x18(%rsi)
leaq 0x2ea(%rip), %rax       # 0x2ef53
movq %rax, 0x20(%rsi)
leaq 0x308(%rip), %rax       # 0x2ef7c
movq %rax, 0x28(%rsi)
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/modules/applesd.c
// Function: handler_data
static void handler_data(deark *c, lctx *d, struct entry_struct *e)
{
	if(d->is_appledouble) {
		de_warn(c, "AppleDouble header files should not have a data fork.");
	}

	d->advf->mainfork.fork_exists = 1;
	d->data_fork_pos = e->offset;
	d->advf->mainfork.fork_len = e->length;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdx, %rbx
movq %rsi, %r14
cmpb $0x0, 0x4(%rsi)
je 0x2f00c
leaq 0xe7ac5(%rip), %rsi     # 0x116aca
xorl %eax, %eax
callq 0xe9b27
movq 0x10(%r14), %rax
movb $0x1, 0x10(%rax)
movq 0x8(%rbx), %rcx
movq %rcx, 0x20(%r14)
movq 0x10(%rbx), %rcx
movq %rcx, 0x18(%rax)
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/modules/applesd.c
// Function: handler_rsrc
static void handler_rsrc(deark *c, lctx *d, struct entry_struct *e)
{
	if(d->extract_rsrc) {
		do_extract_rsrc(c, d, e);
	}
	else {
		do_decode_rsrc(c, d, e);
	}
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdx, %r14
movq %rdi, %rbx
cmpl $0x0, 0xc(%rsi)
movq 0x10(%rdx), %rax
je 0x2f071
testq %rax, %rax
jle 0x2f059
movq 0x10(%rsi), %rcx
movb $0x1, 0x38(%rcx)
movq 0x8(%r14), %rdx
movq %rdx, 0x18(%rsi)
movq %rax, 0x40(%rcx)
movq %rbx, %rdi
xorl %esi, %esi
callq 0xea9b3
xorl %edi, %edi
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0xf6bb0
testq %rax, %rax
jle 0x2f0c5
leaq 0xe7a83(%rip), %rsi     # 0x116b00
movq %rbx, %rdi
xorl %eax, %eax
callq 0xe9226
movq %rbx, %rdi
movl $0x1, %esi
callq 0xe9585
movq 0x18(%rbx), %rcx
movq 0x8(%r14), %r8
movq 0x10(%r14), %r9
leaq 0xe7a75(%rip), %rsi     # 0x116b1c
movq %rbx, %rdi
xorl %edx, %edx
callq 0xea66a
movq %rbx, %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0xe9585
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/modules/applesd.c
// Function: handler_string
static void handler_string(deark *c, lctx *d, struct entry_struct *e)
{
	struct de_stringreaderdata *srd = NULL;
	u8 firstbyte;

	if(e->length<1) goto done;

	firstbyte = de_getbyte(e->offset);

	if(firstbyte==0x00) {
		de_dbg(c, "string is apparently empty");
		goto done;
	}
	else if(is_pascal_string(c, d, e, firstbyte)) {
		i64 slen = (i64)firstbyte;

		de_dbg(c, "guessing this is a Pascal string, len: %u", (unsigned int)slen);
		srd = dbuf_read_string(c->infile, e->offset+1, slen, slen, 0, d->input_encoding);
	}
	else {
		srd = dbuf_read_string(c->infile, e->offset, e->length, 1024,
			DE_CONVFLAG_STOP_AT_NUL, d->input_encoding);
	}

	de_dbg(c, "%s: \"%s\"", e->eid->name, ucstring_getpsz_d(srd->str));

	if(e->id==3 && srd->str->len>0) { // id 3 = real name
		ucstring_empty(d->advf->filename);
		ucstring_append_ucstring(d->advf->filename, srd->str);
		d->advf->original_filename_flag = 1;
		de_advfile_set_orig_filename(d->advf, srd->sz, srd->sz_strlen);
	}

done:
	de_destroy_stringreaderdata(c, srd);
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rdi, %rbx
cmpq $0x0, 0x10(%rdx)
jle 0x2f145
movq %rdx, %r15
movq %rsi, %r14
movq 0x18(%rbx), %rdi
movq 0x8(%rdx), %rsi
callq 0xef0d5
testb %al, %al
je 0x2f14d
movq 0x10(%r15), %rdx
cmpb $0x1f, %al
ja 0x2f166
movzbl %al, %r12d
cmpq %r12, %rdx
jle 0x2f166
leaq -0x101(%rdx), %rax
cmpq $-0x100, %rax
jb 0x2f166
leaq 0xe7a21(%rip), %rsi     # 0x116b3f
movq %rbx, %rdi
movl %r12d, %edx
xorl %eax, %eax
callq 0xe9226
movq 0x18(%rbx), %rdi
movq 0x8(%r15), %rsi
incq %rsi
movl 0x8(%r14), %r9d
movq %r12, %rdx
movq %r12, %rcx
xorl %r8d, %r8d
jmp 0x2f17d
xorl %r12d, %r12d
jmp 0x2f1f7
leaq 0xe79d0(%rip), %rsi     # 0x116b24
xorl %r12d, %r12d
movq %rbx, %rdi
xorl %eax, %eax
callq 0xe9226
jmp 0x2f1f7
movq 0x18(%rbx), %rdi
movq 0x8(%r15), %rsi
movl 0x8(%r14), %r9d
movl $0x400, %ecx            # imm = 0x400
movl $0x1, %r8d
callq 0xefe67
movq %rax, %r12
movq 0x18(%r15), %rax
movq 0x8(%rax), %r13
movq 0x18(%r12), %rdi
callq 0xf7557
leaq 0xfcca4(%rip), %rsi     # 0x12be42
movq %rbx, %rdi
movq %r13, %rdx
movq %rax, %rcx
xorl %eax, %eax
callq 0xe9226
cmpl $0x3, 0x4(%r15)
jne 0x2f1f7
movq 0x18(%r12), %rax
cmpq $0x0, 0x10(%rax)
jle 0x2f1f7
movq 0x10(%r14), %rax
movq 0x68(%rax), %rdi
callq 0xf6883
movq 0x10(%r14), %rax
movq 0x68(%rax), %rdi
movq 0x18(%r12), %rsi
callq 0xf6969
movq 0x10(%r14), %rdi
movb $0x1, 0x79(%rdi)
movq 0x8(%r12), %rsi
movq 0x10(%r12), %rdx
callq 0xfcaec
movq %rbx, %rdi
movq %r12, %rsi
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
jmp 0xf00aa
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/modules/applesd.c
// Function: handler_dates
static void handler_dates(deark *c, lctx *d, struct entry_struct *e)
{
	if(e->length<16) return;
	do_one_date(c, d, e->offset, "creation date", &d->advf->mainfork.fi->timestamp[DE_TIMESTAMPIDX_CREATE]);
	do_one_date(c, d, e->offset+4, "mod date", &d->advf->mainfork.fi->timestamp[DE_TIMESTAMPIDX_MODIFY]);
	do_one_date(c, d, e->offset+8, "backup date", &d->advf->mainfork.fi->timestamp[DE_TIMESTAMPIDX_BACKUP]);
	do_one_date(c, d, e->offset+12, "access date", &d->advf->mainfork.fi->timestamp[DE_TIMESTAMPIDX_ACCESS]);
}

// Assembly:
cmpq $0x10, 0x10(%rdx)
jge 0x2f213
retq
pushq %r15
pushq %r14
pushq %rbx
movq %rdx, %r15
movq %rsi, %r14
movq %rdi, %rbx
movq 0x8(%rdx), %rsi
movq 0x10(%r14), %rax
movq 0x20(%rax), %rcx
addq $0x28, %rcx
leaq 0xfe1bc(%rip), %rdx     # 0x12d3f4
callq 0x2f73c
movq 0x8(%r15), %rsi
addq $0x4, %rsi
movq 0x10(%r14), %rax
movq 0x20(%rax), %rcx
addq $0x18, %rcx
leaq 0xf183e(%rip), %rdx     # 0x120a96
movq %rbx, %rdi
callq 0x2f73c
movq 0x8(%r15), %rsi
addq $0x8, %rsi
movq 0x10(%r14), %rax
movq 0x20(%rax), %rcx
addq $0x58, %rcx
leaq 0xe78ee(%rip), %rdx     # 0x116b69
movq %rbx, %rdi
callq 0x2f73c
movq 0x8(%r15), %rsi
addq $0xc, %rsi
movq 0x10(%r14), %rax
movq 0x20(%rax), %rcx
addq $0x38, %rcx
leaq 0xe78d7(%rip), %rdx     # 0x116b75
movq %rbx, %rdi
popq %rbx
popq %r14
popq %r15
jmp 0x2f73c
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/modules/applesd.c
// Function: do_one_date
static void do_one_date(deark *c, lctx *d, i64 pos, const char *name,
	struct de_timestamp *returned_ts)
{
	i64 dt;
	struct de_timestamp ts;
	char timestamp_buf[64];

	de_zeromem(&ts, sizeof(struct de_timestamp));
	dt = de_geti32be(pos);
	if(dt == -0x80000000LL) {
		de_strlcpy(timestamp_buf, "unknown", sizeof(timestamp_buf));
	}
	else {
		// Epoch is Jan 1, 2001. There are 30 years, with 7 leap days, between
		// that and the Unix time epoch.
		de_unix_time_to_timestamp(dt + ((365*30 + 7)*86400), &ts, 0x1);
		de_timestamp_to_string(&ts, timestamp_buf, sizeof(timestamp_buf), 0);
	}
	de_dbg(c, "%s: %"I64_FMT" (%s)", name, dt, timestamp_buf);
	if(returned_ts) {
		*returned_ts = ts;
	}
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x50, %rsp
movq %rcx, %rbx
movq %rdx, %r14
movq %rdi, %r15
xorps %xmm0, %xmm0
movaps %xmm0, (%rsp)
movq 0x18(%rdi), %rdi
callq 0xef3cb
movq %rax, %r12
cmpq $-0x80000000, %rax      # imm = 0x80000000
jne 0x2f785
leaq 0xe2d18(%rip), %rsi     # 0x11248c
leaq 0x10(%rsp), %rdi
movl $0x40, %edx
callq 0xe8ded
jmp 0x2f7b3
movq %r12, %rdi
addq $0x386d4380, %rdi       # imm = 0x386D4380
movq %rsp, %r13
movq %r13, %rsi
movl $0x1, %edx
callq 0xeace2
leaq 0x10(%rsp), %rsi
movl $0x40, %edx
movq %r13, %rdi
xorl %ecx, %ecx
callq 0xeb4f8
leaq 0xe73c7(%rip), %rsi     # 0x116b81
leaq 0x10(%rsp), %r8
movq %r15, %rdi
movq %r14, %rdx
movq %r12, %rcx
xorl %eax, %eax
callq 0xe9226
testq %rbx, %rbx
je 0x2f7db
movaps (%rsp), %xmm0
movups %xmm0, (%rbx)
addq $0x50, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/modules/binhex.c
// Function: de_module_binhex
void de_module_binhex(deark *c, struct deark_module_info *mi)
{
	mi->id = "binhex";
	mi->desc = "Macintosh BinHex (.hqx) archive";
	mi->run_fn = de_run_binhex;
	mi->identify_fn = de_identify_binhex;
}

// Assembly:
leaq 0xe74e1(%rip), %rax     # 0x116cd4
movq %rax, (%rsi)
leaq 0xe74de(%rip), %rax     # 0x116cdb
movq %rax, 0x8(%rsi)
leaq 0x10(%rip), %rax        # 0x2f818
movq %rax, 0x18(%rsi)
leaq 0x62c(%rip), %rax       # 0x2fe3f
movq %rax, 0x20(%rsi)
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/modules/binhex.c
// Function: de_identify_binhex
static int de_identify_binhex(deark *c)
{
	u8 b0;
	int ret;
	i64 foundpos;

	b0 = de_getbyte(0);
	if(b0==g_binhex_intro1[0]) {
		if(!dbuf_memcmp(c->infile, 0, g_binhex_intro1, INTRO1_LEN)) {
			return 100;
		}
	}

	if(!de_input_file_has_ext(c, "hqx")) return 0;

	// File has .hqx extension. Try harder to identify it.
	ret = find_start(c, &foundpos);
	if(ret) {
		if(foundpos<=1) {
			// Possible BinHex, but no intro
			if(looks_like_binhex_eof(c)) {
				return 75;
			}
		}
		else {
			return 100;
		}
	}

	return 0;
}

// Assembly:
pushq %r14
pushq %rbx
subq $0x18, %rsp
movq %rdi, %r14
movq 0x18(%rdi), %rdi
xorl %ebx, %ebx
xorl %esi, %esi
callq 0xef0d5
cmpb $0x28, %al
jne 0x2fe75
movq 0x18(%r14), %rdi
leaq 0xe6ec1(%rip), %rdx     # 0x116d26
movl $0x28, %ecx
xorl %esi, %esi
callq 0xf025e
testl %eax, %eax
je 0x2fed4
leaq 0xe7023(%rip), %rsi     # 0x116e9f
movq %r14, %rdi
callq 0xea936
testl %eax, %eax
je 0x2ff06
leaq 0x10(%rsp), %rsi
movq %r14, %rdi
callq 0x2ff10
testl %eax, %eax
je 0x2ff04
movl $0x64, %ebx
cmpq $0x1, 0x10(%rsp)
jg 0x2ff06
movq 0x18(%r14), %rdi
movq 0x18(%rdi), %rdx
addq $-0x3, %rdx
leaq 0xd(%rsp), %rbx
movl $0x3, %ecx
movq %rbx, %rsi
callq 0xeeee8
movzbl 0x2(%rbx), %eax
cmpl $0x3a, %eax
jne 0x2fedb
movl $0x4b, %ebx
jmp 0x2ff06
movl $0x64, %ebx
jmp 0x2ff06
movb 0xe(%rsp), %cl
cmpb $0x3a, %cl
jne 0x2feee
cmpl $0xa, %eax
je 0x2fecd
cmpl $0xd, %eax
je 0x2fecd
cmpl $0xa, %eax
jne 0x2ff04
cmpb $0xd, %cl
jne 0x2ff04
movl $0x4b, %ebx
cmpb $0x3a, 0xd(%rsp)
je 0x2ff06
xorl %ebx, %ebx
movl %ebx, %eax
addq $0x18, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/modules/binhex.c
// Function: find_start
static int find_start(deark *c, i64 *foundpos)
{
	i64 pos;
	u8 b;
	int ret;

	*foundpos = 0;

	ret = dbuf_search(c->infile, g_binhex_intro1, INTRO1_LEN, 0, 8192, &pos);
	if(ret) pos += INTRO1_LEN;
	if(!ret) {
		ret = dbuf_search(c->infile, g_binhex_intro2, INTRO2_LEN, 0, 8192, &pos);
		if(ret) pos += INTRO2_LEN;
	}
	if(!ret) {
		ret = dbuf_search(c->infile, g_binhex_intro3, INTRO3_LEN, 0, 8192, &pos);
		if(ret) pos += INTRO3_LEN;
	}
	if(!ret) {
		if(de_getbyte(0)==':') {
			*foundpos = 1;
			return 1;
		}
	}
	if(!ret) {
		return 0;
	}

	// Find the next CR/LF byte
	while(1) {
		if(pos>=c->infile->len) return 0;
		b = de_getbyte(pos);
		pos++;
		if(b=='\x0a' || b=='\x0d') {
			break;
		}
	}

	// Skip any number of additional whitespace
	while(1) {
		b = de_getbyte(pos);
		if(b=='\x0a' || b=='\x0d' || b==' ' || b=='\t') {
			pos++;
		}
		else {
			break;
		}
	}

	// Current byte should be a colon (:)
	b = de_getbyte(pos);
	if(b==':') {
		*foundpos = pos+1;
		return 1;
	}

	return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x10, %rsp
movq %rsi, %rbx
movq %rdi, %r14
movq $0x0, (%rsi)
movq 0x18(%rdi), %rdi
leaq 0xe6df2(%rip), %rsi     # 0x116d26
leaq 0x8(%rsp), %r9
movl $0x28, %edx
movl $0x2000, %r8d           # imm = 0x2000
xorl %ecx, %ecx
callq 0xf1a9c
testl %eax, %eax
je 0x2ff57
addq $0x28, 0x8(%rsp)
jmp 0x2ffb5
movq 0x18(%r14), %rdi
leaq 0xe6ded(%rip), %rsi     # 0x116d4f
leaq 0x8(%rsp), %r9
movl $0x17, %edx
movl $0x2000, %r8d           # imm = 0x2000
xorl %ecx, %ecx
callq 0xf1a9c
testl %eax, %eax
je 0x2ff85
addq $0x17, 0x8(%rsp)
jmp 0x2ffb5
movq 0x18(%r14), %rdi
leaq 0xe6dd7(%rip), %rsi     # 0x116d67
leaq 0x8(%rsp), %r9
movl $0x2a, %edx
movl $0x2000, %r8d           # imm = 0x2000
xorl %ecx, %ecx
callq 0xf1a9c
testl %eax, %eax
je 0x3005f
addq $0x2a, 0x8(%rsp)
xorl %ebp, %ebp
testb %bpl, %bpl
je 0x2ffd8
movq 0x18(%r14), %rdi
xorl %r15d, %r15d
xorl %esi, %esi
callq 0xef0d5
movl $0x1, %ecx
cmpb $0x3a, %al
je 0x30046
testb %bpl, %bpl
jne 0x3004f
movq 0x8(%rsp), %rsi
movq 0x18(%r14), %rdi
xorl %r15d, %r15d
cmpq 0x18(%rdi), %rsi
jge 0x3004f
callq 0xef0d5
incq 0x8(%rsp)
cmpb $0xd, %al
je 0x30000
movzbl %al, %eax
cmpl $0xa, %eax
jne 0x2ffd8
movabsq $0x100002600, %r12      # imm = 0x100002600
movq 0x18(%r14), %rdi
movq 0x8(%rsp), %rsi
callq 0xef0d5
cmpb $0x20, %al
ja 0x3002c
movzbl %al, %eax
btq %rax, %r12
jae 0x3002c
incq 0x8(%rsp)
jmp 0x3000a
movq 0x18(%r14), %rdi
movq 0x8(%rsp), %rsi
callq 0xef0d5
cmpb $0x3a, %al
jne 0x3004f
movq 0x8(%rsp), %rcx
incq %rcx
movq %rcx, (%rbx)
movl $0x1, %r15d
movl %r15d, %eax
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movb $0x1, %bpl
jmp 0x2ffb7
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/modules/binhex.c
// Function: do_pre_extract_fork
static int do_pre_extract_fork(deark *c, lctx *d, dbuf *inf, struct binhex_forkinfo *fki,
	struct de_advfile_forkinfo *advfki)
{
	fki->crc_reported = (u32)dbuf_getu16be(inf, fki->pos + fki->len);
	de_dbg(c, "%s fork crc (reported): 0x%04x", fki->forkname,
		(unsigned int)fki->crc_reported);

	advfki->writelistener_cb = de_writelistener_for_crc;
	advfki->userdata_for_writelistener = (void*)fki->crco;

	if((fki->pos + fki->len > inf->len) && fki->len!=0) {
		de_err(c, "%s fork goes beyond end of file", fki->forkname);
		fki->len = 0;
		return 0;
	}
	return 1;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rcx, %r12
movq %rdx, %rbx
movq %rsi, %r15
movq %rdi, %r14
movq 0x8(%rdx), %rsi
addq (%rdx), %rsi
movq %r15, %rdi
callq 0xef169
movl %eax, 0x10(%rbx)
movq 0x20(%rbx), %rdx
leaq 0xe6d8a(%rip), %rsi     # 0x116e22
movq %r14, %rdi
movl %eax, %ecx
xorl %eax, %eax
callq 0xe9226
leaq 0xc19a6(%rip), %rax     # 0xf1a51
movq %rax, 0x20(%r12)
movq 0x18(%rbx), %rax
movq %rax, 0x18(%r12)
movq 0x8(%rbx), %rax
movl $0x1, %ebp
testq %rax, %rax
je 0x300ef
addq (%rbx), %rax
cmpq 0x18(%r15), %rax
jle 0x300ef
movq 0x20(%rbx), %rdx
leaq 0xe6d66(%rip), %rsi     # 0x116e41
xorl %ebp, %ebp
movq %r14, %rdi
xorl %eax, %eax
callq 0xe9df7
movq $0x0, 0x8(%rbx)
movl %ebp, %eax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/modules/binhex.c
// Function: do_post_extract_fork
static void do_post_extract_fork(deark *c, lctx *d, struct binhex_forkinfo *fki)
{
	u32 crc_calc;

	// Here, the BinHex spec says we should feed two 0x00 bytes to the CRC
	// calculation, to account for the CRC field itself. However, if I do
	// that, none of files I've tested have the correct CRC. If I don't,
	// all of them have the correct CRC.
	//de_crcobj_addbuf(fki->crco, (const u8*)"\0\0", 2);

	crc_calc = de_crcobj_getval(fki->crco);
	de_dbg(c, "%s fork crc (calculated): 0x%04x", fki->forkname,
		(unsigned int)crc_calc);
	if(crc_calc != fki->crc_reported) {
		de_err(c, "CRC check failed for %s fork", fki->forkname);
	}
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movq %rsi, %r14
movq %rdi, %rbx
movq 0x18(%rsi), %rdi
callq 0xebe2a
movl %eax, %ebp
movq 0x20(%r14), %rdx
leaq 0xe6cf9(%rip), %rsi     # 0x116e61
movq %rbx, %rdi
movl %eax, %ecx
xorl %eax, %eax
callq 0xe9226
cmpl 0x10(%r14), %ebp
jne 0x3017f
popq %rbx
popq %r14
popq %rbp
retq
movq 0x20(%r14), %rdx
leaq 0xe6cf8(%rip), %rsi     # 0x116e82
movq %rbx, %rdi
xorl %eax, %eax
popq %rbx
popq %r14
popq %rbp
jmp 0xe9df7
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/modules/bintext.c
// Function: de_module_xbin
void de_module_xbin(deark *c, struct deark_module_info *mi)
{
	mi->id = "xbin";
	mi->desc = "XBIN character graphics";
	mi->run_fn = de_run_xbin;
	mi->identify_fn = de_identify_xbin;
	mi->help_fn = de_help_xbin;
}

// Assembly:
leaq 0xe6e21(%rip), %rax     # 0x116fc0
movq %rax, (%rsi)
leaq 0xe6e1c(%rip), %rax     # 0x116fc5
movq %rax, 0x8(%rsi)
leaq 0x1b(%rip), %rax        # 0x301cf
movq %rax, 0x18(%rsi)
leaq 0x654(%rip), %rax       # 0x30813
movq %rax, 0x20(%rsi)
leaq 0x66f(%rip), %rax       # 0x30839
movq %rax, 0x28(%rsi)
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/modules/bintext.c
// Function: de_module_bintext
void de_module_bintext(deark *c, struct deark_module_info *mi)
{
	mi->id = "bintext";
	mi->desc = "Binary Text character graphics";
	mi->run_fn = de_run_bintext;
	mi->identify_fn = de_identify_bintext;
	mi->help_fn = de_help_bintext;
}

// Assembly:
leaq 0xe6779(%rip), %rax     # 0x116fdd
movq %rax, (%rsi)
leaq 0xe6777(%rip), %rax     # 0x116fe5
movq %rax, 0x8(%rsi)
leaq 0x1b(%rip), %rax        # 0x30894
movq %rax, 0x18(%rsi)
leaq 0x260(%rip), %rax       # 0x30ae4
movq %rax, 0x20(%rsi)
leaq 0x289(%rip), %rax       # 0x30b18
movq %rax, 0x28(%rsi)
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/modules/bintext.c
// Function: de_identify_bintext
static int de_identify_bintext(deark *c)
{
	if(!c->detection_data->SAUCE_detection_attempted) {
		// FIXME?: This is known to happen if "-disablemods sauce" was used.
		de_err(c, "bintext detection requires sauce module");
		return 0;
	}
	if(c->detection_data->sauce.has_SAUCE) {
		if(c->detection_data->sauce.data_type==5)
		{
			return 100;
		}
	}
	return 0;
}

// Assembly:
pushq %rbx
movq 0x28(%rdi), %rax
cmpb $0x0, 0x5(%rax)
je 0x30b04
cmpb $0x0, 0x10(%rax)
je 0x30b00
movl $0x64, %ebx
cmpb $0x5, 0x11(%rax)
je 0x30b14
xorl %ebx, %ebx
jmp 0x30b14
leaq 0xe6828(%rip), %rsi     # 0x117333
xorl %ebx, %ebx
xorl %eax, %eax
callq 0xe9df7
movl %ebx, %eax
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/modules/bintext.c
// Function: de_module_artworx_adf
void de_module_artworx_adf(deark *c, struct deark_module_info *mi)
{
	mi->id = "artworx_adf";
	mi->desc = "ArtWorx Data Format (ADF)";
	mi->run_fn = de_run_artworx_adf;
	mi->identify_fn = de_identify_artworx_adf;
	mi->help_fn = de_help_artworx_adf;
}

// Assembly:
leaq 0xe64b0(%rip), %rax     # 0x117004
movq %rax, (%rsi)
leaq 0xe64b2(%rip), %rax     # 0x117010
movq %rax, 0x8(%rsi)
leaq 0x1b(%rip), %rax        # 0x30b84
movq %rax, 0x18(%rsi)
leaq 0x1aa(%rip), %rax       # 0x30d1e
movq %rax, 0x20(%rsi)
leaq 0x219(%rip), %rax       # 0x30d98
movq %rax, 0x28(%rsi)
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/modules/bintext.c
// Function: de_identify_artworx_adf
static int de_identify_artworx_adf(deark *c)
{
	u8 ver;

	// TODO: This detection algorithm will fail if there is a SAUCE record.

	if(c->infile->len < 1+192+4096+160) {
		return 0;
	}
	if((c->infile->len - (1+192+4096))%160 != 0) {
		return 0;
	}
	if(!de_input_file_has_ext(c, "adf")) return 0;
	ver = de_getbyte(0);
	// I don't know what version numbers are allowed, but I'll assume the
	// version number should be small.
	if(ver>4) return 0;
	return 75;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq 0x18(%rdi), %rax
movq 0x18(%rax), %rax
xorl %ebx, %ebx
cmpq $0x1161, %rax           # imm = 0x1161
jl 0x30d8e
movabsq $-0x3333333333333333, %rcx # imm = 0xCCCCCCCCCCCCCCCD
imulq %rcx, %rax
movabsq $-0x333333333333368d, %rcx # imm = 0xCCCCCCCCCCCCC973
addq %rax, %rcx
rorq $0x5, %rcx
movabsq $0x199999999999999, %rax # imm = 0x199999999999999
cmpq %rax, %rcx
ja 0x30d8e
movq %rdi, %r14
leaq 0x119b36(%rip), %rsi    # 0x14a8a2
callq 0xea936
testl %eax, %eax
je 0x30d8e
movq 0x18(%r14), %rdi
xorl %r14d, %r14d
xorl %esi, %esi
callq 0xef0d5
cmpb $0x5, %al
movl $0x4b, %ebx
cmovael %r14d, %ebx
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/modules/bintext.c
// Function: de_module_icedraw
void de_module_icedraw(deark *c, struct deark_module_info *mi)
{
	mi->id = "icedraw";
	mi->desc = "iCEDraw character graphics format";
	mi->run_fn = de_run_icedraw;
	mi->identify_fn = de_identify_icedraw;
	mi->flags |= DE_MODFLAG_NONWORKING;
}

// Assembly:
leaq 0xe6256(%rip), %rax     # 0x11702a
movq %rax, (%rsi)
leaq 0xe6254(%rip), %rax     # 0x117032
movq %rax, 0x8(%rsi)
leaq 0x14(%rip), %rax        # 0x30dfd
movq %rax, 0x18(%rsi)
leaq 0x84(%rip), %rax        # 0x30e78
movq %rax, 0x20(%rsi)
orb $0x2, 0x30(%rsi)
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/modules/bintext.c
// Function: de_module_thedraw_com
void de_module_thedraw_com(deark *c, struct deark_module_info *mi)
{
	mi->id = "thedraw_com";
	mi->desc = "TheDraw COM file";
	mi->run_fn = de_run_thedraw_com;
	mi->identify_fn = de_identify_thedraw_com;
}

// Assembly:
leaq 0xe61af(%rip), %rax     # 0x117054
movq %rax, (%rsi)
leaq 0xe61b1(%rip), %rax     # 0x117060
movq %rax, 0x8(%rsi)
leaq 0x10(%rip), %rax        # 0x30eca
movq %rax, 0x18(%rsi)
leaq 0x3dd(%rip), %rax       # 0x312a2
movq %rax, 0x20(%rsi)
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/modules/bintext.c
// Function: de_identify_thedraw_com
static int de_identify_thedraw_com(deark *c)
{
	u8 n1, n2;

	if(c->infile->len>65280) return 0;
	n1 = de_getbyte(0);
	if(n1!=0xeb) return 0;

	n1 = de_getbyte(1);
	n2 = de_getbyte(6);
	// Check format subtype & viewer start position.
	if((n2==0 && n1==0x3d) ||
		(n2==1 && n1==0x18) ||
		(n2==2 && n1==0x3d))
	{
		;
	}
	else {
		return 0;
	}

	if(!dbuf_memcmp(c->infile, 9, (const void*)"TheDraw COM file", 16)) {
		return 100;
	}

	if(n2==0) {
		if(!dbuf_memcmp(c->infile, 0x3f,
			(const void*)"\xb4\x0f\xcd\x10\x8c\xcb\x8e\xdb\xbb\x00", 10))
		{
			// An extra check to defend against lookalike formats, particularly
			// P-Screen (search for pscrn_55.zip).
			if(de_getbyte(0x3f+76)==0xad) {
				return 40;
			}
		}
	}
	else if(n2==1) {
		if(!dbuf_memcmp(c->infile, 0x1a,
			(const void*)"\xb4\x0f\xcd\x10\x8b\x3e\x07\x01\xbe\x5e", 10))
		{
			return 40;
		}
	}
	else if(n2==2) {
		if(!dbuf_memcmp(c->infile, 0x3f,
			(const void*)"\xb4\x0f\xcd\x10\xbb\x00\xb8\x3c\x02\x74", 10))
		{
			return 40;
		}
	}

	return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0x18(%rdi), %rdi
xorl %r14d, %r14d
cmpq $0xff00, 0x18(%rdi)     # imm = 0xFF00
jg 0x313c6
xorl %r14d, %r14d
xorl %esi, %esi
callq 0xef0d5
cmpb $-0x15, %al
jne 0x313c6
movq 0x18(%rbx), %rdi
movl $0x1, %esi
callq 0xef0d5
movl %eax, %r15d
movq 0x18(%rbx), %rdi
movl $0x6, %esi
callq 0xef0d5
movl %eax, %ebp
movl %r15d, %eax
xorb $0x3d, %al
movl %ebp, %ecx
orb %al, %cl
jne 0x31347
movq 0x18(%rbx), %rdi
leaq 0xe5d56(%rip), %rdx     # 0x117060
movl $0x9, %esi
movl $0x10, %ecx
callq 0xf025e
testl %eax, %eax
je 0x31365
testb %bpl, %bpl
je 0x3136d
cmpb $0x2, %bpl
je 0x313a5
movzbl %bpl, %eax
cmpl $0x1, %eax
jne 0x313c3
movq 0x18(%rbx), %rdi
leaq 0xe614e(%rip), %rdx     # 0x11748e
movl $0x1a, %esi
jmp 0x313b5
movl %ebp, %ecx
xorb $0x1, %cl
xorb $0x18, %r15b
movl %ebp, %edx
xorb $0x2, %dl
orb %al, %dl
sete %al
orb %cl, %r15b
je 0x312ff
testb %al, %al
je 0x313c6
jmp 0x312ff
movl $0x64, %r14d
jmp 0x313c6
movq 0x18(%rbx), %rdi
leaq 0xe5bb4(%rip), %rdx     # 0x116f2c
movl $0x3f, %esi
movl $0xa, %ecx
callq 0xf025e
testl %eax, %eax
jne 0x313c3
movq 0x18(%rbx), %rdi
movl $0x8b, %esi
callq 0xef0d5
movl $0x28, %r14d
cmpb $-0x53, %al
jne 0x313c3
jmp 0x313c6
movq 0x18(%rbx), %rdi
leaq 0xe5b87(%rip), %rdx     # 0x116f37
movl $0x3f, %esi
movl $0xa, %ecx
callq 0xf025e
testl %eax, %eax
je 0x313d4
xorl %r14d, %r14d
movl %r14d, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movl $0x28, %r14d
jmp 0x313c6
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/modules/bintext.c
// Function: de_module_aciddraw_com
void de_module_aciddraw_com(deark *c, struct deark_module_info *mi)
{
	mi->id = "aciddraw_com";
	mi->desc = "ACiDDraw COM file";
	mi->run_fn = de_run_aciddraw_com;
	mi->identify_fn = de_identify_aciddraw_com;
}

// Assembly:
leaq 0xe5c8e(%rip), %rax     # 0x117071
movq %rax, (%rsi)
leaq 0xe5c91(%rip), %rax     # 0x11707e
movq %rax, 0x8(%rsi)
leaq 0x10(%rip), %rax        # 0x31408
movq %rax, 0x18(%rsi)
leaq 0x2a6(%rip), %rax       # 0x316a9
movq %rax, 0x20(%rsi)
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/modules/bintext.c
// Function: de_identify_aciddraw_com
static int de_identify_aciddraw_com(deark *c)
{
	u8 n1;
	struct aciddraw_id_data adi;

	if(c->infile->len>65280) return 0;
	n1 = de_getbyte(0);
	if(n1!=0xe9 && n1!=0xeb) return 0;
	aciddraw_id(c, n1, &adi);
	if(adi.is_aciddraw) {
		return 92;
	}
	return 0;
}

// Assembly:
pushq %r14
pushq %rbx
subq $0x18, %rsp
movq %rdi, %rbx
movq 0x18(%rdi), %rdi
xorl %r14d, %r14d
cmpq $0xff00, 0x18(%rdi)     # imm = 0xFF00
jg 0x316fb
xorl %r14d, %r14d
xorl %esi, %esi
callq 0xef0d5
movl %eax, %ecx
andb $-0x3, %cl
cmpb $-0x17, %cl
jne 0x316fb
movzbl %al, %esi
leaq 0x8(%rsp), %r14
movq %rbx, %rdi
movq %r14, %rdx
callq 0x323aa
xorl %eax, %eax
cmpb $0x0, (%r14)
movl $0x5c, %r14d
cmovel %eax, %r14d
movl %r14d, %eax
addq $0x18, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/modules/bintext.c
// Function: de_module_ldog_com
void de_module_ldog_com(deark *c, struct deark_module_info *mi)
{
	mi->id = "ldog_com";
	mi->desc = "Laughing Dog COM file";
	mi->run_fn = de_run_ldog_com;
	mi->identify_fn = de_identify_ldog_com;
}

// Assembly:
leaq 0xe5983(%rip), %rax     # 0x117090
movq %rax, (%rsi)
leaq 0xe5982(%rip), %rax     # 0x117099
movq %rax, 0x8(%rsi)
leaq 0x10(%rip), %rax        # 0x31732
movq %rax, 0x18(%rsi)
leaq 0x15c(%rip), %rax       # 0x31889
movq %rax, 0x20(%rsi)
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/modules/bintext.c
// Function: de_run_ldog_com
static void de_run_ldog_com(deark *c, de_module_params *mparams)
{
	lctx *d = NULL;
	struct de_char_context *charctx = NULL;
	u8 b;

	d = de_malloc(c, sizeof(lctx));
	d->csctx.input_encoding = de_get_input_encoding(c, NULL, DE_ENCODING_CP437);

	charctx = de_create_charctx(c, 0);
	charctx->screen_image_flag = 1;

	b = de_getbyte(22);
	if(b != 0xbe) {
		d->need_errmsg = 1;
		goto done;
	}
	b = de_getbyte(65);
	if(b != 0xb6) {
		d->need_errmsg = 1;
		goto done;
	}

	d->csctx.inf_pos = de_getu16le(23);
	d->csctx.inf_pos -= 0x100;
	de_dbg(c, "data pos: %"I64_FMT, d->csctx.inf_pos);

	d->csctx.height_in_chars = (i64)de_getbyte(66);
	d->csctx.width_in_chars = (i64)de_getbyte(68);
	de_dbg_dimensions(c, d->csctx.width_in_chars, d->csctx.height_in_chars);
	d->csctx.inf_len = d->csctx.width_in_chars * d->csctx.height_in_chars * 2;
	if(d->csctx.inf_pos+d->csctx.inf_len > c->infile->len) {
		d->need_errmsg = 1;
		goto done;
	}

	if(d->csctx.width_in_chars>80 || d->csctx.height_in_chars>25) {
		charctx->no_density = 1;
	}

	d->csctx.use_default_pal = 1;
	d->csctx.inf = c->infile;
	fmtutil_char_simple_run(c, &d->csctx, charctx);

done:
	if(d) {
		if(d->need_errmsg) {
			de_err(c, "Unsupported LDOG COM format");
		}
		free_lctx(c, d);
	}
	de_free_charctx(c, charctx);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %rbx
movl $0x70, %esi
callq 0xe969b
movq %rax, %r14
movq %rbx, %rdi
xorl %esi, %esi
movl $0xd, %edx
callq 0xeb7d1
movl %eax, 0x48(%r14)
movq %rbx, %rdi
xorl %esi, %esi
callq 0xf43cc
movq %rax, %r15
movb $0x1, 0x2(%rax)
movq 0x18(%rbx), %rdi
movl $0x16, %esi
callq 0xef0d5
cmpb $-0x42, %al
jne 0x3181b
movq 0x18(%rbx), %rdi
movl $0x41, %esi
callq 0xef0d5
cmpb $-0x4a, %al
jne 0x3181b
movq 0x18(%rbx), %rdi
movl $0x17, %esi
callq 0xef1ca
leaq -0x100(%rax), %rdx
movq %rdx, 0x38(%r14)
leaq 0xf464e(%rip), %rsi     # 0x125e05
movq %rbx, %rdi
xorl %eax, %eax
callq 0xe9226
movq 0x18(%rbx), %rdi
movl $0x42, %esi
callq 0xef0d5
movzbl %al, %eax
movq %rax, 0x58(%r14)
movq 0x18(%rbx), %rdi
movl $0x44, %esi
callq 0xef0d5
movzbl %al, %esi
movq %rsi, 0x50(%r14)
movq 0x58(%r14), %rdx
movq %rbx, %rdi
callq 0xe9b05
movq 0x50(%r14), %rdx
movq 0x58(%r14), %rcx
movq %rdx, %rsi
imulq %rcx, %rsi
addq %rsi, %rsi
movq %rsi, 0x40(%r14)
addq 0x38(%r14), %rsi
movq 0x18(%rbx), %rax
cmpq 0x18(%rax), %rsi
jle 0x31858
movb $0x1, 0x1(%r14)
testq %r14, %r14
je 0x31848
cmpb $0x0, 0x1(%r14)
je 0x3183d
leaq 0xe5cc2(%rip), %rsi     # 0x1174f5
movq %rbx, %rdi
xorl %eax, %eax
callq 0xe9df7
movq %rbx, %rdi
movq %r14, %rsi
callq 0x31fe3
movq %rbx, %rdi
movq %r15, %rsi
popq %rbx
popq %r14
popq %r15
jmp 0xf44c8
leaq 0x30(%r14), %rsi
cmpq $0x51, %rdx
setl %dl
cmpq $0x1a, %rcx
setl %cl
testb %cl, %dl
jne 0x31873
movb $0x1, 0x3(%r15)
movb $0x1, 0x4c(%r14)
movq %rax, 0x30(%r14)
movq %rbx, %rdi
movq %r15, %rdx
callq 0xfa176
jmp 0x31820