	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function amdgpu_vce_validate_bo
_amdgpu_vce_validate_bo:                ## @amdgpu_vce_validate_bo
	.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	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%r9, %r15
	movl	%ecx, %r12d
	movl	%esi, %r14d
	movq	%rdi, %r13
	movl	%r15d, %ebx
	movl	%r8d, -60(%rbp)                 ## 4-byte Spill
	imull	%r8d, %ebx
	movq	$0, -72(%rbp)
	movl	%edx, -52(%rbp)                 ## 4-byte Spill
	callq	_amdgpu_get_ib_value
	movq	%r13, %rdi
	movl	%r14d, %esi
	movl	%r12d, -56(%rbp)                ## 4-byte Spill
	movl	%r12d, %edx
	callq	_amdgpu_get_ib_value
	movl	%ebx, %edi
	callq	_PAGE_ALIGN
	movl	%eax, %r14d
	testq	%r15, %r15
	js	LBB0_2
## %bb.1:
	movabsq	$4294967296, %r12               ## imm = 0x100000000
	movq	_PAGE_SHIFT@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	sarl	%cl, %r14d
	jmp	LBB0_3
LBB0_2:
	movslq	%r14d, %rax
	movabsq	$4294967296, %r12               ## imm = 0x100000000
	subq	%rax, %r12
	movq	_PAGE_SHIFT@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	xorl	%r14d, %r14d
LBB0_3:
                                        ## kill: def $cl killed $cl killed $ecx
	shrq	%cl, %r12
	leaq	-48(%rbp), %rdx
	leaq	-80(%rbp), %rcx
	movq	%r13, %rdi
	callq	_amdgpu_cs_find_mapping
	testl	%eax, %eax
	je	LBB0_4
## %bb.11:
	movl	%eax, %r13d
	leaq	L_.str(%rip), %rdi
	movl	-52(%rbp), %edx                 ## 4-byte Reload
	movl	-56(%rbp), %ecx                 ## 4-byte Reload
	movl	-60(%rbp), %r8d                 ## 4-byte Reload
	movq	%r15, %r9
	callq	_DRM_ERROR
	jmp	LBB0_10
LBB0_4:
	movq	-48(%rbp), %rsi
	cmpl	$0, (%rsi)
	je	LBB0_9
## %bb.5:
	movq	8(%rsi), %rcx
	xorl	%ebx, %ebx
	jmp	LBB0_6
	.p2align	4, 0x90
LBB0_8:                                 ##   in Loop: Header=BB0_6 Depth=1
	movl	%eax, (%rcx,%rbx,8)
	incq	%rbx
	movl	(%rsi), %eax
	cmpq	%rax, %rbx
	jae	LBB0_9
LBB0_6:                                 ## =>This Inner Loop Header: Depth=1
	movl	4(%rcx,%rbx,8), %edi
	movl	%r14d, %esi
	callq	_max
	movq	-48(%rbp), %rsi
	movq	8(%rsi), %rcx
	movl	%eax, 4(%rcx,%rbx,8)
	movl	(%rcx,%rbx,8), %edi
	movl	%r12d, %eax
	testl	%edi, %edi
	je	LBB0_8
## %bb.7:                               ##   in Loop: Header=BB0_6 Depth=1
	movl	%r12d, %esi
	callq	_min
	movq	-48(%rbp), %rsi
	movq	8(%rsi), %rcx
	jmp	LBB0_8
LBB0_9:
	leaq	4(%rsi), %rdi
	leaq	-72(%rbp), %rdx
	callq	_ttm_bo_validate
	movl	%eax, %r13d
LBB0_10:
	movl	%r13d, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_PAGE_SHIFT,4,2                 ## @PAGE_SHIFT
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Can't find BO for addr 0x%010Lx %d %d %d %d\n"

	.no_dead_strip	_amdgpu_vce_validate_bo
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function amdgpu_vce_validate_bo
_amdgpu_vce_validate_bo:                ; @amdgpu_vce_validate_bo
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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
	mov	x20, x5
	mov	x21, x4
	mov	x22, x3
	mov	x23, x2
	mov	x19, x1
	mov	x24, x0
	mul	w25, w20, w4
	str	xzr, [sp, #24]
	bl	_amdgpu_get_ib_value
	mov	x0, x24
	mov	x1, x19
	mov	x2, x22
	bl	_amdgpu_get_ib_value
	mov	x0, x25
	bl	_PAGE_ALIGN
	tbnz	x20, #63, LBB0_2
; %bb.1:
Lloh0:
	adrp	x8, _PAGE_SHIFT@GOTPAGE
Lloh1:
	ldr	x8, [x8, _PAGE_SHIFT@GOTPAGEOFF]
Lloh2:
	ldr	w26, [x8]
	asr	w19, w0, w26
	mov	x25, #4294967296
                                        ; kill: def $w26 killed $w26 killed $x26 def $x26
	b	LBB0_3
LBB0_2:
	mov	w19, #0
	mov	x8, #4294967296
	sub	x25, x8, w0, sxtw
Lloh3:
	adrp	x8, _PAGE_SHIFT@GOTPAGE
Lloh4:
	ldr	x8, [x8, _PAGE_SHIFT@GOTPAGEOFF]
Lloh5:
	ldr	w26, [x8]
LBB0_3:
	add	x2, sp, #8
	add	x3, sp, #16
	mov	x0, x24
	bl	_amdgpu_cs_find_mapping
	cbz	w0, LBB0_5
; %bb.4:
	mov	x24, x0
Lloh6:
	adrp	x0, l_.str@PAGE
Lloh7:
	add	x0, x0, l_.str@PAGEOFF
	mov	x2, x23
	mov	x3, x22
	mov	x4, x21
	mov	x5, x20
	bl	_DRM_ERROR
	b	LBB0_12
LBB0_5:
	ldr	x1, [sp, #8]
	ldr	w8, [x1]
	cbz	w8, LBB0_11
; %bb.6:
	mov	x21, #0
	mov	x22, #0
	lsr	x20, x25, x26
	ldr	x8, [x1, #8]
	b	LBB0_9
LBB0_7:                                 ;   in Loop: Header=BB0_9 Depth=1
	mov	x1, x20
	bl	_min
	ldr	x1, [sp, #8]
	ldr	x8, [x1, #8]
LBB0_8:                                 ;   in Loop: Header=BB0_9 Depth=1
	str	w0, [x8, x21]
	add	x22, x22, #1
	ldr	w9, [x1]
	add	x21, x21, #8
	cmp	x22, x9
	b.hs	LBB0_11
LBB0_9:                                 ; =>This Inner Loop Header: Depth=1
	add	x8, x8, x21
	ldr	w0, [x8, #4]
	mov	x1, x19
	bl	_max
	ldr	x1, [sp, #8]
	ldr	x8, [x1, #8]
	add	x9, x8, x21
	str	w0, [x9, #4]
	ldr	w0, [x9]
	cbnz	w0, LBB0_7
; %bb.10:                               ;   in Loop: Header=BB0_9 Depth=1
	mov	x0, x20
	b	LBB0_8
LBB0_11:
	add	x0, x1, #4
	add	x2, sp, #24
	bl	_ttm_bo_validate
	mov	x24, x0
LBB0_12:
	mov	x0, x24
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpAdd	Lloh6, Lloh7
	.cfi_endproc
                                        ; -- End function
	.comm	_PAGE_SHIFT,4,2                 ; @PAGE_SHIFT
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Can't find BO for addr 0x%010Lx %d %d %d %d\n"

	.no_dead_strip	_amdgpu_vce_validate_bo
.subsections_via_symbols
