// File: /workspace/github_cpp_makefile_star2_O3/frolosofsky[P]pbft/main.cpp
// Function: Simulator::init_nodes(int, int)
void init_nodes(int f, int n) {
        _client = std::make_shared<ClientNode>();
        for(int i = 0; i < n; ++i) {
            _nodes.emplace_back(std::make_shared<PBFTNode>(i == 0 ? PBFTNode::Role::Primary : PBFTNode::Role::Replica, f));
            _nodes[i]->set_primary(_nodes[0]);
            _nodes[i]->set_success_startegy(std::make_unique<PBFT_DB>());
            _links.emplace_back(Link::make(_client, _nodes[i]));
        }
        for(size_t i = 0; i < _nodes.size() - 1; ++i) {
            for(size_t j = i + 1; j < _nodes.size(); ++j) {
                _links.emplace_back(Link::make(_nodes[i], _nodes[j]));
            }
        }

    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x58, %rsp
movl %edx, %r15d
movq %rdi, %rbx
movl %esi, -0x74(%rbp)
leaq -0x40(%rbp), %r14
leaq -0x50(%rbp), %rsi
movq %r14, %rdi
callq 0x3a10
movaps (%r14), %xmm0
xorps %xmm1, %xmm1
movaps %xmm1, (%r14)
movq 0x8(%rbx), %rdi
movups %xmm0, (%rbx)
testq %rdi, %rdi
je 0x35ae
callq 0x2ddc
movq -0x38(%rbp), %rdi
testq %rdi, %rdi
je 0x35ae
callq 0x2ddc
testl %r15d, %r15d
jle 0x3760
leaq 0x10(%rbx), %r14
leaq 0x28(%rbx), %rax
movq %rax, -0x70(%rbp)
movl %r15d, %eax
shlq $0x4, %rax
movq %rax, -0x68(%rbp)
xorl %r12d, %r12d
leaq -0x40(%rbp), %r13
leaq -0x60(%rbp), %r15
xorl %eax, %eax
testq %r12, %r12
setne %al
movl %eax, -0x50(%rbp)
movq %r13, %rdi
movq %r15, %rsi
leaq -0x50(%rbp), %rdx
leaq -0x74(%rbp), %rcx
callq 0x43f6
movq %r14, %rdi
movq %r13, %rsi
callq 0x3998
movq -0x38(%rbp), %rdi
testq %rdi, %rdi
je 0x3610
callq 0x2ddc
movq (%r14), %rcx
movq (%rcx,%r12), %rdi
movq (%rcx), %rax
movq %rax, -0x40(%rbp)
movq 0x8(%rcx), %rcx
movq %rcx, -0x38(%rbp)
testq %rcx, %rcx
je 0x3644
movq 0x699e(%rip), %rdx      # 0x9fd0
cmpb $0x0, (%rdx)
je 0x363c
incl 0x8(%rcx)
jmp 0x3644
lock
incl 0x8(%rcx)
movq -0x40(%rbp), %rax
movq %r15, %r13
movq %rax, 0x80(%rdi)
addq $0x88, %rdi
leaq -0x38(%rbp), %rsi
callq 0x4202
movq -0x38(%rbp), %rdi
testq %rdi, %rdi
je 0x366c
callq 0x2ddc
movq (%r14), %rax
movq (%rax,%r12), %r15
movl $0x20, %edi
callq 0x2130
leaq 0x66ec(%rip), %rcx      # 0x9d70
movq %rcx, (%rax)
xorps %xmm0, %xmm0
movups %xmm0, 0x8(%rax)
movq $0x0, 0x18(%rax)
movq 0x90(%r15), %rdi
movq %rax, 0x90(%r15)
testq %rdi, %rdi
je 0x36af
movq (%rdi), %rax
callq *0x8(%rax)
movq (%rbx), %rax
movq %rax, -0x50(%rbp)
movq 0x8(%rbx), %rax
movq %rax, -0x48(%rbp)
testq %rax, %rax
movq %r13, %r15
leaq -0x40(%rbp), %r13
je 0x36df
movq 0x68ff(%rip), %rcx      # 0x9fd0
cmpb $0x0, (%rcx)
je 0x36db
incl 0x8(%rax)
jmp 0x36df
lock
incl 0x8(%rax)
movq (%r14), %rax
movq (%rax,%r12), %rcx
movq %rcx, -0x60(%rbp)
movq 0x8(%rax,%r12), %rax
movq %rax, -0x58(%rbp)
testq %rax, %rax
je 0x370d
movq 0x68d1(%rip), %rcx      # 0x9fd0
cmpb $0x0, (%rcx)
je 0x3709
incl 0x8(%rax)
jmp 0x370d
lock
incl 0x8(%rax)
movq %r13, %rdi
leaq -0x50(%rbp), %rsi
movq %r15, %rdx
callq 0x2912
movq -0x70(%rbp), %rdi
movq %r13, %rsi
callq 0x39d4
movq -0x38(%rbp), %rdi
testq %rdi, %rdi
je 0x3736
callq 0x2ddc
movq -0x58(%rbp), %rdi
testq %rdi, %rdi
je 0x3744
callq 0x2ddc
movq -0x48(%rbp), %rdi
testq %rdi, %rdi
je 0x3752
callq 0x2ddc
addq $0x10, %r12
cmpq %r12, -0x68(%rbp)
jne 0x35d9
movq 0x10(%rbx), %rax
movq 0x18(%rbx), %rcx
movq %rcx, %rdx
subq %rax, %rdx
cmpq $0x10, %rdx
je 0x388a
leaq 0x28(%rbx), %rdx
movq %rdx, -0x70(%rbp)
movl $0x18, %r12d
xorl %r13d, %r13d
leaq -0x40(%rbp), %r15
leaq 0x1(%r13), %r14
movq %rcx, %rdx
subq %rax, %rdx
sarq $0x4, %rdx
cmpq %rdx, %r14
movq %r12, -0x68(%rbp)
movq %r14, -0x80(%rbp)
jae 0x3872
shlq $0x4, %r13
movq (%rax,%r13), %rcx
movq %rcx, -0x50(%rbp)
movq 0x8(%rax,%r13), %rcx
movq %rcx, -0x48(%rbp)
testq %rcx, %rcx
je 0x37df
movq 0x6803(%rip), %rdx      # 0x9fd0
cmpb $0x0, (%rdx)
je 0x37d7
incl 0x8(%rcx)
jmp 0x37df
lock
incl 0x8(%rcx)
movq 0x10(%rbx), %rax
movq -0x8(%rax,%r12), %rcx
movq %rcx, -0x60(%rbp)
movq (%rax,%r12), %rax
movq %rax, -0x58(%rbp)
testq %rax, %rax
je 0x380a
movq 0x67d4(%rip), %rcx      # 0x9fd0
cmpb $0x0, (%rcx)
je 0x3806
incl 0x8(%rax)
jmp 0x380a
lock
incl 0x8(%rax)
movq %r15, %rdi
leaq -0x50(%rbp), %rsi
leaq -0x60(%rbp), %rdx
callq 0x2912
movq -0x70(%rbp), %rdi
movq %r15, %rsi
callq 0x39d4
movq -0x38(%rbp), %rdi
testq %rdi, %rdi
je 0x3834
callq 0x2ddc
movq -0x58(%rbp), %rdi
testq %rdi, %rdi
je 0x3842
callq 0x2ddc
movq -0x48(%rbp), %rdi
testq %rdi, %rdi
je 0x3850
callq 0x2ddc
incq %r14
movq 0x10(%rbx), %rax
movq 0x18(%rbx), %rcx
movq %rcx, %rdx
subq %rax, %rdx
sarq $0x4, %rdx
addq $0x10, %r12
cmpq %rdx, %r14
jb 0x37b0
decq %rdx
movq -0x68(%rbp), %r12
addq $0x10, %r12
movq -0x80(%rbp), %r13
cmpq %rdx, %r13
jb 0x378d
addq $0x58, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
movq -0x38(%rbp), %rdi
jmp 0x38ce
jmp 0x38b9
jmp 0x38a6
movq %rax, %rbx
movq -0x38(%rbp), %rdi
testq %rdi, %rdi
je 0x38bc
callq 0x2ddc
jmp 0x38bc
movq %rax, %rbx
movq -0x58(%rbp), %rdi
testq %rdi, %rdi
je 0x38ca
callq 0x2ddc
movq -0x48(%rbp), %rdi
testq %rdi, %rdi
je 0x38d8
callq 0x2ddc
movq %rbx, %rdi
callq 0x21f0