// File: /workspace/github_c_makefile_star2_O3/dalnefre[P]kernel_abe/reduce.c
// Function: eval_function
BEH_DECL(eval_function)
{
	CONS* msg = WHAT;
	CONS* expr = map_get(msg, expr_symbol);
	CONS* state = MINE;
	CONS* vars = map_get(state, ATOM("vars"));
	CONS* body = map_get(state, ATOM("body"));
	CONS* cont = map_get(state, cont_symbol);
	CONS* env = map_get(state, env_symbol);

	DBUG_ENTER("eval_function");
	DBUG_PRINT("", ("vars=%s", cons_to_str(vars)));
	DBUG_PRINT("", ("expr=%s", cons_to_str(expr)));
	if (consp(vars)) {
		/* bind vars to values */
		env = map_def(env, vars, expr);
	} else if (atomp(vars)) {
		/* bind single var to list of values */
		env = map_put(env, vars, expr);
	}
	DBUG_PRINT("", ("body=%s", cons_to_str(body)));
	msg = NIL;
	msg = map_put(msg, env_symbol, env);
	msg = map_put(msg, cont_symbol, cont);
	msg = map_put(msg, expr_symbol, body);
	SEND(a_reduce, msg);
	DBUG_RETURN;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x48, %rsp
movq %rdi, %rbx
movq 0x30(%rdi), %rdi
callq 0x11685
movq 0x157b0(%rip), %rsi     # 0x1b148
movq %rax, %rdi
xorl %edx, %edx
callq 0x11aba
movq %rax, 0x8(%rsp)
movq 0x30(%rbx), %rdi
callq 0x115e6
movq %rax, %rdi
callq 0x96d9
movq %rax, %r12
leaq 0xea05(%rip), %rdi      # 0x143c7
callq 0xea73
movq %r12, %rdi
movq %rax, %rsi
xorl %edx, %edx
callq 0x11aba
movq %rax, %rbp
movq %rax, %r15
leaq 0xe9eb(%rip), %rdi      # 0x143cc
callq 0xea73
movq %r12, %rdi
movq %rax, %rsi
xorl %edx, %edx
callq 0x11aba
movq %rax, 0x18(%rsp)
movq 0x15741(%rip), %rsi     # 0x1b140
movq %r12, %rdi
xorl %edx, %edx
callq 0x11aba
movq %rax, 0x10(%rsp)
movq 0x15743(%rip), %rsi     # 0x1b158
movq %r12, %rdi
xorl %edx, %edx
callq 0x11aba
movq %rax, %r13
leaq 0xe9b8(%rip), %rax      # 0x143e1
leaq 0x20(%rsp), %rdi
movq %rax, (%rdi)
leaq 0x15950(%rip), %r14     # 0x1b388
movq (%r14), %rax
movq 0x50(%rax), %rax
movl 0x8(%rax), %ecx
movl %ecx, 0x8(%rdi)
movl $0x3a1, 0xc(%rdi)       # imm = 0x3A1
leaq 0x110b1(%rip), %r12     # 0x16b04
movq %r12, 0x10(%rdi)
leaq 0x156d2(%rip), %rcx     # 0x1b130
movq %rcx, 0x18(%rdi)
movq %rax, 0x20(%rdi)
callq 0x1339a
leaq 0x15ebe(%rip), %rax     # 0x1b930
cmpl $0x0, (%rax)
je 0x5b05
movq (%r14), %rax
movq 0x50(%rax), %rax
movq %r12, 0x10(%rax)
movq %r12, %rdi
callq 0x12afc
testl %eax, %eax
je 0x5ab9
movq (%r14), %rax
movq 0x50(%rax), %rax
movl $0x3a2, 0xc(%rax)       # imm = 0x3A2
movq %r15, %rdi
callq 0xb5b4
leaq 0xe940(%rip), %rdi      # 0x143ef
movq %rax, %rsi
xorl %eax, %eax
callq 0x1340b
leaq 0x15e70(%rip), %rax     # 0x1b930
cmpl $0x0, (%rax)
je 0x5b05
movq (%r14), %rax
movq 0x50(%rax), %rax
movq %r12, 0x10(%rax)
movq %r12, %rdi
callq 0x12afc
testl %eax, %eax
je 0x5b05
movq (%r14), %rax
movq 0x50(%rax), %rax
movl $0x3a3, 0xc(%rax)       # imm = 0x3A3
movq 0x8(%rsp), %rdi
callq 0xb5b4
leaq 0xea9a(%rip), %rdi      # 0x14595
movq %rax, %rsi
xorl %eax, %eax
callq 0x1340b
testq %rbp, %rbp
sete %al
andq $0x3, %rbp
setne %cl
orb %al, %cl
je 0x5b2d
cmpl $0x2, %ebp
jne 0x5b40
movq %r13, %rdi
movq %r15, %rsi
movq 0x8(%rsp), %rdx
callq 0x11b2c
jmp 0x5b3d
movq %r13, %rdi
movq %r15, %rsi
movq 0x8(%rsp), %rdx
callq 0x11c41
movq %rax, %r13
leaq 0x15de9(%rip), %rax     # 0x1b930
cmpl $0x0, (%rax)
movq 0x18(%rsp), %r15
je 0x5b8f
movq (%r14), %rax
movq 0x50(%rax), %rax
movq %r12, 0x10(%rax)
movq %r12, %rdi
callq 0x12afc
testl %eax, %eax
je 0x5b8f
movq (%r14), %rax
movq 0x50(%rax), %rax
movl $0x3ab, 0xc(%rax)       # imm = 0x3AB
movq %r15, %rdi
callq 0xb5b4
leaq 0xe872(%rip), %rdi      # 0x143f7
movq %rax, %rsi
xorl %eax, %eax
callq 0x1340b
movq 0x155c2(%rip), %rsi     # 0x1b158
leaq 0x1575b(%rip), %rdi     # 0x1b2f8
movq %r13, %rdx
callq 0x11b2c
movq 0x15594(%rip), %rsi     # 0x1b140
movq %rax, %rdi
movq 0x10(%rsp), %rdx
callq 0x11b2c
movq 0x15588(%rip), %rsi     # 0x1b148
movq %rax, %rdi
movq %r15, %rdx
callq 0x11b2c
movq 0x155ae(%rip), %rsi     # 0x1b180
movq %rbx, %rdi
movq %rax, %rdx
callq 0xa30f
leaq 0x20(%rsp), %rdi
movl $0x3b1, 0xc(%rdi)       # imm = 0x3B1
callq 0x1351f
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq