	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function radeon_bo_move
_radeon_bo_move:                        ## @radeon_bo_move
	.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
	subq	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%r8, %rbx
	movl	%ecx, %r12d
	movl	%edx, -44(%rbp)                 ## 4-byte Spill
	movl	%esi, %r14d
	movq	%rdi, %r15
	movl	8(%rdi), %edi
	callq	_radeon_get_rdev
	movq	%rax, %r13
	movq	16(%r15), %rax
	movq	_TTM_PL_SYSTEM@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	cmpq	%rcx, %rax
	jne	LBB0_3
## %bb.1:
	cmpq	$0, (%r15)
	je	LBB0_2
LBB0_3:
	movq	_TTM_PL_TT@GOTPCREL(%rip), %rdx
	movq	(%rdx), %rdx
	cmpq	%rdx, %rax
	jne	LBB0_5
## %bb.4:
	cmpq	%rcx, (%rbx)
	je	LBB0_2
LBB0_5:
	cmpq	%rcx, %rax
	jne	LBB0_7
## %bb.6:
	cmpq	%rdx, (%rbx)
	jne	LBB0_7
LBB0_2:
	movq	%r15, %rdi
	movq	%rbx, %rsi
	callq	_radeon_move_null
LBB0_18:
	xorl	%eax, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_7:
	movq	%rbx, -56(%rbp)                 ## 8-byte Spill
	movl	%r14d, %ebx
	movl	%r12d, %r14d
	movq	8(%r13), %r12
	movq	%r13, %rdi
	callq	_radeon_copy_ring_index
	cmpl	$0, (%r12,%rax,4)
	movl	%r14d, %r12d
	movl	%ebx, %r14d
	movq	-56(%rbp), %rbx                 ## 8-byte Reload
	je	LBB0_19
## %bb.8:
	movq	(%r13), %rax
	cmpq	$0, (%rax)
	je	LBB0_19
## %bb.9:
	leaq	16(%r15), %r8
	movq	(%r8), %rcx
	movq	_TTM_PL_VRAM@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	_TTM_PL_SYSTEM@GOTPCREL(%rip), %rdx
	cmpq	%rax, %rcx
	jne	LBB0_10
## %bb.14:
	movq	(%rdx), %rdx
	cmpq	%rdx, (%rbx)
	jne	LBB0_11
## %bb.15:
	movq	%r15, %rdi
	movl	%r14d, %esi
	movl	-44(%rbp), %edx                 ## 4-byte Reload
	movl	%r12d, %ecx
	movq	%rbx, %r8
	callq	_radeon_move_vram_ram
	jmp	LBB0_17
LBB0_10:
	movq	(%rdx), %rdx
LBB0_11:
	cmpq	%rdx, %rcx
	jne	LBB0_16
## %bb.12:
	cmpq	%rax, (%rbx)
	jne	LBB0_16
## %bb.13:
	movq	%r15, %rdi
	movl	%r14d, %esi
	movl	-44(%rbp), %edx                 ## 4-byte Reload
	movl	%r12d, %ecx
	movq	%rbx, %r8
	callq	_radeon_move_ram_vram
	jmp	LBB0_17
LBB0_16:
	movq	%r15, %rdi
	movl	%r14d, %esi
	movl	%r12d, %edx
	movq	%rbx, %rcx
	callq	_radeon_move_blit
LBB0_17:
	testl	%eax, %eax
	je	LBB0_18
