	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function au1550_poll
_au1550_poll:                           ## @au1550_poll
	.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	%r13
	pushq	%r12
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r14
	movq	%rdi, %rbx
	movq	8(%rdi), %r15
	movl	(%rdi), %eax
	movq	_FMODE_WRITE@GOTPCREL(%rip), %r12
	testl	%eax, (%r12)
	je	LBB0_3
## %bb.1:
	cmpl	$0, 44(%r15)
	je	LBB0_15
## %bb.2:
	leaq	40(%r15), %rsi
	movq	%rbx, %rdi
	movq	%r14, %rdx
	callq	_poll_wait
	movl	(%rbx), %eax
LBB0_3:
	movq	_FMODE_READ@GOTPCREL(%rip), %r13
	testl	%eax, (%r13)
	je	LBB0_6
## %bb.4:
	cmpl	$0, 68(%r15)
	je	LBB0_15
## %bb.5:
	leaq	64(%r15), %rsi
	movq	%rbx, %rdi
	movq	%r14, %rdx
	callq	_poll_wait
LBB0_6:
	movq	%r15, %rdi
	callq	_spin_lock_irqsave
	movl	(%rbx), %eax
	xorl	%r14d, %r14d
	testl	%eax, (%r13)
	je	LBB0_9
## %bb.7:
	movl	48(%r15), %ecx
	cmpl	56(%r15), %ecx
	jl	LBB0_9
## %bb.8:
	movq	_POLLIN@GOTPCREL(%rip), %rcx
	movq	_POLLRDNORM@GOTPCREL(%rip), %rdx
	movl	(%rdx), %r14d
	orl	(%rcx), %r14d
LBB0_9:
	testl	%eax, (%r12)
	je	LBB0_13
## %bb.10:
	cmpq	$0, 32(%r15)
	je	LBB0_17
## %bb.11:
	movl	8(%r15), %eax
	cmpl	16(%r15), %eax
	jl	LBB0_13
LBB0_12:
	movq	_POLLOUT@GOTPCREL(%rip), %rax
	movq	_POLLWRNORM@GOTPCREL(%rip), %rcx
	orl	(%rax), %r14d
	orl	(%rcx), %r14d
LBB0_13:
	movq	%r15, %rdi
	callq	_spin_unlock_irqrestore
	jmp	LBB0_16
LBB0_15:
	xorl	%r14d, %r14d
LBB0_16:
	movl	%r14d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_17:
	movl	8(%r15), %eax
	addl	16(%r15), %eax
	cmpl	24(%r15), %eax
	jle	LBB0_12
	jmp	LBB0_13
	.cfi_endproc
                                        ## -- End function
	.comm	_FMODE_WRITE,4,2                ## @FMODE_WRITE
	.comm	_FMODE_READ,4,2                 ## @FMODE_READ
	.comm	_POLLIN,4,2                     ## @POLLIN
	.comm	_POLLRDNORM,4,2                 ## @POLLRDNORM
	.comm	_POLLOUT,4,2                    ## @POLLOUT
	.comm	_POLLWRNORM,4,2                 ## @POLLWRNORM
	.no_dead_strip	_au1550_poll
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function au1550_poll
_au1550_poll:                           ; @au1550_poll
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	mov	x21, x1
	mov	x20, x0
	ldr	x19, [x0, #8]
	ldr	w8, [x0]
Lloh0:
	adrp	x22, _FMODE_WRITE@GOTPAGE
Lloh1:
	ldr	x22, [x22, _FMODE_WRITE@GOTPAGEOFF]
	ldr	w9, [x22]
	tst	w9, w8
	b.eq	LBB0_3
; %bb.1:
	ldr	w8, [x19, #44]
	cbz	w8, LBB0_9
; %bb.2:
	add	x1, x19, #40
	mov	x0, x20
	mov	x2, x21
	bl	_poll_wait
	ldr	w8, [x20]
LBB0_3:
Lloh2:
	adrp	x23, _FMODE_READ@GOTPAGE
Lloh3:
	ldr	x23, [x23, _FMODE_READ@GOTPAGEOFF]
	ldr	w9, [x23]
	tst	w9, w8
	b.eq	LBB0_6
; %bb.4:
	ldr	w8, [x19, #68]
	cbz	w8, LBB0_9
; %bb.5:
	add	x1, x19, #64
	mov	x0, x20
	mov	x2, x21
	bl	_poll_wait
LBB0_6:
	mov	x0, x19
	bl	_spin_lock_irqsave
	ldr	w8, [x20]
	ldr	w9, [x23]
	tst	w9, w8
	b.eq	LBB0_8
; %bb.7:
	ldr	w9, [x19, #48]
	ldr	w10, [x19, #56]
	cmp	w9, w10
	b.ge	LBB0_10
LBB0_8:
	mov	w20, #0
	b	LBB0_11
LBB0_9:
	mov	w20, #0
	b	LBB0_16
LBB0_10:
Lloh4:
	adrp	x9, _POLLIN@GOTPAGE
Lloh5:
	ldr	x9, [x9, _POLLIN@GOTPAGEOFF]
Lloh6:
	ldr	w9, [x9]
Lloh7:
	adrp	x10, _POLLRDNORM@GOTPAGE
Lloh8:
	ldr	x10, [x10, _POLLRDNORM@GOTPAGEOFF]
Lloh9:
	ldr	w10, [x10]
	orr	w20, w10, w9
LBB0_11:
	ldr	w9, [x22]
	tst	w9, w8
	b.eq	LBB0_15
; %bb.12:
	ldr	x8, [x19, #32]
	cbz	x8, LBB0_17
; %bb.13:
	ldr	w8, [x19, #8]
	ldr	w9, [x19, #16]
	cmp	w8, w9
	b.lt	LBB0_15
LBB0_14:
Lloh10:
	adrp	x8, _POLLOUT@GOTPAGE
Lloh11:
	ldr	x8, [x8, _POLLOUT@GOTPAGEOFF]
Lloh12:
	ldr	w8, [x8]
Lloh13:
	adrp	x9, _POLLWRNORM@GOTPAGE
Lloh14:
	ldr	x9, [x9, _POLLWRNORM@GOTPAGEOFF]
Lloh15:
	ldr	w9, [x9]
	orr	w8, w8, w20
	orr	w20, w8, w9
LBB0_15:
	mov	x0, x19
	bl	_spin_unlock_irqrestore
LBB0_16:
	mov	x0, x20
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
LBB0_17:
	ldr	w8, [x19, #24]
	ldr	w9, [x19, #8]
	ldr	w10, [x19, #16]
	add	w9, w9, w10
	cmp	w9, w8
	b.le	LBB0_14
	b	LBB0_15
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.cfi_endproc
                                        ; -- End function
	.comm	_FMODE_WRITE,4,2                ; @FMODE_WRITE
	.comm	_FMODE_READ,4,2                 ; @FMODE_READ
	.comm	_POLLIN,4,2                     ; @POLLIN
	.comm	_POLLRDNORM,4,2                 ; @POLLRDNORM
	.comm	_POLLOUT,4,2                    ; @POLLOUT
	.comm	_POLLWRNORM,4,2                 ; @POLLWRNORM
	.no_dead_strip	_au1550_poll
.subsections_via_symbols
