LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O0/jsummers[P]deark/modules/macbinary.c
// Function: do_prepare_one_fork
static void do_prepare_one_fork(deark *c, lctx *d, struct de_advfile_forkinfo *advfki,
	struct fork_info *fki)
{
	de_dbg(c, "%s fork at %"I64_FMT", len=%"I64_FMT, fork_name(fki->is_rsrc, 0),
		fki->pos, advfki->fork_len);

	if(fki->pos+advfki->fork_len>c->infile->len) {
		de_err(c, "%s fork at %"I64_FMT" goes beyond end of file.",
			fork_name(fki->is_rsrc, 1), fki->pos);
		if(fki->pos+advfki->fork_len > c->infile->len+1024) {
			fki->extract_error_flag = 1;
			goto done;
		}
	}

done:
	;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x28(%rbp)
movq -0x20(%rbp), %rax
movzbl (%rax), %edi
xorl %esi, %esi
callq 0xd2110
movq -0x28(%rbp), %rdi
movq %rax, %rdx
movq -0x20(%rbp), %rax
movq 0x8(%rax), %rcx
movq -0x18(%rbp), %rax
movq 0x8(%rax), %r8
leaq 0xe85fa(%rip), %rsi     # 0x1ba5d6
movb $0x0, %al
callq 0x15b0d0
movq -0x20(%rbp), %rax
movq 0x8(%rax), %rax
movq -0x18(%rbp), %rcx
addq 0x8(%rcx), %rax
movq -0x8(%rbp), %rcx
movq 0x18(%rcx), %rcx
cmpq 0x18(%rcx), %rax
jle 0xd206b
movq -0x8(%rbp), %rax
movq %rax, -0x30(%rbp)
movq -0x20(%rbp), %rax
movzbl (%rax), %edi
movl $0x1, %esi
callq 0xd2110
movq -0x30(%rbp), %rdi
movq %rax, %rdx
movq -0x20(%rbp), %rax
movq 0x8(%rax), %rcx
leaq 0xe85be(%rip), %rsi     # 0x1ba5ee
movb $0x0, %al
callq 0x15bfb0
movq -0x20(%rbp), %rax
movq 0x8(%rax), %rax
movq -0x18(%rbp), %rcx
addq 0x8(%rcx), %rax
movq -0x8(%rbp), %rcx
movq 0x18(%rcx), %rcx
movq 0x18(%rcx), %rcx
addq $0x400, %rcx            # imm = 0x400
cmpq %rcx, %rax
jle 0xd2069
movq -0x20(%rbp), %rax
movb $0x1, 0x1(%rax)
jmp 0xd206d
jmp 0xd206b
jmp 0xd206d
addq $0x30, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/jsummers[P]deark/modules/macbinary.c
// Function: my_advfile_cbfn
static int my_advfile_cbfn(deark *c, struct de_advfile *advf,
	struct de_advfile_cbparams *afp)
{
	struct extract_ctx *ectx = (struct extract_ctx*)advf->userdata;

