LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_cpp_makefile_star2_O1/theuni[P]libbtcnet/src/handler.cpp
// Function: CConnectionHandlerInt::OnIncomingConnection(CConnection const&, int, sockaddr*, int)
void CConnectionHandlerInt::OnIncomingConnection(const CConnection& bind, evutil_socket_t sock, sockaddr* address, int socklen)
{
    assert(IsEventThread());

    ConnID id = GetNextConnectionIndex();
    std::unique_ptr<ConnectionBase> ptr(new CIncomingConn(*this, bind, id, sock, address, socklen));
    {
        auto it = m_connecting.emplace_hint(m_connecting.end(), id, std::move(ptr));
        it->second->Connect();
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x198, %rsp            # imm = 0x198
movl %r8d, %r12d
movq %rcx, %r14
movl %edx, %ebp
movq %rsi, %r13
movq %rdi, %rbx
cmpb $0x1, 0xec(%rdi)
jne 0x9353
movq 0x168(%rbx), %r15
callq 0x4310
cmpq %rax, %r15
jne 0x93ef
movq %rbx, %rdi
callq 0x92ca
movq %rax, 0x18(%rsp)
movl $0x4b8, %edi            # imm = 0x4B8
callq 0x4350
movq %rax, %r15
leaq 0x20(%rsp), %rdi
movq %r13, %rsi
callq 0x75d0
movq 0x18(%rsp), %rcx
movl %r12d, (%rsp)
leaq 0x20(%rsp), %rdx
movq %r15, %rdi
movq %rbx, %rsi
movl %ebp, %r8d
movq %r14, %r9
callq 0x11958
leaq 0x10(%rsp), %r14
movq %r15, (%r14)
leaq 0x20(%rsp), %rdi
callq 0x4e4e
leaq 0x30(%rbx), %rdi
addq $0x38, %rbx
leaq 0x18(%rsp), %rdx
movq %rbx, %rsi
movq %r14, %rcx
callq 0xb11a
movq 0x28(%rax), %rdi
movq (%rdi), %rax
callq *0x10(%rax)
movq 0x10(%rsp), %rdi
testq %rdi, %rdi
je 0x93dd
movq (%rdi), %rax
callq *0x8(%rax)
addq $0x198, %rsp            # imm = 0x198
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x9523(%rip), %rdi      # 0x12919
leaq 0x940e(%rip), %rsi      # 0x1280b
leaq 0x9744(%rip), %rcx      # 0x12b48
movl $0xef, %edx
callq 0x4260
jmp 0x9410
movq %rax, %rbx
movq 0x10(%rsp), %rdi
testq %rdi, %rdi
je 0x9423
movq (%rdi), %rax
callq *0x8(%rax)
movq $0x0, 0x10(%rsp)
jmp 0x9448
movq %rax, %rbx
leaq 0x20(%rsp), %rdi
callq 0x4e4e
jmp 0x9440
movq %rax, %rbx
movq %r15, %rdi
callq 0x4340
movq %rbx, %rdi
callq 0x4640
// File: /workspace/github_cpp_makefile_star2_O1/theuni[P]libbtcnet/src/handler.cpp
// Function: CConnectionHandlerInt::OnListenFailure(long, CConnection const&)
void CConnectionHandlerInt::OnListenFailure(ConnID id, const CConnection& bind)
{
    assert(IsEventThread());
    m_interface.OnBindFailure(bind);
    optional_lock(m_bind_mutex, m_enable_threading);
    m_binds.erase(id);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdx, %rbx
movq %rdi, %r14
movq %rsi, (%rsp)
cmpb $0x1, 0xec(%rdi)
jne 0x947b
movq 0x168(%r14), %r15
callq 0x4310
cmpq %rax, %r15
jne 0x94dd
movq 0xc0(%r14), %rdi
movq (%rdi), %rax
movq %rbx, %rsi
callq *0x18(%rax)
leaq 0x118(%r14), %rbx
movb 0xec(%r14), %bpl
cmpb $0x1, %bpl
jne 0x94ab
movq %rbx, %rdi
callq 0x44f0
testl %eax, %eax
jne 0x94fc
addq $0x60, %r14
movq %rsp, %rsi
movq %r14, %rdi
callq 0xb358
movq %r14, %rdi
movq %rax, %rsi
callq 0xb3d4
testb %bpl, %bpl
je 0x94d2
movq %rbx, %rdi
callq 0x42c0
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
leaq 0x9435(%rip), %rdi      # 0x12919
leaq 0x9320(%rip), %rsi      # 0x1280b
leaq 0x96b2(%rip), %rcx      # 0x12ba4
movl $0xfb, %edx
callq 0x4260
movl %eax, %edi
callq 0x4280
movq %rax, %r14
testb %bpl, %bpl
je 0x9513
movq %rbx, %rdi
callq 0x42c0
movq %r14, %rdi
callq 0x4640
nop
// File: /workspace/github_cpp_makefile_star2_O1/theuni[P]libbtcnet/src/handler.cpp
// Function: CConnectionHandlerInt::OnIncomingConnected(long, CConnection const&, CConnection const&)
void CConnectionHandlerInt::OnIncomingConnected(ConnID id, const CConnection& conn, const CConnection& resolved_conn)
{
    assert(IsEventThread());
    DEBUG_PRINT(LOGVERBOSE, "id:", id);
    auto it = m_connecting.find(id);
    assert(it != m_connecting.end());
    std::unique_ptr<ConnectionBase> moved(nullptr);
    it->second.swap(moved);
    m_connecting.erase(it);

    if (!m_interface.OnIncomingConnection(id, conn, resolved_conn))
        return;
    moved->SetRateLimitGroup(m_incoming_rate_limit);
    moved->Enable();
    {
        optional_lock(m_conn_mutex, m_enable_threading);
        m_connected.emplace_hint(m_connected.end(), id, std::move(moved));
    }
    m_incoming_conn_count++;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rcx, %r14
movq %rdx, %r15
movq %rsi, %r12
movq %rdi, %rbx
movq %rsi, 0x10(%rsp)
cmpb $0x1, 0xec(%rdi)
jne 0x9719
movq 0x168(%rbx), %r13
callq 0x4310
cmpq %rax, %r13
jne 0x983f
movq 0x40(%rbx), %rdx
leaq 0x38(%rbx), %rax
movq %rax, %rcx
testq %rdx, %rdx
je 0x9744
movq %rax, %rcx
xorl %esi, %esi
cmpq %r12, 0x20(%rdx)
setl %sil
cmovgeq %rdx, %rcx
movq 0x10(%rdx,%rsi,8), %rdx
testq %rdx, %rdx
jne 0x972c
movq %rax, %rsi
cmpq %rax, %rcx
je 0x9757
cmpq %r12, 0x20(%rcx)
cmovgq %rax, %rcx
movq %rcx, %rsi
cmpq %rax, %rsi
je 0x9820
leaq 0x30(%rbx), %rdi
xorl %eax, %eax
movq %rax, 0x8(%rsp)
movq 0x28(%rsi), %rcx
movq %rax, 0x28(%rsi)
movq %rcx, 0x8(%rsp)
callq 0xaf62
movq 0xc0(%rbx), %rdi
movq 0x10(%rsp), %rsi
movq (%rdi), %rax
movq %r15, %rdx
movq %r14, %rcx
callq *0x48(%rax)
testb %al, %al
je 0x9801
movq 0x8(%rsp), %rdi
leaq 0x180(%rbx), %rsi
callq 0xe1b4
movq 0x8(%rsp), %rdi
callq 0xdecc
leaq 0xf0(%rbx), %r14
movb 0xec(%rbx), %bpl
cmpb $0x1, %bpl
jne 0x97d8
movq %r14, %rdi
callq 0x44f0
testl %eax, %eax
jne 0x985e
leaq 0x8(%rbx), %rsi
leaq 0x10(%rsp), %rdx
leaq 0x8(%rsp), %rcx
movq %rbx, %rdi
callq 0xb11a
testb %bpl, %bpl
je 0x97fb
movq %r14, %rdi
callq 0x42c0
incl 0xe4(%rbx)
movq 0x8(%rsp), %rdi
testq %rdi, %rdi
je 0x9811
movq (%rdi), %rax
callq *0x8(%rax)
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x942d(%rip), %rdi      # 0x12c54
leaq 0x8fdd(%rip), %rsi      # 0x1280b
leaq 0x9438(%rip), %rcx      # 0x12c6d
movl $0x11e, %edx            # imm = 0x11E
callq 0x4260
leaq 0x90d3(%rip), %rdi      # 0x12919
leaq 0x8fbe(%rip), %rsi      # 0x1280b
leaq 0x9419(%rip), %rcx      # 0x12c6d
movl $0x11b, %edx            # imm = 0x11B
callq 0x4260
movl %eax, %edi
callq 0x4280
jmp 0x9879
movq %rax, %rbx
testb %bpl, %bpl
je 0x987c
movq %r14, %rdi
callq 0x42c0
jmp 0x987c
movq %rax, %rbx
movq 0x8(%rsp), %rdi
testq %rdi, %rdi
je 0x988c
movq (%rdi), %rax
callq *0x8(%rax)
movq %rbx, %rdi
callq 0x4640
// File: /workspace/github_cpp_makefile_star2_O1/theuni[P]libbtcnet/src/handler.cpp
// Function: CConnectionHandlerInt::OnOutgoingConnected(long, CConnection const&, CConnection const&)
void CConnectionHandlerInt::OnOutgoingConnected(ConnID id, const CConnection& conn, const CConnection& resolved_conn)
{
    assert(IsEventThread());
    DEBUG_PRINT(LOGVERBOSE, "id:", id);
    auto it = m_connecting.find(id);
    assert(it != m_connecting.end());
    std::unique_ptr<ConnectionBase> moved(nullptr);
    it->second.swap(moved);
    m_connecting.erase(it);

    if (!m_interface.OnOutgoingConnection(id, conn, resolved_conn))
        return;
    moved->SetRateLimitGroup(m_outgoing_rate_limit);
    moved->Enable();
    {
        optional_lock(m_conn_mutex, m_enable_threading);
        m_connected.emplace_hint(m_connected.end(), id, std::move(moved));
    }
    m_outgoing_conn_count++;
    m_interface.OnReadyForFirstSend(id);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rcx, %r14
movq %rdx, %r15
movq %rsi, %r12
movq %rdi, %rbx
movq %rsi, 0x10(%rsp)
cmpb $0x1, 0xec(%rdi)
jne 0x98d1
movq 0x168(%rbx), %r13
callq 0x4310
cmpq %rax, %r13
jne 0x9a09
movq 0x40(%rbx), %rdx
leaq 0x38(%rbx), %rax
movq %rax, %rcx
testq %rdx, %rdx
je 0x98fc
movq %rax, %rcx
xorl %esi, %esi
cmpq %r12, 0x20(%rdx)
setl %sil
cmovgeq %rdx, %rcx
movq 0x10(%rdx,%rsi,8), %rdx
testq %rdx, %rdx
jne 0x98e4
movq %rax, %rsi
cmpq %rax, %rcx
je 0x990f
cmpq %r12, 0x20(%rcx)
cmovgq %rax, %rcx
movq %rcx, %rsi
cmpq %rax, %rsi
je 0x99ea
leaq 0x30(%rbx), %rdi
xorl %eax, %eax
movq %rax, 0x8(%rsp)
movq 0x28(%rsi), %rcx
movq %rax, 0x28(%rsi)
movq %rcx, 0x8(%rsp)
callq 0xaf62
movq 0xc0(%rbx), %rdi
movq 0x10(%rsp), %rsi
movq (%rdi), %rax
movq %r15, %rdx
movq %r14, %rcx
callq *0x40(%rax)
testb %al, %al
je 0x99cb
movq 0x8(%rsp), %rdi
leaq 0x188(%rbx), %rsi
callq 0xe1b4
movq 0x8(%rsp), %rdi
callq 0xdecc
leaq 0xf0(%rbx), %r14
movb 0xec(%rbx), %bpl
cmpb $0x1, %bpl
jne 0x9990
movq %r14, %rdi
callq 0x44f0
testl %eax, %eax
jne 0x9a28
leaq 0x8(%rbx), %rsi
leaq 0x10(%rsp), %rdx
leaq 0x8(%rsp), %rcx
movq %rbx, %rdi
callq 0xb11a
testb %bpl, %bpl
je 0x99b3
movq %r14, %rdi
callq 0x42c0
incl 0xe0(%rbx)
movq 0xc0(%rbx), %rdi
movq 0x10(%rsp), %rsi
movq (%rdi), %rax
callq *0x58(%rax)
movq 0x8(%rsp), %rdi
testq %rdi, %rdi
je 0x99db
movq (%rdi), %rax
callq *0x8(%rax)
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x9263(%rip), %rdi      # 0x12c54
leaq 0x8e13(%rip), %rsi      # 0x1280b
leaq 0x92d0(%rip), %rcx      # 0x12ccf
movl $0x133, %edx            # imm = 0x133
callq 0x4260
leaq 0x8f09(%rip), %rdi      # 0x12919
leaq 0x8df4(%rip), %rsi      # 0x1280b
leaq 0x92b1(%rip), %rcx      # 0x12ccf
movl $0x130, %edx            # imm = 0x130
callq 0x4260
movl %eax, %edi
callq 0x4280
jmp 0x9a43
movq %rax, %rbx
testb %bpl, %bpl
je 0x9a46
movq %r14, %rdi
callq 0x42c0
jmp 0x9a46
movq %rax, %rbx
movq 0x8(%rsp), %rdi
testq %rdi, %rdi
je 0x9a56
movq (%rdi), %rax
callq *0x8(%rax)
movq %rbx, %rdi
callq 0x4640
// File: /workspace/github_cpp_makefile_star2_O1/theuni[P]libbtcnet/src/handler.cpp
// Function: CConnectionHandlerInt::Bind(CConnection)
bool CConnectionHandlerInt::Bind(CConnection conn)
{
    assert(IsEventThread());
    ConnID id = GetNextConnectionIndex();
    std::unique_ptr<CConnListener> listener(new CConnListener(*this, m_event_base, id, std::move(conn)));
    bool ret = listener->Bind();
    if (ret) {
        optional_lock(m_bind_mutex, m_enable_threading);
        auto it = m_binds.emplace_hint(m_binds.end(), id, std::move(listener));
        it->second->Enable();
    }
    return ret;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x188, %rsp            # imm = 0x188
movq %rsi, %r15
movq %rdi, %rbx
cmpb $0x1, 0xec(%rdi)
jne 0x9c0f
movq 0x168(%rbx), %r14
callq 0x4310
cmpq %rax, %r14
jne 0x9cef
movq %rbx, %rdi
callq 0x92ca
movq %rax, %r12
movq %rax, 0x8(%rsp)
movl $0x198, %edi            # imm = 0x198
callq 0x4350
movq %rax, %r14
leaq 0x190(%rbx), %r13
leaq 0x10(%rsp), %rbp
movq %rbp, %rdi
movq %r15, %rsi
callq 0xa838
movq %r14, %rdi
movq %rbx, %rsi
movq %r13, %rdx
movq %r12, %rcx
movq %rbp, %r8
callq 0x10f18
movq %r14, (%rsp)
leaq 0x10(%rsp), %rdi
callq 0x4e4e
movq (%rsp), %rdi
callq 0x10faa
movl %eax, %ebp
testb %al, %al
je 0x9cc2
leaq 0x118(%rbx), %r14
movb 0xec(%rbx), %r15b
cmpb $0x1, %r15b
jne 0x9c94
movq %r14, %rdi
callq 0x44f0
testl %eax, %eax
jne 0x9d0e
leaq 0x60(%rbx), %rdi
addq $0x68, %rbx
leaq 0x8(%rsp), %rdx
movq %rsp, %rcx
movq %rbx, %rsi
callq 0xb470
movq 0x28(%rax), %rdi
callq 0x11116
testb %r15b, %r15b
je 0x9cc2
movq %r14, %rdi
callq 0x42c0
movq (%rsp), %rbx
testq %rbx, %rbx
je 0x9cdb
movq %rbx, %rdi
callq 0x10f40
movq %rbx, %rdi
callq 0x4340
movl %ebp, %eax
addq $0x188, %rsp            # imm = 0x188
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x8c23(%rip), %rdi      # 0x12919
leaq 0x8b0e(%rip), %rsi      # 0x1280b
leaq 0x90d3(%rip), %rcx      # 0x12dd7
movl $0x15c, %edx            # imm = 0x15C
callq 0x4260
movl %eax, %edi
callq 0x4280
jmp 0x9d2b
jmp 0x9d19
movq %rax, %rbx
testb %r15b, %r15b
je 0x9d2e
movq %r14, %rdi
callq 0x42c0
jmp 0x9d2e
movq %rax, %rbx
movq %rsp, %rdi
callq 0xab28
jmp 0x9d4d
movq %rax, %rbx
leaq 0x10(%rsp), %rdi
callq 0x4e4e
movq %r14, %rdi
callq 0x4340
movq %rbx, %rdi
callq 0x4640
nop
// File: /workspace/github_cpp_makefile_star2_O1/theuni[P]libbtcnet/src/handler.cpp
// Function: CConnectionHandlerInt::PumpEvents(bool)
bool CConnectionHandlerInt::PumpEvents(bool block)
{
    assert(IsEventThread());
    if (!m_event_base)
        return false;
    if (m_shutdown)
        return false;
    event_base_loop(m_event_base, block ? EVLOOP_ONCE : EVLOOP_NONBLOCK);
    if (m_shutdown) {
        m_event_base.free();
        m_interface.OnShutdown();
        return false;
    }
    return true;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movl %esi, %ebp
movq %rdi, %rbx
cmpb $0x1, 0xec(%rdi)
jne 0x9fc3
movq 0x168(%rbx), %r14
callq 0x4310
cmpq %rax, %r14
jne 0xa026
movq 0x190(%rbx), %rdi
testq %rdi, %rdi
je 0xa01f
cmpb $0x0, 0xed(%rbx)
jne 0xa01f
movzbl %bpl, %eax
movl $0x2, %esi
subl %eax, %esi
callq 0x43d0
movb $0x1, %al
cmpb $0x1, 0xed(%rbx)
jne 0xa021
movq 0x190(%rbx), %rdi
testq %rdi, %rdi
je 0xa004
callq 0x10ee0
movq $0x0, 0x190(%rbx)
movq 0xc0(%rbx), %rdi
movq (%rdi), %rax
callq *0x98(%rax)
xorl %eax, %eax
popq %rbx
popq %r14
popq %rbp
retq
leaq 0x88ec(%rip), %rdi      # 0x12919
leaq 0x87d7(%rip), %rsi      # 0x1280b
leaq 0x8ec4(%rip), %rcx      # 0x12eff
movl $0x1a1, %edx            # imm = 0x1A1
callq 0x4260
nop
// File: /workspace/github_cpp_makefile_star2_O1/theuni[P]libbtcnet/src/handler.cpp
// Function: CConnectionHandlerInt::CloseConnection(long, bool)
void CConnectionHandlerInt::CloseConnection(ConnID id, bool immediately)
{
    if (id >= 0) {
        optional_lock(m_conn_mutex, m_enable_threading);
        auto it = m_connected.find(id);
        if (it != m_connected.end()) {
            if (immediately)
                it->second->Disconnect();
            else
                it->second->DisconnectWhenFinished();
        }
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
testq %rsi, %rsi
js 0xa0eb
movl %edx, %ebp
movq %rsi, %r15
movq %rdi, %r14
leaq 0xf0(%rdi), %rbx
movb 0xec(%rdi), %r12b
cmpb $0x1, %r12b
jne 0xa07f
movq %rbx, %rdi
callq 0x44f0
testl %eax, %eax
jne 0xa0f4
movq 0x10(%r14), %rcx
addq $0x8, %r14
movq %r14, %rax
testq %rcx, %rcx
je 0xa0a9
movq %r14, %rax
xorl %edx, %edx
cmpq %r15, 0x20(%rcx)
setl %dl
cmovgeq %rcx, %rax
movq 0x10(%rcx,%rdx,8), %rcx
testq %rcx, %rcx
jne 0xa092
movq %r14, %rcx
cmpq %r14, %rax
je 0xa0bc
cmpq %r15, 0x20(%rax)
cmovgq %r14, %rax
movq %rax, %rcx
cmpq %r14, %rcx
je 0xa0d6
movq 0x28(%rcx), %rdi
testb %bpl, %bpl
je 0xa0d1
callq 0xdd44
jmp 0xa0d6
callq 0xdd50
testb %r12b, %r12b
je 0xa0eb
movq %rbx, %rdi
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0x42c0
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movl %eax, %edi
callq 0x4280
movq %rax, %r14
testb %r12b, %r12b
je 0xa10b
movq %rbx, %rdi
callq 0x42c0
movq %r14, %rdi
callq 0x4640
nop
// File: /workspace/github_cpp_makefile_star2_O1/theuni[P]libbtcnet/src/handler.cpp
// Function: CConnectionHandlerInt::PauseRecv(long)
void CConnectionHandlerInt::PauseRecv(ConnID id)
{
    if (id >= 0) {
        optional_lock(m_conn_mutex, m_enable_threading);
        auto it = m_connected.find(id);
        if (it != m_connected.end())
            it->second->PauseRecv();
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
testq %rsi, %rsi
js 0xa1ac
movq %rsi, %r15
movq %rdi, %r14
leaq 0xf0(%rdi), %rbx
movb 0xec(%rdi), %bpl
cmpb $0x1, %bpl
jne 0xa14a
movq %rbx, %rdi
callq 0x44f0
testl %eax, %eax
jne 0xa1b7
movq 0x10(%r14), %rcx
addq $0x8, %r14
movq %r14, %rax
testq %rcx, %rcx
je 0xa174
movq %r14, %rax
xorl %edx, %edx
cmpq %r15, 0x20(%rcx)
setl %dl
cmovgeq %rcx, %rax
movq 0x10(%rcx,%rdx,8), %rcx
testq %rcx, %rcx
jne 0xa15d
movq %r14, %rcx
cmpq %r14, %rax
je 0xa187
cmpq %r15, 0x20(%rax)
cmovgq %r14, %rax
movq %rax, %rcx
cmpq %r14, %rcx
je 0xa195
movq 0x28(%rcx), %rdi
callq 0xdd94
testb %bpl, %bpl
je 0xa1ac
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x42c0
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movl %eax, %edi
callq 0x4280
movq %rax, %r14
testb %bpl, %bpl
je 0xa1ce
movq %rbx, %rdi
callq 0x42c0
movq %r14, %rdi
callq 0x4640
// File: /workspace/github_cpp_makefile_star2_O1/theuni[P]libbtcnet/src/handler.cpp
// Function: CConnectionHandlerInt::UnpauseRecv(long)
void CConnectionHandlerInt::UnpauseRecv(ConnID id)
{
    if (id >= 0) {
        optional_lock(m_conn_mutex, m_enable_threading);
        auto it = m_connected.find(id);
        if (it != m_connected.end())
            it->second->UnpauseRecv();
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
testq %rsi, %rsi
js 0xa26e
movq %rsi, %r15
movq %rdi, %r14
leaq 0xf0(%rdi), %rbx
movb 0xec(%rdi), %bpl
cmpb $0x1, %bpl
jne 0xa20c
movq %rbx, %rdi
callq 0x44f0
testl %eax, %eax
jne 0xa279
movq 0x10(%r14), %rcx
addq $0x8, %r14
movq %r14, %rax
testq %rcx, %rcx
je 0xa236
movq %r14, %rax
xorl %edx, %edx
cmpq %r15, 0x20(%rcx)
setl %dl
cmovgeq %rcx, %rax
movq 0x10(%rcx,%rdx,8), %rcx
testq %rcx, %rcx
jne 0xa21f
movq %r14, %rcx
cmpq %r14, %rax
je 0xa249
cmpq %r15, 0x20(%rax)
cmovgq %r14, %rax
movq %rax, %rcx
cmpq %r14, %rcx
je 0xa257
movq 0x28(%rcx), %rdi
callq 0xde30
testb %bpl, %bpl
je 0xa26e
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x42c0
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movl %eax, %edi
callq 0x4280
movq %rax, %r14
testb %bpl, %bpl
je 0xa290
movq %rbx, %rdi
callq 0x42c0
movq %r14, %rdi
callq 0x4640
// File: /workspace/github_cpp_makefile_star2_O1/theuni[P]libbtcnet/src/handler.cpp
// Function: CConnectionHandlerInt::Send(long, unsigned char const*, unsigned long)
bool CConnectionHandlerInt::Send(ConnID id, const unsigned char* data, size_t size)
{
    bool ret = false;
    if (id >= 0) {
        optional_lock(m_conn_mutex, m_enable_threading);
        auto it = m_connected.find(id);
        if (it == m_connected.end())
            ret = false;
        else
            ret = it->second->Write(data, size);
    }
    return ret;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
testq %rsi, %rsi
js 0xa32f
movq %rcx, %r14
movq %rdx, %r15
movq %rsi, %r13
movq %rdi, %r12
leaq 0xf0(%rdi), %rbp
movb 0xec(%rdi), %bl
cmpb $0x1, %bl
jne 0xa2d6
movq %rbp, %rdi
callq 0x44f0
testl %eax, %eax
jne 0xa352
movq 0x10(%r12), %rcx
addq $0x8, %r12
movq %r12, %rax
testq %rcx, %rcx
je 0xa301
movq %r12, %rax
xorl %edx, %edx
cmpq %r13, 0x20(%rcx)
setl %dl
cmovgeq %rcx, %rax
movq 0x10(%rcx,%rdx,8), %rcx
testq %rcx, %rcx
jne 0xa2ea
movq %r12, %rcx
cmpq %r12, %rax
je 0xa314
cmpq %r13, 0x20(%rax)
cmovgq %r12, %rax
movq %rax, %rcx
movq %rbp, %r13
cmpq %r12, %rcx
je 0xa333
movq 0x28(%rcx), %rdi
movq %r15, %rsi
movq %r14, %rdx
callq 0xed4c
movl %eax, %ebp
jmp 0xa335
xorl %ebp, %ebp
jmp 0xa341
xorl %ebp, %ebp
testb %bl, %bl
je 0xa341
movq %r13, %rdi
callq 0x42c0
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl %eax, %edi
callq 0x4280
movq %rax, %r14
testb %bl, %bl
je 0xa368
movq %r13, %rdi
callq 0x42c0
movq %r14, %rdi
callq 0x4640
// File: /workspace/github_cpp_makefile_star2_O1/theuni[P]libbtcnet/src/handler.cpp
// Function: CConnectionHandlerInt::SetRateLimit(long, CRateLimit const&)
void CConnectionHandlerInt::SetRateLimit(ConnID id, const CRateLimit& limit)
{
    if (id >= 0) {
        optional_lock(m_conn_mutex, m_enable_threading);
        auto it = m_connected.find(id);
        if (it != m_connected.end())
            it->second->SetRateLimit(limit);
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
testq %rsi, %rsi
js 0xa40d
movq %rdx, %r14
movq %rsi, %r12
movq %rdi, %r15
leaq 0xf0(%rdi), %rbx
movb 0xec(%rdi), %bpl
cmpb $0x1, %bpl
jne 0xa3aa
movq %rbx, %rdi
callq 0x44f0
testl %eax, %eax
jne 0xa416
movq 0x10(%r15), %rcx
addq $0x8, %r15
movq %r15, %rax
testq %rcx, %rcx
je 0xa3d4
movq %r15, %rax
xorl %edx, %edx
cmpq %r12, 0x20(%rcx)
setl %dl
cmovgeq %rcx, %rax
movq 0x10(%rcx,%rdx,8), %rcx
testq %rcx, %rcx
jne 0xa3bd
movq %r15, %rcx
cmpq %r15, %rax
je 0xa3e7
cmpq %r12, 0x20(%rax)
cmovgq %r15, %rax
movq %rax, %rcx
cmpq %r15, %rcx
je 0xa3f8
movq 0x28(%rcx), %rdi
movq %r14, %rsi
callq 0xdf9c
testb %bpl, %bpl
je 0xa40d
movq %rbx, %rdi
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0x42c0
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movl %eax, %edi
callq 0x4280
movq %rax, %r14
testb %bpl, %bpl
je 0xa42d
movq %rbx, %rdi
callq 0x42c0
movq %r14, %rdi
callq 0x4640
nop
// File: /workspace/github_cpp_makefile_star2_O1/theuni[P]libbtcnet/src/handler.cpp
// Function: CConnectionHandlerInt::SetIncomingRateLimit(CRateLimit const&)
void CConnectionHandlerInt::SetIncomingRateLimit(const CRateLimit& limit)
{
    event_type<ev_token_bucket_cfg> temp_cfg(ev_token_bucket_cfg_new(limit.nMaxReadRate, limit.nMaxBurstRead, limit.nMaxWriteRate, limit.nMaxBurstWrite, nullptr));
    {
        optional_lock(m_group_rate_mutex, m_enable_threading);
        bufferevent_rate_limit_group_set_cfg(m_incoming_rate_limit, temp_cfg);
        m_incoming_rate_cfg.swap(temp_cfg);
    }
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rdi, %rbx
movq (%rsi), %rax
movq 0x8(%rsi), %rdi
movq 0x18(%rsi), %rdx
movq 0x10(%rsi), %rcx
movq %rax, %rsi
xorl %r8d, %r8d
callq 0x4590
movq %rax, 0x8(%rsp)
testq %rax, %rax
je 0xa4dc
leaq 0x140(%rbx), %r14
movb 0xec(%rbx), %bpl
cmpb $0x1, %bpl
jne 0xa489
movq %r14, %rdi
callq 0x44f0
testl %eax, %eax
jne 0xa531
movq 0x180(%rbx), %rdi
testq %rdi, %rdi
je 0xa4fb
movq 0x8(%rsp), %rsi
testq %rsi, %rsi
je 0xa512
callq 0x4330
movq 0x170(%rbx), %rax
movq 0x8(%rsp), %rcx
movq %rcx, 0x170(%rbx)
movq %rax, 0x8(%rsp)
testb %bpl, %bpl
je 0xa4c9
movq %r14, %rdi
callq 0x42c0
leaq 0x8(%rsp), %rdi
callq 0xa7f4
addq $0x10, %rsp
popq %rbx
popq %r14
popq %rbp
retq
leaq 0x8a70(%rip), %rdi      # 0x12f53
leaq 0x8a7a(%rip), %rsi      # 0x12f64
leaq 0x8d16(%rip), %rcx      # 0x13207
movl $0x21, %edx
callq 0x4260
leaq 0x8a51(%rip), %rdi      # 0x12f53
leaq 0x8a5b(%rip), %rsi      # 0x12f64
leaq 0x8d42(%rip), %rcx      # 0x13252
jmp 0xa527
leaq 0x8a3a(%rip), %rdi      # 0x12f53
leaq 0x8a44(%rip), %rsi      # 0x12f64
leaq 0x8c10(%rip), %rcx      # 0x13137
movl $0x4b, %edx
callq 0x4260
movl %eax, %edi
callq 0x4280
movq %rax, %rbx
jmp 0xa54d
movq %rax, %rbx
testb %bpl, %bpl
je 0xa54d
movq %r14, %rdi
callq 0x42c0
leaq 0x8(%rsp), %rdi
callq 0xa7f4
movq %rbx, %rdi
callq 0x4640
nop
// File: /workspace/github_cpp_makefile_star2_O1/theuni[P]libbtcnet/src/handler.cpp
// Function: CConnectionHandlerInt::SetOutgoingRateLimit(CRateLimit const&)
void CConnectionHandlerInt::SetOutgoingRateLimit(const CRateLimit& limit)
{
    event_type<ev_token_bucket_cfg> temp_cfg(ev_token_bucket_cfg_new(limit.nMaxReadRate, limit.nMaxBurstRead, limit.nMaxWriteRate, limit.nMaxBurstWrite, nullptr));
    {
        optional_lock(m_group_rate_mutex, m_enable_threading);
        bufferevent_rate_limit_group_set_cfg(m_outgoing_rate_limit, temp_cfg);
        m_outgoing_rate_cfg.swap(temp_cfg);
    }
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rdi, %rbx
movq (%rsi), %rax
movq 0x8(%rsi), %rdi
movq 0x18(%rsi), %rdx
movq 0x10(%rsi), %rcx
movq %rax, %rsi
xorl %r8d, %r8d
callq 0x4590
movq %rax, 0x8(%rsp)
testq %rax, %rax
je 0xa606
leaq 0x140(%rbx), %r14
movb 0xec(%rbx), %bpl
cmpb $0x1, %bpl
jne 0xa5b3
movq %r14, %rdi
callq 0x44f0
testl %eax, %eax
jne 0xa65b
movq 0x188(%rbx), %rdi
testq %rdi, %rdi
je 0xa625
movq 0x8(%rsp), %rsi
testq %rsi, %rsi
je 0xa63c
callq 0x4330
movq 0x178(%rbx), %rax
movq 0x8(%rsp), %rcx
movq %rcx, 0x178(%rbx)
movq %rax, 0x8(%rsp)
testb %bpl, %bpl
je 0xa5f3
movq %r14, %rdi
callq 0x42c0
leaq 0x8(%rsp), %rdi
callq 0xa7f4
addq $0x10, %rsp
popq %rbx
popq %r14
popq %rbp
retq
leaq 0x8946(%rip), %rdi      # 0x12f53
leaq 0x8950(%rip), %rsi      # 0x12f64
leaq 0x8bec(%rip), %rcx      # 0x13207
movl $0x21, %edx
callq 0x4260
leaq 0x8927(%rip), %rdi      # 0x12f53
leaq 0x8931(%rip), %rsi      # 0x12f64
leaq 0x8c18(%rip), %rcx      # 0x13252
jmp 0xa651
leaq 0x8910(%rip), %rdi      # 0x12f53
leaq 0x891a(%rip), %rsi      # 0x12f64
leaq 0x8ae6(%rip), %rcx      # 0x13137
movl $0x4b, %edx
callq 0x4260
movl %eax, %edi
callq 0x4280
movq %rax, %rbx
jmp 0xa677
movq %rax, %rbx
testb %bpl, %bpl
je 0xa677
movq %r14, %rdi
callq 0x42c0
leaq 0x8(%rsp), %rdi
callq 0xa7f4
movq %rbx, %rdi
callq 0x4640
nop
// File: /workspace/github_cpp_makefile_star2_O1/theuni[P]libbtcnet/src/handler.cpp
// Function: CConnectionHandlerInt::ResetPingTimeout(long, int)
void CConnectionHandlerInt::ResetPingTimeout(ConnID id, int seconds)
{
    if (id >= 0) {
        optional_lock(m_conn_mutex, m_enable_threading);
        auto it = m_connected.find(id);
        if (it != m_connected.end())
            it->second->ResetPingTimeout(seconds);
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
testq %rsi, %rsi
js 0xa765
movl %edx, %ebp
movq %rsi, %r15
movq %rdi, %r14
leaq 0xf0(%rdi), %rbx
movb 0xec(%rdi), %r12b
cmpb $0x1, %r12b
jne 0xa703
movq %rbx, %rdi
callq 0x44f0
testl %eax, %eax
jne 0xa76e
movq 0x10(%r14), %rcx
addq $0x8, %r14
movq %r14, %rax
testq %rcx, %rcx
je 0xa72d
movq %r14, %rax
xorl %edx, %edx
cmpq %r15, 0x20(%rcx)
setl %dl
cmovgeq %rcx, %rax
movq 0x10(%rcx,%rdx,8), %rcx
testq %rcx, %rcx
jne 0xa716
movq %r14, %rcx
cmpq %r14, %rax
je 0xa740
cmpq %r15, 0x20(%rax)
cmovgq %r14, %rax
movq %rax, %rcx
cmpq %r14, %rcx
je 0xa750
movq 0x28(%rcx), %rdi
movl %ebp, %esi
callq 0xdd5c
testb %r12b, %r12b
je 0xa765
movq %rbx, %rdi
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0x42c0
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movl %eax, %edi
callq 0x4280
movq %rax, %r14
testb %r12b, %r12b
je 0xa785
movq %rbx, %rdi
callq 0x42c0
movq %r14, %rdi
callq 0x4640
nop
// File: /workspace/github_cpp_makefile_star2_O1/theuni[P]libbtcnet/src/resolve.cpp
// Function: CDNSResponse::iterator::operator++(int)
CDNSResponse::iterator CDNSResponse::iterator::operator++(int)
{
    assert(m_ai != nullptr);
    iterator ret = iterator(m_ai);
    m_ai = m_ai->ai_next;
    return ret;
}

// Assembly:
movq (%rdi), %rax
testq %rax, %rax
je 0xb960
movq 0x28(%rax), %rcx
movq %rcx, (%rdi)
retq
pushq %rax
leaq 0x7a20(%rip), %rdi      # 0x13388
leaq 0x7a29(%rip), %rsi      # 0x13398
leaq 0x7a6f(%rip), %rcx      # 0x133e5
movl $0x23, %edx
callq 0x4260
// File: /workspace/github_cpp_makefile_star2_O1/theuni[P]libbtcnet/src/resolve.cpp
// Function: CDNSResponse::operator=(CDNSResponse&&)
CDNSResponse& CDNSResponse::operator=(CDNSResponse&& rhs) noexcept
{
    clear();
    m_ai = rhs.m_ai;
    rhs.m_ai = nullptr;
    return *this;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %rbx
movq (%rdi), %rdi
testq %rdi, %rdi
je 0xba3f
callq 0x4450
xorl %eax, %eax
movq %rax, (%rbx)
movq (%r14), %rcx
movq %rcx, (%rbx)
movq %rax, (%r14)
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
movq %rax, %rdi
callq 0xab84
// File: /workspace/github_cpp_makefile_star2_O1/theuni[P]libbtcnet/src/resolve.cpp
// Function: CDNSResolve::Resolve(event_type<evdns_base> const&, char const*, char const*, addrinfo const*)
event_type<evdns_getaddrinfo_request> CDNSResolve::Resolve(const event_type<evdns_base>& dns_base, const char* host, const char* port, const evutil_addrinfo* hints)
{
    assert(host != nullptr);
    assert(port != nullptr);
    // evdns_getaddrinfo may return NULL on success.
    event_type<evdns_getaddrinfo_request> result;
    result.reset(evdns_getaddrinfo(dns_base, host, port, hints, dns_callback, this));
    return result;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
testq %rcx, %rcx
je 0xbad6
testq %r8, %r8
je 0xbaf5
movq %rdi, %rbx
movq $0x0, (%rdi)
movq (%rdx), %rdi
testq %rdi, %rdi
je 0xbb14
movq %rsi, %rax
leaq 0x92(%rip), %r10        # 0xbb46
movq %rcx, %rsi
movq %r8, %rdx
movq %r9, %rcx
movq %r10, %r8
movq %rax, %r9
callq 0x4460
movq %rax, (%rbx)
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
leaq 0x797c(%rip), %rdi      # 0x13459
leaq 0x78b4(%rip), %rsi      # 0x13398
leaq 0x797e(%rip), %rcx      # 0x13469
movl $0x7c, %edx
callq 0x4260
leaq 0x79f6(%rip), %rdi      # 0x134f2
leaq 0x7895(%rip), %rsi      # 0x13398
leaq 0x795f(%rip), %rcx      # 0x13469
movl $0x7d, %edx
callq 0x4260
leaq 0x7438(%rip), %rdi      # 0x12f53
leaq 0x7442(%rip), %rsi      # 0x12f64
leaq 0x7a27(%rip), %rcx      # 0x13550
movl $0x4b, %edx
callq 0x4260
movq %rax, %r14
movq %rbx, %rdi
callq 0xb6c6
movq %r14, %rdi
callq 0x4640
// File: /workspace/github_cpp_makefile_star2_O1/theuni[P]libbtcnet/src/resolve.cpp
// Function: CDNSResolve::dns_callback(int, addrinfo*, void*)
void CDNSResolve::dns_callback(int result, evutil_addrinfo* ai, void* ctx)
{
    if (result == EVUTIL_EAI_CANCEL) {
        // Do nothing. Class may no longer exist.
    } else if (result == DNS_ERR_NONE) {
        assert(ctx != nullptr);
        CDNSResolve* resolver = static_cast<CDNSResolve*>(ctx);
        resolver->OnResolveSuccess(CDNSResponse(ai));
    } else {
        assert(ctx != nullptr);
        CDNSResolve* resolver = static_cast<CDNSResolve*>(ctx);
        resolver->OnResolveFailure(result);
    }
}

// Assembly:
pushq %rbx
subq $0x10, %rsp
cmpl $0xfffea06f, %edi       # imm = 0xFFFEA06F
je 0xbb7c
movl %edi, %eax
testl %edi, %edi
jne 0xbb82
testq %rdx, %rdx
je 0xbb9a
leaq 0x8(%rsp), %rax
movq %rsi, (%rax)
movq (%rdx), %rcx
movq %rdx, %rdi
movq %rax, %rsi
callq *0x10(%rcx)
leaq 0x8(%rsp), %rdi
callq 0xb9ca
addq $0x10, %rsp
popq %rbx
retq
testq %rdx, %rdx
je 0xbbb9
movq (%rdx), %rcx
movq 0x18(%rcx), %rcx
movq %rdx, %rdi
movl %eax, %esi
addq $0x10, %rsp
popq %rbx
jmpq *%rcx
leaq 0x7961(%rip), %rdi      # 0x13502
leaq 0x77f0(%rip), %rsi      # 0x13398
leaq 0x7962(%rip), %rcx      # 0x13511
movl $0x89, %edx
callq 0x4260
leaq 0x7942(%rip), %rdi      # 0x13502
leaq 0x77d1(%rip), %rsi      # 0x13398
leaq 0x7943(%rip), %rcx      # 0x13511
movl $0x8d, %edx
callq 0x4260
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0xb9ca
movq %rbx, %rdi
callq 0x4640
nopl (%rax)
// File: /workspace/github_cpp_makefile_star2_O1/theuni[P]libbtcnet/src/directconn.cpp
// Function: CDirectConnection::Connect()
void CDirectConnection::Connect()
{
    assert(m_connection.IsSet());

    const CConnectionOptions& opts = m_connection.GetOptions();

    timeval connTimeout;
    connTimeout.tv_sec = opts.nConnTimeout;
    connTimeout.tv_usec = 0;

    sockaddr_storage addr_storage;
    memset(&addr_storage, 0, sizeof(addr_storage));
    int addrlen = sizeof(addr_storage);
    sockaddr* addr = reinterpret_cast<sockaddr*>(&addr_storage);
    m_connection.GetSockAddr(addr, &addrlen);

    if (m_connection.CanConnectDirect())
        BareConnect(m_event_base, m_handler.GetBevOpts(), BAD_SOCKET, addr, addrlen, connTimeout);
    else
        OnConnectionFailure(ConnectionFailureType::CONNECT, 0, m_connection, false);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x220, %rsp            # imm = 0x220
movq %rdi, %rbx
leaq 0x18(%rdi), %r14
movq %r14, %rdi
callq 0x63d2
testb %al, %al
je 0xbdd0
movq %r14, %rdi
callq 0x701a
movslq 0xc(%rax), %rax
movq %rax, 0x10(%rsp)
movq $0x0, 0x18(%rsp)
xorps %xmm0, %xmm0
leaq 0x20(%rsp), %rsi
movaps %xmm0, 0x70(%rsi)
movaps %xmm0, 0x60(%rsi)
movaps %xmm0, 0x50(%rsi)
movaps %xmm0, 0x40(%rsi)
movaps %xmm0, 0x30(%rsi)
movaps %xmm0, 0x20(%rsi)
movaps %xmm0, 0x10(%rsi)
movaps %xmm0, (%rsi)
leaq 0xc(%rsp), %rdx
movl $0x80, (%rdx)
movq %r14, %rdi
callq 0x618e
movq %r14, %rdi
callq 0x7088
testb %al, %al
je 0xbd8e
leaq 0x2b0(%rbx), %r14
movq 0x8(%rbx), %rdi
movq 0x10(%rbx), %rbx
callq 0x9f56
movl 0xc(%rsp), %r9d
leaq 0x10(%rsp), %rcx
movq %rcx, (%rsp)
leaq 0x20(%rsp), %r8
movq %r14, %rdi
movq %rbx, %rsi
movl %eax, %edx
movl $0xffffffff, %ecx       # imm = 0xFFFFFFFF
callq 0xd336
jmp 0xbdc3
leaq 0xa8(%rsp), %r15
movq %r15, %rdi
movq %r14, %rsi
callq 0x75d0
movq %rbx, %rdi
movl $0x1, %esi
xorl %edx, %edx
movq %r15, %rcx
xorl %r8d, %r8d
callq 0xe0d6
leaq 0xa8(%rsp), %rdi
callq 0x4e4e
addq $0x220, %rsp            # imm = 0x220
popq %rbx
popq %r14
popq %r15
retq
leaq 0x77d1(%rip), %rdi      # 0x135a8
leaq 0x77df(%rip), %rsi      # 0x135bd
leaq 0x77eb(%rip), %rcx      # 0x135d0
movl $0x1e, %edx
callq 0x4260
movq %rax, %rbx
leaq 0xa8(%rsp), %rdi
callq 0x4e4e
movq %rbx, %rdi
callq 0x4640
nop
// File: /workspace/github_cpp_makefile_star2_O1/theuni[P]libbtcnet/src/dnsconn.cpp
// Function: CDNSConnection::ConnectResolved()
void CDNSConnection::ConnectResolved()
{
    assert(m_iter != m_resolved.end());
    assert(!m_resolved.empty());

    const CConnectionOptions& opts = m_connection.GetOptions();
    timeval connTimeout;
    connTimeout.tv_sec = opts.nConnTimeout;
    connTimeout.tv_usec = 0;
    if (CConnection::CanConnectDirect(m_iter->ai_addr, opts.nFamily))
        BareConnect(m_event_base, m_handler.GetBevOpts(), BAD_SOCKET, m_iter->ai_addr, m_iter->ai_addrlen, connTimeout);
    else
        OnConnectFailure(0, 0);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rdi, %r15
leaq 0x2d8(%rdi), %rbx
leaq 0x2d0(%rdi), %r12
movq %r12, %rdi
callq 0xba0a
leaq 0x8(%rsp), %r14
movq %rax, (%r14)
movq %rbx, %rdi
movq %r14, %rsi
callq 0xb9b4
testb %al, %al
je 0xc4cc
movq %r12, %rdi
callq 0xba0e
testb %al, %al
jne 0xc4eb
leaq 0x18(%r15), %rdi
callq 0x701a
movq %rax, %r12
movslq 0xc(%rax), %rax
movq %rax, 0x8(%rsp)
movq $0x0, 0x10(%rsp)
movq %rbx, %rdi
callq 0xb980
movq 0x18(%rax), %rdi
movl 0x28(%r12), %esi
callq 0x702a
testb %al, %al
je 0xc4b3
leaq 0x2b0(%r15), %r12
movq 0x8(%r15), %rdi
movq 0x10(%r15), %r15
callq 0x9f56
movl %eax, %ebp
movq %rbx, %rdi
callq 0xb980
movq 0x18(%rax), %r13
movq %rbx, %rdi
callq 0xb980
movl 0x10(%rax), %r9d
movq %r14, (%rsp)
movq %r12, %rdi
movq %r15, %rsi
movl %ebp, %edx
movl $0xffffffff, %ecx       # imm = 0xFFFFFFFF
movq %r13, %r8
callq 0xd336
jmp 0xc4bd
movq %r15, %rdi
xorl %esi, %esi
callq 0xcca8
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x7289(%rip), %rdi      # 0x1375c
leaq 0x713f(%rip), %rsi      # 0x13619
leaq 0x72d0(%rip), %rcx      # 0x137b1
movl $0x6c, %edx
callq 0x4260
leaq 0x7256(%rip), %rdi      # 0x13748
leaq 0x7120(%rip), %rsi      # 0x13619
leaq 0x72b1(%rip), %rcx      # 0x137b1
movl $0x6d, %edx
callq 0x4260
// File: /workspace/github_cpp_makefile_star2_O1/theuni[P]libbtcnet/src/dnsconn.cpp
// Function: CDNSConnection::OnResolveFailure(int)
void CDNSConnection::OnResolveFailure(int error)
{
    assert(m_resolved.empty());
    assert(m_iter == m_resolved.end());

    m_request.reset(nullptr);
    OnConnectionFailure(ConnectionFailureType::RESOLVE, error, m_connection, m_retries > 0 ? m_retries-- != 0 : m_retries != 0);
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x188, %rsp            # imm = 0x188
movl %esi, %ebx
movq %rdi, %r14
leaq 0x2d0(%rdi), %r15
movq %r15, %rdi
callq 0xba0e
testb %al, %al
je 0xc5c0
leaq 0x2d8(%r14), %r12
movq %r15, %rdi
callq 0xba0a
leaq 0x8(%rsp), %rsi
movq %rax, (%rsi)
movq %r12, %rdi
callq 0xb9aa
testb %al, %al
je 0xc5df
movq $0x0, 0x2e0(%r14)
leaq 0x18(%r14), %rsi
leaq 0x10(%rsp), %rdi
callq 0x75d0
movl 0x2c8(%r14), %eax
testl %eax, %eax
jle 0xc58c
decl %eax
movl %eax, 0x2c8(%r14)
movb $0x1, %al
jmp 0xc58f
setne %al
movzbl %al, %r8d
leaq 0x10(%rsp), %rcx
movq %r14, %rdi
movl $0x2, %esi
movl %ebx, %edx
callq 0xe0d6
leaq 0x10(%rsp), %rdi
callq 0x4e4e
addq $0x188, %rsp            # imm = 0x188
popq %rbx
popq %r12
popq %r14
popq %r15
retq
leaq 0x7182(%rip), %rdi      # 0x13749
leaq 0x704b(%rip), %rsi      # 0x13619
leaq 0x70b7(%rip), %rcx      # 0x1368c
movl $0x3f, %edx
callq 0x4260
leaq 0x708b(%rip), %rdi      # 0x13671
leaq 0x702c(%rip), %rsi      # 0x13619
leaq 0x7098(%rip), %rcx      # 0x1368c
movl $0x40, %edx
callq 0x4260
movq %rax, %rbx
leaq 0x10(%rsp), %rdi
callq 0x4e4e
movq %rbx, %rdi
callq 0x4640
nop
// File: /workspace/github_cpp_makefile_star2_O1/theuni[P]libbtcnet/src/dnsconn.cpp
// Function: CDNSConnection::OnResolveSuccess(CDNSResponse&&)
void CDNSConnection::OnResolveSuccess(CDNSResponse&& response)
{
    assert(m_resolved.empty());
    assert(m_iter == m_resolved.end());

    m_request.reset(nullptr);
    m_resolved = std::move(response);
    m_iter = m_resolved.begin();
    ConnectResolved();
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %r15
movq %rdi, %rbx
leaq 0x2d0(%rdi), %r14
movq %r14, %rdi
callq 0xba0e
testb %al, %al
je 0xc69b
leaq 0x2d8(%rbx), %r12
movq %r14, %rdi
callq 0xba0a
movq %rsp, %rsi
movq %rax, (%rsi)
movq %r12, %rdi
callq 0xb9aa
testb %al, %al
je 0xc6ba
movq $0x0, 0x2e0(%rbx)
movq %r14, %rdi
movq %r15, %rsi
callq 0xba28
movq %r14, %rdi
callq 0xba06
movq %rax, 0x2d8(%rbx)
movq %rbx, %rdi
callq 0xc3e0
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
leaq 0x70a7(%rip), %rdi      # 0x13749
leaq 0x6f70(%rip), %rsi      # 0x13619
leaq 0x700f(%rip), %rcx      # 0x136bf
movl $0x48, %edx
callq 0x4260
leaq 0x6fb0(%rip), %rdi      # 0x13671
leaq 0x6f51(%rip), %rsi      # 0x13619
leaq 0x6ff0(%rip), %rcx      # 0x136bf
movl $0x49, %edx
callq 0x4260
nop
// File: /workspace/github_cpp_makefile_star2_O1/theuni[P]libbtcnet/src/bareconn.cpp
// Function: CBareConnection::conn_event(bufferevent*, short, void*)
void CBareConnection::conn_event(bufferevent* bev, short event, void* ctx)
{
    assert(bev != nullptr);
    assert(ctx != nullptr);
    CBareConnection* data = static_cast<CBareConnection*>(ctx);
    if ((event & BEV_EVENT_CONNECTED) != 0)
        data->OnConnectSuccess(std::move(data->m_bev));
    else {
        evutil_socket_t sock = bufferevent_getfd(bev);
        (void)sock;
        // sock may be BAD_SOCKET here if it wasn't successfully created.
        int error = evutil_socket_geterror(sock);
        data->m_bev.free();
        data->OnConnectFailure(event, error);
    }
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
testq %rdi, %rdi
je 0xd2f7
movq %rdx, %rbx
testq %rdx, %rdx
je 0xd316
movl %esi, %ebp
testb %bpl, %bpl
js 0xd2e3
callq 0x41a0
callq 0x4040
movl (%rax), %r14d
movq 0x8(%rbx), %rdi
testq %rdi, %rdi
je 0xd2c5
callq 0x10eee
movq $0x0, 0x8(%rbx)
movq (%rbx), %rax
movq 0x18(%rax), %rax
movswl %bp, %esi
movq %rbx, %rdi
movl %r14d, %edx
popq %rbx
popq %r14
popq %rbp
jmpq *%rax
leaq 0x8(%rbx), %rsi
movq (%rbx), %rax
movq 0x10(%rax), %rax
movq %rbx, %rdi
popq %rbx
popq %r14
popq %rbp
jmpq *%rax
leaq 0x66f3(%rip), %rdi      # 0x139f1
leaq 0x64e4(%rip), %rsi      # 0x137e9
leaq 0x64ee(%rip), %rcx      # 0x137fa
movl $0x12, %edx
callq 0x4260
leaq 0x61e5(%rip), %rdi      # 0x13502
leaq 0x64c5(%rip), %rsi      # 0x137e9
leaq 0x64cf(%rip), %rcx      # 0x137fa
movl $0x13, %edx
callq 0x4260
nop
// File: /workspace/github_cpp_makefile_star2_O1/theuni[P]libbtcnet/src/connectionbase.cpp
// Function: ConnectionBase::DisconnectInt(int)
void ConnectionBase::DisconnectInt(int /*reason*/)
{
    DEBUG_PRINT(LOGINFO, "id:", m_id, "disconnecting");
    m_disconnect_func.del();
    m_reconnect_func.del();
    m_disconnect_wait_func.del();
    m_check_write_buffer_func.del();
    m_ping_timeout_func.del();
    m_first_data_func.del();
    {
        BufferEventLocker lock(m_bev);
        bufferevent_disable(m_bev, EV_READ | EV_WRITE);
        bufferevent_setcb(m_bev, nullptr, nullptr, nullptr, nullptr);
    }
    bool reconnect = m_connection.GetOptions().fPersistent && this->IsOutgoing();
    m_handler.OnDisconnected(m_id, reconnect);
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
addq $0x1e0, %rdi            # imm = 0x1E0
callq 0x11d42
leaq 0x1b8(%rbx), %rdi
callq 0x11d42
leaq 0x208(%rbx), %rdi
callq 0x11d42
leaq 0x230(%rbx), %rdi
callq 0x11d42
leaq 0x258(%rbx), %rdi
callq 0x11d42
leaq 0x280(%rbx), %rdi
callq 0x11d42
movq 0x1a8(%rbx), %r14
testq %r14, %r14
je 0xda15
movq %r14, %rdi
callq 0x44e0
movq 0x1a8(%rbx), %rdi
testq %rdi, %rdi
je 0xda15
movl $0x6, %esi
callq 0x4510
movq 0x1a8(%rbx), %rdi
testq %rdi, %rdi
je 0xda15
xorl %esi, %esi
xorl %edx, %edx
xorl %ecx, %ecx
xorl %r8d, %r8d
callq 0x4360
movq %r14, %rdi
callq 0x45e0
leaq 0x18(%rbx), %rdi
callq 0x701a
cmpb $0x1, 0x2(%rax)
jne 0xd9f9
movq (%rbx), %rax
movq %rbx, %rdi
callq *0x20(%rax)
jmp 0xd9fb
xorl %eax, %eax
movq 0x8(%rbx), %rdi
movq 0x190(%rbx), %rsi
movzbl %al, %edx
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x90e0
leaq 0x5537(%rip), %rdi      # 0x12f53
leaq 0x5541(%rip), %rsi      # 0x12f64
leaq 0x5eeb(%rip), %rcx      # 0x13915
movl $0x4b, %edx
callq 0x4260
jmp 0xda49
movq %rax, %rbx
movq %r14, %rdi
callq 0x45e0
movq %rbx, %rdi
callq 0x4640
movq %rax, %rdi
callq 0xab84
nop
// File: /workspace/github_cpp_makefile_star2_O1/theuni[P]libbtcnet/src/connectionbase.cpp
// Function: ConnectionBase::ResetPingTimeout(int)
void ConnectionBase::ResetPingTimeout(int seconds)
{
    if (seconds != 0) {
        timeval timeout = {seconds, 0};
        m_ping_timeout_func.add(&timeout);
    } else
        m_ping_timeout_func.del();
}

// Assembly:
testl %esi, %esi
je 0xdd88
subq $0x18, %rsp
movslq %esi, %rax
leaq 0x8(%rsp), %rsi
movq %rax, (%rsi)
movq $0x0, 0x8(%rsi)
addq $0x258, %rdi            # imm = 0x258
callq 0x11d66
addq $0x18, %rsp
retq
addq $0x258, %rdi            # imm = 0x258
jmp 0x11d42
// File: /workspace/github_cpp_makefile_star2_O1/theuni[P]libbtcnet/src/connectionbase.cpp
// Function: ConnectionBase::event_cb(bufferevent*, short, void*)
void ConnectionBase::event_cb(bufferevent* /*unused*/, short type, void* ctx)
{
    assert(ctx);
    ConnectionBase* base = static_cast<ConnectionBase*>(ctx);
    if (((type & BEV_EVENT_TIMEOUT) != 0) ||
        ((type & BEV_EVENT_EOF) != 0) ||
        ((type & BEV_EVENT_ERROR) != 0))
        base->DisconnectInt(0);
}

// Assembly:
testq %rdx, %rdx
je 0xe194
testb $0x70, %sil
je 0xe193
movq %rdx, %rdi
jmp 0xd944
retq
pushq %rax
leaq 0x591c(%rip), %rdi      # 0x13ab8
leaq 0x57f1(%rip), %rsi      # 0x13994
leaq 0x59d7(%rip), %rcx      # 0x13b81
movl $0x142, %edx            # imm = 0x142
callq 0x4260
// File: /workspace/github_cpp_makefile_star2_O1/theuni[P]libbtcnet/src/connectionbase.cpp
// Function: ConnectionBase::SetSocketOpts(int)
bool ConnectionBase::SetSocketOpts(evutil_socket_t sock)
{
    if (evutil_make_socket_nonblocking(sock) != 0)
        return false;

#ifdef _WIN32
    typedef char sockoptptr;
#else
    typedef void sockoptptr;
#endif
    int type;
    ev_socklen_t length = sizeof(type);
    if (getsockopt(sock, SOL_SOCKET, SO_TYPE, reinterpret_cast<sockoptptr*>(&type), &length) == 0) {
        int set = 1;
        if (type == SOCK_STREAM)
            setsockopt(sock, IPPROTO_TCP, TCP_NODELAY, reinterpret_cast<sockoptptr*>(&set), sizeof(int));
    }
    return true;
}

// Assembly:
pushq %rbp
pushq %rbx
subq $0x18, %rsp
movl %edi, %ebp
callq 0x44b0
movl %eax, %ebx
testl %eax, %eax
jne 0xe26a
leaq 0x14(%rsp), %r8
movl $0x4, (%r8)
leaq 0x10(%rsp), %rcx
movl %ebp, %edi
movl $0x1, %esi
movl $0x3, %edx
callq 0x42b0
testl %eax, %eax
jne 0xe26a
movl $0x1, 0xc(%rsp)
cmpl $0x1, 0x10(%rsp)
jne 0xe26a
leaq 0xc(%rsp), %rcx
movl %ebp, %edi
movl $0x6, %esi
movl $0x1, %edx
movl $0x4, %r8d
callq 0x4650
testl %ebx, %ebx
sete %al
addq $0x18, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/theuni[P]libbtcnet/src/connectionbase.cpp
// Function: ConnectionBase::read_cb_chunk(bufferevent*, void*)
void ConnectionBase::read_cb_chunk(bufferevent* bev, void* ctx)
{
    assert(ctx);
    assert(bev);

    ConnectionBase* base = static_cast<ConnectionBase*>(ctx);
    const CNetworkConfig& netconfig = base->m_connection.GetNetConfig();
    assert(netconfig.chunk_size > 0);
    size_t chunk_size = netconfig.chunk_size;

    std::list<std::vector<unsigned char> > msgs;
    size_t remaining;
    evbuffer* input;
    {
        BufferEventLocker lock(bev);
        input = bufferevent_get_input(bev);
        remaining = evbuffer_get_length(input);
        while (remaining >= chunk_size) {
            msgs.emplace_back(chunk_size);
            evbuffer_remove(input, msgs.back().data(), chunk_size);
            remaining -= chunk_size;
        }
    }
    evbuffer_expand(input, chunk_size);
    if (!msgs.empty())
        base->m_handler.OnReceiveMessages(base->m_id, std::move(msgs), msgs.size() * chunk_size);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
testq %rsi, %rsi
je 0xe6b3
movq %rdi, %r14
testq %rdi, %rdi
je 0xe6d2
movq %rsi, %rbx
leaq 0x18(%rsi), %rdi
callq 0x7022
movslq 0x28(%rax), %rax
testq %rax, %rax
jle 0xe6f1
movq %rax, 0x8(%rsp)
leaq 0x10(%rsp), %rax
movq %rax, 0x8(%rax)
movq %rax, (%rax)
movq $0x0, 0x10(%rax)
movq %r14, %rdi
callq 0x44e0
movq %r14, %rdi
callq 0x4270
movq %rax, %r15
movq %rax, %rdi
callq 0x43a0
movq %rax, %r12
cmpq 0x8(%rsp), %rax
jb 0xe65a
leaq 0x10(%rsp), %r13
leaq 0x8(%rsp), %rbp
movq %r13, %rdi
movq %rbp, %rsi
callq 0xef6c
movq %rax, %rdi
movq %r13, %rsi
callq 0x4070
incq 0x20(%rsp)
movq 0x18(%rsp), %rax
movq 0x10(%rax), %rsi
movq 0x8(%rsp), %rdx
movq %r15, %rdi
callq 0x4440
movq 0x8(%rsp), %rax
subq %rax, %r12
cmpq %rax, %r12
jae 0xe61c
movq %r14, %rdi
callq 0x45e0
movq 0x8(%rsp), %rsi
movq %r15, %rdi
callq 0x41c0
leaq 0x10(%rsp), %rax
cmpq %rax, 0x10(%rsp)
je 0xe69a
movq 0x8(%rbx), %rdi
movq 0x190(%rbx), %rsi
movq 0x8(%rsp), %rcx
leaq 0x10(%rsp), %rdx
imulq 0x10(%rdx), %rcx
callq 0x9a5e
leaq 0x10(%rsp), %rdi
callq 0xac9a
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x53fe(%rip), %rdi      # 0x13ab8
leaq 0x52d3(%rip), %rsi      # 0x13994
leaq 0x54fc(%rip), %rcx      # 0x13bc4
movl $0x14c, %edx            # imm = 0x14C
callq 0x4260
leaq 0x516a(%rip), %rdi      # 0x13843
leaq 0x52b4(%rip), %rsi      # 0x13994
leaq 0x54dd(%rip), %rcx      # 0x13bc4
movl $0x14d, %edx            # imm = 0x14D
callq 0x4260
leaq 0x550d(%rip), %rdi      # 0x13c05
leaq 0x5295(%rip), %rsi      # 0x13994
leaq 0x54be(%rip), %rcx      # 0x13bc4
movl $0x151, %edx            # imm = 0x151
callq 0x4260
jmp 0xe738
jmp 0xe714
movq %rax, %rbx
jmp 0xe726
jmp 0xe71b
movq %rax, %rbx
movq %r14, %rdi
callq 0x45e0
leaq 0x10(%rsp), %rdi
callq 0xac9a
movq %rbx, %rdi
callq 0x4640
movq %rax, %rdi
callq 0xab84
// File: /workspace/github_cpp_makefile_star2_O1/theuni[P]libbtcnet/src/connectionbase.cpp
// Function: ConnectionBase::read_data(evbuffer*, evbuffer_cb_info const*, void*)
void ConnectionBase::read_data(struct evbuffer* /*unused*/, const struct evbuffer_cb_info* info, void* ctx)
{
    assert(ctx);
    if (info->n_added != 0u) {
        ConnectionBase* base = static_cast<ConnectionBase*>(ctx);
        base->m_bytes_read += info->n_added;
        base->m_handler.m_interface.OnBytesRead(base->m_id, info->n_added, base->m_bytes_read);
        DEBUG_PRINT(LOGALL, "id:", base->m_id, "Read:", info->n_added, "bytes. Total:", base->m_bytes_read);
    }
}

// Assembly:
testq %rdx, %rdx
je 0xea3d
movq %rdx, %rax
movq 0x8(%rsi), %rdx
testq %rdx, %rdx
je 0xea3c
movq 0x198(%rax), %rcx
addq %rdx, %rcx
movq %rcx, 0x198(%rax)
movq 0x8(%rax), %rdi
movq 0x190(%rax), %rsi
movq 0xc0(%rdi), %rdi
movq (%rdi), %rax
movq 0x80(%rax), %rax
jmpq *%rax
retq
pushq %rax
leaq 0x5073(%rip), %rdi      # 0x13ab8
leaq 0x4f48(%rip), %rsi      # 0x13994
leaq 0x5069(%rip), %rcx      # 0x13abc
movl $0x12c, %edx            # imm = 0x12C
callq 0x4260
nop
// File: /workspace/github_cpp_makefile_star2_O1/theuni[P]libbtcnet/src/connectionbase.cpp
// Function: ConnectionBase::wrote_data(evbuffer*, evbuffer_cb_info const*, void*)
void ConnectionBase::wrote_data(struct evbuffer* /*unused*/, const struct evbuffer_cb_info* info, void* ctx)
{
    assert(ctx);
    if (info->n_deleted != 0u) {
        ConnectionBase* base = static_cast<ConnectionBase*>(ctx);
        base->m_bytes_written += info->n_deleted;
        base->m_handler.m_interface.OnBytesWritten(base->m_id, info->n_deleted, base->m_bytes_written);
        DEBUG_PRINT(LOGALL, "id:", base->m_id, "Wrote:", info->n_deleted, "bytes. Total:", base->m_bytes_written);
    }
}

// Assembly:
testq %rdx, %rdx
je 0xea9f
movq %rdx, %rax
movq 0x10(%rsi), %rdx
testq %rdx, %rdx
je 0xea9e
movq 0x1a0(%rax), %rcx
addq %rdx, %rcx
movq %rcx, 0x1a0(%rax)
movq 0x8(%rax), %rdi
movq 0x190(%rax), %rsi
movq 0xc0(%rdi), %rdi
movq (%rdi), %rax
movq 0x88(%rax), %rax
jmpq *%rax
retq
pushq %rax
leaq 0x5011(%rip), %rdi      # 0x13ab8
leaq 0x4ee6(%rip), %rsi      # 0x13994
leaq 0x5069(%rip), %rcx      # 0x13b1e
movl $0x137, %edx            # imm = 0x137
callq 0x4260
nop