	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ddb_redirect
_ddb_redirect:                          ## @ddb_redirect
	.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	_ddbs@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movl	%edi, %ecx
	shrl	$4, %ecx
	andl	$63, %ecx
	movq	(%rax,%rcx,8), %r12
	testq	%r12, %r12
	je	LBB0_2
## %bb.1:
	movl	%esi, %r15d
	movl	%esi, %ecx
	shrl	$4, %ecx
	andl	$63, %ecx
	movq	(%rax,%rcx,8), %rax
	testq	%rax, %rax
	je	LBB0_2
## %bb.4:
	cmpl	$0, 16(%r12)
	je	LBB0_2
## %bb.5:
	cmpl	$0, 16(%rax)
	je	LBB0_2
## %bb.6:
	movq	8(%rax), %r13
	andl	$15, %r15d
	shlq	$4, %r15
	cmpq	$0, (%r13,%r15)
	je	LBB0_2
## %bb.7:
	movl	%edi, %r14d
	leaq	(%r15,%r13), %rbx
	movq	%rbx, %rdi
	callq	_ddb_unredirect
	testq	%rax, %rax
	je	LBB0_9
## %bb.8:
	movq	_EBUSY@GOTPCREL(%rip), %rax
	jmp	LBB0_3
LBB0_9:
	movq	%rbx, -48(%rbp)                 ## 8-byte Spill
	xorl	%ebx, %ebx
	cmpl	$8, %r14d
	je	LBB0_19
## %bb.10:
	movq	(%r12), %r12
	testq	%r12, %r12
	je	LBB0_2
## %bb.11:
	movq	_redirect_lock@GOTPCREL(%rip), %rdi
	callq	_mutex_lock
	movq	-48(%rbp), %rax                 ## 8-byte Reload
	movq	(%rax), %rax
	movq	(%rax), %rdx
	cmpq	$0, (%rdx)
	jne	LBB0_13
## %bb.12:
	andl	$7, %r14d
	shlq	$5, %r14
	leaq	(%r12,%r14), %rcx
	movq	(%rcx), %rsi
	cmpq	$0, (%rsi)
	je	LBB0_14
LBB0_13:
	movq	_redirect_lock@GOTPCREL(%rip), %rdi
	callq	_mutex_unlock
	movq	_EBUSY@GOTPCREL(%rip), %rax
	jmp	LBB0_3
LBB0_2:
	movq	_EINVAL@GOTPCREL(%rip), %rax
LBB0_3:
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
LBB0_19:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_14:
	movq	8(%r13,%r15), %rdi
	movq	(%rdi), %rdi
	testq	%rdi, %rdi
	je	LBB0_18
## %bb.15:
	movq	24(%r12,%r14), %r8
	testq	%r8, %r8
	je	LBB0_17
## %bb.16:
	leaq	(%r12,%r14), %r9
	addq	$24, %r9
	movq	%r8, 24(%rdi)
	movq	$0, (%r9)
	jmp	LBB0_18
LBB0_17:
	movq	%rcx, 24(%rdi)
LBB0_18:
	movq	%rax, 16(%r12,%r14)
	movq	%rcx, 8(%rax)
	movq	8(%r12,%r14), %rax
	movl	(%rax), %edi
	callq	_ddb_redirect_dma
	movq	_redirect_lock@GOTPCREL(%rip), %rdi
	callq	_mutex_unlock
	jmp	LBB0_19
	.cfi_endproc
                                        ## -- End function
	.comm	_ddbs,8,3                       ## @ddbs
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_EBUSY,4,2                      ## @EBUSY
	.comm	_redirect_lock,4,2              ## @redirect_lock
	.no_dead_strip	_ddb_redirect
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ddb_redirect
_ddb_redirect:                          ; @ddb_redirect
	.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
Lloh0:
	adrp	x8, _ddbs@GOTPAGE
Lloh1:
	ldr	x8, [x8, _ddbs@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	ubfx	w9, w0, #4, #6
	ldr	x21, [x8, w9, uxtw #3]
	ubfx	w9, w1, #4, #6
	ldr	x8, [x8, w9, uxtw #3]
	cmp	x21, #0
	ccmp	x8, #0, #4, ne
	b.eq	LBB0_12
; %bb.1:
	ldr	w9, [x21, #16]
	cbz	w9, LBB0_12
; %bb.2:
	ldr	w9, [x8, #16]
	cbz	w9, LBB0_12
; %bb.3:
	ldr	x22, [x8, #8]
	and	w23, w1, #0xf
	add	x20, x22, w23, uxtw #4
	ldr	x8, [x20]
	cbz	x8, LBB0_12
; %bb.4:
	mov	x19, x0
	mov	x0, x20
	bl	_ddb_unredirect
	cbz	x0, LBB0_6
LBB0_5:
Lloh3:
	adrp	x8, _EBUSY@GOTPAGE
Lloh4:
	ldr	x8, [x8, _EBUSY@GOTPAGEOFF]
	b	LBB0_13
LBB0_6:
	cmp	w19, #8
	b.ne	LBB0_8
LBB0_7:
	mov	w0, #0
	b	LBB0_14
LBB0_8:
	ldr	x21, [x21]
	cbz	x21, LBB0_12
; %bb.9:
Lloh5:
	adrp	x0, _redirect_lock@GOTPAGE
Lloh6:
	ldr	x0, [x0, _redirect_lock@GOTPAGEOFF]
	bl	_mutex_lock
	ldr	x8, [x20]
	ldr	x2, [x8]
	ldr	x9, [x2]
	cbnz	x9, LBB0_11
; %bb.10:
	and	w9, w19, #0x7
	add	x10, x21, x9, lsl #5
	ldr	x1, [x10]
	ldr	x11, [x1]
	cbz	x11, LBB0_15
LBB0_11:
Lloh7:
	adrp	x0, _redirect_lock@GOTPAGE
Lloh8:
	ldr	x0, [x0, _redirect_lock@GOTPAGEOFF]
	bl	_mutex_unlock
	b	LBB0_5
LBB0_12:
Lloh9:
	adrp	x8, _EINVAL@GOTPAGE
Lloh10:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
LBB0_13:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_14:
	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_15:
	add	x11, x22, x23, lsl #4
	ldr	x11, [x11, #8]
	ldr	x11, [x11]
	cbz	x11, LBB0_19
; %bb.16:
	add	x12, x21, x9, lsl #5
	ldr	x13, [x12, #24]!
	cbz	x13, LBB0_18
; %bb.17:
	str	x13, [x11, #24]
	str	xzr, [x12]
	b	LBB0_19
LBB0_18:
	str	x10, [x11, #24]
LBB0_19:
	add	x9, x21, x9, lsl #5
	str	x8, [x9, #16]
	str	x10, [x8, #8]
	ldr	x8, [x9, #8]
	ldr	w0, [x8]
	bl	_ddb_redirect_dma
Lloh11:
	adrp	x0, _redirect_lock@GOTPAGE
Lloh12:
	ldr	x0, [x0, _redirect_lock@GOTPAGEOFF]
	bl	_mutex_unlock
	b	LBB0_7
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh11, Lloh12
	.cfi_endproc
                                        ; -- End function
	.comm	_ddbs,8,3                       ; @ddbs
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_EBUSY,4,2                      ; @EBUSY
	.comm	_redirect_lock,4,2              ; @redirect_lock
	.no_dead_strip	_ddb_redirect
.subsections_via_symbols