LBB0_19:
	movq	%r15, %rdi
	movl	%r14d, %esi
	movl	%r12d, %edx
	movq	%rbx, %rcx
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_ttm_bo_move_memcpy             ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_TTM_PL_SYSTEM,8,3              ## @TTM_PL_SYSTEM
	.comm	_TTM_PL_TT,8,3                  ## @TTM_PL_TT
	.comm	_TTM_PL_VRAM,8,3                ## @TTM_PL_VRAM
	.no_dead_strip	_radeon_bo_move
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function radeon_bo_move
_radeon_bo_move:                        ; @radeon_bo_move
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x19, x4
	mov	x20, x3
	mov	x23, x2
	mov	x22, x1
	mov	x21, x0
	ldr	w0, [x0, #8]
	bl	_radeon_get_rdev
	mov	x25, x0
	mov	x24, x21
	ldr	x8, [x24, #16]!
Lloh0:
	adrp	x26, _TTM_PL_SYSTEM@GOTPAGE
Lloh1:
	ldr	x26, [x26, _TTM_PL_SYSTEM@GOTPAGEOFF]
	ldr	x9, [x26]
	cmp	x8, x9
	b.ne	LBB0_2
; %bb.1:
	ldr	x10, [x21]
	cbz	x10, LBB0_6
LBB0_2:
Lloh2:
	adrp	x10, _TTM_PL_TT@GOTPAGE
Lloh3:
	ldr	x10, [x10, _TTM_PL_TT@GOTPAGEOFF]
Lloh4:
	ldr	x10, [x10]
	cmp	x8, x10
	b.ne	LBB0_4
; %bb.3:
	ldr	x11, [x19]
	cmp	x11, x9
	b.eq	LBB0_6
LBB0_4:
	cmp	x8, x9
	b.ne	LBB0_8
; %bb.5:
	ldr	x8, [x19]
	cmp	x8, x10
	b.ne	LBB0_8
LBB0_6:
	mov	x0, x21
	mov	x1, x19
	bl	_radeon_move_null
LBB0_7:
	mov	w0, #0
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	ret
LBB0_8:
	ldr	x27, [x25, #8]
	mov	x0, x25
	bl	_radeon_copy_ring_index
	ldr	w8, [x27, x0, lsl #2]
	cbz	w8, LBB0_19
; %bb.9:
	ldr	x8, [x25]
	ldr	x8, [x8]
	cbz	x8, LBB0_19
; %bb.10:
	ldr	x9, [x24]
Lloh5:
	adrp	x8, _TTM_PL_VRAM@GOTPAGE
Lloh6:
	ldr	x8, [x8, _TTM_PL_VRAM@GOTPAGEOFF]
Lloh7:
	ldr	x8, [x8]
	cmp	x9, x8
	b.ne	LBB0_13
; %bb.11:
	ldr	x11, [x19]
	ldr	x10, [x26]
	cmp	x11, x10
	b.ne	LBB0_14
; %bb.12:
	mov	x0, x21
	mov	x1, x22
	mov	x2, x23
	mov	x3, x20
	mov	x4, x19
	bl	_radeon_move_vram_ram
	b	LBB0_18
LBB0_13:
	ldr	x10, [x26]
LBB0_14:
	cmp	x9, x10
	b.ne	LBB0_17
; %bb.15:
	ldr	x9, [x19]
	cmp	x9, x8
	b.ne	LBB0_17
; %bb.16:
	mov	x0, x21
	mov	x1, x22
	mov	x2, x23
	mov	x3, x20
	mov	x4, x19
	bl	_radeon_move_ram_vram
	b	LBB0_18
LBB0_17:
	mov	x0, x21
	mov	x1, x22
	mov	x2, x20
	mov	x3, x19
	mov	x4, x24
	bl	_radeon_move_blit
LBB0_18:
	cbz	w0, LBB0_7
LBB0_19:
	mov	x0, x21
	mov	x1, x22
	mov	x2, x20
	mov	x3, x19
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	b	_ttm_bo_move_memcpy
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.cfi_endproc
                                        ; -- End function
	.comm	_TTM_PL_SYSTEM,8,3              ; @TTM_PL_SYSTEM
	.comm	_TTM_PL_TT,8,3                  ; @TTM_PL_TT
	.comm	_TTM_PL_VRAM,8,3                ; @TTM_PL_VRAM
	.no_dead_strip	_radeon_bo_move
.subsections_via_symbols
