	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function SNDDMA_AudioCallback
_SNDDMA_AudioCallback:                  ## @SNDDMA_AudioCallback
	.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	_dma@GOTPCREL(%rip), %r13
	movl	(%r13), %ecx
	leal	7(%rcx), %eax
	testl	%ecx, %ecx
	cmovnsl	%ecx, %eax
	movq	_dmapos@GOTPCREL(%rip), %r12
	sarl	$3, %eax
	imull	(%r12), %eax
	movq	%rsi, %r14
	movq	_dmasize@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	cmpl	%ecx, %eax
	jl	LBB0_2
## %bb.1:
	movl	$0, (%r12)
	xorl	%eax, %eax
LBB0_2:
	movq	_snd_inited@GOTPCREL(%rip), %rsi
	cmpl	$0, (%rsi)
	je	LBB0_7
## %bb.3:
	subl	%eax, %ecx
	movl	%ecx, %esi
	subl	%edx, %esi
	movl	%edx, %ebx
	cmovll	%ecx, %ebx
	negl	%esi
	xorl	%r15d, %r15d
	cmpl	%ecx, %edx
	cmovgl	%esi, %r15d
	movslq	%eax, %rsi
	addq	16(%r13), %rsi
	movq	%r14, %rdi
	movl	%ebx, %edx
	callq	_memcpy
	testl	%r15d, %r15d
	jle	LBB0_4
## %bb.5:
	movslq	%ebx, %rax
	leaq	(%r14,%rax,8), %rdi
	movq	16(%r13), %rsi
	movl	%r15d, %edx
	callq	_memcpy
	movl	(%r13), %eax
	leal	7(%rax), %ecx
	testl	%eax, %eax
	cmovnsl	%eax, %ecx
	sarl	$3, %ecx
	movl	%r15d, %eax
	cltd
	idivl	%ecx
	jmp	LBB0_6
LBB0_7:
	movq	%r14, %rdi
	xorl	%esi, %esi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_memset                         ## TAILCALL
LBB0_4:
	movl	(%r13), %eax
	leal	7(%rax), %ecx
	testl	%eax, %eax
	cmovnsl	%eax, %ecx
	sarl	$3, %ecx
	movl	%ebx, %eax
	cltd
	idivl	%ecx
	addl	(%r12), %eax
LBB0_6:
	xorl	%ecx, %ecx
	movq	_dmasize@GOTPCREL(%rip), %rdx
	cmpl	(%rdx), %eax
	cmovll	%eax, %ecx
	movl	%ecx, (%r12)
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_dmapos,4,2                     ## @dmapos
	.comm	_dma,24,3                       ## @dma
	.comm	_dmasize,4,2                    ## @dmasize
	.comm	_snd_inited,4,2                 ## @snd_inited
	.comm	_sdlMasterGain,4,2              ## @sdlMasterGain
	.no_dead_strip	_SNDDMA_AudioCallback
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function SNDDMA_AudioCallback
_SNDDMA_AudioCallback:                  ; @SNDDMA_AudioCallback
	.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	x19, x1
Lloh0:
	adrp	x22, _dmapos@GOTPAGE
Lloh1:
	ldr	x22, [x22, _dmapos@GOTPAGEOFF]
	ldr	w8, [x22]
Lloh2:
	adrp	x24, _dma@GOTPAGE
Lloh3:
	ldr	x24, [x24, _dma@GOTPAGEOFF]
	ldr	w9, [x24]
	add	w10, w9, #7
	cmp	w9, #0
	csel	w9, w10, w9, lt
	asr	w9, w9, #3
	mul	w8, w9, w8
Lloh4:
	adrp	x23, _dmasize@GOTPAGE
Lloh5:
	ldr	x23, [x23, _dmasize@GOTPAGEOFF]
	ldr	w9, [x23]
	cmp	w8, w9
	b.lt	LBB0_2
; %bb.1:
	mov	w8, #0
	str	wzr, [x22]
LBB0_2:
Lloh6:
	adrp	x10, _snd_inited@GOTPAGE
Lloh7:
	ldr	x10, [x10, _snd_inited@GOTPAGEOFF]
Lloh8:
	ldr	w10, [x10]
	cbz	w10, LBB0_5
; %bb.3:
	sub	w9, w9, w8
	cmp	w9, w2
	csel	w21, w9, w2, lt
	subs	w9, w2, w9
	csel	w20, w9, wzr, gt
	ldr	x9, [x24, #16]
	add	x1, x9, w8, sxtw
	mov	x0, x19
	mov	x2, x21
	bl	_memcpy
	cmp	w20, #0
	b.le	LBB0_6
; %bb.4:
	add	x0, x19, w21, sxtw #3
	ldr	x1, [x24, #16]
	mov	x2, x20
	bl	_memcpy
	ldr	w8, [x24]
	add	w9, w8, #7
	cmp	w8, #0
	csel	w8, w9, w8, lt
	asr	w8, w8, #3
	sdiv	w8, w20, w8
	b	LBB0_7
LBB0_5:
	mov	x0, x19
	mov	w1, #0
	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
	b	_memset
LBB0_6:
	ldr	w8, [x24]
	add	w9, w8, #7
	cmp	w8, #0
	csel	w8, w9, w8, lt
	asr	w8, w8, #3
	sdiv	w8, w21, w8
	ldr	w9, [x22]
	add	w8, w9, w8
LBB0_7:
	ldr	w9, [x23]
	cmp	w8, w9
	csel	w8, w8, wzr, lt
	str	w8, [x22]
	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
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_dmapos,4,2                     ; @dmapos
	.comm	_dma,24,3                       ; @dma
	.comm	_dmasize,4,2                    ; @dmasize
	.comm	_snd_inited,4,2                 ; @snd_inited
	.comm	_sdlMasterGain,4,2              ; @sdlMasterGain
	.no_dead_strip	_SNDDMA_AudioCallback
.subsections_via_symbols
