LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O3/nurse[P]nkf/nkf.c
// Function: nkf_default_encoding
static nkf_encoding*
nkf_default_encoding(void)
{
    nkf_encoding *enc = 0;
#ifdef DEFAULT_CODE_LOCALE
    enc = nkf_locale_encoding();
#elif defined(DEFAULT_ENCIDX)
    enc = nkf_enc_from_index(DEFAULT_ENCIDX);
#endif
    if (!enc) enc = nkf_utf8_encoding();
    return enc;
}

// Assembly:
pushq %rax
movl $0xe, %edi
callq 0xc1a0
testq %rax, %rax
je 0x1266a
movq %rax, %rdi
callq 0x120ee
testq %rax, %rax
jne 0x12671
leaq 0x343a7(%rip), %rax     # 0x46a18
popq %rcx
retq
// File: /workspace/github_c_makefile_star2_O3/nurse[P]nkf/nkf.c
// Function: eol_conv
static void
eol_conv(nkf_char c2, nkf_char c1)
{
    if (guess_f && input_eol != EOF) {
	if (c2 == 0 && c1 == LF) {
	    if (!input_eol) input_eol = prev_cr ? CRLF : LF;
	    else if (input_eol != (prev_cr ? CRLF : LF)) input_eol = EOF;
	} else if (c2 == 0 && c1 == CR && input_eol == LF) input_eol = EOF;
	else if (!prev_cr);
	else if (!input_eol) input_eol = CR;
	else if (input_eol != CR) input_eol = EOF;
    }
    if (prev_cr || (c2 == 0 && c1 == LF)) {
	prev_cr = 0;
	if (eolmode_f != LF) (*o_eol_conv)(0, CR);
	if (eolmode_f != CR) (*o_eol_conv)(0, LF);
    }
    if (c2 == 0 && c1 == CR) prev_cr = CR;
    else if (c2 != 0 || c1 != LF) (*o_eol_conv)(c2, c1);
}

// Assembly:
pushq %rbp
pushq %rbx
pushq %rax
movl %esi, %ebx
movl %edi, %ebp
cmpl $0x0, 0x39a48(%rip)     # 0x4d3b0
setne %cl
movl 0x41a6f(%rip), %eax     # 0x553e0
cmpl $-0x1, %eax
setne %dl
andb %cl, %dl
cmpb $0x1, %dl
jne 0x139ca
movl %ebx, %ecx
xorl $0xa, %ecx
orl %ebp, %ecx
jne 0x139b0
movb 0x41c6f(%rip), %cl      # 0x555fc
testb %cl, %cl
movl $0xd0a, %esi            # imm = 0xD0A
movl $0xa, %edx
cmovnel %esi, %edx
testl %eax, %eax
je 0x139f5
cmpl %edx, %eax
je 0x139fb
movl $0xffffffff, 0x41a32(%rip) # imm = 0xFFFFFFFF
jmp 0x139fb
movl %ebx, %ecx
xorl $0xd, %ecx
orl %ebp, %ecx
movl %eax, %edx
xorl $0xa, %edx
orl %ecx, %edx
jne 0x139d5
movl $0xffffffff, 0x41a16(%rip) # imm = 0xFFFFFFFF
cmpb $0x0, 0x41c2b(%rip)     # 0x555fc
je 0x139ff
jmp 0x13a08
cmpb $0x1, 0x41c20(%rip)     # 0x555fc
jne 0x139ff
testl %eax, %eax
je 0x13a70
cmpl $0xd, %eax
je 0x13a08
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
jmp 0x13a75
movl %edx, 0x419e5(%rip)     # 0x553e0
testb %cl, %cl
jne 0x13a08
movl %ebx, %eax
xorl $0xa, %eax
orl %ebp, %eax
jne 0x13a3b
movb $0x0, 0x41bed(%rip)     # 0x555fc
cmpl $0xa, 0x41b7e(%rip)     # 0x55594
je 0x13a2e
xorl %edi, %edi
movl $0xd, %esi
callq *0x398db(%rip)          # 0x4d300
cmpl $0xd, 0x41b68(%rip)     # 0x55594
je 0x13a3b
xorl %edi, %edi
movl $0xa, %esi
callq *0x398c5(%rip)          # 0x4d300
movl %ebx, %eax
xorl $0xd, %eax
orl %ebp, %eax
jne 0x13a4d
movb $0x1, 0x41bb1(%rip)     # 0x555fc
jmp 0x13a69
movl %ebx, %eax
xorl $0xa, %eax
orl %ebp, %eax
je 0x13a69
movq 0x398a3(%rip), %rax     # 0x4d300
movl %ebp, %edi
movl %ebx, %esi
addq $0x8, %rsp
popq %rbx
popq %rbp
jmpq *%rax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
movl $0xd, %eax
movl %eax, 0x41965(%rip)     # 0x553e0
jmp 0x13a08
// File: /workspace/github_c_makefile_star2_O3/nurse[P]nkf/nkf.c
// Function: rot_conv
static void
rot_conv(nkf_char c2, nkf_char c1)
{
    if (c2 == 0 || c2 == JIS_X_0201_1976_K || c2 == ISO_8859_1) {
	c1 = rot13(c1);
    } else if (c2) {
	c1 = rot47(c1);
	c2 = rot47(c2);
    }
    (*o_rot_conv)(c2,c1);
}

// Assembly:
cmpl $0x2, %edi
jb 0x13a8a
cmpl $0x1013, %edi           # imm = 0x1013
jne 0x13a99
cmpl $0x41, %esi
jl 0x13aee
cmpl $0x4d, %esi
ja 0x13aa8
addl $0xd, %esi
jmp 0x13aee
cmpl $0x21, %esi
jl 0x13ad4
cmpl $0x4f, %esi
ja 0x13ac9
addl $0x2f, %esi
jmp 0x13ad4
cmpl $0x5a, %esi
ja 0x13ab2
addl $-0xd, %esi
jmp 0x13aee
cmpl $0x61, %esi
jb 0x13aee
cmpl $0x6d, %esi
jbe 0x13a94
leal -0xd(%rsi), %eax
cmpl $0x7b, %esi
cmovael %esi, %eax
movl %eax, %esi
jmp 0x13aee
leal -0x2f(%rsi), %eax
cmpl $0x7f, %esi
cmovael %esi, %eax
movl %eax, %esi
cmpl $0x21, %edi
jl 0x13aee
cmpl $0x4f, %edi
ja 0x13ae3
addl $0x2f, %edi
jmp 0x13aee
leal -0x2f(%rdi), %eax
cmpl $0x7f, %edi
cmovael %edi, %eax
movl %eax, %edi
movq 0x39813(%rip), %rax     # 0x4d308
jmpq *%rax
// File: /workspace/github_c_makefile_star2_O3/nurse[P]nkf/nkf.c
// Function: hira_conv
static void
hira_conv(nkf_char c2, nkf_char c1)
{
    if (hira_f & 1) {
	if (c2 == 0x25) {
	    if (0x20 < c1 && c1 < 0x74) {
		c2 = 0x24;
		(*o_hira_conv)(c2,c1);
		return;
	    } else if (c1 == 0x74 && nkf_enc_unicode_p(output_encoding)) {
		c2 = 0;
		c1 = nkf_char_unicode_new(0x3094);
		(*o_hira_conv)(c2,c1);
		return;
	    }
	} else if (c2 == 0x21 && (c1 == 0x33 || c1 == 0x34)) {
	    c1 += 2;
	    (*o_hira_conv)(c2,c1);
	    return;
	}
    }
    if (hira_f & 2) {
	if (c2 == 0 && c1 == nkf_char_unicode_new(0x3094)) {
	    c2 = 0x25;
	    c1 = 0x74;
	} else if (c2 == 0x24 && 0x20 < c1 && c1 < 0x74) {
	    c2 = 0x25;
	} else if (c2 == 0x21 && (c1 == 0x35 || c1 == 0x36)) {
	    c1 -= 2;
	}
    }
    (*o_hira_conv)(c2,c1);
}

