	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_snd_emu10k1_memblk_map         ## -- Begin function snd_emu10k1_memblk_map
	.p2align	4, 0x90
_snd_emu10k1_memblk_map:                ## @snd_emu10k1_memblk_map
	.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, %r13
	movq	%rdi, %r14
	callq	_spin_lock_irqsave
	cmpq	$0, (%r13)
	js	LBB0_2
## %bb.1:
	addq	$24, %r13
	movq	%r13, %rdi
	callq	_list_del
	leaq	8(%r14), %rsi
	movq	%r13, %rdi
	callq	_list_add_tail
	xorl	%r15d, %r15d
	jmp	LBB0_8
LBB0_2:
	movq	%r14, %rdi
	movq	%r13, %rsi
	callq	_map_memblk
	movl	%eax, %r15d
	testl	%eax, %eax
	js	LBB0_3
LBB0_8:
	movq	%r14, %rdi
	callq	_spin_unlock_irqrestore
	movl	%r15d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_3:
	leaq	8(%r14), %r12
	movq	8(%r14), %rbx
	.p2align	4, 0x90
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	cmpq	%r12, %rbx
	je	LBB0_8
## %bb.5:                               ##   in Loop: Header=BB0_4 Depth=1
	movq	%rbx, %rdi
	movq	(%rbx), %rbx
	movq	_mapped_order_link@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_get_emu10k1_memblk
	cmpq	$0, 16(%rax)
	jne	LBB0_4
## %bb.6:                               ##   in Loop: Header=BB0_4 Depth=1
	movq	%r14, %rdi
	movq	%rax, %rsi
	callq	_unmap_memblk
	cmpl	8(%r13), %eax
	jl	LBB0_4
## %bb.7:
	movq	%r14, %rdi
	movq	%r13, %rsi
	callq	_map_memblk
	movl	%eax, %r15d
	jmp	LBB0_8
	.cfi_endproc
                                        ## -- End function
	.comm	_mapped_order_link,4,2          ## @mapped_order_link
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_snd_emu10k1_memblk_map         ; -- Begin function snd_emu10k1_memblk_map
	.p2align	2
_snd_emu10k1_memblk_map:                ; @snd_emu10k1_memblk_map
	.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	x19, x0
	bl	_spin_lock_irqsave
	ldr	x8, [x21]
	tbnz	x8, #63, LBB0_2
; %bb.1:
	add	x20, x21, #24
	mov	x0, x20
	bl	_list_del
	add	x1, x19, #8
	mov	x0, x20
	bl	_list_add_tail
	mov	w20, #0
	b	LBB0_3
LBB0_2:
	mov	x0, x19
	mov	x1, x21
	bl	_map_memblk
	mov	x20, x0
	tbnz	w0, #31, LBB0_4
LBB0_3:
	mov	x0, x19
	bl	_spin_unlock_irqrestore
	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_4:
	mov	x22, x19
	ldr	x0, [x22, #8]!
	cmp	x0, x22
	b.eq	LBB0_3
; %bb.5:
Lloh0:
	adrp	x23, _mapped_order_link@GOTPAGE
Lloh1:
	ldr	x23, [x23, _mapped_order_link@GOTPAGEOFF]
	b	LBB0_7
LBB0_6:                                 ;   in Loop: Header=BB0_7 Depth=1
	mov	x0, x24
	cmp	x24, x22
	b.eq	LBB0_3
LBB0_7:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x24, [x0]
	ldr	w1, [x23]
	bl	_get_emu10k1_memblk
	ldr	x8, [x0, #16]
	cbnz	x8, LBB0_6
; %bb.8:                                ;   in Loop: Header=BB0_7 Depth=1
	mov	x1, x0
	mov	x0, x19
	bl	_unmap_memblk
	ldr	w8, [x21, #8]
	cmp	w0, w8
	b.lt	LBB0_6
; %bb.9:
	mov	x0, x19
	mov	x1, x21
	bl	_map_memblk
	mov	x20, x0
	b	LBB0_3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.comm	_mapped_order_link,4,2          ; @mapped_order_link
.subsections_via_symbols
