	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function gen8_ppgtt_notify_vgt
_gen8_ppgtt_notify_vgt:                 ## @gen8_ppgtt_notify_vgt
	.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
	movl	%esi, %r13d
	movq	%rdi, %r14
	leaq	8(%rdi), %rbx
	movq	8(%rdi), %r15
	movl	(%rdi), %edi
	callq	_px_used
	movl	%eax, %edi
	testl	%r13d, %r13d
	je	LBB0_2
## %bb.1:
	callq	_atomic_inc
	jmp	LBB0_3
LBB0_2:
	callq	_atomic_dec
LBB0_3:
	movq	%r15, %rdi
	callq	_mutex_lock
	movq	%rbx, %rdi
	callq	_i915_vm_is_4lvl
	testq	%rax, %rax
	je	LBB0_4
## %bb.9:
	movl	(%r14), %edi
	callq	_px_dma
	movl	%eax, %r12d
	movq	_pdp@GOTPCREL(%rip), %r14
	movq	(%r14), %rax
	movl	4(%rax), %edi
	callq	_vgtif_reg
	movl	%eax, %ebx
	movl	%r12d, %edi
	callq	_lower_32_bits
	movl	%ebx, %edi
	movl	%eax, %esi
	callq	_I915_WRITE
	movq	(%r14), %rax
	movl	(%rax), %edi
	callq	_vgtif_reg
	movl	%eax, %ebx
	movl	%r12d, %edi
	callq	_upper_32_bits
	movl	%ebx, %edi
	movl	%eax, %esi
	callq	_I915_WRITE
	movq	_VGT_G2V_PPGTT_L4_PAGE_TABLE_DESTROY@GOTPCREL(%rip), %rax
	movq	_VGT_G2V_PPGTT_L4_PAGE_TABLE_CREATE@GOTPCREL(%rip), %rcx
	jmp	LBB0_8
LBB0_4:
	movq	_GEN8_3LVL_PDPES@GOTPCREL(%rip), %rdx
	movq	_VGT_G2V_PPGTT_L3_PAGE_TABLE_DESTROY@GOTPCREL(%rip), %rax
	movq	_VGT_G2V_PPGTT_L3_PAGE_TABLE_CREATE@GOTPCREL(%rip), %rcx
	cmpl	$0, (%rdx)
	jle	LBB0_8
## %bb.5:
	movl	%r13d, -44(%rbp)                ## 4-byte Spill
	movq	%r15, -56(%rbp)                 ## 8-byte Spill
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_6:                                 ## =>This Inner Loop Header: Depth=1
	movq	%r14, %rdi
	movl	%ebx, %esi
	callq	_i915_page_dir_dma_addr
	movl	%eax, %r13d
	movq	_pdp@GOTPCREL(%rip), %r12
	movq	(%r12), %rax
	movl	4(%rax,%rbx,8), %edi
	callq	_vgtif_reg
	movq	%r14, %r15
	movl	%eax, %r14d
	movl	%r13d, %edi
	callq	_lower_32_bits
	movl	%r14d, %edi
	movl	%eax, %esi
	callq	_I915_WRITE
	movq	(%r12), %rax
	movl	(%rax,%rbx,8), %edi
	callq	_vgtif_reg
	movl	%eax, %r14d
	movl	%r13d, %edi
	callq	_upper_32_bits
	movl	%r14d, %edi
	movq	%r15, %r14
	movl	%eax, %esi
	callq	_I915_WRITE
	movq	_GEN8_3LVL_PDPES@GOTPCREL(%rip), %rax
	incq	%rbx
	movslq	(%rax), %rax
	cmpq	%rax, %rbx
	jl	LBB0_6
## %bb.7:
	movq	-56(%rbp), %r15                 ## 8-byte Reload
	movl	-44(%rbp), %r13d                ## 4-byte Reload
	movq	_VGT_G2V_PPGTT_L3_PAGE_TABLE_DESTROY@GOTPCREL(%rip), %rax
	movq	_VGT_G2V_PPGTT_L3_PAGE_TABLE_CREATE@GOTPCREL(%rip), %rcx
