// File: /workspace/github_c_makefile_star2_O2/dalnefre[P]kernel_abe/life.c
// Function: init_life
CONFIG*
init_life()
{
	static BOOL init_done = FALSE;
	int x, y;
	CONFIG* cfg;
	
	DBUG_ENTER("init_life");
	if (init_done) {
		DBUG_RETURN NULL;
	}
	DBUG_PRINT("", ("init needed"));
	cfg = new_configuration(1000);
	for (y = 0; y < Y_MAX; ++y) {
		for (x = 0; x < X_MAX; ++x) {
			CONS* state = NIL;
			state = map_put(state, ATOM("y"), NUMBER(y));
			state = map_put(state, ATOM("x"), NUMBER(x));
			state = map_put(state, ATOM("value"), NUMBER(get_grid_value(x, y)));
			cells[y][x] = CFG_ACTOR(cfg, cell_actor, state);
			DBUG_PRINT("", ("cell(%d,%d) = %s", x, y, cons_to_str(cells[y][x])));
		}
	}
	init_done = TRUE;
	DBUG_RETURN cfg;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
leaq 0xaeec(%rip), %rax      # 0xe144
leaq 0x10(%rsp), %rdi
movq %rax, (%rdi)
leaq 0x11191(%rip), %rbx     # 0x143f8
movq (%rbx), %rax
movq 0x50(%rax), %rax
movl 0x8(%rax), %ecx
movl %ecx, 0x8(%rdi)
movl $0x15c, 0xc(%rdi)       # imm = 0x15C
leaq 0xcb5e(%rip), %r14      # 0xfde0
movq %r14, 0x10(%rdi)
leaq 0x10fa3(%rip), %rcx     # 0x14230
movq %rcx, 0x18(%rdi)
movq %rax, 0x20(%rdi)
callq 0xd145
cmpq $0x0, 0x113ae(%rip)     # 0x14650
je 0x32b1
movl $0x15e, %eax            # imm = 0x15E
xorl %r12d, %r12d
jmp 0x344d
leaq 0x118e8(%rip), %rax     # 0x14ba0
cmpl $0x0, (%rax)
je 0x32f0
movq (%rbx), %rax
movq 0x50(%rax), %rax
movq %r14, 0x10(%rax)
movq %r14, %rdi
callq 0xc8c0
testl %eax, %eax
je 0x32f0
movq (%rbx), %rax
movq 0x50(%rax), %rax
movl $0x160, 0xc(%rax)       # imm = 0x160
leaq 0xae65(%rip), %rdi      # 0xe14e
xorl %eax, %eax
callq 0xd1bc
movl $0x3e8, %edi            # imm = 0x3E8
callq 0x3ddc
movq %rax, %r12
leaq 0x1114c(%rip), %rax     # 0x14450
movq %rax, (%rsp)
xorl %r15d, %r15d
cmpq $0x8, %r15
je 0x343d
leaq 0x3(,%r15,4), %rax
movq %rax, 0x8(%rsp)
xorl %r13d, %r13d
pushq $0x3
popq %rbp
cmpq $0x23, %rbp
je 0x3430
leaq 0xb525(%rip), %rdi      # 0xe85e
callq 0x89eb
leaq 0x11023(%rip), %rdi     # 0x14368
movq %rax, %rsi
movq 0x8(%rsp), %rdx
callq 0xb8c5
movq %rax, %rbx
leaq 0xc03a(%rip), %rdi      # 0xf396
callq 0x89eb
movq %rbx, %rdi
movq %rax, %rsi
movq %rbp, %rdx
callq 0xb8c5
movq %rax, %rbx
leaq 0xc3be(%rip), %rdi      # 0xf737
callq 0x89eb
movq %rax, %r14
movl %r13d, %edi
movl %r15d, %esi
callq 0x2382
cltq
leaq 0x3(,%rax,4), %rdx
movq %rbx, %rdi
movq %r14, %rsi
callq 0xb8c5
movq %r12, %rdi
leaq -0x955(%rip), %rsi      # 0x2a56
movq %rax, %rdx
callq 0x4483
movq (%rsp), %rcx
movq %rax, -0x6(%rcx,%rbp,2)
leaq 0x117dd(%rip), %rax     # 0x14ba0
cmpl $0x0, (%rax)
je 0x3424
leaq 0x11029(%rip), %rax     # 0x143f8
movq (%rax), %rax
movq 0x50(%rax), %rax
leaq 0xca03(%rip), %rdi      # 0xfde0
movq %rdi, 0x10(%rax)
callq 0xc8c0
testl %eax, %eax
je 0x3424
leaq 0x11007(%rip), %rax     # 0x143f8
movq (%rax), %rax
movq 0x50(%rax), %rax
movl $0x169, 0xc(%rax)       # imm = 0x169
movq (%rsp), %rax
movq -0x6(%rax,%rbp,2), %rdi
callq 0x57d4
leaq 0xad46(%rip), %rdi      # 0xe15a
movl %r13d, %esi
movl %r15d, %edx
movq %rax, %rcx
xorl %eax, %eax
callq 0xd1bc
addq $0x4, %rbp
incl %r13d
jmp 0x3328
incq %r15
addq $0x40, (%rsp)
jmp 0x330b
movq $0x1, 0x11208(%rip) # 0x14650
movl $0x16d, %eax            # imm = 0x16D
leaq 0x10(%rsp), %rdi
movl %eax, 0xc(%rdi)
callq 0xd2be
movq %r12, %rax
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq