// File: /workspace/github_c_makefile_star2_O1/dalnefre[P]kernel_abe/atom.c
// Function: test_number
void
test_number()
{
	int i;
	int j;
	CONS* p;
	
	DBUG_ENTER("test_number");
	TRACE(printf("--test_number--\n"));

	j = 0;
	p = NUMBER(j);
	DBUG_PRINT("", ("NUMBER(%d)=16#%08lx", j, (ulint)p));
	assert(numberp(p));
	i = MK_INT(p);
	assert(0 == i);
	assert(!nilp(p));
	assert(!consp(p));
	assert(!atomp(p));
#if NUMBER_IS_FUNC
#if TYPETAG_USES_2LSB
	assert(funcp(p));
	assert(!boolp(p));
#endif
#else
	assert(!funcp(p));
#endif

	j = 1;
	p = NUMBER(j);
	DBUG_PRINT("", ("NUMBER(%d)=16#%08lx", j, (ulint)p));
	assert(numberp(p));
	i = MK_INT(p);
	assert(i == j);
	assert(!nilp(p));
	assert(!consp(p));
	assert(!atomp(p));
#if NUMBER_IS_FUNC
	assert(funcp(p));
#else
	assert(!funcp(p));
#endif
	assert(!boolp(p));

	j = -1;
	p = NUMBER(j);
	DBUG_PRINT("", ("NUMBER(%d)=16#%08lx", j, (ulint)p));
	assert(numberp(p));
	i = MK_INT(p);
	assert(i == j);
	assert(!nilp(p));
	assert(!consp(p));
	assert(!atomp(p));
#if NUMBER_IS_FUNC
	assert(funcp(p));
#else
	assert(!funcp(p));
#endif
	assert(!boolp(p));

	j = 0x07FFFFFF;
	p = NUMBER(j);
	DBUG_PRINT("", ("NUMBER(%d)=16#%08lx", j, (ulint)p));
	assert(numberp(p));
	i = MK_INT(p);
	assert(i == j);

	j = -j;
	p = NUMBER(j);
	DBUG_PRINT("", ("NUMBER(%d)=16#%08lx", j, (ulint)p));
	assert(numberp(p));
	i = MK_INT(p);
	assert(i == j);
	
	DBUG_RETURN;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x28, %rsp
leaq 0x65a6(%rip), %rax      # 0x1da3e
movq %rsp, %rdi
movq %rax, (%rdi)
leaq 0xbe8b(%rip), %r14      # 0x23330
movq (%r14), %rax
movq 0x50(%rax), %rax
movl 0x8(%rax), %ecx
movl %ecx, 0x8(%rdi)
movl $0xad, 0xc(%rdi)
leaq 0x4e8a(%rip), %rbx      # 0x1c34a
movq %rbx, 0x10(%rdi)
leaq 0xbd05(%rip), %rcx      # 0x231d0
movq %rcx, 0x18(%rdi)
movq %rax, 0x20(%rdi)
callq 0x1b912
leaq 0x65a0(%rip), %rdi      # 0x1da7f
callq 0x20a0
leaq 0xc445(%rip), %r15      # 0x23930
cmpl $0x0, (%r15)
je 0x1752b
movq (%r14), %rax
movq 0x50(%rax), %rax
movq %rbx, 0x10(%rax)
movq %rbx, %rdi
callq 0x1b084
testl %eax, %eax
je 0x1752b
movq (%r14), %rax
movq 0x50(%rax), %rax
movl $0xb2, 0xc(%rax)
leaq 0x652d(%rip), %rdi      # 0x1da4a
movl $0x3, %edx
xorl %esi, %esi
xorl %eax, %eax
callq 0x1b983
leaq 0xbd6e(%rip), %r12      # 0x232a0
cmpq $0x3, %r12
je 0x17671
cmpl $0x0, (%r15)
je 0x1757f
movq (%r14), %rax
movq 0x50(%rax), %rax
movq %rbx, 0x10(%rax)
movq %rbx, %rdi
callq 0x1b084
testl %eax, %eax
je 0x1757f
movq (%r14), %rax
movq 0x50(%rax), %rax
movl $0xc4, 0xc(%rax)
leaq 0x64dc(%rip), %rdi      # 0x1da4a
movl $0x7, %edx
movl $0x1, %esi
xorl %eax, %eax
callq 0x1b983
cmpq $0x7, %r12
je 0x17690
cmpl $0x0, (%r15)
je 0x175ce
movq (%r14), %rax
movq 0x50(%rax), %rax
movq %rbx, 0x10(%rax)
movq %rbx, %rdi
callq 0x1b084
testl %eax, %eax
je 0x175ce
movq (%r14), %rax
movq 0x50(%rax), %rax
movl $0xd4, 0xc(%rax)
leaq 0x648f(%rip), %rdi      # 0x1da4a
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
movq $-0x1, %rdx
xorl %eax, %eax
callq 0x1b983
cmpl $0x0, (%r15)
je 0x17611
movq (%r14), %rax
movq 0x50(%rax), %rax
movq %rbx, 0x10(%rax)
movq %rbx, %rdi
callq 0x1b084
testl %eax, %eax
je 0x17611
movq (%r14), %rax
movq 0x50(%rax), %rax
movl $0xe4, 0xc(%rax)
leaq 0x644a(%rip), %rdi      # 0x1da4a
movl $0x1fffffff, %edx       # imm = 0x1FFFFFFF
movl $0x7ffffff, %esi        # imm = 0x7FFFFFF
xorl %eax, %eax
callq 0x1b983
cmpl $0x0, (%r15)
je 0x17656
movq (%r14), %rax
movq 0x50(%rax), %rax
movq %rbx, 0x10(%rax)
movq %rbx, %rdi
callq 0x1b084
testl %eax, %eax
je 0x17656
movq (%r14), %rax
movq 0x50(%rax), %rax
movl $0xeb, 0xc(%rax)
leaq 0x6407(%rip), %rdi      # 0x1da4a
movl $0xf8000001, %esi       # imm = 0xF8000001
movq $-0x1ffffff9, %rdx      # imm = 0xE0000007
xorl %eax, %eax
callq 0x1b983
movq %rsp, %rdi
movl $0xf0, 0xc(%rdi)
callq 0x1ba97
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
leaq 0x58b8(%rip), %rdi      # 0x1cf30
leaq 0x62e9(%rip), %rsi      # 0x1d968
leaq 0x63d8(%rip), %rcx      # 0x1da5e
movl $0xb6, %edx
callq 0x2100
leaq 0x5899(%rip), %rdi      # 0x1cf30
leaq 0x62ca(%rip), %rsi      # 0x1d968
leaq 0x63b9(%rip), %rcx      # 0x1da5e
movl $0xc8, %edx
callq 0x2100
nop