	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_pdacf_tasklet                  ## -- Begin function pdacf_tasklet
	.p2align	4, 0x90
_pdacf_tasklet:                         ## @pdacf_tasklet
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	_PDAUDIOCF_STAT_IS_STALE@GOTPCREL(%rip), %rax
	movq	_PDAUDIOCF_STAT_IS_CONFIGURED@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	(%rax), %eax
	orl	%ecx, %eax
	andl	(%rdi), %eax
	cmpl	%ecx, %eax
	jne	LBB0_11
## %bb.1:
	movq	%rdi, %r14
	movq	40(%rdi), %rdi
	testq	%rdi, %rdi
	je	LBB0_11
## %bb.2:
	cmpq	$0, (%rdi)
	je	LBB0_11
## %bb.3:
	callq	_snd_pcm_running
	testl	%eax, %eax
	je	LBB0_11
## %bb.4:
	movq	_PDAUDIOCF_REG_RDP@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	addq	8(%r14), %rdi
	callq	_inw
	movl	%eax, %ebx
	movq	_PDAUDIOCF_REG_WDP@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	addq	8(%r14), %rdi
	callq	_inw
                                        ## kill: def $eax killed $eax def $rax
	subl	%ebx, %eax
	leal	65536(%rax), %ecx
	testl	%eax, %eax
	cmovsl	%ecx, %eax
	testl	%eax, %eax
	movl	$65536, %ecx                    ## imm = 0x10000
	cmovel	%ecx, %eax
                                        ## kill: def $eax killed $eax killed $rax
	cltd
	idivl	16(%r14)
                                        ## kill: def $eax killed $eax def $rax
	leal	-32(%rax), %r12d
	cmpl	$65, %eax
	cmovll	%eax, %r12d
	movl	20(%r14), %ecx
	movl	24(%r14), %ebx
	movl	28(%r14), %eax
	leal	(%rax,%r12), %edx
	movl	%edx, 28(%r14)
	testl	%r12d, %r12d
	jle	LBB0_7
## %bb.5:
	addl	%ecx, %eax
                                        ## kill: def $eax killed $eax killed $rax
	cltd
	idivl	%ebx
	movl	%edx, %r15d
	.p2align	4, 0x90
LBB0_6:                                 ## =>This Inner Loop Header: Depth=1
	subl	%r15d, %ebx
	cmpl	%r12d, %ebx
	cmovgel	%r12d, %ebx
	movq	%r14, %rdi
	movl	%ebx, %esi
	movl	%r15d, %edx
	callq	_pdacf_transfer
	addl	%ebx, %r15d
	movl	24(%r14), %ecx
	movl	%r15d, %eax
	cltd
	idivl	%ecx
	movl	%edx, %r15d
	subl	%ebx, %r12d
	movl	%ecx, %ebx
	jg	LBB0_6
LBB0_7:
	leaq	36(%r14), %rbx
	.p2align	4, 0x90
LBB0_9:                                 ## =>This Inner Loop Header: Depth=1
	movq	%rbx, %rdi
	callq	_spin_lock
	movl	28(%r14), %ecx
	movl	32(%r14), %esi
	cmpl	%esi, %ecx
	jl	LBB0_10
## %bb.8:                               ##   in Loop: Header=BB0_9 Depth=1
	movl	20(%r14), %eax
	addl	%esi, %eax
	cltd
	idivl	24(%r14)
	movl	%edx, 20(%r14)
	subl	%esi, %ecx
	movl	%ecx, 28(%r14)
	movq	%rbx, %rdi
	callq	_spin_unlock
	movq	40(%r14), %rdi
	callq	_snd_pcm_period_elapsed
	jmp	LBB0_9
LBB0_11:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_10:
	movq	%rbx, %rdi
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_spin_unlock                    ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_PDAUDIOCF_STAT_IS_STALE,4,2    ## @PDAUDIOCF_STAT_IS_STALE
	.comm	_PDAUDIOCF_STAT_IS_CONFIGURED,4,2 ## @PDAUDIOCF_STAT_IS_CONFIGURED
	.comm	_PDAUDIOCF_REG_RDP,8,3          ## @PDAUDIOCF_REG_RDP
	.comm	_PDAUDIOCF_REG_WDP,8,3          ## @PDAUDIOCF_REG_WDP
	.comm	_PDAUDIOCF_REG_MD,8,3           ## @PDAUDIOCF_REG_MD
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_pdacf_tasklet                  ; -- Begin function pdacf_tasklet
	.p2align	2