	if(afp->whattodo == DE_ADVFILE_WRITEMAIN) {
		dbuf_copy(c->infile, ectx->fki_data.pos, advf->mainfork.fork_len, afp->outf);
	}
	else if(afp->whattodo == DE_ADVFILE_WRITERSRC) {
		dbuf_copy(c->infile, ectx->fki_rsrc.pos, advf->rsrcfork.fork_len, afp->outf);
	}
	return 1;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
movq %rax, -0x20(%rbp)
movq -0x18(%rbp), %rax
cmpl $0x1, (%rax)
jne 0xd20d0
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rdi
movq -0x20(%rbp), %rax
movq 0x10(%rax), %rsi
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rdx
movq -0x18(%rbp), %rax
movq 0x8(%rax), %rcx
callq 0x166070
jmp 0xd2100
movq -0x18(%rbp), %rax
cmpl $0x2, (%rax)
jne 0xd20fe
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rdi
movq -0x20(%rbp), %rax
movq 0x20(%rax), %rsi
movq -0x10(%rbp), %rax
movq 0x40(%rax), %rdx
movq -0x18(%rbp), %rax
movq 0x8(%rax), %rcx
callq 0x166070
jmp 0xd2100
movl $0x1, %eax
addq $0x20, %rsp
popq %rbp
retq
nopl (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/jsummers[P]deark/modules/macrsrc.c
// Function: de_module_macrsrc
void de_module_macrsrc(deark *c, struct deark_module_info *mi)
{
	mi->id = "macrsrc";
	mi->desc = "Macintosh Resource Manager";
	mi->run_fn = de_run_macrsrc;
	mi->identify_fn = de_identify_macrsrc;
	mi->help_fn = de_help_macrsrc;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x10(%rbp), %rax
leaq 0xd0871(%rip), %rcx     # 0x1a29e8
movq %rcx, (%rax)
movq -0x10(%rbp), %rax
leaq 0xe849f(%rip), %rcx     # 0x1ba624
movq %rcx, 0x8(%rax)
movq -0x10(%rbp), %rax
leaq 0x2c(%rip), %rcx        # 0xd21c0
movq %rcx, 0x18(%rax)
movq -0x10(%rbp), %rax
leaq 0x1dd(%rip), %rcx       # 0xd2380
movq %rcx, 0x20(%rax)
movq -0x10(%rbp), %rax
leaq 0x2fe(%rip), %rcx       # 0xd24b0
movq %rcx, 0x28(%rax)
popq %rbp
retq
nopl (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/jsummers[P]deark/modules/macrsrc.c
// Function: de_identify_macrsrc
static int de_identify_macrsrc(deark *c)
{
	u8 b[16];
	i64 n[4];
	size_t k;

	if(de_getu32be(0)!=256) return 0;
	de_read(b, 0, 16);
	for(k=0; k<4; k++) {
		n[k] = de_getu32be_direct(&b[4*k]);
	}
	if(n[0]+n[2]>n[1]) return 0; // data can't go past map start
	if(n[3]<30) return 0; // minimum map len
	if(n[1]+n[3]>c->infile->len) return 0; // map can't go past eof
	// map should start with a copy of the header
	if(dbuf_memcmp(c->infile, n[1], (const void*)b, 16)) return 0;
	if(n[1]+n[3]==c->infile->len) return 100;
	return 75;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rdi
xorl %eax, %eax
movl %eax, %esi
callq 0x165470
cmpq $0x100, %rax            # imm = 0x100
je 0xd23b1
movl $0x0, -0x4(%rbp)
jmp 0xd249c
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rdi
leaq -0x20(%rbp), %rsi
xorl %eax, %eax
movl %eax, %edx
movl $0x10, %ecx
callq 0x164d10
movq $0x0, -0x48(%rbp)
cmpq $0x4, -0x48(%rbp)
jae 0xd2408
movq -0x48(%rbp), %rax
shlq $0x2, %rax
leaq -0x20(%rbp), %rdi
addq %rax, %rdi
callq 0x165430
movq %rax, %rcx
movq -0x48(%rbp), %rax
movq %rcx, -0x40(%rbp,%rax,8)
movq -0x48(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x48(%rbp)
jmp 0xd23d3
movq -0x40(%rbp), %rax
addq -0x30(%rbp), %rax
cmpq -0x38(%rbp), %rax
jle 0xd241f
movl $0x0, -0x4(%rbp)
jmp 0xd249c
cmpq $0x1e, -0x28(%rbp)
jge 0xd242f
movl $0x0, -0x4(%rbp)
jmp 0xd249c
movq -0x38(%rbp), %rax
addq -0x28(%rbp), %rax
movq -0x10(%rbp), %rcx
movq 0x18(%rcx), %rcx
cmpq 0x18(%rcx), %rax
jle 0xd244e
movl $0x0, -0x4(%rbp)
jmp 0xd249c
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rdi
movq -0x38(%rbp), %rsi
leaq -0x20(%rbp), %rdx
movl $0x10, %ecx
callq 0x166ab0
cmpl $0x0, %eax
je 0xd2476
movl $0x0, -0x4(%rbp)
jmp 0xd249c
movq -0x38(%rbp), %rax
addq -0x28(%rbp), %rax
movq -0x10(%rbp), %rcx
movq 0x18(%rcx), %rcx
cmpq 0x18(%rcx), %rax
jne 0xd2495
movl $0x64, -0x4(%rbp)
jmp 0xd249c
movl $0x4b, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x50, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/jsummers[P]deark/modules/macrsrc.c
// Function: finalize_icns_streams
static void finalize_icns_streams(deark *c, lctx *d)
{
	size_t i;

	for(i=0; i<d->num_icns_streams_used; i++) {
		if(d->icns_strm[i].tmpf) {
			finalize_icns_stream(c, d, d->icns_strm[i].tmpf);
			dbuf_close(d->icns_strm[i].tmpf);
			d->icns_strm[i].tmpf = NULL;
		}
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq $0x0, -0x18(%rbp)
movq -0x18(%rbp), %rax
movq -0x10(%rbp), %rcx
cmpq 0x48(%rcx), %rax
jae 0xd2732
movq -0x10(%rbp), %rax
addq $0x50, %rax
movq -0x18(%rbp), %rcx
shlq $0x4, %rcx
addq %rcx, %rax
cmpq $0x0, 0x8(%rax)
je 0xd271f
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
movq -0x10(%rbp), %rax
addq $0x50, %rax
movq -0x18(%rbp), %rcx
shlq $0x4, %rcx
addq %rcx, %rax
movq 0x8(%rax), %rdx
callq 0xd4b00
movq -0x10(%rbp), %rax
addq $0x50, %rax
movq -0x18(%rbp), %rcx
shlq $0x4, %rcx
addq %rcx, %rax
movq 0x8(%rax), %rdi
callq 0x1676a0
movq -0x10(%rbp), %rax
addq $0x50, %rax
movq -0x18(%rbp), %rcx
shlq $0x4, %rcx
addq %rcx, %rax
movq $0x0, 0x8(%rax)
jmp 0xd2721
movq -0x18(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x18(%rbp)
jmp 0xd2698
addq $0x20, %rsp
popq %rbp
retq
nopl (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/jsummers[P]deark/modules/macrsrc.c
// Function: finalize_psrc_stream
static void finalize_psrc_stream(deark *c, lctx *d)
{
	if(!d->psrc_stream) return;
	fmtutil_handle_photoshop_rsrc(c, d->psrc_stream, 0, d->psrc_stream->len, 0x1);
	dbuf_close(d->psrc_stream);
	d->psrc_stream = NULL;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x10(%rbp), %rax
cmpq $0x0, 0x38(%rax)
jne 0xd275d
jmp 0xd279d
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rax
movq 0x38(%rax), %rsi
movq -0x10(%rbp), %rax
movq 0x38(%rax), %rax
movq 0x18(%rax), %rcx
xorl %eax, %eax
movl %eax, %edx
movl $0x1, %r8d
callq 0x173bd0
movq -0x10(%rbp), %rax
movq 0x38(%rax), %rdi
callq 0x1676a0
movq -0x10(%rbp), %rax
movq $0x0, 0x38(%rax)
addq $0x10, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/jsummers[P]deark/modules/macrsrc.c
// Function: do_type_list
static void do_type_list(deark *c, lctx *d)
{
	i64 pos1 = d->typeListOffset_abs;
	i64 pos = pos1;
	i64 type_count_raw;
	i64 type_count;
	i64 k;

	de_dbg(c, "type list at %d", (int)pos1);
	de_dbg_indent(c, 1);
	type_count_raw = de_getu16be_p(&pos);
	type_count = (type_count_raw==0xffff)?0:(type_count_raw+1);
	de_dbg(c, "type count: %d", (int)type_count);

	for(k=0; k<type_count; k++) {
		de_dbg(c, "type record[%d] at %d", (int)k, (int)pos);
		de_dbg_indent(c, 1);
		do_type_item(c, d, pos1, k, pos);
		pos += 8;
		de_dbg_indent(c, -1);
	}
	de_dbg_indent(c, -1);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq 0x28(%rax), %rax
movq %rax, -0x18(%rbp)
movq -0x18(%rbp), %rax
movq %rax, -0x20(%rbp)
movq -0x8(%rbp), %rdi
movq -0x18(%rbp), %rax
movl %eax, %edx
leaq 0xe7f8e(%rip), %rsi     # 0x1ba773
movb $0x0, %al
callq 0x15b0d0
movq -0x8(%rbp), %rdi
movl $0x1, %esi
callq 0x15b560
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rdi
leaq -0x20(%rbp), %rsi
callq 0x165210
movq %rax, -0x28(%rbp)
cmpq $0xffff, -0x28(%rbp)    # imm = 0xFFFF
jne 0xd2821
xorl %eax, %eax
movq %rax, -0x40(%rbp)
jmp 0xd282d
movq -0x28(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x40(%rbp)
movq -0x40(%rbp), %rax
movq %rax, -0x30(%rbp)
movq -0x8(%rbp), %rdi
movq -0x30(%rbp), %rax
movl %eax, %edx
leaq 0xe7f3d(%rip), %rsi     # 0x1ba783
movb $0x0, %al
callq 0x15b0d0
movq $0x0, -0x38(%rbp)
movq -0x38(%rbp), %rax
cmpq -0x30(%rbp), %rax
jge 0xd28cc
movq -0x8(%rbp), %rdi
movq -0x38(%rbp), %rax
movl %eax, %edx
movq -0x20(%rbp), %rax
movl %eax, %ecx
leaq 0xe7f1c(%rip), %rsi     # 0x1ba792
movb $0x0, %al
callq 0x15b0d0
movq -0x8(%rbp), %rdi
movl $0x1, %esi
callq 0x15b560
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
movq -0x18(%rbp), %rdx
movq -0x38(%rbp), %rcx
movq -0x20(%rbp), %r8
callq 0xd28e0
movq -0x20(%rbp), %rax
addq $0x8, %rax
movq %rax, -0x20(%rbp)
movq -0x8(%rbp), %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
callq 0x15b560
movq -0x38(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x38(%rbp)
jmp 0xd2855
movq -0x8(%rbp), %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
callq 0x15b560
addq $0x40, %rsp
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O0/jsummers[P]deark/modules/macrsrc.c
// Function: do_type_item
static void do_type_item(deark *c, lctx *d, i64 type_list_offs,
	i64 idx, i64 pos1)
{
	i64 pos = pos1;
	UI count;
	i64 list_offs_rel;
	struct rsrctypeinfo rti;

	de_zeromem(&rti, sizeof(struct rsrctypeinfo));
	dbuf_read_fourcc(c->infile, pos, &rti.fcc, 4, 0x0);
	de_dbg(c, "resource type: '%s'", rti.fcc.id_dbgstr);
	pos += 4;
	rti.is_icns_type = is_icns_icon(c, d, &rti);

	// TODO: What other signatures should we include?
	if(rti.fcc.id==CODE_8BIM || rti.fcc.id==CODE_MeSa) {
		rti.is_psrc_type = 1;
	}

	count = (UI)(1+de_getu16be_p(&pos));
	de_dbg(c, "resource count: %u", count);
	list_offs_rel = de_getu16be_p(&pos);
	de_dbg(c, "list offset: (%d+)%d", (int)type_list_offs, (int)list_offs_rel);

	do_resource_list(c, d, &rti, type_list_offs+list_offs_rel, count);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x80, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq %r8, -0x28(%rbp)
movq -0x28(%rbp), %rax
movq %rax, -0x30(%rbp)
leaq -0x78(%rbp), %rdi
xorl %esi, %esi
movl $0x38, %edx
callq 0x19140
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rdi
movq -0x30(%rbp), %rsi
leaq -0x78(%rbp), %rdx
movl $0x4, %ecx
xorl %r8d, %r8d
callq 0x169860
movq -0x8(%rbp), %rdi
leaq -0x78(%rbp), %rdx
addq $0x10, %rdx
leaq 0xe7e61(%rip), %rsi     # 0x1ba7a8
movb $0x0, %al
callq 0x15b0d0
movq -0x30(%rbp), %rax
addq $0x4, %rax
movq %rax, -0x30(%rbp)
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
leaq -0x78(%rbp), %rdx
callq 0xd2a10
movl %eax, -0x48(%rbp)
cmpl $0x3842494d, -0x74(%rbp) # imm = 0x3842494D
je 0xd2980
cmpl $0x4d655361, -0x74(%rbp) # imm = 0x4D655361
jne 0xd2987
movl $0x1, -0x44(%rbp)
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rdi
leaq -0x30(%rbp), %rsi
callq 0x165210
addq $0x1, %rax
movl %eax, -0x34(%rbp)
movq -0x8(%rbp), %rdi
movl -0x34(%rbp), %edx
leaq 0xe7e0f(%rip), %rsi     # 0x1ba7bc
movb $0x0, %al
callq 0x15b0d0
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rdi
leaq -0x30(%rbp), %rsi
callq 0x165210
movq %rax, -0x40(%rbp)
movq -0x8(%rbp), %rdi
movq -0x18(%rbp), %rax
movl %eax, %edx
movq -0x40(%rbp), %rax
movl %eax, %ecx
leaq 0xe7d65(%rip), %rsi     # 0x1ba745
movb $0x0, %al
callq 0x15b0d0
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
movq -0x18(%rbp), %rcx
addq -0x40(%rbp), %rcx
movl -0x34(%rbp), %r8d
leaq -0x78(%rbp), %rdx
callq 0xd2ac0
addq $0x80, %rsp
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/jsummers[P]deark/modules/macrsrc.c
// Function: is_icns_icon
static int is_icns_icon(deark *c, lctx *d, struct rsrctypeinfo *rti)
{
	// TODO: There are many more icns icon types, but it's not clear
	// to me if any others are found in resource forks.
	switch(rti->fcc.id) {
	case CODE_icm_: case CODE_icm4: case CODE_icm8: // 16x12
	case CODE_ics_: case CODE_ics4: case CODE_ics8: // 16x16
	case CODE_ICN_: case CODE_ICON: case CODE_icl4: case CODE_icl8: // 32x32
		return 1;
	}
	return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq -0x20(%rbp), %rax
movl 0x4(%rax), %eax
movl %eax, -0x24(%rbp)
subl $0x49434e23, %eax       # imm = 0x49434E23
je 0xd2a9f
jmp 0xd2a33
movl -0x24(%rbp), %eax
subl $0x49434f4e, %eax       # imm = 0x49434F4E
je 0xd2a9f
jmp 0xd2a3f
movl -0x24(%rbp), %eax
subl $0x69636c34, %eax       # imm = 0x69636C34
je 0xd2a9f
jmp 0xd2a4b
movl -0x24(%rbp), %eax
subl $0x69636c38, %eax       # imm = 0x69636C38
je 0xd2a9f
jmp 0xd2a57
movl -0x24(%rbp), %eax
subl $0x69636d23, %eax       # imm = 0x69636D23
je 0xd2a9f
jmp 0xd2a63
movl -0x24(%rbp), %eax
subl $0x69636d34, %eax       # imm = 0x69636D34
je 0xd2a9f
jmp 0xd2a6f
movl -0x24(%rbp), %eax
subl $0x69636d38, %eax       # imm = 0x69636D38
je 0xd2a9f
jmp 0xd2a7b
movl -0x24(%rbp), %eax
subl $0x69637323, %eax       # imm = 0x69637323
je 0xd2a9f
jmp 0xd2a87
movl -0x24(%rbp), %eax
subl $0x69637334, %eax       # imm = 0x69637334
je 0xd2a9f
jmp 0xd2a93
movl -0x24(%rbp), %eax
subl $0x69637338, %eax       # imm = 0x69637338
jne 0xd2aa8
jmp 0xd2a9f
movl $0x1, -0x4(%rbp)
jmp 0xd2aaf
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/jsummers[P]deark/modules/macrsrc.c
// Function: do_resource_list
static void do_resource_list(deark *c, lctx *d, struct rsrctypeinfo *rti,
	i64 rsrc_list_offs, UI count)
{
	UI idx;
	i64 pos = rsrc_list_offs;

	de_dbg(c, "resource list at %d", (int)rsrc_list_offs);
	de_dbg_indent(c, 1);
	for(idx=0; idx<count; idx++) {
		de_dbg(c, "resource record[%u] at %"I64_FMT" (type '%s')", idx, pos,
			rti->fcc.id_dbgstr);
		de_dbg_indent(c, 1);
		do_resource_record(c, d, rti, pos, idx);
		de_dbg_indent(c, -1);
		pos += 12;
	}
	de_dbg_indent(c, -1);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movl %r8d, -0x24(%rbp)
movq -0x20(%rbp), %rax
movq %rax, -0x30(%rbp)
movq -0x8(%rbp), %rdi
movq -0x20(%rbp), %rax
movl %eax, %edx
leaq 0xe7cda(%rip), %rsi     # 0x1ba7cf
movb $0x0, %al
callq 0x15b0d0
movq -0x8(%rbp), %rdi
movl $0x1, %esi
callq 0x15b560
movl $0x0, -0x28(%rbp)
movl -0x28(%rbp), %eax
cmpl -0x24(%rbp), %eax
jae 0xd2b86
movq -0x8(%rbp), %rdi
movl -0x28(%rbp), %edx
movq -0x30(%rbp), %rcx
movq -0x18(%rbp), %r8
addq $0x10, %r8
leaq 0xe7cb0(%rip), %rsi     # 0x1ba7e3
movb $0x0, %al
callq 0x15b0d0
movq -0x8(%rbp), %rdi
movl $0x1, %esi
callq 0x15b560
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
movq -0x18(%rbp), %rdx
movq -0x30(%rbp), %rcx
movl -0x28(%rbp), %r8d
callq 0xd2ba0
movq -0x8(%rbp), %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
callq 0x15b560
movq -0x30(%rbp), %rax
addq $0xc, %rax
movq %rax, -0x30(%rbp)
movl -0x28(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x28(%rbp)
jmp 0xd2b11
movq -0x8(%rbp), %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
callq 0x15b560
addq $0x30, %rsp
popq %rbp
retq
nopw (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/jsummers[P]deark/modules/macrsrc.c
// Function: do_resource_name
static void do_resource_name(deark *c, lctx *d, struct rsrcinstanceinfo *rii)
{
	i64 nlen;

	nlen = (i64)de_getbyte(rii->name_offset);
	rii->name_raw_len = 1+nlen;
	rii->name = ucstring_create(c);
	dbuf_read_to_ucstring(c->infile, rii->name_offset+1, nlen, rii->name , 0, DE_ENCODING_MACROMAN);
	de_dbg(c, "name: \"%s\"", ucstring_getpsz_d(rii->name ));
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rdi
movq -0x18(%rbp), %rax
movq 0x18(%rax), %rsi
callq 0x165060
movzbl %al, %eax
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rcx
addq $0x1, %rcx
movq -0x18(%rbp), %rax
movq %rcx, 0x20(%rax)
movq -0x8(%rbp), %rdi
callq 0x1711d0
movq %rax, %rcx
movq -0x18(%rbp), %rax
movq %rcx, 0x28(%rax)
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rdi
movq -0x18(%rbp), %rax
movq 0x18(%rax), %rsi
addq $0x1, %rsi
movq -0x20(%rbp), %rdx
movq -0x18(%rbp), %rax
movq 0x28(%rax), %rcx
xorl %r8d, %r8d
movl $0x11, %r9d
callq 0x1669f0
movq -0x8(%rbp), %rax
movq %rax, -0x28(%rbp)
movq -0x18(%rbp), %rax
movq 0x28(%rax), %rdi
callq 0x172650
movq -0x28(%rbp), %rdi
movq %rax, %rdx
leaq 0xdb1fb(%rip), %rsi     # 0x1ae1d0
movb $0x0, %al
callq 0x15b0d0
addq $0x30, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/jsummers[P]deark/modules/macrsrc.c
// Function: extract_raw_rsrc
static void extract_raw_rsrc(deark *c, lctx *d, struct rsrctypeinfo *rti,
	struct rsrcinstanceinfo *rii, i64 dpos, i64 dlen)
{
	de_finfo *fi = NULL;
	de_ucstring *s = NULL;

	fi = de_finfo_create(c);
	s = ucstring_create(c);

	ucstring_append_sz(s, rti->fcc.id_sanitized_sz, DE_ENCODING_LATIN1);
	ucstring_strip_trailing_spaces(s);
	if(rii->attribs&0x01) {
		ucstring_append_sz(s, ".cmpr", DE_ENCODING_LATIN1);
	}
	else {
		ucstring_append_sz(s, ".bin", DE_ENCODING_LATIN1);
	}
	de_finfo_set_name_from_ucstring(c, fi, s, 0);
	dbuf_create_file_from_slice(c->infile, dpos, dlen, NULL, fi, 0x0);

	de_finfo_destroy(c, fi);
	ucstring_destroy(s);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq %r8, -0x28(%rbp)
movq %r9, -0x30(%rbp)
movq $0x0, -0x38(%rbp)
movq $0x0, -0x40(%rbp)
movq -0x8(%rbp), %rdi
callq 0x15d230
movq %rax, -0x38(%rbp)
movq -0x8(%rbp), %rdi
callq 0x1711d0
movq %rax, -0x40(%rbp)
movq -0x40(%rbp), %rdi
movq -0x18(%rbp), %rsi
addq $0x8, %rsi
movl $0x5, %edx
callq 0x1715e0
movq -0x40(%rbp), %rdi
callq 0x171360
movq -0x20(%rbp), %rax
movzbl 0x8(%rax), %eax
andl $0x1, %eax
cmpl $0x0, %eax
je 0xd34f0
movq -0x40(%rbp), %rdi
leaq 0xe747a(%rip), %rsi     # 0x1ba95e
movl $0x5, %edx
callq 0x1715e0
jmp 0xd3505
movq -0x40(%rbp), %rdi
leaq 0xedd0b(%rip), %rsi     # 0x1c1206
movl $0x5, %edx
callq 0x1715e0
movq -0x8(%rbp), %rdi
movq -0x38(%rbp), %rsi
movq -0x40(%rbp), %rdx
xorl %ecx, %ecx
callq 0x15d2c0
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rdi
movq -0x28(%rbp), %rsi
movq -0x30(%rbp), %rdx
movq -0x38(%rbp), %r8
xorl %eax, %eax
movl %eax, %ecx
xorl %r9d, %r9d
callq 0x166be0
movq -0x8(%rbp), %rdi
movq -0x38(%rbp), %rsi
callq 0x15d260
movq -0x40(%rbp), %rdi
callq 0x171750
addq $0x40, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/jsummers[P]deark/modules/macrsrc.c
// Function: looks_like_pict
static int looks_like_pict(deark *c, lctx *d, struct rsrcinstanceinfo *rii,
	i64 pos, i64 len)
{
	if(len>=12 && !dbuf_memcmp(c->infile, pos+10, "\x11\x01", 2)) {
		return 1; // PICTv1
	}
	if(len>=16 && !dbuf_memcmp(c->infile, pos+10, "\x00\x11\x02\xff\x0c\x00", 6)) {
		return 1; // PICTv2
	}
	return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq %rcx, -0x28(%rbp)
movq %r8, -0x30(%rbp)
cmpq $0xc, -0x30(%rbp)
jl 0xd35b2
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rdi
movq -0x28(%rbp), %rsi
addq $0xa, %rsi
leaq 0xe73ca(%rip), %rdx     # 0x1ba964
movl $0x2, %ecx
callq 0x166ab0
cmpl $0x0, %eax
jne 0xd35b2
movl $0x1, -0x4(%rbp)
jmp 0xd35ef
cmpq $0x10, -0x30(%rbp)
jl 0xd35e8
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rdi
movq -0x28(%rbp), %rsi
addq $0xa, %rsi
leaq 0xe7614(%rip), %rdx     # 0x1babe4
movl $0x6, %ecx
callq 0x166ab0
cmpl $0x0, %eax
jne 0xd35e8
movl $0x1, -0x4(%rbp)
jmp 0xd35ef
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x30, %rsp
popq %rbp
retq
nopl (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/jsummers[P]deark/modules/macrsrc.c
// Function: get_icns_stream
static dbuf *get_icns_stream(deark *c, lctx *d, int id)
{
	size_t entry = 0;
	size_t i;

	for(i=0; i<d->num_icns_streams_used; i++) {
		if(d->icns_strm[i].id == id) {
			entry = i;
			goto found;
		}
	}

	if(d->num_icns_streams_used >= MAX_ICNS_STREAMS) {
		entry = MAX_ICNS_STREAMS - 1; // stream of last resort
	}
	else {
		entry = d->num_icns_streams_used++;
		d->icns_strm[entry].id = id;
	}

found:
	if(!d->icns_strm[entry].tmpf) {
		d->icns_strm[entry].tmpf = dbuf_create_membuf(c, 0, 0);
	}
	return d->icns_strm[entry].tmpf;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movl %edx, -0x14(%rbp)
movq $0x0, -0x20(%rbp)
movq $0x0, -0x28(%rbp)
movq -0x28(%rbp), %rax
movq -0x10(%rbp), %rcx
cmpq 0x48(%rcx), %rax
jae 0xd3665
movq -0x10(%rbp), %rax
addq $0x50, %rax
movq -0x28(%rbp), %rcx
shlq $0x4, %rcx
addq %rcx, %rax
movl (%rax), %eax
cmpl -0x14(%rbp), %eax
jne 0xd3655
movq -0x28(%rbp), %rax
movq %rax, -0x20(%rbp)
jmp 0xd36ab
jmp 0xd3657
movq -0x28(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x28(%rbp)
jmp 0xd3623
movq -0x10(%rbp), %rax
cmpq $0x40, 0x48(%rax)
jb 0xd367a
movq $0x3f, -0x20(%rbp)
jmp 0xd36a9
movq -0x10(%rbp), %rcx
movq 0x48(%rcx), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, 0x48(%rcx)
movq %rax, -0x20(%rbp)
movl -0x14(%rbp), %ecx
movq -0x10(%rbp), %rax
addq $0x50, %rax
movq -0x20(%rbp), %rdx
shlq $0x4, %rdx
addq %rdx, %rax
movl %ecx, (%rax)
jmp 0xd36ab
movq -0x10(%rbp), %rax
addq $0x50, %rax
movq -0x20(%rbp), %rcx
shlq $0x4, %rcx
addq %rcx, %rax
cmpq $0x0, 0x8(%rax)
jne 0xd36ee
movq -0x8(%rbp), %rdi
xorl %eax, %eax
movl %eax, %esi
xorl %edx, %edx
callq 0x168020
movq %rax, %rcx
movq -0x10(%rbp), %rax
addq $0x50, %rax
movq -0x20(%rbp), %rdx
shlq $0x4, %rdx
addq %rdx, %rax
movq %rcx, 0x8(%rax)
movq -0x10(%rbp), %rax
addq $0x50, %rax
movq -0x20(%rbp), %rcx
shlq $0x4, %rcx
addq %rcx, %rax
movq 0x8(%rax), %rax
addq $0x30, %rsp
popq %rbp
retq
nopl (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/jsummers[P]deark/modules/macrsrc.c
// Function: do_psrc_resource
static void do_psrc_resource(deark *c, lctx *d, struct rsrctypeinfo *rti,
	struct rsrcinstanceinfo *rii, i64 dpos, i64 dlen)
{
	if(!d->psrc_stream) {
		open_psrc_stream(c, d);
	}

	// Convert this exploded format to the normal Photoshop Resources format,
	// which we will eventually write to a file.
	// It would be messy to implement a way to directly use the decoder in the
	// psd module. And even if we did that, the option to do this conversion
	// might still be useful.

	de_dbg(c, "[Photoshop resource]");
	dbuf_write(d->psrc_stream, rti->fcc.bytes, 4);
	dbuf_writei16be(d->psrc_stream, (i64)rii->id);
	if(rii->has_name) {
		dbuf_copy(c->infile, rii->name_offset, rii->name_raw_len, d->psrc_stream);
		if(rii->name_raw_len%2) {
			dbuf_writebyte(d->psrc_stream, 0); // padding byte for name
		}
	}
	else {
		dbuf_write_zeroes(d->psrc_stream, 2);
	}
	dbuf_writeu32be(d->psrc_stream, dlen);
	dbuf_copy(c->infile, dpos, dlen, d->psrc_stream);
	if(dlen%2) {
		dbuf_writebyte(d->psrc_stream, 0); // padding byte for data
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq %r8, -0x28(%rbp)
movq %r9, -0x30(%rbp)
movq -0x10(%rbp), %rax
cmpq $0x0, 0x38(%rax)
jne 0xd3748
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
callq 0xd4790
movq -0x8(%rbp), %rdi
leaq 0xe7214(%rip), %rsi     # 0x1ba967
movb $0x0, %al
callq 0x15b0d0
movq -0x10(%rbp), %rax
movq 0x38(%rax), %rdi
movq -0x18(%rbp), %rsi
movl $0x4, %edx
callq 0x166170
movq -0x10(%rbp), %rax
movq 0x38(%rax), %rdi
movq -0x20(%rbp), %rax
movslq (%rax), %rsi
callq 0x168ad0
movq -0x20(%rbp), %rax
cmpb $0x0, 0x9(%rax)
je 0xd37dc
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rdi
movq -0x20(%rbp), %rax
movq 0x18(%rax), %rsi
movq -0x20(%rbp), %rax
movq 0x20(%rax), %rdx
movq -0x10(%rbp), %rax
movq 0x38(%rax), %rcx
callq 0x166070
movq -0x20(%rbp), %rax
movq 0x20(%rax), %rax
movl $0x2, %ecx
cqto
idivq %rcx
cmpq $0x0, %rdx
je 0xd37da
movq -0x10(%rbp), %rax
movq 0x38(%rax), %rdi
xorl %esi, %esi
callq 0x168380
jmp 0xd37ee
movq -0x10(%rbp), %rax
movq 0x38(%rax), %rdi
movl $0x2, %esi
callq 0x1685f0
movq -0x10(%rbp), %rax
movq 0x38(%rax), %rdi
movq -0x30(%rbp), %rsi
callq 0x168b80
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rdi
movq -0x28(%rbp), %rsi
movq -0x30(%rbp), %rdx
movq -0x10(%rbp), %rax
movq 0x38(%rax), %rcx
callq 0x166070
movq -0x30(%rbp), %rax
movl $0x2, %ecx
cqto
idivq %rcx
cmpq $0x0, %rdx
je 0xd383f
movq -0x10(%rbp), %rax
movq 0x38(%rax), %rdi
xorl %esi, %esi
callq 0x168380
addq $0x30, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/jsummers[P]deark/modules/macrsrc.c
// Function: do_SICN_resource
static void do_SICN_resource(deark *c, lctx *d, struct rsrctypeinfo *rti,
	struct rsrcinstanceinfo *rii, i64 pos1, i64 len)
{
	i64 numicons;

	numicons = len/32;
	de_dbg(c, "num icons: %"I64_FMT, numicons);
	if(numicons>1 && d->combine_SICN) {
		do_SICN_resource_gallery(c, d, rti, rii, pos1, numicons);
	}
	else {
		do_SICN_resource_1(c, d, rti, rii, pos1, numicons);
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq %r8, -0x28(%rbp)
movq %r9, -0x30(%rbp)
movq -0x30(%rbp), %rax
movl $0x20, %ecx
cqto
idivq %rcx
movq %rax, -0x38(%rbp)
movq -0x8(%rbp), %rdi
movq -0x38(%rbp), %rdx
leaq 0xdc76f(%rip), %rsi     # 0x1b0dd0
movb $0x0, %al
callq 0x15b0d0
cmpq $0x1, -0x38(%rbp)
jle 0xd469b
movq -0x10(%rbp), %rax
movzbl 0x1(%rax), %eax
cmpl $0x0, %eax
je 0xd469b
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
movq -0x18(%rbp), %rdx
movq -0x20(%rbp), %rcx
movq -0x28(%rbp), %r8
movq -0x38(%rbp), %r9
callq 0xd47d0
jmp 0xd46b8
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
movq -0x18(%rbp), %rdx
movq -0x20(%rbp), %rcx
movq -0x28(%rbp), %r8
movq -0x38(%rbp), %r9
callq 0xd49e0
addq $0x40, %rsp
popq %rbp
retq
nop
// File: /workspace/github_c_makefile_star2_O0/jsummers[P]deark/modules/macrsrc.c
// Function: set_resource_filename
static void set_resource_filename(deark *c, lctx *d, de_finfo *fi,
	struct rsrctypeinfo *rti, struct rsrcinstanceinfo *rii, const char *token)
{
	de_ucstring *tmpname = NULL;

	tmpname = ucstring_create(c);
	if(c->filenames_from_file && ucstring_isnonempty(rii->name)) {
		ucstring_append_ucstring(tmpname, rii->name);
		ucstring_append_sz(tmpname, ".", DE_ENCODING_LATIN1);
	}

	if(token) {
		ucstring_append_sz(tmpname, token, DE_ENCODING_LATIN1);
	}
	else {
		ucstring_append_sz(tmpname, rti->fcc.id_sanitized_sz, DE_ENCODING_LATIN1);
	}
	de_finfo_set_name_from_ucstring(c, fi, tmpname, 0);
	ucstring_destroy(tmpname);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq %r8, -0x28(%rbp)
movq %r9, -0x30(%rbp)
movq $0x0, -0x38(%rbp)
movq -0x8(%rbp), %rdi
callq 0x1711d0
movq %rax, -0x38(%rbp)
movq -0x8(%rbp), %rax
movzbl 0xd0(%rax), %eax
cmpl $0x0, %eax
je 0xd473d
movq -0x28(%rbp), %rax
movq 0x28(%rax), %rdi
callq 0x1717f0
cmpl $0x0, %eax
je 0xd473d
movq -0x38(%rbp), %rdi
movq -0x28(%rbp), %rax
movq 0x28(%rax), %rsi
callq 0x171460
movq -0x38(%rbp), %rdi
leaq 0xf2a70(%rip), %rsi     # 0x1c71a3
movl $0x5, %edx
callq 0x1715e0
cmpq $0x0, -0x30(%rbp)
je 0xd4758
movq -0x38(%rbp), %rdi
movq -0x30(%rbp), %rsi
movl $0x5, %edx
callq 0x1715e0
jmp 0xd476e
movq -0x38(%rbp), %rdi
movq -0x20(%rbp), %rsi
addq $0x8, %rsi
movl $0x5, %edx
callq 0x1715e0
movq -0x8(%rbp), %rdi
movq -0x18(%rbp), %rsi
movq -0x38(%rbp), %rdx
xorl %ecx, %ecx
callq 0x15d2c0
movq -0x38(%rbp), %rdi
callq 0x171750
addq $0x40, %rsp
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O0/jsummers[P]deark/modules/macrsrc.c
// Function: do_SICN_resource_1
static void do_SICN_resource_1(deark *c, lctx *d, struct rsrctypeinfo *rti,
	struct rsrcinstanceinfo *rii, i64 pos1, i64 numicons)
{
	de_finfo *fi = NULL;
	de_bitmap *img = NULL;
	i64 i;

	fi = de_finfo_create(c);
	set_resource_filename(c, d, fi, rti, rii, NULL);
	img = de_bitmap_create(c, 16, 16, 1);

	for(i=0; i<numicons; i++) {
		de_bitmap_rect(img, 0, 0, img->width, img->height, DE_STOCKCOLOR_BLACK, 0);
		de_convert_image_bilevel(c->infile, pos1+32*i, 2, img, DE_CVTF_WHITEISZERO);
		de_bitmap_write_to_file_finfo(img, fi, DE_CREATEFLAG_IS_BWIMG);
	}

	de_bitmap_destroy(img);
	de_finfo_destroy(c, fi);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq %r8, -0x28(%rbp)
movq %r9, -0x30(%rbp)
movq $0x0, -0x38(%rbp)
movq $0x0, -0x40(%rbp)
movq -0x8(%rbp), %rdi
callq 0x15d230
movq %rax, -0x38(%rbp)
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
movq -0x38(%rbp), %rdx
movq -0x18(%rbp), %rcx
movq -0x20(%rbp), %r8
xorl %eax, %eax
movl %eax, %r9d
callq 0xd46c0
movq -0x8(%rbp), %rdi
movl $0x10, %edx
movl $0x1, %ecx
movq %rdx, %rsi
callq 0x16b750
movq %rax, -0x40(%rbp)
movq $0x0, -0x48(%rbp)
movq -0x48(%rbp), %rax
cmpq -0x30(%rbp), %rax
jge 0xd4ae4
movq -0x40(%rbp), %rdi
movq -0x40(%rbp), %rax
movq 0x8(%rax), %rcx
movq -0x40(%rbp), %rax
movq 0x10(%rax), %r8
xorl %eax, %eax
movl %eax, %edx
movl $0xff000000, %r9d       # imm = 0xFF000000
xorl %eax, %eax
movq %rdx, %rsi
movl $0x0, (%rsp)
callq 0x16cdc0
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rdi
movq -0x28(%rbp), %rsi
movq -0x48(%rbp), %rax
shlq $0x5, %rax
addq %rax, %rsi
movq -0x40(%rbp), %rcx
movl $0x2, %edx
movl $0x1, %r8d
callq 0x16bee0
movq -0x40(%rbp), %rdi
movq -0x38(%rbp), %rsi
movl $0x8, %edx
callq 0x16afa0
movq -0x48(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x48(%rbp)
jmp 0xd4a5d
movq -0x40(%rbp), %rdi
callq 0x16af60
movq -0x8(%rbp), %rdi
movq -0x38(%rbp), %rsi
callq 0x15d260
addq $0x50, %rsp
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O0/jsummers[P]deark/modules/macrsrc.c
// Function: finalize_icns_stream
static void finalize_icns_stream(deark *c, lctx *d, dbuf *tmpf)
{
	dbuf *outf = NULL;

	if(!tmpf) return;
	outf = dbuf_create_output_file(c, "icns", NULL, 0);
	dbuf_writeu32be(outf, CODE_icns);
	dbuf_writeu32be(outf, 8+tmpf->len);
	dbuf_copy(tmpf, 0, tmpf->len, outf);
	dbuf_close(outf);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq $0x0, -0x20(%rbp)
cmpq $0x0, -0x18(%rbp)
jne 0xd4b25
jmp 0xd4b84
movq -0x8(%rbp), %rdi
leaq 0xdddeb(%rip), %rsi     # 0x1b291b
xorl %eax, %eax
movl %eax, %edx
xorl %ecx, %ecx
callq 0x166c60
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rdi
movl $0x69636e73, %esi       # imm = 0x69636E73
callq 0x168b80
movq -0x20(%rbp), %rdi
movq -0x18(%rbp), %rax
movq 0x18(%rax), %rsi
addq $0x8, %rsi
callq 0x168b80
movq -0x18(%rbp), %rdi
movq -0x18(%rbp), %rax
movq 0x18(%rax), %rdx
movq -0x20(%rbp), %rcx
xorl %eax, %eax
movl %eax, %esi
callq 0x166070
movq -0x20(%rbp), %rdi
callq 0x1676a0
addq $0x20, %rsp
popq %rbp
retq
nopw (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/jsummers[P]deark/modules/lzexe.c
// Function: de_module_lzexe
void de_module_lzexe(deark *c, struct deark_module_info *mi)
{
	mi->id = "lzexe";
	mi->desc = "LZEXE-compressed EXE";
	mi->run_fn = de_run_lzexe;
	mi->help_fn = de_help_lzexe;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x10(%rbp), %rax
leaq 0xe6044(%rip), %rcx     # 0x1babeb
movq %rcx, (%rax)
movq -0x10(%rbp), %rax
leaq 0xe603c(%rip), %rcx     # 0x1babf1
movq %rcx, 0x8(%rax)
movq -0x10(%rbp), %rax
leaq 0x1c(%rip), %rcx        # 0xd4be0
movq %rcx, 0x18(%rax)
movq -0x10(%rbp), %rax
leaq 0x43d(%rip), %rcx       # 0xd5010
movq %rcx, 0x28(%rax)
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/jsummers[P]deark/modules/lzexe.c
// Function: get_lzexe_subfmt_name
static const char *get_lzexe_subfmt_name(int n)
{
	const char *name = NULL;

	switch(n) {
	case LZEXE_VER_090: name = "v0.90"; break;
	case LZEXE_VER_091: name = "v0.91"; break;
	case LZEXE_VER_091E: name = "v0.91e"; break;
	case LZEXE_VER_LHARK_SFX: name = "v0.91-LHARK-SFX"; break;
	case LZEXE_VER_PCX2EXE: name = "v0.91-PCX2EXE"; break;
	}
	return name?name:"?";
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movl %edi, -0x4(%rbp)
movq $0x0, -0x10(%rbp)
movl -0x4(%rbp), %eax
movl %eax, -0x14(%rbp)
subl $0x1, %eax
je 0xd5096
jmp 0xd506c
movl -0x14(%rbp), %eax
subl $0x2, %eax
je 0xd50a3
jmp 0xd5076
movl -0x14(%rbp), %eax
subl $0x3, %eax
je 0xd50b0
jmp 0xd5080
movl -0x14(%rbp), %eax
subl $0x66, %eax
je 0xd50bd
jmp 0xd508a
movl -0x14(%rbp), %eax
subl $0xca, %eax
je 0xd50ca
jmp 0xd50d5
leaq 0xe5c37(%rip), %rax     # 0x1bacd4
movq %rax, -0x10(%rbp)
jmp 0xd50d5
leaq 0xe5c30(%rip), %rax     # 0x1bacda
movq %rax, -0x10(%rbp)
jmp 0xd50d5
leaq 0xe5c29(%rip), %rax     # 0x1bace0
movq %rax, -0x10(%rbp)
jmp 0xd50d5
leaq 0xe5c23(%rip), %rax     # 0x1bace7
movq %rax, -0x10(%rbp)
jmp 0xd50d5
leaq 0xe5c26(%rip), %rax     # 0x1bacf7
movq %rax, -0x10(%rbp)
cmpq $0x0, -0x10(%rbp)
je 0xd50e6
movq -0x10(%rbp), %rax
movq %rax, -0x20(%rbp)
jmp 0xd50f3
leaq 0xe2b40(%rip), %rax     # 0x1b7c2d
movq %rax, -0x20(%rbp)
jmp 0xd50f3
movq -0x20(%rbp), %rax
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/jsummers[P]deark/modules/lzexe.c
// Function: do_read_header
static void do_read_header(deark *c, lctx *d)
{
	d->host_minmem = (UI)de_getu16le(10);
	d->host_maxmem = (UI)de_getu16le(12);

	if(d->host_ei->regCS < 0) {
		// CS is signed. If it's ever negative in an LZEXE'd file, I'm not sure
		// how to handle that.
		d->errflag = 1;
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rdi
movl $0xa, %esi
callq 0x165280
movl %eax, %ecx
movq -0x10(%rbp), %rax
movl %ecx, 0x20(%rax)
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rdi
movl $0xc, %esi
callq 0x165280
movl %eax, %ecx
movq -0x10(%rbp), %rax
movl %ecx, 0x24(%rax)
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rax
cmpq $0x0, 0x20(%rax)
jge 0xd5160
movq -0x10(%rbp), %rax
movl $0x1, 0x4(%rax)
addq $0x10, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/jsummers[P]deark/modules/lzexe.c
// Function: read_reloc_tbl
static void read_reloc_tbl(deark *c, lctx *d)
{
	d->end_of_reloc_tbl = d->ephdr_pos + d->ephdr.field6;
	if(d->end_of_reloc_tbl > c->infile->len) {
		d->errflag = 1;
		goto done;
	}
	if(d->ver==LZEXE_VER_090) {
		do_decode_reloc_tbl_v090(c, d);
	}
	else {
		do_decode_reloc_tbl_v091(c, d);
	}
done:
	;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq 0x28(%rax), %rcx
movq -0x10(%rbp), %rax
addq 0x68(%rax), %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x30(%rax)
movq -0x10(%rbp), %rax
movq 0x30(%rax), %rax
movq -0x8(%rbp), %rcx
movq 0x18(%rcx), %rcx
cmpq 0x18(%rcx), %rax
jle 0xd542b
movq -0x10(%rbp), %rax
movl $0x1, 0x4(%rax)
jmp 0xd5452
movq -0x10(%rbp), %rax
cmpl $0x1, (%rax)
jne 0xd5443
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
callq 0xd5ad0
jmp 0xd5450
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
callq 0xd5b30
jmp 0xd5452
addq $0x10, %rsp
popq %rbp
retq
nopl (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/jsummers[P]deark/modules/lzexe.c
// Function: do_decode_reloc_tbl_v090
static void do_decode_reloc_tbl_v090(deark *c, lctx *d)
{
	i64 pos;
	i64 endpos;

	pos = d->ephdr_pos + 413;
	endpos = d->end_of_reloc_tbl;
	if(!fmtutil_decompress_exepack_reloc_tbl(c, pos, endpos, d->guest_reloc_table)) {
		d->errflag = 1;
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq 0x28(%rax), %rax
addq $0x19d, %rax            # imm = 0x19D
movq %rax, -0x18(%rbp)
movq -0x10(%rbp), %rax
movq 0x30(%rax), %rax
movq %rax, -0x20(%rbp)
movq -0x8(%rbp), %rdi
movq -0x18(%rbp), %rsi
movq -0x20(%rbp), %rdx
movq -0x10(%rbp), %rax
movq 0x80(%rax), %rcx
callq 0x179880
cmpl $0x0, %eax
jne 0xd5b2a
movq -0x10(%rbp), %rax
movl $0x1, 0x4(%rax)
addq $0x20, %rsp
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O0/jsummers[P]deark/modules/lzexe.c
// Function: do_decode_reloc_tbl_v091
static void do_decode_reloc_tbl_v091(deark *c, lctx *d)
{
	i64 ipos;
	int reloc_count = 0;
	UI reloc = 0;

	ipos = d->ephdr_pos + 344;
	de_dbg(c, "compressed reloc table: pos=%"I64_FMT, ipos);
	de_dbg_indent(c, 1);

	while(1) {
		u8 x;

		if(ipos>=d->end_of_reloc_tbl || reloc_count>65535) {
			d->errflag = 1;
			goto done;
		}

		x = (UI)de_getbyte_p(&ipos);
		if(x==0) {
			UI x2;

			x2 = (UI)de_getu16le_p(&ipos);
			if(x2==0) {
				reloc += 0xfff0;
				continue;
			}
			else if(x2==1) {
				break;
			}
			else {
				reloc += x2;
			}
		}
		else {
			reloc += (UI)x;
		}

		de_dbg2(c, "reloc: %05x", reloc);
		dbuf_writeu16le(d->guest_reloc_table, (i64)(reloc&0x0f));
		dbuf_writeu16le(d->guest_reloc_table, (i64)(reloc>>4));
		reloc_count++;
	}
	de_dbg(c, "reloc count: %d", (int)reloc_count);

done:
	de_dbg_indent(c, -1);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movl $0x0, -0x1c(%rbp)
movl $0x0, -0x20(%rbp)
movq -0x10(%rbp), %rax
movq 0x28(%rax), %rax
addq $0x158, %rax            # imm = 0x158
movq %rax, -0x18(%rbp)
movq -0x8(%rbp), %rdi
movq -0x18(%rbp), %rdx
leaq 0xe51f4(%rip), %rsi     # 0x1bad63
movb $0x0, %al
callq 0x15b0d0
movq -0x8(%rbp), %rdi
movl $0x1, %esi
callq 0x15b560
movq -0x18(%rbp), %rax
movq -0x10(%rbp), %rcx
cmpq 0x30(%rcx), %rax
jge 0xd5b9b
cmpl $0xffff, -0x1c(%rbp)    # imm = 0xFFFF
jle 0xd5bab
movq -0x10(%rbp), %rax
movl $0x1, 0x4(%rax)
jmp 0xd5c7d
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rdi
leaq -0x18(%rbp), %rsi
callq 0x165170
movzbl %al, %eax
movb %al, -0x21(%rbp)
movzbl -0x21(%rbp), %eax
cmpl $0x0, %eax
jne 0xd5c07
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rdi
leaq -0x18(%rbp), %rsi
callq 0x1652c0
movl %eax, -0x28(%rbp)
cmpl $0x0, -0x28(%rbp)
jne 0xd5bf2
movl -0x20(%rbp), %eax
addl $0xfff0, %eax           # imm = 0xFFF0
movl %eax, -0x20(%rbp)
jmp 0xd5b84
cmpl $0x1, -0x28(%rbp)
jne 0xd5bfa
jmp 0xd5c68
movl -0x28(%rbp), %eax
addl -0x20(%rbp), %eax
movl %eax, -0x20(%rbp)
jmp 0xd5c05
jmp 0xd5c11
movzbl -0x21(%rbp), %eax
addl -0x20(%rbp), %eax
movl %eax, -0x20(%rbp)
movq -0x8(%rbp), %rdi
movl -0x20(%rbp), %edx
leaq 0xe5164(%rip), %rsi     # 0x1bad83
movb $0x0, %al
callq 0x15b350
movq -0x10(%rbp), %rax
movq 0x80(%rax), %rdi
movl -0x20(%rbp), %eax
andl $0xf, %eax
movl %eax, %eax
movl %eax, %esi
callq 0x168a10
movq -0x10(%rbp), %rax
movq 0x80(%rax), %rdi
movl -0x20(%rbp), %eax
shrl $0x4, %eax
movl %eax, %eax
movl %eax, %esi
callq 0x168a10
movl -0x1c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1c(%rbp)
jmp 0xd5b84
movq -0x8(%rbp), %rdi
movl -0x1c(%rbp), %edx
leaq 0xe5119(%rip), %rsi     # 0x1bad8f
movb $0x0, %al
callq 0x15b0d0
movq -0x8(%rbp), %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
callq 0x15b560
addq $0x30, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/jsummers[P]deark/modules/lzexe.c
// Function: fill_bitbuf
static void fill_bitbuf(deark *c, lctx *d)
{
	UI i;

	if(d->errflag) return;
	if(d->dcmpr_cur_ipos+2 > d->ephdr_pos)
	{
		d->errflag = 1;
		return;
	}

	for(i=0; i<2; i++) {
		u8 b;
		b = de_getbyte_p(&d->dcmpr_cur_ipos);
		de_bitbuf_lowlevel_add_byte(&d->bbll, b);
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x10(%rbp), %rax
cmpl $0x0, 0x4(%rax)
je 0xd5d7c
jmp 0xd5de9
movq -0x10(%rbp), %rax
movq 0x90(%rax), %rax
addq $0x2, %rax
movq -0x10(%rbp), %rcx
cmpq 0x28(%rcx), %rax
jle 0xd5da2
movq -0x10(%rbp), %rax
movl $0x1, 0x4(%rax)
jmp 0xd5de9
movl $0x0, -0x14(%rbp)
cmpl $0x2, -0x14(%rbp)
jae 0xd5de9
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rdi
movq -0x10(%rbp), %rsi
addq $0x90, %rsi
callq 0x165170
movb %al, -0x15(%rbp)
movq -0x10(%rbp), %rdi
addq $0x98, %rdi
movzbl -0x15(%rbp), %esi
callq 0x16a230
movl -0x14(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x14(%rbp)
jmp 0xd5da9
addq $0x20, %rsp
popq %rbp
retq
nop
// File: /workspace/github_c_makefile_star2_O0/jsummers[P]deark/modules/nufx.c
// Function: de_module_nufx
void de_module_nufx(deark *c, struct deark_module_info *mi)
{
	mi->id = "nufx";
	mi->desc = "NuFX / ShrinkIt";
	mi->run_fn = de_run_nufx;
	mi->identify_fn = de_identify_nufx;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x10(%rbp), %rax
leaq 0xe5075(%rip), %rcx     # 0x1bae7c
movq %rcx, (%rax)
movq -0x10(%rbp), %rax
leaq 0xe506c(%rip), %rcx     # 0x1bae81
movq %rcx, 0x8(%rax)
movq -0x10(%rbp), %rax
leaq 0x1c(%rip), %rcx        # 0xd5e40
movq %rcx, 0x18(%rax)
movq -0x10(%rbp), %rax
leaq 0x27d(%rip), %rcx       # 0xd60b0
movq %rcx, 0x20(%rax)
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/jsummers[P]deark/modules/nufx.c
// Function: destroy_record
static void destroy_record(deark *c, struct nufx_record *rec)
{
	if(!rec) return;
	ucstring_destroy(rec->filename);
	ucstring_destroy(rec->filename_old);
	de_free(c, rec->threads);
	de_free(c, rec);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
cmpq $0x0, -0x10(%rbp)
jne 0xd6379
jmp 0xd63ba
movq -0x10(%rbp), %rax
movq 0x98(%rax), %rdi
callq 0x171750
movq -0x10(%rbp), %rax
movq 0x90(%rax), %rdi
callq 0x171750
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rax
movq 0xa0(%rax), %rsi
callq 0x15b820
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
callq 0x15b820
addq $0x10, %rsp
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O0/jsummers[P]deark/modules/nufx.c
// Function: do_nufx_record
static void do_nufx_record(deark *c,
	struct nufx_ctx *d, struct nufx_record *rec)
{
	int saved_indent_level;
	UI id;

	de_dbg_indent_save(c, &saved_indent_level);

	id = (UI)de_getu32be(rec->hdr_pos);
	if(id != 0x4ef546d8) {
		de_err(c, "Expected record not found at %"I64_FMT, rec->hdr_pos);
		d->fatalerrflag = 1;
		goto done;
	}

	de_dbg(c, "record #%u at %"I64_FMT, rec->idx, rec->hdr_pos);
	de_dbg_indent(c, 1);

	do_nufx_record_header(c, d, rec);
	if(d->fatalerrflag) goto done;

	extract_from_record(c, d, rec);

done:
	de_dbg_indent_restore(c, saved_indent_level);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq -0x8(%rbp), %rdi
leaq -0x1c(%rbp), %rsi
callq 0x15b580
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rdi
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rsi
callq 0x165470
movl %eax, -0x20(%rbp)
cmpl $0x4ef546d8, -0x20(%rbp) # imm = 0x4EF546D8
je 0xd6425
movq -0x8(%rbp), %rdi
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rdx
leaq 0xe4b40(%rip), %rsi     # 0x1baf55
movb $0x0, %al
callq 0x15bfb0
movq -0x10(%rbp), %rax
movb $0x1, (%rax)
jmp 0xd6481
movq -0x8(%rbp), %rdi
movq -0x18(%rbp), %rax
movl 0x8(%rax), %edx
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rcx
leaq 0xdc3cc(%rip), %rsi     # 0x1b280b
movb $0x0, %al
callq 0x15b0d0
movq -0x8(%rbp), %rdi
movl $0x1, %esi
callq 0x15b560
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
movq -0x18(%rbp), %rdx
callq 0xd6600
movq -0x10(%rbp), %rax
cmpb $0x0, (%rax)
je 0xd6470
jmp 0xd6481
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
movq -0x18(%rbp), %rdx
callq 0xd6bf0
movq -0x8(%rbp), %rdi
movl -0x1c(%rbp), %esi
callq 0x15b5a0
addq $0x20, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/jsummers[P]deark/modules/nufx.c
// Function: nufx_read_datetime_to_timestamp_p
static void nufx_read_datetime_to_timestamp_p(dbuf *f, i64 *ppos,
	struct de_timestamp *ts)
{
	i64 yr, mo, da, hr, mi, se;
	i64 pos;

	pos = *ppos;
	*ppos += 8;

	se = (i64)dbuf_getbyte_p(f, &pos);
	mi = (i64)dbuf_getbyte_p(f, &pos);
	hr = (i64)dbuf_getbyte_p(f, &pos);
	yr = 1900 + (i64)dbuf_getbyte_p(f, &pos);
	da = 1 + (i64)dbuf_getbyte_p(f, &pos);
	mo = 1 + (i64)dbuf_getbyte_p(f, &pos);

	if(yr==1900) {
		de_zeromem(ts, sizeof(struct de_timestamp));
		ts->is_valid = 0;
		return;
	}
	de_make_timestamp(ts, yr, mo, da, hr, mi, se);
	ts->precision = DE_TSPREC_1SEC;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x60, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x50(%rbp)
movq -0x10(%rbp), %rax
movq (%rax), %rcx
addq $0x8, %rcx
movq %rcx, (%rax)
movq -0x8(%rbp), %rdi
leaq -0x50(%rbp), %rsi
callq 0x165170
movzbl %al, %eax
movq %rax, -0x48(%rbp)
movq -0x8(%rbp), %rdi
leaq -0x50(%rbp), %rsi
callq 0x165170
movzbl %al, %eax
movq %rax, -0x40(%rbp)
movq -0x8(%rbp), %rdi
leaq -0x50(%rbp), %rsi
callq 0x165170
movzbl %al, %eax
movq %rax, -0x38(%rbp)
movq -0x8(%rbp), %rdi
leaq -0x50(%rbp), %rsi
callq 0x165170
movzbl %al, %eax
addq $0x76c, %rax            # imm = 0x76C
movq %rax, -0x20(%rbp)
movq -0x8(%rbp), %rdi
leaq -0x50(%rbp), %rsi
callq 0x165170
movzbl %al, %eax
addq $0x1, %rax
movq %rax, -0x30(%rbp)
movq -0x8(%rbp), %rdi
leaq -0x50(%rbp), %rsi
callq 0x165170
movzbl %al, %eax
addq $0x1, %rax
movq %rax, -0x28(%rbp)
cmpq $0x76c, -0x20(%rbp)     # imm = 0x76C
jne 0xd6576
movq -0x18(%rbp), %rdi
xorl %esi, %esi
movl $0x10, %edx
callq 0x19140
movq -0x18(%rbp), %rax
movb $0x0, (%rax)
jmp 0xd65a3
movq -0x18(%rbp), %rdi
movq -0x20(%rbp), %rsi
movq -0x28(%rbp), %rdx
movq -0x30(%rbp), %rcx
movq -0x38(%rbp), %r8
movq -0x40(%rbp), %r9
movq -0x48(%rbp), %rax
movq %rax, (%rsp)
callq 0x15d830
movq -0x18(%rbp), %rax
movb $0x1e, 0x2(%rax)
addq $0x60, %rsp
popq %rbp
retq
nopl (%rax)