// File: /workspace/github_cpp_makefile_star2_O3/SaadBazaz[P]RIP-Protocol-Simulation/ProxyRouter.cpp
// Function: sendTableToAllRouters(int)
void sendTableToAllRouters(int ignore_fd = -1){
	auto index_vec = findAllRowsByType("ROUTER");

	for (int i=0; i<index_vec.size(); i++){

		if (table[index_vec[i]].fd == ignore_fd)
			continue;

		cout<<"Index is "<<index_vec[i]<<endl;

		string table_string = serialize (table);
		auto router = table[index_vec[i]];
		auto to_send = constructNewMessage(TABLE, port, router.identifier, (void*)table_string.c_str());
		send (router.fd, to_send.c_str(), to_send.size(), 0);
	}

}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xc8, %rsp
movl %edi, %ebx
leaq 0xb8(%rsp), %r15
movq %r15, -0x10(%r15)
leaq 0x4877(%rip), %rsi      # 0x80df
leaq 0x4876(%rip), %rdx      # 0x80e5
leaq 0xa8(%rsp), %r14
movq %r14, %rdi
callq 0x725c
leaq 0x8(%rsp), %rdi
movq %r14, %rsi
callq 0x3694
movq 0xa8(%rsp), %rdi
cmpq %r15, %rdi
je 0x38a9
movq 0xb8(%rsp), %rsi
incq %rsi
callq 0x2270
movq 0x8(%rsp), %rdi
movq 0x10(%rsp), %rax
cmpq %rdi, %rax
je 0x3a45
leaq 0x70(%rsp), %r14
xorl %r12d, %r12d
movq 0x7705(%rip), %r15      # 0xafd0
movslq (%rdi,%r12,4), %rcx
movq 0x7952(%rip), %rdx      # 0xb228
shlq $0x6, %rcx
cmpl %ebx, 0x4(%rdx,%rcx)
je 0x3a2f
movl $0x9, %edx
movq %r15, %rdi
leaq 0x47f3(%rip), %rsi      # 0x80e6
callq 0x22b0
movq 0x8(%rsp), %rax
movl (%rax,%r12,4), %esi
movq %r15, %rdi
callq 0x2390
movq %rax, %r13
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %r13, %rdi
movl $0xa, %esi
callq 0x2240
movsbl %al, %esi
movq %r13, %rdi
callq 0x2030
movq %rax, %rdi
callq 0x2190
leaq 0x40(%rsp), %rdi
leaq 0x78e9(%rip), %rsi      # 0xb228
callq 0x2763
movq 0x8(%rsp), %rax
movslq (%rax,%r12,4), %rbp
movq 0x78d4(%rip), %r13      # 0xb228
shlq $0x6, %rbp
movups (%r13,%rbp), %xmm0
movaps %xmm0, 0x60(%rsp)
leaq 0x80(%rsp), %rax
movq %rax, 0x70(%rsp)
movq 0x10(%r13,%rbp), %rsi
movq 0x18(%r13,%rbp), %rdx
addq %rsi, %rdx
movq %r14, %rdi
callq 0x71c6
addq %rbp, %r13
movl 0x38(%r13), %eax
movl %eax, 0x28(%r14)
movq 0x30(%r13), %rax
movq %rax, 0x20(%r14)
movl 0x78a2(%rip), %edx      # 0xb240
movl 0x60(%rsp), %ecx
movq 0x40(%rsp), %r8
leaq 0x20(%rsp), %rdi
movl $0x1, %esi
callq 0x2a12
movl 0x64(%rsp), %edi
movq 0x20(%rsp), %rsi
movq 0x28(%rsp), %rdx
xorl %ecx, %ecx
callq 0x2120
movq 0x20(%rsp), %rdi
leaq 0x30(%rsp), %rax
cmpq %rax, %rdi
je 0x39e7
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x2270
movq 0x70(%rsp), %rdi
leaq 0x80(%rsp), %rax
cmpq %rax, %rdi
je 0x3a09
movq 0x80(%rsp), %rsi
incq %rsi
callq 0x2270
movq 0x40(%rsp), %rdi
leaq 0x50(%rsp), %rax
cmpq %rax, %rdi
je 0x3a25
movq 0x50(%rsp), %rsi
incq %rsi
callq 0x2270
movq 0x8(%rsp), %rdi
movq 0x10(%rsp), %rax
incq %r12
movq %rax, %rcx
subq %rdi, %rcx
sarq $0x2, %rcx
cmpq %r12, %rcx
ja 0x38cb
testq %rdi, %rdi
je 0x3a57
movq 0x18(%rsp), %rsi
subq %rdi, %rsi
callq 0x2270
addq $0xc8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
movq 0xa8(%rsp), %rdi
cmpq %r15, %rdi
je 0x3b12
movq 0xb8(%rsp), %rsi
incq %rsi
jmp 0x3b0d
jmp 0x3af8
movq %rax, %rbx
jmp 0x3ab8
movq %rax, %rbx
jmp 0x3ada
movq %rax, %rbx
movq 0x20(%rsp), %rdi
leaq 0x30(%rsp), %rax
cmpq %rax, %rdi
je 0x3ab8
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x2270
movq 0x70(%rsp), %rdi
leaq 0x80(%rsp), %rax
cmpq %rax, %rdi
je 0x3ada
movq 0x80(%rsp), %rsi
incq %rsi
callq 0x2270
movq 0x40(%rsp), %rdi
leaq 0x50(%rsp), %rax
cmpq %rax, %rdi
je 0x3afb
movq 0x50(%rsp), %rsi
incq %rsi
callq 0x2270
jmp 0x3afb
movq %rax, %rbx
movq 0x8(%rsp), %rdi
testq %rdi, %rdi
je 0x3b12
movq 0x18(%rsp), %rsi
subq %rdi, %rsi
callq 0x2270
movq %rbx, %rdi
callq 0x23a0