// File: ynilu[P]elastic/graph.cpp
// Function: Phy_graph::assign_transceivers(int, int, int)
void Phy_graph::assign_transceivers(int num_OTDM_transceiver, int num_OFDM_transceiver, int transceiver_connection_limit)
{
    for(auto &node : node_list)
    {
        node.transmitter.resize(num_OTDM_transceiver * node.degree);
        node.num_available_transmitter = num_OTDM_transceiver * node.degree;

        node.receiver.resize(num_OTDM_transceiver * node.degree);
        node.num_available_receiver = num_OTDM_transceiver * node.degree;

        node.OFDMtransmitter.resize(num_OFDM_transceiver * node.degree, OFDMTransceiver(transceiver_connection_limit));
        node.num_available_OFDM_transmitter = num_OFDM_transceiver * node.degree;

        node.OFDMreceiver.resize(num_OFDM_transceiver * node.degree, OFDMTransceiver(transceiver_connection_limit));
        node.num_available_OFDM_receiver = num_OFDM_transceiver * node.degree;
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x130, %rsp            # imm = 0x130
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movl %edx, -0x10(%rbp)
movl %ecx, -0x14(%rbp)
movq -0x8(%rbp), %rax
addq $0x8, %rax
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rdi
callq 0x1bc20
movq %rax, -0x28(%rbp)
movq -0x20(%rbp), %rdi
callq 0x1bc50
movq %rax, -0x30(%rbp)
leaq -0x28(%rbp), %rdi
leaq -0x30(%rbp), %rsi
callq 0x1bc80
testb $0x1, %al
jne 0x1acd4
jmp 0x1ae6d
leaq -0x28(%rbp), %rdi
callq 0x1bcc0
movq %rax, -0x38(%rbp)
movq -0x38(%rbp), %rcx
movq %rcx, %rdi
addq $0x38, %rdi
movl -0xc(%rbp), %eax
movl 0x8(%rcx), %ecx
imull %ecx, %eax
movslq %eax, %rsi
callq 0x1bce0
movl -0xc(%rbp), %ecx
movq -0x38(%rbp), %rax
movl 0x8(%rax), %edx
imull %edx, %ecx
movl %ecx, 0x28(%rax)
movq -0x38(%rbp), %rcx
movq %rcx, %rdi
addq $0x50, %rdi
movl -0xc(%rbp), %eax
movl 0x8(%rcx), %ecx
imull %ecx, %eax
movslq %eax, %rsi
callq 0x1bce0
movl -0xc(%rbp), %ecx
movq -0x38(%rbp), %rax
movl 0x8(%rax), %edx
imull %edx, %ecx
movl %ecx, 0x30(%rax)
movq -0x38(%rbp), %rcx
movq %rcx, %rax
addq $0x68, %rax
movq %rax, -0x110(%rbp)
movl -0x10(%rbp), %eax
movl 0x8(%rcx), %ecx
imull %ecx, %eax
cltq
movq %rax, -0x108(%rbp)
movl -0x14(%rbp), %esi
leaq -0x90(%rbp), %rdi
movq %rdi, -0x100(%rbp)
callq 0x1b950
movq -0x110(%rbp), %rdi
movq -0x108(%rbp), %rsi
movq -0x100(%rbp), %rdx
callq 0x1bd70
jmp 0x1ad8f
leaq -0x90(%rbp), %rdi
callq 0x1ba10
movl -0x10(%rbp), %ecx
movq -0x38(%rbp), %rax
movl 0x8(%rax), %edx
imull %edx, %ecx
movl %ecx, 0x2c(%rax)
movq -0x38(%rbp), %rcx
movq %rcx, %rax
subq $-0x80, %rax
movq %rax, -0x128(%rbp)
movl -0x10(%rbp), %eax
movl 0x8(%rcx), %ecx
imull %ecx, %eax
cltq
movq %rax, -0x120(%rbp)
movl -0x14(%rbp), %esi
leaq -0xf8(%rbp), %rdi
movq %rdi, -0x118(%rbp)
callq 0x1b950
movq -0x128(%rbp), %rdi
movq -0x120(%rbp), %rsi
movq -0x118(%rbp), %rdx
callq 0x1bd70
jmp 0x1ae01
leaq -0xf8(%rbp), %rdi
callq 0x1ba10
movl -0x10(%rbp), %ecx
movq -0x38(%rbp), %rax
imull 0x8(%rax), %ecx
movq -0x38(%rbp), %rax
movl %ecx, 0x34(%rax)
leaq -0x28(%rbp), %rdi
callq 0x1be20
jmp 0x1acbe
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x98(%rbp)
movl %eax, -0x9c(%rbp)
leaq -0x90(%rbp), %rdi
callq 0x1ba10
jmp 0x1ae76
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x98(%rbp)
movl %eax, -0x9c(%rbp)
leaq -0xf8(%rbp), %rdi
callq 0x1ba10
jmp 0x1ae76
addq $0x130, %rsp            # imm = 0x130
popq %rbp
retq
movq -0x98(%rbp), %rdi
callq 0x3340
nopw %cs:(%rax,%rax)