// File: /workspace/github_c_makefile_star2_O0/dalnefre[P]kernel_abe/reduce.c
// Function: apply_if
BEH_DECL(apply_if)
{
	CONS* msg = WHAT;
	CONS* expr = map_get(msg, expr_symbol);
	CONS* state = MINE;
	CONS* form = map_get(state, form_symbol);
	CONS* cont = map_get(state, cont_symbol);
	CONS* env = map_get(state, env_symbol);
	
	DBUG_ENTER("apply_if");
	if (expr == true_symbol) {
		expr = car(form);
	} else if (expr == false_symbol) {
		expr = car(cdr(form));
	} else {	/* error */
		SEND(an_error, ATOM("if: predicate must reduce to TRUE or FALSE"));
		SEND(cont, map_put(NIL, expr_symbol, undefined_symbol));
		DBUG_RETURN;
	}
	DBUG_PRINT("", ("expr=%s", cons_to_str(expr)));
	msg = NIL;
	msg = map_put(msg, env_symbol, env);
	msg = map_put(msg, cont_symbol, cont);
	msg = map_put(msg, expr_symbol, expr);
	SEND(a_reduce, msg);
	DBUG_RETURN;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x80, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
movq 0x30(%rax), %rdi
callq 0x16990
movq %rax, -0x10(%rbp)
movq -0x10(%rbp), %rdi
movq 0x1b5dd(%rip), %rsi     # 0x20148
xorl %eax, %eax
movl %eax, %edx
callq 0x171b0
movq %rax, -0x18(%rbp)
movq -0x8(%rbp), %rax
movq 0x30(%rax), %rdi
callq 0x16800
movq %rax, %rdi
callq 0xba80
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rdi
movq 0x1b5b4(%rip), %rsi     # 0x20150
xorl %eax, %eax
movl %eax, %edx
callq 0x171b0
movq %rax, -0x28(%rbp)
movq -0x20(%rbp), %rdi
movq 0x1b58c(%rip), %rsi     # 0x20140
xorl %eax, %eax
movl %eax, %edx
callq 0x171b0
movq %rax, -0x30(%rbp)
movq -0x20(%rbp), %rdi
movq 0x1b58c(%rip), %rsi     # 0x20158
xorl %eax, %eax
movl %eax, %edx
callq 0x171b0
movq %rax, -0x38(%rbp)
leaq 0x1569c(%rip), %rax     # 0x1a27c
movq %rax, -0x60(%rbp)
leaq 0x1b79d(%rip), %rax     # 0x20388
movq (%rax), %rax
movq 0x50(%rax), %rax
movl 0x8(%rax), %eax
movl %eax, -0x58(%rbp)
movl $0x240, -0x54(%rbp)     # imm = 0x240
leaq 0x180aa(%rip), %rax     # 0x1ccb0
movq %rax, -0x50(%rbp)
leaq 0x1b51f(%rip), %rax     # 0x20130
movq %rax, -0x48(%rbp)
leaq 0x1b76c(%rip), %rax     # 0x20388
movq (%rax), %rax
movq 0x50(%rax), %rax
movq %rax, -0x40(%rbp)
leaq -0x60(%rbp), %rdi
callq 0x19910
movq -0x18(%rbp), %rax
cmpq 0x1b535(%rip), %rax     # 0x20170
jne 0x4c4f
movq -0x28(%rbp), %rdi
callq 0x16800
movq %rax, -0x18(%rbp)
jmp 0x4cf3
movq -0x18(%rbp), %rax
cmpq 0x1b51e(%rip), %rax     # 0x20178
jne 0x4c73
movq -0x28(%rbp), %rdi
callq 0x16990
movq %rax, %rdi
callq 0x16800
movq %rax, -0x18(%rbp)
jmp 0x4cf1
movq -0x8(%rbp), %rax
movq %rax, -0x80(%rbp)
movq 0x1b4de(%rip), %rax     # 0x20160
movq %rax, -0x78(%rbp)
leaq 0x155f8(%rip), %rdi     # 0x1a285
callq 0x12b60
movq -0x80(%rbp), %rdi
movq -0x78(%rbp), %rsi
movq %rax, %rdx
callq 0xcc90
movq -0x8(%rbp), %rax
movq %rax, -0x70(%rbp)
movq -0x30(%rbp), %rax
movq %rax, -0x68(%rbp)
movq 0x1b48f(%rip), %rsi     # 0x20148
movq 0x1b4a8(%rip), %rdx     # 0x20168
leaq 0x1b631(%rip), %rdi     # 0x202f8
callq 0x172a0
movq -0x70(%rbp), %rdi
movq -0x68(%rbp), %rsi
movq %rax, %rdx
callq 0xcc90
movl $0x248, -0x54(%rbp)     # imm = 0x248
leaq -0x60(%rbp), %rdi
callq 0x19ae0
jmp 0x4dd3
jmp 0x4cf3
jmp 0x4cf5
leaq 0x1bc34(%rip), %rax     # 0x20930
cmpl $0x0, (%rax)
je 0x4d5a
leaq 0x1b680(%rip), %rax     # 0x20388
movq (%rax), %rax
movq 0x50(%rax), %rax
leaq 0x17f9a(%rip), %rcx     # 0x1ccb0
movq %rcx, 0x10(%rax)
leaq 0x17f8f(%rip), %rdi     # 0x1ccb0
callq 0x18d20
cmpl $0x0, %eax
je 0x4d5a
leaq 0x1b656(%rip), %rax     # 0x20388
movq (%rax), %rax
movq 0x50(%rax), %rax
movl $0x24a, 0xc(%rax)       # imm = 0x24A
movq -0x18(%rbp), %rdi
callq 0xe6d0
movq %rax, %rsi
leaq 0x15840(%rip), %rdi     # 0x1a593
movb $0x0, %al
callq 0x199c0
jmp 0x4d5c
leaq 0x1b595(%rip), %rax     # 0x202f8
movq %rax, -0x10(%rbp)
movq -0x10(%rbp), %rdi
movq 0x1b3e6(%rip), %rsi     # 0x20158
movq -0x38(%rbp), %rdx
callq 0x172a0
movq %rax, -0x10(%rbp)
movq -0x10(%rbp), %rdi
movq 0x1b3b6(%rip), %rsi     # 0x20140
movq -0x30(%rbp), %rdx
callq 0x172a0
movq %rax, -0x10(%rbp)
movq -0x10(%rbp), %rdi
movq 0x1b3a6(%rip), %rsi     # 0x20148
movq -0x18(%rbp), %rdx
callq 0x172a0
movq %rax, -0x10(%rbp)
movq -0x8(%rbp), %rdi
movq 0x1b3c6(%rip), %rsi     # 0x20180
movq -0x10(%rbp), %rdx
callq 0xcc90
movl $0x250, -0x54(%rbp)     # imm = 0x250
leaq -0x60(%rbp), %rdi
callq 0x19ae0
addq $0x80, %rsp
popq %rbp
retq
nopl (%rax)