LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/src/deark-data.c
// Function: de_riscos_to_unicode
static de_rune de_riscos_to_unicode(struct de_encconv_state *es, i32 a)
{
	de_rune n;
	if(a>=0x80 && a<=0x9f) n = (de_rune)riscostable[a-0x80];
	else if(a<=0xff) n = a;
	else n = DE_CODEPOINT_INVALID;
	if(n==0xffff) n = DE_CODEPOINT_INVALID;
	return n;
}

// Assembly:
movl %esi, %eax
andl $-0x20, %eax
cmpl $0x80, %eax
jne 0xec68f
addl $-0x80, %esi
leaq 0x5ab77(%rip), %rax     # 0x147200
movzwl (%rax,%rsi,2), %ecx
jmp 0xec69d
cmpl $0x100, %esi            # imm = 0x100
movl $0xfffffff, %ecx        # imm = 0xFFFFFFF
cmovll %esi, %ecx
cmpl $0xffff, %ecx           # imm = 0xFFFF
movl $0xfffffff, %eax        # imm = 0xFFFFFFF
cmovnel %ecx, %eax
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/src/deark-data.c
// Function: de_decspecialgraphics_to_unicode
static de_rune de_decspecialgraphics_to_unicode(struct de_encconv_state *es, i32 a)
{
	de_rune n;
	if(a>=95 && a<=126) n = (de_rune)decspecialgraphicstable[a-95];
	else n = DE_CODEPOINT_INVALID;
	if(n==0xffff) n = DE_CODEPOINT_INVALID;
	return n;
}

// Assembly:
addl $-0x5f, %esi
movl $0xfffffff, %eax        # imm = 0xFFFFFFF
movl $0xfffffff, %ecx        # imm = 0xFFFFFFF
cmpl $0x1f, %esi
ja 0xec6d1
movl %esi, %ecx
leaq 0x5ab73(%rip), %rdx     # 0x147240
movzwl (%rdx,%rcx,2), %ecx
cmpl $0xffff, %ecx           # imm = 0xFFFF
cmovnel %ecx, %eax
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/src/deark-data.c
// Function: de_char_to_unicode_ex
de_rune de_char_to_unicode_ex(i32 a, struct de_encconv_state *es)
{
	if(a<0) return DE_CODEPOINT_INVALID;
	if(es->fn) {
		return es->fn(es, a);
	}

	switch(es->enc) {
	case DE_ENCODING_ASCII:
		if(es->enc_subtype==DE_ENCSUBTYPE_PRINTABLE) {
			return (a>=32 && a<=126)?a:DE_CODEPOINT_INVALID;
		}
		return (a<128)?a:DE_CODEPOINT_INVALID;
	case DE_ENCODING_LATIN1:
		return (a<256)?a:DE_CODEPOINT_INVALID;
	default:
		break;
	}
	return a;
}

// Assembly:
testl %edi, %edi
js 0xec713
movl %edi, %eax
movq 0x8(%rsi), %rcx
testq %rcx, %rcx
je 0xec719
movq %rsi, %rdi
movl %eax, %esi
jmpq *%rcx
movl $0xfffffff, %eax        # imm = 0xFFFFFFF
retq
movl (%rsi), %ecx
cmpl $0x5, %ecx
je 0xec73b
cmpl $0x1, %ecx
jne 0xec718
cmpl $0x4, 0x4(%rsi)
jne 0xec742
leal -0x20(%rax), %ecx
cmpl $0x5f, %ecx
movl $0xfffffff, %ecx        # imm = 0xFFFFFFF
cmovbl %eax, %ecx
jmp 0xec74f
cmpl $0x100, %eax            # imm = 0x100
jmp 0xec747
cmpl $0x80, %eax
movl $0xfffffff, %ecx        # imm = 0xFFFFFFF
cmovll %eax, %ecx
movl %ecx, %eax
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/src/deark-data.c
// Function: de_uchar_to_utf8
void de_uchar_to_utf8(de_rune u1, u8 *utf8buf, i64 *p_utf8len)
{
	u32 u = (u32)u1;

	// TODO: Maybe there should be a flag to tell what to do with
	// our special codepoints (DE_CODEPOINT_BYTE00, ...).
	if(u1<0 || u1>0x10ffff)	{
		u=0xfffd;
	}

	if(u<=0x7f) {
		*p_utf8len = 1;
		utf8buf[0] = (u8)u;
	}
	else if(u>=0x80 && u<=0x7ff) {
		*p_utf8len = 2;
		utf8buf[0] = 0xc0 | (u8)(u>>6);
		utf8buf[1] = 0x80 | (u&0x3f);
	}
	else if(u>=0x800 && u<=0xffff) {
		*p_utf8len = 3;
		utf8buf[0] = 0xe0 | (u8)(u>>12);
		utf8buf[1] = 0x80 | ((u>>6)&0x3f);
		utf8buf[2] = 0x80 | (u&0x3f);
	}
	else {
		*p_utf8len = 4;
		utf8buf[0] = 0xf0 | (u8)(u>>18);
		utf8buf[1] = 0x80 | ((u>>12)&0x3f);
		utf8buf[2] = 0x80 | ((u>>6)&0x3f);
		utf8buf[3] = 0x80 | (u&0x3f);
	}
}

// Assembly:
cmpl $0x110000, %edi         # imm = 0x110000
movl $0xfffd, %eax           # imm = 0xFFFD
cmovbl %edi, %eax
cmpl $0x7f, %eax
ja 0xec799
movq $0x1, (%rdx)
movb %al, (%rsi)
retq
cmpl $0x7ff, %eax            # imm = 0x7FF
ja 0xec7b9
movq $0x2, (%rdx)
movl %eax, %ecx
shrl $0x6, %ecx
orb $-0x40, %cl
movb %cl, (%rsi)
andb $0x3f, %al
orb $-0x80, %al
movb %al, 0x1(%rsi)
retq
cmpl $0xffff, %eax           # imm = 0xFFFF
ja 0xec7e7
movq $0x3, (%rdx)
movl %eax, %ecx
shrl $0xc, %ecx
orb $-0x20, %cl
movb %cl, (%rsi)
movl %eax, %ecx
shrl $0x6, %ecx
andb $0x3f, %cl
orb $-0x80, %cl
movb %cl, 0x1(%rsi)
andb $0x3f, %al
orb $-0x80, %al
movb %al, 0x2(%rsi)
retq
movq $0x4, (%rdx)
movl %eax, %ecx
shrl $0x12, %ecx
orb $-0x10, %cl
movb %cl, (%rsi)
movl %eax, %ecx
shrl $0xc, %ecx
andb $0x3f, %cl
orb $-0x80, %cl
movb %cl, 0x1(%rsi)
movl %eax, %ecx
shrl $0x6, %ecx
andb $0x3f, %cl
orb $-0x80, %cl
movb %cl, 0x2(%rsi)
andb $0x3f, %al
orb $-0x80, %al
movb %al, 0x3(%rsi)
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/src/deark-data.c
// Function: de_utf8_to_uchar
int de_utf8_to_uchar(const u8 *utf8buf, i64 buflen,
	de_rune *p_uchar, i64 *p_utf8len)
{
	i32 u0=0;
	i32 u1=0;
	i32 u2=0;
	i32 u3=0;

	if(buflen<1) return 0;
	u0 = (i32)utf8buf[0];
	if(u0<=0x7f) { // 1-byte UTF-8 char
		*p_utf8len = 1;
		*p_uchar = u0;
		return 1;
	}
	if(buflen<2) return 0;
	if((utf8buf[1]&0xc0)!=0x80) return 0;
	u1 = (i32)utf8buf[1];
	if(u0<=0xdf) { // 2-byte UTF-8 char
		*p_utf8len = 2;
		*p_uchar = ((u0&0x1f)<<6) | (u1&0x3f);
		return 1;
	}
	if(buflen<3) return 0;
	if((utf8buf[2]&0xc0)!=0x80) return 0;
	u2 = (i32)utf8buf[2];
	if(u0<=0xef) { // 3-byte UTF-8 char
		*p_utf8len = 3;
		*p_uchar = ((u0&0x0f)<<12) | ((u1&0x3f)<<6) | (u2&0x3f);
		return 1;
	}
	if(buflen<4) return 0;
	if((utf8buf[3]&0xc0)!=0x80) return 0;
	u3 = (i32)utf8buf[3];
	if(u0<=0xf7) { // 4-byte UTF-8 char
		*p_utf8len = 4;
		*p_uchar = ((u0&0x07)<<18) | ((u1&0x3f)<<12) | ((u2&0x3f)<<6) | (u3&0x3f);
		return 1;
	}
	return 0;
}

// Assembly:
xorl %eax, %eax
testq %rsi, %rsi
jle 0xec96b
movzbl (%rdi), %r8d
testb %r8b, %r8b
js 0xec87f
movq $0x1, (%rcx)
movl %r8d, (%rdx)
movl $0x1, %eax
jmp 0xec96b
cmpq $0x1, %rsi
je 0xec96b
movzbl 0x1(%rdi), %r9d
movl %r9d, %r10d
andl $-0x40, %r10d
cmpl $0x80, %r10d
jne 0xec96b
cmpb $-0x21, %r8b
ja 0xec8c0
movq $0x2, (%rcx)
andl $0x1f, %r8d
shll $0x6, %r8d
andl $0x3f, %r9d
orl %r9d, %r8d
jmp 0xec872
cmpq $0x3, %rsi
jl 0xec96b
movzbl 0x2(%rdi), %r10d
movl %r10d, %r11d
andl $-0x40, %r11d
cmpl $0x80, %r11d
jne 0xec96b
cmpb $-0x11, %r8b
ja 0xec912
movq $0x3, (%rcx)
shll $0xc, %r8d
movzwl %r8w, %eax
andl $0x3f, %r9d
shll $0x6, %r9d
orl %eax, %r9d
andl $0x3f, %r10d
orl %r9d, %r10d
movl %r10d, %r8d
jmp 0xec872
cmpq $0x3, %rsi
je 0xec96b
movzbl 0x3(%rdi), %esi
movl %esi, %edi
andl $-0x40, %edi
cmpl $0x80, %edi
setne %dil
cmpb $-0x8, %r8b
setae %r11b
orb %dil, %r11b
jne 0xec96b
movq $0x4, (%rcx)
andl $0x7, %r8d
shll $0x12, %r8d
andl $0x3f, %r9d
shll $0xc, %r9d
orl %r8d, %r9d
andl $0x3f, %r10d
shll $0x6, %r10d
orl %r9d, %r10d
andl $0x3f, %esi
orl %r10d, %esi
movl %esi, %r8d
jmp 0xec872
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/src/deark-data.c
// Function: de_utf8_to_ascii
void de_utf8_to_ascii(const char *src, char *dst, size_t dstlen, unsigned int flags)
{
	size_t srcpos = 0;
	size_t dstpos = 0;
	unsigned char ch;
	i32 uchar;
	i64 code_len;
	int ret;

	while(1) {
		char sc; // substitution character 1
		char sc2 = 0; // substitution character 2

		if(dstpos >= dstlen-1) {
			dst[dstlen-1] = '\0';
			break;
		}

		ch = (unsigned char)src[srcpos];
		if(ch<0x80) {
			dst[dstpos++] = src[srcpos++];
			if(ch=='\0')
				break;
		}
		else { // Start of a multi-byte UTF8 char

			ret = de_utf8_to_uchar((const u8*)&src[srcpos], 4, &uchar, &code_len);
			if(ret) {
				srcpos += (size_t)code_len;
				switch(uchar) {
				case 0x00d7: sc='x'; break; // Multiplication sign
				case 0x2018: case 0x2019: sc='\''; break; // single quotes
				case 0x201c: case 0x201d: sc='"'; break; // double quotes
				case 0x2192: sc='-'; sc2='>'; break; // Rightwards arrow
				case 0x2264: sc='<'; sc2='='; break;
				case 0x2265: sc='>'; sc2='='; break;
				case 0x2502: sc='|'; break; // Box drawings light vertical
				default: sc = '_';
				}
			}
			else {
				srcpos += 1;
				sc = '?';
			}
			dst[dstpos++] = sc;
			if(sc2 && dstpos<dstlen-1) dst[dstpos++] = sc2;
		}
	}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rdx, %rbx
movq %rsi, %r14
movq %rdi, %r15
decq %rbx
xorl %ebp, %ebp
leaq 0x10(%rsp), %r13
xorl %r12d, %r12d
cmpq %rbx, %rbp
jae 0xec9ae
movb (%r15,%r12), %al
testb %al, %al
js 0xec9be
incq %r12
movb %al, (%r14,%rbp)
incq %rbp
testb %al, %al
setne %al
jmp 0xec9b5
movb $0x0, (%r14,%rbx)
xorl %eax, %eax
testb %al, %al
jne 0xec990
jmp 0xeca99
leaq (%r15,%r12), %rdi
movl $0x4, %esi
leaq 0xc(%rsp), %rdx
movq %r13, %rcx
callq 0xec857
testl %eax, %eax
je 0xeca03
movq 0x10(%rsp), %rax
movl 0xc(%rsp), %ecx
cmpl $0x2191, %ecx           # imm = 0x2191
jg 0xeca0c
leal -0x2018(%rcx), %edx
cmpl $0x2, %edx
jb 0xeca41
leal -0x201c(%rcx), %edx
cmpl $0x2, %edx
jae 0xeca45
movb $0x22, %dl
jmp 0xeca65
movb $0x3f, %dl
movl $0x1, %eax
jmp 0xeca65
cmpl $0x2264, %ecx           # imm = 0x2264
jg 0xeca2d
cmpl $0x2192, %ecx           # imm = 0x2192
je 0xeca51
cmpl $0x2264, %ecx           # imm = 0x2264
jne 0xeca63
movb $0x3d, %sil
movb $0x1, %cl
movb $0x3c, %dl
jmp 0xeca69
cmpl $0x2265, %ecx           # imm = 0x2265
je 0xeca5a
cmpl $0x2502, %ecx           # imm = 0x2502
jne 0xeca63
movb $0x7c, %dl
jmp 0xeca65
movb $0x27, %dl
jmp 0xeca65
cmpl $0xd7, %ecx
jne 0xeca63
movb $0x78, %dl
jmp 0xeca65
movb $0x3e, %sil
movb $0x1, %cl
movb $0x2d, %dl
jmp 0xeca69
movb $0x3d, %sil
movb $0x1, %cl
movb $0x3e, %dl
jmp 0xeca69
movb $0x5f, %dl
xorl %ecx, %ecx
xorl %esi, %esi
addq %rax, %r12
leaq 0x1(%rbp), %rdi
movb %dl, (%r14,%rbp)
cmpq %rbx, %rdi
setae %dl
xorb $0x1, %cl
movb $0x1, %al
orb %dl, %cl
jne 0xeca91
movb %sil, 0x1(%r14,%rbp)
addq $0x2, %rbp
jmp 0xec9b5
movq %rdi, %rbp
jmp 0xec9b5
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/src/deark-data.c
// Function: get_stdpal_colors
static const u8 *get_stdpal_colors(int pal_id, int pal_subid, i64 *pncolors)
{
	const u8 *p = NULL;

	*pncolors = 0;

	switch(pal_id) {
	case DE_PALID_CGA:
		*pncolors = 4;
		if(pal_subid>=0 && pal_subid<=5) {
			p = stdpals_cga[pal_subid];
		}
		else {
			p = stdpals_cga[2];
		}
		break;
	case DE_PALID_PC16:
		*pncolors = 16;
		p = stdpal_pc16_colors;
		break;
	case DE_PALID_WIN16:
		*pncolors = 16;
		switch(pal_subid) {
		case 1: p = stdpal_win16_colors_1; break;
		case 2: p = stdpal_win16_colors_2; break;
		default: p = stdpal_win16_colors_0; break;
		}
		break;
	case DE_PALID_EGA64:
		*pncolors = 64;
		p = stdpal_ega64_colors;
		break;
	case DE_PALID_VGA256:
		*pncolors = 256;
		p = stdpal_vga256_colors;
		break;
	}
	return p;
}

// Assembly:
movq $0x0, (%rdx)
xorl %eax, %eax
cmpl $0x1d, %edi
jle 0xecb5f
cmpl $0x1e, %edi
je 0xecb78
cmpl $0x28, %edi
je 0xecb87
cmpl $0x32, %edi
jne 0xecb95
movq $0x10, (%rdx)
cmpl $0x2, %esi
leaq 0x5a7eb(%rip), %rax     # 0x147330
leaq 0x5a814(%rip), %rcx     # 0x147360
cmoveq %rax, %rcx
cmpl $0x1, %esi
leaq 0x5a7a6(%rip), %rax     # 0x147300
cmovneq %rcx, %rax
retq
cmpl $0xa, %edi
je 0xecb96
cmpl $0x14, %edi
jne 0xecb95
movq $0x10, (%rdx)
leaq 0x5a759(%rip), %rax     # 0x1472d0
retq
movq $0x40, (%rdx)
leaq 0x5a80a(%rip), %rax     # 0x147390
retq
movq $0x100, (%rdx)          # imm = 0x100
leaq 0x5a8bb(%rip), %rax     # 0x147450
retq
movq $0x4, (%rdx)
cmpl $0x5, %esi
ja 0xecbb4
movl %esi, %eax
leaq (%rax,%rax,2), %rax
leaq 0x5a6d1(%rip), %rcx     # 0x147280
leaq (%rcx,%rax,4), %rax
retq
leaq 0x5a6dd(%rip), %rax     # 0x147298
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/src/deark-data.c
// Function: de_copy_std_palette
void de_copy_std_palette(int pal_id, int pal_subid, i64 starting_idx,
	de_color *dstpal, size_t dstpal_capacity, UI flags)
{
	const u8 *pal;
	i64 n_to_copy;
	i64 stdpal_ncolors;

	if(flags & DE_COPYPALFLAG_INITPAL) {
		de_zeromem(dstpal, dstpal_capacity*sizeof(de_color));
	}

	pal = get_stdpal_colors(pal_id, pal_subid, &stdpal_ncolors);
	if(!pal) goto done;
	if(starting_idx >= stdpal_ncolors) goto done;

	n_to_copy = de_min_int((i64)dstpal_capacity, stdpal_ncolors - starting_idx);
	if(n_to_copy<=0) goto done;
	de_copy_palette_from_rgb24(&pal[starting_idx*3], dstpal, (size_t)n_to_copy);
done:
	;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x10, %rsp
movq %r8, %r15
movq %rcx, %rbx
movq %rdx, %r14
movl %esi, %ebp
movl %edi, %r12d
testb $0x10, %r9b
je 0xecbee
leaq (,%r15,4), %rdx
movq %rbx, %rdi
xorl %esi, %esi
callq 0x18140
leaq 0x8(%rsp), %rdx
movl %r12d, %edi
movl %ebp, %esi
callq 0xecb17
testq %rax, %rax
je 0xecc53
movq 0x8(%rsp), %rsi
subq %r14, %rsi
jle 0xecc53
movq %rax, %r12
movq %r15, %rdi
callq 0xea792
testq %rax, %rax
jle 0xecc53
leaq (%r14,%r14,2), %rcx
addq %r12, %rcx
addq $0x2, %rcx
xorl %edx, %edx
movzbl -0x2(%rcx), %esi
shll $0x10, %esi
movzbl -0x1(%rcx), %edi
shll $0x8, %edi
orl %esi, %edi
movzbl (%rcx), %esi
orl %edi, %esi
orl $0xff000000, %esi       # imm = 0xFF000000
movl %esi, (%rbx,%rdx,4)
incq %rdx
addq $0x3, %rcx
cmpq %rdx, %rax
jne 0xecc29
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/src/deark-data.c
// Function: de_color_to_css
void de_color_to_css(de_color color, char *buf, int buflen)
{
	u8 r, g, b;

	buf[0] = '#';
	r = DE_COLOR_R(color);
	g = DE_COLOR_G(color);
	b = DE_COLOR_B(color);

	if(r%17==0 && g%17==0 && b%17==0) {
		// Can use short form.
		buf[1] = g_hexchars[r/17];
		buf[2] = g_hexchars[g/17];
		buf[3] = g_hexchars[b/17];
		buf[4] = '\0';
		return;
	}

	buf[1] = g_hexchars[r/16];
	buf[2] = g_hexchars[r%16];
	buf[3] = g_hexchars[g/16];
	buf[4] = g_hexchars[g%16];
	buf[5] = g_hexchars[b/16];
	buf[6] = g_hexchars[b%16];
	buf[7] = '\0';
}

// Assembly:
movb $0x23, (%rsi)
movl %edi, %ecx
shrl $0x10, %ecx
movl %edi, %eax
shrl $0x8, %eax
movzbl %cl, %edx
imull $0xf0f0f0f1, %edx, %r8d # imm = 0xF0F0F0F1
cmpl $0xf0f0f0f, %r8d        # imm = 0xF0F0F0F
ja 0xeccf2
movzbl %al, %r8d
imull $0xf0f0f0f1, %r8d, %r9d # imm = 0xF0F0F0F1
cmpl $0xf0f0f0f, %r9d        # imm = 0xF0F0F0F
ja 0xeccf2
movzbl %dil, %r9d
imull $0xf0f0f0f1, %r9d, %r10d # imm = 0xF0F0F0F1
cmpl $0xf0f0f0f, %r10d       # imm = 0xF0F0F0F
jbe 0xecd56
shrl $0x4, %edx
leaq 0x5bad3(%rip), %r8      # 0x1487cf
movb (%rdx,%r8), %dl
movb %dl, 0x1(%rsi)
andl $0xf, %ecx
movb (%rcx,%r8), %cl
movb %cl, 0x2(%rsi)
movl %edi, %ecx
shrl $0xc, %ecx
andl $0xf, %ecx
movb (%rcx,%r8), %cl
movb %cl, 0x3(%rsi)
andl $0xf, %eax
movb (%rax,%r8), %al
movb %al, 0x4(%rsi)
movl %edi, %eax
shrl $0x4, %eax
andl $0xf, %eax
movb (%rax,%r8), %al
movb %al, 0x5(%rsi)
andl $0xf, %edi
movl $0x7, %eax
movl $0x6, %ecx
movl %edi, %edx
leaq 0x5ba84(%rip), %rdi     # 0x1487cf
movb (%rdx,%rdi), %dl
movb %dl, (%rsi,%rcx)
movb $0x0, (%rsi,%rax)
retq
imulq $0xf0f0f10, %rdx, %rax  # imm = 0xF0F0F10
shrq $0x20, %rax
imulq $0xf0f0f10, %r8, %rcx   # imm = 0xF0F0F10
shrq $0x20, %rcx
imulq $0xf0f0f10, %r9, %rdi   # imm = 0xF0F0F10
shrq $0x20, %rdi
movl %eax, %eax
leaq 0x5ba4f(%rip), %rdx     # 0x1487cf
movb (%rax,%rdx), %al
movb %al, 0x1(%rsi)
movl %ecx, %eax
movb (%rax,%rdx), %al
movb %al, 0x2(%rsi)
movl $0x4, %eax
movl $0x3, %ecx
jmp 0xecd42
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/src/deark-data.c
// Function: de_sample_nbit_to_8bit
u8 de_sample_nbit_to_8bit(i64 n, unsigned int x)
{
	unsigned int maxval;

	if(x==0) return 0;
	if(n<1 || n>16) return 0;
	maxval = (1<<n)-1;
	if(x>=maxval) return 255;
	return (u8)(0.5+((((double)x)/(double)maxval)*255.0));
}

// Assembly:
testl %esi, %esi
sete %al
leaq -0x11(%rdi), %rcx
cmpq $-0x10, %rcx
setb %cl
orb %al, %cl
je 0xecdb1
xorl %eax, %eax
retq
movl $0xffffffff, %edx       # imm = 0xFFFFFFFF
movl %edi, %ecx
shll %cl, %edx
notl %edx
movb $-0x1, %al
cmpl %esi, %edx
jbe 0xecdb0
cvtsi2sd %esi, %xmm0
cvtsi2sd %edx, %xmm1
divsd %xmm1, %xmm0
mulsd 0x2a902(%rip), %xmm0    # 0x1176d8
addsd 0x2a8f2(%rip), %xmm0    # 0x1176d0
cvttsd2si %xmm0, %eax
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/src/deark-data.c
// Function: de_scale_n_to_16bit
void de_scale_n_to_16bit(int n, int x_in, u8 *x_out_hi, u8 *x_out_lo)
{
	double tmp1;
	UI tmp2;

	if(x_in<0) x_in = 0;
	if(x_in>n) x_in = n;
	tmp1 = ((double)x_in / (double)n) * 65535.0;
	tmp2 = (UI)(tmp1 + 0.5);
	*x_out_hi = (tmp2 & 0xff00)>>8;
	*x_out_lo = (tmp2 & 0xff);
}

// Assembly:
xorl %eax, %eax
testl %esi, %esi
cmovgl %esi, %eax
cmpl %edi, %eax
cmovgel %edi, %eax
cvtsi2sd %eax, %xmm0
cvtsi2sd %edi, %xmm1
divsd %xmm1, %xmm0
mulsd 0x5b8d5(%rip), %xmm0    # 0x148760
addsd 0x2a83d(%rip), %xmm0    # 0x1176d0
cvttsd2si %xmm0, %rax
movb %ah, (%rdx)
movb %al, (%rcx)
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/src/deark-data.c
// Function: de_rgb565_to_888
de_color de_rgb565_to_888(u32 x)
{
	u8 cr, cg, cb;
	cr = (u8)(x>>11);
	cg = (u8)((x>>5)&0x3f);
	cb = (u8)(x&0x1f);
	cr = (u8)(0.5+((double)cr)*(255.0/31.0));
	cg = (u8)(0.5+((double)cg)*(255.0/63.0));
	cb = (u8)(0.5+((double)cb)*(255.0/31.0));
	return DE_MAKE_RGB(cr, cg, cb);
}

// Assembly:
movl %edi, %eax
shrl $0xb, %eax
movl %edi, %edx
movl $0xff, %ecx
andl %ecx, %eax
cvtsi2sd %eax, %xmm0
shrl $0x5, %edx
movsd 0x5b8ae(%rip), %xmm1    # 0x148768
mulsd %xmm1, %xmm0
movsd 0x2a80a(%rip), %xmm2    # 0x1176d0
addsd %xmm2, %xmm0
cvttsd2si %xmm0, %esi
andl $0x3f, %edx
xorps %xmm0, %xmm0
cvtsi2sd %edx, %xmm0
mulsd 0x5b870(%rip), %xmm0    # 0x148750
addsd %xmm2, %xmm0
cvttsd2si %xmm0, %edx
andl $0x1f, %edi
xorps %xmm0, %xmm0
cvtsi2sd %edi, %xmm0
mulsd %xmm1, %xmm0
addsd %xmm2, %xmm0
cvttsd2si %xmm0, %eax
shll $0x10, %esi
andl %ecx, %edx
shll $0x8, %edx
orl %esi, %edx
andl %ecx, %eax
orl %edx, %eax
orl $0xff000000, %eax       # imm = 0xFF000000
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/src/deark-data.c
// Function: de_bgr555_to_888
de_color de_bgr555_to_888(u32 x)
{
	u8 cr, cg, cb;
	cb = (u8)((x>>10)&0x1f);
	cg = (u8)((x>>5)&0x1f);
	cr = (u8)(x&0x1f);
	cb = (u8)(0.5+((double)cb)*(255.0/31.0));
	cg = (u8)(0.5+((double)cg)*(255.0/31.0));
	cr = (u8)(0.5+((double)cr)*(255.0/31.0));
	return DE_MAKE_RGB(cr, cg, cb);
}

// Assembly:
movl %edi, %eax
shrl $0xa, %eax
movl %edi, %ecx
andl $0x1f, %eax
cvtsi2sd %eax, %xmm0
movsd 0x5b840(%rip), %xmm1    # 0x148768
mulsd %xmm1, %xmm0
movsd 0x2a79c(%rip), %xmm2    # 0x1176d0
addsd %xmm2, %xmm0
cvttsd2si %xmm0, %eax
shrl $0x5, %ecx
andl $0x1f, %ecx
xorps %xmm0, %xmm0
cvtsi2sd %ecx, %xmm0
mulsd %xmm1, %xmm0
addsd %xmm2, %xmm0
cvttsd2si %xmm0, %ecx
andl $0x1f, %edi
xorps %xmm0, %xmm0
cvtsi2sd %edi, %xmm0
mulsd %xmm1, %xmm0
addsd %xmm2, %xmm0
cvttsd2si %xmm0, %edx
shll $0x10, %edx
movl $0xff, %esi
andl %esi, %ecx
shll $0x8, %ecx
orl %edx, %ecx
andl %esi, %eax
orl %ecx, %eax
orl $0xff000000, %eax       # imm = 0xFF000000
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/src/deark-data.c
// Function: de_bytes_to_printable_sz
void de_bytes_to_printable_sz(const u8 *s1, i64 s1_len,
	char *s2, i64 s2_size, unsigned int conv_flags, de_ext_encoding src_ee)
{
	i64 i;
	i64 s2_pos = 0;
	de_ext_encoding src_encoding = DE_EXTENC_GET_BASE(src_ee);

	if(src_encoding!=DE_ENCODING_ASCII) {
		s2[0] = '\0';
		return;
	}

	for(i=0; i<s1_len; i++) {
		int is_printable = 0;

		if(s1[i]=='\0' && (conv_flags & DE_CONVFLAG_STOP_AT_NUL)) {
			break;
		}

		if(s1[i]>=32 && s1[i]<=126) {
			is_printable = 1;
		}

		if(is_printable) {
			if(s2_pos < s2_size-1) {
				s2[s2_pos++] = (char)s1[i];
			}
		}
		else if(conv_flags & DE_CONVFLAG_ALLOW_HL) {
			if(s2_pos < s2_size-6) {
				s2[s2_pos++] = 0x01; // DE_CODEPOINT_HL
				s2[s2_pos++] = '<';
				s2[s2_pos++] = de_get_hexcharUC((int)(s1[i]/16));
				s2[s2_pos++] = de_get_hexcharUC((int)(s1[i]%16));
				s2[s2_pos++] = '>';
				s2[s2_pos++] = 0x02; // DE_CODEPOINT_UNHL
			}
		}
		else {
			if(s2_pos < s2_size-1) {
				s2[s2_pos++] = '_';
			}
		}
	}

	s2[s2_pos] = '\0';
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
cmpb $0x1, %r9b
jne 0xed0c6
testq %rsi, %rsi
jle 0xed0c0
leaq -0x6(%rcx), %rax
decq %rcx
decq %rsi
xorl %r11d, %r11d
leaq 0x5b7b1(%rip), %r10     # 0x1487e0
xorl %r9d, %r9d
movb (%rdi,%r11), %r14b
testb %r14b, %r14b
sete %bl
andb %r8b, %bl
jne 0xed0a7
leal -0x20(%r14), %ebp
cmpb $0x5e, %bpl
ja 0xed056
cmpq %rcx, %r9
jge 0xed0a7
movb %r14b, (%rdx,%r9)
jmp 0xed066
testb $0x20, %r8b
jne 0xed06b
cmpq %rcx, %r9
jge 0xed0a7
movb $0x5f, (%rdx,%r9)
incq %r9
jmp 0xed0a7
cmpq %rax, %r9
jge 0xed0a7
movw $0x3c01, (%rdx,%r9)     # imm = 0x3C01
movzbl (%rdi,%r11), %r14d
shrl $0x4, %r14d
movb (%r14,%r10), %bpl
movb %bpl, 0x2(%rdx,%r9)
movzbl (%rdi,%r11), %r14d
andl $0xf, %r14d
movb (%r14,%r10), %bpl
movb %bpl, 0x3(%rdx,%r9)
movw $0x23e, 0x4(%rdx,%r9)   # imm = 0x23E
addq $0x6, %r9
cmpq %r11, %rsi
leaq 0x1(%r11), %r11
sete %bpl
orb %bpl, %bl
cmpb $0x1, %bl
jne 0xed032
jmp 0xed0c3
xorl %r9d, %r9d
addq %r9, %rdx
movb $0x0, (%rdx)
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/src/deark-data.c
// Function: de_write_codepoint_to_html
void de_write_codepoint_to_html(deark *c, dbuf *f, de_rune ch)
{
	int e; // How to encode this codepoint

	if(ch<0 || ch>0x10ffff || ch==DE_CODEPOINT_INVALID) ch=0xfffd;

	if(ch=='&' || ch=='<' || ch=='>') {
		e = 1; // HTML entity
	}
	else if(ch>=32 && ch<=126) {
		e = 2; // raw byte
	}
	else if(c->ascii_html) {
		e = 1; // HTML entity
	}
	else {
		e = 3; // UTF-8
	}

	if(e==2) {
		dbuf_writebyte(f, (u8)ch);
	}
	else if(e==3) {
		dbuf_write_uchar_as_utf8(f, ch);
	}
	else {
		dbuf_printf(f, "&#%d;", (int)ch);
	}
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rsi, %rbx
cmpl $0x110000, %edx         # imm = 0x110000
movl $0xfffd, %eax           # imm = 0xFFFD
cmovbl %edx, %eax
cmpl $0x26, %eax
sete %cl
movl %eax, %edx
andl $0x1ffffd, %edx         # imm = 0x1FFFFD
cmpl $0x3c, %edx
sete %dl
orb %cl, %dl
je 0xed104
xorl %edx, %edx
jmp 0xed10e
leal -0x20(%rax), %ecx
cmpl $0x5f, %ecx
jae 0xed112
movb $0x1, %dl
xorl %ecx, %ecx
jmp 0xed11e
cmpb $0x0, 0xce(%rdi)
sete %cl
xorl %edx, %edx
testb %dl, %dl
je 0xed136
movzbl %al, %esi
movq %rbx, %rdi
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
jmp 0xf11be
testb %cl, %cl
je 0xed169
leaq 0x4(%rsp), %r14
leaq 0x8(%rsp), %r15
movl %eax, %edi
movq %r14, %rsi
movq %r15, %rdx
callq 0xec77c
movq (%r15), %rdx
movq %rbx, %rdi
movq %r14, %rsi
callq 0xefb82
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
leaq 0x5b608(%rip), %rsi     # 0x148778
movq %rbx, %rdi
movl %eax, %edx
xorl %eax, %eax
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
jmp 0xf0ec4
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/src/deark-data.c
// Function: de_encoding_name_to_code
de_encoding de_encoding_name_to_code(const char *encname)
{
	size_t k;

	for(k=0; k<DE_ARRAYCOUNT(de_encmap_arr); k++) {
		if(!de_strcasecmp(encname, de_encmap_arr[k].encname)) {
			return de_encmap_arr[k].n;
		}
	}
	return DE_ENCODING_UNKNOWN;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %rbx
movl $0x8, %r14d
leaq 0xa1666(%rip), %r15     # 0x18e800
movq (%r14,%r15), %rsi
movq %rbx, %rdi
callq 0xe8e26
testl %eax, %eax
je 0xed1bb
addq $0x10, %r14
cmpq $0x188, %r14            # imm = 0x188
jne 0xed19a
xorl %eax, %eax
jmp 0xed1c0
movl -0x4(%r14,%r15), %eax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/src/deark-data.c
// Function: de_windows_codepage_to_encoding
de_encoding de_windows_codepage_to_encoding(deark *c, int wincodepage,
	char *encname, size_t encname_len, unsigned int flags)
{
	size_t k;
	const struct de_encmapwin_item *cpinfo = NULL;

	for(k=0; k<DE_ARRAYCOUNT(de_encmapwin_arr); k++) {
		if(de_encmapwin_arr[k].wincodepage == wincodepage) {
			cpinfo = &de_encmapwin_arr[k];
			break;
		}
	}

	if(cpinfo) {
		// Code page is known, though not necessarily supported.
		if(encname) {
			char note_tmp[80];
			if(cpinfo->encname_note) {
				de_snprintf(note_tmp, sizeof(note_tmp), " (%s)", cpinfo->encname_note);
			}
			else {
				note_tmp[0] = '\0';
			}
			de_snprintf(encname, encname_len, "%s%s%s", cpinfo->encname, note_tmp,
				((cpinfo->flags&0x1)==0 && (flags&0x1)!=0)?" (unsupported)":"");
		}
		return (cpinfo->flags&0x1) ? cpinfo->enc : DE_ENCODING_UNKNOWN;
	}

	if(encname) {
		de_strlcpy(encname, "?", encname_len);
	}
	return DE_ENCODING_UNKNOWN;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x58, %rsp
movl %r8d, %ebp
movq %rcx, %rbx
movq %rdx, %r14
xorl %r15d, %r15d
leaq 0xa179d(%rip), %rax     # 0x18e980
xorl %ecx, %ecx
cmpl %esi, 0x4(%rcx,%rax)
je 0xed1fa
addq $0x20, %rcx
cmpq $0x1e0, %rcx            # imm = 0x1E0
jne 0xed1e5
jmp 0xed200
addq %rcx, %rax
movq %rax, %r15
testq %r15, %r15
je 0xed22b
testq %r14, %r14
je 0xed283
movq 0x18(%r15), %rcx
testq %rcx, %rcx
je 0xed246
leaq 0x3e90c(%rip), %rdx     # 0x12bb26
movq %rsp, %rdi
movl $0x50, %esi
xorl %eax, %eax
callq 0xe8d67
jmp 0xed24a
xorl %ebp, %ebp
testq %r14, %r14
je 0xed28f
leaq 0x3ec30(%rip), %rsi     # 0x12be69
movq %r14, %rdi
movq %rbx, %rdx
callq 0xe8ded
jmp 0xed28f
movb $0x0, (%rsp)
testb $0x1, (%r15)
leaq 0x5b529(%rip), %r9      # 0x14877e
leaq 0x57974(%rip), %rax     # 0x144bd0
cmovneq %rax, %r9
movq 0x10(%r15), %rcx
testb $0x1, %bpl
cmoveq %rax, %r9
leaq 0x33d93(%rip), %rdx     # 0x121006
movq %rsp, %r8
movq %r14, %rdi
movq %rbx, %rsi
xorl %eax, %eax
callq 0xe8d67
xorl %ebp, %ebp
testb $0x1, (%r15)
je 0xed28f
movl 0x8(%r15), %ebp
movl %ebp, %eax
addq $0x58, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/src/deark-data.c
// Function: de_decode_base16
void de_decode_base16(deark *c, dbuf *inf, i64 pos1, i64 len,
	dbuf *outf, unsigned int flags)
{
	i64 pos = pos1;
	u8 b;
	int bad_warned = 0;
	struct base16_ctx {
		int cbuf_count;
		u8 cbuf[5];
	};
	struct base16_ctx *d = NULL;

	d = de_malloc(c, sizeof(struct base16_ctx));
	pos = pos1;
	d->cbuf_count = 0;
	while(pos<pos1+len) {
		b = dbuf_getbyte_p(inf, &pos);
		if(b>='0' && b<='9') {
			d->cbuf[d->cbuf_count++] = b-48;
		}
		else if(b>='A' && b<='F') {
			d->cbuf[d->cbuf_count++] = b-55;
		}
		else if(b>='a' && b<='f') {
			d->cbuf[d->cbuf_count++] = b-87;
		}
		else if(b==9 || b==10 || b==13 || b==32) {
			; // ignore whitespace
		}
		else {
			if(!bad_warned) {
				de_warn(c, "Bad hex character(s) found (offset %d)", (int)pos);
				bad_warned = 1;
			}
		}

		if(d->cbuf_count>=2) {
			dbuf_writebyte(outf, (d->cbuf[0]<<4)|(d->cbuf[1]));
			d->cbuf_count=0;
		}
	}

	if(d->cbuf_count>0) {
		de_warn(c, "Unexpected end of hex data");
	}

	de_free(c, d);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %r8, %r15
movq %rcx, %r12
movq %rdx, %rbp
movq %rsi, %r13
movq %rdx, 0x8(%rsp)
movl $0xc, %esi
movq %rdi, 0x10(%rsp)
callq 0xe969b
movq %rax, %r14
movq %rbp, 0x8(%rsp)
movl $0x0, (%rax)
testq %r12, %r12
jle 0xed397
addq %rbp, %r12
leaq 0x8(%rsp), %rbp
xorl %ebx, %ebx
movq %r13, %rdi
movq %rbp, %rsi
callq 0xef14d
leal -0x30(%rax), %ecx
cmpb $0x9, %cl
ja 0xed30e
movslq (%r14), %rax
leal 0x1(%rax), %edx
movl %edx, (%r14)
movb %cl, 0x4(%r14,%rax)
jmp 0xed332
leal -0x41(%rax), %ecx
cmpb $0x5, %cl
ja 0xed31a
addb $-0x37, %al
jmp 0xed324
leal -0x61(%rax), %ecx
cmpb $0x5, %cl
ja 0xed35e
addb $-0x57, %al
movslq (%r14), %rcx
leal 0x1(%rcx), %edx
movl %edx, (%r14)
movb %al, 0x4(%r14,%rcx)
cmpl $0x2, (%r14)
jl 0xed355
movb 0x4(%r14), %al
shlb $0x4, %al
orb 0x5(%r14), %al
movzbl %al, %esi
movq %r15, %rdi
callq 0xf11be
movl $0x0, (%r14)
cmpq %r12, 0x8(%rsp)
jl 0xed2eb
jmp 0xed397
testl %ebx, %ebx
jne 0xed332
cmpb $0x20, %al
ja 0xed379
movzbl %al, %eax
movabsq $0x100002600, %rcx      # imm = 0x100002600
btq %rax, %rcx
jb 0xed332
movl 0x8(%rsp), %edx
movq 0x10(%rsp), %rdi
leaq 0x5b404(%rip), %rsi     # 0x14878d
xorl %eax, %eax
callq 0xe9b27
movl $0x1, %ebx
jmp 0xed332
cmpl $0x0, (%r14)
movq 0x10(%rsp), %rbx
jle 0xed3b3
leaq 0x5b40b(%rip), %rsi     # 0x1487b4
movq %rbx, %rdi
xorl %eax, %eax
callq 0xe9b27
movq %rbx, %rdi
movq %r14, %rsi
callq 0xe9752
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/src/deark-data.c
// Function: de_cp437like_to_unicode
static de_rune de_cp437like_to_unicode(struct de_encconv_state *es, i32 a,
	const u16 tbl2[128])
{
	de_rune n;

	if(a>0xff) n = DE_CODEPOINT_INVALID;
	else if(a>=0x20 && a<=0x7e) n = a;
	else if(a>=0x80 && a<=0xff) n = (de_rune)tbl2[a-0x80];
	else {
		if(es->enc_subtype==DE_ENCSUBTYPE_CONTROLS ||
			(es->enc_subtype==DE_ENCSUBTYPE_HYBRID && is_hybrid_codepoint(a)))
		{
			n = a;
		}
		else {
			return de_cp437g_to_unicode(es, a);
		}
	}
	return n;
}

// Assembly:
movl $0xfffffff, %eax        # imm = 0xFFFFFFF
cmpl $0xff, %esi
jg 0xed3e4
leal -0x20(%rsi), %eax
cmpl $0x5f, %eax
jae 0xed3e5
movl %esi, %eax
retq
cmpl $0x80, %esi
jl 0xed3fb
movl %esi, %eax
leaq (%rdx,%rax,2), %rax
addq $-0x100, %rax
jmp 0xed425
movl 0x4(%rdi), %eax
cmpl $0x2, %eax
je 0xed3e2
cmpl $0x3, %eax
jne 0xed417
cmpl $0xd, %esi
ja 0xed417
movl $0x2601, %eax           # imm = 0x2601
btl %esi, %eax
jb 0xed3e2
movslq %esi, %rax
leaq 0x5907f(%rip), %rcx     # 0x1464a0
leaq (%rcx,%rax,2), %rax
movzwl (%rax), %eax
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/src/deark-zip.c
// Function: de_zip_create_file
int de_zip_create_file(deark *c)
{
	struct zipw_ctx *zzz;
	const char *opt_level;

	if(c->zip_data) return 1; // Already created. Shouldn't happen.

	zzz = de_malloc(c, sizeof(struct zipw_ctx));
	zzz->c = c;
	c->zip_data = (void*)zzz;
	zzz->crc32o = de_crcobj_create(c, DE_CRCOBJ_CRC32_IEEE);

	zzz->cmprlevel = MZ_BEST_COMPRESSION; // default
	opt_level = de_get_ext_option(c, "archive:zipcmprlevel");
	if(opt_level) {
		i64 opt_level_n = de_atoi64(opt_level);
		if(opt_level_n>9) {
			zzz->cmprlevel = 9;
		}
		else if(opt_level_n<0) {
			zzz->cmprlevel = MZ_DEFAULT_LEVEL;
		}
		else {
			zzz->cmprlevel = (unsigned int)opt_level_n;
		}
	}

	if(c->archive_to_stdout) {
		zzz->pFilename = "[stdout]";
	}
	else {
		if(c->output_archive_filename) {
			zzz->pFilename = c->output_archive_filename;
		}
		else {
			zzz->pFilename = "output.zip";
		}
	}

	if(c->archive_to_stdout) {
		zzz->outf = dbuf_create_unmanaged_file_stdout(c, "[ZIP stdout stream]");
	}
	else {
		de_info(c, "Creating %s", zzz->pFilename);
		zzz->outf = dbuf_create_unmanaged_file(c, zzz->pFilename, c->overwrite_mode, 0);
	}

	zzz->cdir = dbuf_create_membuf(c, 1024, 0);

	if(zzz->outf->btype==DBUF_TYPE_NULL) {
		de_err(c, "Failed to create ZIP file");
		dbuf_close(zzz->outf);
		zzz->outf = NULL;
		return 0;
	}

	return 1;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movl $0x1, %ebx
cmpq $0x0, 0x138(%rdi)
jne 0xed55c
movq %rdi, %r14
movl $0x38, %esi
callq 0xe969b
movq %rax, %r15
movq %r14, (%rax)
movq %rax, 0x138(%r14)
movq %r14, %rdi
movl $0x10, %esi
callq 0xeba56
movq %rax, 0x30(%r15)
movl $0x9, 0x10(%r15)
leaq 0x5b535(%rip), %rsi     # 0x1489b3
movq %r14, %rdi
callq 0xea6cb
testq %rax, %rax
je 0xed4ae
movq %rax, %rdi
callq 0xea786
testq %rax, %rax
movl $0x6, %ecx
cmovnsl %eax, %ecx
cmpq $0xa, %rax
movl $0x9, %eax
cmovll %ecx, %eax
movl %eax, 0x10(%r15)
movb 0x88(%r14), %al
testb %al, %al
je 0xed4c2
leaq 0x5b8e4(%rip), %rcx     # 0x148da4
jmp 0xed4d5
movq 0x160(%r14), %rcx
testq %rcx, %rcx
jne 0xed4d5
leaq 0x5b4f3(%rip), %rcx     # 0x1489c8
movq %rcx, 0x8(%r15)
testb %al, %al
je 0xed4ee
leaq 0x5b4ef(%rip), %rsi     # 0x1489d3
movq %r14, %rdi
callq 0xf0de0
jmp 0xed518
movq 0x8(%r15), %rdx
leaq 0x5b4ee(%rip), %rsi     # 0x1489e7
movq %r14, %rdi
xorl %eax, %eax
callq 0xe9ef5
movq 0x8(%r15), %rsi
movl 0xd8(%r14), %edx
movq %r14, %rdi
xorl %ecx, %ecx
callq 0xf0d34
movq %rax, 0x20(%r15)
movl $0x400, %esi            # imm = 0x400
movq %r14, %rdi
xorl %edx, %edx
callq 0xf0faf
movq %rax, 0x28(%r15)
movq 0x20(%r15), %rax
cmpl $0x0, (%rax)
jne 0xed55c
leaq 0x5b4b4(%rip), %rsi     # 0x1489f3
movq %r14, %rdi
xorl %eax, %eax
callq 0xe9df7
movq 0x20(%r15), %rdi
callq 0xf0b13
movq $0x0, 0x20(%r15)
xorl %ebx, %ebx
movl %ebx, %eax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/src/deark-zip.c
// Function: do_UT_times
static void do_UT_times(deark *c, struct zipw_md *md,
	dbuf *ef, int is_central)
{
	int have_crtime = 0;
	int have_actime = 0;
	i64 num_timestamps = 0; // Number to write
	i64 actime_unix = 0;
	i64 crtime_unix = 0;
	u8 flags = 0;

	if(md->actime.is_valid) {
		actime_unix = de_timestamp_to_unix_time(&md->actime);
		if(is_valid_32bit_unix_time(actime_unix)) {
			have_actime = 1;
		}
	}

	if(md->crtime.is_valid) {
		crtime_unix = de_timestamp_to_unix_time(&md->crtime);
		if(is_valid_32bit_unix_time(crtime_unix)) {
			have_crtime = 1;
		}
	}

	// Always write mod time
	num_timestamps++;
	flags |= 0x01;

	if(have_actime) {
		if(!is_central) num_timestamps++;
		flags |= 0x02;
	}

	if(have_crtime) {
		if(!is_central) num_timestamps++;
		flags |= 0x04;
	}

	dbuf_writeu16le(ef, 0x5455);
	dbuf_writeu16le(ef, (i64)(1+4*num_timestamps));
	dbuf_writebyte(ef, flags); // tells which fields are present in local header
	dbuf_writei32le(ef, md->modtime_unix);
	if(have_actime && !is_central) {
		dbuf_writei32le(ef, actime_unix);
	}
	if(have_crtime && !is_central) {
		dbuf_writei32le(ef, crtime_unix);
	}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movl %edx, %r12d
movq %rsi, 0x10(%rsp)
movq %rdi, %rbx
movabsq $-0x100000000, %r14     # imm = 0xFFFFFFFF00000000
cmpb $0x0, 0x10(%rdi)
je 0xed8de
leaq 0x10(%rbx), %rdi
callq 0xeb296
movq %rax, 0x28(%rsp)
addq $-0x80000000, %rax      # imm = 0x80000000
cmpq %r14, %rax
setb %bpl
jmp 0xed8ea
movq $0x0, 0x28(%rsp)
movb $0x1, %bpl
cmpb $0x0, 0x20(%rbx)
movq %rbx, 0x30(%rsp)
je 0xed911
leaq 0x20(%rbx), %rdi
callq 0xeb296
movq %rax, 0x20(%rsp)
addq $-0x80000000, %rax      # imm = 0x80000000
cmpq %r14, %rax
setb %bl
jmp 0xed91c
movq $0x0, 0x20(%rsp)
movb $0x1, %bl
xorl %r13d, %r13d
testl %r12d, %r12d
sete %r13b
setne 0xe(%rsp)
incl %r13d
testb %bpl, %bpl
movl $0x1, %eax
cmovnel %eax, %r13d
movl %ebp, %ecx
movb %bpl, 0xd(%rsp)
leal 0x1(%r13), %ebp
movl %r12d, 0x1c(%rsp)
testl %r12d, %r12d
cmovnel %eax, %ebp
movl %ecx, %eax
xorb $0x1, %al
addb %al, %al
leal 0x1(%rax), %ecx
orb $0x5, %al
movzbl %al, %r12d
movzbl %cl, %r14d
movl $0x5455, %esi           # imm = 0x5455
movq 0x10(%rsp), %r15
movq %r15, %rdi
callq 0xf1598
movb %bl, 0xf(%rsp)
testb %bl, %bl
cmovel %r12d, %r14d
cmovnel %r13d, %ebp
leaq 0x1(,%rbp,4), %rsi
movzbl %r14b, %r13d
movq %r15, %rdi
callq 0xf1598
movq %r15, %rdi
movl %r13d, %esi
callq 0xf11be
movq 0x30(%rsp), %rax
movq 0x30(%rax), %rsi
movq %r15, %rdi
callq 0xf165c
movb 0xd(%rsp), %al
orb %al, 0xe(%rsp)
jne 0xed9cc
movq 0x10(%rsp), %rdi
movq 0x28(%rsp), %rsi
callq 0xf165c
cmpl $0x0, 0x1c(%rsp)
setne %al
orb 0xf(%rsp), %al
je 0xed9e9
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq 0x10(%rsp), %rdi
movq 0x20(%rsp), %rsi
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0xf165c
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/src/deark-zip.c
// Function: do_ntfs_times
static void do_ntfs_times(deark *c, struct zipw_md *md,
	dbuf *ef, int is_central)
{
	u64 modtm, actm, crtm;

	dbuf_writeu16le(ef, 0x000a); // = NTFS
	dbuf_writeu16le(ef, 32); // data size
	dbuf_write_zeroes(ef, 4);
	dbuf_writeu16le(ef, 0x0001); // file times element
	dbuf_writeu16le(ef, 24); // element data size
	// We only necessarily know the mod time, but we have to write something for
	// the others.
	modtm = (u64)md->modtime_as_FILETIME;
	actm = (md->actime_as_FILETIME>0) ? (u64)md->actime_as_FILETIME : modtm;
	crtm = (md->crtime_as_FILETIME>0) ? (u64)md->crtime_as_FILETIME : modtm;
	dbuf_writeu64le(ef, modtm);
	dbuf_writeu64le(ef, actm);
	dbuf_writeu64le(ef, crtm);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %rbx
movq %rdi, %r14
movl $0xa, %esi
movq %rbx, %rdi
callq 0xf1598
movl $0x20, %esi
movq %rbx, %rdi
callq 0xf1598
movl $0x4, %esi
movq %rbx, %rdi
callq 0xf1346
movl $0x1, %esi
movq %rbx, %rdi
callq 0xf1598
movl $0x18, %esi
movq %rbx, %rdi
callq 0xf1598
movq 0x40(%r14), %rsi
movq 0x48(%r14), %r15
testq %r15, %r15
cmovleq %rsi, %r15
movq 0x50(%r14), %r14
testq %r14, %r14
cmovleq %rsi, %r14
movq %rbx, %rdi
callq 0xf16da
movq %rbx, %rdi
movq %r15, %rsi
callq 0xf16da
movq %rbx, %rdi
movq %r14, %rsi
popq %rbx
popq %r14
popq %r15
jmp 0xf16da
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/src/deark-zip.c
// Function: do_riscos_attribs
static void do_riscos_attribs(deark *c, struct zipw_md *md, de_finfo *fi, dbuf *ef)
{
	 if(!fi) return;
	 if(fi->riscos_appended_type) return; // Already handled attribs in a different way
	 if(!fi->has_riscos_data) return;
	 if(md->is_directory) return;
	 if(md->is_volume_label) return;
	 dbuf_writeu16le(ef, 0x4341); // AC
	 dbuf_writeu16le(ef, 20); // data size
	 dbuf_write(ef, (const u8*)"ARC0", 4);

	 // The only thing we really want to write is the file type (part of
	 // the load_addr), but unfortunately there's no way to do just that.
	 dbuf_writeu32le(ef, fi->load_addr);
	 dbuf_writeu32le(ef, fi->exec_addr);

	 // The attributes field has a "gotcha" and/or error: The ZIP documentation
	 // (from Info-Zip zip/unzip) has the Readable and Writable bits swapped
	 // from the standard RISC OS format. I can't assume that all other
	 // programmers will notice that and respect it.
	 // This just sets the file to be user-readable and user-writable.
	 // I'd like to make it public-readable (and not writable), but I don't
	 // see a safe way to do that.
	 dbuf_writeu32le(ef, 0x00000003);

	 dbuf_writeu32le(ef, 0); // reserved
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
testq %rsi, %rsi
je 0xedaa1
movq %rsi, %r14
cmpb $0x0, 0x11(%rsi)
je 0xedaa9
addq $0x8, %rsp
popq %rbx
popq %r14
retq
cmpb $0x0, 0x10(%r14)
je 0xedaa1
cmpb $0x0, 0x59(%rdi)
jne 0xedaa1
cmpb $0x0, 0x5a(%rdi)
jne 0xedaa1
movq %rdx, %rbx
movl $0x4341, %esi           # imm = 0x4341
movq %rdx, %rdi
callq 0xf1598
movl $0x14, %esi
movq %rbx, %rdi
callq 0xf1598
leaq 0x56386(%rip), %rsi     # 0x143e66
movl $0x4, %edx
movq %rbx, %rdi
callq 0xefb82
movl 0xa4(%r14), %esi
movq %rbx, %rdi
callq 0xf1645
movl 0xa8(%r14), %esi
movq %rbx, %rdi
callq 0xf1645
movl $0x3, %esi
movq %rbx, %rdi
callq 0xf1645
movq %rbx, %rdi
xorl %esi, %esi
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0xf1645
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/src/deark-tar.c
// Function: de_tar_create_file
int de_tar_create_file(deark *c)
{
	struct tar_ctx *tctx = NULL;
	int retval = 0;

	if(c->tar_data) return 1;

	tctx = de_malloc(c, sizeof(struct tar_ctx));
	c->tar_data = (void*)tctx;

	if(c->archive_to_stdout) {
		tctx->tar_filename = "[stdout]";
		de_err(c, "TAR to stdout is not implemented");
		de_fatalerror(c);
		goto done;
	}


	if(c->output_archive_filename) {
		tctx->tar_filename = c->output_archive_filename;
	}
	else {
		tctx->tar_filename = "output.tar";
	}

	de_info(c, "Creating %s", tctx->tar_filename);
	tctx->outf = dbuf_create_unmanaged_file(c, tctx->tar_filename,
		c->overwrite_mode, 0);

	if(tctx->outf->btype==DBUF_TYPE_NULL) {
		de_fatalerror(c);
		goto done;
	}

	retval = 1;

done:
	return retval;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movl $0x1, %ebp
cmpq $0x0, 0x140(%rdi)
jne 0xee2af
movq %rdi, %rbx
movl $0x28, %esi
callq 0xe969b
movq %rax, %r14
movq %rax, 0x140(%rbx)
cmpb $0x0, 0x88(%rbx)
je 0xee26a
leaq 0x5ab5a(%rip), %rax     # 0x148da4
movq %rax, (%r14)
leaq 0x5a8ed(%rip), %rsi     # 0x148b41
movq %rbx, %rdi
xorl %eax, %eax
callq 0xe9df7
movq %rbx, %rdi
callq 0xea084
xorl %ebp, %ebp
jmp 0xee2af
movq 0x160(%rbx), %rax
testq %rax, %rax
leaq 0x5a8e7(%rip), %rdx     # 0x148b62
cmovneq %rax, %rdx
movq %rdx, (%r14)
leaq 0x5a75e(%rip), %rsi     # 0x1489e7
movq %rbx, %rdi
xorl %eax, %eax
callq 0xe9ef5
movq (%r14), %rsi
movl 0xd8(%rbx), %edx
movq %rbx, %rdi
xorl %ecx, %ecx
callq 0xf0d34
movq %rax, 0x8(%r14)
cmpl $0x0, (%rax)
je 0xee25e
movl %ebp, %eax
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/src/deark-tar.c
// Function: de_tar_close_file
void de_tar_close_file(deark *c)
{
	struct tar_ctx *tctx = (struct tar_ctx *)c->tar_data;

	if(!tctx) return;
	if(tctx->outf) {
		dbuf_write_zeroes(tctx->outf, 512*2);
		dbuf_close(tctx->outf);
		de_crcobj_destroy(tctx->crco_cksum);
	}
	destroy_md(c, tctx->md);
	de_free(c, tctx);
	c->tar_data = NULL;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq 0x140(%rdi), %r14
testq %r14, %r14
je 0xee310
movq %rdi, %rbx
movq 0x8(%r14), %rdi
testq %rdi, %rdi
je 0xee2ee
movl $0x400, %esi            # imm = 0x400
callq 0xf1346
movq 0x8(%r14), %rdi
callq 0xf0b13
movq 0x10(%r14), %rdi
callq 0xebe1d
movq 0x20(%r14), %rsi
movq %rbx, %rdi
callq 0xee318
movq %rbx, %rdi
movq %r14, %rsi
callq 0xe9752
movq $0x0, 0x140(%rbx)
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/src/deark-tar.c
// Function: prepare_timestamp_exthdr
static void prepare_timestamp_exthdr(deark *c, struct tar_md *md, int tsidx)
{
	i64 unix_time;
	i64 subsec = 0;
	int is_high_prec = 0;
	struct timestamp_data *tsd = &md->tsdata[tsidx];

	if(!tsd->timestamp.is_valid) return;

	unix_time = tsd->timestamp_unix;

	if(unix_time>=0 && tsd->timestamp.precision>DE_TSPREC_1SEC) {
		subsec = de_timestamp_get_subsec(&tsd->timestamp);
		if(subsec!=0) is_high_prec = 1;
	}

	if(tsidx!=DE_TIMESTAMPIDX_MODIFY || is_high_prec || unix_time<0 || unix_time>0x1ffffffffLL) {
		tsd->need_exthdr = 1;
	}
	else {
		return;
	}

	if(is_high_prec) {
		de_snprintf(tsd->exthdr_sz, sizeof(tsd->exthdr_sz),
			"%"I64_FMT".%07"I64_FMT, unix_time, subsec);
	}
	else {
		de_snprintf(tsd->exthdr_sz, sizeof(tsd->exthdr_sz),
			"%"I64_FMT, unix_time);
	}

	// Max length for this item is around 29, so we allow 2 bytes for the
	// length field.
	// E.g. "28 mtime=1222333444.5555555\n"
	md->extdata_nbytes_needed += 2 + 1 + 5 + 1 + (i64)de_strlen(tsd->exthdr_sz) + 1;
}

// Assembly:
movl %esi, %eax
shlq $0x6, %rax
cmpb $0x0, 0x40(%rdi,%rax)
je 0xee66c
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %esi, %ebp
movq %rdi, %rbx
leaq (%rdi,%rax), %r14
addq $0x40, %r14
movq 0x10(%r14), %r15
testq %r15, %r15
js 0xee5e9
cmpb $0x1f, 0x2(%r14)
jb 0xee5e9
movq %r14, %rdi
callq 0xeadb6
testq %rax, %rax
setne %cl
jmp 0xee5ed
xorl %ecx, %ecx
xorl %eax, %eax
testl %ebp, %ebp
setne %dl
movq %r15, %rsi
shrq $0x21, %rsi
setne %sil
orb %cl, %dl
orb %sil, %dl
cmpb $0x1, %dl
jne 0xee662
movb $0x1, 0x18(%r14)
addq $0x19, %r14
testb %cl, %cl
je 0xee632
leaq 0x5a552(%rip), %rdx     # 0x148b6d
movl $0x20, %esi
movq %r14, %rdi
movq %r15, %rcx
movq %rax, %r8
xorl %eax, %eax
callq 0xe8d67
jmp 0xee64b
leaq 0x3af78(%rip), %rdx     # 0x1295b1
movl $0x20, %esi
movq %r14, %rdi
movq %r15, %rcx
xorl %eax, %eax
callq 0xe8d67
movq %r14, %rdi
callq 0x180e0
movq 0x28(%rbx), %rcx
addq %rcx, %rax
addq $0xa, %rax
movq %rax, 0x28(%rbx)
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/src/deark-tar.c
// Function: set_common_header_fields
static void set_common_header_fields(deark *c, struct tar_ctx *tctx,
	dbuf *hdr)
{
	struct tar_md *md = tctx->md;

	// uid
	format_and_write_ascii_octal_field(c, tctx, 0, 8, hdr, 108);
	// gid
	format_and_write_ascii_octal_field(c, tctx, 0, 8, hdr, 116);
	// mtime
	format_and_write_ascii_octal_field(c, tctx, md->tsdata[DE_TIMESTAMPIDX_MODIFY].timestamp_unix, 12, hdr, 136);
	// magic/version
	dbuf_write_at(hdr, 257, (const u8*)"ustar\0" "00", 8);
	format_and_write_ascii_field(c, tctx, "root", 32, hdr, 265); // uname
	format_and_write_ascii_field(c, tctx, "root", 32, hdr, 297); // gname
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rsi, %rbx
movq 0x20(%rdi), %r15
leaq 0x4(%rsp), %r14
movl $0x8, %edx
xorl %edi, %edi
movq %r14, %rsi
callq 0xeecee
movl $0x6c, %esi
movl $0x8, %ecx
movq %rbx, %rdi
movq %r14, %rdx
callq 0xf11f9
leaq 0x4(%rsp), %r14
movl $0x8, %edx
xorl %edi, %edi
movq %r14, %rsi
callq 0xeecee
movl $0x74, %esi
movl $0x8, %ecx
movq %rbx, %rdi
movq %r14, %rdx
callq 0xf11f9
movq 0x50(%r15), %rdi
leaq 0x4(%rsp), %r14
movl $0xc, %edx
movq %r14, %rsi
callq 0xeecee
movl $0x88, %esi
movl $0xc, %ecx
movq %rbx, %rdi
movq %r14, %rdx
callq 0xf11f9
leaq 0x59fd8(%rip), %rdx     # 0x148b93
movl $0x101, %esi            # imm = 0x101
movl $0x8, %ecx
movq %rbx, %rdi
callq 0xf11f9
leaq 0x2b242(%rip), %r14     # 0x119e16
movl $0x20, %esi
movl $0x109, %ecx            # imm = 0x109
movq %r14, %rdi
movq %rbx, %rdx
callq 0xeec08
movl $0x20, %esi
movl $0x129, %ecx            # imm = 0x129
movq %r14, %rdi
movq %rbx, %rdx
callq 0xeec08
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/src/deark-tar.c
// Function: set_checksum_field
static void set_checksum_field(deark *c, struct tar_ctx *tctx,
	dbuf *hdr)
{
	u8 buf[8];

	calc_checksum(c, tctx, hdr);
	format_ascii_octal_field(c, tctx, tctx->checksum_calc, buf, 7);
	buf[6] = 0x00;
	buf[7] = 0x20;
	dbuf_write_at(hdr, 148, buf, 8);
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdx, %rbx
movq %rsi, %r14
movq 0x10(%rsi), %rax
testq %rax, %rax
je 0xeec61
movq %rax, %rdi
callq 0xebdc3
jmp 0xeec6f
movl $0x30, %esi
callq 0xeba56
movq %rax, 0x10(%r14)
movq 0x10(%r14), %rdi
movl $0x94, %ecx
movq %rbx, %rsi
xorl %edx, %edx
callq 0xebf09
movq 0x10(%r14), %rdi
movl $0x8, %edx
movl $0x20, %esi
callq 0xebe83
movq 0x10(%r14), %rdi
movl $0x9c, %edx
movl $0x164, %ecx            # imm = 0x164
movq %rbx, %rsi
callq 0xebf09
movq 0x10(%r14), %rdi
callq 0xebe2a
movl %eax, %edi
movq %rdi, 0x18(%r14)
movq %rsp, %r14
movl $0x7, %edx
movq %r14, %rsi
callq 0xeecee
movw $0x2000, 0x6(%r14)      # imm = 0x2000
movl $0x94, %esi
movl $0x8, %ecx
movq %rbx, %rdi
movq %r14, %rdx
callq 0xf11f9
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O1/jsummers[P]deark/src/deark-tar.c
// Function: format_ascii_octal_field
static int format_ascii_octal_field(deark *c, struct tar_ctx *tctx,
	i64 val, u8 *buf2, size_t buf2len)
{
	char buf1[32]; // The largest field we need to support is 12 bytes
	size_t k;
	size_t len_in_octal;

	de_zeromem(buf2, buf2len);
	if(buf2len>12) return 0;
	if(val<0) val = 0;

	de_snprintf(buf1, sizeof(buf1), "%"U64_FMTo, (u64)val);
	len_in_octal = de_strlen(buf1);
	if(len_in_octal > buf2len) {
		for(k=0; k<buf2len; k++) {
			buf2[k] = '7';
		}
	}
	else if(len_in_octal == buf2len) {
		de_memcpy(buf2, buf1, buf2len);
	}
	else {
		size_t num_leading_0s = buf2len - 1 - len_in_octal;

		for(k=0; k<buf2len; k++) {
			if(k < num_leading_0s) {
				buf2[k] = '0';
			}
			else if(k < buf2len - 1) {
				buf2[k] = buf1[k-num_leading_0s];
			}
			else {
				buf2[k] = '\0';
			}
		}
	}

	return 1;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rdx, %rbx
movq %rsi, %r14
movq %rdi, %r12
xorl %r15d, %r15d
movq %rsi, %rdi
xorl %esi, %esi
callq 0x18140
testq %r12, %r12
cmovleq %r15, %r12
leaq 0x59e5a(%rip), %rdx     # 0x148b77
movq %rsp, %r15
movl $0x20, %esi
movq %r15, %rdi
movq %r12, %rcx
xorl %eax, %eax
callq 0xe8d67
movq %r15, %rdi
callq 0x180e0
movq %rax, %rsi
subq %rbx, %rsi
jbe 0xeed59
testq %rbx, %rbx
je 0xeeda5
movq %r14, %rdi
movl $0x37, %esi
movq %rbx, %rdx
callq 0x18140
jmp 0xeeda5
jne 0xeed6b
movq %rsp, %rsi
movq %r14, %rdi
movq %rbx, %rdx
callq 0x181e0
jmp 0xeeda5
leaq -0x1(%rbx), %rcx
movq %rbx, %rdx
subq $0x1, %rdx
jb 0xeeda5
subq %rax, %rcx
leaq (%rsi,%r15), %rax
incq %rax
xorl %esi, %esi
movb $0x30, %dil
cmpq %rcx, %rsi
jb 0xeed99
cmpq %rdx, %rsi
jae 0xeed97
movb (%rax,%rsi), %dil
jmp 0xeed99
xorl %edi, %edi
movb %dil, (%r14,%rsi)
incq %rsi
cmpq %rsi, %rbx
jne 0xeed84
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq