	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_radeon_vm_bo_rmv               ## -- Begin function radeon_vm_bo_rmv
	.p2align	4, 0x90
_radeon_vm_bo_rmv:                      ## @radeon_vm_bo_rmv
	.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, %rbx
	movq	40(%rsi), %r14
	leaq	32(%rsi), %rdi
	callq	_list_del
	movq	%r14, %rdi
	callq	_mutex_lock
	leaq	16(%rbx), %r12
	cmpq	$0, 24(%rbx)
	jne	LBB0_2
## %bb.1:
	cmpq	$0, (%r12)
	je	LBB0_3
LBB0_2:
	leaq	12(%r14), %rsi
	movq	%r12, %rdi
	callq	_interval_tree_remove
LBB0_3:
	leaq	4(%r14), %r15
	movq	%r15, %rdi
	callq	_spin_lock
	leaq	4(%rbx), %r13
	movq	%r13, %rdi
	callq	_list_del
	cmpq	$0, 24(%rbx)
	jne	LBB0_5
## %bb.4:
	cmpq	$0, (%r12)
	je	LBB0_6
LBB0_5:
	movl	8(%rbx), %edi
	callq	_radeon_bo_ref
	movl	%eax, 8(%rbx)
	leaq	8(%r14), %rsi
	movq	%r13, %rdi
	callq	_list_add
LBB0_7:
	movq	%r15, %rdi
	callq	_spin_unlock
	movq	%r14, %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_mutex_unlock                   ## TAILCALL
LBB0_6:
	movq	%rbx, %rdi
	callq	_radeon_fence_unref
	movq	%rbx, %rdi
	callq	_kfree
	jmp	LBB0_7
	.cfi_endproc
                                        ## -- End function
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_radeon_vm_bo_rmv               ; -- Begin function radeon_vm_bo_rmv
	.p2align	2
_radeon_vm_bo_rmv:                      ; @radeon_vm_bo_rmv
	.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, x1
	ldr	x19, [x1, #40]
	add	x0, x1, #32
	bl	_list_del
	mov	x0, x19
	bl	_mutex_lock
	add	x22, x20, #16
	ldr	x8, [x20, #24]
	cbnz	x8, LBB0_2
; %bb.1:
	ldr	x8, [x22]
	cbz	x8, LBB0_3
LBB0_2:
	add	x1, x19, #12
	mov	x0, x22
	bl	_interval_tree_remove
LBB0_3:
	add	x21, x19, #4
	mov	x0, x21
	bl	_spin_lock
	add	x23, x20, #4
	mov	x0, x23
	bl	_list_del
	ldr	x8, [x20, #24]
	cbnz	x8, LBB0_5
; %bb.4:
	ldr	x8, [x22]
	cbz	x8, LBB0_7
LBB0_5:
	ldr	w0, [x20, #8]
	bl	_radeon_bo_ref
	str	w0, [x20, #8]
	add	x1, x19, #8
	mov	x0, x23
	bl	_list_add
LBB0_6:
	mov	x0, x21
	bl	_spin_unlock
	mov	x0, x19
	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	_mutex_unlock
LBB0_7:
	mov	x0, x20
	bl	_radeon_fence_unref
	mov	x0, x20
	bl	_kfree
	b	LBB0_6
	.cfi_endproc
                                        ; -- End function
.subsections_via_symbols
