// File: /workspace/github_c_makefile_star2_O0/martintopholm[P]xping/xping.c
// Function: target_probe
static void
target_probe(int fd, short what, void *thunk)
{
	struct target *t = thunk;

	/* Missed request */
	if (t->npkts > 0 && GETRES(t, -1) != '.') {
		if (GETRES(t, -1) == ' ')
			target_mark(t, t->npkts - 1, '?');
		if (A_flag == 1)
			bell();
		else if (A_flag >= 2 &&
		    GETRES(t, -4) == '.' &&
		    GETRES(t, -3) == '.' &&
		    GETRES(t, -2) != '.' &&
		    GETRES(t, -1) != '.')
			bell();
	}

	/* Check packet count limit */
	if (c_count && t->npkts >= c_count) {
		numcomplete++;
		event_del(t->ev_write);
		if (numcomplete >= numtargets) {
			event_base_loopexit(ev_base, NULL);
		}
		return;
	}

	/* Transmit request */
	t->res[t->npkts % NUM] = ' ';
	probe_send(t->prb, t->npkts);
	t->npkts++;

	ui_update(t);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movw %si, %ax
movl %edi, -0x4(%rbp)
movw %ax, -0x6(%rbp)
movq %rdx, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x18(%rbp)
movq -0x18(%rbp), %rax
cmpl $0x0, 0x40(%rax)
jle 0x31f7
movq -0x18(%rbp), %rax
movq %rax, -0x20(%rbp)
movq -0x18(%rbp), %rax
movl 0x40(%rax), %eax
addl $-0x1, %eax
movl $0x12c, %ecx            # imm = 0x12C
cltd
idivl %ecx
movq -0x20(%rbp), %rax
movslq %edx, %rcx
movsbl 0x44(%rax,%rcx), %eax
cmpl $0x2e, %eax
je 0x31f7
movq -0x18(%rbp), %rax
movq %rax, -0x28(%rbp)
movq -0x18(%rbp), %rax
movl 0x40(%rax), %eax
addl $-0x1, %eax
movl $0x12c, %ecx            # imm = 0x12C
cltd
idivl %ecx
movq -0x28(%rbp), %rax
movslq %edx, %rcx
movsbl 0x44(%rax,%rcx), %eax
cmpl $0x20, %eax
jne 0x311e
movq -0x18(%rbp), %rdi
movq -0x18(%rbp), %rax
movl 0x40(%rax), %esi
subl $0x1, %esi
movl $0x3f, %edx
callq 0x2550
cmpl $0x1, 0x6143(%rip)      # 0x9268
jne 0x3131
callq 0x26f0
jmp 0x31f5
cmpl $0x2, 0x6130(%rip)      # 0x9268
jl 0x31f3
movq -0x18(%rbp), %rax
movq %rax, -0x30(%rbp)
movq -0x18(%rbp), %rax
movl 0x40(%rax), %eax
addl $-0x4, %eax
movl $0x12c, %ecx            # imm = 0x12C
cltd
idivl %ecx
movq -0x30(%rbp), %rax
movslq %edx, %rcx
movsbl 0x44(%rax,%rcx), %eax
cmpl $0x2e, %eax
jne 0x31f3
movq -0x18(%rbp), %rax
movq %rax, -0x38(%rbp)
movq -0x18(%rbp), %rax
movl 0x40(%rax), %eax
addl $-0x3, %eax
movl $0x12c, %ecx            # imm = 0x12C
cltd
idivl %ecx
movq -0x38(%rbp), %rax
movslq %edx, %rcx
movsbl 0x44(%rax,%rcx), %eax
cmpl $0x2e, %eax
jne 0x31f3
movq -0x18(%rbp), %rax
movq %rax, -0x40(%rbp)
movq -0x18(%rbp), %rax
movl 0x40(%rax), %eax
addl $-0x2, %eax
movl $0x12c, %ecx            # imm = 0x12C
cltd
idivl %ecx
movq -0x40(%rbp), %rax
movslq %edx, %rcx
movsbl 0x44(%rax,%rcx), %eax
cmpl $0x2e, %eax
je 0x31f3
movq -0x18(%rbp), %rax
movq %rax, -0x48(%rbp)
movq -0x18(%rbp), %rax
movl 0x40(%rax), %eax
addl $-0x1, %eax
movl $0x12c, %ecx            # imm = 0x12C
cltd
idivl %ecx
movq -0x48(%rbp), %rax
movslq %edx, %rcx
movsbl 0x44(%rax,%rcx), %eax
cmpl $0x2e, %eax
je 0x31f3
callq 0x26f0
jmp 0x31f5
jmp 0x31f7
cmpl $0x0, 0x6066(%rip)      # 0x9264
je 0x324e
movq -0x18(%rbp), %rax
movl 0x40(%rax), %eax
cmpl 0x6057(%rip), %eax      # 0x9264
jl 0x324e
movl 0x606f(%rip), %eax      # 0x9284
addl $0x1, %eax
movl %eax, 0x6066(%rip)      # 0x9284
movq -0x18(%rbp), %rax
movq 0x180(%rax), %rdi
callq 0x23b0
movl 0x6050(%rip), %eax      # 0x9284
cmpl 0x6046(%rip), %eax      # 0x9280
jl 0x324c
movq 0x604d(%rip), %rdi      # 0x9290
xorl %eax, %eax
movl %eax, %esi
callq 0x2170
jmp 0x32a2
movq -0x18(%rbp), %rax
movq %rax, -0x50(%rbp)
movq -0x18(%rbp), %rax
movl 0x40(%rax), %eax
movl $0x12c, %ecx            # imm = 0x12C
cltd
idivl %ecx
movq -0x50(%rbp), %rax
movslq %edx, %rcx
movb $0x20, 0x44(%rax,%rcx)
movq -0x18(%rbp), %rax
movq 0x178(%rax), %rdi
movq -0x18(%rbp), %rax
movl 0x40(%rax), %esi
callq 0x3ae0
movq -0x18(%rbp), %rax
movl 0x40(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0x40(%rax)
movq 0x5f94(%rip), %rax      # 0x9230
movq -0x18(%rbp), %rdi
callq *%rax
addq $0x50, %rsp
popq %rbp
retq
nopl (%rax,%rax)