	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function radeon_cp_dispatch_indirect
_radeon_cp_dispatch_indirect:           ## @radeon_cp_dispatch_indirect
	.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
	movl	%ecx, %ebx
	movl	%edx, %r13d
	movq	%rsi, %r14
	movq	%rdi, %r12
	movq	8(%rdi), %r15
	movl	4(%rsi), %esi
	leaq	L_.str(%rip), %rdi
	callq	_DRM_DEBUG
	subl	%r13d, %ebx
	jne	LBB0_1
## %bb.4:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_1:
	movslq	(%r14), %rax
	movl	(%r15), %r15d
	addl	%r13d, %r15d
	addl	%eax, %r15d
	addl	$3, %ebx
	movl	%ebx, %r14d
	sarl	$2, %r14d
	testb	$4, %bl
	je	LBB0_3
## %bb.2:
	movq	(%r12), %rcx
	addq	(%rcx), %rax
	movslq	%r13d, %rcx
	addq	%rax, %rcx
	movq	_RADEON_CP_PACKET2@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movslq	%r14d, %rdx
	incl	%r14d
	movl	%eax, (%rcx,%rdx,4)
LBB0_3:
	movl	$3, %edi
	callq	_BEGIN_RING
	movq	_RADEON_CP_IB_BASE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	$1, %esi
	callq	_CP_PACKET0
	movl	%eax, %edi
	callq	_OUT_RING
	movl	%r15d, %edi
	callq	_OUT_RING
	movl	%r14d, %edi
	callq	_OUT_RING
	xorl	%eax, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_ADVANCE_RING                   ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_RING_LOCALS,4,2                ## @RING_LOCALS
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"buf=%d s=0x%x e=0x%x\n"

	.comm	_RADEON_CP_PACKET2,4,2          ## @RADEON_CP_PACKET2
	.comm	_RADEON_CP_IB_BASE,4,2          ## @RADEON_CP_IB_BASE
	.no_dead_strip	_radeon_cp_dispatch_indirect
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function radeon_cp_dispatch_indirect
_radeon_cp_dispatch_indirect:           ; @radeon_cp_dispatch_indirect
	.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	x20, x3
	mov	x21, x2
	mov	x19, x1
	mov	x22, x0
	ldr	x23, [x0, #8]
	ldr	w1, [x1, #4]
Lloh0:
	adrp	x0, l_.str@PAGE
Lloh1:
	add	x0, x0, l_.str@PAGEOFF
	bl	_DRM_DEBUG
	subs	w9, w20, w21
	b.ne	LBB0_2
; %bb.1:
	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_2:
	ldr	w10, [x23]
	ldrsw	x8, [x19]
	add	w10, w10, w21
	add	w20, w10, w8
	add	w9, w9, #3
	asr	w19, w9, #2
	tbz	w9, #2, LBB0_4
; %bb.3:
	ldr	x9, [x22]
	ldr	x9, [x9]
	add	x8, x9, x8
Lloh2:
	adrp	x9, _RADEON_CP_PACKET2@GOTPAGE
Lloh3:
	ldr	x9, [x9, _RADEON_CP_PACKET2@GOTPAGEOFF]
	add	x8, x8, w21, sxtw
Lloh4:
	ldr	w9, [x9]
	str	w9, [x8, w19, sxtw #2]
	add	w19, w19, #1
LBB0_4:
	mov	w0, #3
	bl	_BEGIN_RING
Lloh5:
	adrp	x8, _RADEON_CP_IB_BASE@GOTPAGE
Lloh6:
	ldr	x8, [x8, _RADEON_CP_IB_BASE@GOTPAGEOFF]
Lloh7:
	ldr	w0, [x8]
	mov	w1, #1
	bl	_CP_PACKET0
	bl	_OUT_RING
	mov	x0, x20
	bl	_OUT_RING
	mov	x0, x19
	bl	_OUT_RING
	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	_ADVANCE_RING
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.cfi_endproc
                                        ; -- End function
	.comm	_RING_LOCALS,4,2                ; @RING_LOCALS
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"buf=%d s=0x%x e=0x%x\n"

	.comm	_RADEON_CP_PACKET2,4,2          ; @RADEON_CP_PACKET2
	.comm	_RADEON_CP_IB_BASE,4,2          ; @RADEON_CP_IB_BASE
	.no_dead_strip	_radeon_cp_dispatch_indirect
.subsections_via_symbols
