	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function X11_PendingInput
_X11_PendingInput:                      ## @X11_PendingInput
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r15
	pushq	%r14
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	_dpy@GOTPCREL(%rip), %r15
	xorl	%edi, %edi
	cmpq	$0, (%r15)
	setne	%dil
	callq	_assert
	movq	(%r15), %rdi
	callq	_XFlush
	movq	(%r15), %rdi
	movq	_QueuedAlready@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_XEventsQueued
	testq	%rax, %rax
	je	LBB0_2
## %bb.1:
	movq	_qtrue@GOTPCREL(%rip), %rax
	jmp	LBB0_6
LBB0_2:
	movq	(%r15), %rdi
	callq	_ConnectionNumber
	movl	%eax, %ebx
	leaq	-28(%rbp), %r14
	movq	%r14, %rdi
	callq	_FD_ZERO
	movl	%ebx, %edi
	movq	%r14, %rsi
	callq	_FD_SET
	incl	%ebx
	leaq	_X11_PendingInput.zero_time(%rip), %r8
	movl	%ebx, %edi
	movq	%r14, %rsi
	xorl	%edx, %edx
	xorl	%ecx, %ecx
	callq	_select
	movl	%eax, %ebx
                                        ## implicit-def: $eax
	cmpl	$1, %ebx
	jne	LBB0_4
## %bb.3:
	movq	(%r15), %rdi
	callq	_XPending
LBB0_4:
	cmpl	$1, %ebx
	je	LBB0_7
## %bb.5:
	movq	_qfalse@GOTPCREL(%rip), %rax
LBB0_6:
	movl	(%rax), %eax
LBB0_7:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_dpy,8,3                        ## @dpy
	.comm	_QueuedAlready,4,2              ## @QueuedAlready
	.comm	_qtrue,4,2                      ## @qtrue
.zerofill __DATA,__bss,_X11_PendingInput.zero_time,4,2 ## @X11_PendingInput.zero_time
	.comm	_qfalse,4,2                     ## @qfalse
	.no_dead_strip	_X11_PendingInput
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function X11_PendingInput
_X11_PendingInput:                      ; @X11_PendingInput
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
Lloh0:
	adrp	x20, _dpy@GOTPAGE
Lloh1:
	ldr	x20, [x20, _dpy@GOTPAGEOFF]
	ldr	x8, [x20]
	cmp	x8, #0
	cset	w0, ne
	bl	_assert
	ldr	x0, [x20]
	bl	_XFlush
	ldr	x0, [x20]
Lloh2:
	adrp	x8, _QueuedAlready@GOTPAGE
Lloh3:
	ldr	x8, [x8, _QueuedAlready@GOTPAGEOFF]
Lloh4:
	ldr	w1, [x8]
	bl	_XEventsQueued
	cbz	x0, LBB0_2
; %bb.1:
Lloh5:
	adrp	x8, _qtrue@GOTPAGE
Lloh6:
	ldr	x8, [x8, _qtrue@GOTPAGEOFF]
Lloh7:
	ldr	w0, [x8]
	b	LBB0_5
LBB0_2:
	ldr	x0, [x20]
	bl	_ConnectionNumber
	mov	x19, x0
	add	x0, sp, #12
	bl	_FD_ZERO
	add	x1, sp, #12
	mov	x0, x19
	bl	_FD_SET
	add	w0, w19, #1
Lloh8:
	adrp	x4, _X11_PendingInput.zero_time@PAGE
Lloh9:
	add	x4, x4, _X11_PendingInput.zero_time@PAGEOFF
	add	x1, sp, #12
	mov	x2, #0
	mov	x3, #0
	bl	_select
	mov	x19, x0
                                        ; implicit-def: $w0
	cmp	w19, #1
	b.ne	LBB0_4
; %bb.3:
	ldr	x0, [x20]
	bl	_XPending
LBB0_4:
Lloh10:
	adrp	x8, _qfalse@GOTPAGE
Lloh11:
	ldr	x8, [x8, _qfalse@GOTPAGEOFF]
Lloh12:
	ldr	w8, [x8]
	cmp	w19, #1
	csel	w0, w0, w8, eq
LBB0_5:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.cfi_endproc
                                        ; -- End function
	.comm	_dpy,8,3                        ; @dpy
	.comm	_QueuedAlready,4,2              ; @QueuedAlready
	.comm	_qtrue,4,2                      ; @qtrue
.zerofill __DATA,__bss,_X11_PendingInput.zero_time,4,2 ; @X11_PendingInput.zero_time
	.comm	_qfalse,4,2                     ; @qfalse
	.no_dead_strip	_X11_PendingInput
.subsections_via_symbols
