LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O1/vincenthsu[P]nweb/nweb23.c
// Function: logger
void logger(int type, char *s1, char *s2, int socket_fd)
{
	int fd ;
	char logbuffer[BUFSIZE*2];

	switch (type) {
	case ERROR: (void)sprintf(logbuffer,"ERROR: %s:%s Errno=%d exiting pid=%d",s1, s2, errno,getpid()); 
		break;
	case FORBIDDEN: 
		(void)write(socket_fd, "HTTP/1.1 403 Forbidden\nContent-Length: 185\nConnection: close\nContent-Type: text/html\n\n<html><head>\n<title>403 Forbidden</title>\n</head><body>\n<h1>Forbidden</h1>\nThe requested URL, file type or operation is not allowed on this simple static file webserver.\n</body></html>\n",271);
		(void)sprintf(logbuffer,"FORBIDDEN: %s:%s",s1, s2); 
		break;
	case NOTFOUND: 
		(void)write(socket_fd, "HTTP/1.1 404 Not Found\nContent-Length: 136\nConnection: close\nContent-Type: text/html\n\n<html><head>\n<title>404 Not Found</title>\n</head><body>\n<h1>Not Found</h1>\nThe requested URL was not found on this server.\n</body></html>\n",224);
		(void)sprintf(logbuffer,"NOT FOUND: %s:%s",s1, s2); 
		break;
	case LOG: (void)sprintf(logbuffer," INFO: %s:%s:%d",s1, s2,socket_fd); break;
	}	
	/* No checks here, nothing can be done with a failure anyway */
	if((fd = open("nweb.log", O_CREAT| O_WRONLY | O_APPEND,0644)) >= 0) {
		(void)write(fd,logbuffer,strlen(logbuffer)); 
		(void)write(fd,"\n",1);      
		(void)close(fd);
	}
	if(type == ERROR || type == NOTFOUND || type == FORBIDDEN) exit(3);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x3f48, %rsp           # imm = 0x3F48
movl %ecx, %r8d
movq %rdx, %r14
movq %rsi, %r15
movl %edi, %ebx
cmpl $0x192, %edi            # imm = 0x192
jg 0x12f6
cmpl $0x2a, %ebx
je 0x1323
cmpl $0x2c, %ebx
jne 0x1379
leaq 0xfb9(%rip), %rsi       # 0x229a
movq %rsp, %rdi
movq %r15, %rdx
movq %r14, %rcx
xorl %eax, %eax
callq 0x1150
jmp 0x1379
cmpl $0x193, %ebx            # imm = 0x193
je 0x134e
cmpl $0x194, %ebx            # imm = 0x194
jne 0x1379
leaq 0xe9b(%rip), %rsi       # 0x21a8
movl $0xe0, %edx
movl %r8d, %edi
callq 0x1060
leaq 0xf68(%rip), %rsi       # 0x2289
jmp 0x1369
callq 0x1030
movl (%rax), %ebp
callq 0x1070
leaq 0xd2c(%rip), %rsi       # 0x2062
movq %rsp, %rdi
movq %r15, %rdx
movq %r14, %rcx
movl %ebp, %r8d
movl %eax, %r9d
xorl %eax, %eax
callq 0x1150
jmp 0x1379
leaq 0xd32(%rip), %rsi       # 0x2087
movl $0x10f, %edx            # imm = 0x10F
movl %r8d, %edi
callq 0x1060
leaq 0xe2e(%rip), %rsi       # 0x2197
movq %rsp, %rdi
movq %r15, %rdx
movq %r14, %rcx
xorl %eax, %eax
callq 0x1150
leaq 0xf2a(%rip), %rdi       # 0x22aa
movl $0x441, %esi            # imm = 0x441
movl $0x1a4, %edx            # imm = 0x1A4
xorl %eax, %eax
callq 0x1120
testl %eax, %eax
js 0x13c9
movl %eax, %ebp
movq %rsp, %r14
movq %r14, %rdi
callq 0x1080
movl %ebp, %edi
movq %r14, %rsi
movq %rax, %rdx
callq 0x1060
leaq 0x1013(%rip), %rsi      # 0x23c9
movl $0x1, %edx
movl %ebp, %edi
callq 0x1060
movl %ebp, %edi
callq 0x10c0
leal -0x193(%rbx), %eax
cmpl $0x2, %eax
jb 0x13e7
cmpl $0x2a, %ebx
je 0x13e7
addq $0x3f48, %rsp           # imm = 0x3F48
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movl $0x3, %edi
callq 0x1160
// File: /workspace/github_c_makefile_star2_O1/eric-lo[P]3150/3-ProcessUser/exec_example.c
// Function: main
int main(void) {
	int i = 10;
	printf("before execl...\n");

//	execl("/bin/xxx", "/bin/ls", "-l", "-a", NULL);
  execl("/bin/ls", "-l", "-a", NULL);
//    execl("/bin/ls", "/bin/ls", "*.c", NULL);

	printf("after execl...(%d)\n", i);

	return 0;
}

// Assembly:
pushq %rax
leaq 0xec2(%rip), %rdi       # 0x2026
callq 0x1030
leaq 0xe94(%rip), %rdi       # 0x2004
leaq 0xe95(%rip), %rsi       # 0x200c
leaq 0xe91(%rip), %rdx       # 0x200f
xorl %ecx, %ecx
xorl %eax, %eax
callq 0x1050
leaq 0xe84(%rip), %rdi       # 0x2012
movl $0xa, %esi
xorl %eax, %eax
callq 0x1040
xorl %eax, %eax
popq %rcx
retq
// File: /workspace/github_c_makefile_star2_O1/saulvargas[P]re-C-sys/test_ub.c
// Function: main
int main(int argc, char** argv) {
    FILE* user_data;
    FILE* item_data;
    int N_users;
    int N_items;
    int N_prefs;
    int binary;
    recdata_t* recdata;
    int uid;
    int i;
    similarity_t* similarity;
    recommender_t* recommender;
    idpairs_t* pairs;

    if (!read_args(argc, argv, &user_data, &item_data, &N_users, &N_items, &N_prefs, &binary)) {
        return EXIT_FAILURE;
    }

    recdata = recdata_simple_create(user_data, item_data, N_users, N_items, N_prefs, binary);
    
    fclose(user_data);
    fclose(item_data);

    if (!binary) {
        similarity = similarity_veccosine_create(recdata);
    } else {
        similarity = similarity_setcosine_create(recdata);
    }

    recommender = recommender_ub_create(recdata, similarity, 100, binary);

    for (uid = 0; uid < recdata->N_users; uid++) {
        pairs = recommender_recommend(recommender, uid, 100);

        for (i = 0; i < idpairs_size(pairs); i++) {
            printf("%d\t%d\t%.4f\n", uid, idpairs_keys(pairs)[i], idpairs_values(pairs)[i]);
        }
        
        idpairs_close_deep(pairs);
    }
 
    recommender_close(recommender);
 
    similarity_close(similarity);
    
    recdata_close(recdata);
    
    return EXIT_SUCCESS;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
leaq 0x8(%rsp), %rax
leaq 0xc(%rsp), %r10
leaq 0x28(%rsp), %rdx
leaq 0x20(%rsp), %rcx
leaq 0x14(%rsp), %r8
leaq 0x10(%rsp), %r9
pushq %rax
pushq %r10
callq 0x2638
addq $0x10, %rsp
testl %eax, %eax
je 0x1291
movq 0x28(%rsp), %rdi
movq 0x20(%rsp), %rsi
movl 0x14(%rsp), %edx
movl 0x10(%rsp), %ecx
movl 0xc(%rsp), %r8d
movl 0x8(%rsp), %r9d
callq 0x169e
movq %rax, %r15
movq 0x28(%rsp), %rdi
callq 0x1060
movq 0x20(%rsp), %rdi
callq 0x1060
cmpl $0x0, 0x8(%rsp)
je 0x129b
movq %r15, %rdi
callq 0x1958
jmp 0x12a3
movl $0x1, %eax
jmp 0x135d
movq %r15, %rdi
callq 0x1c11
movl 0x8(%rsp), %ecx
movq %r15, %rdi
movq %rax, 0x30(%rsp)
movq %rax, %rsi
movl $0x64, %edx
callq 0x2293
movq %rax, 0x18(%rsp)
cmpl $0x0, (%r15)
jle 0x133f
xorl %r12d, %r12d
leaq 0x1d33(%rip), %r13      # 0x3004
movq 0x18(%rsp), %rdi
movl %r12d, %esi
movl $0x64, %edx
callq 0x207c
movq %rax, %rbp
movq %rax, %rdi
callq 0x2555
testl %eax, %eax
jle 0x132f
xorl %ebx, %ebx
movq %rbp, %rdi
callq 0x2558
movl (%rax,%rbx,4), %r14d
movq %rbp, %rdi
callq 0x255d
movsd (%rax,%rbx,8), %xmm0
movq %r13, %rdi
movl %r12d, %esi
movl %r14d, %edx
movb $0x1, %al
callq 0x1080
incq %rbx
movq %rbp, %rdi
callq 0x2555
cltq
cmpq %rax, %rbx
jl 0x12f4
movq %rbp, %rdi
callq 0x2531
incl %r12d
cmpl (%r15), %r12d
jl 0x12d1
movq 0x18(%rsp), %rdi
callq 0x215e
movq 0x30(%rsp), %rdi
callq 0x17e4
movq %r15, %rdi
callq 0x13a4
xorl %eax, %eax
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/doy[P]libvt100/src/parser.c
// Function: vt100_parser_yy_create_buffer
YY_BUFFER_STATE yy_create_buffer  (FILE * file, int  size , yyscan_t yyscanner)
{
	YY_BUFFER_STATE b;
    
	b = (YY_BUFFER_STATE) yyalloc( sizeof( struct yy_buffer_state ) , yyscanner );
	if ( ! b )
		YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );

	b->yy_buf_size = size;

	/* yy_ch_buf has to be 2 characters longer than the size given because
	 * we need to put in 2 end-of-buffer characters.
	 */
	b->yy_ch_buf = (char *) yyalloc( (yy_size_t) (b->yy_buf_size + 2) , yyscanner );
	if ( ! b->yy_ch_buf )
		YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );

	b->yy_is_our_buffer = 1;

	yy_init_buffer( b, file , yyscanner);

	return b;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdx, %rbx
movl %esi, %ebp
movq %rdi, %r14
movl $0x40, %edi
callq 0x34f0
testq %rax, %rax
je 0x532b
movq %rax, %r15
movl %ebp, 0x18(%rax)
addl $0x2, %ebp
movslq %ebp, %rdi
callq 0x34f0
movq %rax, 0x8(%r15)
testq %rax, %rax
je 0x532b
movl $0x1, 0x20(%r15)
movq %r15, %rdi
movq %r14, %rsi
movq %rbx, %rdx
callq 0x566a
movq %r15, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
leaq 0x4280(%rip), %rdi      # 0x95b2
callq 0x54df
// File: /workspace/github_c_makefile_star2_O1/doy[P]libvt100/src/parser.c
// Function: yy_get_previous_state
static yy_state_type yy_get_previous_state (yyscan_t yyscanner)
{
	yy_state_type yy_current_state;
	char *yy_cp;
    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;

	yy_current_state = yyg->yy_start;

	for ( yy_cp = yyg->yytext_ptr + YY_MORE_ADJ; yy_cp < yyg->yy_c_buf_p; ++yy_cp )
		{
		YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1);
		if ( yy_accept[yy_current_state] )
			{
			yyg->yy_last_accepting_state = yy_current_state;
			yyg->yy_last_accepting_cpos = yy_cp;
			}
		while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
			{
			yy_current_state = (int) yy_def[yy_current_state];
			if ( yy_current_state >= 158 )
				yy_c = yy_meta[yy_c];
			}
		yy_current_state = yy_nxt[yy_base[yy_current_state] + yy_c];
		}

	return yy_current_state;
}

