	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function drm_gem_vram_placement
_drm_gem_vram_placement:                ## @drm_gem_vram_placement
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	movq	(%rdi), %rax
	movq	%rax, 24(%rdi)
	movq	%rax, 16(%rdi)
	movq	_TTM_PL_FLAG_VRAM@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	testq	%rsi, %rcx
	je	LBB0_1
## %bb.3:
	movq	_TTM_PL_FLAG_WC@GOTPCREL(%rip), %rdx
	orq	(%rdx), %rcx
	movq	_TTM_PL_FLAG_UNCACHED@GOTPCREL(%rip), %rdx
	orq	(%rdx), %rcx
	movq	%rcx, (%rax)
	movq	_TTM_PL_FLAG_SYSTEM@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rdx
	movl	$1, %ecx
	testq	%rsi, %rdx
	jne	LBB0_4
	jmp	LBB0_6
LBB0_1:
	movq	_TTM_PL_FLAG_SYSTEM@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rdx
	xorl	%ecx, %ecx
	testq	%rsi, %rdx
	je	LBB0_2
LBB0_4:
	movq	_TTM_PL_MASK_CACHING@GOTPCREL(%rip), %rsi
	orq	(%rsi), %rdx
	movl	%ecx, %esi
	incl	%ecx
LBB0_5:
	leaq	(%rsi,%rsi,2), %rsi
	movq	%rdx, (%rax,%rsi,8)
LBB0_6:
	movl	%ecx, 8(%rdi)
	movl	%ecx, 12(%rdi)
	xorps	%xmm0, %xmm0
	movups	%xmm0, 8(%rax)
	cmpl	$1, %ecx
	je	LBB0_8
## %bb.7:
	movups	%xmm0, 32(%rax)
LBB0_8:
	popq	%rbp
	retq
LBB0_2:
	movq	_TTM_PL_MASK_CACHING@GOTPCREL(%rip), %rcx
	orq	(%rcx), %rdx
	movl	$1, %ecx
	xorl	%esi, %esi
	jmp	LBB0_5
	.cfi_endproc
                                        ## -- End function
	.comm	_TTM_PL_FLAG_VRAM,8,3           ## @TTM_PL_FLAG_VRAM
	.comm	_TTM_PL_FLAG_WC,8,3             ## @TTM_PL_FLAG_WC
	.comm	_TTM_PL_FLAG_UNCACHED,8,3       ## @TTM_PL_FLAG_UNCACHED
	.comm	_TTM_PL_FLAG_SYSTEM,8,3         ## @TTM_PL_FLAG_SYSTEM
	.comm	_TTM_PL_MASK_CACHING,8,3        ## @TTM_PL_MASK_CACHING
	.no_dead_strip	_drm_gem_vram_placement
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function drm_gem_vram_placement
_drm_gem_vram_placement:                ; @drm_gem_vram_placement
	.cfi_startproc
; %bb.0:
	ldr	x8, [x0]
	stp	x8, x8, [x0, #16]
Lloh0:
	adrp	x9, _TTM_PL_FLAG_VRAM@GOTPAGE
Lloh1:
	ldr	x9, [x9, _TTM_PL_FLAG_VRAM@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	tst	x9, x1
	b.eq	LBB0_2
; %bb.1:
Lloh3:
	adrp	x10, _TTM_PL_FLAG_WC@GOTPAGE
Lloh4:
	ldr	x10, [x10, _TTM_PL_FLAG_WC@GOTPAGEOFF]
Lloh5:
	ldr	x10, [x10]
Lloh6:
	adrp	x11, _TTM_PL_FLAG_UNCACHED@GOTPAGE
Lloh7:
	ldr	x11, [x11, _TTM_PL_FLAG_UNCACHED@GOTPAGEOFF]
Lloh8:
	ldr	x11, [x11]
	orr	x9, x10, x9
	orr	x9, x9, x11
	str	x9, [x8]
Lloh9:
	adrp	x9, _TTM_PL_FLAG_SYSTEM@GOTPAGE
Lloh10:
	ldr	x9, [x9, _TTM_PL_FLAG_SYSTEM@GOTPAGEOFF]
Lloh11:
	ldr	x9, [x9]
	mov	w10, #1
	tst	x9, x1
	b.ne	LBB0_4
	b	LBB0_6
LBB0_2:
Lloh12:
	adrp	x9, _TTM_PL_FLAG_SYSTEM@GOTPAGE
Lloh13:
	ldr	x9, [x9, _TTM_PL_FLAG_SYSTEM@GOTPAGEOFF]
Lloh14:
	ldr	x9, [x9]
	tst	x9, x1
	b.eq	LBB0_9
; %bb.3:
	mov	w10, #0
LBB0_4:
Lloh15:
	adrp	x11, _TTM_PL_MASK_CACHING@GOTPAGE
Lloh16:
	ldr	x11, [x11, _TTM_PL_MASK_CACHING@GOTPAGEOFF]
Lloh17:
	ldr	x11, [x11]
	orr	x9, x11, x9
	add	w11, w10, #1
	mov	w10, w10
LBB0_5:
	mov	w12, #24
	mul	x10, x10, x12
	str	x9, [x8, x10]
	mov	x10, x11
LBB0_6:
	stp	w10, w10, [x0, #8]
	stp	xzr, xzr, [x8, #8]
	cmp	w10, #1
	b.eq	LBB0_8
; %bb.7:
	stp	xzr, xzr, [x8, #32]
LBB0_8:
	ret
LBB0_9:
	mov	x10, #0
Lloh18:
	adrp	x11, _TTM_PL_MASK_CACHING@GOTPAGE
Lloh19:
	ldr	x11, [x11, _TTM_PL_MASK_CACHING@GOTPAGEOFF]
Lloh20:
	ldr	x11, [x11]
	orr	x9, x9, x11
	mov	w11, #1
	b	LBB0_5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.cfi_endproc
                                        ; -- End function
	.comm	_TTM_PL_FLAG_VRAM,8,3           ; @TTM_PL_FLAG_VRAM
	.comm	_TTM_PL_FLAG_WC,8,3             ; @TTM_PL_FLAG_WC
	.comm	_TTM_PL_FLAG_UNCACHED,8,3       ; @TTM_PL_FLAG_UNCACHED
	.comm	_TTM_PL_FLAG_SYSTEM,8,3         ; @TTM_PL_FLAG_SYSTEM
	.comm	_TTM_PL_MASK_CACHING,8,3        ; @TTM_PL_MASK_CACHING
	.no_dead_strip	_drm_gem_vram_placement
.subsections_via_symbols
