	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function sdma_v4_0_rb_cntl
_sdma_v4_0_rb_cntl:                     ## @sdma_v4_0_rb_cntl
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -24
	movl	%esi, %ebx
	movl	(%rdi), %eax
	leal	3(%rax), %edi
	testl	%eax, %eax
	cmovnsl	%eax, %edi
	sarl	$2, %edi
	callq	_order_base_2
	movq	_SDMA0_GFX_RB_CNTL@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	movq	_RB_SIZE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	movl	%ebx, %edi
	movl	%eax, %ecx
	addq	$8, %rsp
	popq	%rbx
	popq	%rbp
	jmp	_REG_SET_FIELD                  ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_SDMA0_GFX_RB_CNTL,4,2          ## @SDMA0_GFX_RB_CNTL
	.comm	_RB_SIZE,4,2                    ## @RB_SIZE
	.comm	_RB_SWAP_ENABLE,4,2             ## @RB_SWAP_ENABLE
	.comm	_RPTR_WRITEBACK_SWAP_ENABLE,4,2 ## @RPTR_WRITEBACK_SWAP_ENABLE
	.no_dead_strip	_sdma_v4_0_rb_cntl
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function sdma_v4_0_rb_cntl
_sdma_v4_0_rb_cntl:                     ; @sdma_v4_0_rb_cntl
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x1
	ldr	w8, [x0]
	add	w9, w8, #3
	cmp	w8, #0
	csel	w8, w9, w8, lt
	asr	w0, w8, #2
	bl	_order_base_2
	mov	x3, x0
Lloh0:
	adrp	x8, _SDMA0_GFX_RB_CNTL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _SDMA0_GFX_RB_CNTL@GOTPAGEOFF]
Lloh2:
	adrp	x9, _RB_SIZE@GOTPAGE
Lloh3:
	ldr	x9, [x9, _RB_SIZE@GOTPAGEOFF]
Lloh4:
	ldr	w1, [x8]
Lloh5:
	ldr	w2, [x9]
	mov	x0, x19
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	b	_REG_SET_FIELD
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh4
	.cfi_endproc
                                        ; -- End function
	.comm	_SDMA0_GFX_RB_CNTL,4,2          ; @SDMA0_GFX_RB_CNTL
	.comm	_RB_SIZE,4,2                    ; @RB_SIZE
	.comm	_RB_SWAP_ENABLE,4,2             ; @RB_SWAP_ENABLE
	.comm	_RPTR_WRITEBACK_SWAP_ENABLE,4,2 ; @RPTR_WRITEBACK_SWAP_ENABLE
	.no_dead_strip	_sdma_v4_0_rb_cntl
.subsections_via_symbols
