	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function poll_output
_poll_output:                           ## @poll_output
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -24
	movq	_audio_devs@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movslq	%esi, %rcx
	movq	(%rax,%rcx,8), %rax
	movq	_OPEN_WRITE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	xorl	%ebx, %ebx
	testl	%ecx, (%rax)
	je	LBB0_7
## %bb.1:
	movq	8(%rax), %rax
	movq	_DMA_MAP_MAPPED@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	testl	%ecx, (%rax)
	je	LBB0_3
## %bb.2:
	cmpq	$0, 16(%rax)
	je	LBB0_7
LBB0_6:
	movq	_POLLOUT@GOTPCREL(%rip), %rax
	movq	_POLLWRNORM@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ebx
	orl	(%rax), %ebx
	jmp	LBB0_7
LBB0_3:
	movq	8(%rax), %rax
	movq	_DMODE_INPUT@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_4
LBB0_7:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%rbp
	retq
LBB0_4:
	movq	_DMODE_NONE@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_6
## %bb.5:
	movl	%esi, %edi
	callq	_DMAbuf_space_in_queue
	testl	%eax, %eax
	jne	LBB0_6
	jmp	LBB0_7
	.cfi_endproc
                                        ## -- End function
	.comm	_audio_devs,8,3                 ## @audio_devs
	.comm	_OPEN_WRITE,4,2                 ## @OPEN_WRITE
	.comm	_DMA_MAP_MAPPED,4,2             ## @DMA_MAP_MAPPED
	.comm	_POLLOUT,4,2                    ## @POLLOUT
	.comm	_POLLWRNORM,4,2                 ## @POLLWRNORM
	.comm	_DMODE_INPUT,8,3                ## @DMODE_INPUT
	.comm	_DMODE_NONE,8,3                 ## @DMODE_NONE
	.no_dead_strip	_poll_output
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function poll_output
_poll_output:                           ; @poll_output
	.cfi_startproc
; %bb.0:
	stp	x29, x30, [sp, #-16]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 16
	mov	x29, sp
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
Lloh0:
	adrp	x8, _audio_devs@GOTPAGE
Lloh1:
	ldr	x8, [x8, _audio_devs@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	ldr	x8, [x8, w1, sxtw #3]
	ldr	w9, [x8]
Lloh3:
	adrp	x10, _OPEN_WRITE@GOTPAGE
Lloh4:
	ldr	x10, [x10, _OPEN_WRITE@GOTPAGEOFF]
Lloh5:
	ldr	w10, [x10]
	tst	w10, w9
	b.eq	LBB0_6
; %bb.1:
	ldr	x8, [x8, #8]
	ldr	w9, [x8]
Lloh6:
	adrp	x10, _DMA_MAP_MAPPED@GOTPAGE
Lloh7:
	ldr	x10, [x10, _DMA_MAP_MAPPED@GOTPAGEOFF]
Lloh8:
	ldr	w10, [x10]
	tst	w10, w9
	b.eq	LBB0_5
; %bb.2:
	ldr	x8, [x8, #16]
	cbz	x8, LBB0_6
LBB0_3:
Lloh9:
	adrp	x8, _POLLOUT@GOTPAGE
Lloh10:
	ldr	x8, [x8, _POLLOUT@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
Lloh12:
	adrp	x9, _POLLWRNORM@GOTPAGE
Lloh13:
	ldr	x9, [x9, _POLLWRNORM@GOTPAGEOFF]
Lloh14:
	ldr	w9, [x9]
	orr	w0, w9, w8
LBB0_4:
	ldp	x29, x30, [sp], #16             ; 16-byte Folded Reload
	ret
LBB0_5:
	ldr	x8, [x8, #8]
Lloh15:
	adrp	x9, _DMODE_INPUT@GOTPAGE
Lloh16:
	ldr	x9, [x9, _DMODE_INPUT@GOTPAGEOFF]
Lloh17:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_7
LBB0_6:
	mov	w0, #0
	ldp	x29, x30, [sp], #16             ; 16-byte Folded Reload
	ret
LBB0_7:
Lloh18:
	adrp	x9, _DMODE_NONE@GOTPAGE
Lloh19:
	ldr	x9, [x9, _DMODE_NONE@GOTPAGEOFF]
Lloh20:
	ldr	x9, [x9]
	cmp	x8, x9
	b.eq	LBB0_3
; %bb.8:
	mov	x0, x1
	bl	_DMAbuf_space_in_queue
	cbnz	w0, LBB0_3
	b	LBB0_4
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.cfi_endproc
                                        ; -- End function
	.comm	_audio_devs,8,3                 ; @audio_devs
	.comm	_OPEN_WRITE,4,2                 ; @OPEN_WRITE
	.comm	_DMA_MAP_MAPPED,4,2             ; @DMA_MAP_MAPPED
	.comm	_POLLOUT,4,2                    ; @POLLOUT
	.comm	_POLLWRNORM,4,2                 ; @POLLWRNORM
	.comm	_DMODE_INPUT,8,3                ; @DMODE_INPUT
	.comm	_DMODE_NONE,8,3                 ; @DMODE_NONE
	.no_dead_strip	_poll_output
.subsections_via_symbols
