// File: /workspace/github_cpp_makefile_star2_O1/bonetblai[P]mdp-engine/ctp3/../engine/dispatcher.h
// Function: Dispatcher::dispatcher_t<state_t>::solve(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, Algorithm::algorithm_t<state_t> const&, state_t const&, Dispatcher::dispatcher_t<state_t>::solve_result_t&) const
void dispatcher_t<T>::solve(const std::string &name, const Algorithm::algorithm_t<T> &algorithm, const T &s, solve_result_t &result) const {
    std::cout << "dispatcher: solve: " << name << std::endl;
    const Problem::problem_t<T> &problem = algorithm.problem();

    result.name_ = name;
    result.algorithm_ = &algorithm;
    result.state_ = s;
    result.seed_ = algorithm.seed();
    Random::set_seed(result.seed_);

    float start_time = Utils::read_time_in_seconds();
    Problem::hash_t<T> *hash = new Problem::hash_t<T>(problem);
    algorithm.solve(s, *hash);
    float end_time = Utils::read_time_in_seconds();

    // expansions from problem
    result.problem_expansions_ = problem.expansions();

    // extract stats from hash
    result.hash_ = hash;

    // time stats
    result.time_raw_ = end_time - start_time;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xa0, %rsp
movq %r8, %rbx
movq %rcx, %r14
movq %rdx, %r15
movq %rsi, %r12
movq 0x3551f(%rip), %r13     # 0x3efd8
leaq 0x266ca(%rip), %rsi     # 0x3018a
movl $0x13, %edx
movq %r13, %rdi
callq 0x62e0
movq (%r12), %rsi
movq 0x8(%r12), %rdx
movq %r13, %rdi
callq 0x62e0
movq %rax, %r13
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %r13, %rdi
movl $0xa, %esi
callq 0x6270
movsbl %al, %esi
movq %r13, %rdi
callq 0x6040
movq %rax, %rdi
callq 0x61e0
movq 0x8(%r15), %r13
leaq 0x70(%rbx), %rdi
movq %r12, %rsi
callq 0x6170
movq %r15, 0x90(%rbx)
movq %rbx, %rdi
movq %r14, %rsi
callq 0xd546
movslq 0x18(%r15), %rdi
movl %edi, 0x98(%rbx)
leaq 0x10(%rsp), %r12
movw %di, 0x4(%r12)
movw %di, 0x2(%r12)
movw %di, (%r12)
callq 0x63f0
movq %r12, %rdi
callq 0x6120
leaq 0x10(%rsp), %r12
xorl %edi, %edi
movq %r12, %rsi
callq 0x6190
cvtsi2ssq (%r12), %xmm0
movss %xmm0, 0x8(%rsp)
xorps %xmm0, %xmm0
cvtsi2ssq 0x8(%r12), %xmm0
movss %xmm0, 0xc(%rsp)
movl $0xffffffff, %edi       # imm = 0xFFFFFFFF
movq %r12, %rsi
callq 0x6190
xorps %xmm0, %xmm0
cvtsi2ssq (%r12), %xmm0
addss 0x8(%rsp), %xmm0
movss %xmm0, 0x8(%rsp)
xorps %xmm0, %xmm0
cvtsi2ssq 0x8(%r12), %xmm0
addss 0xc(%rsp), %xmm0
movss %xmm0, 0xc(%rsp)
movl $0x58, %edi
callq 0x6290
movq %rax, %r12
addq $0x38, %rax
movq %rax, 0x8(%r12)
movq $0x1, 0x10(%r12)
xorps %xmm0, %xmm0
movups %xmm0, 0x18(%r12)
movl $0x3f800000, 0x28(%r12) # imm = 0x3F800000
movups %xmm0, 0x30(%r12)
movq $0x0, 0x40(%r12)
leaq 0x349d7(%rip), %rax     # 0x3e5d8
movq %rax, (%r12)
movq %r13, 0x48(%r12)
movl $0x0, 0x50(%r12)
movq (%r15), %rax
movq %r15, %rdi
movq %r14, %rsi
movq %r12, %rdx
callq *0x28(%rax)
leaq 0x10(%rsp), %r14
xorl %edi, %edi
movq %r14, %rsi
callq 0x6190
xorps %xmm0, %xmm0
cvtsi2ssq (%r14), %xmm0
subss 0x8(%rsp), %xmm0
movss %xmm0, 0x8(%rsp)
xorps %xmm0, %xmm0
cvtsi2ssq 0x8(%r14), %xmm0
subss 0xc(%rsp), %xmm0
movss %xmm0, 0xc(%rsp)
movl $0xffffffff, %edi       # imm = 0xFFFFFFFF
movq %r14, %rsi
callq 0x6190
xorps %xmm0, %xmm0
cvtsi2ssq (%r14), %xmm0
addss 0x8(%rsp), %xmm0
cvtsi2ssq 0x8(%r14), %xmm1
addss 0xc(%rsp), %xmm1
movl 0x10(%r13), %eax
movl %eax, 0x9c(%rbx)
movq %r12, 0xa0(%rbx)
mulss 0x2336a(%rip), %xmm1    # 0x2d004
addss %xmm0, %xmm1
movss %xmm1, 0xb0(%rbx)
addq $0xa0, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
nop