LBB0_8:
	testl	%r13d, %r13d
	cmoveq	%rax, %rcx
	movl	(%rcx), %ebx
	movq	_g2v_notify@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_vgtif_reg
	movl	%eax, %edi
	movl	%ebx, %esi
	callq	_I915_WRITE
	movq	%r15, %rdi
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_mutex_unlock                   ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_pdp,8,3                        ## @pdp
	.comm	_VGT_G2V_PPGTT_L4_PAGE_TABLE_CREATE,4,2 ## @VGT_G2V_PPGTT_L4_PAGE_TABLE_CREATE
	.comm	_VGT_G2V_PPGTT_L4_PAGE_TABLE_DESTROY,4,2 ## @VGT_G2V_PPGTT_L4_PAGE_TABLE_DESTROY
	.comm	_GEN8_3LVL_PDPES,4,2            ## @GEN8_3LVL_PDPES
	.comm	_VGT_G2V_PPGTT_L3_PAGE_TABLE_CREATE,4,2 ## @VGT_G2V_PPGTT_L3_PAGE_TABLE_CREATE
	.comm	_VGT_G2V_PPGTT_L3_PAGE_TABLE_DESTROY,4,2 ## @VGT_G2V_PPGTT_L3_PAGE_TABLE_DESTROY
	.comm	_g2v_notify,4,2                 ## @g2v_notify
	.no_dead_strip	_gen8_ppgtt_notify_vgt
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function gen8_ppgtt_notify_vgt
_gen8_ppgtt_notify_vgt:                 ; @gen8_ppgtt_notify_vgt
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x28, x27, [sp, #16]             ; 16-byte Folded Spill
	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
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x20, x1
	mov	x21, x0
	mov	x22, x0
	ldr	x23, [x22, #8]!
	ldr	w0, [x0]
	bl	_px_used
	cbz	w20, LBB0_2
; %bb.1:
	bl	_atomic_inc
	b	LBB0_3
LBB0_2:
	bl	_atomic_dec
LBB0_3:
	mov	x0, x23
	bl	_mutex_lock
	mov	x0, x22
	bl	_i915_vm_is_4lvl
	cbz	x0, LBB0_5
; %bb.4:
	ldr	w0, [x21]
	bl	_px_dma
	mov	x21, x0
Lloh0:
	adrp	x19, _pdp@GOTPAGE
Lloh1:
	ldr	x19, [x19, _pdp@GOTPAGEOFF]
	ldr	x8, [x19]
	ldr	w0, [x8, #4]
	bl	_vgtif_reg
	mov	x22, x0
	mov	x0, x21
	bl	_lower_32_bits
	mov	x1, x0
	mov	x0, x22
	bl	_I915_WRITE
	ldr	x8, [x19]
	ldr	w0, [x8]
	bl	_vgtif_reg
	mov	x22, x0
	mov	x0, x21
	bl	_upper_32_bits
	mov	x1, x0
	mov	x0, x22
	bl	_I915_WRITE
Lloh2:
	adrp	x25, _VGT_G2V_PPGTT_L4_PAGE_TABLE_DESTROY@GOTPAGE
Lloh3:
	ldr	x25, [x25, _VGT_G2V_PPGTT_L4_PAGE_TABLE_DESTROY@GOTPAGEOFF]
Lloh4:
	adrp	x26, _VGT_G2V_PPGTT_L4_PAGE_TABLE_CREATE@GOTPAGE
Lloh5:
	ldr	x26, [x26, _VGT_G2V_PPGTT_L4_PAGE_TABLE_CREATE@GOTPAGEOFF]
	b	LBB0_10
LBB0_5:
Lloh6:
	adrp	x27, _GEN8_3LVL_PDPES@GOTPAGE
Lloh7:
	ldr	x27, [x27, _GEN8_3LVL_PDPES@GOTPAGEOFF]
	ldr	w8, [x27]
	cmp	w8, #1
	b.lt	LBB0_9
; %bb.6:
	str	x23, [sp, #8]                   ; 8-byte Folded Spill
	mov	x28, #0
	mov	x22, #0
Lloh8:
	adrp	x19, _pdp@GOTPAGE
Lloh9:
	ldr	x19, [x19, _pdp@GOTPAGEOFF]
Lloh10:
	adrp	x25, _VGT_G2V_PPGTT_L3_PAGE_TABLE_DESTROY@GOTPAGE
Lloh11:
	ldr	x25, [x25, _VGT_G2V_PPGTT_L3_PAGE_TABLE_DESTROY@GOTPAGEOFF]
Lloh12:
	adrp	x26, _VGT_G2V_PPGTT_L3_PAGE_TABLE_CREATE@GOTPAGE
Lloh13:
	ldr	x26, [x26, _VGT_G2V_PPGTT_L3_PAGE_TABLE_CREATE@GOTPAGEOFF]
LBB0_7:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x21
	mov	x1, x22
	bl	_i915_page_dir_dma_addr
	mov	x23, x0
	ldr	x8, [x19]
	add	x8, x8, x28
	ldr	w0, [x8, #4]
	bl	_vgtif_reg
	mov	x24, x0
	mov	x0, x23
	bl	_lower_32_bits
	mov	x1, x0
	mov	x0, x24
	bl	_I915_WRITE
	ldr	x8, [x19]
	ldr	w0, [x8, x28]
	bl	_vgtif_reg
	mov	x24, x0
	mov	x0, x23
	bl	_upper_32_bits
	mov	x1, x0
	mov	x0, x24
	bl	_I915_WRITE
	add	x22, x22, #1
	ldrsw	x8, [x27]
	add	x28, x28, #8
	cmp	x22, x8
	b.lt	LBB0_7
; %bb.8:
	ldr	x23, [sp, #8]                   ; 8-byte Folded Reload
	b	LBB0_10
LBB0_9:
Lloh14:
	adrp	x25, _VGT_G2V_PPGTT_L3_PAGE_TABLE_DESTROY@GOTPAGE
Lloh15:
	ldr	x25, [x25, _VGT_G2V_PPGTT_L3_PAGE_TABLE_DESTROY@GOTPAGEOFF]
Lloh16:
	adrp	x26, _VGT_G2V_PPGTT_L3_PAGE_TABLE_CREATE@GOTPAGE
Lloh17:
	ldr	x26, [x26, _VGT_G2V_PPGTT_L3_PAGE_TABLE_CREATE@GOTPAGEOFF]
LBB0_10:
	cmp	w20, #0
	csel	x8, x25, x26, eq
	ldr	w20, [x8]
Lloh18:
	adrp	x8, _g2v_notify@GOTPAGE
Lloh19:
	ldr	x8, [x8, _g2v_notify@GOTPAGEOFF]
Lloh20:
	ldr	w0, [x8]
	bl	_vgtif_reg
	mov	x1, x20
	bl	_I915_WRITE
	mov	x0, x23
	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
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	b	_mutex_unlock
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh16, Lloh17
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.cfi_endproc
                                        ; -- End function
	.comm	_pdp,8,3                        ; @pdp
	.comm	_VGT_G2V_PPGTT_L4_PAGE_TABLE_CREATE,4,2 ; @VGT_G2V_PPGTT_L4_PAGE_TABLE_CREATE
	.comm	_VGT_G2V_PPGTT_L4_PAGE_TABLE_DESTROY,4,2 ; @VGT_G2V_PPGTT_L4_PAGE_TABLE_DESTROY
	.comm	_GEN8_3LVL_PDPES,4,2            ; @GEN8_3LVL_PDPES
	.comm	_VGT_G2V_PPGTT_L3_PAGE_TABLE_CREATE,4,2 ; @VGT_G2V_PPGTT_L3_PAGE_TABLE_CREATE
	.comm	_VGT_G2V_PPGTT_L3_PAGE_TABLE_DESTROY,4,2 ; @VGT_G2V_PPGTT_L3_PAGE_TABLE_DESTROY
	.comm	_g2v_notify,4,2                 ; @g2v_notify
	.no_dead_strip	_gen8_ppgtt_notify_vgt
.subsections_via_symbols
