// File: /workspace/github_c_makefile_star2_O3/wahern[P]cqueues/src/cqueues.c
// Function: cqueue_pause
static int cqueue_pause(lua_State *L) {
	struct cqueue *Q = cqueue_checkself(L, 1);
	sigset_t block;
	fd_set rfds;
	int index, error;

	if ((error = cqs_sigmask(SIG_SETMASK, NULL, &block)))
		goto error;

	for (index = 2; index <= lua_gettop(L); index++) {
		sigdelset(&block, luaL_checkint(L, index));
	}

	/* FD_SETSIZE unsigned on FreeBSD. */
	if (Q->kp.fd < 0 || Q->kp.fd >= (int)FD_SETSIZE)
		return luaL_error(L, "cqueue:pause: fd %d outside allowable range 0..%d", Q->kp.fd, (int)(FD_SETSIZE - 1));

	FD_ZERO(&rfds);
	FD_SET(Q->kp.fd, &rfds);

	if (-1 == cqs_pselect(Q->kp.fd + 1, &rfds, NULL, NULL, f2ts(cqueue_timeout_(Q)), &block, &error)) {
		if (error != EINTR)
			goto error;
	}

	return 0;
error:
	return luaL_error(L, "cqueue:pause: %s", cqs_strerror(error));
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x1a8, %rsp            # imm = 0x1A8
movq %rdi, %rbx
callq 0x12de1
movq %rax, %r15
leaq 0xa0(%rsp), %r14
movq %r14, %rdi
callq 0x10010
movl $0x2, %edi
xorl %esi, %esi
movq %r14, %rdx
callq 0xf350
testl %eax, %eax
jne 0x12858
movq %rbx, %rdi
callq 0xf920
cmpl $0x2, %eax
jl 0x126cb
movl $0x1, %ebp
leaq 0xa0(%rsp), %r14
incl %ebp
movq %rbx, %rdi
movl %ebp, %esi
callq 0x10a60
movq %r14, %rdi
movl %eax, %esi
callq 0x10060
movq %rbx, %rdi
callq 0xf920
cmpl %eax, %ebp
jl 0x126a9
movl (%r15), %ecx
cmpq $0x3ff, %rcx            # imm = 0x3FF
ja 0x128ab
xorpd %xmm0, %xmm0
movapd %xmm0, 0x90(%rsp)
movapd %xmm0, 0x80(%rsp)
movapd %xmm0, 0x70(%rsp)
movapd %xmm0, 0x60(%rsp)
movapd %xmm0, 0x50(%rsp)
movapd %xmm0, 0x40(%rsp)
movapd %xmm0, 0x30(%rsp)
movapd %xmm0, 0x20(%rsp)
movl $0x1, %eax
shlq %cl, %rax
movl %ecx, %edx
shrl $0x6, %edx
orq %rax, 0x20(%rsp,%rdx,8)
leal 0x1(%rcx), %ebp
movq %rsp, %r14
movapd %xmm0, (%r14)
movq 0x228(%r15), %rdi
callq 0x129d6
movsd %xmm0, 0x10(%rsp)
callq 0xf060
cmpl $0x2, %eax
je 0x1281c
cmpl $0x3, %eax
je 0x127ed
cmpl $0x4, %eax
jne 0x12800
movq 0x10(%rsp), %xmm0
movq %xmm0, %rax
testq %rax, %rax
js 0x1281c
leaq 0x18(%rsp), %r15
movq %r15, %rdi
callq 0x10830
movsd 0x22893(%rip), %xmm1    # 0x35020
mulsd %xmm1, %xmm0
callq 0xf1c0
movsd (%r15), %xmm1
movsd 0x22885(%rip), %xmm2    # 0x35028
addsd %xmm1, %xmm2
movsd 0x22871(%rip), %xmm3    # 0x35020
cmpnlesd %xmm0, %xmm3
andpd %xmm3, %xmm1
andnpd %xmm2, %xmm3
orpd %xmm1, %xmm3
ucomisd 0x22868(%rip), %xmm3    # 0x35030
jae 0x12805
xorl %eax, %eax
ucomisd 0x2284c(%rip), %xmm0    # 0x35020
cvttsd2si %xmm0, %rcx
cmovbq %rcx, %rax
cvttsd2si %xmm3, %rcx
movq %rcx, (%rsp)
movq %rax, 0x8(%rsp)
jmp 0x1281c
movq $0x0, (%rsp)
movq $0x1, 0x8(%rsp)
jmp 0x1281c
xorl %r14d, %r14d
jmp 0x1281c
movabsq $0x7fffffffffffffff, %rax # imm = 0x7FFFFFFFFFFFFFFF
movq %rax, (%rsp)
movq $0x0, 0x8(%rsp)
leaq 0x20(%rsp), %rsi
leaq 0xa0(%rsp), %r9
movl %ebp, %edi
xorl %edx, %edx
xorl %ecx, %ecx
movq %r14, %r8
callq 0xfe20
cmpl $-0x1, %eax
jne 0x12848
callq 0xf0a0
movl (%rax), %eax
cmpl $0x4, %eax
jne 0x12858
xorl %eax, %eax
addq $0x1a8, %rsp            # imm = 0x1A8
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
xorpd %xmm0, %xmm0
leaq 0x120(%rsp), %rsi
movapd %xmm0, 0x70(%rsi)
movapd %xmm0, 0x60(%rsi)
movapd %xmm0, 0x50(%rsi)
movapd %xmm0, 0x40(%rsi)
movapd %xmm0, 0x30(%rsi)
movapd %xmm0, 0x20(%rsi)
movapd %xmm0, 0x10(%rsi)
movapd %xmm0, (%rsi)
movl $0x80, %edx
movl %eax, %edi
callq 0xf250
leaq 0x22bff(%rip), %rsi     # 0x3549d
movq %rbx, %rdi
movq %rax, %rdx
xorl %eax, %eax
callq 0xfd60
leaq 0x22bb9(%rip), %rsi     # 0x3546b
movq %rbx, %rdi
movl %ecx, %edx
movl $0x3ff, %ecx            # imm = 0x3FF
xorl %eax, %eax
callq 0xfd60