	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function amdgpu_bo_validate_size
_amdgpu_bo_validate_size:               ## @amdgpu_bo_validate_size
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	movq	_AMDGPU_GEM_DOMAIN_GTT@GOTPCREL(%rip), %rax
	testl	%edx, (%rax)
	je	LBB0_2
## %bb.1:
	movq	(%rdi), %rax
	movq	_TTM_PL_TT@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movq	(%rax,%rcx,8), %rdx
	movq	_PAGE_SHIFT@GOTPCREL(%rip), %rax
	movb	(%rax), %cl
	shlq	%cl, %rdx
	movl	$1, %eax
	cmpq	%rsi, %rdx
	jbe	LBB0_5
LBB0_6:
	popq	%rbp
	retq
LBB0_2:
	movq	_AMDGPU_GEM_DOMAIN_VRAM@GOTPCREL(%rip), %rcx
	movl	$1, %eax
	testl	%edx, (%rcx)
	je	LBB0_6
## %bb.3:
	movq	(%rdi), %rcx
	movq	_TTM_PL_VRAM@GOTPCREL(%rip), %rdx
	movq	(%rdx), %rdx
	movq	(%rcx,%rdx,8), %rdx
	movq	_PAGE_SHIFT@GOTPCREL(%rip), %rcx
	movb	(%rcx), %cl
	shlq	%cl, %rdx
	cmpq	%rsi, %rdx
	ja	LBB0_6
LBB0_5:
	leaq	L_.str(%rip), %rdi
	callq	_DRM_DEBUG
	xorl	%eax, %eax
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_AMDGPU_GEM_DOMAIN_GTT,4,2      ## @AMDGPU_GEM_DOMAIN_GTT
	.comm	_TTM_PL_TT,8,3                  ## @TTM_PL_TT
	.comm	_PAGE_SHIFT,8,3                 ## @PAGE_SHIFT
	.comm	_AMDGPU_GEM_DOMAIN_VRAM,4,2     ## @AMDGPU_GEM_DOMAIN_VRAM
	.comm	_TTM_PL_VRAM,8,3                ## @TTM_PL_VRAM
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"BO size %lu > total memory in domain: %llu\n"

	.no_dead_strip	_amdgpu_bo_validate_size
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function amdgpu_bo_validate_size
_amdgpu_bo_validate_size:               ; @amdgpu_bo_validate_size
	.cfi_startproc
; %bb.0:
	stp	x29, x30, [sp, #-16]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 16
	mov	x29, sp
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
Lloh0:
	adrp	x8, _AMDGPU_GEM_DOMAIN_GTT@GOTPAGE
Lloh1:
	ldr	x8, [x8, _AMDGPU_GEM_DOMAIN_GTT@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	tst	w8, w2
	b.eq	LBB0_2
; %bb.1:
	ldr	x8, [x0]
Lloh3:
	adrp	x9, _TTM_PL_TT@GOTPAGE
Lloh4:
	ldr	x9, [x9, _TTM_PL_TT@GOTPAGEOFF]
	b	LBB0_4
LBB0_2:
Lloh5:
	adrp	x8, _AMDGPU_GEM_DOMAIN_VRAM@GOTPAGE
Lloh6:
	ldr	x8, [x8, _AMDGPU_GEM_DOMAIN_VRAM@GOTPAGEOFF]
Lloh7:
	ldr	w8, [x8]
	tst	w8, w2
	b.eq	LBB0_5
; %bb.3:
	ldr	x8, [x0]
Lloh8:
	adrp	x9, _TTM_PL_VRAM@GOTPAGE
Lloh9:
	ldr	x9, [x9, _TTM_PL_VRAM@GOTPAGEOFF]
LBB0_4:
	ldr	x9, [x9]
	ldr	x8, [x8, x9, lsl #3]
Lloh10:
	adrp	x9, _PAGE_SHIFT@GOTPAGE
Lloh11:
	ldr	x9, [x9, _PAGE_SHIFT@GOTPAGEOFF]
Lloh12:
	ldr	x9, [x9]
	lsl	x2, x8, x9
	cmp	x2, x1
	b.ls	LBB0_6
LBB0_5:
	mov	w0, #1
	ldp	x29, x30, [sp], #16             ; 16-byte Folded Reload
	ret
LBB0_6:
Lloh13:
	adrp	x0, l_.str@PAGE
Lloh14:
	add	x0, x0, l_.str@PAGEOFF
	bl	_DRM_DEBUG
	mov	w0, #0
	ldp	x29, x30, [sp], #16             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpAdd	Lloh13, Lloh14
	.cfi_endproc
                                        ; -- End function
	.comm	_AMDGPU_GEM_DOMAIN_GTT,4,2      ; @AMDGPU_GEM_DOMAIN_GTT
	.comm	_TTM_PL_TT,8,3                  ; @TTM_PL_TT
	.comm	_PAGE_SHIFT,8,3                 ; @PAGE_SHIFT
	.comm	_AMDGPU_GEM_DOMAIN_VRAM,4,2     ; @AMDGPU_GEM_DOMAIN_VRAM
	.comm	_TTM_PL_VRAM,8,3                ; @TTM_PL_VRAM
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"BO size %lu > total memory in domain: %llu\n"

	.no_dead_strip	_amdgpu_bo_validate_size
.subsections_via_symbols
