// File: /workspace/github_cpp_makefile_star2_O3/Nallantli[P]Rossa/main/rossa/node/node.cpp
// Function: MapNode::fold(std::vector<std::pair<std::vector<unsigned long long, std::allocator<unsigned long long>>, symbol_t>, std::allocator<std::pair<std::vector<unsigned long long, std::allocator<unsigned long long>>, symbol_t>>> const&) const
const ptr_node_t MapNode::fold(const std::vector<std::pair<std::vector<hash_ull>, symbol_t>> &consts) const
{
	if (isConst())
	{
		auto i = genParser();
		object_t newScope(static_cast<hash_ull>(0));
		trace_t stack_trace;
		auto r = i->evaluate(&newScope, stack_trace);
		return std::make_shared<ContainerNode>(path, r, token);
	}

	std::vector<std::pair<std::string, ptr_node_t>> nargs;
	for (auto &c : args)
		nargs.push_back({c.first, c.second->fold(consts)});
	return std::make_shared<MapNode>(path, nargs, token);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xa8, %rsp
movq %rdx, %r15
movq %rsi, %r14
movq %rdi, %rbx
movq (%rsi), %rax
movq %rsi, %rdi
callq *0x8(%rax)
testb %al, %al
je 0x647b7
movq (%r14), %rax
leaq 0x20(%rsp), %rdi
movq %r14, %rsi
callq *(%rax)
leaq 0x40(%rsp), %rsi
movq $0x0, (%rsi)
leaq 0x10(%rsp), %rdi
callq 0x3c8de
xorps %xmm0, %xmm0
leaq 0x40(%rsp), %rcx
movaps %xmm0, (%rcx)
movq $0x0, 0x10(%rcx)
movq 0x20(%rsp), %rsi
movq (%rsi), %rax
leaq 0x80(%rsp), %rdi
leaq 0x10(%rsp), %rdx
callq *(%rax)
leaq 0x8(%r14), %rcx
addq $0x28, %r14
leaq 0x98(%rsp), %rdi
movq $0x0, -0x8(%rdi)
leaq 0x90(%rsp), %rsi
leaq 0xf(%rsp), %rdx
leaq 0x80(%rsp), %r8
movq %r14, %r9
callq 0x676e2
movaps 0x90(%rsp), %xmm0
movups %xmm0, (%rbx)
leaq 0x80(%rsp), %rdi
callq 0x3fe06
leaq 0x40(%rsp), %rdi
callq 0x1d632
leaq 0x10(%rsp), %rdi
callq 0x3cb40
movq 0x28(%rsp), %rdi
testq %rdi, %rdi
je 0x648a6
callq 0x1e5bc
jmp 0x648a6
movq %rbx, 0x70(%rsp)
xorps %xmm0, %xmm0
movaps %xmm0, 0x20(%rsp)
movq $0x0, 0x30(%rsp)
movq 0xa8(%r14), %r12
movq %r14, 0x78(%rsp)
movq 0xb0(%r14), %r14
cmpq %r14, %r12
je 0x64861
leaq 0x10(%rsp), %r13
leaq 0x40(%rsp), %rbp
leaq 0x20(%rsp), %rbx
movq 0x20(%r12), %rsi
movq (%rsi), %rax
movq %r13, %rdi
movq %r15, %rdx
callq *0x18(%rax)
movq %rbp, %rdi
movq %r12, %rsi
movq %r13, %rdx
callq 0x66ce6
movq %rbx, %rdi
movq %rbp, %rsi
callq 0x6cb8e
movq 0x68(%rsp), %rdi
testq %rdi, %rdi
je 0x6482d
callq 0x1e5bc
movq 0x40(%rsp), %rdi
leaq 0x50(%rsp), %rax
cmpq %rax, %rdi
je 0x64849
movq 0x50(%rsp), %rsi
incq %rsi
callq 0x103d0
movq 0x18(%rsp), %rdi
testq %rdi, %rdi
je 0x64858
callq 0x1e5bc
addq $0x30, %r12
cmpq %r14, %r12
jne 0x647f4
movq 0x78(%rsp), %r9
leaq 0x8(%r9), %rcx
addq $0x28, %r9
leaq 0x48(%rsp), %rdi
movq $0x0, -0x8(%rdi)
leaq 0x40(%rsp), %rsi
leaq 0x10(%rsp), %rdx
leaq 0x20(%rsp), %r8
callq 0x6ccb2
movaps 0x40(%rsp), %xmm0
movq 0x70(%rsp), %rbx
movups %xmm0, (%rbx)
leaq 0x20(%rsp), %rdi
callq 0x370ba
movq %rbx, %rax
addq $0xa8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x648fc
movq %rax, %rbx
leaq 0x80(%rsp), %rdi
callq 0x3fe06
jmp 0x648d2
movq %rax, %rbx
leaq 0x40(%rsp), %rdi
callq 0x1d632
leaq 0x10(%rsp), %rdi
callq 0x3cb40
jmp 0x648eb
movq %rax, %rbx
movq 0x28(%rsp), %rdi
testq %rdi, %rdi
je 0x6492c
callq 0x1e5bc
jmp 0x6492c
movq %rax, %rbx
jmp 0x64922
movq %rax, %rbx
jmp 0x64913
movq %rax, %rbx
leaq 0x40(%rsp), %rdi
callq 0x3708e
movq 0x18(%rsp), %rdi
testq %rdi, %rdi
je 0x64922
callq 0x1e5bc
leaq 0x20(%rsp), %rdi
callq 0x370ba
movq %rbx, %rdi
callq 0x106f0