// Assembly:
movl 0x419ec(%rip), %eax     # 0x55568
testb $0x1, %al
je 0x13bed
cmpl $0x21, %edi
je 0x13ba0
cmpl $0x25, %edi
jne 0x13bed
leal -0x21(%rsi), %ecx
cmpl $0x52, %ecx
ja 0x13bb9
movq 0x39777(%rip), %rax     # 0x4d310
movl $0x24, %edi
jmpq *%rax
leal -0x33(%rsi), %ecx
cmpl $0x1, %ecx
ja 0x13bed
addl $0x2, %esi
movq 0x3975e(%rip), %rax     # 0x4d310
movl $0x21, %edi
jmpq *%rax
cmpl $0x74, %esi
jne 0x13bed
movq 0x41983(%rip), %rcx     # 0x55548
movq 0x10(%rcx), %rcx
leaq 0x32c30(%rip), %rdx     # 0x46800
cmpq %rdx, %rcx
je 0x13c43
leaq 0x32bf4(%rip), %rdx     # 0x467d0
cmpq %rdx, %rcx
je 0x13c43
leaq 0x32c00(%rip), %rdx     # 0x467e8
cmpq %rdx, %rcx
je 0x13c43
testb $0x2, %al
je 0x13c3a
movl %esi, %eax
xorl $0x1003094, %eax        # imm = 0x1003094
orl %edi, %eax
jne 0x13c08
movl $0x25, %edi
movl $0x74, %esi
jmp 0x13c3a
cmpl $0x24, %edi
sete %al
leal -0x21(%rsi), %ecx
cmpl $0x53, %ecx
setb %cl
testb %cl, %al
je 0x13c22
movl $0x25, %edi
jmp 0x13c3a
cmpl $0x21, %edi
jne 0x13c3a
leal -0x35(%rsi), %eax
leal -0x2(%rsi), %ecx
cmpl $0x2, %eax
cmovael %esi, %ecx
movl $0x21, %edi
movl %ecx, %esi
movq 0x396cf(%rip), %rax     # 0x4d310
jmpq *%rax
movq 0x396c6(%rip), %rax     # 0x4d310
xorl %edi, %edi
movl $0x1003094, %esi        # imm = 0x1003094
jmpq *%rax
// File: /workspace/github_c_makefile_star2_O3/nurse[P]nkf/nkf.c
// Function: numchar_getc
static nkf_char
numchar_getc(FILE *f)
{
    nkf_char (*g)(FILE *) = i_ngetc;
    nkf_char (*u)(nkf_char c ,FILE *f) = i_nungetc;
    int i = 0, j;
    nkf_char buf[12];
    nkf_char c = -1;

    buf[i] = (*g)(f);
    if (buf[i] == '&'){
	buf[++i] = (*g)(f);
	if (buf[i] == '#'){
	    c = 0;
	    buf[++i] = (*g)(f);
	    if (buf[i] == 'x' || buf[i] == 'X'){
		for (j = 0; j < 7; j++){
		    buf[++i] = (*g)(f);
		    if (!nkf_isxdigit(buf[i])){
			if (buf[i] != ';'){
			    c = -1;
			}
			break;
		    }
		    c <<= 4;
		    c |= hex2bin(buf[i]);
		}
	    }else{
		for (j = 0; j < 8; j++){
		    if (j){
			buf[++i] = (*g)(f);
		    }
		    if (!nkf_isdigit(buf[i])){
			if (buf[i] != ';'){
			    c = -1;
			}
			break;
		    }
		    c *= 10;
		    c += hex2bin(buf[i]);
		}
	    }
	}
    }
    if (c != -1){
	return nkf_char_unicode_new(c);
    }
    while (i > 0){
	(*u)(buf[i], f);
	--i;
    }
    return buf[0];
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq %rdi, %rbx
movq 0x38fa3(%rip), %r13     # 0x4d380
movq 0x38fa4(%rip), %r15     # 0x4d388
callq *%r13
movl %eax, (%rsp)
cmpl $0x26, %eax
jne 0x144e3
movq %rbx, %rdi
callq *%r13
movl %eax, 0x4(%rsp)
movl $0x1, %r12d
cmpl $0x23, %eax
jne 0x144c9
movq %rbx, %rdi
callq *%r13
movl %eax, 0x8(%rsp)
orl $0x20, %eax
cmpl $0x78, %eax
jne 0x1446b
xorl %r14d, %r14d
movl $0x3, %r12d
movq %rbx, %rdi
callq *%r13
movl %eax, (%rsp,%r12,4)
leal -0x30(%rax), %ecx
cmpl $0xa, %ecx
jb 0x14453
leal -0x61(%rax), %ecx
cmpl $0x5, %ecx
ja 0x14446
addl $-0x57, %eax
jmp 0x14451
leal -0x41(%rax), %ecx
cmpl $0x6, %ecx
jae 0x144b0
addl $-0x37, %eax
movl %eax, %ecx
shll $0x4, %r14d
orl %ecx, %r14d
incq %r12
cmpq $0xa, %r12
jne 0x14427
movl $0x9, %r12d
jmp 0x144b5
movl $0x2, %r12d
xorl %r14d, %r14d
movl $0x8, %ebp
cmpl $0x8, %ebp
jne 0x14486
movslq %r12d, %rax
movl (%rsp,%rax,4), %eax
jmp 0x14496
movq %rbx, %rdi
callq *%r13
movslq %r12d, %rcx
incl %r12d
movl %eax, 0x4(%rsp,%rcx,4)
leal -0x30(%rax), %ecx
cmpl $0xa, %ecx
jae 0x144b0
leal (%r14,%r14,4), %ecx
leal (%rax,%rcx,2), %r14d
addl $-0x30, %r14d
decl %ebp
jne 0x14479
jmp 0x144b5
cmpl $0x3b, %eax
jne 0x144c4
cmpl $-0x1, %r14d
je 0x144c4
orl $0x1000000, %r14d       # imm = 0x1000000
jmp 0x144e7
testl %r12d, %r12d
jle 0x144e3
movl %r12d, %r14d
incq %r14
movl -0x4(%rsp,%r14,4), %edi
movq %rbx, %rsi
callq *%r15
decq %r14
cmpq $0x1, %r14
ja 0x144cf
movl (%rsp), %r14d
movl %r14d, %eax
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/nurse[P]nkf/nkf.c
// Function: broken_getc
static nkf_char
broken_getc(FILE *f)
{
    nkf_char c, c1;

    if (!nkf_buf_empty_p(nkf_state->broken_buf)) {
	return nkf_buf_pop(nkf_state->broken_buf);
    }
    c = (*i_bgetc)(f);
    if (c=='$' && nkf_state->broken_state != ESC
	&& (input_mode == ASCII || input_mode == JIS_X_0201_1976_K)) {
	c1= (*i_bgetc)(f);
	nkf_state->broken_state = 0;
	if (c1=='@'|| c1=='B') {
	    nkf_buf_push(nkf_state->broken_buf, c1);
	    nkf_buf_push(nkf_state->broken_buf, c);
	    return ESC;
	} else {
	    (*i_bungetc)(c1,f);
	    return c;
	}
    } else if (c=='(' && nkf_state->broken_state != ESC
	       && (input_mode == JIS_X_0208 || input_mode == JIS_X_0201_1976_K)) {
	c1= (*i_bgetc)(f);
	nkf_state->broken_state = 0;
	if (c1=='J'|| c1=='B') {
	    nkf_buf_push(nkf_state->broken_buf, c1);
	    nkf_buf_push(nkf_state->broken_buf, c);
	    return ESC;
	} else {
	    (*i_bungetc)(c1,f);
	    return c;
	}
    } else {
	nkf_state->broken_state = c;
	return c;
    }
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
movq 0x405bf(%rip), %rax     # 0x55538
movq 0x10(%rax), %rdi
cmpq $0x0, 0x8(%rdi)
je 0x14f8a
popq %rbx
jmp 0x126bd
movq %rbx, %rdi
callq *0x383a5(%rip)          # 0x4d338
movq 0x4059e(%rip), %rcx     # 0x55538
cmpl $0x28, %eax
je 0x1502f
cmpl $0x24, %eax
jne 0x150a7
cmpl $0x1b, 0x8(%rcx)
je 0x150a7
movl 0x4063c(%rip), %edx     # 0x555f8
cmpl $0x1013, %edx           # imm = 0x1013
je 0x14fcc
testl %edx, %edx
jne 0x150a7
movq %rbx, %rdi
callq *0x38363(%rip)          # 0x4d338
movq 0x4055c(%rip), %rcx     # 0x55538
movl $0x0, 0x8(%rcx)
movl %eax, %edx
andl $-0x3, %edx
cmpl $0x40, %edx
jne 0x150ac
movq 0x10(%rcx), %rcx
movq (%rcx), %rsi
movq 0x8(%rcx), %rdx
cmpq %rdx, %rsi
jle 0x150d0
movq 0x10(%rcx), %rdi
leaq 0x1(%rdx), %r8
movq %r8, 0x8(%rcx)
movl %eax, (%rdi,%rdx,4)
cmpq %r8, %rsi
jle 0x150d0
leaq 0x2(%rdx), %rax
movq %rax, 0x8(%rcx)
movl $0x24, 0x4(%rdi,%rdx,4)
jmp 0x150a0
cmpl $0x1b, 0x8(%rcx)
je 0x150a7
movl 0x405bd(%rip), %edx     # 0x555f8
cmpl $0x1168, %edx           # imm = 0x1168
je 0x1504b
cmpl $0x1013, %edx           # imm = 0x1013
jne 0x150a7
movq %rbx, %rdi
callq *0x382e4(%rip)          # 0x4d338
movq 0x404dd(%rip), %rcx     # 0x55538
movl $0x0, 0x8(%rcx)
movl %eax, %edx
andl $-0x9, %edx
cmpl $0x42, %edx
jne 0x150be
movq 0x10(%rcx), %rcx
movq (%rcx), %rsi
movq 0x8(%rcx), %rdx
cmpq %rdx, %rsi
jle 0x150d0
movq 0x10(%rcx), %rdi
leaq 0x1(%rdx), %r8
movq %r8, 0x8(%rcx)
movl %eax, (%rdi,%rdx,4)
cmpq %r8, %rsi
jle 0x150d0
leaq 0x2(%rdx), %rax
movq %rax, 0x8(%rcx)
movl $0x28, 0x4(%rdi,%rdx,4)
movl $0x1b, %eax
jmp 0x150aa
movl %eax, 0x8(%rcx)
popq %rbx
retq
movl %eax, %edi
movq %rbx, %rsi
callq *0x38289(%rip)          # 0x4d340
movl $0x24, %eax
jmp 0x150aa
movl %eax, %edi
movq %rbx, %rsi
callq *0x38277(%rip)          # 0x4d340
movl $0x28, %eax
jmp 0x150aa
movl $0x1, %edi
callq 0xc240
// File: /workspace/github_c_makefile_star2_O3/nurse[P]nkf/nkf.c
// Function: eof_mime
static void
eof_mime(void)
{
    switch(mimeout_mode) {
    case 'Q':
    case 'B':
	break;
    case 2:
	(*o_mputc)(basis_64[((nkf_state->mimeout_state & 0x3)<< 4)]);
	(*o_mputc)('=');
	(*o_mputc)('=');
	base64_count += 3;
	break;
    case 1:
	(*o_mputc)(basis_64[((nkf_state->mimeout_state & 0xF) << 2)]);
	(*o_mputc)('=');
	base64_count += 2;
	break;
    }
    if (mimeout_mode > 0) {
	if (mimeout_f!=FIXED_MIME) {
	    close_mime();
	} else if (mimeout_mode != 'Q')
	    mimeout_mode = 'B';
    }
}

// Assembly:
pushq %rbx
movl 0x40470(%rip), %eax     # 0x55588
cmpl $0x1, %eax
je 0x15155
cmpl $0x2, %eax
jne 0x1518f
movq 0x4040f(%rip), %rax     # 0x55538
movl 0x18(%rax), %eax
shll $0x4, %eax
andl $0x30, %eax
leaq 0x36e7(%rip), %rcx      # 0x18820
movsbl (%rax,%rcx), %edi
callq *0x38205(%rip)          # 0x4d348
movl $0x3d, %edi
callq *0x381fa(%rip)          # 0x4d348
movl $0x3, %ebx
jmp 0x15178
movq 0x403dc(%rip), %rax     # 0x55538
movl 0x18(%rax), %eax
andl $0xf, %eax
leaq 0x36b7(%rip), %rcx      # 0x18820
movsbl (%rcx,%rax,4), %edi
callq *0x381d5(%rip)          # 0x4d348
movl $0x2, %ebx
movl $0x3d, %edi
callq *0x381c5(%rip)          # 0x4d348
addl %ebx, 0x40463(%rip)     # 0x555ec
movl 0x403f9(%rip), %eax     # 0x55588
testl %eax, %eax
jle 0x151cd
cmpl $0x7, 0x403f2(%rip)     # 0x5558c
jne 0x151a8
movl $0x42, %ecx
cmpl $0x51, %eax
jne 0x151c7
jmp 0x151cd
movl $0x3f, %edi
callq *0x38195(%rip)          # 0x4d348
movl $0x3d, %edi
callq *0x3818a(%rip)          # 0x4d348
addl $0x2, 0x40427(%rip)     # 0x555ec
xorl %ecx, %ecx
movl %ecx, 0x403bb(%rip)     # 0x55588
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O3/nurse[P]nkf/nkf.c
// Function: mimeout_addchar
static void
mimeout_addchar(nkf_char c)
{
    switch(mimeout_mode) {
    case 'Q':
	if (c==CR||c==LF) {
	    (*o_mputc)(c);
	    base64_count = 0;
	} else if(!nkf_isalnum(c)) {
	    (*o_mputc)('=');
	    (*o_mputc)(bin2hex(((c>>4)&0xf)));
	    (*o_mputc)(bin2hex((c&0xf)));
	    base64_count += 3;
	} else {
	    (*o_mputc)(c);
	    base64_count++;
	}
	break;
    case 'B':
	nkf_state->mimeout_state=c;
	(*o_mputc)(basis_64[c>>2]);
	mimeout_mode=2;
	base64_count ++;
	break;
    case 2:
	(*o_mputc)(basis_64[((nkf_state->mimeout_state & 0x3)<< 4) | ((c & 0xF0) >> 4)]);
	nkf_state->mimeout_state=c;
	mimeout_mode=1;
	base64_count ++;
	break;
    case 1:
	(*o_mputc)(basis_64[((nkf_state->mimeout_state & 0xF) << 2) | ((c & 0xC0) >>6)]);
	(*o_mputc)(basis_64[c & 0x3F]);
	mimeout_mode='B';
	base64_count += 2;
	break;
    default:
	(*o_mputc)(c);
	base64_count++;
	break;
    }
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movl %edi, %ebx
movl 0x403ad(%rip), %eax     # 0x55588
cmpl $0x41, %eax
jg 0x1522e
cmpl $0x1, %eax
je 0x1525f
cmpl $0x2, %eax
jne 0x15255
movq 0x40347(%rip), %rax     # 0x55538
movl 0x18(%rax), %eax
shll $0x4, %eax
andl $0x30, %eax
movl %ebx, %ecx
shrl $0x4, %ecx
andl $0xf, %ecx
orl %eax, %ecx
leaq 0x3615(%rip), %rax      # 0x18820
movsbl (%rcx,%rax), %edi
callq *0x38133(%rip)          # 0x4d348
movq 0x4031c(%rip), %rax     # 0x55538
movl %ebx, 0x18(%rax)
movl $0x1, 0x4035f(%rip)     # 0x55588
jmp 0x152d7
cmpl $0x42, %eax
je 0x152ac
cmpl $0x51, %eax
jne 0x15255
cmpl $0xd, %ebx
je 0x15246
cmpl $0xa, %ebx
jne 0x152ed
movl %ebx, %edi
callq *0x380fa(%rip)          # 0x4d348
xorl %eax, %eax
jmp 0x152df
movl %ebx, %edi
callq *0x380eb(%rip)          # 0x4d348
jmp 0x152d7
movq 0x402d2(%rip), %rax     # 0x55538
movl 0x18(%rax), %eax
andl $0xf, %eax
movl %ebx, %ecx
shrl $0x6, %ecx
andl $0x3, %ecx
leal (%rcx,%rax,4), %eax
leaq 0x35a2(%rip), %r14      # 0x18820
movsbl (%rax,%r14), %edi
callq *0x380bf(%rip)          # 0x4d348
andl $0x3f, %ebx
movsbl (%rbx,%r14), %edi
callq *0x380b1(%rip)          # 0x4d348
movl $0x42, 0x402e7(%rip)    # 0x55588
movl 0x40345(%rip), %eax     # 0x555ec
addl $0x2, %eax
jmp 0x152df
movq 0x40285(%rip), %rax     # 0x55538
movl %ebx, 0x18(%rax)
sarl $0x2, %ebx
movslq %ebx, %rax
leaq 0x355d(%rip), %rcx      # 0x18820
movsbl (%rax,%rcx), %edi
callq *0x3807b(%rip)          # 0x4d348
movl $0x2, 0x402b1(%rip)     # 0x55588
movl 0x4030f(%rip), %eax     # 0x555ec
incl %eax
movl %eax, 0x40307(%rip)     # 0x555ec
addq $0x8, %rsp
popq %rbx
popq %r14
retq
leal -0x30(%rbx), %ecx
movq 0x38051(%rip), %rax     # 0x4d348
cmpl $0xa, %ecx
jb 0x15343
movl %ebx, %ecx
andl $-0x21, %ecx
addl $-0x41, %ecx
cmpl $0x1a, %ecx
jb 0x15343
movl $0x3d, %edi
callq *%rax
movl %ebx, %eax
shrl $0x4, %eax
andl $0xf, %eax
leaq 0x3175(%rip), %r14      # 0x18494
movsbl (%rax,%r14), %edi
callq *0x3801e(%rip)          # 0x4d348
andl $0xf, %ebx
movsbl (%rbx,%r14), %edi
callq *0x38010(%rip)          # 0x4d348
movl 0x402ae(%rip), %eax     # 0x555ec
addl $0x3, %eax
jmp 0x152df
movl %ebx, %edi
callq *%rax
jmp 0x152d7
// File: /workspace/github_c_makefile_star2_O3/nurse[P]nkf/nkf.c
// Function: hex_getc
static nkf_char
hex_getc(nkf_char ch, FILE *f, nkf_char (*g)(FILE *f), nkf_char (*u)(nkf_char c, FILE *f))
{
    nkf_char c1, c2, c3;
    c1 = (*g)(f);
    if (c1 != ch){
	return c1;
    }
    c2 = (*g)(f);
    if (!nkf_isxdigit(c2)){
	(*u)(c2, f);
	return c1;
    }
    c3 = (*g)(f);
    if (!nkf_isxdigit(c3)){
	(*u)(c2, f);
	(*u)(c3, f);
	return c1;
    }
    return (hex2bin(c2) << 4) | hex2bin(c3);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rcx, %r14
movq %rdx, %rbx
movq %rsi, %r15
movl %edi, %ebp
movq %rsi, %rdi
callq *%rdx
cmpl %ebp, %eax
jne 0x155d6
movq %r15, %rdi
callq *%rbx
movl %eax, %r12d
leal -0x30(%r12), %r13d
cmpl $0xa, %r13d
jb 0x1555a
leal -0x41(%r12), %eax
cmpl $0x25, %eax
ja 0x155e5
movabsq $0x3f0000003f, %rcx     # imm = 0x3F0000003F
btq %rax, %rcx
jae 0x155e5
movq %r15, %rdi
callq *%rbx
movl %eax, %ebx
leal -0x30(%rbx), %eax
cmpl $0xa, %eax
jb 0x15581
leal -0x41(%rbx), %ecx
cmpl $0x25, %ecx
ja 0x155ea
movabsq $0x3f0000003f, %rdx     # imm = 0x3F0000003F
btq %rcx, %rdx
jae 0x155ea
cmpl $0xa, %r13d
jb 0x155ad
leal -0x41(%r12), %ecx
cmpl $0x5, %ecx
ja 0x1559a
addl $-0x37, %r12d
movl %r12d, %r13d
jmp 0x155ad
leal -0x61(%r12), %ecx
addl $-0x57, %r12d
xorl %r13d, %r13d
cmpl $0x6, %ecx
cmovbl %r12d, %r13d
shll $0x4, %r13d
cmpl $0xa, %eax
jb 0x155d3
leal -0x41(%rbx), %eax
cmpl $0x5, %eax
ja 0x155c5
addl $-0x37, %ebx
movl %ebx, %eax
jmp 0x155d3
leal -0x61(%rbx), %ecx
addl $-0x57, %ebx
xorl %eax, %eax
cmpl $0x6, %ecx
cmovbl %ebx, %eax
orl %r13d, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl %r12d, %edi
jmp 0x155f5
movl %r12d, %edi
movq %r15, %rsi
callq *%r14
movl %ebx, %edi
movq %r15, %rsi
callq *%r14
movl %ebp, %eax
jmp 0x155d6
// File: /workspace/github_c_makefile_star2_O3/nurse[P]nkf/nkf.c
// Function: nkf_iconv_utf_16
static size_t
nkf_iconv_utf_16(nkf_char c1, nkf_char c2, nkf_char c3, nkf_char c4)
{
    nkf_char wc;

    if (c1 == EOF) {
	(*oconv)(EOF, 0);
	return 0;
    }

    if (input_endian == ENDIAN_BIG) {
	if (0xD8 <= c1 && c1 <= 0xDB) {
	    if (0xDC <= c3 && c3 <= 0xDF) {
		wc = UTF16_TO_UTF32(c1 << 8 | c2, c3 << 8 | c4);
	    } else return NKF_ICONV_NEED_TWO_MORE_BYTES;
	} else {
	    wc = c1 << 8 | c2;
	}
    } else {
	if (0xD8 <= c2 && c2 <= 0xDB) {
	    if (0xDC <= c4 && c4 <= 0xDF) {
		wc = UTF16_TO_UTF32(c2 << 8 | c1, c4 << 8 | c3);
	    } else return NKF_ICONV_NEED_TWO_MORE_BYTES;
	} else {
	    wc = c2 << 8 | c1;
	}
    }

    return (*unicode_iconv)(wc, FALSE);
}

// Assembly:
cmpl $0x1, 0x37cc4(%rip)     # 0x4d2e4
jne 0x15652
movl %edi, %eax
andl $-0x4, %eax
cmpl $0xd8, %eax
jne 0x15681
movl %edx, %eax
andl $-0x4, %eax
cmpl $0xdc, %eax
jne 0x15696
shll $0x12, %edi
shll $0xa, %esi
orl %edi, %esi
shll $0x8, %edx
orl %ecx, %edx
leal (%rsi,%rdx), %edi
addl $0xfca02400, %edi       # imm = 0xFCA02400
jmp 0x1568f
movl %esi, %eax
andl $-0x4, %eax
cmpl $0xd8, %eax
jne 0x15688
movl %ecx, %eax
andl $-0x4, %eax
cmpl $0xdc, %eax
jne 0x15696
shll $0x12, %esi
shll $0xa, %edi
orl %esi, %edi
shll $0x8, %ecx
orl %edx, %ecx
addl %ecx, %edi
addl $0xfca02400, %edi       # imm = 0xFCA02400
jmp 0x1568f
shll $0x8, %edi
orl %esi, %edi
jmp 0x1568f
shll $0x8, %esi
orl %edi, %esi
movl %esi, %edi
xorl %esi, %esi
jmp 0x15e4f
movq $-0x2, %rax
retq
// File: /workspace/github_c_makefile_star2_O3/nurse[P]nkf/nkf.c
// Function: code_status
static void
code_status(nkf_char c)
{
    int action_flag = 1;
    struct input_code *result = 0;
    struct input_code *p = input_code_list;
    while (p->name){
	if (!p->status_func) {
	    ++p;
	    continue;
	}
	if (!p->status_func)
	    continue;
	(p->status_func)(p, c);
	if (p->stat > 0){
	    action_flag = 0;
	}else if(p->stat == 0){
	    if (result){
		action_flag = 0;
	    }else{
		result = p;
	    }
	}
	++p;
    }

    if (action_flag){
	if (result && !estab_f){
	    set_iconv(TRUE, result->iconv_func);
	}else if (c <= DEL){
	    struct input_code *ptr = input_code_list;
	    while (ptr->name){
		status_reset(ptr);
		++ptr;
	    }
	}
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %edi, %ebx
cmpq $0x0, 0x37a9d(%rip)     # 0x4d150
je 0x1573d
movl $0x1, %ebp
leaq 0x37a8b(%rip), %r13     # 0x4d150
xorl %r12d, %r12d
xorl %r15d, %r15d
addq $0x38, %r13
movq -0x18(%r13), %rax
testq %rax, %rax
jne 0x156e5
cmpq $0x0, (%r13)
leaq 0x38(%r13), %r13
jne 0x156cf
jmp 0x1570f
leaq -0x38(%r13), %r14
movq %r14, %rdi
movl %ebx, %esi
callq *%rax
cmpl $0x0, -0x30(%r13)
jle 0x156fb
xorl %ebp, %ebp
jmp 0x15708
jne 0x15708
testq %r15, %r15
cmovnel %r12d, %ebp
cmoveq %r14, %r15
cmpq $0x0, (%r13)
jne 0x156cb
testl %ebp, %ebp
je 0x15772
testq %r15, %r15
je 0x1573d
cmpl $0x0, 0x3fd09(%rip)     # 0x55428
jne 0x1573d
movq 0x28(%r15), %rsi
movl $0x1, %edi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x11c09
cmpl $0x7f, %ebx
jg 0x15772
cmpq $0x0, 0x37a06(%rip)     # 0x4d150
je 0x15772
leaq 0x37a05(%rip), %rcx     # 0x4d158
movabsq $0x8000000000, %rax     # imm = 0x8000000000
movq %rax, (%rcx)
movl $0x0, 0x8(%rcx)
cmpq $0x0, 0x30(%rcx)
leaq 0x38(%rcx), %rcx
jne 0x1575d
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/nurse[P]nkf/nkf.c
// Function: w_iconv_combine
static nkf_char
w_iconv_combine(nkf_char c1, nkf_char c2, nkf_char c3, nkf_char c4, nkf_char c5, nkf_char c6)
{
    nkf_char wc, wc2;
    wc = nkf_utf8_to_unicode(c1, c2, c3, 0);
    wc2 = nkf_utf8_to_unicode(c4, c5, c6, 0);
    if (wc2 < 0)
	return wc2;
    return unicode_iconv_combine(wc, wc2);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %edx, %ebx
movl %esi, %ebp
movl %edi, %r15d
movl %ecx, %edi
movl %r8d, %esi
movl %r9d, %edx
xorl %ecx, %ecx
callq 0x112e4
movl %eax, %r14d
testl %eax, %eax
js 0x15dd2
movl %r15d, %edi
movl %ebp, %esi
movl %ebx, %edx
xorl %ecx, %ecx
callq 0x112e4
movl %eax, %edi
movl %r14d, %esi
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x15f04
movl %r14d, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/nurse[P]nkf/nkf.c
// Function: w_iconv_nocombine
static nkf_char
w_iconv_nocombine(nkf_char c1, nkf_char c2, nkf_char c3)
{
    /* continue from the line below 'return -3;' in w_iconv() */
    nkf_char ret = w2e_conv(c1, c2, c3, &c1, &c2);
    if (ret == 0){
	(*oconv)(c1, c2);
    }
    return ret;
}

// Assembly:
pushq %rax
leaq 0x4(%rsp), %rcx
movl %edi, (%rcx)
movq %rsp, %r8
movl %esi, (%r8)
callq 0x11357
testl %eax, %eax
jne 0x15e04
movl 0x4(%rsp), %edi
movl (%rsp), %esi
callq *0x374b4(%rip)          # 0x4d2b8
popq %rax
retq
// File: /workspace/github_c_makefile_star2_O3/nurse[P]nkf/nkf.c
// Function: utf32_to_nkf_char
static nkf_char
utf32_to_nkf_char(nkf_char c1, nkf_char c2, nkf_char c3, nkf_char c4)
{
    nkf_char wc;

    switch(input_endian){
    case ENDIAN_BIG:
	wc = c2 << 16 | c3 << 8 | c4;
	break;
    case ENDIAN_LITTLE:
	wc = c3 << 16 | c2 << 8 | c1;
	break;
    case ENDIAN_2143:
	wc = c1 << 16 | c4 << 8 | c3;
	break;
    case ENDIAN_3412:
	wc = c4 << 16 | c1 << 8 | c2;
	break;
    default:
	return NKF_ICONV_INVALID_CODE_RANGE;
    }
    return wc;
}

// Assembly:
movl %edx, %eax
movl 0x374d6(%rip), %edx     # 0x4d2e4
decl %edx
leaq 0x1509(%rip), %r8       # 0x17320
movslq (%r8,%rdx,4), %rdx
addq %r8, %rdx
jmpq *%rdx
shll $0x10, %esi
shll $0x8, %eax
orl %esi, %eax
jmp 0x15e32
shll $0x10, %edi
shll $0x8, %ecx
orl %edi, %ecx
orl %ecx, %eax
retq
shll $0x10, %ecx
shll $0x8, %edi
orl %ecx, %edi
orl %esi, %edi
movl %edi, %eax
retq
shll $0x10, %eax
shll $0x8, %esi
orl %eax, %esi
orl %edi, %esi
movl %esi, %eax
retq
// File: /workspace/github_c_makefile_star2_O3/nurse[P]nkf/nkf.c
// Function: unicode_iconv
static size_t
unicode_iconv(nkf_char wc, int nocombine)
{
    nkf_char c1, c2;
    int ret = 0;

    if (wc < 0x80) {
	c2 = 0;
	c1 = wc;
    }else if ((wc>>11) == 27) {
	/* unpaired surrogate */
	return NKF_ICONV_INVALID_CODE_RANGE;
    }else if (wc < 0xFFFF) {
	if (!nocombine && x0213_f && x0213_wait_combining_p(wc))
	    return NKF_ICONV_WAIT_COMBINING_CHAR;
	ret = w16e_conv(wc, &c2, &c1);
	if (ret) return ret;
    }else if (wc < 0x10FFFF) {
	c2 = 0;
	c1 = nkf_char_unicode_new(wc);
    } else {
	return NKF_ICONV_INVALID_CODE_RANGE;
    }
    (*oconv)(c2, c1);
    return 0;
}

// Assembly:
pushq %rax
movl %edi, %ecx
cmpl $0x7f, %edi
jg 0x15e70
movl $0x0, (%rsp)
movl %ecx, 0x4(%rsp)
xorl %edi, %edi
movl %ecx, %esi
callq *0x3744c(%rip)          # 0x4d2b8
xorl %eax, %eax
jmp 0x15e87
movl %ecx, %edx
andl $0x7ffff800, %edx       # imm = 0x7FFFF800
movq $-0xd, %rax
cmpl $0xd800, %edx           # imm = 0xD800
jne 0x15e89
popq %rcx
retq
cmpl $0xfffe, %ecx           # imm = 0xFFFE
ja 0x15ed5
testl %esi, %esi
jne 0x15ebe
testb $0x1, 0x37520(%rip)     # 0x4d3bc
je 0x15ebe
movl $0x2, %eax
leaq 0xc0c6(%rip), %rdx      # 0x21f70
movzwl (%rdx,%rax), %esi
cmpl %ecx, %esi
je 0x15efb
addq $0x6, %rax
cmpq $0x98, %rax
jne 0x15eaa
movq %rsp, %rsi
leaq 0x4(%rsp), %rdx
movl %ecx, %edi
callq 0x1191d
testl %eax, %eax
je 0x15eef
cltq
jmp 0x15e87
cmpl $0x10fffe, %ecx         # imm = 0x10FFFE
ja 0x15e87
movl $0x0, (%rsp)
orl $0x1000000, %ecx        # imm = 0x1000000
jmp 0x15e5e
movl (%rsp), %edi
movl 0x4(%rsp), %ecx
jmp 0x15e64
movq $-0xe, %rax
jmp 0x15e87
// File: /workspace/github_c_makefile_star2_O3/nurse[P]nkf/nkf.c
// Function: unicode_iconv_combine
static nkf_char
unicode_iconv_combine(nkf_char wc, nkf_char wc2)
{
    nkf_char c1, c2;
    int i;

    if (wc2 < 0x80) {
	return NKF_ICONV_NOT_COMBINED;
    }else if ((wc2>>11) == 27) {
	/* unpaired surrogate */
	return NKF_ICONV_INVALID_CODE_RANGE;
    }else if (wc2 < 0xFFFF) {
	if (!x0213_combining_p(wc2))
	    return NKF_ICONV_NOT_COMBINED;
	for (i = 0; i < sizeof_x0213_combining_table; i++) {
	    if (x0213_combining_table[i][1] == wc &&
		x0213_combining_table[i][2] == wc2) {
		c2 = x0213_combining_table[i][0] >> 8;
		c1 = x0213_combining_table[i][0] & 0x7f;
		(*oconv)(c2, c1);
		return 0;
	    }
	}
    }else if (wc2 < 0x10FFFF) {
	return NKF_ICONV_NOT_COMBINED;
    } else {
	return NKF_ICONV_INVALID_CODE_RANGE;
    }
    return NKF_ICONV_NOT_COMBINED;
}

// Assembly:
cmpl $0x80, %esi
jge 0x15f12
movl $0xfffffff1, %eax       # imm = 0xFFFFFFF1
retq
movl %esi, %ecx
andl $0x7ffff800, %ecx       # imm = 0x7FFFF800
movl $0xfffffff3, %eax       # imm = 0xFFFFFFF3
cmpl $0xd800, %ecx           # imm = 0xD800
je 0x15f5c
cmpl $0xfffe, %esi           # imm = 0xFFFE
ja 0x15f4c
pushq %rax
xorl %eax, %eax
leaq 0xc023(%rip), %rcx      # 0x21f5c
movzwl (%rcx,%rax,2), %edx
cmpl %esi, %edx
je 0x15f5d
incq %rax
cmpq $0x5, %rax
jne 0x15f39
jmp 0x15f86
xorl %eax, %eax
cmpl $0x10ffff, %esi         # imm = 0x10FFFF
setae %al
addl %eax, %eax
orl $-0xf, %eax
retq
movl $0x4, %eax
leaq 0xc007(%rip), %rcx      # 0x21f70
movzwl -0x2(%rcx,%rax), %edx
cmpl %edi, %edx
jne 0x15f7a
movzwl (%rcx,%rax), %edx
cmpl %esi, %edx
je 0x15f90
addq $0x6, %rax
cmpq $0x9a, %rax
jne 0x15f69
movl $0xfffffff1, %eax       # imm = 0xFFFFFFF1
addq $0x8, %rsp
retq
movzwl -0x4(%rcx,%rax), %esi
movl %esi, %edi
shrl $0x8, %edi
andl $0x7f, %esi
callq *0x37315(%rip)          # 0x4d2b8
xorl %eax, %eax
jmp 0x15f8b
// File: /workspace/github_c_makefile_star2_O3/nurse[P]nkf/nkf.c
// Function: mime_getc_buf
static nkf_char
mime_getc_buf(FILE *f)
{
    /* we don't keep eof of mime_input_buf, because it contains ?= as
       a terminator. It was checked in mime_integrity. */
    return ((mimebuf_f)?
	    (*i_mgetc_buf)(f):mime_input_buf(mime_input_state.input++));
}

// Assembly:
cmpl $0x0, 0x3f5d6(%rip)     # 0x55584
je 0x15fb6
jmpq *0x373aa(%rip)          # 0x4d360
movl 0x3fa54(%rip), %eax     # 0x55a10
leaq 0x3f645(%rip), %rcx     # 0x55608
leal 0x1(%rax), %edx
movl %edx, 0x3fa44(%rip)     # 0x55a10
andl $0x3ff, %eax            # imm = 0x3FF
movzbl (%rax,%rcx), %eax
retq
// File: /workspace/github_c_makefile_star2_O3/nurse[P]nkf/nkf.c
// Function: mime_ungetc_buf
static nkf_char
mime_ungetc_buf(nkf_char c, FILE *f)
{
    if (mimebuf_f)
	(*i_mungetc_buf)(c,f);
    else
	mime_input_buf(--mime_input_state.input) = (unsigned char)c;
    return c;
}

// Assembly:
pushq %rbx
movl %edi, %ebx
cmpl $0x0, 0x3f5a4(%rip)     # 0x55584
je 0x15fec
movl %ebx, %edi
callq *0x3737e(%rip)          # 0x4d368
jmp 0x1600a
leaq 0x3f615(%rip), %rax     # 0x55608
movl 0x3fa17(%rip), %ecx     # 0x55a10
decl %ecx
movl %ecx, 0x3fa0f(%rip)     # 0x55a10
andl $0x3ff, %ecx            # imm = 0x3FF
movb %bl, (%rcx,%rax)
movl %ebx, %eax
popq %rbx
retq
nop
// File: /workspace/github_c_makefile_star2_O3/LenShustek[P]miditones/miditones_scroll.c
// Function: HandleOptions
int HandleOptions (int argc, char *argv[]) {
   /* returns the index of the first argument that is not an option; i.e.
      does not start with a dash or a slash */

   int i, firstnonoption = 0;

   /* --- The following skeleton comes from C:\lcc\lib\wizard\textmode.tpl. */
   for (i = 1; i < argc; i++) {
      if (argv[i][0] == '/' || argv[i][0] == '-') {
         switch (toupper (argv[i][1])) {
         case 'H':
         case '?':
            SayUsage (argv[0]);
            exit (1);
         case 'C':
            codeoutput = true;
            break;
         case 'X':
            showhex = true;
            break;
         case 'N':
            showbytestream = false;
            break;
         case 'T':
            if (sscanf (&argv[i][2], "%d", &num_tonegens) != 1 || num_tonegens < 1
                  || num_tonegens > MAX_TONEGENS)
               goto opterror;
            break;
         case 'V':
            expect_volume = true;
            if (argv[i][2] == '\0')
               break;
            if (toupper (argv[i][2]) == 'I')
               ignore_volume = true;
            else
               goto opterror;
            break;

            /* add more  option switches here */
opterror:
         default:
            fprintf (stderr, "unknown option: %s\n", argv[i]);
            SayUsage (argv[0]);
            exit (4); } }
      else {
         firstnonoption = i;
         break; } }
   return firstnonoption; }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
cmpl $0x2, %edi
jl 0x2436
movq %rsi, %r14
movl %edi, %ebp
movl $0x1, %ebx
leaq 0x1e19(%rip), %r15      # 0x418a
leaq 0x4d38(%rip), %r12      # 0x70b0
movq (%r14,%rbx,8), %r13
movzbl (%r13), %eax
orl $0x2, %eax
cmpl $0x2f, %eax
jne 0x2438
callq 0x2030
movq (%rax), %rcx
movsbq 0x1(%r13), %rax
movl (%rcx,%rax,4), %eax
cmpl $0x53, %eax
jle 0x23be
cmpl $0x54, %eax
je 0x23e3
cmpl $0x56, %eax
je 0x240c
cmpl $0x58, %eax
jne 0x245e
movb $0x1, 0x4d37(%rip)      # 0x70f3
jmp 0x242a
cmpl $0x47, %eax
jg 0x23d5
cmpl $0x43, %eax
jne 0x2450
movb $0x1, 0x4d1d(%rip)      # 0x70f0
jmp 0x242a
cmpl $0x4e, %eax
jne 0x2449
movb $0x0, 0x4cd3(%rip)      # 0x70b4
jmp 0x242a
addq $0x2, %r13
movq %r13, %rdi
movq %r15, %rsi
movq %r12, %rdx
xorl %eax, %eax
callq 0x20f0
cmpl $0x1, %eax
jne 0x245a
movl 0x4cae(%rip), %eax      # 0x70b0
addl $-0x11, %eax
cmpl $-0x11, %eax
ja 0x242a
jmp 0x245a
movb $0x1, 0x4cde(%rip)      # 0x70f1
movsbq 0x2(%r13), %rax
testq %rax, %rax
je 0x242a
cmpl $0x49, (%rcx,%rax,4)
jne 0x245e
movb $0x1, 0x4cc8(%rip)      # 0x70f2
incq %rbx
cmpq %rbx, %rbp
jne 0x2378
xorl %ebx, %ebx
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
cmpl $0x48, %eax
je 0x2455
jmp 0x245e
cmpl $0x3f, %eax
jne 0x245e
callq 0x219e
movq (%r14,%rbx,8), %r13
movq %r13, %rdi
callq 0x21ac
// File: /workspace/github_c_makefile_star2_O3/LenShustek[P]miditones/miditones_scroll.c
// Function: strlcpy
unsigned int strlcpy (char *dst, const char *src, unsigned int siz) {
   char *d = dst;
   const char *s = src;
   unsigned int n = siz;
   if (n != 0) {  /* Copy as many bytes as will fit */
      while (--n != 0) {
         if ((*d++ = *s++) == '\0')
            break; } }
   /* Not enough room in dst, add NUL and traverse rest of src */
   if (n == 0) {
      if (siz != 0)
         *d = '\0';             /* NUL-terminate dst */
      while (*s++); }
   return (s - src - 1);        /* count does not include NUL */
}

// Assembly:
movq %rsi, %rcx
testl %edx, %edx
je 0x24a2
decl %edx
xorl %ecx, %ecx
cmpl %ecx, %edx
je 0x249b
movb (%rsi,%rcx), %al
movb %al, (%rdi,%rcx)
incq %rcx
testb %al, %al
jne 0x2482
addq %rsi, %rcx
movq %rcx, %rax
jmp 0x24ae
movb $0x0, (%rdi,%rcx)
addq %rsi, %rcx
leaq 0x1(%rcx), %rax
cmpb $0x0, (%rcx)
movq %rax, %rcx
jne 0x24a2
notl %esi
addl %esi, %eax
retq
// File: /workspace/github_c_makefile_star2_O3/LenShustek[P]miditones/miditones_scroll.c
// Function: strlcat
unsigned int strlcat (char *dst, const char *src, unsigned int siz) {
   char *d = dst;
   const char *s = src;
   unsigned int n = siz;
   unsigned int dlen;
   /* Find the end of dst and adjust bytes left but don't go past end */
   while (n-- != 0 && *d != '\0') d++;
   dlen = d - dst;
   n = siz - dlen;
   if (n == 0) return (dlen + strlength (s));
   while (*s != '\0') {
      if (n != 1) {
         *d++ = *s;
         n--; }
      s++; }
   *d = '\0';
   return (dlen + (s - src));   /* count does not include NUL */
}

// Assembly:
movq %rdi, %rax
movq %rdi, %rcx
testl %edx, %edx
je 0x24d8
movl %edx, %edi
addq %rax, %rdi
movl %edx, %r8d
movq %rax, %rcx
cmpb $0x0, (%rcx)
je 0x24d8
incq %rcx
decl %r8d
jne 0x24c8
movq %rdi, %rcx
movq %rcx, %rdi
subq %rax, %rdi
subl %edi, %edx
je 0x2519
movb (%rsi), %r8b
movq %rsi, %rax
testb %r8b, %r8b
je 0x2511
movl $0x1, %r9d
cmpl $0x1, %edx
jne 0x24fd
movl %r9d, %edx
jmp 0x2505
movb %r8b, (%rcx)
incq %rcx
decl %edx
movb 0x1(%rax), %r8b
incq %rax
testb %r8b, %r8b
jne 0x24f3
movb $0x0, (%rcx)
subl %esi, %edi
addl %edi, %eax
retq
notl %eax
addl %ecx, %eax
incl %eax
cmpb $0x0, (%rsi)
leaq 0x1(%rsi), %rsi
jne 0x251d
retq
// File: /workspace/github_c_makefile_star2_O3/LenShustek[P]miditones/miditones_scroll.c
// Function: file_error
void file_error (char *msg, unsigned char *bufptr) {
   unsigned char *ptr;
   fprintf (outfile, "\n---> file format error at position %04X (%d), time %d.%03d: %s\n",
            (unsigned int) (bufptr - buffer), (unsigned int) (bufptr - buffer), timenow / 1000, timenow % 1000, msg);
   /* print some bytes surrounding the error */
   ptr = bufptr - 16;
   if (ptr < buffer) ptr = buffer;
   for (; ptr <= bufptr + 16 && ptr < buffer + buflen; ++ptr)
      fprintf (outfile, ptr == bufptr ? " [%02X]  " : "%02X ", *ptr);
   fprintf (outfile, "\n"); }

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x10, %rsp
movq %rsi, %rbx
movq 0x4dc0(%rip), %r10      # 0x7300
movl 0x4dc2(%rip), %eax      # 0x7308
movl %ebx, %ecx
subl %eax, %ecx
movq 0x4b97(%rip), %r9       # 0x70e8
movq %r9, %rax
shrq $0x3, %rax
movabsq $0x20c49ba5e353f7cf, %rdx # imm = 0x20C49BA5E353F7CF
mulq %rdx
movq %rdx, %r8
shrq $0x4, %r8
imulq $0x3e8, %r8, %rax       # imm = 0x3E8
subq %rax, %r9
movq %rdi, (%rsp)
leaq 0x1c20(%rip), %rsi      # 0x41a1
movq %r10, %rdi
movl %ecx, %edx
xorl %eax, %eax
callq 0x20b0
leaq -0x10(%rbx), %r14
movq 0x4d70(%rip), %rax      # 0x7308
cmpq %rax, %r14
cmovbq %rax, %r14
leaq 0x10(%rbx), %r15
cmpq %r15, %r14
ja 0x25f9
addq 0x4d61(%rip), %rax      # 0x7310
cmpq %rax, %r14
jae 0x25f9
leaq 0x1c27(%rip), %r12      # 0x41e2
leaq 0x1c4a(%rip), %r13      # 0x420c
movq 0x4d37(%rip), %rdi      # 0x7300
cmpq %rbx, %r14
movq %r13, %rsi
cmoveq %r12, %rsi
movzbl (%r14), %edx
xorl %eax, %eax
callq 0x20b0
incq %r14
cmpq %r15, %r14
ja 0x25f9
movq 0x4d1b(%rip), %rax      # 0x7308
addq 0x4d1c(%rip), %rax      # 0x7310
cmpq %rax, %r14
jb 0x25c2
movq 0x4d00(%rip), %rsi      # 0x7300
movl $0xa, %edi
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
jmp 0x20a0
// File: /workspace/github_c_makefile_star2_O3/LenShustek[P]miditones/miditones_scroll.c
// Function: countbits
int countbits (unsigned int bitmap) {
   int count;
   for (count = 0; bitmap; bitmap >>= 1)
      count += bitmap & 1;
   return count; }

// Assembly:
xorl %eax, %eax
testl %edi, %edi
je 0x29c4
movl %edi, %ecx
movl %edi, %edx
andl $0x1, %edx
addl %edx, %eax
shrl %ecx
cmpl $0x1, %edi
movl %ecx, %edi
ja 0x29b4
retq
// File: /workspace/github_c_makefile_star2_O3/srned[P]baselib/adlist.c
// Function: listRotate
void listRotate(list *list) {
    listNode *tail = list->tail;

    if (listLength(list) <= 1) return;

    /* Detatch current tail */
    list->tail = tail->prev;
    list->tail->next = NULL;
    /* Move it as head */
    list->head->prev = tail;
    tail->prev = NULL;
    tail->next = list->head;
    list->head = tail;
}

// Assembly:
cmpq $0x2, 0x28(%rdi)
jb 0x4d3f
movq 0x8(%rdi), %rax
movq (%rax), %rcx
movq %rcx, 0x8(%rdi)
xorl %edx, %edx
movq %rdx, 0x8(%rcx)
movq (%rdi), %rcx
movq %rax, (%rcx)
movq %rdx, (%rax)
movq %rcx, 0x8(%rax)
movq %rax, (%rdi)
retq
// File: /workspace/github_c_makefile_star2_O3/srned[P]baselib/anet.c
// Function: anetResolve
int anetResolve(char *err, char *host, char *ipbuf)
{
    struct sockaddr_in sa;

    sa.sin_family = AF_INET;
    if (inet_aton(host, &sa.sin_addr) == 0) {
        struct hostent *he;

        he = gethostbyname(host);
        if (he == NULL) {
            anetSetError(err, "can't resolve: %s", host);
            return ANET_ERR;
        }
        memcpy(&sa.sin_addr, he->h_addr, sizeof(struct in_addr));
    }
    strcpy(ipbuf,inet_ntoa(sa.sin_addr));
    return ANET_OK;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rdx, %rbx
movq %rsi, %r14
movq %rdi, %r15
leaq 0x4(%rsp), %rsi
movw $0x2, -0x4(%rsi)
movq %r14, %rdi
callq 0x4250
testl %eax, %eax
je 0x58ff
movl 0x4(%rsp), %edi
jmp 0x5919
movq %r14, %rdi
callq 0x4210
testq %rax, %rax
je 0x5935
movq 0x18(%rax), %rax
movq (%rax), %rax
movl (%rax), %edi
movl %edi, 0x4(%rsp)
callq 0x4110
movq %rbx, %rdi
movq %rax, %rsi
callq 0x40a0
xorl %eax, %eax
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
leaq 0x679b(%rip), %rsi      # 0xc0d7
movq %r15, %rdi
movq %r14, %rdx
xorl %eax, %eax
callq 0x5722
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
jmp 0x592b
// File: /workspace/github_c_makefile_star2_O3/srned[P]baselib/anet.c
// Function: anetTcpGenericConnect
static int anetTcpGenericConnect(char *err, char *addr, int port, int flags)
{
    int s;
    struct sockaddr_in sa;

    if ((s = anetCreateSocket(err,AF_INET)) == ANET_ERR)
        return ANET_ERR;

    sa.sin_family = AF_INET;
    sa.sin_port = htons(port);
    if (inet_aton(addr, &sa.sin_addr) == 0) {
        struct hostent *he;

        he = gethostbyname(addr);
        if (he == NULL) {
            anetSetError(err, "can't resolve: %s", addr);
            close(s);
            return ANET_ERR;
        }
        memcpy(&sa.sin_addr, he->h_addr, sizeof(struct in_addr));
    }
    if (flags & ANET_CONNECT_NONBLOCK) {
        if (anetNonBlock(err,s) != ANET_OK)
            return ANET_ERR;
    }
    if (connect(s, (struct sockaddr*)&sa, sizeof(sa)) == -1) {
        if (errno == EINPROGRESS &&
            flags & ANET_CONNECT_NONBLOCK)
            return s;

        anetSetError(err, "connect: %s", strerror(errno));
        close(s);
        return ANET_ERR;
    }
    return s;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movl %ecx, %r15d
movl %edx, %r13d
movq %rsi, %r12
movq %rdi, %r14
movl $0x2, %esi
callq 0x5aff
movl $0xffffffff, %ebx       # imm = 0xFFFFFFFF
cmpl $-0x1, %eax
je 0x5a32
movl %eax, %ebp
leaq 0xc(%rsp), %rsi
movw $0x2, -0x4(%rsi)
rolw $0x8, %r13w
movw %r13w, -0x2(%rsi)
movq %r12, %rdi
callq 0x4250
testl %eax, %eax
jne 0x59c3
movq %r12, %rdi
callq 0x4210
testq %rax, %rax
je 0x5a17
movq 0x18(%rax), %rax
movq (%rax), %rax
movl (%rax), %eax
movl %eax, 0xc(%rsp)
testb $0x1, %r15b
je 0x59d7
movq %r14, %rdi
movl %ebp, %esi
callq 0x56b0
testl %eax, %eax
jne 0x5a32
leaq 0x8(%rsp), %rsi
movl %ebp, %edi
movl $0x10, %edx
callq 0x4390
cmpl $-0x1, %eax
jne 0x5a13
callq 0x4080
movl (%rax), %edi
cmpl $0x73, %edi
sete %al
testb %al, %r15b
jne 0x5a13
callq 0x43b0
leaq 0x66de(%rip), %rsi      # 0xc0e9
movq %r14, %rdi
movq %rax, %rdx
jmp 0x5a24
movl %ebp, %ebx
jmp 0x5a32
leaq 0x66b9(%rip), %rsi      # 0xc0d7
movq %r14, %rdi
movq %r12, %rdx
xorl %eax, %eax
callq 0x5722
movl %ebp, %edi
callq 0x41b0
movl %ebx, %eax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/srned[P]baselib/anet.c
// Function: anetCreateSocket
static int anetCreateSocket(char *err, int domain) {
    int s, on = 1;
    if ((s = socket(domain, SOCK_STREAM, 0)) == -1) {
        anetSetError(err, "creating socket: %s", strerror(errno));
        return ANET_ERR;
    }

    /* Make sure connection-intensive things like the redis benckmark
     * will be able to close/open sockets a zillion of times */
    if (setsockopt(s, SOL_SOCKET, SO_REUSEADDR, &on, sizeof(on)) == -1) {
        anetSetError(err, "setsockopt SO_REUSEADDR: %s", strerror(errno));
        return ANET_ERR;
    }
    return s;
}

// Assembly:
pushq %rbp
pushq %rbx
pushq %rax
movq %rdi, %rbx
movl $0x1, 0x4(%rsp)
movl %esi, %edi
movl $0x1, %esi
xorl %edx, %edx
callq 0x43f0
cmpl $-0x1, %eax
je 0x5b58
movl %eax, %ebp
leaq 0x4(%rsp), %rcx
movl %eax, %edi
movl $0x1, %esi
movl $0x2, %edx
movl $0x4, %r8d
callq 0x40e0
cmpl $-0x1, %eax
jne 0x5b7d
callq 0x4080
movl (%rax), %edi
callq 0x43b0
leaq 0x65c8(%rip), %rsi      # 0xc11e
jmp 0x5b6b
callq 0x4080
movl (%rax), %edi
callq 0x43b0
leaq 0x659f(%rip), %rsi      # 0xc10a
movq %rbx, %rdi
movq %rax, %rdx
xorl %eax, %eax
callq 0x5722
movl $0xffffffff, %ebp       # imm = 0xFFFFFFFF
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/srned[P]baselib/anet.c
// Function: anetTcpServer
int anetTcpServer(char *err, int port, char *bindaddr)
{
    int s;
    struct sockaddr_in sa;

    if ((s = anetCreateSocket(err,AF_INET)) == ANET_ERR)
        return ANET_ERR;

    memset(&sa,0,sizeof(sa));
    sa.sin_family = AF_INET;
    sa.sin_port = htons(port);
    sa.sin_addr.s_addr = htonl(INADDR_ANY);
    if (bindaddr && inet_aton(bindaddr, &sa.sin_addr) == 0) {
        anetSetError(err, "invalid bind address");
        close(s);
        return ANET_ERR;
    }
    if (anetListen(err,s,(struct sockaddr*)&sa,sizeof(sa)) == ANET_ERR)
        return ANET_ERR;
    return s;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x10, %rsp
movq %rdx, %r15
movl %esi, %r12d
movq %rdi, %r14
movl $0x2, %esi
callq 0x5aff
movl $0xffffffff, %ebp       # imm = 0xFFFFFFFF
cmpl $-0x1, %eax
je 0x5cd2
movl %eax, %ebx
movq $0x0, 0x8(%rsp)
rolw $0x8, %r12w
movw $0x2, (%rsp)
movw %r12w, 0x2(%rsp)
movl $0x0, 0x4(%rsp)
testq %r15, %r15
je 0x5c9e
leaq 0x4(%rsp), %rsi
movq %r15, %rdi
callq 0x4250
testl %eax, %eax
je 0x5cba
movq %rsp, %rdx
movq %r14, %rdi
movl %ebx, %esi
movl $0x10, %ecx
callq 0x5ce1
cmpl $-0x1, %eax
cmovel %eax, %ebx
movl %ebx, %ebp
jmp 0x5cd2
leaq 0x6434(%rip), %rsi      # 0xc0f5
movq %r14, %rdi
xorl %eax, %eax
callq 0x5722
movl %ebx, %edi
callq 0x41b0
movl %ebp, %eax
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/srned[P]baselib/anet.c
// Function: anetTcpAccept
int anetTcpAccept(char *err, int s, char *ip, int *port) {
    int fd;
    struct sockaddr_in sa;
    socklen_t salen = sizeof(sa);
    if ((fd = anetGenericAccept(err,s,(struct sockaddr*)&sa,&salen)) == ANET_ERR)
        return ANET_ERR;

    if (ip) strcpy(ip,inet_ntoa(sa.sin_addr));
    if (port) *port = ntohs(sa.sin_port);
    return fd;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
subq $0x20, %rsp
movq %rcx, %rbx
movq %rdx, %r14
leaq 0xc(%rsp), %rcx
movl $0x10, (%rcx)
leaq 0x10(%rsp), %rdx
callq 0x5e3c
movl %eax, %ebp
cmpl $-0x1, %eax
je 0x5e31
testq %r14, %r14
je 0x5e1e
movl 0x14(%rsp), %edi
callq 0x4110
movq %r14, %rdi
movq %rax, %rsi
callq 0x40a0
testq %rbx, %rbx
je 0x5e31
movzwl 0x12(%rsp), %eax
rolw $0x8, %ax
movzwl %ax, %eax
movl %eax, (%rbx)
movl %ebp, %eax
addq $0x20, %rsp
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/srned[P]baselib/anet.c
// Function: anetPeerToString
int anetPeerToString(int fd, char *ip, int *port) {
    struct sockaddr_in sa;
    socklen_t salen = sizeof(sa);

    if (getpeername(fd,(struct sockaddr*)&sa,&salen) == -1) {
        *port = 0;
        ip[0] = '?';
        ip[1] = '\0';
        return -1;
    }
    if (ip) strcpy(ip,inet_ntoa(sa.sin_addr));
    if (port) *port = ntohs(sa.sin_port);
    return 0;
}

// Assembly:
pushq %r14
pushq %rbx
subq $0x18, %rsp
movq %rdx, %rbx
movq %rsi, %r14
leaq 0x4(%rsp), %rdx
movl $0x10, (%rdx)
leaq 0x8(%rsp), %rsi
callq 0x4120
cmpl $-0x1, %eax
je 0x5f08
testq %r14, %r14
je 0x5ef1
movl 0xc(%rsp), %edi
callq 0x4110
movq %r14, %rdi
movq %rax, %rsi
callq 0x40a0
xorl %eax, %eax
testq %rbx, %rbx
je 0x5f19
movzwl 0xa(%rsp), %ecx
rolw $0x8, %cx
movzwl %cx, %ecx
movl %ecx, (%rbx)
jmp 0x5f19
movl $0x0, (%rbx)
movw $0x3f, (%r14)
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
addq $0x18, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O3/srned[P]baselib/anet.c
// Function: anetSockName
int anetSockName(int fd, char *ip, int *port) {
    struct sockaddr_in sa;
    socklen_t salen = sizeof(sa);

    if (getsockname(fd,(struct sockaddr*)&sa,&salen) == -1) {
        *port = 0;
        ip[0] = '?';
        ip[1] = '\0';
        return -1;
    }
    if (ip) strcpy(ip,inet_ntoa(sa.sin_addr));
    if (port) *port = ntohs(sa.sin_port);
    return 0;
}

// Assembly:
pushq %r14
pushq %rbx
subq $0x18, %rsp
movq %rdx, %rbx
movq %rsi, %r14
leaq 0x4(%rsp), %rdx
movl $0x10, (%rdx)
leaq 0x8(%rsp), %rsi
callq 0x4370
cmpl $-0x1, %eax
je 0x5f78
testq %r14, %r14
je 0x5f61
movl 0xc(%rsp), %edi
callq 0x4110
movq %r14, %rdi
movq %rax, %rsi
callq 0x40a0
xorl %eax, %eax
testq %rbx, %rbx
je 0x5f89
movzwl 0xa(%rsp), %ecx
rolw $0x8, %cx
movzwl %cx, %ecx
movl %ecx, (%rbx)
jmp 0x5f89
movl $0x0, (%rbx)
movw $0x3f, (%r14)
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
addq $0x18, %rsp
popq %rbx
popq %r14
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O3/srned[P]baselib/dict.c
// Function: dictGenHashFunction
unsigned int dictGenHashFunction(const unsigned char *buf, int len) {
    unsigned int hash = dict_hash_function_seed;

    while (len--)
        hash = ((hash << 5) + hash) + (*buf++); /* hash * 33 + c */
    return hash;
}

// Assembly:
movl 0xb20a(%rip), %eax      # 0x11210
testl %esi, %esi
je 0x6022
movl %esi, %ecx
xorl %edx, %edx
movl %eax, %esi
shll $0x5, %esi
addl %eax, %esi
movzbl (%rdi,%rdx), %eax
addl %esi, %eax
incq %rdx
cmpl %edx, %ecx
jne 0x600e
retq
// File: /workspace/github_c_makefile_star2_O3/srned[P]baselib/dict.c
// Function: dictGenCaseHashFunction
unsigned int dictGenCaseHashFunction(const unsigned char *buf, int len) {
    unsigned int hash = dict_hash_function_seed;

    while (len--)
        hash = ((hash << 5) + hash) + (tolower(*buf++)); /* hash * 33 + c */
    return hash;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movl 0xb1e2(%rip), %r14d     # 0x11210
testl %esi, %esi
je 0x605f
movl %esi, %ebp
movq %rdi, %rbx
callq 0x43d0
movq (%rax), %rcx
movl %ebp, %edx
xorl %esi, %esi
movl %r14d, %eax
shll $0x5, %eax
addl %r14d, %eax
movzbl (%rbx,%rsi), %edi
addl (%rcx,%rdi,4), %eax
incq %rsi
movl %eax, %r14d
cmpl %esi, %edx
jne 0x6046
jmp 0x6062
movl %r14d, %eax
popq %rbx
popq %r14
popq %rbp
retq