// File: /workspace/github_c_makefile_star2_O0/jech[P]shncpd/send.c
// Function: buffer_node_state
int
buffer_node_state(struct node *node, int full,
                  const struct sockaddr_in6 *sin6, struct interface *interface)
{
    int buflen = full ? 20 + node->datalen : 20;
    unsigned char buf[buflen];
    int i = 0;
    long long orig_delay =
        (now.tv_sec - node->orig_time.tv_sec) * 1000LL +
        ((long long)now.tv_nsec - node->orig_time.tv_nsec + 999999) / 1000000;

    BYTES(node->id, 4);
    LONG(node->seqno);
    LONG((unsigned)orig_delay);
    BYTES(node->datahash, 8);
    if(full) {
        BYTES(node->data, node->datalen);
    }
    assert(i == buflen);
    debugf("-> NODE-STATE %s%s\n",
           format_32(node->id),
           full && interface ? " (full, multicast)" :
           full ? " (full)" :
           interface ? " (multicast)" : "");
    return buffer_tlv(5, buf, buflen, sin6, interface);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x80, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
cmpl $0x0, -0xc(%rbp)
je 0x5b2f
movq -0x8(%rbp), %rax
movl 0x18(%rax), %eax
addl $0x14, %eax
movl %eax, -0x54(%rbp)
jmp 0x5b39
movl $0x14, %eax
movl %eax, -0x54(%rbp)
jmp 0x5b39
movl -0x54(%rbp), %eax
movl %eax, -0x24(%rbp)
movl -0x24(%rbp), %eax
movq %rsp, %rcx
movq %rcx, -0x30(%rbp)
movq %rax, %rdx
addq $0xf, %rdx
andq $-0x10, %rdx
movq %rsp, %rcx
subq %rdx, %rcx
movq %rcx, -0x60(%rbp)
movq %rcx, %rsp
movq %rax, -0x38(%rbp)
movl $0x0, -0x3c(%rbp)
leaq 0x1070d(%rip), %rax     # 0x16280
movq (%rax), %rax
movq -0x8(%rbp), %rcx
subq 0x28(%rcx), %rax
imulq $0x3e8, %rax, %rcx      # imm = 0x3E8
leaq 0x106f4(%rip), %rax     # 0x16280
movq 0x8(%rax), %rax
movq -0x8(%rbp), %rdx
subq 0x30(%rdx), %rax
addq $0xf423f, %rax          # imm = 0xF423F
movl $0xf4240, %esi          # imm = 0xF4240
cqto
idivq %rsi
movq %rax, %rdx
movq -0x60(%rbp), %rax
addq %rdx, %rcx
movq %rcx, -0x48(%rbp)
movslq -0x3c(%rbp), %rcx
movq -0x8(%rbp), %rdx
movl 0x8(%rdx), %edx
movl %edx, (%rax,%rcx)
movl -0x3c(%rbp), %eax
addl $0x4, %eax
movl %eax, -0x3c(%rbp)
movq -0x8(%rbp), %rax
movl 0x24(%rax), %edi
callq 0x2160
movl %eax, %ecx
movq -0x60(%rbp), %rax
movl %ecx, -0x4c(%rbp)
movslq -0x3c(%rbp), %rcx
movl -0x4c(%rbp), %edx
movl %edx, (%rax,%rcx)
jmp 0x5bee
movl -0x3c(%rbp), %eax
addl $0x4, %eax
movl %eax, -0x3c(%rbp)
movq -0x48(%rbp), %rax
movl %eax, %edi
callq 0x2160
movl %eax, %ecx
movq -0x60(%rbp), %rax
movl %ecx, -0x50(%rbp)
movslq -0x3c(%rbp), %rcx
movl -0x50(%rbp), %edx
movl %edx, (%rax,%rcx)
jmp 0x5c17
movq -0x60(%rbp), %rax
movl -0x3c(%rbp), %ecx
addl $0x4, %ecx
movl %ecx, -0x3c(%rbp)
movslq -0x3c(%rbp), %rcx
movq -0x8(%rbp), %rdx
movq 0x1c(%rdx), %rdx
movq %rdx, (%rax,%rcx)
movl -0x3c(%rbp), %eax
addl $0x8, %eax
movl %eax, -0x3c(%rbp)
cmpl $0x0, -0xc(%rbp)
je 0x5c71
movq -0x60(%rbp), %rdi
movslq -0x3c(%rbp), %rax
addq %rax, %rdi
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rsi
movq -0x8(%rbp), %rax
movl 0x18(%rax), %eax
movl %eax, %edx
callq 0x2230
movq -0x8(%rbp), %rax
movl 0x18(%rax), %eax
addl -0x3c(%rbp), %eax
movl %eax, -0x3c(%rbp)
movl -0x3c(%rbp), %eax
cmpl -0x24(%rbp), %eax
jne 0x5c7b
jmp 0x5c9a
leaq 0xcafe(%rip), %rdi      # 0x12780
leaq 0xcb03(%rip), %rsi      # 0x1278c
movl $0xb1, %edx
leaq 0xcafe(%rip), %rcx      # 0x12793
callq 0x2150
jmp 0x5c9c
leaq 0x105c5(%rip), %rax     # 0x16268
cmpl $0x2, (%rax)
jl 0x5d27
movq -0x8(%rbp), %rdi
addq $0x8, %rdi
callq 0xfc40
movq %rax, -0x68(%rbp)
cmpl $0x0, -0xc(%rbp)
je 0x5cd3
cmpq $0x0, -0x20(%rbp)
je 0x5cd3
leaq 0xcb35(%rip), %rax      # 0x12802
movq %rax, -0x70(%rbp)
jmp 0x5d0c
cmpl $0x0, -0xc(%rbp)
je 0x5ce6
leaq 0xcb35(%rip), %rax      # 0x12815
movq %rax, -0x78(%rbp)
jmp 0x5d04
movq -0x20(%rbp), %rdx
leaq 0xccf5(%rip), %rax      # 0x129e6
leaq 0xca7b(%rip), %rcx      # 0x12773
cmpq $0x0, %rdx
cmovneq %rcx, %rax
movq %rax, -0x78(%rbp)
movq -0x78(%rbp), %rax
movq %rax, -0x70(%rbp)
movq -0x68(%rbp), %rdx
movq -0x70(%rbp), %rcx
movl $0x2, %edi
leaq 0xcace(%rip), %rsi      # 0x127ee
movb $0x0, %al
callq 0xfda0
jmp 0x5d29
jmp 0x5d2b
movq -0x60(%rbp), %rsi
movl -0x24(%rbp), %edx
movq -0x18(%rbp), %rcx
movq -0x20(%rbp), %r8
movl $0x5, %edi
callq 0x5790
movq -0x30(%rbp), %rcx
movq %rcx, %rsp
movq %rbp, %rsp
popq %rbp
retq