// File: /workspace/github_cpp_makefile_star2_O1/Nallantli[P]Rossa/main/rossa/node/node.cpp
// Function: SwitchNode::genParser() const
ptr_instruction_t SwitchNode::genParser() const
{
	std::map<symbol_t, size_t> cases_solved;
	std::map<ptr_instruction_t, size_t> cases_unsolved;
	std::vector<ptr_instruction_t> goto_cases;
	trace_t stack_trace;
	for (auto &e : this->cases)
	{
		if (e.first->isConst())
		{
			object_t newScope(static_cast<hash_ull>(0));
			trace_t stack_trace;
			auto key = e.first->genParser()->evaluate(&newScope, stack_trace);
			cases_solved[key] = e.second;
		}
		else
		{
			cases_unsolved[e.first->genParser()] = e.second;
		}
	}
	for (auto &e : this->gotos)
	{
		goto_cases.push_back(e->genParser());
	}
	if (elses)
		return std::make_shared<SwitchI>(switchs->genParser(), cases_solved, cases_unsolved, goto_cases, elses->genParser(), token);
	return std::make_shared<SwitchI>(switchs->genParser(), cases_solved, cases_unsolved, goto_cases, nullptr, token);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xe8, %rsp
movq %rdi, 0x28(%rsp)
leaq 0xc0(%rsp), %rax
xorl %ecx, %ecx
movl %ecx, (%rax)
movq %rcx, 0x8(%rax)
movq %rax, 0x10(%rax)
movq %rax, 0x18(%rax)
movq %rcx, 0x20(%rax)
leaq 0x90(%rsp), %rax
movl %ecx, (%rax)
movq %rcx, 0x8(%rax)
movq %rax, 0x10(%rax)
movq %rax, 0x18(%rax)
movq %rcx, 0x20(%rax)
movq %rcx, 0x60(%rsp)
xorps %xmm0, %xmm0
movaps %xmm0, 0x50(%rsp)
movq %rcx, 0x80(%rsp)
movaps %xmm0, 0x70(%rsp)
movq 0xd0(%rsi), %r15
movq %rsi, 0x68(%rsp)
leaq 0xc0(%rsi), %rbp
cmpq %rbp, %r15
je 0x6584f
leaq 0x18(%rsp), %r12
movq %rsp, %r13
leaq 0x40(%rsp), %rbx
movq 0x20(%r15), %rdi
movq (%rdi), %rax
callq *0x8(%rax)
testb %al, %al
je 0x65809
movq $0x0, (%rsp)
movq %r12, %rdi
movq %r13, %rsi
callq 0x3cf06
xorps %xmm0, %xmm0
movaps %xmm0, (%rsp)
movq $0x0, 0x10(%rsp)
movq 0x20(%r15), %rsi
movq (%rsi), %rax
leaq 0x30(%rsp), %rdi
callq *(%rax)
movq 0x30(%rsp), %rsi
movq (%rsi), %rax
movq %rbx, %rdi
movq %r12, %rdx
movq %r13, %rcx
callq *(%rax)
movq 0x38(%rsp), %rdi
testq %rdi, %rdi
je 0x657d8
callq 0x1e6ee
movq 0x30(%r15), %r14
leaq 0xb8(%rsp), %rdi
movq %rbx, %rsi
callq 0x67ace
movq %r14, (%rax)
movq %rbx, %rdi
callq 0x404da
movq %r13, %rdi
callq 0x1d77a
movq %r12, %rdi
callq 0x3d168
jmp 0x6583b
movq 0x30(%r15), %r14
movq 0x20(%r15), %rsi
movq (%rsi), %rax
movq %r13, %rdi
callq *(%rax)
leaq 0x88(%rsp), %rdi
movq %r13, %rsi
callq 0x67b60
movq %r14, (%rax)
movq 0x8(%rsp), %rdi
testq %rdi, %rdi
je 0x6583b
callq 0x1e6ee
movq %r15, %rdi
callq 0x104b0
movq %rax, %r15
cmpq %rbp, %rax
jne 0x65773
movq 0x68(%rsp), %r14
movq 0xe8(%r14), %r12
movq 0xf0(%r14), %r13
cmpq %r13, %r12
je 0x6589e
movq %rsp, %rbx
leaq 0x50(%rsp), %r15
movq (%r12), %rsi
movq (%rsi), %rax
movq %rbx, %rdi
callq *(%rax)
movq %r15, %rdi
movq %rbx, %rsi
callq 0x68108
movq 0x8(%rsp), %rdi
testq %rdi, %rdi
je 0x65895
callq 0x1e6ee
addq $0x10, %r12
cmpq %r13, %r12
jne 0x6586f
cmpq $0x0, 0x100(%r14)
je 0x6595d
movq 0xa8(%r14), %rsi
movq (%rsi), %rax
leaq 0x18(%rsp), %rdi
callq *(%rax)
movq 0x100(%r14), %rsi
movq (%rsi), %rax
leaq 0x40(%rsp), %rbx
movq %rbx, %rdi
callq *(%rax)
addq $0x28, %r14
leaq 0x8(%rsp), %rdi
movq $0x0, -0x8(%rdi)
subq $0x8, %rsp
leaq 0x58(%rsp), %rax
leaq 0x8(%rsp), %rsi
leaq 0x38(%rsp), %rdx
leaq 0x20(%rsp), %rcx
leaq 0xc0(%rsp), %r8
leaq 0x90(%rsp), %r9
pushq %r14
pushq %rbx
pushq %rax
callq 0x6e19e
addq $0x20, %rsp
movq (%rsp), %rax
movq 0x28(%rsp), %rbx
movq %rax, (%rbx)
xorl %eax, %eax
movq %rax, 0x8(%rbx)
movq 0x8(%rsp), %rcx
movq %rax, 0x8(%rsp)
movq %rcx, 0x8(%rbx)
movq %rax, (%rsp)
movq 0x48(%rsp), %rdi
testq %rdi, %rdi
je 0x6594a
callq 0x1e6ee
movq 0x20(%rsp), %rdi
testq %rdi, %rdi
je 0x659ee
jmp 0x659e9
movq 0xa8(%r14), %rsi
movq (%rsi), %rax
leaq 0x18(%rsp), %rdi
callq *(%rax)
movq 0x28(%rsp), %rbx
xorl %eax, %eax
leaq 0x40(%rsp), %r10
movq %rax, (%r10)
addq $0x28, %r14
leaq 0x8(%rsp), %rdi
movq %rax, -0x8(%rdi)
subq $0x8, %rsp
leaq 0x58(%rsp), %rax
leaq 0x8(%rsp), %rsi
leaq 0x38(%rsp), %rdx
leaq 0x20(%rsp), %rcx
leaq 0xc0(%rsp), %r8
leaq 0x90(%rsp), %r9
pushq %r14
pushq %r10
pushq %rax
callq 0x6e2a6
addq $0x20, %rsp
movq (%rsp), %rax
movq %rax, (%rbx)
xorl %eax, %eax
movq %rax, 0x8(%rbx)
movq 0x8(%rsp), %rcx
movq %rax, 0x8(%rsp)
movq %rcx, 0x8(%rbx)
movq %rax, (%rsp)
movq 0x20(%rsp), %rdi
testq %rdi, %rdi
je 0x659ee
callq 0x1e6ee
leaq 0x70(%rsp), %rdi
callq 0x1d77a
leaq 0x50(%rsp), %rdi
callq 0x677d6
leaq 0x88(%rsp), %rdi
callq 0x67e1a
leaq 0xb8(%rsp), %rdi
callq 0x67e88
movq %rbx, %rax
addq $0xe8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
movq 0x20(%rsp), %rdi
testq %rdi, %rdi
je 0x65ad7
jmp 0x65acd
jmp 0x65ad4
movq %rax, %rbx
movq 0x48(%rsp), %rdi
testq %rdi, %rdi
je 0x65a63
callq 0x1e6ee
jmp 0x65a63
movq %rax, %rbx
movq 0x20(%rsp), %rdi
testq %rdi, %rdi
je 0x65ad7
jmp 0x65acd
jmp 0x65ad4
jmp 0x65ad4
jmp 0x65ad4
movq %rax, %rbx
movq 0x38(%rsp), %rdi
testq %rdi, %rdi
je 0x65aaa
callq 0x1e6ee
jmp 0x65aaa
movq %rax, %rbx
movq 0x8(%rsp), %rdi
testq %rdi, %rdi
je 0x65ad7
jmp 0x65acd
movq %rax, %rbx
jmp 0x65aaa
movq %rax, %rbx
leaq 0x40(%rsp), %rdi
callq 0x404da
movq %rsp, %rdi
callq 0x1d77a
leaq 0x18(%rsp), %rdi
callq 0x3d168
jmp 0x65ad7
jmp 0x65ad4
movq %rax, %rbx
movq 0x8(%rsp), %rdi
testq %rdi, %rdi
je 0x65ad7
callq 0x1e6ee
jmp 0x65ad7
movq %rax, %rbx
leaq 0x70(%rsp), %rdi
callq 0x1d77a
leaq 0x50(%rsp), %rdi
callq 0x677d6
leaq 0x88(%rsp), %rdi
callq 0x67e1a
leaq 0xb8(%rsp), %rdi
callq 0x67e88
movq %rbx, %rdi
callq 0x106f0
nop