// File: /workspace/github_cpp_makefile_star2_O1/Nallantli[P]Rossa/main/rossa/instruction/instruction.cpp
// Function: ClassI::evaluate(object_t const*, std::vector<std::pair<token_t, function_t>, std::allocator<std::pair<token_t, function_t>>>&) const
const symbol_t ClassI::evaluate(const object_t *scope, trace_t &stack_trace) const
{
	ptr_instruction_t nbody = body;
	object_t *ex = NULL;
	std::vector<aug_type_t> extensions;
	if (extends)
	{
		const symbol_t e = extends->evaluate(scope, stack_trace);
		if (e.getValueType() == value_type_enum::TYPE_NAME)
			extensions.push_back(e.getTypeName(&token, stack_trace).getBase());
		else
		{
			ex = e.getObject(&token, stack_trace);
			if (ex->getType() == scope_type_enum::SCOPE_STATIC)
				throw rossa_error_t(_FAILURE_EXTEND_, token, stack_trace);
			const ptr_instruction_t eb = ex->getBody();
			std::vector<ptr_instruction_t> temp;
			temp.push_back(body);
			temp.push_back(eb);
			nbody = std::make_shared<ScopeI>(temp, token);
		}
	}
	object_t o(scope, type, nbody, key, ex, extensions);
	if (type == scope_type_enum::SCOPE_STATIC)
		nbody->evaluate(&o, stack_trace);
	return scope->createVariable(key, symbol_t::Object(o), &token);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xe8, %rsp
movq %rcx, %r15
movq %rsi, %r14
movq %rdi, %rbx
movq 0xa0(%rsi), %rax
movq %rax, 0x30(%rsp)
movq 0xa8(%rsi), %rax
movq %rax, 0x38(%rsp)
testq %rax, %rax
je 0x7249c
movq 0x44b02(%rip), %rcx     # 0xb6f90
cmpb $0x0, (%rcx)
je 0x72498
incl 0x8(%rax)
jmp 0x7249c
lock
incl 0x8(%rax)
xorps %xmm0, %xmm0
movaps %xmm0, 0xb0(%rsp)
movq $0x0, 0xc0(%rsp)
movq 0xb0(%r14), %rsi
testq %rsi, %rsi
movq %r15, 0xd0(%rsp)
je 0x7257a
movq (%rsi), %rax
leaq 0x40(%rsp), %rdi
movq %rdx, %r12
movq %r15, %rcx
callq *(%rax)
leaq 0x40(%rsp), %rdi
callq 0x41262
cmpl $-0x9, %eax
jne 0x72585
leaq 0x8(%r14), %rdx
leaq 0x60(%rsp), %rdi
leaq 0x40(%rsp), %rsi
movq %r15, %rcx
callq 0x4132c
leaq 0x18(%rsp), %rdi
leaq 0x60(%rsp), %rsi
callq 0x3e0e4
leaq 0xb0(%rsp), %rdi
leaq 0x18(%rsp), %rsi
callq 0x3d6f0
movq %rbx, %r15
movq 0x18(%rsp), %rdi
testq %rdi, %rdi
je 0x7253f
movq 0x28(%rsp), %rsi
subq %rdi, %rsi
callq 0x103d0
leaq 0x90(%rsp), %rbx
movq %rbx, %rdi
callq 0x3743a
movq -0x18(%rbx), %rdi
testq %rdi, %rdi
je 0x72568
movq 0x88(%rsp), %rsi
subq %rdi, %rsi
callq 0x103d0
leaq 0x60(%rsp), %rdi
callq 0x3729c
xorl %r13d, %r13d
jmp 0x72658
movq %rbx, %r15
xorl %r13d, %r13d
jmp 0x72665
leaq 0x8(%r14), %rbp
leaq 0x40(%rsp), %rdi
movq %rbp, %rsi
movq %r15, %rdx
callq 0x411a4
movq %rax, %r13
movq %rax, %rdi
callq 0x3d53e
cmpl $0x2, %eax
je 0x72744
leaq 0x18(%rsp), %rdi
movq %r13, %rsi
callq 0x3d544
leaq 0xa0(%r14), %rsi
xorps %xmm0, %xmm0
leaq 0x60(%rsp), %rdi
movaps %xmm0, (%rdi)
movq $0x0, 0x10(%rdi)
callq 0x77358
leaq 0x60(%rsp), %rdi
leaq 0x18(%rsp), %rsi
callq 0x77358
leaq 0x58(%rsp), %rdi
movq $0x0, -0x8(%rdi)
leaq 0x50(%rsp), %rsi
leaq 0x17(%rsp), %rdx
leaq 0x60(%rsp), %rcx
movq %rbp, %r8
callq 0x682d2
movaps 0x50(%rsp), %xmm0
xorps %xmm1, %xmm1
movaps %xmm1, 0x50(%rsp)
movq 0x38(%rsp), %rdi
movups %xmm0, 0x30(%rsp)
testq %rdi, %rdi
je 0x7262d
callq 0x1e6ee
movq 0x58(%rsp), %rdi
testq %rdi, %rdi
je 0x7263c
callq 0x1e6ee
leaq 0x60(%rsp), %rdi
callq 0x677d6
movq 0x20(%rsp), %rdi
testq %rdi, %rdi
je 0x72655
callq 0x1e6ee
movq %rbx, %r15
leaq 0x40(%rsp), %rdi
callq 0x404da
movq %r12, %rdx
leaq 0x98(%r14), %rbx
leaq 0x90(%r14), %rbp
leaq 0xb0(%rsp), %rax
movq %rax, (%rsp)
leaq 0x60(%rsp), %rdi
leaq 0x30(%rsp), %rcx
movq %rdx, %r12
movq %rdx, %rsi
movq %rbx, %rdx
movq %rbp, %r8
movq %r13, %r9
callq 0x3d024
cmpl $0x2, (%rbx)
jne 0x726ce
movq 0x30(%rsp), %rsi
movq (%rsi), %rax
leaq 0xd8(%rsp), %rdi
leaq 0x60(%rsp), %rdx
movq 0xd0(%rsp), %rcx
callq *(%rax)
leaq 0xd8(%rsp), %rdi
callq 0x404da
leaq 0x18(%rsp), %rdi
leaq 0x60(%rsp), %rsi
callq 0x40482
addq $0x8, %r14
leaq 0x18(%rsp), %rdx
movq %r12, %rdi
movq %rbp, %rsi
movq %r14, %rcx
callq 0x3d512
movq %r15, %rdi
movq %rax, %rsi
callq 0x404c8
leaq 0x18(%rsp), %rdi
callq 0x404da
leaq 0x60(%rsp), %rdi
callq 0x3d168
leaq 0xb0(%rsp), %rdi
callq 0x3729c
movq 0x38(%rsp), %rdi
testq %rdi, %rdi
je 0x7272f
callq 0x1e6ee
movq %r15, %rax
addq $0xe8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl $0xa8, %edi
callq 0x101e0
movq %rax, %r14
leaq 0x70(%rsp), %r13
movq %r13, -0x10(%r13)
leaq 0x15fe2(%rip), %rsi     # 0x88743
leaq 0x16005(%rip), %rdx     # 0x8876d
leaq 0x60(%rsp), %rdi
callq 0x1e7ca
movb $0x1, %r12b
leaq 0x60(%rsp), %rsi
movq %r14, %rdi
movq %rbp, %rdx
movq %r15, %rcx
callq 0x476dc
xorl %r12d, %r12d
leaq 0x4054e(%rip), %rsi     # 0xb2ce0
leaq -0x3afe5(%rip), %rdx    # 0x377b4
movq %r14, %rdi
callq 0x106d0
movq %rax, %rbx
movq 0x60(%rsp), %rdi
cmpq %r13, %rdi
je 0x727c3
movq 0x70(%rsp), %rsi
incq %rsi
callq 0x103d0
jmp 0x727c3
movq %rax, %rbx
movb $0x1, %r12b
testb %r12b, %r12b
je 0x72832
movq %r14, %rdi
callq 0x102d0
jmp 0x72832
jmp 0x72805
jmp 0x7282f
movq %rax, %rbx
movq 0x18(%rsp), %rdi
testq %rdi, %rdi
je 0x727f5
movq 0x28(%rsp), %rsi
subq %rdi, %rsi
callq 0x103d0
jmp 0x727f5
movq %rax, %rbx
leaq 0x60(%rsp), %rdi
callq 0x37330
jmp 0x72832
jmp 0x7282f
jmp 0x72825
movq %rax, %rbx
leaq 0x60(%rsp), %rdi
callq 0x677d6
movq 0x20(%rsp), %rdi
testq %rdi, %rdi
je 0x72832
callq 0x1e6ee
jmp 0x72832
jmp 0x7282a
movq %rax, %rbx
jmp 0x7284b
movq %rax, %rbx
jmp 0x72855
movq %rax, %rbx
leaq 0x40(%rsp), %rdi
callq 0x404da
jmp 0x72855
movq %rax, %rbx
leaq 0x18(%rsp), %rdi
callq 0x404da
leaq 0x60(%rsp), %rdi
callq 0x3d168
leaq 0xb0(%rsp), %rdi
callq 0x3729c
movq 0x38(%rsp), %rdi
testq %rdi, %rdi
je 0x72871
callq 0x1e6ee
movq %rbx, %rdi
callq 0x106f0
nop