// Assembly:
movl 0x4c(%rdi), %eax
movq 0x80(%rdi), %rcx
movq 0x40(%rdi), %rdx
cmpq %rdx, %rcx
jae 0x55cd
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
leaq 0x2ec3(%rip), %rsi      # 0x83f0
leaq 0x360c(%rip), %r8       # 0x8b40
leaq 0x2ff5(%rip), %r9       # 0x8530
leaq 0x391e(%rip), %r10      # 0x8e60
leaq 0x3767(%rip), %r11      # 0x8cb0
leaq 0x38d0(%rip), %rbx      # 0x8e20
movzbl (%rcx), %r15d
testq %r15, %r15
je 0x5566
leaq 0x2d90(%rip), %r14      # 0x82f0
movb (%r15,%r14), %bpl
jmp 0x5569
movb $0x1, %bpl
movslq %eax, %r15
cmpw $0x0, (%rsi,%r15,2)
je 0x557b
movl %eax, 0x68(%rdi)
movq %rcx, 0x70(%rdi)
movswq (%r8,%r15,2), %r13
movzbl %bpl, %r12d
addq %r12, %r13
movswl (%r9,%r13,2), %r14d
cmpl %r14d, %eax
je 0x55b6
movswq (%r11,%r15,2), %r15
cmpq $0x9e, %r15
jl 0x55a3
movb (%r12,%rbx), %bpl
movswq (%r8,%r15,2), %r13
movzbl %bpl, %r12d
addq %r12, %r13
cmpw (%r9,%r13,2), %r15w
jne 0x5591
movswl (%r10,%r13,2), %eax
incq %rcx
cmpq %rdx, %rcx
jne 0x5550
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/doy[P]libvt100/src/parser.c
// Function: vt100_parser_yyrestart
void yyrestart  (FILE * input_file , yyscan_t yyscanner)
{
    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;

	if ( ! YY_CURRENT_BUFFER ){
        yyensure_buffer_stack (yyscanner);
		YY_CURRENT_BUFFER_LVALUE =
            yy_create_buffer( yyin, YY_BUF_SIZE , yyscanner);
	}

	yy_init_buffer( YY_CURRENT_BUFFER, input_file , yyscanner);
	yy_load_buffer_state( yyscanner );
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
movq 0x28(%rsi), %rax
testq %rax, %rax
je 0x55ec
movq 0x18(%rbx), %rcx
cmpq $0x0, (%rax,%rcx,8)
jne 0x5611
movq %rbx, %rdi
callq 0x523f
movq 0x8(%rbx), %rdi
movl $0x4000, %esi           # imm = 0x4000
movq %rbx, %rdx
callq 0x34d0
movq 0x18(%rbx), %rcx
movq 0x28(%rbx), %rdx
movq %rax, (%rdx,%rcx,8)
movq 0x28(%rbx), %rax
testq %rax, %rax
je 0x5624
movq 0x18(%rbx), %rcx
movq (%rax,%rcx,8), %rdi
jmp 0x5626
xorl %edi, %edi
movq %r14, %rsi
movq %rbx, %rdx
callq 0x566a
movq 0x18(%rbx), %rax
movq 0x28(%rbx), %rcx
movq (%rcx,%rax,8), %rdx
movl 0x1c(%rdx), %esi
movl %esi, 0x34(%rbx)
movq 0x10(%rdx), %rdx
movq %rdx, 0x40(%rbx)
movq %rdx, 0x80(%rbx)
movq (%rcx,%rax,8), %rax
movq (%rax), %rax
movq %rax, 0x8(%rbx)
movb (%rdx), %al
movb %al, 0x30(%rbx)
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O1/doy[P]libvt100/src/parser.c
// Function: vt100_parser_yy_switch_to_buffer
void yy_switch_to_buffer  (YY_BUFFER_STATE  new_buffer , yyscan_t yyscanner)
{
    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;

	/* TODO. We should be able to replace this entire function body
	 * with
	 *		yypop_buffer_state();
	 *		yypush_buffer_state(new_buffer);
     */
	yyensure_buffer_stack (yyscanner);
	if ( YY_CURRENT_BUFFER == new_buffer )
		return;

	if ( YY_CURRENT_BUFFER )
		{
		/* Flush out information for old buffer. */
		*yyg->yy_c_buf_p = yyg->yy_hold_char;
		YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = yyg->yy_c_buf_p;
		YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars;
		}

	YY_CURRENT_BUFFER_LVALUE = new_buffer;
	yy_load_buffer_state( yyscanner );

	/* We don't actually know whether we did this switch during
	 * EOF (yywrap()) processing, but the only time this flag
	 * is looked at is after yywrap() is called, so it's safe
	 * to go ahead and always set it.
	 */
	yyg->yy_did_buffer_switch_on_eof = 1;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
movq %rsi, %rdi
callq 0x523f
movq 0x28(%rbx), %rax
testq %rax, %rax
je 0x5711
movq 0x18(%rbx), %rcx
movq (%rax,%rcx,8), %rcx
jmp 0x5713
xorl %ecx, %ecx
cmpq %r14, %rcx
je 0x578f
testq %rax, %rax
je 0x574f
movq 0x18(%rbx), %rcx
cmpq $0x0, (%rax,%rcx,8)
je 0x574f
movb 0x30(%rbx), %al
movq 0x40(%rbx), %rcx
movb %al, (%rcx)
movq 0x40(%rbx), %rax
movq 0x18(%rbx), %rcx
movq 0x28(%rbx), %rdx
movq (%rdx,%rcx,8), %rsi
movq %rax, 0x10(%rsi)
movl 0x34(%rbx), %eax
movq (%rdx,%rcx,8), %rcx
movl %eax, 0x1c(%rcx)
movq 0x18(%rbx), %rax
movq 0x28(%rbx), %rcx
movq %r14, (%rcx,%rax,8)
movq 0x28(%rbx), %rcx
movq (%rcx,%rax,8), %rdx
movl 0x1c(%rdx), %esi
movl %esi, 0x34(%rbx)
movq 0x10(%rdx), %rdx
movq %rdx, 0x40(%rbx)
movq %rdx, 0x80(%rbx)
movq (%rcx,%rax,8), %rax
movq (%rax), %rax
movq %rax, 0x8(%rbx)
movb (%rdx), %al
movb %al, 0x30(%rbx)
movl $0x1, 0x50(%rbx)
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O1/doy[P]libvt100/src/parser.c
// Function: vt100_parser_yy_delete_buffer
void yy_delete_buffer (YY_BUFFER_STATE  b , yyscan_t yyscanner)
{
    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;

	if ( ! b )
		return;

	if ( b == YY_CURRENT_BUFFER ) /* Not sure if we should pop here. */
		YY_CURRENT_BUFFER_LVALUE = (YY_BUFFER_STATE) 0;

	if ( b->yy_is_our_buffer )
		yyfree( (void *) b->yy_ch_buf , yyscanner );

	yyfree( (void *) b , yyscanner );
}

// Assembly:
testq %rdi, %rdi
je 0x57b8
pushq %rbx
movq %rdi, %rbx
movq 0x28(%rsi), %rax
testq %rax, %rax
je 0x57b9
movq 0x18(%rsi), %rcx
movq (%rax,%rcx,8), %rcx
jmp 0x57bb
retq
xorl %ecx, %ecx
cmpq %rbx, %rcx
jne 0x57cc
movq 0x18(%rsi), %rcx
movq $0x0, (%rax,%rcx,8)
cmpl $0x0, 0x20(%rbx)
je 0x57db
movq 0x8(%rbx), %rdi
callq 0x3050
movq %rbx, %rdi
popq %rbx
jmp 0x3050
// File: /workspace/github_c_makefile_star2_O1/doy[P]libvt100/src/parser.c
// Function: vt100_parser_yy_flush_buffer
void yy_flush_buffer (YY_BUFFER_STATE  b , yyscan_t yyscanner)
{
    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
	if ( ! b )
		return;

	b->yy_n_chars = 0;

	/* We always need two end-of-buffer characters.  The first causes
	 * a transition to the end-of-buffer state.  The second causes
	 * a jam in that state.
	 */
	b->yy_ch_buf[0] = YY_END_OF_BUFFER_CHAR;
	b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR;

	b->yy_buf_pos = &b->yy_ch_buf[0];

	b->yy_at_bol = 1;
	b->yy_buffer_status = YY_BUFFER_NEW;

	if ( b == YY_CURRENT_BUFFER )
		yy_load_buffer_state( yyscanner );
}

// Assembly:
testq %rdi, %rdi
je 0x5828
xorl %ecx, %ecx
movl %ecx, 0x1c(%rdi)
movq 0x8(%rdi), %rax
movb %cl, (%rax)
movq 0x8(%rdi), %rax
movb %cl, 0x1(%rax)
movq 0x8(%rdi), %rax
movq %rax, 0x10(%rdi)
movl $0x1, 0x28(%rdi)
movl %ecx, 0x38(%rdi)
movq 0x28(%rsi), %rax
testq %rax, %rax
je 0x5823
movq 0x18(%rsi), %rcx
movq (%rax,%rcx,8), %rcx
cmpq %rdi, %rcx
je 0x5829
retq
movq 0x18(%rsi), %rcx
movq (%rax,%rcx,8), %rdx
movl 0x1c(%rdx), %edi
movl %edi, 0x34(%rsi)
movq 0x10(%rdx), %rdx
movq %rdx, 0x40(%rsi)
movq %rdx, 0x80(%rsi)
movq (%rax,%rcx,8), %rax
movq (%rax), %rax
movq %rax, 0x8(%rsi)
movb (%rdx), %al
movb %al, 0x30(%rsi)
retq
// File: /workspace/github_c_makefile_star2_O1/doy[P]libvt100/src/parser.c
// Function: vt100_parser_yypush_buffer_state
void yypush_buffer_state (YY_BUFFER_STATE new_buffer , yyscan_t yyscanner)
{
    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
	if (new_buffer == NULL)
		return;

	yyensure_buffer_stack(yyscanner);

	/* This block is copied from yy_switch_to_buffer. */
	if ( YY_CURRENT_BUFFER )
		{
		/* Flush out information for old buffer. */
		*yyg->yy_c_buf_p = yyg->yy_hold_char;
		YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = yyg->yy_c_buf_p;
		YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars;
		}

	/* Only push if top exists. Otherwise, replace top. */
	if (YY_CURRENT_BUFFER)
		yyg->yy_buffer_stack_top++;
	YY_CURRENT_BUFFER_LVALUE = new_buffer;

	/* copied from yy_switch_to_buffer. */
	yy_load_buffer_state( yyscanner );
	yyg->yy_did_buffer_switch_on_eof = 1;
}

// Assembly:
testq %rdi, %rdi
je 0x590b
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
movq %rsi, %rdi
callq 0x523f
movq 0x28(%rbx), %rax
testq %rax, %rax
je 0x58ad
movq 0x18(%rbx), %rcx
cmpq $0x0, (%rax,%rcx,8)
je 0x58ad
movb 0x30(%rbx), %al
movq 0x40(%rbx), %rcx
movb %al, (%rcx)
movq 0x40(%rbx), %rax
movq 0x18(%rbx), %rcx
movq 0x28(%rbx), %rdx
movq (%rdx,%rcx,8), %rsi
movq %rax, 0x10(%rsi)
movl 0x34(%rbx), %eax
movq (%rdx,%rcx,8), %rcx
movl %eax, 0x1c(%rcx)
movq 0x28(%rbx), %rax
testq %rax, %rax
je 0x58c8
movq 0x18(%rbx), %rcx
cmpq $0x0, (%rax,%rcx,8)
je 0x58c8
incq %rcx
movq %rcx, 0x18(%rbx)
movq 0x18(%rbx), %rcx
movq %r14, (%rax,%rcx,8)
movq 0x28(%rbx), %rax
movq (%rax,%rcx,8), %rdx
movl 0x1c(%rdx), %esi
movl %esi, 0x34(%rbx)
movq 0x10(%rdx), %rdx
movq %rdx, 0x40(%rbx)
movq %rdx, 0x80(%rbx)
movq (%rax,%rcx,8), %rax
movq (%rax), %rax
movq %rax, 0x8(%rbx)
movb (%rdx), %al
movb %al, 0x30(%rbx)
movl $0x1, 0x50(%rbx)
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O1/doy[P]libvt100/src/parser.c
// Function: vt100_parser_yypop_buffer_state
void yypop_buffer_state (yyscan_t yyscanner)
{
    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
	if (!YY_CURRENT_BUFFER)
		return;

	yy_delete_buffer(YY_CURRENT_BUFFER , yyscanner);
	YY_CURRENT_BUFFER_LVALUE = NULL;
	if (yyg->yy_buffer_stack_top > 0)
		--yyg->yy_buffer_stack_top;

	if (YY_CURRENT_BUFFER) {
		yy_load_buffer_state( yyscanner );
		yyg->yy_did_buffer_switch_on_eof = 1;
	}
}

// Assembly:
movq 0x28(%rdi), %rax
testq %rax, %rax
je 0x598d
pushq %rbx
movq %rdi, %rbx
movq 0x18(%rdi), %rcx
movq (%rax,%rcx,8), %rdi
testq %rdi, %rdi
je 0x598c
movq %rbx, %rsi
callq 0x3280
movq 0x18(%rbx), %rax
movq 0x28(%rbx), %rcx
movq $0x0, (%rcx,%rax,8)
testq %rax, %rax
je 0x594a
decq %rax
movq %rax, 0x18(%rbx)
movq 0x28(%rbx), %rax
testq %rax, %rax
je 0x598c
movq 0x18(%rbx), %rcx
movq (%rax,%rcx,8), %rdx
testq %rdx, %rdx
je 0x598c
movl 0x1c(%rdx), %esi
movl %esi, 0x34(%rbx)
movq 0x10(%rdx), %rdx
movq %rdx, 0x40(%rbx)
movq %rdx, 0x80(%rbx)
movq (%rax,%rcx,8), %rax
movq (%rax), %rax
movq %rax, 0x8(%rbx)
movb (%rdx), %al
movb %al, 0x30(%rbx)
movl $0x1, 0x50(%rbx)
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O1/doy[P]libvt100/src/parser.c
// Function: vt100_parser_yylex_init
int yylex_init(yyscan_t* ptr_yy_globals)
{
    if (ptr_yy_globals == NULL){
        errno = EINVAL;
        return 1;
    }

    *ptr_yy_globals = (yyscan_t) yyalloc ( sizeof( struct yyguts_t ), NULL );

    if (*ptr_yy_globals == NULL){
        errno = ENOMEM;
        return 1;
    }

    /* By setting to 0xAA, we expose bugs in yy_init_globals. Leave at 0x00 for releases. */
    memset(*ptr_yy_globals,0x00,sizeof(struct yyguts_t));

    return yy_init_globals ( *ptr_yy_globals );
}

// Assembly:
pushq %rbx
testq %rdi, %rdi
je 0x5bab
movq %rdi, %rbx
movl $0x90, %edi
callq 0x34f0
movq %rax, (%rbx)
testq %rax, %rax
je 0x5bb8
xorl %ebx, %ebx
movl $0x90, %edx
movq %rax, %rdi
xorl %esi, %esi
callq 0x32c0
jmp 0x5bc8
callq 0x3080
movl $0x16, (%rax)
jmp 0x5bc3
callq 0x3080
movl $0xc, (%rax)
movl $0x1, %ebx
movl %ebx, %eax
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O1/doy[P]libvt100/src/parser.c
// Function: vt100_parser_yylex_init_extra
int yylex_init_extra( YY_EXTRA_TYPE yy_user_defined, yyscan_t* ptr_yy_globals )
{
    struct yyguts_t dummy_yyguts;

    yyset_extra (yy_user_defined, &dummy_yyguts);

    if (ptr_yy_globals == NULL){
        errno = EINVAL;
        return 1;
    }

    *ptr_yy_globals = (yyscan_t) yyalloc ( sizeof( struct yyguts_t ), &dummy_yyguts );

    if (*ptr_yy_globals == NULL){
        errno = ENOMEM;
        return 1;
    }

    /* By setting to 0xAA, we expose bugs in
    yy_init_globals. Leave at 0x00 for releases. */
    memset(*ptr_yy_globals,0x00,sizeof(struct yyguts_t));

    yyset_extra (yy_user_defined, *ptr_yy_globals);

    return yy_init_globals ( *ptr_yy_globals );
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
testq %rsi, %rsi
je 0x5c25
movq %rsi, %rbx
movq %rdi, %r14
movl $0x90, %edi
callq 0x34f0
movq %rax, (%rbx)
testq %rax, %rax
je 0x5c32
movq %rax, %r15
xorl %ebx, %ebx
movl $0x90, %edx
movq %rax, %rdi
xorl %esi, %esi
callq 0x32c0
movq %r14, (%r15)
movq %rbx, 0x54(%r15)
movq %rbx, 0x60(%r15)
xorps %xmm0, %xmm0
movups %xmm0, 0x8(%r15)
movups %xmm0, 0x18(%r15)
movq %rbx, 0x28(%r15)
movups %xmm0, 0x40(%r15)
jmp 0x5c42
callq 0x3080
movl $0x16, (%rax)
jmp 0x5c3d
callq 0x3080
movl $0xc, (%rax)
movl $0x1, %ebx
movl %ebx, %eax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/doy[P]libvt100/src/parser.c
// Function: vt100_parser_yylex_destroy
int yylex_destroy  (yyscan_t yyscanner)
{
    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;

    /* Pop the buffer stack, destroying each element. */
	while(YY_CURRENT_BUFFER){
		yy_delete_buffer( YY_CURRENT_BUFFER , yyscanner );
		YY_CURRENT_BUFFER_LVALUE = NULL;
		yypop_buffer_state(yyscanner);
	}

	/* Destroy the stack itself. */
	yyfree(yyg->yy_buffer_stack , yyscanner);
	yyg->yy_buffer_stack = NULL;

    /* Destroy the start condition stack. */
        yyfree( yyg->yy_start_stack , yyscanner );
        yyg->yy_start_stack = NULL;

    /* Reset the globals. This is important in a non-reentrant scanner so the next time
     * yylex() is called, initialization will occur. */
    yy_init_globals( yyscanner);

    /* Destroy the main struct (reentrant only). */
    yyfree ( yyscanner , yyscanner );
    yyscanner = NULL;
    return 0;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0x28(%rdi), %rdi
testq %rdi, %rdi
je 0x5c90
movq 0x18(%rbx), %rax
movq (%rdi,%rax,8), %rax
testq %rax, %rax
je 0x5c90
movq %rax, %rdi
movq %rbx, %rsi
callq 0x3280
movq 0x18(%rbx), %rax
movq 0x28(%rbx), %rcx
movq $0x0, (%rcx,%rax,8)
movq %rbx, %rdi
callq 0x3370
movq 0x28(%rbx), %rdi
jmp 0x5c55
callq 0x3050
xorl %r14d, %r14d
movq %r14, 0x28(%rbx)
movq 0x60(%rbx), %rdi
callq 0x3050
movq %r14, 0x60(%rbx)
movq %r14, 0x54(%rbx)
xorps %xmm0, %xmm0
movups %xmm0, 0x8(%rbx)
movups %xmm0, 0x18(%rbx)
movq %r14, 0x28(%rbx)
movups %xmm0, 0x40(%rbx)
movq %rbx, %rdi
callq 0x3050
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O1/doy[P]libvt100/src/screen.c
// Function: vt100_screen_new
VT100Screen *vt100_screen_new(int rows, int cols)
{
    VT100Screen *vt;

    vt = calloc(1, sizeof(VT100Screen));
    vt100_screen_init(vt);
    vt100_screen_set_window_size(vt, rows, cols);

    return vt;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movl %esi, %ebx
movl %edi, %ebp
movl $0x1, %edi
movl $0x50, %esi
callq 0x33b0
movq %rax, %r14
movq %rax, %rdi
callq 0x34e0
movq %r14, %rdi
movl %ebp, %esi
movl %ebx, %edx
callq 0x3690
movq %r14, %rax
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/doy[P]libvt100/src/screen.c
// Function: vt100_screen_ensure_capacity
static void vt100_screen_ensure_capacity(VT100Screen *vt, int size)
{
    int old_capacity = vt->grid->row_capacity;

    if (vt->grid->row_capacity >= size) {
        return;
    }

    if (vt->grid->row_capacity == 0) {
        vt->grid->row_capacity = vt->grid->max.row;
    }

    while (vt->grid->row_capacity < size) {
        vt->grid->row_capacity *= 1.5;
    }

    vt->grid->rows = realloc(
        vt->grid->rows, vt->grid->row_capacity * sizeof(struct vt100_row));
    memset(
        &vt->grid->rows[old_capacity], 0,
        (vt->grid->row_capacity - old_capacity) * sizeof(struct vt100_row));
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq (%rdi), %rax
movslq 0x24(%rax), %r14
cmpl %esi, %r14d
jge 0x5fb2
movq %rdi, %rbx
testl %r14d, %r14d
jne 0x5f53
movl 0x8(%rax), %ecx
movl %ecx, 0x24(%rax)
movl 0x24(%rax), %ecx
cmpl %esi, %ecx
jge 0x5f78
movsd 0x397e(%rip), %xmm0     # 0x98e0
xorps %xmm1, %xmm1
cvtsi2sd %ecx, %xmm1
mulsd %xmm0, %xmm1
cvttsd2si %xmm1, %ecx
cmpl %esi, %ecx
jl 0x5f62
movl %ecx, 0x24(%rax)
movq 0x30(%rax), %rdi
movslq %ecx, %rsi
shlq $0x4, %rsi
callq 0x3570
movq (%rbx), %rcx
movq %rax, 0x30(%rcx)
movq %r14, %rdi
shlq $0x4, %rdi
addq %rax, %rdi
movslq 0x24(%rcx), %rdx
subq %r14, %rdx
shlq $0x4, %rdx
xorl %esi, %esi
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x32c0
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O1/doy[P]libvt100/src/screen.c
// Function: vt100_screen_process_string
int vt100_screen_process_string(VT100Screen *vt, char *buf, size_t len)
{
    struct vt100_parser_state *state = vt->parser_state;
    int remaining;

    state->state = vt100_parser_yy_scan_bytes(buf, len, state->scanner);
    remaining = vt100_parser_yylex(state->scanner);
    vt100_parser_yy_delete_buffer(state->state, state->scanner);
    return len - remaining;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movq %rdx, %rbx
movq 0x10(%rdi), %r14
movq (%r14), %rdx
movq %rsi, %rdi
movl %ebx, %esi
callq 0x30d0
movq %rax, 0x8(%r14)
movq (%r14), %rdi
callq 0x33f0
movl %eax, %ebp
movq (%r14), %rsi
movq 0x8(%r14), %rdi
callq 0x3280
subl %ebp, %ebx
movl %ebx, %eax
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/doy[P]libvt100/src/screen.c
// Function: vt100_screen_show_string_ascii
void vt100_screen_show_string_ascii(VT100Screen *vt, char *buf, size_t len)
{
    size_t i;

    if (len) {
        vt->dirty = 1;

        if (vt->grid->cur.col > 0) {
            struct vt100_cell *cell;

            cell = vt100_screen_cell_at(
                vt, vt->grid->cur.row, vt->grid->cur.col - 1);
            if (cell->is_wide) {
                cell->len = 0;
            }
        }
    }

    for (i = 0; i < len; ++i) {
        struct vt100_cell *cell;

        vt100_screen_check_wrap(vt, 1);
        cell = vt100_screen_cell_at(vt, vt->grid->cur.row, vt->grid->cur.col);

        cell->len = 1;
        cell->contents[0] = buf[i];
        cell->attrs = vt->attrs;
        cell->is_wide = 0;

        vt->grid->cur.col++;
    }
}

// Assembly:
testq %rdx, %rdx
je 0x6516
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rdx, %rbx
movq %rsi, %r14
movq %rdi, %r15
orb $0x20, 0x4a(%rdi)
movq (%rdi), %rcx
movslq 0x4(%rcx), %rax
testq %rax, %rax
jle 0x64a3
movslq (%rcx), %rdx
movq 0x30(%rcx), %rsi
movslq 0x28(%rcx), %rcx
addq %rdx, %rcx
shlq $0x4, %rcx
movq (%rsi,%rcx), %rcx
shlq $0x5, %rax
testb $0x1, -0x4(%rcx,%rax)
je 0x64a3
addq %rax, %rcx
movq $0x0, -0x18(%rcx)
leaq 0x3c(%r15), %r12
xorl %r13d, %r13d
movq %r15, %rdi
movl $0x1, %esi
callq 0x6517
movq (%r15), %rax
movslq (%rax), %rcx
movslq 0x4(%rax), %rdx
movq 0x30(%rax), %rsi
movslq 0x28(%rax), %rax
addq %rcx, %rax
shlq $0x4, %rax
movq (%rsi,%rax), %rax
shlq $0x5, %rdx
movq $0x1, 0x8(%rax,%rdx)
movb (%r14,%r13), %cl
movb %cl, (%rax,%rdx)
movq (%r12), %rcx
movq %rcx, 0x10(%rax,%rdx)
movl 0x8(%r12), %ecx
movl %ecx, 0x18(%rax,%rdx)
andb $-0x2, 0x1c(%rax,%rdx)
movq (%r15), %rax
incl 0x4(%rax)
incq %r13
cmpq %r13, %rbx
jne 0x64aa
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/doy[P]libvt100/src/screen.c
// Function: vt100_screen_check_wrap
static void vt100_screen_check_wrap(VT100Screen *vt, int width)
{
    if (vt->grid->cur.col + width > vt->grid->max.col) {
        vt100_screen_row_at(vt, vt->grid->cur.row)->wrapped = 1;
        vt100_screen_move_down_or_scroll(vt);
        vt->grid->cur.col = 0;
    }
}

// Assembly:
movq (%rdi), %rax
addl 0x4(%rax), %esi
cmpl 0xc(%rax), %esi
jle 0x654d
pushq %rbx
movq %rdi, %rbx
movslq (%rax), %rcx
movq 0x30(%rax), %rdx
movslq 0x28(%rax), %rax
addq %rcx, %rax
shlq $0x4, %rax
orb $0x1, 0x8(%rdx,%rax)
callq 0x3550
movq (%rbx), %rax
movl $0x0, 0x4(%rax)
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O1/doy[P]libvt100/src/screen.c
// Function: vt100_screen_move_to
void vt100_screen_move_to(VT100Screen *vt, int row, int col)
{
    row = row < 0                  ? 0
        : row >= vt->grid->max.row ? vt->grid->max.row - 1
        : row;
    col = col < 0                  ? 0
        : col >= vt->grid->max.col ? vt->grid->max.col - 1
        : col;

    if (vt->origin_mode) {
        row += vt->grid->scroll_top;
        if (row > vt->grid->scroll_bottom) {
            row = vt->grid->scroll_bottom;
        }
    }

    vt->grid->cur.row = row;
    vt->grid->cur.col = col;
}

// Assembly:
xorl %eax, %eax
movl $0x0, %ecx
testl %esi, %esi
js 0x675d
movq (%rdi), %rcx
movl 0x8(%rcx), %r8d
leal -0x1(%r8), %ecx
cmpl %esi, %r8d
cmovgl %esi, %ecx
testl %edx, %edx
js 0x676f
movq (%rdi), %rax
movl 0xc(%rax), %esi
leal -0x1(%rsi), %eax
cmpl %edx, %esi
cmovgl %edx, %eax
testb $0x1, 0x4a(%rdi)
je 0x6783
movq (%rdi), %rdx
addl 0x18(%rdx), %ecx
movl 0x1c(%rdx), %edx
cmpl %edx, %ecx
cmovgel %edx, %ecx
movq (%rdi), %rdx
movl %ecx, (%rdx)
movl %eax, 0x4(%rdx)
retq
// File: /workspace/github_c_makefile_star2_O1/doy[P]libvt100/src/screen.c
// Function: vt100_screen_clear_screen
void vt100_screen_clear_screen(VT100Screen *vt)
{
    int r;

    for (r = 0; r < vt->grid->max.row; ++r) {
        struct vt100_row *row;

        row = vt100_screen_row_at(vt, r);
        memset(row->cells, 0, vt->grid->max.col * sizeof(struct vt100_cell));
        row->wrapped = 0;
    }

    vt->dirty = 1;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq (%rdi), %rax
cmpl $0x0, 0x8(%rax)
jle 0x67d7
xorl %r14d, %r14d
movq 0x30(%rax), %r15
movslq 0x28(%rax), %r12
addq %r14, %r12
shlq $0x4, %r12
movq (%r15,%r12), %rdi
movslq 0xc(%rax), %rdx
shlq $0x5, %rdx
xorl %esi, %esi
callq 0x32c0
andb $-0x2, 0x8(%r15,%r12)
movq (%rbx), %rax
incq %r14
cmpl 0x8(%rax), %r14d
jl 0x67a3
orb $0x20, 0x4a(%rbx)
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/doy[P]libvt100/src/screen.c
// Function: vt100_screen_clear_screen_forward
void vt100_screen_clear_screen_forward(VT100Screen *vt)
{
    struct vt100_row *row;
    int r;

    row = vt100_screen_row_at(vt, vt->grid->cur.row);
    memset(
        &row->cells[vt->grid->cur.col], 0,
        (vt->grid->max.col - vt->grid->cur.col) * sizeof(struct vt100_cell));
    row->wrapped = 0;
    for (r = vt->grid->cur.row + 1; r < vt->grid->max.row; ++r) {
        row = vt100_screen_row_at(vt, r);
        memset(row->cells, 0, vt->grid->max.col * sizeof(struct vt100_cell));
        row->wrapped = 0;
    }

    vt->dirty = 1;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq (%rdi), %rax
movslq (%rax), %rcx
movq 0x30(%rax), %r14
movslq 0x28(%rax), %r15
addq %rcx, %r15
shlq $0x4, %r15
movslq 0x4(%rax), %rdi
movslq 0xc(%rax), %rdx
subq %rdi, %rdx
shlq $0x5, %rdi
addq (%r14,%r15), %rdi
shlq $0x5, %rdx
xorl %esi, %esi
callq 0x32c0
andb $-0x2, 0x8(%r14,%r15)
movq (%rbx), %rax
movslq (%rax), %r14
leal 0x1(%r14), %ecx
cmpl 0x8(%rax), %ecx
jge 0x6871
incq %r14
movq 0x30(%rax), %r15
movslq 0x28(%rax), %r12
addq %r14, %r12
shlq $0x4, %r12
movq (%r15,%r12), %rdi
movslq 0xc(%rax), %rdx
shlq $0x5, %rdx
xorl %esi, %esi
callq 0x32c0
andb $-0x2, 0x8(%r15,%r12)
movq (%rbx), %rax
incq %r14
cmpl 0x8(%rax), %r14d
jl 0x683d
orb $0x20, 0x4a(%rbx)
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/doy[P]libvt100/src/screen.c
// Function: vt100_screen_clear_screen_backward
void vt100_screen_clear_screen_backward(VT100Screen *vt)
{
    struct vt100_row *row;
    int r;

    for (r = 0; r < vt->grid->cur.row - 1; ++r) {
        row = vt100_screen_row_at(vt, r);
        memset(row->cells, 0, vt->grid->max.col * sizeof(struct vt100_cell));
        row->wrapped = 0;
    }
    row = vt100_screen_row_at(vt, vt->grid->cur.row);
    memset(row->cells, 0, vt->grid->cur.col * sizeof(struct vt100_cell));

    vt->dirty = 1;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq (%rdi), %rax
movl (%rax), %ecx
cmpl $0x2, %ecx
jl 0x68d1
xorl %r14d, %r14d
movq 0x30(%rax), %r15
movslq 0x28(%rax), %r12
addq %r14, %r12
shlq $0x4, %r12
movq (%r15,%r12), %rdi
movslq 0xc(%rax), %rdx
shlq $0x5, %rdx
xorl %esi, %esi
callq 0x32c0
andb $-0x2, 0x8(%r15,%r12)
movq (%rbx), %rax
movl (%rax), %ecx
leal -0x1(%rcx), %edx
incq %r14
cmpl %edx, %r14d
jl 0x6899
movq 0x30(%rax), %rdx
movslq 0x28(%rax), %rsi
movslq %ecx, %rcx
addq %rsi, %rcx
shlq $0x4, %rcx
movq (%rdx,%rcx), %rdi
movslq 0x4(%rax), %rdx
shlq $0x5, %rdx
xorl %esi, %esi
callq 0x32c0
orb $0x20, 0x4a(%rbx)
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/doy[P]libvt100/src/screen.c
// Function: vt100_screen_kill_line
void vt100_screen_kill_line(VT100Screen *vt)
{
    struct vt100_row *row;

    row = vt100_screen_row_at(vt, vt->grid->cur.row);
    memset(row->cells, 0, vt->grid->max.col * sizeof(struct vt100_cell));
    row->wrapped = 0;

    vt->dirty = 1;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %rbx
movq (%rdi), %rax
movslq (%rax), %rcx
movq 0x30(%rax), %r14
movslq 0x28(%rax), %r15
addq %rcx, %r15
shlq $0x4, %r15
movq (%r14,%r15), %rdi
movslq 0xc(%rax), %rdx
shlq $0x5, %rdx
xorl %esi, %esi
callq 0x32c0
andb $-0x2, 0x8(%r14,%r15)
orb $0x20, 0x4a(%rbx)
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/doy[P]libvt100/src/screen.c
// Function: vt100_screen_kill_line_forward
void vt100_screen_kill_line_forward(VT100Screen *vt)
{
    struct vt100_row *row;

    row = vt100_screen_row_at(vt, vt->grid->cur.row);
    memset(
        &row->cells[vt->grid->cur.col], 0,
        (vt->grid->max.col - vt->grid->cur.col) * sizeof(struct vt100_cell));
    row->wrapped = 0;

    vt->dirty = 1;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %rbx
movq (%rdi), %rax
movslq (%rax), %rcx
movq 0x30(%rax), %r14
movslq 0x28(%rax), %r15
addq %rcx, %r15
shlq $0x4, %r15
movslq 0x4(%rax), %rdi
movslq 0xc(%rax), %rdx
subq %rdi, %rdx
shlq $0x5, %rdi
addq (%r14,%r15), %rdi
shlq $0x5, %rdx
xorl %esi, %esi
callq 0x32c0
andb $-0x2, 0x8(%r14,%r15)
orb $0x20, 0x4a(%rbx)
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/doy[P]libvt100/src/screen.c
// Function: vt100_screen_kill_line_backward
void vt100_screen_kill_line_backward(VT100Screen *vt)
{
    struct vt100_row *row;

    row = vt100_screen_row_at(vt, vt->grid->cur.row);
    memset(row->cells, 0, vt->grid->cur.col * sizeof(struct vt100_cell));
    if (vt->grid->cur.row > 0) {
        row = vt100_screen_row_at(vt, vt->grid->cur.row - 1);
        row->wrapped = 0;
    }

    vt->dirty = 1;
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
movq (%rdi), %rax
movslq (%rax), %rcx
movq 0x30(%rax), %rdx
movslq 0x28(%rax), %rsi
addq %rcx, %rsi
shlq $0x4, %rsi
movq (%rdx,%rsi), %rdi
movslq 0x4(%rax), %rdx
shlq $0x5, %rdx
xorl %esi, %esi
callq 0x32c0
movq (%rbx), %rcx
movslq (%rcx), %rax
testq %rax, %rax
jle 0x69dc
movslq 0x28(%rcx), %rdx
addq %rdx, %rax
movq 0x30(%rcx), %rcx
shlq $0x4, %rax
andb $-0x2, -0x8(%rax,%rcx)
orb $0x20, 0x4a(%rbx)
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O1/doy[P]libvt100/src/screen.c
// Function: vt100_screen_insert_characters
void vt100_screen_insert_characters(VT100Screen *vt, int count)
{
    struct vt100_row *row;

    row = vt100_screen_row_at(vt, vt->grid->cur.row);
    if (count >= vt->grid->max.col - vt->grid->cur.col) {
        vt100_screen_kill_line_forward(vt);
    }
    else {
        memmove(
            &row->cells[vt->grid->cur.col + count],
            &row->cells[vt->grid->cur.col],
            (vt->grid->max.col - vt->grid->cur.col - count) * sizeof(struct vt100_cell));
        memset(
            &row->cells[vt->grid->cur.col], 0,
            count * sizeof(struct vt100_cell));
        row->wrapped = 0;
    }

    vt->dirty = 1;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movl %esi, %eax
movq %rdi, %rbx
movq (%rdi), %rcx
movslq (%rcx), %rdx
movq 0x30(%rcx), %rdi
movslq 0x28(%rcx), %r8
addq %rdx, %r8
shlq $0x4, %r8
leaq (%rdi,%r8), %r15
movslq 0xc(%rcx), %rdx
movslq 0x4(%rcx), %rsi
subq %rsi, %rdx
movl %edx, %ecx
movq (%rdi,%r8), %rdi
subl %eax, %ecx
jle 0x6a61
movslq %eax, %r14
leaq (%rsi,%r14), %rax
shlq $0x5, %rax
addq %rdi, %rax
shlq $0x5, %rsi
addq %rdi, %rsi
movslq %ecx, %rdx
shlq $0x5, %rdx
movq %rax, %rdi
callq 0x3590
movq (%rbx), %rax
movslq 0x4(%rax), %rdi
shlq $0x5, %rdi
addq (%r15), %rdi
shlq $0x5, %r14
xorl %esi, %esi
movq %r14, %rdx
callq 0x32c0
andb $-0x2, 0x8(%r15)
jmp 0x6a7c
shlq $0x5, %rsi
addq %rsi, %rdi
shlq $0x5, %rdx
xorl %esi, %esi
callq 0x32c0
andb $-0x2, 0x8(%r15)
orb $0x20, 0x4a(%rbx)
orb $0x20, 0x4a(%rbx)
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/doy[P]libvt100/src/screen.c
// Function: vt100_screen_insert_lines
void vt100_screen_insert_lines(VT100Screen *vt, int count)
{
    if (count >= vt->grid->max.row - vt->grid->cur.row) {
        vt100_screen_clear_screen_forward(vt);
        vt100_screen_kill_line(vt);
    }
    else {
        struct vt100_row *row;
        int bottom = vt->grid->scroll_bottom + 1;
        int i;

        for (i = bottom - count; i < bottom; ++i) {
            row = vt100_screen_row_at(vt, i);
            free(row->cells);
        }
        row = vt100_screen_row_at(vt, vt->grid->cur.row);
        memmove(
            row + count, row,
            (bottom - vt->grid->cur.row - count) * sizeof(struct vt100_row));
        memset(row, 0, count * sizeof(struct vt100_row));
        for (i = vt->grid->cur.row; i < vt->grid->cur.row + count; ++i) {
            row = vt100_screen_row_at(vt, i);
            row->cells = calloc(vt->grid->max.col, sizeof(struct vt100_cell));
            row->wrapped = 0;
        }
    }

    vt->dirty = 1;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rdi, %rbx
movq (%rdi), %rax
movl 0x8(%rax), %ecx
subl (%rax), %ecx
cmpl %esi, %ecx
jle 0x6b64
movl %esi, %r14d
movl 0x1c(%rax), %eax
leal 0x1(%rax), %r13d
movl %r13d, %ecx
subl %esi, %ecx
cmpl %eax, %ecx
jg 0x6ade
movl %r14d, %r15d
negl %r15d
movq (%rbx), %rax
leal (%r15,%r13), %ecx
addl 0x28(%rax), %ecx
movq 0x30(%rax), %rax
movslq %ecx, %rcx
shlq $0x4, %rcx
movq (%rax,%rcx), %rdi
callq 0x3050
incl %r15d
jne 0x6abb
movq (%rbx), %rax
movslq (%rax), %rcx
movslq 0x28(%rax), %r15
addq %rcx, %r15
shlq $0x4, %r15
addq 0x30(%rax), %r15
movslq %r14d, %r12
shlq $0x4, %r12
leaq (%r15,%r12), %rdi
subl %ecx, %r13d
subl %r14d, %r13d
movslq %r13d, %rdx
shlq $0x4, %rdx
movq %r15, %rsi
callq 0x3590
movq %r15, %rdi
xorl %esi, %esi
movq %r12, %rdx
callq 0x32c0
testl %r14d, %r14d
jle 0x6b9e
movq (%rbx), %rax
movslq (%rax), %r15
movq 0x30(%rax), %r12
movslq 0x28(%rax), %r13
addq %r15, %r13
shlq $0x4, %r13
movslq 0xc(%rax), %rdi
movl $0x20, %esi
callq 0x33b0
movq %rax, (%r12,%r13)
andb $-0x2, 0x8(%r12,%r13)
movq (%rbx), %rax
movl (%rax), %ecx
addl %r14d, %ecx
incq %r15
cmpl %ecx, %r15d
jl 0x6b2b
jmp 0x6b9e
movq %rbx, %rdi
callq 0x3330
movq (%rbx), %rax
movslq (%rax), %rcx
movq 0x30(%rax), %r14
movslq 0x28(%rax), %r15
addq %rcx, %r15
shlq $0x4, %r15
movq (%r14,%r15), %rdi
movslq 0xc(%rax), %rdx
shlq $0x5, %rdx
xorl %esi, %esi
callq 0x32c0
andb $-0x2, 0x8(%r14,%r15)
orb $0x20, 0x4a(%rbx)
orb $0x20, 0x4a(%rbx)
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/doy[P]libvt100/src/screen.c
// Function: vt100_screen_delete_characters
void vt100_screen_delete_characters(VT100Screen *vt, int count)
{
    if (count >= vt->grid->max.col - vt->grid->cur.col) {
        vt100_screen_kill_line_forward(vt);
    }
    else {
        struct vt100_row *row;

        row = vt100_screen_row_at(vt, vt->grid->cur.row);
        memmove(
            &row->cells[vt->grid->cur.col],
            &row->cells[vt->grid->cur.col + count],
            (vt->grid->max.col - vt->grid->cur.col - count) * sizeof(struct vt100_cell));
        memset(
            &row->cells[vt->grid->max.col - count], 0,
            count * sizeof(struct vt100_cell));
        row->wrapped = 0;
    }

    vt->dirty = 1;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movl %esi, %r14d
movq %rdi, %rbx
movq (%rdi), %rsi
movl 0xc(%rsi), %eax
movslq 0x4(%rsi), %rcx
movl %eax, %edx
subl %ecx, %edx
movslq (%rsi), %rdi
movq 0x30(%rsi), %r8
movslq 0x28(%rsi), %rsi
addq %rdi, %rsi
shlq $0x4, %rsi
leaq (%r8,%rsi), %r15
movq (%r8,%rsi), %rsi
movq %rcx, %rdi
shlq $0x5, %rdi
addq %rsi, %rdi
cmpl %r14d, %edx
jle 0x6c2f
addl %r14d, %ecx
movslq %ecx, %rcx
subl %ecx, %eax
shlq $0x5, %rcx
addq %rcx, %rsi
movslq %eax, %rdx
shlq $0x5, %rdx
callq 0x3590
movq (%rbx), %rax
movslq 0xc(%rax), %rdi
movslq %r14d, %rdx
subq %rdx, %rdi
shlq $0x5, %rdi
addq (%r15), %rdi
shlq $0x5, %rdx
xorl %esi, %esi
callq 0x32c0
andb $-0x2, 0x8(%r15)
jmp 0x6c46
movslq %edx, %rdx
shlq $0x5, %rdx
xorl %esi, %esi
callq 0x32c0
andb $-0x2, 0x8(%r15)
orb $0x20, 0x4a(%rbx)
orb $0x20, 0x4a(%rbx)
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/doy[P]libvt100/src/screen.c
// Function: vt100_screen_erase_characters
void vt100_screen_erase_characters(VT100Screen *vt, int count)
{
    if (count >= vt->grid->max.col - vt->grid->cur.col) {
        vt100_screen_kill_line_forward(vt);
    }
    else {
        struct vt100_row *row;
        int i;

        row = vt100_screen_row_at(vt, vt->grid->cur.row);

        for (i = vt->grid->cur.col; i < vt->grid->cur.col + count; ++i) {
            struct vt100_cell *cell = &row->cells[i];

            cell->len = 0;
        }
    }

    vt->dirty = 1;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %rbx
movq (%rdi), %rcx
movslq 0xc(%rcx), %rdx
movslq 0x4(%rcx), %rdi
subq %rdi, %rdx
cmpl %esi, %edx
jle 0x6dea
testl %esi, %esi
jle 0x6e19
movslq %esi, %rax
addq %rdi, %rax
movq 0x30(%rcx), %rdx
movslq 0x28(%rcx), %rsi
movslq (%rcx), %rcx
addq %rsi, %rcx
shlq $0x4, %rcx
movq (%rdx,%rcx), %rcx
movq %rdi, %rdx
shlq $0x5, %rdx
addq %rdx, %rcx
addq $0x8, %rcx
movq $0x0, (%rcx)
incq %rdi
addq $0x20, %rcx
cmpq %rax, %rdi
jl 0x6dd5
jmp 0x6e19
movslq (%rcx), %rax
movq 0x30(%rcx), %r14
movslq 0x28(%rcx), %r15
addq %rax, %r15
shlq $0x4, %r15
shlq $0x5, %rdi
addq (%r14,%r15), %rdi
shlq $0x5, %rdx
xorl %esi, %esi
callq 0x32c0
andb $-0x2, 0x8(%r14,%r15)
orb $0x20, 0x4a(%rbx)
orb $0x20, 0x4a(%rbx)
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/doy[P]libvt100/src/screen.c
// Function: vt100_screen_scroll_down
void vt100_screen_scroll_down(VT100Screen *vt, int count)
{
    struct vt100_row *row;
    int bottom = vt->grid->scroll_bottom, top = vt->grid->scroll_top;
    int i;

    if (bottom - top + 1 > count) {
        for (i = 0; i < count; ++i) {
            row = vt100_screen_row_at(vt, bottom - i);
            free(row->cells);
        }
        row = vt100_screen_row_at(vt, top);
        memmove(
            row + count, row,
            (bottom - top + 1 - count) * sizeof(struct vt100_row));
        for (i = 0; i < count; ++i) {
            row = vt100_screen_row_at(vt, top + i);
            row->cells = calloc(vt->grid->max.col, sizeof(struct vt100_cell));
            row->wrapped = 0;
        }
    }
    else {
        for (i = 0; i < bottom - top + 1; ++i) {
            row = vt100_screen_row_at(vt, top + i);
            memset(
                row->cells, 0, vt->grid->max.col * sizeof(struct vt100_cell));
            row->wrapped = 0;
        }
    }

    vt->dirty = 1;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq (%rdi), %rax
movl 0x18(%rax), %r14d
movl 0x1c(%rax), %r15d
movl %r15d, %eax
subl %r14d, %eax
movl %eax, %r12d
subl %esi, %r12d
jge 0x6e8f
testl %eax, %eax
js 0x6f1f
incl %r15d
movq (%rbx), %rax
movq 0x30(%rax), %r12
movl 0x28(%rax), %ecx
addl %r14d, %ecx
movslq %ecx, %r13
shlq $0x4, %r13
movq (%r12,%r13), %rdi
movslq 0xc(%rax), %rdx
shlq $0x5, %rdx
xorl %esi, %esi
callq 0x32c0
andb $-0x2, 0x8(%r12,%r13)
incl %r14d
cmpl %r14d, %r15d
jne 0x6e55
jmp 0x6f1f
movl %esi, %ebp
movslq %r14d, %r14
testl %esi, %esi
jle 0x6ebf
movl %ebp, %r13d
movq (%rbx), %rax
movq 0x30(%rax), %rcx
movl 0x28(%rax), %eax
addl %r15d, %eax
cltq
shlq $0x4, %rax
movq (%rcx,%rax), %rdi
callq 0x3050
decl %r15d
decl %r13d
jne 0x6e9b
movq (%rbx), %rax
movslq 0x28(%rax), %rsi
addq %r14, %rsi
shlq $0x4, %rsi
addq 0x30(%rax), %rsi
movslq %ebp, %rdi
shlq $0x4, %rdi
addq %rsi, %rdi
incl %r12d
movslq %r12d, %rdx
shlq $0x4, %rdx
callq 0x3590
testl %ebp, %ebp
jle 0x6f1f
movq (%rbx), %rax
movq 0x30(%rax), %r15
movslq 0x28(%rax), %r12
addq %r14, %r12
shlq $0x4, %r12
movslq 0xc(%rax), %rdi
movl $0x20, %esi
callq 0x33b0
movq %rax, (%r15,%r12)
andb $-0x2, 0x8(%r15,%r12)
incq %r14
decl %ebp
jne 0x6eee
orb $0x20, 0x4a(%rbx)
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/doy[P]libvt100/src/screen.c
// Function: vt100_screen_set_scroll_region
void vt100_screen_set_scroll_region(
    VT100Screen *vt, int top, int bottom, int left, int right)
{
    if (left > 0 || right < vt->grid->max.col - 1) {
        fprintf(stderr, "vertical scroll regions not yet implemented\n");
    }

    if (top > bottom) {
        return;
    }

    vt->grid->scroll_top = top < 0
        ? 0
        : top;
    vt->grid->scroll_bottom = bottom >= vt->grid->max.row
        ? vt->grid->max.row - 1
        : bottom;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movl %edx, %ebx
movl %esi, %ebp
movq %rdi, %r14
testl %ecx, %ecx
jg 0x722a
movq (%r14), %rax
movl 0xc(%rax), %eax
decl %eax
cmpl %r8d, %eax
jg 0x722a
cmpl %ebx, %ebp
jg 0x7225
xorl %eax, %eax
testl %ebp, %ebp
cmovgl %ebp, %eax
movq (%r14), %rcx
movl %eax, 0x18(%rcx)
movl 0x8(%rcx), %eax
leal -0x1(%rax), %edx
cmpl %ebx, %eax
cmovgl %ebx, %edx
movl %edx, 0x1c(%rcx)
popq %rbx
popq %r14
popq %rbp
retq
callq 0x38aa
jmp 0x7206
// File: /workspace/github_c_makefile_star2_O1/doy[P]libvt100/src/screen.c
// Function: vt100_screen_use_alternate_buffer
void vt100_screen_use_alternate_buffer(VT100Screen *vt)
{
    if (vt->alternate) {
        return;
    }

    vt->alternate = vt->grid;
    vt->grid = calloc(1, sizeof(struct vt100_grid));
    vt100_screen_set_window_size(
        vt, vt->alternate->max.row, vt->alternate->max.col
    );

    vt->dirty = 1;
}

// Assembly:
cmpq $0x0, 0x8(%rdi)
je 0x72ab
retq
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq (%rdi), %r14
movq %r14, 0x8(%rdi)
movl $0x1, %edi
movl $0x38, %esi
callq 0x33b0
movq %rax, (%rbx)
movl 0x8(%r14), %esi
movl 0xc(%r14), %edx
movq %rbx, %rdi
callq 0x3690
orb $0x20, 0x4a(%rbx)
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O1/doy[P]libvt100/src/screen.c
// Function: vt100_screen_use_normal_buffer
void vt100_screen_use_normal_buffer(VT100Screen *vt)
{
    int i;

    if (!vt->alternate) {
        return;
    }

    for (i = 0; i < vt->grid->row_count; ++i) {
        free(vt->grid->rows[i].cells);
    }
    free(vt->grid->rows);
    free(vt->grid);

    vt->grid = vt->alternate;
    vt->alternate = NULL;

    vt100_screen_set_window_size(vt, vt->grid->max.row, vt->grid->max.col);

    vt->dirty = 1;
}

// Assembly:
cmpq $0x0, 0x8(%rdi)
je 0x735c
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %rbx
movq (%rdi), %rax
cmpl $0x0, 0x20(%rax)
jle 0x7325
xorl %r14d, %r14d
xorl %r15d, %r15d
movq 0x30(%rax), %rax
movq (%rax,%r14), %rdi
callq 0x3050
incq %r15
movq (%rbx), %rax
movslq 0x20(%rax), %rcx
addq $0x10, %r14
cmpq %rcx, %r15
jl 0x7305
movq 0x30(%rax), %rdi
callq 0x3050
movq (%rbx), %rdi
callq 0x3050
movq 0x8(%rbx), %rax
movq %rax, (%rbx)
movq $0x0, 0x8(%rbx)
movl 0x8(%rax), %esi
movl 0xc(%rax), %edx
movq %rbx, %rdi
callq 0x3690
orb $0x20, 0x4a(%rbx)
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/doy[P]libvt100/src/screen.c
// Function: vt100_screen_set_window_title
void vt100_screen_set_window_title(VT100Screen *vt, char *buf, size_t len)
{
    free(vt->title);
    vt->title_len = len;
    vt->title = malloc(vt->title_len);
    memcpy(vt->title, buf, vt->title_len);
    vt->update_title = 1;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdx, %rbx
movq %rsi, %r14
movq %rdi, %r15
movq 0x18(%rdi), %rdi
callq 0x3050
movq %rbx, 0x20(%r15)
movq %rbx, %rdi
callq 0x34f0
movq %rax, 0x18(%r15)
movq %rax, %rdi
movq %r14, %rsi
movq %rbx, %rdx
callq 0x3430
orb $0x8, 0x4a(%r15)
popq %rbx
popq %r14
popq %r15
retq