// File: /workspace/github_c_makefile_star2_O1/jech[P]dht/dht.c
// Function: send_find_node
int
send_find_node(const struct sockaddr *sa, int salen,
               const unsigned char *tid, int tid_len,
               const unsigned char *target, int want, int confirm)
{
    char buf[512];
    int i = 0, rc;
    rc = snprintf(buf + i, 512 - i, "d1:ad2:id20:"); INC(i, rc, 512);
    COPY(buf, i, myid, 20, 512);
    rc = snprintf(buf + i, 512 - i, "6:target20:"); INC(i, rc, 512);
    COPY(buf, i, target, 20, 512);
    if(want > 0) {
        rc = snprintf(buf + i, 512 - i, "4:wantl%s%se",
                      (want & WANT4) ? "2:n4" : "",
                      (want & WANT6) ? "2:n6" : "");
        INC(i, rc, 512);
    }
    rc = snprintf(buf + i, 512 - i, "e1:q9:find_node1:t%d:", tid_len);
    INC(i, rc, 512);
    COPY(buf, i, tid, tid_len, 512);
    ADD_V(buf, i, 512);
    rc = snprintf(buf + i, 512 - i, "1:y1:qe"); INC(i, rc, 512);
    return dht_send(buf, i, confirm ? MSG_CONFIRM : 0, sa, salen);

 fail:
    errno = ENOSPC;
    return -1;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x208, %rsp            # imm = 0x208
movl %r9d, %ebp
movq %rdx, %r15
movl %esi, %ebx
movq %rdi, %r14
movabsq $0x3a303264693a32, %rax # imm = 0x3A303264693A32
movq %rax, 0x5(%rsp)
movabsq $0x693a3264613a3164, %rax # imm = 0x693A3264613A3164
movq %rax, (%rsp)
movl 0x5844(%rip), %eax      # 0xdc40
movl %eax, 0x1c(%rsp)
movaps 0x5829(%rip), %xmm0     # 0xdc30
movups %xmm0, 0xc(%rsp)
movabsq $0x7465677261743a36, %rax # imm = 0x7465677261743A36
movq %rax, 0x20(%rsp)
movl $0x3a3032, 0x28(%rsp)   # imm = 0x3A3032
movups (%rcx), %xmm0
movups %xmm0, 0x2b(%rsp)
movl 0x10(%rcx), %eax
movl %eax, 0x3b(%rsp)
testl %r8d, %r8d
jle 0x8484
leaq 0x3f(%rsp), %rdi
testb $0x1, %r8b
leaq 0xee1(%rip), %rax       # 0x9328
leaq 0x1483(%rip), %rcx      # 0x98d1
cmoveq %rax, %rcx
testb $0x2, %r8b
leaq 0x1479(%rip), %r8       # 0x98d6
cmoveq %rax, %r8
leaq 0x145c(%rip), %rdx      # 0x98c4
movl $0x1c1, %esi            # imm = 0x1C1
xorl %eax, %eax
callq 0x2110
cmpl $0x1c1, %eax            # imm = 0x1C1
ja 0x852b
addl $0x3f, %eax
jmp 0x8489
movl $0x3f, %eax
movl %eax, %r12d
leaq (%rsp,%r12), %rdi
movl $0x200, %esi            # imm = 0x200
subl %eax, %esi
leaq 0x14b0(%rip), %rdx      # 0x994e
movl $0x4, %ecx
xorl %eax, %eax
callq 0x2110
testl %eax, %eax
js 0x852b
movl %eax, %eax
addq %rax, %r12
cmpl $0x200, %r12d           # imm = 0x200
jg 0x852b
cmpl $0x1fc, %r12d           # imm = 0x1FC
jg 0x852b
leal 0x4(%r12), %r13d
movl (%r15), %eax
movl %eax, (%rsp,%r12)
cmpb $0x1, 0x57a4(%rip)      # 0xdc7c
jne 0x8500
cmpl $0x1f3, %r12d           # imm = 0x1F3
ja 0x852b
movl %r13d, %eax
leal 0xd(%r12), %r13d
movb 0x5787(%rip), %cl       # 0xdc78
movb %cl, 0x8(%rsp,%rax)
movq 0x5774(%rip), %rcx      # 0xdc70
movq %rcx, (%rsp,%rax)
movl %r13d, %eax
leaq (%rsp,%rax), %rdi
movl $0x200, %esi            # imm = 0x200
subl %r13d, %esi
leaq 0x11c2(%rip), %rdx      # 0x96d8
xorl %eax, %eax
callq 0x2110
testl %eax, %eax
js 0x852b
addl %r13d, %eax
cmpl $0x200, %eax            # imm = 0x200
jle 0x8548
callq 0x2060
movl $0x1c, (%rax)
addq $0x208, %rsp            # imm = 0x208
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl %eax, %esi
xorl %edx, %edx
testl %ebp, %ebp
setne %dl
shll $0xb, %edx
movq %rsp, %rdi
movq %r14, %rcx
movl %ebx, %r8d
callq 0x8058
jmp 0x8536