_pdacf_tasklet:                         ; @pdacf_tasklet
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	ldr	w8, [x0]
Lloh0:
	adrp	x9, _PDAUDIOCF_STAT_IS_STALE@GOTPAGE
Lloh1:
	ldr	x9, [x9, _PDAUDIOCF_STAT_IS_STALE@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x9]
Lloh3:
	adrp	x10, _PDAUDIOCF_STAT_IS_CONFIGURED@GOTPAGE
Lloh4:
	ldr	x10, [x10, _PDAUDIOCF_STAT_IS_CONFIGURED@GOTPAGEOFF]
Lloh5:
	ldr	w10, [x10]
	orr	w9, w10, w9
	and	w8, w9, w8
	cmp	w8, w10
	b.ne	LBB0_10
; %bb.1:
	mov	x19, x0
	ldr	x0, [x0, #40]
	cbz	x0, LBB0_10
; %bb.2:
	ldr	x8, [x0]
	cbz	x8, LBB0_10
; %bb.3:
	bl	_snd_pcm_running
	cbz	w0, LBB0_10
; %bb.4:
	ldr	x8, [x19, #8]
Lloh6:
	adrp	x9, _PDAUDIOCF_REG_RDP@GOTPAGE
Lloh7:
	ldr	x9, [x9, _PDAUDIOCF_REG_RDP@GOTPAGEOFF]
Lloh8:
	ldr	x9, [x9]
	add	x0, x9, x8
	bl	_inw
	mov	x20, x0
	ldr	x8, [x19, #8]
Lloh9:
	adrp	x9, _PDAUDIOCF_REG_WDP@GOTPAGE
Lloh10:
	ldr	x9, [x9, _PDAUDIOCF_REG_WDP@GOTPAGEOFF]
Lloh11:
	ldr	x9, [x9]
	add	x0, x9, x8
	bl	_inw
	sub	w8, w0, w20
	add	w9, w8, #16, lsl #12            ; =65536
	cmp	w8, #0
	csel	w8, w9, w8, lt
	mov	w9, #65536
	cmp	w8, #0
	csel	w8, w9, w8, eq
	ldp	w10, w9, [x19, #16]
	sdiv	w8, w8, w10
	sub	w10, w8, #32
	cmp	w8, #64
	csel	w22, w10, w8, gt
	ldp	w8, w10, [x19, #24]
	add	w11, w10, w22
	str	w11, [x19, #28]
	cmp	w22, #1
	b.lt	LBB0_7
; %bb.5:
	add	w9, w10, w9
	sdiv	w10, w9, w8
	msub	w20, w10, w8, w9
LBB0_6:                                 ; =>This Inner Loop Header: Depth=1
	sub	w8, w8, w20
	cmp	w8, w22
	csel	w21, w8, w22, lt
	mov	x0, x19
	mov	x1, x21
	mov	x2, x20
	bl	_pdacf_transfer
	add	w9, w21, w20
	ldr	w8, [x19, #24]
	sdiv	w10, w9, w8
	msub	w20, w10, w8, w9
	sub	w22, w22, w21
	cmp	w22, #0
	b.gt	LBB0_6
LBB0_7:
	add	x20, x19, #36
LBB0_8:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x20
	bl	_spin_lock
	ldp	w8, w9, [x19, #28]
	cmp	w8, w9
	b.lt	LBB0_11
; %bb.9:                                ;   in Loop: Header=BB0_8 Depth=1
	ldp	w10, w11, [x19, #20]
	add	w10, w10, w9
	sdiv	w12, w10, w11
	msub	w10, w12, w11, w10
	str	w10, [x19, #20]
	sub	w8, w8, w9
	str	w8, [x19, #28]
	mov	x0, x20
	bl	_spin_unlock
	ldr	x0, [x19, #40]
	bl	_snd_pcm_period_elapsed
	b	LBB0_8
LBB0_10:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
LBB0_11:
	mov	x0, x20
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	b	_spin_unlock
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_PDAUDIOCF_STAT_IS_STALE,4,2    ; @PDAUDIOCF_STAT_IS_STALE
	.comm	_PDAUDIOCF_STAT_IS_CONFIGURED,4,2 ; @PDAUDIOCF_STAT_IS_CONFIGURED
	.comm	_PDAUDIOCF_REG_RDP,8,3          ; @PDAUDIOCF_REG_RDP
	.comm	_PDAUDIOCF_REG_WDP,8,3          ; @PDAUDIOCF_REG_WDP
	.comm	_PDAUDIOCF_REG_MD,8,3           ; @PDAUDIOCF_REG_MD
.subsections_via_symbols
