// File: /workspace/github_c_makefile_star2_O0/dalnefre[P]kernel_abe/kernel.c
// Function: run_repl
void
run_repl(int batch)
{
	CONFIG* cfg = CFG;  /* USE GLOBAL CONFIGURATION */

	for (;;) {
		int remain = run_configuration(cfg, batch);

		if (remain < 0) {
			DBUG_PRINT("", ("%d messages queued (limit %d).", cfg->q_count, cfg->q_limit));
			break;		/* abnormal return */
		}
		DBUG_PRINT("", ("%d messages delivered (batch %d).", (batch - remain), batch));
		if (remain == 0) {
			fprintf(stderr, "\nMessage limit of %d exceeded!\n", batch);
			fprintf(stderr, "%d undelivered message(s)\n", cfg->q_count);
		}
		if (cfg->t_count > 0) {
			DBUG_PRINT("", ("waiting for timed event..."));
			sleep(1);
		} else {
			return;		/* no more work to do! */
		}
	}
	fprintf(stderr, "\nOutstanding messages exceeded limit of %d\n", cfg->q_limit);
	abort();	/* abnormal termination */
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movl %edi, -0x4(%rbp)
movq 0x2ac3e(%rip), %rax     # 0x2f390
movq %rax, -0x10(%rbp)
movq -0x10(%rbp), %rdi
movl -0x4(%rbp), %esi
callq 0x1c110
movl %eax, -0x14(%rbp)
cmpl $0x0, -0x14(%rbp)
jge 0x47db
jmp 0x476d
leaq 0x2b1ac(%rip), %rax     # 0x2f920
cmpl $0x0, (%rax)
je 0x47d4
leaq 0x2aba0(%rip), %rax     # 0x2f320
movq (%rax), %rax
movq 0x50(%rax), %rax
leaq 0x24be1(%rip), %rcx     # 0x2936f
movq %rcx, 0x10(%rax)
leaq 0x24bd6(%rip), %rdi     # 0x2936f
callq 0x278a0
cmpl $0x0, %eax
je 0x47d4
leaq 0x2ab76(%rip), %rax     # 0x2f320
movq (%rax), %rax
movq 0x50(%rax), %rax
movl $0xb14, 0xc(%rax)       # imm = 0xB14
movq -0x10(%rbp), %rax
movl 0x28(%rax), %esi
movq -0x10(%rbp), %rax
movl 0x40(%rax), %edx
leaq 0x249a8(%rip), %rdi     # 0x29175
movb $0x0, %al
callq 0x28540
jmp 0x47d6
jmp 0x48ff
jmp 0x47dd
leaq 0x2b13c(%rip), %rax     # 0x2f920
cmpl $0x0, (%rax)
je 0x483f
leaq 0x2ab30(%rip), %rax     # 0x2f320
movq (%rax), %rax
movq 0x50(%rax), %rax
leaq 0x24b71(%rip), %rcx     # 0x2936f
movq %rcx, 0x10(%rax)
leaq 0x24b66(%rip), %rdi     # 0x2936f
callq 0x278a0
cmpl $0x0, %eax
je 0x483f
leaq 0x2ab06(%rip), %rax     # 0x2f320
movq (%rax), %rax
movq 0x50(%rax), %rax
movl $0xb17, 0xc(%rax)       # imm = 0xB17
movl -0x4(%rbp), %esi
subl -0x14(%rbp), %esi
movl -0x4(%rbp), %edx
leaq 0x2495c(%rip), %rdi     # 0x29194
movb $0x0, %al
callq 0x28540
jmp 0x4841
cmpl $0x0, -0x14(%rbp)
jne 0x4881
movq 0x2a7aa(%rip), %rax     # 0x2eff8
movq (%rax), %rdi
movl -0x4(%rbp), %edx
leaq 0x2495b(%rip), %rsi     # 0x291b6
movb $0x0, %al
callq 0x2170
movq 0x2a78f(%rip), %rax     # 0x2eff8
movq (%rax), %rdi
movq -0x10(%rbp), %rax
movl 0x28(%rax), %edx
leaq 0x2495c(%rip), %rsi     # 0x291d6
movb $0x0, %al
callq 0x2170
movq -0x10(%rbp), %rax
cmpl $0x0, 0x68(%rax)
jle 0x48f4
jmp 0x488d
leaq 0x2b08c(%rip), %rax     # 0x2f920
cmpl $0x0, (%rax)
je 0x48e6
leaq 0x2aa80(%rip), %rax     # 0x2f320
movq (%rax), %rax
movq 0x50(%rax), %rax
leaq 0x24ac1(%rip), %rcx     # 0x2936f
movq %rcx, 0x10(%rax)
leaq 0x24ab6(%rip), %rdi     # 0x2936f
callq 0x278a0
cmpl $0x0, %eax
je 0x48e6
leaq 0x2aa56(%rip), %rax     # 0x2f320
movq (%rax), %rax
movq 0x50(%rax), %rax
movl $0xb1d, 0xc(%rax)       # imm = 0xB1D
leaq 0x24912(%rip), %rdi     # 0x291f1
movb $0x0, %al
callq 0x28540
jmp 0x48e8
movl $0x1, %edi
callq 0x2240
jmp 0x48fa
addq $0x20, %rsp
popq %rbp
retq
jmp 0x4756
movq 0x2a6f2(%rip), %rax     # 0x2eff8
movq (%rax), %rdi
movq -0x10(%rbp), %rax
movl 0x40(%rax), %edx
leaq 0x248f5(%rip), %rsi     # 0x2920c
movb $0x0, %al
callq 0x2170
callq 0x2050
nopw %cs:(%rax,%rax)